User APIs

Assign / Revoke Key Contact

OVERVIEW

Overview

This API is used to assign and revoke a user as a Key Contact.

Since v5.0

HTTP Request

POST  /api/2/users/<ID>/keycontact?{parameters}

OR

POST  /api/2/users/<EMAIL>/keycontact?{parameters}

 

URL Parameters
Parameter Description
ID The ID of the user to assign / revoke Key Contact
EMAIL The email of the user to assign / revoke Key Contact

 

URL Query Parameters
Parameter Format Description
action String

Set value as assign/revoke to assign or revoke Key Contact:

  1. assign: to make user a key contact set "assign"
  2. revoke: to revoke a key contact set "revoke"

GET /api/2/users/3/keycontact?action=assign

 
HTTP Headers
HTTP Request Header Description Example
Authorization The API Authorisation token. "Bearer XXXXXXXXXXXXX"
Accept

The format of the expected response

  • "application/json"
  • "application/xml"

If no parameter is set, JSON is the default response given.

"application/xml"
Content-Type

The format of the provided content

  • "application/json"
  • "application/xml"

If no parameter is set, JSON is the expected content by default.

"application/json"

 

HTTP Response

Success

HTTP response 200 with User summary Object

(Example below)

 

Error

See API Error messages 

 

Example HTTP Request & Response

POST http://example.com/context/api/2/users/3/keycontact?action=assign

 

JSON Response

{

    "user": {

        "id": 3,

        "email": "user@domain.com",

        "link": "http://example.com/context/api/2/user/3"

    }

}

 

 

Comments


0 Comments

Last Updated: Nov 08,2024