botruntime
API ReferenceChat API

Update Message

Updates a message tags and payload. The message type cannot be changed. Calling this operation from an integration, to update an incoming message, will not invoke the bot. The other way around it also true; Calling this operation from the bot, to update an outgoing message, will not invoke the integration.

PUT
/v1/chat/messages/{id}

Path Parameters

id*string

Message id

Header Parameters

x-bot-id*string

Bot id

x-integration-id?string

Integration id

x-integration-alias?string

Integration alias

Request Body

application/json

Message data

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

curl -X PUT "https://example.com/v1/chat/messages/string" \  -H "x-bot-id: string" \  -H "Content-Type: application/json" \  -d '{}'
{  "message": {    "id": "stringstringstringstringstri",    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z",    "type": "string",    "payload": {},    "direction": "incoming",    "userId": "stringstringstringstringstri",    "conversationId": "stringstringstringstringstri",    "tags": {      "property1": "string",      "property2": "string"    },    "origin": "synthetic"  }}
{  "message": {    "id": "stringstringstringstringstri",    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z",    "type": "string",    "payload": {},    "direction": "incoming",    "userId": "stringstringstringstringstri",    "conversationId": "stringstringstringstringstri",    "tags": {      "property1": "string",      "property2": "string"    },    "origin": "synthetic"  }}