chats

This endpoint updates properties of a chat

patch/chats/{chat_id}

Request

  • Base URL
    https://api.periskope.app/v1
  • URL
    https://api.periskope.app/v1/chats/{chat_id}
  • Auth
    HTTP bearer

Headers

x-phonestring
Example:918527184400

Please provide the number of the phone you want to call with this API in the header. The number must be in country code + number format without any characters or spaces, e.g. 919876543210; Alternatively, provide the phone_id (phone-xxxxxxxxxxxx) in the header

Request body

assigned_tostring
  • Update the assignee of the chat. The assignee must be a valid email address of a user in the organization
labelsstring
  • A comma-separated list of labels to be assigned to the chat. All labels are case-insensitive.
  • If any label currently does not exist, it will be created
status'open' | 'closed'
  • Update the status of the chat. Must be either open or closed.
  • Setting the status to closed marks the chat as closed and records the closed timestamp; setting it to open reopens the chat

Example request

{
  "assigned_to": "bharat@hashlabs.dev",
  "custom_properties": {
    "Custom Property 1": "hello"
  },
  "labels": "chatlabel1,chatlabel2",
  "status": "closed"
}

Response

200 OK

object required

The response is a chat object. Refer to the chat object here

Changes