Close conversation

This method is used for closing conversations.

URL

POST https://api.dashly.app/v1/conversations/{id}/close

ID of the conversation should be used as {id}.

Arguments

This method follows the general rules. Arguments are transmitted as GET or POST parameters.

Argument Description
auth_token Required. Authorization token (requires scope: conversations-write)
from_admin Specify the administrator ID if the administrator (not the bot) creates it.<!-- You can specify default_admin - default administrator
bot_name Specify the bot name who sends the replica. The default name is Bot.-->
random_id Random ConversationPart ID for sending control. Default: 0

If the conversation is already closed, the answer with 200 status will be returned.

Answer

{
  "data": {
  }
  "meta": {
    "status": 200
  }
}

Answer will be empty.

Example

<!-- Close conversation with ID=716 on behalf of the bot:

curl -X POST \
  --data-urlencode 'auth_token=XXX' \
  'https://api.dashly.app/v1/conversations/716/close'

--> Close conversation with ID=716 on behalf of the administrator with ID=912:

curl -X POST \
  --data-urlencode 'auth_token=XXX' \
  --data-urlencode 'from_admin=912' \
  'https://api.dashly.app/v1/conversations/716/close'