Ticket junk email.
Junk is represented as simple flat JSON objects with the following keys:
Name | Type | Description |
---|---|---|
id |
guid | Id of the junk message. |
time |
datetime | Time when receiving the junk message. |
isReadByAgent |
bool | Whether the junk message is read by agent or not. |
sentById |
guid | Id of contact or visitor. |
sentByType |
string | Type of the sender. Allowed values are "contact", "visitor", "chatbot", "channelAccount", "system", "agent", "outreachCampaign". |
type |
string | Type of the junk. Allowed values are "text", "html", "video", "audio", "image", "file", "location", "quickReply", "webView". |
metadata |
object | Message metadata, Json format. |
channelId |
string | Id of the channel. |
body |
string | Content of the junk. |
attachments |
attachments[] | Reference to JunkAttachment. |
JunkAttachment JSON Format:
Name | Type | Description |
---|---|---|
id |
guid | Id of the attachment. |
junkId |
guid | Id of the junk ticket which the attachment belongs to. |
fileKey |
string | Unique key in file service. |
name |
string | Name of the attachment. |
size |
integer | Size of the attachment. |
type |
string | Type of the attachment. Allowed values are "video", "audio", "image", "file". |
url |
string | Download URL of the attachment. |
GET ticketing/junks
Name | Type | In | Required | Description |
---|---|---|---|---|
time |
string | query | no | Filter by time. |
include |
string | query | no | Allowed values are "ticketingJunkAttachment", "sentBy". |
An array of Junk
Sample Request:
Response:
HTTP/1.1 200 OK
GET ticketing/junks/{id}
Name | Type | In | Required | Description |
---|---|---|---|---|
include |
string | query | no | Allowed values are "ticketingJunkAttachment", "sentBy". |
Sample Request:
Response:
HTTP/1.1 200 OK
POST ticketing/junks
Name | Type | In | Required | Description |
---|---|---|---|---|
time |
datetime | body | no | Time when receiving the junk message. |
isReadByAgent |
bool | body | no | Whether the junk message is read by agent or not. |
sentById |
guid | body | yes | Id of contact or visitor. |
sentByType |
string | body | yes | Type of the sender. Allowed values are "contact", "visitor", "chatbot", "channelAccount", "system", "agent", "outreachCampaign". |
type |
string | body | yes | Type of the junk. Allowed values are "text", "html", "video", "audio", "image", "file", "location", "quickReply", "webView". |
metadata |
object | body | no | Message metadata, Json format. |
channelId |
string | body | yes | Id of the channel. |
body |
string | body | no | Content of the junk. |
attachments |
attachments[] | body | no | Attachment in junk message. |
Sample Request:
Response:
HTTP/1.1 201 Created
POST ticketing/junks/{id}:notJunk
No Content
Sample Request:
Response:
HTTP/1.1 200 OK
POST ticketing/junks/{id}:read
No Content
Sample Request:
Response:
HTTP/1.1 200 OK
POST ticketing/junks/{id}:unread
No Content
Sample Request:
Response:
HTTP/1.1 200 OK
PUT ticketing/junks/{id}
Name | Type | In | Required | Description |
---|---|---|---|---|
isReadByAgent |
bool | body | no | Whether the junk message is read by agent or not. |
Sample Request:
Response:
HTTP/1.1 200 OK
DELETE ticketing/junks/{id}
No Content
Sample Request:
Response:
HTTP/1.1 204 No Content