What's New
Cloud Contact Center Terminology Update
https://console.tim.qq.com/v4/desk_http_svc/send_msg?sdkappid=88888888&identifier=admin&usersig=xxx&random=99999999&contenttype=json
Parameter | Description |
v4/desk_http_svc/send_msg | Request API. |
sdkappid | Assigned SDKAppID in the IM console when creating an application. |
identifier | |
usersig | Signature generated by the App administrator account. For specific operations, see Generate UserSig. |
random | Enter a random 32-bit unsigned integer in the range of [0,4294967295]. |
contenttype | The request format is fixed as json. |
{"SessionId": "fd8a2e30-54de-4e40-bcaf-02718409c5cf","MsgRandom": 8436874,"MsgBody": [{"MsgType": "TIMTextElem","MsgContent": {"Text": "Welcome to use smart customer service. Glad to serve you."}}],"CloudCustomData": "your cloud custom data"}
{"FromAccount": "@customer_service_account","ToAccount": "user45","MsgRandom": 82139,"MsgBody": [{"MsgType": "TIMTextElem","MsgContent": {"Text": "Welcome to register with xx mall. You can purchase the products you want herein. If you have any questions, contact our customer service."}}],"CloudCustomData": "your cloud custom data"}
{"FromAccount": "@customer_service_account","ToAccount": "user45","MsgRandom": 82139,"MsgBody": [{"MsgType": "TIMCustomElem","MsgContent": {"Data": "{\\"src\\": \\"22\\",\\"content\\": {\\"header\\": \\"card title\\",\\"desc\\": \\"description\\",\\"pic\\": \\"https://static.cloudcachetci.com/qcloud/portal/kit/images/presale.a4955999.jpeg\\",\\"url\\": \\"https://www.qcloud.com/\\"},\\"customerServicePlugin\\": 0}"}}],"CloudCustomData": "your cloud custom data"}
Field | Type | Required | Description |
SessionId | String | Optional. | Session ID. If this field is filled, there is no need to fill the FromAccount and ToAccount fields. |
FromAccount | String | Optional. | Sender UserID, applicable only to the client-side integration method of "application/client", and the sender must be a customer service account. |
ToAccount | String | Optional. | Recipient UserID, applicable only to the client-side integration method of "application/client", and the recipient is a general user. |
MsgRandom | Integer | Required | Message random number (a 32-bit unsigned integer) for deduplication. |
MsgBody | Array | Required | Message content, for the specific format, please see message format description. For the custom message formats defined by smart customer service (such as card messages, order messages, etc.), please participate Integration Solution (No UI). Serialize the well-defined JSON data structure in the document and place it into the Data field of the custom message. |
CloudCustomData | String | Optional. | |
ExcludeFromUserRespTimeout | Integer | Optional. | Control whether this message is counted into the countdown of "user reply timeout" when a user chats with a human customer service. 0 means timing, and 1 means no timing. The default is 0. |
{"ActionStatus": "OK","ErrorInfo": "","ErrorCode": 0}
Field | Type | Description |
ErrorCode | Integer | Error Code: 0 indicates success. Non-zero indicates failure. |
ErrorInfo | String | Error message. |
ActionStatus | String | Result of request processing. |
Error Code | Description |
90001 | JSON format parsing failed. Check whether the request package conforms to the JSON Specification. |
90002 | The MsgBody in the JSON format request packet does not match the message format description, or the MsgBody is not an Array type. Please see the definition of TIMMsgElement object. |
90005 | The JSON format request body lacks the MsgRandom field or the MsgRandom field is not of Integer type. |
90007 | The MsgBody in the JSON format request body is not of Array type. Change it to Array type. |
90009 | Request requires App administrator permissions. |
90010 | The JSON format request packet does not match the message format description. Please see the definition of TIMMsgElement object. |
93000 | The JSON data packet is overly long. The message body should not exceed 12K. |
141002 | Internal error, retry. |
141004 | Invalid parameter. |
141005 | The session does not exist or has stopped. |
Apakah halaman ini membantu?
Anda juga dapat Menghubungi Penjualan atau Mengirimkan Tiket untuk meminta bantuan.
masukan