Private Canned Message
- 04 Jul 2022
- 4 Minutes to read
- Print
- DarkLight
Private Canned Message
- Updated on 04 Jul 2022
- 4 Minutes to read
- Print
- DarkLight
Article summary
Did you find this summary helpful?    
Thank you for your feedback!
Private Canned Message
You need Manage Private Canned Messages permission to manage the private canned message.
- Private Canned Messages- Private Canned Messages Manage- GET global/privateCannedMessages- Get the list of Private Canned Messages
- GET global/privateCannedMessages/{id}- Get a single Private Canned Message
- POST global/privateCannedMessages- Create a new Private Canned Message
- PUT global/privateCannedMessages/{id}- Update the Private Canned Message
- DELETE global/privateCannedMessages/{id}- Remove the Private Canned Message
 
Private Canned Message JSON Format
Private Canned Message is represented as simple flat JSON objects with the following keys:
| Name | Type | Description | 
|---|---|---|
| id | guid | Id of the private canned message. | 
| categoryId | guid | Id of the category. | 
| name | string | Name of the canned message. | 
| message | string | Default message content in all channels. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| htmlMessage | string | Message content for html email in Ticketing & Messaging. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| textMessage | string | Message content for plaintext email in Ticketing & Messaging. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| shortcuts | string | Shortcut using which agents can quickly locate the canned message while chatting with a visitor. | 
| createdById | guid | Id of the agent who create the canned message. | 
Get the list of Private Canned Messages
GET global/privateCannedMessages
- Parameters:
| Name | Type | in | Required | Description | 
|---|---|---|---|---|
| category | guid | query | no | Id of the private canned message category. | 
| keywords | string | query | no | Filter by keywords in name and message of the private canned message. | 
| include | string | query | no | Allowed value is "privateCannedMessageCategory". | 
- Response:
An array of Private Canned Message
- Example
Sample Request:
curl https://api11.comm100.io/v4/global/privateCannedMessages \ 
    -X 'GET' \ 
    -H 'Authorization: Bearer {access_token}' \ 
Response:
HTTP/1.1 200 OK
[
  {
      "id": "e1be942c-b8e9-470a-8dfd-81ca521b1548",
      "categoryId": "79a02303-959b-eb11-8103-00155d081d0b",
      "name": "Goodbye",
      "message": "Goodbye",
      "htmlMessage": "<p>Goodbye</p>",
      "textMessage": "Goodbye",
      "shortcuts": "bye",
      "createdById": "9a413cfe-792e-4abe-bc5e-8595640ddb3d"
  }
] 
Get a single Private Canned Message
GET global/privateCannedMessages/{id}
- Parameters:
| Name | Type | in | Required | Description | 
|---|---|---|---|---|
| include | string | query | no | Allowed value is "privateCannedMessageCategory". | 
- Response:
- Example
Sample Request:
curl https://api11.comm100.io/v4/global/privateCannedMessages/e1be942c-b8e9-470a-8dfd-81ca521b1548 \ 
    -X 'GET' \ 
    -H 'Authorization: Bearer {access_token}' \ 
Response:
HTTP/1.1 200 OK
{
  "id": "e1be942c-b8e9-470a-8dfd-81ca521b1548",
  "categoryId": "79a02303-959b-eb11-8103-00155d081d0b",
  "name": "Goodbye",
  "message": "Goodbye",
  "htmlMessage": "<p>Goodbye</p>",
  "textMessage": "Goodbye",
  "shortcuts": "bye",
  "createdById": "9a413cfe-792e-4abe-bc5e-8595640ddb3d"
} 
Create a new Private Canned Message
POST global/privateCannedMessages
- Parameters:
| Name | Type | in | Required | Description | 
|---|---|---|---|---|
| categoryId | guid | body | yes | Id of the category. | 
| name | string | body | yes | Name of the canned message. | 
| message | string | body | yes | Default message content in all channels. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| htmlMessage | string | body | no | Message content for html email in Ticketing & Messaging. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| textMessage | string | body | no | Message content for plaintext email in Ticketing & Messaging. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| shortcuts | string | body | no | Shortcut using which agents can quickly locate the canned message while chatting with a visitor. | 
| createdById | guid | body | no | Id of the agent who create the canned message. | 
- Response:
- Example
Sample Request:
curl https://api11.comm100.io/v4/global/privateCannedMessages \ 
    -X 'POST' \ 
    -H 'Authorization: Bearer {access_token}' \ 
    -H 'Content-Type: application/json' \ 
    -D '{"categoryId":"79a02303-959b-eb11-8103-00155d081d0b","name":"Goodbye","message":"Goodbye","htmlMessage":"<p>Goodbye</p>","textMessage":"Goodbye","shortcuts":"bye","createdById":"9a413cfe-792e-4abe-bc5e-8595640ddb3d"}' 
Response:
HTTP/1.1 201 Created
{
  "id": "e1be942c-b8e9-470a-8dfd-81ca521b1548",
  "categoryId": "79a02303-959b-eb11-8103-00155d081d0b",
  "name": "Goodbye",
  "message": "Goodbye",
  "htmlMessage": "<p>Goodbye</p>",
  "textMessage": "Goodbye",
  "shortcuts": "bye",
  "createdById": "9a413cfe-792e-4abe-bc5e-8595640ddb3d"
} 
Update the Private Canned Message
PUT global/privateCannedMessages/{id}
- Parameters:
| Name | Type | in | Required | Description | 
|---|---|---|---|---|
| categoryId | guid | body | yes | Id of the category. | 
| name | string | body | yes | Name of the canned message. | 
| message | string | body | yes | Default message content in all channels. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| htmlMessage | string | body | no | Message content for html email in Ticketing & Messaging. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| textMessage | string | body | no | Message content for plaintext email in Ticketing & Messaging. You can pass both plaintext and base64 encoded text. If the request containing plaintext is blocked by comm100 WAF, use base64 format. When using base64, add "data:text/plain;base64," before the content. | 
| shortcuts | string | body | no | Shortcut using which agents can quickly locate the canned message while chatting with a visitor. | 
| createdById | guid | body | no | Id of the agent who create the canned message. | 
- Response:
- Example
Sample Request:
curl https://api11.comm100.io/v4/global/privateCannedMessages/e1be942c-b8e9-470a-8dfd-81ca521b1548 \ 
    -X 'PUT' \ 
    -H 'Authorization: Bearer {access_token}' \ 
    -H 'Content-Type: application/json' \ 
    -D '{"categoryId":"79a02303-959b-eb11-8103-00155d081d0b","name":"Goodbye","message":"Goodbye","htmlMessage":"<p>Goodbye</p>","textMessage":"Goodbye","shortcuts":"bye","createdById":"9a413cfe-792e-4abe-bc5e-8595640ddb3d"}' 
Response:
HTTP/1.1 200 OK
{
  "id": "e1be942c-b8e9-470a-8dfd-81ca521b1548",
  "categoryId": "79a02303-959b-eb11-8103-00155d081d0b",
  "name": "Goodbye",
  "message": "Goodbye",
  "htmlMessage": "<p>Goodbye</p>",
  "textMessage": "Goodbye",
  "shortcuts": "bye",
  "createdById": "9a413cfe-792e-4abe-bc5e-8595640ddb3d"
} 
Remove the Private Canned Message
DELETE global/privateCannedMessages/{id}
- Parameters:
No Parameters
- Response:
No Content
- Example
Sample Request:
curl https://api11.comm100.io/v4/global/privateCannedMessages/e1be942c-b8e9-470a-8dfd-81ca521b1548 \ 
    -X 'DELETE' \ 
    -H 'Authorization: Bearer {access_token}' \ 
Response:
HTTP/1.1 204 No Content
Was this article helpful?