Conversations
Resource Fields
| Name | Type | Read-only | Description |
|---|---|---|---|
| uuid | string | ||
| legacy_id | string | ||
| subject | string | ||
| channel | string | ||
| requester | User | The requester of the conversation, represented as a user resource | |
| creator | User | The creator of the conversation, represented as a user resource | |
| last_replier | User | The user (agent/customer) who responded last | |
| last_agent_replier | User | The agent who responded last. | |
| assigned_team | Team | The team that this conversation is currently assigned to | |
| assigned_agent | User | The agent that this conversation is currently assigned to | |
| status | Status |
The status of this conversation. Returns null if the field is not visible to customers
|
|
| is_closed | boolean | Whether the conversation is closed or not. Closed conversations cannnot be replied to. | |
| priority | Priority |
Priority, defines the urgency with which the conversation should be addressed. Returns null if the field is not visible to customers
|
|
| type | Type |
The Type of this conversation. Returns null if the field is not visible to customers
|
|
| read_marker | Read marker | Read marker for the currently logged in user | |
| custom_fields | Custom Fields | List of all custom fields that are visible to customers. | |
| realtime_channel | string | Subscribe to this channel for realtime updates | |
| last_message_status | string |
SENT, DELIVERED, REJECTED, SEEN
|
|
| last_message_preview | string | Preview text of the last message on this conversation | |
| last_replied_at | timestamp | ISO-8601 Format | |
| created_at | timestamp | ISO-8601 Format | |
| updated_at | timestamp | ISO-8601 Format |
Read marker
| Name | Type | Read-only | Description |
|---|---|---|---|
| id | integer | ||
| last_read_post_id | integer | ||
| last_read_at | timestamp | ISO-8601 Format | |
| unread_count | integer |
Metadata
| Version | 1.0 |
| Last Updated | January 13, 2017 |
Actions
Retrieve all conversations
GET /api/v1/conversations.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
| Ordered by | created_at (descending) |
This endpoint supports fingerprint-based authentication.
Arguments
| Name | Type | Mandatory | Description |
|---|---|---|---|
| status | string | NEW, OPEN, PENDING, COMPLETED, CLOSED, CUSTOM |
|
| priority | integer | Include all conversation having priority level less than or equal to provided level | |
| filters | string | MY_ORGANIZATION |
Response
{
"status": 200,
"data": [
{
"id": 1,
"uuid": "3502b1bf-8a7f-5ac7-967e-e2f02d0fb056",
"legacy_id": null,
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"requester":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_agent_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"assigned_team": {
"id": 1,
"legacy_id": null,
"resource_type": "team"
},
"assigned_agent":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"status": {
"id": 1,
"resource_type": "case_status"
},
"is_closed": false,
"priority": {
"id": 3,
"resource_type": "case_priority"
},
"type": {
"id": 1,
"resource_type": "case_type"
}
,
"read_marker": {
"id": 1,
"resource_type": "read_marker"
},
"custom_fields": [
{
"field": {
"id": 10,
"resource_type": "conversation_field"
}
,
"value": "12",
"resource_type": "conversation_field_value"
}
],
"last_message_status": "SEEN",
"last_message_preview": "Coffee machine annual maintenance",
"realtime_channel": "presence-d6c6a8b31be92885222ee53dde6c99c745c5f4cf77f1bd9dd3519d07fa730c71@v1_cases_1",
"last_replied_at": "2015-07-27T11:35:09+05:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1"
}
],
"resource": "conversation",
"offset": 0,
"limit": 10,
"total_count": 1
}
Retrieve a conversation
GET /api/v1/conversations/:id.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
This endpoint supports fingerprint-based authentication.
Response
{
"status": 200,
"data": {
"id": 1,
"uuid": "3502b1bf-8a7f-5ac7-967e-e2f02d0fb056",
"legacy_id": null,
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"requester":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_agent_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"assigned_team": {
"id": 1,
"legacy_id": null,
"resource_type": "team"
},
"assigned_agent":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"status": {
"id": 1,
"resource_type": "case_status"
},
"is_closed": false,
"priority": {
"id": 3,
"resource_type": "case_priority"
},
"type": {
"id": 1,
"resource_type": "case_type"
}
,
"read_marker": {
"id": 1,
"resource_type": "read_marker"
},
"custom_fields": [
{
"field": {
"id": 10,
"resource_type": "conversation_field"
}
,
"value": "12",
"resource_type": "conversation_field_value"
}
],
"last_message_status": "SEEN",
"last_message_preview": "Coffee machine annual maintenance",
"realtime_channel": "presence-d6c6a8b31be92885222ee53dde6c99c745c5f4cf77f1bd9dd3519d07fa730c71@v1_cases_1",
"last_replied_at": "2015-07-27T11:35:09+05:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1"
}
,
"resource": "conversation"
}
Retrieve a conversation on token
GET /api/v1/conversations/:id.jsonInformation
| Allowed for | Public |
Note: Token is returned in response header in
X-Request-Token parameter. Token is valid for next 120 seconds post creation.Arguments
| Name | Type | Mandatory | Description |
|---|---|---|---|
| token | string |
Response
{
"status": 200,
"data": {
"id": 1,
"uuid": "3502b1bf-8a7f-5ac7-967e-e2f02d0fb056",
"legacy_id": null,
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"requester":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_agent_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"assigned_team": {
"id": 1,
"legacy_id": null,
"resource_type": "team"
},
"assigned_agent":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"status": {
"id": 1,
"resource_type": "case_status"
},
"is_closed": false,
"priority": {
"id": 3,
"resource_type": "case_priority"
},
"type": {
"id": 1,
"resource_type": "case_type"
}
,
"read_marker": {
"id": 1,
"resource_type": "read_marker"
},
"custom_fields": [
{
"field": {
"id": 10,
"resource_type": "conversation_field"
}
,
"value": "12",
"resource_type": "conversation_field_value"
}
],
"last_message_status": "SEEN",
"last_message_preview": "Coffee machine annual maintenance",
"realtime_channel": "presence-d6c6a8b31be92885222ee53dde6c99c745c5f4cf77f1bd9dd3519d07fa730c71@v1_cases_1",
"last_replied_at": "2015-07-27T11:35:09+05:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1"
}
,
"resource": "conversation"
}
Retrieve participants
GET /api/v1/conversations/:id/participants.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
This endpoint supports fingerprint-based authentication.
Response
{
"status": 200,
"data": [
{
"id": 1,
"uuid": "11b60c25-c44c-47b8-9f48-56631cd7fa01",
"full_name": "Simon Blackhouse",
"role":
{
"id": 2,
"resource_type": "role"
},
"teams": [
{
"id": 6,
"resource_type": "team_minimal"
}
],
"avatar": "https://brewfictus.kayako.com/avatar/get/a6d2cc92-85e7-5005-b962-955efa915d26",
"last_activity_at": "2015-12-13T06:39:09+05:00",
"last_active_at": "2015-12-13T06:39:09+05:00",
"last_seen_at": "2015-12-13T06:39:09+05:00",
"presence_channel": "user_presence-281f395f6f51d031a6d3db3489906c98285191ebac41bb744f9323f61af63433@5c98cdaa58dd91ff1119a476e8b3e305d2906d3b",
"resource_type": "user_minimal"
,"resource_url": "https://brewfictus.kayako.com/api/v1/users/2"
}
],
"resource": "user_minimal",
"offset": 0,
"limit": 10,
"total_count": 1
}
Add a conversation
POST /api/v1/conversations.jsonInformation
| Allowed for | Public |
This endpoint supports fingerprint-based authentication.
Parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
| name | string | Name of the user creating this conversation. Only required if not logged in. | |
| string | Email of the user creating this conversation. Only required if not logged in. If a User by this email does not exist, a new one is created | ||
| subject | string | ||
| contents | string | The contents of the first message on this conversation | |
| source | string | HELPCENTER, MESSENGER, API |
|
| metadata | array | We accept metadata in key - value pairs Example: {"user_agent":"Chrome", "page_url":"https://brewfictus.kayako.com/pricing"} Note: Currently only user_agent & page_url are supported, user_agent can be used to set user-friendly names like Chrome, Firefox etc |
|
| priority_id | integer | ID of the Priority to assign to this case. Only accepted if customers are allowed to edit priorities | |
| form_id | integer | ||
| field_values | array | Format: {"field_key" => "value"} |
|
| files | array | File Upload multipart/form-data | |
| client_id | string | If provided, this value will be returned in the Messages resource. Used to identify messages reflected back from the server. |
Response
{
"status": 201,
"data": {
"id": 1,
"uuid": "3502b1bf-8a7f-5ac7-967e-e2f02d0fb056",
"legacy_id": null,
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"requester":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_agent_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"assigned_team": {
"id": 1,
"legacy_id": null,
"resource_type": "team"
},
"assigned_agent":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"status": {
"id": 1,
"resource_type": "case_status"
},
"is_closed": false,
"priority": {
"id": 3,
"resource_type": "case_priority"
},
"type": {
"id": 1,
"resource_type": "case_type"
}
,
"read_marker": {
"id": 1,
"resource_type": "read_marker"
},
"custom_fields": [
{
"field": {
"id": 10,
"resource_type": "conversation_field"
}
,
"value": "12",
"resource_type": "conversation_field_value"
}
],
"last_message_status": "SEEN",
"last_message_preview": "Coffee machine annual maintenance",
"realtime_channel": "presence-d6c6a8b31be92885222ee53dde6c99c745c5f4cf77f1bd9dd3519d07fa730c71@v1_cases_1",
"last_replied_at": "2015-07-27T11:35:09+05:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1"
}
,
"resource": "conversation"
}
Update a conversation
PUT /api/v1/conversations/:id.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
Parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
| source | string | Allowed values: HELPCENTER, MESSENGER, API. This parameter can be used to execute different Triggers depending on the source of the update. |
|
| field_values | array | Format: ['field_key' => value] |
|
| subject | string | ||
| priority_id | integer | ||
| status_id | integer | ||
| type_id | integer |
Response
{
"status": 200,
"data": {
"id": 1,
"uuid": "3502b1bf-8a7f-5ac7-967e-e2f02d0fb056",
"legacy_id": null,
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"requester":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"last_agent_replier":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"assigned_team": {
"id": 1,
"legacy_id": null,
"resource_type": "team"
},
"assigned_agent":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"status": {
"id": 1,
"resource_type": "case_status"
},
"is_closed": false,
"priority": {
"id": 3,
"resource_type": "case_priority"
},
"type": {
"id": 1,
"resource_type": "case_type"
}
,
"read_marker": {
"id": 1,
"resource_type": "read_marker"
},
"custom_fields": [
{
"field": {
"id": 10,
"resource_type": "conversation_field"
}
,
"value": "12",
"resource_type": "conversation_field_value"
}
],
"last_message_status": "SEEN",
"last_message_preview": "Coffee machine annual maintenance",
"realtime_channel": "presence-d6c6a8b31be92885222ee53dde6c99c745c5f4cf77f1bd9dd3519d07fa730c71@v1_cases_1",
"last_replied_at": "2015-07-27T11:35:09+05:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1"
}
,
"resource": "conversation"
}
Messages
RESOURCE FIELDS
| Name | Type | Read-only | Description |
|---|---|---|---|
| uuid | string | ||
| client_id | string | client_id is provided by the client when creating a message. Can be used to identify messages reflected from the server back to the originating entity. This value may be null if not supplied by the client. Since this is only useful for realtime communication, older values might be erased periodically. |
|
| subject | string | ||
| channel | string | Channel represents the source from which message was originally created. MAIL, HELPCENTER, TWITTER, MESSENGER, FACEBOOK |
|
| content_text | string | ||
| content_html | string | ||
| creator | User | The creator of the post, represented as a user resource |
|
| attachments | Attachments | ||
| download_all | string | ||
| source | string | API, AGENT, MAIL, MESSENGER, MOBILE, HELPCENTER |
|
| metadata | array | Metadata will be in key - value pair | |
| message_status | string | SENT, DELIVERED, REJECTED, SEEN Default: SENT |
|
| message_status_reject_type | string | BOUNCE, BLOCKED, DROPPED, DEFERRED, EXPIRED, ERROR Note: This field applicable for REJECTED message_status |
|
| message_status_reject_reason | string | Reject reason from MTA Note: This field applicable for REJECTED message_status |
|
| message_status_updated_at | timestamp | ISO-8601 Format | |
| created_at | timestamp | ISO-8601 Format | |
| updated_at | timestamp | ISO-8601 Format | |
| resource_type | string | Categorized the posts (Facebook, Twitter, Email etc.) |
Attachments
RESOURCE FIELDS
| Name | Type | Read-only | Description |
|---|---|---|---|
| name | string | ||
| size | integer | ||
| width | integer | Only if the attachment is image | |
| height | integer | Only if the attachment is image | |
| type | string | Mime-type of the file | |
| content_id | string | Content ID used for inline attachment | |
| alt | string | ||
| url | string | The URL to view the attachment | |
| url_download | string | The URL to download the attachment | |
| thumbnails | Thumbnails | ||
| created_at | timestamp | ISO-8601 Format |
Thumbnails
RESOURCE FIELDS
| Name | Type | Read-only | Description |
|---|---|---|---|
| name | string | ||
| size | integer | ||
| width | integer | ||
| height | integer | ||
| type | string | Mime-type of the file | |
| url | string | The URL to view the thumbnail | |
| created_at | timestamp | ISO-8601 Format |
Retrieve all messages
GET /api/v1/conversations/:id/messages.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
| Ordered by | created_at (descending) |
This endpoint supports fingerprint-based authentication.
Response
{
"status": 200,
"data": [
{
"id": 1,
"uuid": "c96c7abe-2d75-4ab9-ad85-87cf1b609e93",
"client_id": "93a236f0-edac-4b5a-8747-14140da7d4dc",
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"content_text": "Dear Caryn,\n\n\t\t\t\tIt is that fun time of the year again - annual maintenance time! Further to our phone conversation, .....",
"content_html": "Dear Caryn,<br />\n<br />\n\t\t\t\tIt is that fun time of the year again - annual maintenance time! Further to our phone conversation, .....",
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"attachments": [],
"download_all": null,
"source": "MESSENGER",
"metadata": {
"user_agent": "Chrome",
"page_url": "https://brewfictus.kayako.com/pricing"
},
"message_status": "SENT",
"message_status_reject_type": null,
"message_status_reject_reason": null,
"message_status_updated_at": "2016-11-08T18:44:27+00:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "case_message",
"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1/messages/1"
}
],
"resource": "conversation_message",
"offset": 0,
"limit": 10,
"total_count": 1
}
Retrieve a message
GET /api/v1/conversations/:id/messages/:id.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
This endpoint supports fingerprint-based authentication.
Response
{
"status": 200,
"data": {
"id": 1,
"uuid": "c96c7abe-2d75-4ab9-ad85-87cf1b609e93",
"client_id": "93a236f0-edac-4b5a-8747-14140da7d4dc",
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"content_text": "Dear Caryn,\n\n\t\t\t\tIt is that fun time of the year again - annual maintenance time! Further to our phone conversation, .....",
"content_html": "Dear Caryn,<br />\n<br />\n\t\t\t\tIt is that fun time of the year again - annual maintenance time! Further to our phone conversation, .....",
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"attachments": [],
"download_all": null,
"source": "MESSENGER",
"metadata": {
"user_agent": "Chrome",
"page_url": "https://brewfictus.kayako.com/pricing"
},
"message_status": "SENT",
"message_status_reject_type": null,
"message_status_reject_reason": null,
"message_status_updated_at": "2016-11-08T18:44:27+00:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "case_message",
"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1/messages/1"
}
,
"resource": "conversation_message"
}
Add a message
POST /api/v1/conversations/:id/messages.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
This endpoint supports fingerprint-based authentication.
Parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
| contents | string | ||
| source | string | HELPCENTER, MESSENGER, API |
|
| metadata | array | We accept the metadata in key - value pair Example: {"user_agent":"Chrome", "page_url":"https://brewfictus.kayako.com/pricing"} Currently we support user_agent & page_url, user_agent can be used to set user-friendly names like Chrome, Firefox etc. A raw user agent string (like Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/55.0.2883.87 Chrome/55.0.2883.87 Safari/537.36) can also be passed in using the key user_agent_raw. This will be parsed and set in the user_agent node. |
|
| client_id | string | If provided, this value will be returned in the Messages resource. Used to identify messages reflected back from the server. | |
| files | array | File Upload multipart/form-data | |
| file_ids | string | Comma-separated list of file IDs. Files can be uploaded via the Add a file endpoint |
Response
{
"status": 201,
"data": {
"id": 1,
"uuid": "c96c7abe-2d75-4ab9-ad85-87cf1b609e93",
"client_id": "93a236f0-edac-4b5a-8747-14140da7d4dc",
"subject": "Atmosphere Coffee, Inc annual maintenance",
"channel": "MAIL",
"content_text": "Dear Caryn,\n\n\t\t\t\tIt is that fun time of the year again - annual maintenance time! Further to our phone conversation, .....",
"content_html": "Dear Caryn,<br />\n<br />\n\t\t\t\tIt is that fun time of the year again - annual maintenance time! Further to our phone conversation, .....",
"creator":
{
"id": 1,
"resource_type": "user_minimal"
}
,
"attachments": [],
"download_all": null,
"source": "MESSENGER",
"metadata": {
"user_agent": "Chrome",
"page_url": "https://brewfictus.kayako.com/pricing"
},
"message_status": "SENT",
"message_status_reject_type": null,
"message_status_reject_reason": null,
"message_status_updated_at": "2016-11-08T18:44:27+00:00",
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "case_message",
"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/1/messages/1"
}
,
"resource": "conversation_message"
}
Update a Message
PUT /api/v1/conversations/:id/messages/:id.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
This endpoint supports fingerprint-based authentication.
Parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
| message_status | string | Allowed values are DELIVERED, SEEN |
Response
{
"status": 200
}
Conversation forms
RESOURCE FIELDS
| Name | Type | Read-only | Description |
|---|---|---|---|
| title | string | Deprecated: This field will be removed soon | |
| titles | Field Locales | ||
| description | string | Deprecated: This field will be removed soon | |
| descriptions | Field Locales | ||
| fields | Fields | ||
| brand | Brand | ||
| created_at | timestamp | ISO-8601 Format | |
| updated_at | timestamp | ISO-8601 Format |
Retrieve all forms
GET /api/v1/conversations/forms.jsonInformation
| Allowed for | Public |
| Ordered by | sort_order (ascending) |
Response
{
"status": 200,
"data": [
{
"id": 1,
"title": "Maintenance job form",
"description": null,
"fields": [
{
"id": 10,
"resource_type": "conversation_field"
}
],
"brand": null,
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation_form"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/forms/1"
}
],
"resource": "conversation_form",
"total_count": 1
}
Retrieve a from
GET /api/v1/conversations/forms/:id.jsonInformation
| Allowed for | Public |
Response
{
"status": 200,
"data": {
"id": 1,
"title": "Maintenance job form",
"description": null,
"fields": [
{
"id": 10,
"resource_type": "conversation_field"
}
],
"brand": null,
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation_form"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/forms/1"
}
,
"resource": "conversation_form"
}
Custom fields
RESOURCE FIELDS
| Name | Type | Read-only | Description |
|---|---|---|---|
| fielduuid | string | ||
| titles | Field Locales | ||
| type | string | Supported Types: TEXT, TEXTAREA, CHECKBOX, RADIO, SELECT, DATE, FILE, NUMERIC, DECIMAL, YESNO, REGEX, CASCADINGSELECT |
|
| key | string | ||
| descriptions | Field Locales | ||
| is_required | boolean | ||
| is_editable | boolean | ||
| is_system | boolean | ||
| regular_expression | string | ||
| options | Options | Presented for a field of type CHECKBOX, RADIO, SELECT, CASCADINGSELECT |
|
| created_at | string | ISO-8601 Format | |
| updated_at | string | ISO-8601 Format |
Retrieve fields
GET /api/v1/conversations/fields.jsonInformation
| Allowed for | Public |
Response
{
"status": 200,
"data": [
{
"id": 10,
"fielduuid": "7a9b2b25-b164-48a5-99c4-59eee826e285",
"titles":
[
{
"id": 1,
"resource_type": "locale_field"
},
{
"id": 2,
"resource_type": "locale_field"
}
],
"type": "NUMERIC",
"key": "reported_issues",
"descriptions": [],
"is_required": true,
"is_editable": true,
"is_system": false,
"regular_expression": null,
"options": [],
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation_field"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/fields/10"
}
],
"resource": "conversation_field",
"offset": 0,
"limit": 10,
"total_count": 1
}
Retrieve a field
GET /api/v1/conversations/fields/:id.jsonInformation
| Allowed for | Public |
Response
{
"status": 200,
"data": {
"id": 10,
"fielduuid": "7a9b2b25-b164-48a5-99c4-59eee826e285",
"titles":
[
{
"id": 1,
"resource_type": "locale_field"
},
{
"id": 2,
"resource_type": "locale_field"
}
],
"type": "NUMERIC",
"key": "reported_issues",
"descriptions": [],
"is_required": true,
"is_editable": true,
"is_system": false,
"regular_expression": null,
"options": [],
"created_at": "2015-12-28T08:52:45+05:00",
"updated_at": "2015-12-28T08:52:45+05:00",
"resource_type": "conversation_field"
,"resource_url": "https://brewfictus.kayako.com/api/v1/conversations/fields/10"
}
,
"resource": "conversation_field"
}
Satisfaction Ratings
RESOURCE FIELDS
| Name | Type | Read-only | Description |
|---|---|---|---|
| score | string | GOOD, BAD |
|
| comment | string | The comment provided when creating this rating. Can be empty if no comment was provided. | |
| conversation | Conversation | The Conversation that this rating belongs to | |
| creator | User | The User that created this rating | |
| created_at | timestamp | ISO-8601 Format | |
| updated_at | timestamp | ISO-8601 Format |
Retrieve all ratings
GET /api/v1/conversations/:id/ratings.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
| Ordered by | created_at (descending) |
This endpoint supports fingerprint-based authentication.
Response
{
"status": 200,
"data": [
{
"id": 1,
"score": "GOOD",
"comment": "Excellent service!",
"conversation": {
"id": 1,
"resource_type": "conversation"
}
,
"creator":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"created_at": "2015-07-28T06:15:24+05:00",
"updated_at": "2015-07-28T06:15:24+05:00",
"resource_type": "conversation_rating",
"resource_url": "https://brewfictus.kayako.com/api/v1/cases/ratings/1"
}
],
"resource": "conversation_rating",
"offset": 0,
"limit": 10,
"total_count": 1
}
Add a rating
POST /api/v1/conversations/:id/ratings.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
This endpoint supports fingerprint-based authentication.
Only creator of the conversation is allowed to rate their conversation.
Parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
| score | string | GOOD/BAD |
|
| comment | string | A comment to be added to this rating. Can be updated later if required. |
Response
{
"status": 201,
"data": {
"id": 1,
"score": "GOOD",
"comment": "Excellent service!",
"conversation": {
"id": 1,
"resource_type": "conversation"
}
,
"creator":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"created_at": "2015-07-28T06:15:24+05:00",
"updated_at": "2015-07-28T06:15:24+05:00",
"resource_type": "conversation_rating",
"resource_url": "https://brewfictus.kayako.com/api/v1/cases/ratings/1"
}
,
"resource": "conversation_rating"
}
Update a rating
PUT /api/v1/conversations/:id/ratings/:id.jsonInformation
| Allowed for | Customers, Collaborators, Agents, Admins & Owners |
This endpoint supports fingerprint-based authentication.
Only creator of the conversation is allowed to update rating of their conversation.
Parameters
| Name | Type | Mandatory | Description |
|---|---|---|---|
| score | string | GOOD/BAD |
|
| comment | string |
Response
{
"status": 200,
"data": {
"id": 1,
"score": "GOOD",
"comment": "Excellent service!",
"conversation": {
"id": 1,
"resource_type": "conversation"
}
,
"creator":
{
"id": 2,
"resource_type": "user_minimal"
}
,
"created_at": "2015-07-28T06:15:24+05:00",
"updated_at": "2015-07-28T06:15:24+05:00",
"resource_type": "conversation_rating",
"resource_url": "https://brewfictus.kayako.com/api/v1/cases/ratings/1"
}
,
"resource": "conversation_rating"
}