Contact identity
Contact identities
- Contact identities Manage
GET global/contactIdentities
GET global/contactIdentities/{id}
POST global/contactIdentities
PUT global/contactIdentities/{id}
DELETE global/contactIdentities/{id}
Model
Contact identity JSON Format
Contact identity is represented as simple flat JSON objects with the following keys:
Name | Type | Description |
---|---|---|
id |
guid | Id of the contact identity. |
contactId |
guid | Id of the contact. |
contactIdentityType |
string | Allowed values are: "visitor", "email", "SMS", "Facebook", "Twitter", "WeChat", "ssoid", "externalid", "Whatsapp", "inphase". |
value |
string | The value of the identity. |
avatarUrl |
string | The avatar used in a certain channel, like the avatar of a Facebook user. Not every channel yields an avatar. For example, SMS Numbers will not produce one. |
infoUrl |
string | Contact information from the channels. Such as the number of Twitter followers and tweets from the twitter identity. The info is displayed in an iframe in the agent console. Available for Twitter, Facebook, SMS, and WeChat. |
screenName |
string | Twitter only. Like @Comm100Corp. |
originalContactPageUrl |
string | The contact profile URL on Facebook or Twitter. |
Endpoint
Get the list of Contact identities
GET global/contactIdentities
Example
Sample Request:
curl https://api11.comm100.io/v4/global/contactIdentities \
-X
'GET'
\
-H
'Authorization: Bearer {access_token}'
\
Response:
HTTP/1.1 200 OK
Get a single Contact identity
GET global/contactIdentities/{id}
Example
Sample Request:
curl https://api11.comm100.io/v4/global/contactIdentities/{id} \
-X
'GET'
\
-H
'Authorization: Bearer {access_token}'
\
Response:
HTTP/1.1 200 OK
Create a new Contact identity
POST global/contactIdentities
Parameters:
Name | Type | In | Required | Description |
---|---|---|---|---|
contactId |
guid | body | no | Id of the contact. |
contactIdentityType |
string | body | yes | Allowed values are: "visitor", "email", "SMS", "Facebook", "Twitter", "WeChat", "ssoid", "externalid", "Whatsapp", "inphase". |
value |
string | body | yes | The value of the identity. |
avatarUrl |
string | body | no | The avatar used in a certain channel, like the avatar of a Facebook user. Not every channel yields an avatar. For example, SMS Numbers will not produce one. |
infoUrl |
string | body | no | Contact information from the channels. Such as the number of Twitter followers and tweets from the twitter identity. The info is displayed in an iframe in the agent console. Available for Twitter, Facebook, SMS, and WeChat. |
screenName |
string | body | no | Twitter only. Like @Comm100Corp. |
originalContactPageUrl |
string | body | no | The contact profile URL on Facebook or Twitter. |
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/global/contactIdentities \
-X
'POST'
\
-H
'Authorization: Bearer {access_token}'
\
-H
'Content-Type: application/json'
\
-D
'{"contactId":"1d090a45-14cf-4613-a7f8-c07ee90a2f5f","contactIdentityType":"Twitter","value":"1361654692588728354","avatarUrl":"https://dash11.comm100.com/api/v4/chatbot/images/42dwdaww-92e6-4487-a2e8-92e68d6892e6","infoUrl":"https://dash17.comm100.io/api/twitterapp/platform/users?uid=1831584982944736245","screenName":"@Comm100Corp","originalContactPageUrl":"https://twitter.com/Vincent42"}'
Response:
HTTP/1.1 201 Created
Update the Contact identity
PUT global/contactIdentities/{id}
Parameters:
Name | Type | In | Required | Description |
---|---|---|---|---|
contactId |
guid | body | no | Id of the contact. |
contactIdentityType |
string | body | yes | Allowed values are: "visitor", "email", "SMS", "Facebook", "Twitter", "WeChat", "ssoid", "externalid", "Whatsapp", "inphase". |
value |
string | body | yes | The value of the identity. |
avatarUrl |
string | body | no | The avatar used in a certain channel, like the avatar of a Facebook user. Not every channel yields an avatar. For example, SMS Numbers will not produce one. |
infoUrl |
string | body | no | Contact information from the channels. Such as the number of Twitter followers and tweets from the twitter identity. The info is displayed in an iframe in the agent console. Available for Twitter, Facebook, SMS, and WeChat. |
screenName |
string | body | no | Twitter only. Like @Comm100Corp. |
originalContactPageUrl |
string | body | no | The contact profile URL on Facebook or Twitter. |
Response:
Example
Sample Request:
curl https://api11.comm100.io/v4/global/contactIdentities/b5333222-094e-4cb9-b190-9dccccb37c70 \
-X
'PUT'
\
-H
'Authorization: Bearer {access_token}'
\
-H
'Content-Type: application/json'
\
-D
'{"contactId":"1d090a45-14cf-4613-a7f8-c07ee90a2f5f","contactIdentityType":"Twitter","value":"1361654692588728354","avatarUrl":"https://dash11.comm100.com/api/v4/chatbot/images/42dwdaww-92e6-4487-a2e8-92e68d6892e6","infoUrl":"https://dash17.comm100.io/api/twitterapp/platform/users?uid=1831584982944736245","screenName":"@Comm100Corp","originalContactPageUrl":"https://twitter.com/Vincent42"}'
Response:
HTTP/1.1 200 OK
Remove the Contact identity
DELETE global/contactIdentities/{id}
Parameters:
No Parameters
Response:
No Content
Example
Sample Request:
curl https://api11.comm100.io/v4/global/contactIdentities/b5333222-094e-4cb9-b190-9dccccb37c70 \
-X
'DELETE'
\
-H
'Authorization: Bearer {access_token}'
\
Response:
HTTP/1.1 204 No Content