{"info":{"_postman_id":"52e540b6-537c-4812-b935-841f324a572c","name":"Chat2Desk Public API","description":"<html><head></head><body><p>This API is designed to send and receive messages, get clients list, apply tags, set webhooks and more.</p>\n<p>To start testing the API:</p>\n<ul>\n<li><p>Go to the System site (see <em>TERMS</em> below) under admin account and open <em>Settings &gt; API</em> section.</p>\n</li>\n<li><p>Using Postman app, copy API token to this Postman collection in <em>Variables</em> section.</p>\n</li>\n<li><p>Make sure you have a few messages from clients to test the API.</p>\n</li>\n</ul>\n<p>The footnotes indicate the changes that are planned for the next release.</p>\n<p><strong>Important!</strong> The release date can be changed.</p>\n<h2 id=\"changelog\">CHANGELOG</h2>\n<p><strong>2026-01-27</strong></p>\n<p>Added new <code>imported_message</code> event for <code>webhooks (POST)</code></p>\n<p>Added API for operators management (<code>/operators</code> <code>(POST)</code>, <code>(PUT)</code>)</p>\n<p>Added API for new custom role model (<code>/access rights</code> <code>(GET)</code> and <code>/access_rights/:id</code> <code>(GET)</code>)</p>\n<p><strong>2025-07-30</strong></p>\n<p>Added new parameter <code>force_assign</code> for the following methods <code>messages/:id/transfer</code>, <code>messages/:id/transfer_to_group</code>, <code>dialogs/:id/</code></p>\n<p><strong>2025-06-06</strong></p>\n<p>Added Webhook Signature Verification (HMAC). See Webhooks description</p>\n<p><strong>2025-05-01</strong></p>\n<p>Changes in <code>/statistics</code> response. Examples added</p>\n<p><strong>2024-09-17</strong></p>\n<p>Added new method <code>companies/info (GET)</code></p>\n<p><strong>2024-08-12</strong></p>\n<p>Added API for Tickets managment (<code>/tickets</code> <code>(GET)</code>, <code>(POST)</code>, <code>(PUT)</code>, <code>(DELETE)</code>)</p>\n<p>Added new <code>new_ticket</code>, <code>ticket_updated</code>, <code>ticket_deleted</code> events for <code>webhooks (POST)</code></p>\n<p>Added new values (<code>help/tickets (GET)</code>) for Tickets in <code>Data types and values</code></p>\n<p><strong>2024-07-03</strong></p>\n<p>Added new <code>client_added_to_blacklist</code> event for <code>webhooks (POST)</code>.</p>\n<p>Added new filter by channels for <code>webhooks (POST)</code>.</p>\n<p>Added new supported transport for <code>messages (POST)</code> with buttons and interactive type.</p>\n<p>Added <code>two_factor</code> field in <code>operators (GET)</code> response.</p>\n<p>Added <code>attachment_filename</code> parameter for <code>messages (POST)</code> to provide the original filename.</p>\n<p>Added <code>attachment</code> parameter for <code>messages/inbox (POST)</code>. We recommend using this instead of <code>image</code> or <code>video</code>.</p>\n<p>Added <code>attachment_filename</code> parameter for <code>messages/inbox (POST)</code> to provide the original filename. Note that <code>attachment</code> is required; <code>image</code> or <code>video</code> do not support <code>attachment_filename</code>.</p>\n<p><strong>2024-02-20</strong></p>\n<p>Added new events <code>operator_status_changed</code> and <code>operator_authentication_updated</code> for <code>webhooks (POST)</code>.</p>\n<p>Added new parameters <em>client_phone</em> and <em>custom_fields</em> for <code>message/inbox (POST)</code>.</p>\n<p>Added the ability to send interactive messages with type <em>list</em> in Wa dialog for <code>messages (POST)</code>.</p>\n<p>Added the ability to send interactive messages with type <em>buttons</em> in Wa dialog for <code>messages (POST)</code>.</p>\n<h5 id=\"earlier-changelog-is-not-provided\"><em>Earlier changelog is not provided.</em></h5>\n<h2 id=\"terms\">TERMS</h2>\n<p><em>System</em> — Chat2Desk service.</p>\n<p><em>Client</em> — is a person, who sends or receives messages via the System.</p>\n<p><em>Transport</em> – is a messenger, social network or online chat which is supported by the System. Such as WhatsApp, Viber, Telegram, Facebook, Instagram, VKontakte, online chat and more.</p>\n<p><em>Channel</em> — is a group of your messenger accounts. You can have many channels with different auto replies, self service menu, chat assignment etc. for each channel.</p>\n<p><em>External channel</em> — is a source of messages from any messenger (transport) not supported by the System. For example, 3rd party chat, messenger, app or CRM.</p>\n<p><em>Request</em> — is a set of messages within a dialog with a client. As a rule, request starts with first client message and finishes when the dialog is closed. When the client continues to chat in closed dialog, a new request starts in the same dialog.</p>\n<h2 id=\"general-information\">GENERAL INFORMATION</h2>\n<ul>\n<li><p>RESTful architecture and methods GET, PUT, DEL and POST are used.</p>\n</li>\n<li><p>Commands’ results are presented in JSON format.</p>\n</li>\n<li><p>This API uses HTTPS.</p>\n</li>\n<li><p>Authorization is based on API token, which is available in <em>Settings &gt; API</em> on the site under admin account.</p>\n</li>\n<li><p>Commands that return large list of data support pagination using URL parameters:</p>\n<ul>\n<li><p><em>limit</em> — number of records returned (maximum is 200, default is 20).</p>\n</li>\n<li><p><em>offset</em> — offset from the 1st record of the list (default is 0). <code>Messages (GET)</code> is an exception as it uses <em>start_id</em> instead of <em>offset</em>.Example of the request (list of clients): <code>/v1/clients?offset=50&amp;limit=30</code></p>\n</li>\n</ul>\n</li>\n<li><p>In general, the system is designed to answer those clients who first contacted your company and so are in the list of you clients (see <code>clients (GET)</code>). Using <code>clients (POST)</code> you can create a new client and then contact him or her. Contact these newly created clients reasonably because your messenger account might get <strong>blocked</strong> for spam in case of too many new contacts or messages.</p>\n</li>\n</ul>\n<h2 id=\"before-you-begin\">BEFORE YOU BEGIN</h2>\n<p>Obtain your API token on the System site in <em>Settings &gt; API</em> section. Info on the API is available with <code>api_modes (GET)</code>. Put the token to this Postman collection in <em>Variables</em> section using Postman app.</p>\n<p>There are 2 ways to work with messages:</p>\n<ul>\n<li><p>Your clients use regular messengers, social networks, emails or our online chat to send messages to your company. In this case use <code>webhooks (POST)</code> to receive these messages from the System. To send messages back to the clients use <code>messages (POST)</code>.<br>  If you want to contact a client that never contacted you before ( this is <em>Write first</em> paid option) use <code>client (POST)</code> to create a new client, get the client's id and then use <code>messages (POST)</code> to send a message as described above.</p>\n</li>\n<li><p>Your clients contact you via your own app, CRM or contact form and you need the System to let your operators (agents) and chat bots to serve the clients. You should use <em>external channel</em> to pass messages to the System from these external source of messages using <code>messages/inbox (POST)</code>. To receive operators’ and chat bots replies to send them back to your clients – use webhooks (see <code>webhooks (POST)</code>).</p>\n</li>\n</ul>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"8899980","collectionId":"52e540b6-537c-4812-b935-841f324a572c","publishedId":"UVC8BRBo","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2025-06-02T14:38:46.000Z"},"item":[{"name":"Clients","item":[{"name":"clients","id":"542073df-3443-43f5-b322-777dd475ee9e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"order\": \"desc\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/clients","description":"<p>Returns a list of your clients with their info. You can filter the list of clients by clients phone, tags, info in client's info card and more.</p>\n<p>Some fields in response:</p>\n<ul>\n<li>assigned_name – a name assigned to the client – see <code>clients (PUT)</code>.</li>\n<li>comment – commentary to client left by an operator on the site.</li>\n<li>custom_fields – JSON data of your client’s custom fields with their id, name and value. These fields are visible to operators in client’s info card. They are managed by admin in <em>Settings &gt; General</em> section on the site.</li>\n<li>phone – client’s phone number if exists. Available only for WhatsApp, Viber, Viber Business, Telegram numeric (user) and SMS. For other messengers these messenger’s respective client id is stored. Also see <em>client_phone</em> below. For Telegram numeric (user), client's phone is stored as <em>[tg_user] phone</em> like <em>[tg_user] 11122233344</em>.</li>\n<li>client_phone – client’s phone if the client revealed his/her real phone number in messengers that do not disclose it by default (currently Telegram and Facebook). Also this field can be edited by an operator manually or via <code>clients (PUT)</code>.</li>\n<li>name – client’s nickname (if available).</li>\n</ul>\n","urlObject":{"path":["v1","clients"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Client’s phone filter. For Telegram numeric (user), client's phone is stored as [tg_user] 11122233344.</p>\n","type":"text/plain"},"key":"phone","value":"918446169771"},{"disabled":true,"description":{"content":"<p>Сlient’s phone if the client revealed his/her real phone number in messengers that do not disclose it by default (currently Telegram and Facebook). Also this field can be edited by an operator manually or via clients (PUT).</p>\n","type":"text/plain"},"key":"client_phone","value":"380504312345"},{"disabled":true,"description":{"content":"<p>Client's tags filter, comma delimited. Clients with at least 1 tag from the list are returned.</p>\n","type":"text/plain"},"key":"tags","value":"103429,103430"},{"disabled":true,"description":{"content":"<p>Client custom field id to filter clients using <em>custom_field[text]</em> (see <em>custom_client_fields (GET)</em>).</p>\n","type":"text/plain"},"key":"custom_field[id]","value":"1"},{"disabled":true,"description":{"content":"<p>Text to seacrh in field id specified by <em>custom_field[id]</em>.</p>\n","type":"text/plain"},"key":"custom_field[text]","value":"California"},{"disabled":true,"description":{"content":"<p>Clients with creation date (by the first message)\nafter specified unix time are returned.</p>\n","type":"text/plain"},"key":"created_after","value":""},{"disabled":true,"description":{"content":"<p>Order of records returned (asc, desc). Default is ascending order.</p>\n","type":"text/plain"},"key":"order","value":"asc"},{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":""}],"variable":[]}},"response":[{"id":"e0147890-39d5-470f-9b10-6a35abfff7e6","name":"clients","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/clients/","host":["https://api.chat2desk.com"],"path":["v1","clients",""],"query":[{"key":"phone","value":"918446169771","description":"Client’s phone filter.","disabled":true},{"key":"tags","value":"103429,103430","description":"Client's tags filter, comma delimited. Clients with at least 1 tag from the list are returned.","disabled":true},{"key":"custom_field[id]","value":"1","description":"Client custom field id to filter clients using *custom_field[text]* (see *custom_client_fields (GET)*).","disabled":true},{"key":"custom_field[text]","value":"California","description":"Text to seacrh in field id specified by *custom_field[id]*.","disabled":true},{"key":"created_after","value":"","description":"Clients with creation date (by the first message)\nafter specified unix time are returned.","disabled":true},{"key":"order","value":"asc","description":"Order of records returned (asc, desc). Default is ascending order.","disabled":true},{"key":"limit","value":"","description":"Number of records returned (maximum is 200, default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\r\n    \"data\": [\r\n        {\r\n            \"id\": 50485,\r\n            \"name\": \"Username\",\r\n            \"avatar\": \"http://site.com/images/users/client/1112233_1.jpg\",\r\n            \"phone\": \"[id] 1\",\r\n            \"external_id\": null,\r\n            \"assigned_name\": \"New name\",\r\n            \"comment\": \"This is comment\",\r\n            \"client_phone\": 89211234567,\r\n            \"region_id\": 1495,\r\n            \"country_id\": 2,\r\n            \"client_external_id\": null,\r\n            \"external_ids\": {},\r\n            \"extra_comment_1\": null,\r\n            \"extra_comment_2\": null,\r\n            \"custom_fields\": {\r\n                \"1\": \"Field 1\",\r\n                \"2\": \"Field 2\",\r\n                \"3\": \"Field 3\"\r\n            },\r\n            \"extra_comment_3\": null\r\n        },\r\n    ...\r\n    ],\r\n    \"meta\": {\r\n        \"total\": 146,\r\n        \"limit\": 20,\r\n        \"offset\": 100\r\n    },\r\n    \"status\": \"success\"\r\n}"}],"_postman_id":"542073df-3443-43f5-b322-777dd475ee9e"},{"name":"clients/<id>","id":"0ee91384-c601-4bca-88e8-c881062355b5","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/clients/17340089/","description":"<p>Returns extended info for a specified client. 17340089 here is an example of client id.</p>\n<p>See <code>clients (GET)</code> for more info.</p>\n","urlObject":{"path":["v1","clients","17340089",""],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"3b3ec618-5ae1-4624-9c62-664cb3e6091b","name":"clients/<id>","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/clients/17340089/"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\"data\": {\r\n      \"id\": 17340089,\r\n      \"comment\": \"This is a comment\",\r\n      \"assigned_name\": \"Username\",\r\n      \"phone\": \"19001112233\",\r\n      \"name\": \"Thats my name!\",\r\n      \"avatar\": \"http://site.com/images/users/client/112233.jpg\",\r\n      \"region_id\": null,\r\n      \"country_id\": 1\r\n      \"first_client_message\": \"2015-12-27T18:36:41 UTC\",\r\n      \"last_client_message\": \"2023-01-28T20:29:25 UTC\"\r\n  },\r\n  \"status\": \"success\"}"}],"_postman_id":"0ee91384-c601-4bca-88e8-c881062355b5"},{"name":"clients/<id>/transport","id":"4ab69f1e-7d33-46c7-8f78-0f30bc3ec42a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/clients/17340089/transport","description":"<p>Returns a list of available transports for the client specified (see <a href=\"#intro\">TERMS</a> for <em>transport</em>). 17340089 here is an example of client id.</p>\n<p>See <code>clients (GET)</code> for more info.</p>\n","urlObject":{"path":["v1","clients","17340089","transport"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"ce66bade-a3f3-4b11-807d-0296fba4e1a4","name":"clients/<id>/transport","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/clients/17340089/transport"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\"data\": [\r\n    {\r\n      \"channel_id\": 1,\r\n      \"transports\": [\r\n        \"sms\",\r\n        \"whatsapp\"\r\n      ]\r\n    },\r\n    {\r\n      \"channel_id\": 2,\r\n      \"transports\": [\r\n        \"viber\"\r\n      ]\r\n    }\r\n  ],\r\n  \"status\": \"success\"}"}],"_postman_id":"4ab69f1e-7d33-46c7-8f78-0f30bc3ec42a"},{"name":"clients/<id>/dialogs","id":"0ab2dcc2-ddc7-4562-aec9-b8c15973c3b1","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/clients/17340089/dialogs","description":"<p>Returns a list of dialogs for the client specified. 17340089 here is an example of client id.</p>\n<p>See <code>clients (GET)</code> for more info.</p>\n","urlObject":{"path":["v1","clients","17340089","dialogs"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"e013de80-dfda-4e39-92a4-dced77e801e5","name":"clients/<id>/dialogs","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/clients/17340089/dialogs"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[\n    {'begin': '2019-11-13T09:52:17 UTC',\n    'end': '2023-07-26T16:22:02 UTC',\n    'id': 10389149,\n    'operator_id': 47257,\n    'state': 'closed'}\n]"}],"_postman_id":"0ab2dcc2-ddc7-4562-aec9-b8c15973c3b1"},{"name":"clients/<id>/questions","id":"96c7f6f1-f558-4778-b956-67788a601db6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/clients/17340089/questions?start_date=01-11-2021&finish_date=31-12-2021","description":"<p>Returns a list of self service menu items sent to the client specified. 17340089 here is an example of client id. See <em>Settings &gt; Self-service menu</em> section on the site.</p>\n<p>See <code>clients (GET)</code> for more info.</p>\n","urlObject":{"path":["v1","clients","17340089","questions"],"host":["https://api.chat2desk.com"],"query":[{"description":{"content":"<p>Date span</p>\n","type":"text/plain"},"key":"start_date","value":"01-11-2021"},{"description":{"content":"<p>Date span</p>\n","type":"text/plain"},"key":"finish_date","value":"31-12-2021"}],"variable":[]}},"response":[{"id":"082e9129-67f3-4888-a62c-1782a0a9cfd6","name":"clients/<id>/questions","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/clients/17340089/questions?start_date=01-11-2021&finish_date=31-12-2023","host":["https://api.chat2desk.com"],"path":["v1","clients","17340089","questions"],"query":[{"key":"start_date","value":"01-11-2021","description":"Date span"},{"key":"finish_date","value":"31-12-2023","description":"Date span"}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[{'created': '2020-03-13T12:47:14 UTC',\n  'id': 61529,\n  'image': None,\n  'text': '1'}]"}],"_postman_id":"96c7f6f1-f558-4778-b956-67788a601db6"},{"name":"clients/<id>/last_question","id":"af6ab166-35fc-488a-b623-d4a314f192d2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/clients/17340089/last_question","description":"<p>Returns the last self service menu item sent to the client specified. 17340089 here is an example of client id. See <em>Settings &gt; Self-service menu</em> section on the site.</p>\n<p>See <code>clients (GET)</code> for more info.</p>\n","urlObject":{"path":["v1","clients","17340089","last_question"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"b8895c86-4034-4ef2-91ea-fb1fc93313f2","name":"clients/<id>/last_question","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/clients/17340089/last_question"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\"data\": {\r\n    \"id\": 4322,\r\n    \"text\": \"This is menu item #20\",\r\n    \"image\": null\r\n  },\r\n  \"status\": \"success\"}"}],"_postman_id":"af6ab166-35fc-488a-b623-d4a314f192d2"},{"name":"clients/<id>","id":"67736539-ef70-4bc9-b607-6a175a6f65f2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"f3be2657b181fa51e32c24296e5397","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"ban_status\": 0\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/clients/673282519","description":"<p>Modifies info for specified client.<br />17340089 here is an example of client id.</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<ul>\n<li>nickname – client’s name (assigned name). If <em>null</em> is specified, then the name will be deleted.</li>\n<li>assigned_phone – client’s phone number (<em>client_phone</em> in <code>clients (GET)</code>. This field is informational and is NOT used when exchanging messages with messenger. It and can be edited in client card.</li>\n<li>custom fields – JSON of custom client fields ids and their values. These fields can be edited in <em>Settings &gt; General</em> section on the site. See <code>custom_client_fields (GET)</code>.</li>\n<li>external_id – client id to use in external system.</li>\n<li>external_service – external service for external client id. Allowed only <em>amo</em> and <em>bitrix</em>.</li>\n</ul>\n","urlObject":{"path":["v1","clients","673282519"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"67736539-ef70-4bc9-b607-6a175a6f65f2"},{"name":"clients","id":"7d243850-a5aa-4d0f-ae29-7759db9a95ff","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Get this token in Settings &gt; API section (under admin account).</p>\n"},{"key":"Content-Type","value":"application/json"}],"url":"https://api.chat2desk.com/v1/clients","description":"<p>Creates a new client so you can contact this client afterwards. It is possible to send messages only to a client which exists in the System. So if you need to contact a client first, the client have to be created first.</p>\n<p>Use with caution because a client that you contact first, likely, doesn't have your number in address book and can tap “This is spam!” button, which may lead your WhatsApp or Viber account to get blocked.</p>\n<p>After successful execution, the command returns an info on newly created client. Region and country are determined based on the phone number.</p>\n<p>Having received the client’s id, you can then send this client a message using <code>messages (POST)</code>.</p>\n<p>To use this command you need a <em>Write first</em> option. It is turned off by default. Contact our tech. support on the site to enable this option.</p>\n<p>If the client is already registered in the system, the <code>client_id</code> will be returned in error in response to the request (see example error Client already exists)</p>\n","urlObject":{"path":["v1","clients"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Client’s phone number with country code, without any symbols and spaces or email address if you want to contact the client via email.</p>\n","type":"text/plain"},"key":"phone","value":"499210009991"},{"disabled":true,"description":{"content":"<p>Name of a transport (messenger), via which you want to contact this client. You can create a new client only using WhatsApp, Viber, Viber Business, External, Email and SMS. To get a list of your available transports use <em>transports (GET)</em>.</p>\n","type":"text/plain"},"key":"transport","value":"whatsapp"},{"disabled":true,"description":{"content":"<p>(Optional) Id of a channel in which the client will be created. If left blank, your first channel will be used. To get a list of your channels use <em>channels (GET)</em>.</p>\n","type":"text/plain"},"key":"channel_id","value":""},{"disabled":true,"description":{"content":"<p>(Optional) Assigned name of this new client.</p>\n","type":"text/plain"},"key":"nickname","value":"John"},{"disabled":true,"description":{"content":"<p>(Optional) Client’s phone number that can stored\nadditionally in client card. This field is informational and is NOT used when exchanging messages with messenger. It and can be edited in client card. </p>\n","type":"text/plain"},"key":"assigned_phone","value":""}],"variable":[]}},"response":[{"id":"507f667e-40fb-4fbe-97e1-8c622553e618","name":"OK clients","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"","description":"Get this token in Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","disabled":true}],"body":{"mode":"raw","raw":""},"url":{"raw":"https://api.chat2desk.com/v1/clients","host":["https://api.chat2desk.com"],"path":["v1","clients"],"query":[{"key":"phone","value":"499210009991","description":"Client’s phone number with country code, without any symbols and spaces or email address if you want to contact the client via email.","disabled":true},{"key":"transport","value":"telegram","description":"Name of a transport (messenger), via which you want to contact this client. You can create a new client only using WhatsApp, Viber, Viber Business, External, Email and SMS. To get a list of your available transports use *transports (GET)*.","disabled":true},{"key":"channel_id","value":"21872","description":"(Optional) Id of a channel in which the client will be created. If left blank, your first channel will be used. To get a list of your channels use *channels (GET)*.","disabled":true},{"key":"nickname","value":"John","description":"(Optional) Assigned name of this new client.","disabled":true},{"key":"assigned_phone","value":"","description":"(Optional) Client’s phone number that can stored\nadditionally in client card. This field is informational and is NOT used when exchanging messages with messenger. It and can be edited in client card. ","type":"text","disabled":true}]}},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\r\n    \"data\": {\r\n        \"id\": 75,\r\n        \"assigned_name\": John,\r\n        \"phone\": \"499210009991\",\r\n        \"name\": null,\r\n        \"avatar\": null,\r\n        \"region_id\": null,\r\n        \"country_id\": 1,\r\n        \"first_client_message\": \"2016-07-07T05:34:28 UTC\",\r\n        \"last_client_message\": \"2016-07-07T05:34:28 UTC\"\r\n    },\r\n    \"status\": \"success\"\r\n}"},{"id":"d1d759cf-d355-46a1-ac97-e348f7b1caff","name":"error Client already exists","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Get this token in Settings > API section (under admin account)."},{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\r\n   \"phone\": \"234567\",\r\n   \"transport\":\"telegram\",\r\n   \"channel_id\": \"5432\"\r\n\r\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"https://api.chat2desk.com/v1/clients","host":["https://api.chat2desk.com"],"path":["v1","clients"],"query":[{"key":"phone","value":"499210009991","description":"Client’s phone number with country code, without any symbols and spaces or email address if you want to contact the client via email.","disabled":true},{"key":"transport","value":"whatsapp","description":"Name of a transport (messenger), via which you want to contact this client. You can create a new client only using WhatsApp, Viber, Viber Business, External, Email and SMS. To get a list of your available transports use *transports (GET)*.","disabled":true},{"key":"channel_id","value":"","description":"(Optional) Id of a channel in which the client will be created. If left blank, your first channel will be used. To get a list of your channels use *channels (GET)*.","disabled":true},{"key":"nickname","value":"John","description":"(Optional) Assigned name of this new client.","disabled":true},{"key":"assigned_phone","value":"","description":"(Optional) Client’s phone number that can stored\nadditionally in client card. This field is informational and is NOT used when exchanging messages with messenger. It and can be edited in client card. ","type":"text","disabled":true}]}},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\r\n    \"message\": \"bad_request\",\r\n    \"errors\": {\r\n        \"client\":\r\n         [\r\n            \"Client already exists\",\r\n            \"{\\\"id\\\":50485\\}\"\r\n        ]\r\n      },\r\n    \"status\": \"error\"\r\n}"}],"_postman_id":"7d243850-a5aa-4d0f-ae29-7759db9a95ff"},{"name":"custom_client_fields","id":"dc675f69-4cb4-4170-a14b-a4f7393f0b44","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/custom_client_fields","description":"<p>Returns your list of custom fields of client info card. These fields can be edited in <em>Settings &gt; General</em> section on the site.</p>\n<p>Some fields in response:</p>\n<ul>\n<li>type – <em>input</em> (free text) or <em>dropdown</em> (preset values).</li>\n<li>value – preset values for dropdown type.</li>\n<li>editable – if <em>true</em>, operators (agents) can edit this field manually in client’s info card on the site.</li>\n<li>viewable – if <em>true</em> and this field for given client is not empty, it is shown in the client’s chat header along with its current value.</li>\n</ul>\n","urlObject":{"path":["v1","custom_client_fields"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"601e1e02-d73a-4e90-8c6f-eb6bf6189d8a","name":"custom_client_fields","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/custom_client_fields"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[{'editable': True,\n  'id': 1,\n  'name': '123',\n  'type': 'input',\n  'value': '',\n\t'viewable': True},\n\t{'editable': True,\n\t'id': 2,\n\t'name': '456',\n\t'type': 'input',\n\t'value': '',\n\t'viewable': True},\n\t{'editable': True,\n\t'id': 3,\n\t'name': 'uniqueCompanyId',\n\t'type': 'input',\n\t'value': '',\n\t'viewable': True}]"}],"_postman_id":"dc675f69-4cb4-4170-a14b-a4f7393f0b44"}],"id":"92271ce1-eb82-4a28-adac-0ec38e2324e2","description":"<p>Working with clients.</p>\n","_postman_id":"92271ce1-eb82-4a28-adac-0ec38e2324e2"},{"name":"Messages & requests","item":[{"name":"messages","id":"eab4cc5c-f448-4ae0-807a-406b25df0930","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/messages/","description":"<p>Returns a list of accumulated messages (both from and to clients as well as system messages). Where supported, delivery and read status also returned.</p>\n<p>When this command is used without message id it returns a list of all messages. When message id is specified, the command returns extended info about specified message, including dialog_id, operator_id and channel_id.</p>\n<p><strong>Important!</strong> Do not use this command too often with high number of records to receive (<em>limit</em> parameter). You will hit API requests limit very soon. Use webhooks instead (see <code>web_hook (POST)</code>).</p>\n<p>Pay attention, that for this <code>messages (GET)</code> command <em>start_id</em> parameter replaces <em>offset</em> parameter to reduce server load.</p>\n<p>Some fields in response:</p>\n<ul>\n<li><p>coordinates – geo coordinates.</p>\n</li>\n<li><p>type:</p>\n<ul>\n<li><p>from_client – a message from client.</p>\n</li>\n<li><p>to_client – a message to client.</p>\n</li>\n<li><p>system – system message (like “Chat was transferred…”). Such message is not sent to a client.</p>\n</li>\n<li><p>autoreply – autoanswer to a client or menu message.</p>\n</li>\n</ul>\n</li>\n<li><p>read – status read or not by an operator.</p>\n</li>\n<li><p>created – date of message creation (UTC).</p>\n</li>\n<li><p>recipient_status – info about delivery status of the message (where supported).</p>\n</li>\n<li><p>attachments – array of attachments in the message with name and link of each attachment. For backward compatibility some attachment types are additionally returned in separate fields like photo, video and audio.</p>\n</li>\n<li><p>insta_comment – <em>true</em> for Instagram comment message.</p>\n</li>\n<li><p>extra data – may contain:</p>\n<ul>\n<li><p>external id passed using <code>messages/inbox (POST)</code>).</p>\n</li>\n<li><p>post_url - link to a post for Instagram comment message.</p>\n</li>\n</ul>\n</li>\n</ul>\n","urlObject":{"path":["v1","messages",""],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Order of records returned (asc or desc). Default is ascending order.</p>\n","type":"text/plain"},"key":"order","value":"desc"},{"disabled":true,"description":{"content":"<p>Transport filter.</p>\n","type":"text/plain"},"key":"transport","value":"whatsapp"},{"disabled":true,"description":{"content":"<p>Channel id.</p>\n","type":"text/plain"},"key":"channel_id","value":""},{"disabled":true,"description":{"content":"<p>Client's id.</p>\n","type":"text/plain"},"key":"client_id","value":"17340089"},{"disabled":true,"description":{"content":"<p>Supprorted types: to_client, from_client, autoreply, system.</p>\n","type":"text/plain"},"key":"type","value":""},{"disabled":true,"description":{"content":"<p>Operator's id.</p>\n","type":"text/plain"},"key":"operator_id","value":""},{"disabled":true,"description":{"content":"<p>Timespan start date. The parameter is mutually exclusive with the start_id parameter. If the start_id parameter is specified, the use of the parameters start_date and finish_date is not allowed.</p>\n","type":"text/plain"},"key":"start_date","value":""},{"disabled":true,"description":{"content":"<p>Timespan finish date. The parameter is mutually exclusive with the start_id parameter. If the start_id parameter is specified, the use of the parameters start_date and finish_date is not allowed.</p>\n","type":"text/plain"},"key":"finish_date","value":""},{"disabled":true,"key":"dialog_id","value":"18498876"},{"disabled":true,"description":{"content":"<p>(instead of <em>offset</em> pararmeter) starting message id (messages with id⩾start_id). The parameter is mutually exclusive with the start_date and finish_date parameters. If the start_date and finish_date parameters are specified, the use of the parameters start_id is not allowed.</p>\n","type":"text/plain"},"key":"start_id","value":""},{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>The enabled parameter sorts messages by start_id in reverse order, from later to earlier.</p>\n","type":"text/plain"},"key":"direction_reverse","value":"true"}],"variable":[]}},"response":[{"id":"cc43aac4-e1a2-4b51-98a8-da32cd9cf9e7","name":"messages","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/messages/","host":["https://api.chat2desk.com"],"path":["v1","messages",""],"query":[{"key":"order","value":"desc","description":"Order of records returned (asc or desc). Default is ascending order.","disabled":true},{"key":"transport","value":"whatsapp","description":"Transport filter.","disabled":true},{"key":"channel_id","value":"","description":"Channel id.","disabled":true},{"key":"client_id","value":"17340089","description":"Client's id.","disabled":true},{"key":"type","value":"","description":"Supprorted types: to_client, from_client, autoreply, system.","disabled":true},{"key":"operator_id","value":"","description":"Operator's id.","disabled":true},{"key":"start_date","value":"","description":"Timespan start date. The parameter is mutually exclusive with the start_id parameter. If the start_id parameter is specified, the use of the parameters start_date and finish_date is not allowed.","disabled":true},{"key":"finish_date","value":"","description":"Timespan finish date. The parameter is mutually exclusive with the start_id parameter. If the start_id parameter is specified, the use of the parameters start_date and finish_date is not allowed.","disabled":true},{"key":"dialog_id","value":"18498876","disabled":true},{"key":"start_id","value":"","description":"(instead of *offset* pararmeter) starting message id (messages with id⩾start_id). The parameter is mutually exclusive with the start_date and finish_date parameters. If the start_date and finish_date parameters are specified, the use of the parameters start_id is not allowed.","disabled":true},{"key":"limit","value":"","description":"Number of records returned (maximum is 200, default is 20).","type":"text","disabled":true},{"key":"direction_reverse","value":"true","description":"The enabled parameter sorts messages by start_id in reverse order, from earlier to later.","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[{'ai_tips': None,\n  'attachments': [],\n  'audio': None,\n  'channel_id': 21085,\n  'client_id': 4659188,\n  'coordinates': None,\n  'created': '2023-11-13T09:52:17 UTC',\n  'dialog_id': 10389149,\n  'extra_data': {},\n  'id': 274002417,\n  'is_new': 0,\n  'operator_id': 47257,\n  'pdf': None,\n  'photo': None,\n  'read': 1,\n  'recipient_status': None,\n  'remote_id': None,\n  'request_id': 30875600,\n  'text': '111',\n  'transport': 'telegram',\n  'type': 'from_client',\n  'video': None}]"}],"_postman_id":"eab4cc5c-f448-4ae0-807a-406b25df0930"},{"name":"messages/<id>","id":"e010f279-c876-4bd6-8535-bb7cffdc4d57","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/messages/1312913968","description":"<p>Returns an info on specified message id. 1 here is an example of message id. Where supported, delivery and read status is returned.</p>\n<p>See <code>messages (GET)</code> for more info.</p>\n","urlObject":{"path":["v1","messages","1312913968"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"f20da232-2e13-4f89-9f11-244ba32be219","name":"messages/<id>","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/messages/1312913968"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{'ai_tips': None,\n 'attachments': [],\n 'audio': None,\n 'channel_id': 21085,\n 'client_id': 4659188,\n 'coordinates': None,\n 'created': '2019-11-13T09:52:17 UTC',\n 'dialog_id': 10389149,\n 'extra_data': {},\n 'id': 274002417,\n 'operator_id': 47257,\n 'pdf': None,\n 'photo': None,\n 'read': 1,\n 'recipient_status': None,\n 'remote_id': None,\n 'request_id': 30875600,\n 'text': '111',\n 'transport': 'telegram',\n 'type': 'from_client',\n 'video': None}"}],"_postman_id":"e010f279-c876-4bd6-8535-bb7cffdc4d57"},{"name":"messages/<id>/transfer","id":"6a607f90-21f8-4b66-ace2-8ce62092955c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":""},"url":"https://api.chat2desk.com/v1/messages/1/transfer?operator_id=100","description":"<p>Assigns a dialog to which the specified message belongs to an operator specified. 1 here is an example of message id.</p>\n","urlObject":{"path":["v1","messages","1","transfer"],"host":["https://api.chat2desk.com"],"query":[{"description":{"content":"<p>Id of an operator (agent), on whom this message and corresponding dialog will be assigned. See <em>operators (GET)</em>.</p>\n","type":"text/plain"},"key":"operator_id","value":"100"},{"disabled":true,"description":{"content":"<p>Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.</p>\n","type":"text/plain"},"key":"force_assign","value":"{true, false}"}],"variable":[]}},"response":[{"id":"05ab4925-56ae-40f5-8188-a178fca22695","name":"OK transfer","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":""},"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer?operator_id=100","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer"],"query":[{"key":"operator_id","value":"100","description":"Id of an operator (agent), on whom this message and corresponding dialog will be assigned. See *operators (GET)*."},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"data\": [],\r\n    \"status\": \"success\"\r\n}"},{"id":"c6f25ea6-d2e4-4446-abbc-2c286526c44f","name":"error Could not transfer to operator","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":""},"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer?operator_id=100","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer"],"query":[{"key":"operator_id","value":"100","description":"Id of an operator (agent), on whom this message and corresponding dialog will be assigned. See *operators (GET)*."},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"message\": \"bad_request\",\r\n    \"errors\": [\r\n        {\r\n            \"text\": \"Could not transfer to operator 100.\",\r\n            \"error\": \"not_found\"\r\n        }\r\n    ],\r\n    \"status\": \"error\"\r\n}"},{"id":"ee537374-2544-4b18-b6c9-8d1efb3e8014","name":"error Operator not found","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":""},"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer?operator_id=100","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer"],"query":[{"key":"operator_id","value":"100","description":"Id of an operator (agent), on whom this message and corresponding dialog will be assigned. See *operators (GET)*."},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"message\": \"bad_request\",\r\n    \"errors\": {\r\n        \"operator_id\": [\r\n            {\r\n                \"text\": \"Operator 100 not found.\",\r\n                \"error\": \"not_found\"\r\n            }\r\n        ]\r\n    },\r\n    \"status\": \"error\"\r\n}"},{"id":"35c2eecd-042f-4cbe-9bb9-b2c19c89c4f8","name":"error Parameter is required","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":""},"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer"],"query":[{"key":"operator_id","value":"100","description":"Id of an operator (agent), on whom this message and corresponding dialog will be assigned. See *operators (GET)*.","disabled":true},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"message\": \"bad_request\",\r\n    \"errors\": {\r\n        \"operator_id\": [\r\n            {\r\n                \"text\": \"Parameter is required.\",\r\n                \"error\": \"missing_parameter\"\r\n            }\r\n        ]\r\n    },\r\n    \"status\": \"error\"\r\n}"},{"id":"6888f221-c899-49cd-9984-3a396fadac11","name":"error Message not found","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":""},"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer?operator_id=100","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer"],"query":[{"key":"operator_id","value":"100","description":"Id of an operator (agent), on whom this message and corresponding dialog will be assigned. See *operators (GET)*."},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"Not Found","code":404,"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\r\n    \"message\": \"not_found\",\r\n    \"errors\": \"Message #1 not found\",\r\n    \"status\": \"error\"\r\n}"}],"_postman_id":"6a607f90-21f8-4b66-ace2-8ce62092955c"},{"name":"messages/<id>/read","id":"5f0372df-04dd-42d3-ba94-8cc0146a5f30","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/messages/1312913968/unread","description":"<p>Marks a message as read by operator (agent).\n1312913968 here is an example of message id.</p>\n<p>Note, that when a message gets answered, the message and the whole dialog are marked as read automatically.</p>\n","urlObject":{"path":["v1","messages","1312913968","unread"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"5f0372df-04dd-42d3-ba94-8cc0146a5f30"},{"name":"messages/<id>/unread","id":"2a84e3d5-d0bd-408a-ac71-2c8de9e2242b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/messages/1312913968/unread","description":"<p>Marks a message as unread by operator (agent). 1312913968 here is an example of message id.</p>\n<p>Note, that when a message gets answered, the message and the whole dialog are marked as read automatically.</p>\n","urlObject":{"path":["v1","messages","1312913968","unread"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"2a84e3d5-d0bd-408a-ac71-2c8de9e2242b"},{"name":"messages","id":"56879bbe-3d69-4c64-9f23-07c10971723d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"Button\": \n    {\n        \"text\": \"Label\",\n        \"type\": \"reply\",\n        \"payload\": \"My payload\",\n        \"color\": \"red\",\n        \"url\": \"http://site.com\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/messages","description":"<p>Sends a message, including buttons, to a client. You can refer a client only by his/her client id. So, this client should exist in clients’ list. Otherwise, use <code>clients (POST)</code> to create a new client.<br />17340089 here is an example of client id.</p>\n<p><strong>Important!</strong> Rate limit is apllied to sending messages using this command. The rate is around 15-20 messages per second (may vary). In case of too many messages an error will be returned: <em>429 Too many requests</em>.</p>\n<h6 id=\"sending-buttons\">Sending buttons</h6>\n<p>When sending buttons (see <em>inline_buttons</em> and <em>keyboard</em> parameters), these parameters supported by messengers:</p>\n<ul>\n<li><p>reply – VK, Viber Public, Facebook, Telegram, Online chat, Instagram.</p>\n</li>\n<li><p>phone – Telegram, Facebook, Viber Public.</p>\n</li>\n<li><p>email – Facebook.</p>\n</li>\n<li><p>location – Telegram, Facebook.</p>\n</li>\n<li><p>url – Viber Public, Online chat.</p>\n</li>\n<li><p>payload – Viber Public, Facebook, VK, Online chat.</p>\n</li>\n<li><p>color – Viber Public, VK.</p>\n</li>\n</ul>\n<p>Inline-buttons support:</p>\n<ul>\n<li><p>url – Viber Public, Facebook, Telegram</p>\n</li>\n<li><p>reply – Viber Public, Facebook, Telegram, Wa_dialog, Wa_gupshup, Wa_direct.</p>\n</li>\n<li><p>location, phone, email – none</p>\n</li>\n</ul>\n<p>We recommend keeping buttons text 38 characters maximum (19 for cyrillic characters). Otherwise the message with buttons might not be sent.</p>\n<p>List messages (interactive) support:</p>\n<ul>\n<li><p>Wa_dialog</p>\n</li>\n<li><p>Wa_gupshup</p>\n</li>\n<li><p>Wa_direct</p>\n</li>\n</ul>\n","urlObject":{"path":["v1","messages"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Message text (required if there’s no attachment).</p>\n","type":"text/plain"},"key":"text","value":"Hello, developer (with buttons)"},{"disabled":true,"description":{"content":"<p>Direct URL for an attachment (photo, audio, PDF, etc.). Not all attachment file types are supported by all messengers.</p>\n","type":"text/plain"},"key":"attachment","value":"https://upload.wikimedia.org/wikipedia/commons/thumb/9/97/The_Earth_seen_from_Apollo_17.jpg/1280px-The_Earth_seen_from_Apollo_17.jpg"},{"disabled":true,"description":{"content":"<p>Original filename for attachment. Attachment (link) required. If ommited we'll try to get it from link</p>\n","type":"text/plain"},"key":"attachment_filename","value":"PDF Example.PDF"},{"disabled":true,"description":{"content":"<ul>\n<li>to_client – message to a client (by default).</li>\n<li>autoreply – auto message to a client (like menu reply).</li>\n<li>system – system message (is not sent to the client).</li>\n<li>comment – internal text comment (is not sent to the client).\nSending coordinates to a client is not supported.</li>\n</ul>\n","type":"text/plain"},"key":"type","value":""},{"disabled":true,"description":{"content":"<p>Id of a client to whom message will be sent</p>\n","type":"text/plain"},"key":"client_id","value":"17340089"},{"disabled":true,"description":{"content":"<p>See <em>channels (GET)</em>. If omitted, channel of last message from the client will be used.</p>\n","type":"text/plain"},"key":"channel_id","value":""},{"disabled":true,"description":{"content":"<p>Id of the operator on whose behalf the message will be sent. \nIf the dialog is assigned to another operator, then when sending the current request, the chat will not be reassigned, and the message will be sent from the operator specified in the parameter.\nTo reassign the dialog to another operator, use the (PUT) dialogs request.</p>\n","type":"text/plain"},"key":"operator_id","value":""},{"disabled":true,"description":{"content":"<ul>\n<li>telegram</li>\n<li>tg_user</li>\n<li>whatsapp</li>\n<li>wa_dialog</li>\n<li>wa_gupshup</li>\n<li>wa_direct</li>\n<li>wa_infobip</li>\n<li>wa_cm</li>\n<li>widget (online chat)</li>\n<li>external</li>\n<li>facebook</li>\n<li>vk</li>\n<li>ok</li>\n<li>email</li>\n<li>max_bot</li>\n<li>viber</li>\n<li>viber_public</li>\n<li>viber_business</li>\n<li>tamtam and more – see <em>transports (GET)</em> for full list.\nIf omitted, transport of last message from the client will be used.</li>\n</ul>\n","type":"text/plain"},"key":"transport","value":""},{"disabled":true,"description":{"content":"<p>The status of the dialog.\nThe dialog can be open (the value = true) or closed (value = false). By default the value = true.</p>\n<p>NB: If the dialog is closed and the current request is sent with the value true, the dialog will switch to the open status.</p>\n","type":"text/plain"},"key":"open_dialog","value":"{true, false}"},{"disabled":true,"description":{"content":"<p>If you send message using an integration with another platform or CRM system, you can store id of the message in the external system in this field.</p>\n","type":"text/plain"},"key":"external_id","value":""},{"disabled":true,"description":{"content":"<p>Send the message in encrypted format or not. By default - false. The message looks encrypted everywhere inside the System but anyway is sent to a client in normal nonencrypted format.</p>\n","type":"text/plain"},"key":"encrypted","value":"{true, false}"},{"disabled":true,"description":{"content":"<p>Id of a message to quote when sending this message (in reply to). The text of the message will look like this:\n«Initial message text»\n— Message text</p>\n","type":"text/plain"},"key":"reply_message_id","value":"1312926701"},{"disabled":true,"description":{"content":"<p>Button array may contain:\n\"Button\": {</p>\n<ul>\n<li>\"type\": \"reply\" // or \"location\" or \"phone\" or \"email\" or</li>\n<li>\"url\"</li>\n<li>\"text\": \"Label\" // button label</li>\n<li>\"payload\": \"My payload\" // what the button really sends\n(only for \"text\" type)</li>\n<li>\"color\": \"red\" // or \"green\" or \"blue\" or \"yellow\" (online\nchat only)</li>\n<li>\"url\": \"http://...\" // button’s URL (only for \"url\" type)\n}\nInline-buttons support:</li>\n</ul>\n<p>url – Viber Public, Facebook, Telegram\nreply – Viber Public, Facebook, Telegram\nlocation, phone, email – none</p>\n","type":"text/plain"},"key":"inline_buttons","value":"Button[]"},{"disabled":true,"description":{"content":"<p>Example: {\"keyboard\": {\"buttons\": [{\"type\":\"url\", \"text\": \"Site\nbutton\", \"color\": \"blue\",\"url\": \"<a href=\"https://www.google.com%22%7D%5D%7D%7D\">https://www.google.com\"}]}}</a></p>\n","type":"text/plain"},"key":"keyboard","value":"Button: {type:reply;text:A button}"},{"disabled":true,"description":{"content":"<p>An array with interactive message parameters for the \"list\" and \"button\" types. Only for wa_dialog.</p>\n","type":"text/plain"},"key":"interactive","value":""}],"variable":[]}},"response":[{"id":"005e67f3-10b3-4cfb-8777-4916972d53a8","name":"message with keyboard","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","disabled":true}],"body":{"mode":"raw","raw":"{\n    \"keyboard\": {\n        \"buttons\": [\n            {\n                \"type\": \"reply\",\n                \"text\": \"Site button\",\n                \"color\": \"blue\"\n            },\n            {\n                \"type\": \"url\",\n                \"text\": \"Link\",\n                \"color\": \"blue\",\n                \"url\": \"https://www.google.com\"\n            }\n        ]\n    }\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"https://api.chat2desk.com/v1/messages?text=Hello, developer (with buttons)&client_id=17340089","host":["https://api.chat2desk.com"],"path":["v1","messages"],"query":[{"key":"text","value":"Hello, developer (with buttons)","description":"Message text (required if there’s no attachment)."},{"key":"attachment","value":"https://upload.wikimedia.org/wikipedia/commons/thumb/9/97/The_Earth_seen_from_Apollo_17.jpg/1280px-The_Earth_seen_from_Apollo_17.jpg","description":"Direct URL for an attachment (photo, audio, PDF, etc.). Not all attachment file types are supported by all messengers. Note, that you can send audio inside internal comments (type = comment).","disabled":true},{"key":"type","value":"","description":"* to_client – message to a client (by default).\n* autoreply – auto message to a client (like menu reply).\n* system – system message (is not sent to the client).\n* comment – internal text comment (is not sent to the client).\nSending coordinates to a client is not supported.","disabled":true},{"key":"transport","value":"","description":"* whatsapp\n* wa_cm\n* wa_infobip\n* viber\n* viber_public\n* viber_business\n* widget (online chat)\n* facebook\n* vk\n* telegram\n* email\n* wa_dialog\n* tg_user\n* sms and more – see *transports (GET)* for full list.\nIf omitted, transport of last message from the client will be used.","disabled":true},{"key":"channel_id","value":"","description":"See *channels (GET)*. If omitted, channel of last message from the client will be used.","disabled":true},{"key":"operator_id","value":"","description":"Id of the operator on whose behalf the message will be sent. \nIf the dialog is assigned to another operator, then when sending the current request, the chat will not be reassigned, and the message will be sent from the operator specified in the parameter.\nTo reassign the dialog to another operator, use the (PUT) dialogs request.","disabled":true},{"key":"open_dialog","value":"{true, false}","description":"The status of the dialog.\nThe dialog can be open (the value = true) or closed (value = false). By default the value = true.\n\nNB: If the dialog is closed and the current request is sent with the value true, the dialog will switch to the open status.","disabled":true},{"key":"external_id","value":"","description":"If you send message using an integration with another platform or CRM system, you can store id of the message in the external system in this field.","disabled":true},{"key":"encrypted","value":"{true, false}","description":"Send the message in encrypted format or not. By default - false. The message looks encrypted everywhere inside the System but anyway is sent to a client in normal nonencrypted format.","disabled":true},{"key":"reply_message_id","value":"1312926701","description":"Id of a message to quote when sending this message (in reply to). The text of the message will look like this:\n«Initial message text»\n— Message text","disabled":true},{"key":"inline_buttons","value":"Button[]","description":"Button array may contain:\n\"Button\": {\n* \"type\": \"reply\" // or \"location\" or \"phone\" or \"email\" or\n* \"url\"\n* \"text\": \"Label\" // button label\n* \"payload\": \"My payload\" // what the button really sends\n(only for \"text\" type)\n* \"color\": \"red\" // or \"green\" or \"blue\" or \"yellow\" (online\nchat only)\n* \"url\": \"http://...\" // button’s URL (only for \"url\" type)\n}\nInline-buttons support:\n\nurl – Viber Public, Facebook, Telegram\nreply – Viber Public, Facebook, Telegram\nlocation, phone, email – none","disabled":true},{"key":"keyboard","value":"Button: {type:reply;text:A button}","description":"Example: {\"keyboard\": {\"buttons\": [{\"type\":\"url\", \"text\": \"Site\nbutton\", \"color\": \"blue\",\"url\": \"https://www.google.com\"}]}}","disabled":true},{"key":"client_id","value":"17340089"},{"key":"interactive","value":null,"description":"An array with interactive message parameters for the \"list\" type. Only for wa_dialog.","type":"text","disabled":true}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null},{"id":"c65a2319-35bd-42ab-a34e-9da97e4edc09","name":"message with inline buttons","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","disabled":true}],"body":{"mode":"raw","raw":"{\n    \"inline buttons\": [\n        {\n            \"text\": \"Label\",\n            \"type\": \"reply\",\n            \"payload\": \"My payload\"\n        },\n        {\n            \"text\": \"Label 2\",\n            \"type\": \"url\",\n            \"payload\": \"My payload 2\",\n            \"url\": \"http://site.com\"\n        }\n    ]\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"https://api.chat2desk.com/v1/messages?text=Hello, developer (with buttons)&client_id=17340089","host":["https://api.chat2desk.com"],"path":["v1","messages"],"query":[{"key":"text","value":"Hello, developer (with buttons)","description":"Message text (required if there’s no attachment)."},{"key":"attachment","value":"https://upload.wikimedia.org/wikipedia/commons/thumb/9/97/The_Earth_seen_from_Apollo_17.jpg/1280px-The_Earth_seen_from_Apollo_17.jpg","description":"Direct URL for an attachment (photo, audio, PDF, etc.). Not all attachment file types are supported by all messengers. Note, that you can send audio inside internal comments (type = comment).","disabled":true},{"key":"type","value":"","description":"* to_client – message to a client (by default).\n* autoreply – auto message to a client (like menu reply).\n* system – system message (is not sent to the client).\n* comment – internal text comment (is not sent to the client).\nSending coordinates to a client is not supported.","disabled":true},{"key":"transport","value":"","description":"* whatsapp\n* wa_cm\n* wa_infobip\n* viber\n* viber_public\n* viber_business\n* widget (online chat)\n* facebook\n* vk\n* telegram\n* email\n* wa_dialog\n* tg_user\n* sms and more – see *transports (GET)* for full list.\nIf omitted, transport of last message from the client will be used.","disabled":true},{"key":"channel_id","value":"","description":"See *channels (GET)*. If omitted, channel of last message from the client will be used.","disabled":true},{"key":"operator_id","value":"","description":"Id of the operator on whose behalf the message will be sent. \nIf the dialog is assigned to another operator, then when sending the current request, the chat will not be reassigned, and the message will be sent from the operator specified in the parameter.\nTo reassign the dialog to another operator, use the (PUT) dialogs request.","disabled":true},{"key":"open_dialog","value":"{true, false}","description":"The status of the dialog.\nThe dialog can be open (the value = true) or closed (value = false). By default the value = true.\n\nNB: If the dialog is closed and the current request is sent with the value true, the dialog will switch to the open status.","disabled":true},{"key":"external_id","value":"","description":"If you send message using an integration with another platform or CRM system, you can store id of the message in the external system in this field.","disabled":true},{"key":"encrypted","value":"{true, false}","description":"Send the message in encrypted format or not. By default - false. The message looks encrypted everywhere inside the System but anyway is sent to a client in normal nonencrypted format.","disabled":true},{"key":"reply_message_id","value":"1312926701","description":"Id of a message to quote when sending this message (in reply to). The text of the message will look like this:\n«Initial message text»\n— Message text","disabled":true},{"key":"inline_buttons","value":"Button[]","description":"Button array may contain:\n\"Button\": {\n* \"type\": \"reply\" // or \"location\" or \"phone\" or \"email\" or\n* \"url\"\n* \"text\": \"Label\" // button label\n* \"payload\": \"My payload\" // what the button really sends\n(only for \"text\" type)\n* \"color\": \"red\" // or \"green\" or \"blue\" or \"yellow\" (online\nchat only)\n* \"url\": \"http://...\" // button’s URL (only for \"url\" type)\n}\nInline-buttons support:\n\nurl – Viber Public, Facebook, Telegram\nreply – Viber Public, Facebook, Telegram\nlocation, phone, email – none","disabled":true},{"key":"keyboard","value":"Button: {type:reply;text:A button}","description":"Example: {\"keyboard\": {\"buttons\": [{\"type\":\"url\", \"text\": \"Site\nbutton\", \"color\": \"blue\",\"url\": \"https://www.google.com\"}]}}","disabled":true},{"key":"client_id","value":"17340089"},{"key":"interactive","value":null,"description":"An array with interactive message parameters for the \"list\" type. Only for wa_dialog.","type":"text","disabled":true}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null},{"id":"5173364e-c410-464a-840f-b53d0d010bf2","name":"list message","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","disabled":true}],"body":{"mode":"raw","raw":"{\n    \"interactive\": {\n        \"type\": \"list\",\n        \"header\": {\n            \"type\": \"text\",\n            \"text\": \"your-header-content\"\n        },\n        \"body\": {\n            \"text\": \"text of list\"\n        },\n        \"footer\": {\n            \"text\": \"your-footer-content\"\n        },\n        \"action\": {\n            \"button\": \"text of menu\",\n            \"sections\": [\n                {\n                    \"title\": \"text\",\n                    \"rows\": [\n                        {\n                            \"id\": \"1\",\n                            \"title\": \"name of the button\",\n                            \"description\": \"button's description\"\n                        }\n                    ]\n                }\n            ]\n        }\n    }\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"https://api.chat2desk.com/v1/messages?text=Hello, developer (with buttons)&client_id=17340089","host":["https://api.chat2desk.com"],"path":["v1","messages"],"query":[{"key":"text","value":"Hello, developer (with buttons)","description":"Message text (required if there’s no attachment)."},{"key":"attachment","value":"https://upload.wikimedia.org/wikipedia/commons/thumb/9/97/The_Earth_seen_from_Apollo_17.jpg/1280px-The_Earth_seen_from_Apollo_17.jpg","description":"Direct URL for an attachment (photo, audio, PDF, etc.). Not all attachment file types are supported by all messengers. Note, that you can send audio inside internal comments (type = comment).","disabled":true},{"key":"type","value":"","description":"* to_client – message to a client (by default).\n* autoreply – auto message to a client (like menu reply).\n* system – system message (is not sent to the client).\n* comment – internal text comment (is not sent to the client).\nSending coordinates to a client is not supported.","disabled":true},{"key":"transport","value":"","description":"* whatsapp\n* wa_cm\n* wa_infobip\n* viber\n* viber_public\n* viber_business\n* widget (online chat)\n* facebook\n* vk\n* telegram\n* email\n* wa_dialog\n* tg_user\n* sms and more – see *transports (GET)* for full list.\nIf omitted, transport of last message from the client will be used.","disabled":true},{"key":"channel_id","value":"","description":"See *channels (GET)*. If omitted, channel of last message from the client will be used.","disabled":true},{"key":"operator_id","value":"","description":"Id of the operator on whose behalf the message will be sent. \nIf the dialog is assigned to another operator, then when sending the current request, the chat will not be reassigned, and the message will be sent from the operator specified in the parameter.\n\nTo reassign the dialog to another operator, use the (PUT) dialogs request.","disabled":true},{"key":"open_dialog","value":"{true, false}","description":"The status of the dialog. \nThe dialog can be open (the value = true) or closed (value = false). By default the value = true.\n\nNB: If the dialog is closed and the current request is sent with the value true, the dialog will switch to the open status.","disabled":true},{"key":"external_id","value":"","description":"If you send message using an integration with another platform or CRM system, you can store id of the message in the external system in this field.","disabled":true},{"key":"encrypted","value":"{true, false}","description":"Send the message in encrypted format or not. By default - false. The message looks encrypted everywhere inside the System but anyway is sent to a client in normal nonencrypted format.","disabled":true},{"key":"reply_message_id","value":"1312926701","description":"Id of a message to quote when sending this message (in reply to). The text of the message will look like this:\n«Initial message text»\n— Message text","disabled":true},{"key":"inline_buttons","value":"Button[]","description":"Button array may contain:\n\"Button\": {\n* \"type\": \"reply\" // or \"location\" or \"phone\" or \"email\" or\n* \"url\"\n* \"text\": \"Label\" // button label\n* \"payload\": \"My payload\" // what the button really sends\n(only for \"text\" type)\n* \"color\": \"red\" // or \"green\" or \"blue\" or \"yellow\" (online\nchat only)\n* \"url\": \"http://...\" // button’s URL (only for \"url\" type)\n}\nInline-buttons support:\n\nurl – Viber Public, Facebook, Telegram\nreply – Viber Public, Facebook, Telegram\nlocation, phone, email – none","disabled":true},{"key":"keyboard","value":"Button: {type:reply;text:A button}","description":"Example: {\"keyboard\": {\"buttons\": [{\"type\":\"url\", \"text\": \"Site\nbutton\", \"color\": \"blue\",\"url\": \"https://www.google.com\"}]}}","disabled":true},{"key":"client_id","value":"17340089"}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null}],"_postman_id":"56879bbe-3d69-4c64-9f23-07c10971723d"},{"name":"messages/inbox","id":"78bea85f-14a2-47ec-8489-02926b589296","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\r\n    \"channel_id\": \"1\",\r\n    \"body\": \"This is message text\",\r\n    \"attachment\": \"https://pdfobject.com/pdf/sample.pdf\",\r\n    \"attachment_filename\": \"PDF Example.PDF\",\r\n    \"location\": \"lat lng\",\r\n    \"extra_data\": {\r\n        \"external_id\": \"111111\"\r\n    },\r\n    \"from_client\": {\r\n        \"id\": \"123abc\" or \"phone\": 19110001122,\r\n        \"avatar\": \"direct url\",\r\n        \"nickname\": \"API_boy\",\r\n        \"client_phone\": 7800808080,\r\n        \"custom_fields\": {\r\n            \"1\": \"Text 1\",\r\n            \"2\": \"Text 2\",\r\n            \"3\": \"Text 3\"\r\n        }\r\n    }\r\n}\r\n\r\n/*\r\n    \"channel_id\" - id of the channel.\r\n    \"body\" - message text.\r\n    \"attachment\" - (optional) direct URL for an attachment\r\n    \"attachment_filename\" - (optional, attachment required). If ommited we'll try to get it from link\r\n    \"attachment_filename\": \"PDF Example.PDF\",\r\n    \"image\" - (optional, not supported) url to image. Only one of these two parameters is accepted: \"image\" or \"video\".\r\n    \"video\" - (optional, not supported) url to video. \r\n    \"location\"- (optional) link to the location.\r\n    \"external_id\"-(optional) your id of the message. This id will be sent you back using inbox web hook event.\r\n                  This id is also available via messages (GET).\r\n    \"id\"- id as you identify a client (any symbols), except phone number. If you identify a client with phone number, \r\n          then use the phone parameter.\r\n    \"phone\"- client’s phone number. Only digits are allowed.\r\n    \"avatar\" - (optional) client’s avatar (url to a picture) to display in Chats section.\r\n    \"nickname\" - (optional) client’s name. Works only if nickname is empty. To change existing client's name use PUT Clients\r\n    \"client_phone\" - (optional) customer's phone number.\r\n    \"custom_fields\" -(optional) an array that includes the unique identifiers of the Client's custom fields and their values.\r\n*/","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/messages/inbox","description":"<p>Sends incoming message from client to the System using external channel.</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"channel_id\": \"1\",\n    \"body\": \"This is message text\",\n    \"attachment\": \"https://pdfobject.com/pdf/sample.pdf\",\n    \"attachment_filename\": \"PDF Example.PDF\",\n    \"location\": \"lat lng\",\n    \"extra_data\": {\n        \"external_id\": \"111111\"\n    },\n    \"from_client\": {\n        \"id\": \"123abc\" or \"phone\": 19110001122,\n        \"avatar\": \"direct url\",\n        \"nickname\": \"API_boy\",\n        \"client_phone\": 7800808080,\n        \"custom_fields\": {\n            \"1\": \"Text 1\",\n            \"2\": \"Text 2\",\n            \"3\": \"Text 3\"\n        }\n    }\n}\n\n</code></pre>\n<ul>\n<li><p>external_id – (optional) your id of the message. This id will be sent you back using inbox webhook event. This id is also available via <code>messages (GET)</code>.</p>\n</li>\n<li><p>id – id as you identify a client (any symbols), except phone number. If you identify a client with phone number, then use <em>phone</em> parameter.</p>\n</li>\n<li><p>phone – client’s phone number. Only digits are allowed. Only one of these two parameters is accepted: id or phone. If both or none<br />  is used, then an error is returned.</p>\n</li>\n<li><p>nickname – (optional) client’s name. Works only if nickname is empty. To change existing client's name use <code>сlients (PUT)</code></p>\n</li>\n<li><p>avatar – (optional) client’s avatar (direct url to a picture) to display in <em>Chats</em> section.</p>\n</li>\n</ul>\n<p>In order this command to work you must have an external channel connected to your company. Contact administration.</p>\n","urlObject":{"path":["v1","messages","inbox"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"78bea85f-14a2-47ec-8489-02926b589296"},{"name":"messages/import","id":"24b16311-9206-4cb3-8ee2-b478530602a6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"client_id\": \"44413\",\r\n    \"channel_id\": \"433\",\r\n    \"transport\": \"vk\",\r\n    \"messages\": [\r\n        {\r\n            \"timestamp\": \"1682676120\",\r\n            \"text\": \"text\",\r\n            \"type\": \"to_client\",\r\n            \"attachment\": \"\",\r\n            \"operator_id\": \"234567\",\r\n            \"external_id\": \"3234\"\r\n        }\r\n    ]\r\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/messages/import/","description":"<p>This method allows you to import messages (incoming, outgoing, attachments) that are not present in the C2D system (if the user corresponded before connecting the messenger in the C2D system).</p>\n<p>Messages can be imported as an array, but you can send no more than 10 messages per request.</p>\n<p>Only one attachment can be passed in the application parameter and the attachment format is presented as a direct link to the file.</p>\n<p>In the event that the <code>operator_id</code> is not specified, the admin id is automatically substituted, while after import the dialog will not be translated to the admin.</p>\n<h5 id=\"parameters\">Parameters:</h5>\n<p><strong>client_id</strong> - unique client ID (required parameter).</p>\n<p><strong>channel_id</strong> - the channel to which the device is connected (required parameter).</p>\n<p><strong>transport</strong> - name of the transport for which messages are imported (required parameter).</p>\n<p><strong>timestamp</strong> - the date of sending/receiving the message, by which all dialog messages are sorted (required parameter).</p>\n<p><strong>text</strong> - the text of the message, context-dependent on the value of the attachment parameter:</p>\n<ul>\n<li>if attachment is not filled in - a required parameter</li>\n<li>if attachment is filled in - optional to fill in</li>\n</ul>\n<p><strong>attachment</strong> - array with attachments, context-dependent on the text parameter. If text is filled in, the parameter is mandatory. If the text is not filled in, it is not required. The parameter must contain a direct link to the resource. Only one attachment can be passed in the application parameter</p>\n<p><strong>type</strong> - Message type (required parameter). Possible vakues \"autoreply\" \"to_client\" \"from_client\"</p>\n<p><strong>operator_id</strong> - the unique identifier of the author of the message, a context-dependent parameter from the value of the type parameter (optional parameter):</p>\n<ul>\n<li>if type = to_client - if the parameter is not specified, the company administrator ID will be automatically assigned.</li>\n<li>if type = auto_reply - parameter filling is not required</li>\n</ul>\n<p><strong>external_id</strong> - If you send message using an integration with another platform or CRM system, you can store id of the message in the external system in this field.</p>\n","urlObject":{"path":["v1","messages","import",""],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"d645dda2-d267-4076-a82c-e7ab3ab97dfb","name":"OK","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"client_id\": 97371709,\r\n    \"channel_id\": 21325,\r\n    \"transport\": \"widget\",\r\n    \"messages\": [\r\n        {\r\n            \"timestamp\": \"1682676120\",\r\n            \"text\": \"image from interent\",\r\n            \"type\": \"to_client\",\r\n            \"attachment\": \"https://i.pinimg.com/236x/ed/83/4d/ed834d9d873cc920f44ee72598f14e6b--cute-baby-bunnies-adorable-babies.jpg?nii=t\"\r\n        },\r\n        {\r\n            \"timestamp\": \"1682676121\",\r\n            \"text\": \"document from storage\",\r\n            \"type\": \"to_client\",\r\n            \"attachment\": \"https://storage-test20.chat2desk.com/companies/company_62596/messages/2023-4/4a9f429abc678aba98c4_name_ZG9jLmRvYw==_.doc\"\r\n        },\r\n        {\r\n            \"timestamp\": \"1682676122\",\r\n            \"text\": \"link to mp4\",\r\n            \"type\": \"from_client\",\r\n            \"attachment\": \"https://samplelib.com/lib/preview/mp4/sample-5s.mp4\"\r\n        },\r\n        {\r\n            \"timestamp\": \"1682676123\",\r\n            \"text\": \"pdf\",\r\n            \"type\": \"from_client\",\r\n            \"attachment\": \"https://www.africau.edu/images/default/sample.pdf\"\r\n        },\r\n        {\r\n            \"timestamp\": \"1682676124\",\r\n            \"text\": \"robot\",\r\n            \"type\": \"autoreply\"\r\n        }\r\n    ]\r\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/messages/import/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\r\n    \"errors\": [],\r\n    \"status\": \"success\"\r\n}"},{"id":"c615eade-7e90-41e5-8635-5390c5180689","name":"error several attachments","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"client_id\": 97371709,\r\n    \"channel_id\": 21325,\r\n    \"transport\": \"widget\",\r\n    \"messages\": [\r\n        {\r\n            \"timestamp\": \"1682676120\",\r\n            \"text\": \"imported message with 2 attachments\",\r\n            \"type\": \"to_client\",\r\n            \"attachment\": [\r\n                \"https://i.pinimg.com/236x/ed/83/4d/ed834d9d873cc920f44ee72598f14e6b--cute-baby-bunnies-adorable-babies.jpg?nii=t\",\r\n                \"https://avatars.mds.yandex.net/i?id=ddb638252f6035b02a4d2483e1e16c6ceccd539a-5885375-images-thumbs&ref=rim&n=33&w=150&h=150\"\r\n            ]\r\n        }\r\n    ]\r\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"https://api.chat2desk.com/v1/messages/import/","host":["https://api.chat2desk.com"],"path":["v1","messages","import",""],"query":[{"key":"external_id","value":null,"description":"If you send message using an integration with another platform or CRM system, you can store id of the message in the external system in this field.","disabled":true}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\r\n    \"errors\": [\r\n        {\r\n            \"text\": \"imported message with 2 attachments\",\r\n            \"errors\": [\r\n                {\r\n                     \"attachment\": [\r\n                        \"must be a string\"\r\n                    ]\r\n                }\r\n            ]\r\n        }\r\n    ],\r\n    \"status\": \"failure\"\r\n}"}],"_postman_id":"24b16311-9206-4cb3-8ee2-b478530602a6"},{"name":"transfer_to_group","id":"a74a3828-ec84-4034-8286-41217cfda351","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/messages/1/transfer_to_group?group_id=1","description":"<p>Arranges a dialog with the specified message to a group of operators (agents). One operator from the group will be chosen by the System in according with the rules specified in <em>Settings &gt; Operators &gt; Groups &gt; Rules of selecting specific operator from group</em>.</p>\n","urlObject":{"path":["v1","messages","1","transfer_to_group"],"host":["https://api.chat2desk.com"],"query":[{"description":{"content":"<p>Id of an operators_groups (agents), on whom this message and corresponding dialog will be assigned. See <em>operators_groups (GET)</em>.</p>\n","type":"text/plain"},"key":"group_id","value":"1"},{"disabled":true,"description":{"content":"<p>Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.</p>\n","type":"text/plain"},"key":"force_assign","value":"{true, false}"}],"variable":[]}},"response":[{"id":"eb668b99-c72a-4b05-a912-e44b93bce9b8","name":"OK transfer_to_group","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer_to_group?group_id=1","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer_to_group"],"query":[{"key":"group_id","value":"1","description":"Id of an operators_groups (agents), on whom this message and corresponding dialog will be assigned. See *operators_groups (GET)*."},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"data\": {\r\n        \"assignee\": {\r\n            \"id\": 100,\r\n            \"email\": \"mail@mail.com\"\r\n        }\r\n    },\r\n    \"status\": \"success\"\r\n}"},{"id":"995a4f73-fc3a-442c-aff4-27b4fa6660a3","name":"error No available operator found!","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer_to_group?group_id=1&force_assign=false","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer_to_group"],"query":[{"key":"group_id","value":"1","description":"Id of an operators_groups (agents), on whom this message and corresponding dialog will be assigned. See *operators_groups (GET)*."},{"key":"force_assign","value":"false","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits."}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\r\n    \"message\": \"bad_request\",\r\n    \"errors\": [\r\n        {\r\n            \"text\": \"No available operator found!\",\r\n            \"error\": \"not_found\"\r\n        }\r\n    ],\r\n    \"status\": \"error\"\r\n}"},{"id":"a912bd13-b7b4-4ebd-8ef8-d50f7fe30478","name":"error Operator Group not found","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer_to_group?group_id=1","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer_to_group"],"query":[{"key":"group_id","value":"1","description":"Id of an operators_groups (agents), on whom this message and corresponding dialog will be assigned. See *operators_groups (GET)*."},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"Not Found","code":404,"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\r\n    \"message\": \"not_found\",\r\n    \"errors\": \"Operator Group #1 not found\",\r\n    \"status\": \"error\"\r\n}"},{"id":"48ae980b-663a-4266-b230-772f66e3863e","name":"error Message not found","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/messages/1/transfer_to_group?group_id=1","host":["https://api.chat2desk.com"],"path":["v1","messages","1","transfer_to_group"],"query":[{"key":"group_id","value":"1","description":"Id of an operators_groups (agents), on whom this message and corresponding dialog will be assigned. See *operators_groups (GET)*."},{"key":"force_assign","value":"{true, false}","description":"Force-assign a chat bypassing all assignment rules (default: true).\nSet to false to apply standard assignment logic: operator online status, queues, and dialog limits.","type":"text","disabled":true}]}},"status":"Not Found","code":404,"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"message\": \"not_found\",\r\n    \"errors\": \"Message #1 not found\",\r\n    \"status\": \"error\"\r\n}"}],"_postman_id":"a74a3828-ec84-4034-8286-41217cfda351"},{"name":"requests/<id>","id":"c5f661c5-4c38-4401-adda-19de07d03058","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/requests/165505634","description":"<p>Returns an info about specified request (see <a href=\"#intro\">TERMS</a> for <em>request</em>).</p>\n<p>Use <em>requests/id/messages</em> to get a list of request messages.</p>\n","urlObject":{"path":["v1","requests","165505634"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"2714e8e2-e300-420f-a62d-0390982340a7","name":"requests/<id>","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/requests/165505634"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{'dialog_id': 10389149, 'id': 30875600, 'tags': []}"}],"_postman_id":"c5f661c5-4c38-4401-adda-19de07d03058"},{"name":"requests/<id>/messages","id":"a5d92f3a-c1e6-42bd-8fd8-647b33e9826f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/requests/165505634/messages","description":"<p>Returns a list of request messages (see <a href=\"#intro\">TERMS</a> for <em>request</em>).</p>\n<p>Use <em>requests/id</em> to get an info about the request.</p>\n","urlObject":{"path":["v1","requests","165505634","messages"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"e098054a-e010-48a9-8ffd-b355f094285f","name":"requests/<id>/messages","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/requests/165505634/messages"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[{'ai_tips': None,\n  'audio': None,\n  'channelID': 21085,\n  'clientID': 4659188,\n  'companyID': 400,\n  'conversationID': None,\n  'coordinates': None,\n  'created': 1573638755,\n  'dialogID': 10389149,\n  'extra_data': {},\n  'extra_type': 'normal',\n  'gateway_status': 'sent',\n  'id': 274002631,\n  'is_menu': None,\n  'job_id': None,\n  'operatorID': 47257,\n  'pdf': None,\n  'photo': None,\n  'read': 1,\n  'recipient_status': None,\n  'remote_id': None,\n  'sent_at': None,\n  'text': \"{u'phone': u'+430006142463'}\\nClient\\n\",\n  'transport': 'telegram',\n  'type': 'out',\n  'video': None}]"}],"_postman_id":"a5d92f3a-c1e6-42bd-8fd8-647b33e9826f"},{"name":"requests/close","id":"7f8e8c57-5489-4ce7-b74e-833bf0b82662","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"request_id\": 165505634\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/requests/close","description":"<p>Closes a request (see <a href=\"#intro\">TERMS</a> for <em>request</em>).</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:\n{\"request_id\": 537136\nor\n\"client_id\": 37817}</p>\n<ul>\n<li>request_id – request to close.</li>\n<li>client_id – current request of specified client will be closed.</li>\n</ul>\n","urlObject":{"path":["v1","requests","close"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"7f8e8c57-5489-4ce7-b74e-833bf0b82662"},{"name":"messages","id":"ce1ae93b-8ba2-490d-b831-b520479338e1","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/messages/<message_id>/status/<status>","description":"<p>Allows to change delivery status for outgoing message <strong>only for external channel</strong>.</p>\n<p>Possible use case:<br />Client implemented integration with corporate mobile application using external channel.<br />• Message is sent to mobile application using <code>messages (POST)</code><br />• Message is delivered to end user in mobile application<br />• Message is marked as delivered using <code>messages (PUT)</code></p>\n<p>Params:<br />• status – can be one of the following:<br />1 – pending;<br />2 – sent;<br />3 – failed;<br />5 – canceled;<br />6 – delivered;<br />7 - seen.</p>\n","urlObject":{"path":["v1","messages","<message_id>","status","<status>"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"ce1ae93b-8ba2-490d-b831-b520479338e1"}],"id":"d170e873-15c9-412a-9c2a-a92ff616b293","description":"<p>Working with messages and requests.</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"53fd6533-2969-4c4d-a2ff-4040b7fd13de"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"139ea2dd-b2a2-4dc7-a7bc-026070a7f93b"}}],"_postman_id":"d170e873-15c9-412a-9c2a-a92ff616b293"},{"name":"Dialogs","item":[{"name":"dialogs","id":"bae63c1d-f11d-4e59-b013-9b3bea5c337d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/dialogs/","description":"<p>Returns a list of your dialogs. </p>\n<p>Note, that once an operator (agent) takes or is being assigned with a dialog with a client, the messages of the chat start to belong to this dialog.</p>\n","urlObject":{"path":["v1","dialogs",""],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":""},{"disabled":true,"description":{"content":"<p>id of operator.</p>\n","type":"text/plain"},"key":"operator_id","value":null},{"disabled":true,"description":{"content":"<p>state of dialog (open or closed).</p>\n","type":"text/plain"},"key":"state","value":""},{"disabled":true,"description":{"content":"<p>order of records returned (asc or desc). Default is ascending order.</p>\n","type":"text/plain"},"key":"order","value":""}],"variable":[]}},"response":[{"id":"dfa264fc-65ff-4f62-b391-f071184e5ff4","name":"dialogs","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/dialogs/","host":["https://api.chat2desk.com"],"path":["v1","dialogs",""],"query":[{"key":"limit","value":"","description":"Number of records returned (maximum is 200, default is 20).","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","disabled":true}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[{'begin': '2019-11-13T09:52:17 UTC',\n  'end': '2023-07-26T16:22:02 UTC',\n  'id': 10389149,\n  'last_message': {'ai_tips': None,\n                   'attachments': [],\n                   'audio': None,\n                   'channel_id': 21085,\n                   'client_id': 4659188,\n                   'coordinates': None,\n                   'created': '2022-07-26T16:22:02 UTC',\n                   'dialog_id': 10389149,\n                   'extra_data': {},\n                   'id': 1776753541,\n                   'operator_id': 47257,\n                   'pdf': None,\n                   'photo': None,\n                   'read': 1,\n                   'recipient_status': None,\n                   'remote_id': None,\n                   'request_id': 221266751,\n                   'text': '...',\n                   'transport': 'telegram',\n                   'type': 'system',\n                   'video': None},\n  'operator_id': 47257,\n  'state': 'closed'},"}],"_postman_id":"bae63c1d-f11d-4e59-b013-9b3bea5c337d"},{"name":"dialogs/<id>","id":"01526c90-0bda-4907-9dc8-8bc54cc57b88","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/dialogs/18498876/","description":"<p>Returns an info on a dialog specified.\n18498876 here is an example of dialog id.</p>\n<p>Note, that once an operator (agent) takes or is being assigned with a dialog with a client, the messages of the chat start to belong to this dialog.</p>\n","urlObject":{"path":["v1","dialogs","18498876",""],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":""}],"variable":[]}},"response":[{"id":"50d1aea2-eef2-40fc-9513-3f648b7a2f62","name":"dialogs/<id>","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/dialogs/18498876/","host":["https://api.chat2desk.com"],"path":["v1","dialogs","18498876",""],"query":[{"key":"limit","value":"","description":"Number of records returned (maximum is 200, default is 20).","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","disabled":true}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{'begin': '2020-01-09T07:20:13 UTC',\n 'end': '2022-01-24T07:36:45 UTC',\n 'id': 11556193,\n 'last_message': {'ai_tips': None,\n                  'attachments': [],\n                  'audio': None,\n                  'channel_id': 22247,\n                  'client_id': 93392623,\n                  'coordinates': None,\n                  'created': '2021-07-24T06:04:49 UTC',\n                  'dialog_id': 11556193,\n                  'extra_data': {},\n                  'id': 1064929991,\n                  'operator_id': 210350,\n                  'pdf': None,\n                  'photo': None,\n                  'read': 1,\n                  'recipient_status': None,\n                  'remote_id': None,\n                  'request_id': None,\n                  'text': '...',\n                  'transport': 'tg_user',\n                  'type': 'system',\n                  'video': None},\n 'last_request_id': 38892783,\n 'messages': 111,\n 'operator_id': 210350,\n 'state': 'closed'}"}],"_postman_id":"01526c90-0bda-4907-9dc8-8bc54cc57b88"},{"name":"dialogs/unanswered","id":"845bc479-e52a-435f-bdbf-368ea2366bee","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/dialogs/unanswered?limit=600","description":"<p>Returns a list of overdue dialogs that are unanswered for specified period of seconds. Use it to track \"stuck\" chats with your clients.</p>\n","urlObject":{"path":["v1","dialogs","unanswered"],"host":["https://api.chat2desk.com"],"query":[{"description":{"content":"<p>Time in seconds after last client’s message after which a dialog is considered overdue. As you can see, here <em>limit</em> parameter replaces the number of records to return.</p>\n","type":"text/plain"},"key":"limit","value":"600"}],"variable":[]}},"response":[{"id":"fa8cfc20-3058-442d-9596-1a45ee83246d","name":"dialogs/unanswered","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/dialogs/unanswered?limit=600","host":["https://api.chat2desk.com"],"path":["v1","dialogs","unanswered"],"query":[{"key":"limit","value":"600","description":"Time in seconds after last client’s message after which a dialog is considered overdue. As you can see, here *limit* parameter replaces the number of records to return."}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{'client_ids': [454339496], 'ids': [45504535]}"}],"_postman_id":"845bc479-e52a-435f-bdbf-368ea2366bee"},{"name":"dialogs/<id>","id":"5ae5a8d4-138e-4faf-afd0-d92986eac1ec","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"operator_id\": 221063,\n    \"state\": \"closed\",\n    \"initiator_id\": 2,\n    \"force_assign\": \"true\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/dialogs/18498876","description":"<p>Changes a dialog state and arranges it to an operator (agent).</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:<br />{\"operator_id\": 1,<br />\"state\": \"open\" or \"closed\",<br />\"initiator_id\": 2,<br />\"force_assign\": \"true\" or \"false\"}</p>\n<p>* initiator_id - (optional) You can specify the id of the operator who initiated the chat translation. If the parameter is not specified, the administrator is the initiator of the transfer</p>\n<p>* force_assign - (optional) Force-assign a chat bypassing all assignment rules (default: true). Set to false to apply standard assigment logic: operator online status, queues, and dialog limits.</p>\n","urlObject":{"path":["v1","dialogs","18498876"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"64790e8e-8583-43b9-84f8-c40ec837b89f","name":"OK","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"operator_id\": 221063,\n    \"state\": \"closed\",\n    \"initiator_id\": 2,\n    \"force_assign\": \"true\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/dialogs/18498876"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null},{"id":"fa593ff5-4466-485b-a3f7-86226a175105","name":"error Could not transfer to operator","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"operator_id\": 221063,\n    \"state\": \"closed\",\n    \"initiator_id\": 2,\n    \"force_assign\": \"false\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/dialogs/18498876"},"status":"Bad Request","code":400,"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"message\": \"bad_request\",\r\n    \"errors\": [\r\n        {\r\n            \"text\": \"Could not transfer to operator 221063.\",\r\n            \"error\": \"not_found\"\r\n        }\r\n    ],\r\n    \"status\": \"error\"\r\n}"}],"_postman_id":"5ae5a8d4-138e-4faf-afd0-d92986eac1ec"}],"id":"dde2655e-dbf9-4b2b-b8b3-d27998180c6f","description":"<p>Working with dialogs (chats).</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"f7fa5126-1db0-461c-9c9a-333a4b95e260"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"0075a73d-d73e-4ca7-ba93-84e020651336"}}],"_postman_id":"dde2655e-dbf9-4b2b-b8b3-d27998180c6f"},{"name":"Webhooks","item":[{"name":"webhooks","id":"90e3507e-6e7e-426e-ae61-6c1d16a6c75a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"javascript"}}},"url":"https://api.chat2desk.com/v1/webhooks","description":"<p>Returns a list of your active webhooks.</p>\n","urlObject":{"path":["v1","webhooks"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"8625ffeb-b869-465e-9c6b-6f9fe194d94a","name":"webhooks","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"API token","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"javascript"}}},"url":"https://api.chat2desk.com/v1/webhooks"},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 537680,\n            \"name\": \"New name\",\n            \"url\": \"https://yoursite.com/\",\n            \"events\": [\n                \"inbox\",\n                \"outbox\",\n                \"comment\"\n            ],\n            \"status\": \"enable\",\n            \"errors\": [],\n            \"source\": \"client\",\n            \"channels\": [\n                1123,\n                5813\n            ]\n        }\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"90e3507e-6e7e-426e-ae61-6c1d16a6c75a"},{"name":"webhooks/<id>","id":"33357787-b16d-45c4-b991-098b3ea6ec35","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/webhooks/5518","description":"<p>Returns an info about specified webhook.<br />5518 here as an example of webhook id.</p>\n","urlObject":{"path":["v1","webhooks","5518"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"34f53e57-8f52-427f-980d-8f3951d5d3c3","name":"webhooks/<id>","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/webhooks/5518"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 5518,\n            \"name\": \"My first web hook\",\n            \"url\": \"https://yoursite.com/\",\n            \"events\": [\n                \"inbox\"\n            ],\n            \"status\": \"enable\",\n            \"errors\": null\n        }\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"33357787-b16d-45c4-b991-098b3ea6ec35"},{"name":"webhooks","id":"9b34340c-b37b-4916-a215-be9b1327c57c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\r\n    \"url\": \"https://yoursite.com/\",\r\n    \"name\": \"My first web hook\",\r\n    \"events\": [\r\n        \"inbox\",\r\n        \"outbox\",\r\n        \"comment\"\r\n    ],\r\n    \"channels\": [\r\n        1123,\r\n        5813\r\n    ]\r\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/webhooks","description":"<p>Creates a new webhook for various events.</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example with events:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"url\": \"https://yoursite.com/\",\n    \"name\": \"Webhook name\",\n    \"events\": [\n        \"inbox\",\n        \"outbox\",\n        \"outbox_status\",\n        \"comment\",\n        \"operator_status_changed\",\n        \"operator_authentication_updated\",\n        \"new_client\",        \n        \"new_tag\",        \n        \"new_request\",\n        \"add_tag_to_client\",\n        \"add_tag_to_request\",\n        \"delete_tag_from_client\",\n        \"delete_tag_from_request\",\n        \"client_updated\",\n        \"client_added_to_blacklist\",\n        \"close_dialog\",\n        \"close_request\",\n        \"dialog_transferred\",\n        \"device_updated\",\n        \"new_ticket\",\n        \"ticket_updated\",\n        \"ticket_deleted\",\n        \"new_qr_code\",\n        \"ai_hints_requested\"\n    ],\n    \"channels\": [\n        1123,\n        5813\n    ]\n}\n\n</code></pre>\n<ul>\n<li><p>name: name of new webhook. Up to 5 simultaneous webhooks are allowed for free.</p>\n</li>\n<li><p>url: URL on your server where the requests will come. Any URL is allowed but we recommend https. If empty value (null) is set then the<br />  webhook will be deleted.</p>\n</li>\n<li><p>events: events list for which webhook will be triggered. See supported events in Webhooks description</p>\n</li>\n<li><p>channels: list of channels through which you will receive events related to the channel (events for messages, dialogs, etc.). If omitted, events will be sent for all channels. Events not related to a channel (events for operators, client changes, etc.) will always be received.</p>\n</li>\n</ul>\n","urlObject":{"path":["v1","webhooks"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"0e37f871-d8b8-4dd5-af36-1ceb0e4f74d5","name":"webhooks","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"API token","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\r\n    \"url\": \"https://yoursite.com/\",\r\n    \"name\": \"My first web hook\",\r\n    \"events\": [\r\n        \"inbox\",\r\n        \"outbox\",\r\n        \"comment\"\r\n    ],\r\n    \"channels\": [\r\n        1123,\r\n        5813\r\n    ]\r\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/webhooks"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": 97,\n        \"name\": \"My first web hook\",\n        \"url\": \"https://yoursite.com/\",\n        \"events\": [\n            \"inbox\",\n            \"outbox\",\n            \"comment\"\n        ],\n        \"status\": \"enable\",\n        \"errors\": null,\n        \"source\": \"client\",\n        \"channels\": [\n            1123,\n            5813\n        ]\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"9b34340c-b37b-4916-a215-be9b1327c57c"},{"name":"webhooks/<id>","id":"51d49f89-afdf-4584-887b-fd87b5dc19db","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\r\n    \"url\": \"https://yoursite.com/\",\r\n    \"name\": \"New name\",\r\n    \"events\": [\"inbox\", \"outbox\"]\r\n }\r\n","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/webhooks/222421","description":"<p>Updates specified webhook.<br />222421 here is an example of webhook id that you want to update – see <code>webhooks (POST)</code></p>\n","urlObject":{"path":["v1","webhooks","222421"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>use this parameter if you want to\nactivate or deactivate existing wehhook. If omitted, webhook status will not be\nchanged</p>\n","type":"text/plain"},"key":"status","value":"enable/disable"}],"variable":[]}},"response":[],"_postman_id":"51d49f89-afdf-4584-887b-fd87b5dc19db"},{"name":"webhooks/<id>","id":"32a549ad-4eb8-4bf1-9d5a-438581d23ddb","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/webhooks/{id}","description":"<p>Deletes specified webhook.<br />222421 here is an example of webhook id.</p>\n","urlObject":{"path":["v1","webhooks","{id}"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"1188c807-ba50-4e81-9c5d-81286f1996f5","name":"webhooks/<id>","originalRequest":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/webhooks/{id}"},"status":"OK","code":200,"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\r\n \"status\": \"success\"\r\n}"}],"_postman_id":"32a549ad-4eb8-4bf1-9d5a-438581d23ddb"}],"id":"c156e2a3-3e11-44dd-8ad7-852cd6cf7740","description":"<p>Working with webhooks. The System supports up to 5 simultaneous webhooks for free.</p>\n<p><strong>Important!</strong> We resend unsuccessful webhook event 3 times: after 10 seconds, after 5 minutes and after 2 hours. In order to avoid overload, a webhook will be <strong>disabled</strong> if after 5 hours no respond of successful data acceptance was received. See <em>Errors</em> section for more details.</p>\n<h3 id=\"these-events-are-supported\"><strong>These events are supported:</strong></h3>\n<ul>\n<li><strong>inbox</strong>: an incoming message from a client came.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"message_id\": 115816153,\n  \"type\": \"from_client\",\n  \"text\": \"Hello!\",\n  \"transport\": \"telegram\",\n  \"client_id\": 30247382,\n  \"operator_id\": null,\n  \"dialog_id\": 4236638,\n  \"channel_id\": 18337,\n  \"photo\": null,\n  \"coordinates\": null,\n  \"audio\": null,\n  \"pdf\": null,\n  \"client\": {\n    \"id\": 30247382,\n    \"phone\": \"[tg] 734937551\",\n    \"client_phone\": \"\",\n    \"name\": \"Ольга Шуст\",\n    \"assigned_name\": null,\n    \"external_id\": null\n  },\n  \"hook_type\": \"inbox\",\n  \"request_id\": 8891565,\n  \"attachments\": [],\n  \"is_new_request\": true,\n  \"is_new_client\": false,\n  \"insta_comment\": false,\n  \"extra_data\": {},\n  \"is_new\": true,\n  \"event_time\": \"2023-01-25T09:32:10.137860Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>outbox</strong>: an outgoing message from the System to a client was sent.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"message_id\": 115816478,\n  \"type\": \"to_client\",\n  \"text\": \"How do you do ?\",\n  \"transport\": \"telegram\",\n  \"client_id\": 30247382,\n  \"operator_id\": 40818,\n  \"dialog_id\": 4236638,\n  \"channel_id\": 18337,\n  \"photo\": null,\n  \"coordinates\": null,\n  \"audio\": null,\n  \"pdf\": null,\n  \"client\": {\n    \"id\": 30247382,\n    \"phone\": \"[tg] 734937551\",\n    \"client_phone\": \"\",\n    \"name\": \"Ольга Шуст\",\n    \"assigned_name\": null,\n    \"external_id\": null\n  },\n  \"hook_type\": \"outbox\",\n  \"request_id\": 8891565,\n  \"attachments\": [],\n  \"is_new_request\": false,\n  \"is_new_client\": false,\n  \"insta_comment\": false,\n  \"extra_data\": {},\n  \"is_new\": false,\n  \"event_time\": \"2023-01-25T09:44:48.968258Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>imported_message</strong>: a message imported into the system via POST <code>messages/inbox</code> or received directly from messengers (WhatsApp, VK Direct, Telegram User). These messages do not trigger standard inbox/outbox webhooks or automations.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n \"message_id\": 5015921655,\n \"type\": \"to_client\",\n \"text\": \"text import\",\n \"transport\": \"telegram\",\n \"client_id\": 30247382,\n \"operator_id\": 40818,\n \"dialog_id\": 4236638,\n \"channel_id\": 18337,\n \"photo\": null,\n \"coordinates\": null,\n \"audio\": null,\n \"pdf\": null,\n \"client\": {\n \"id\": 30247382,\n \"phone\": \"[tg] 734937551\",\n \"client_phone\": null,\n \"name\": \"Dariia \",\n \"assigned_name\": \"Dariia\",\n \"external_id\": null\n },\n \"hook_type\": \"imported_message\",\n \"request_id\": 8891565,\n \"attachments\": [],\n \"is_new_request\": false,\n \"is_new_client\": false,\n \"insta_comment\": false,\n \"extra_data\": {\n \"external_id\": \"3234\",\n \"imported\": true\n },\n \"is_new\": false,\n \"event_time\": \"2026-02-02T13:44:41.694809Z\"\n}\n\n</code></pre>\n<ul>\n<li><p><strong>outbox_status</strong>: an error was received by the System from the messenger provider when trying to send a message. For example, a message from operator was processed by the System and sent to WhatsApp Business API (WABA), but the WABA provider responded with error – <em>timeout error</em> -<code>\"gateway_status\": \"failed\".</code><br />  The possible gateway_status for the event:</p>\n<ul>\n<li><p>pending</p>\n</li>\n<li><p>sent</p>\n</li>\n<li><p>failed</p>\n</li>\n<li><p>scheduled</p>\n</li>\n<li><p>canceled</p>\n</li>\n<li><p>delivered</p>\n</li>\n<li><p>seen</p>\n</li>\n</ul>\n</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"data\": {\n    \"id\": 983574888,\n    \"gateway_status\": \"sent\",\n    \"created\": \"2021-06-10T17:38:04 MSK\",\n    \"dialog_id\": 23544077,\n    \"client_id\": 177597039,\n    \"error\": null\n  },\n  \"hook_type\": \"outbox_status\",\n  \"event_time\": \"2021-06-10T14:38:04Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>comment</strong>: an internal comment was added in the dialog box.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"message_id\": 115816454,\n  \"type\": \"comment\",\n  \"text\": \"Don't close\",\n  \"transport\": \"telegram\",\n  \"client_id\": 30247382,\n  \"operator_id\": 40818,\n  \"dialog_id\": 4236638,\n  \"channel_id\": 18337,\n  \"photo\": null,\n  \"coordinates\": null,\n  \"audio\": null,\n  \"pdf\": null,\n  \"client\": {\n    \"id\": 30247382,\n    \"phone\": \"[tg] 734937551\",\n    \"client_phone\": \"\",\n    \"name\": \"Ольга Шуст\",\n    \"assigned_name\": \"misterbanana\",\n    \"external_id\": null\n  },\n  \"hook_type\": \"comment\",\n  \"request_id\": 8891565,\n  \"attachments\": null,\n  \"is_new_request\": false,\n  \"is_new_client\": false,\n  \"insta_comment\": false,\n  \"extra_data\": {},\n  \"event_time\": \"2023-01-25T09:43:12.494933Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>operator_status_changed</strong>: the status of operator was changed.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"id\": \"2325532\",\n  \"email\": \"operator_email@mail.com\",\n  \"online\": 0,\n  \"offline_type\": \"busy\",\n  \"status_id\": 1,\n  \"hook_type\": \"operator_status_updated\",\n  \"event_time\": \"2023-01-25T09:40:12.518169Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>operator_authentication_updated</strong>: the information about changing the operator's authorization. Posiible event parameters: <code>log out</code> and <code>log in</code>. Example of data:</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"id\": 40818,\n  \"email\": \"operator_email@mail.com\",\n  \"event\": \"login\"/\"logout\",\n  \"platform\": \"web\"/\"mobile\"\n  \"event_time\": \"2023-01-25T09:40:12.518169Z\",\n  \"hook_type\": \"operator_authentication_updated\",\n  \"ip_address\": \"\"\n}\n\n</code></pre>\n<ul>\n<li><strong>new_client</strong>: first incoming message came from the new client or a new client was created using <code>clients (POST)</code>.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"id\": 31074670,\n  \"phone\": \"[tg] 7536765434\",\n  \"name\": \"Nocolas\",\n  \"avatar\": \"\",\n  \"assigned_name\": null,\n  \"comment\": null,\n  \"region_id\": null,\n  \"country_id\": null,\n  \"extra_comment_1\": null,\n  \"extra_comment_2\": null,\n  \"extra_comment_3\": null,\n  \"client_created\": \"2023-01-25T10:14:46 UTC\",\n  \"client_updated\": \"2023-01-25T10:14:46 UTC\",\n  \"channels\": [\n    {\n      \"id\": 18333,\n      \"transports\": [\n        \"telegram\"\n      ]\n    }\n  ],\n  \"tags\": [],\n  \"client_source\": \"incoming_message\",\n  \"hook_type\": \"new_client\",\n  \"event_time\": \"2023-01-25T10:14:46.699087Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>new_tag</strong>: a new tag was added to company settings.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"id\": 22114,\n  \"label\": \"vip\",\n  \"description\": \"vip client\",\n  \"group_id\": 14779,\n  \"group_name\": \"test\",\n  \"hook_type\": \"new_tag\",\n  \"event_time\": \"2023-01-25T10:03:48.266263Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>new_request</strong>: a new request was created.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"request_id\": 8891565,\n  \"client_id\": 30247382,\n  \"dialog_id\": 4236638,\n  \"created\": 1674639130,\n  \"updated\": 1674639130,\n  \"start_message_id\": 115816153,\n  \"end_message_id\": null,\n  \"type\": \"common\",\n  \"channel_id\": 18337,\n  \"transport\": \"telegram\",\n  \"is_new_client\": false,\n  \"starter\": \"other\",\n  \"client\": {\n    \"id\": 30247382,\n    \"phone\": \"[tg] 734937551\",\n    \"name\": \"Ольга Шуст\",\n    \"avatar\": \"https://storage.chat2desk.com/companies/clients/avatars/2023-1/5797f8bfca0befda2.jpg\",\n    \"client_source\": null,\n    \"assigned_name\": null,\n    \"comment\": \"\",\n    \"extra_comment_1\": null,\n    \"client_phone\": \"\",\n    \"extra_comment_2\": null,\n    \"extra_comment_3\": null,\n    \"channels\": {\n      \"id\": 18337,\n      \"transports\": [\n        \"telegram\"\n      ]\n    },\n    \"region_id\": null,\n    \"country_id\": null,\n    \"custom_fields\": {}\n  },\n  \"by_client\": true,\n  \"hook_type\": \"new_request\",\n  \"event_time\": \"2023-01-25T09:32:10.134614Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>add_tag_to_client</strong>: a tag was assigned to a client.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"id\": 22113,\n  \"name\": \"tag\",\n  \"description\": \"taggg\",\n  \"group_id\": 14779,\n  \"group_name\": \"test\",\n  \"client_id\": 30247382,\n  \"channel_id\": 18337,\n  \"transport\": \"telegram\",\n  \"all_client_channels\": [\n    18337\n  ],\n  \"hook_type\": \"add_tag_to_client\",\n  \"event_time\": \"2023-01-25T09:46:00.603275Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>add_tag_to_request</strong>: a tag was assigned to a request.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n \"id\": 6385,\n \"name\": \"ABC1\",\n \"description\": \"My tag description\",\n \"group_id\": 1128,\n \"group_name\": \"группа тегов\",\n \"client_id\": 29030799,\n \"request_id\": 8705737,\n \"channel_id\": 17320,\n \"transport\": \"insta_local\",\n \"hook_type\": \"add_tag_to_request\",\n \"event_time\": \"2023-01-25T12:06:00.603275Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>delete_tag_from_client</strong>: a client tag was deleted.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n \"id\": 6385,\n \"name\": \"ABC1\",\n \"description\": \"My tag description\",\n \"group_id\": 1128,\n \"group_name\": \"группа тегов\",\n \"client_id\": 29030799,\n \"hook_type\": \"delete_tag_from_client\",\n \"event_time\": \"2023-01-06T08:19:06Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>delete_tag_from_request</strong>: a request tag was deleted.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n \"id\": 6385,\n \"name\": \"ABC1\",\n \"description\": \"My tag description\",\n \"group_id\": 1128,\n \"group_name\": \"группа тегов\",\n \"request_id\": 8705737,\n \"hook_type\": \"delete_tag_from_request\",\n \"event_time\": \"2023-01-25T09:46:00.603275Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>client_updated</strong>: an info in client card was changed.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"id\": 30247382,\n  \"phone\": \"[tg] 734937551\",\n  \"name\": \"Ольга Шуст\",\n  \"avatar\": \"https://storage.chat2desk.com/companies/clients/avatars/2023-1/5797f8bfca0befda2.jpg\",\n  \"client_source\": null,\n  \"assigned_name\": null,\n  \"comment\": \"VIP\",\n  \"extra_comment_1\": null,\n  \"client_phone\": \"+73456789009\",\n  \"extra_comment_2\": null,\n  \"extra_comment_3\": null,\n  \"channels\": {\n    \"id\": null,\n    \"transports\": [\n      null\n    ]\n  },\n  \"region_id\": null,\n  \"country_id\": null,\n  \"custom_fields\": {},\n  \"hook_type\": \"client_updated\",\n  \"event_time\": \"2023-01-25T09:40:12.518169Z\"\n}\n\n</code></pre>\n<ul>\n<li><p><strong>client_added_to_blacklist</strong>: a client was added / removed to/from blacklist</p>\n<ul>\n<li>\"is_blocked\": true / false</li>\n</ul>\n</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"id\": 97370263,\n  \"phone\": \"[chat] c78b4ab2e85c4c9f601e\",\n  \"name\": null,\n  \"avatar\": null,\n  \"assigned_name\": null,\n  \"comment\": null,\n  \"region_id\": null,\n  \"country_id\": null,\n  \"extra_comment_1\": null,\n  \"extra_comment_2\": null,\n  \"extra_comment_3\": null,\n  \"client_created\": \"2024-04-26T07:57:40 UTC\",\n  \"client_updated\": \"2024-04-26T07:57:40 UTC\",\n  \"tags\": [],\n  \"is_blocked\": true,\n  \"hook_type\": \"client_added_to_blacklist\",\n  \"event_time\": \"2024-04-26T08:50:18.801711Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>close_dialog</strong>: a dialog was closed.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"dialog_id\": 4236638,\n  \"request_id\": 8891506,\n  \"created\": 1674636968,\n  \"updated\": 1674638907,\n  \"channel_id\": 18337,\n  \"client_id\": 30247382,\n  \"operator_id\": 40818,\n  \"current_operator_id\": 40818,\n  \"transport\": \"telegram\",\n  \"hook_type\": \"close_dialog\",\n  \"event_time\": \"2023-01-25T09:28:27.111923Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>close_request</strong>: a request was closed.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"dialog_id\": 4236638,\n  \"request_id\": 8891506,\n  \"created\": 1674636968,\n  \"updated\": 1674638907,\n  \"channel_id\": 18337,\n  \"client_id\": 30247382,\n  \"operator_id\": 40818,\n  \"transport\": \"telegram\",\n  \"end_message_id\": 115816049,\n  \"hook_type\": \"close_request\",\n  \"event_time\": \"2023-01-25T09:28:27.106220Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>dialog_transferred</strong>: a dialog was (re)assigned to an operator (agent).</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"dialog_id\": 4236638,\n  \"request_id\": 8891565,\n  \"created\": 1674636968,\n  \"updated\": 1674639504,\n  \"channel_id\": 18337,\n  \"client_id\": 30247382,\n  \"operator_id\": 40818,\n  \"current_operator_id\": 40818,\n  \"transport\": \"telegram\",\n  \"last_operator_id\": null,\n  \"scenario_id\": null,\n  \"hook_type\": \"dialog_transferred\",\n  \"event_time\": \"2023-01-25T09:38:24.422610Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>device_updated</strong>: the status of device was changed. Example of data:</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n \"transport\": \"telegram\",\n \"channel_id\": 17313,\n \"hook_type\": \"device_update\",\n \"status\": \"Created\",\n \"event_time\": \"2021-12-06T07:59:37Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>new_qr_code</strong>: new QR code to restore personal WhatsApp connection appeared on the site in <em>Settings &gt; Accounts</em> section. It means your WhatsApp connection got broken and needs repair. Contact administration.</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n \"qrcode_data\": \"OxrhCyoevcoool+z5GKz5GKz5GKz5GK\nz5GK\",\n \"qrcode_image\":\n \"data:image/png;base64,iVBORw0KG…=\",\n \"phone\": 1630507770,\n \"device_owner\": \"client\",\n \"hook_type\": \"new_qr_code\",\n \"event_time\": \"2023-01-25T09:43:12.494933Z\"\n}\n\n</code></pre>\n<ul>\n<li><strong>new_ticket</strong>: new ticket is created. Example of event:</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"hook_type\": \"ticket_created\",\n    \"timestamp\": \"2024-06-18T12:00:00Z\",\n    \"ticket\": {\n        \"id\": \"TICK-2\",\n        \"reporter_id\": 110889,\n        \"assignee_id\": 12321,\n        \"summary\": \"Non-compliance with the Pantone color palette\",\n        \"description\": \"A large batch of Malibu Blue paint did not comply with the color palette. The paint had a maroon tint.\",\n        \"status\": 1,\n        \"priority\": 2,\n        \"deadline\": \"2005-07-19T12:00:00Z\",\n        \"request_ids\": [\n            \"49284\",\n            \"443556\"\n        ],\n        \"created_at\": \"1956-01-03T10:00:00Z\",\n        \"updated_at\": \"1995-05-18T11:00:00Z\"\n    }\n}\n\n</code></pre>\n<ul>\n<li><strong>ticket_updated</strong> — ticket was changed. Example of event:</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"hook_type\": \"ticket_updated\",\n    \"timestamp\": \"1995-05-18T11:00:00Z\",\n    \"ticket\": {\n        \"id\": \"TICK-1\",\n        \"reporter_id\": 12321,\n        \"updater_id\": \"Public API\",\n        \"assignee_id\": 443556,\n        \"summary\": \"URGENT Delivery problem\",\n        \"description\": \"Problem with delivery with package 49284 to Mel Gibson and Sophie Marceau\",\n        \"status\": 2,\n        \"priority\": 3,\n        \"deadline\": \"2005-07-10T12:00:00Z\",\n        \"request_ids\": [\n            \"5813\",\n            \"2134\"\n        ],\n        \"created_at\": \"1956-01-03T10:00:00Z\",\n        \"updated_at\": \"1995-05-18T11:00:00Z\"\n    },\n    \"updates\": {\n        \"update_summary\": \"Delivery problem -&gt; URGENT Delivery problem\",\n        \"update_description\": \"Problem with delivery with package 49284 to Mel Gibson -&gt; Problem with delivery with package 49284 to Mel Gibson and Sophie Marceau\",\n        \"update_status\": \"1 → 2\",\n        \"update_priority\": \"2 → 3\",\n        \"update_assignee\": \"12321 → 443556\",\n        \"update_deadline\": \"2005-07-19 → 2005-07-10\",\n        \"attach_requests\": \"[2134]\",\n        \"detach_requests\": \"[1123]\"\n    }\n}\n\n</code></pre>\n<ul>\n<li><strong>ticket_deleted</strong> — ticket was deleted. Example of event:</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"hook_type\": \"ticket_deleted\",\n    \"timestamp\": \"2005-07-11T11:00:00Z\",\n    \"id\": \"1\",\n    \"ticket\": {\n        \"id\": \"TICK-1\",\n        \"reporter_id\": 12321,\n        \"updater_id\": \"Public API\",\n        \"assignee_id\": 443556,\n        \"summary\": \"URGENT Delivery problem\",\n        \"description\": \"Problem with delivery with package 49284 to Mel Gibson and Sophie Marceau\",\n        \"status\": 2,\n        \"priority\": 3,\n        \"deadline\": \"2005-07-10T12:00:00Z\",\n        \"request_ids\": [\n            \"5813\",\n            \"2134\"\n        ],\n        \"created_at\": \"1956-01-03T10:00:00Z\",\n        \"updated_at\": \"1995-05-18T11:00:00Z\"\n    },\n    \"deleted by\": \"12321\"/\"Public API\"\n}\n\n</code></pre>\n<ul>\n<li><p><strong>ai_hints_requested</strong>: this webhook is for AI (Artificial Intelligence) provider and used in 2 ways:</p>\n<ul>\n<li><p>An operator (agent) or the System requested AI hints (suggestions) in <em>prompter mode</em>. Hints (suggestions) from AI provider are expected in return. To understand the context the provider should have all<br />  messages using webhooks <em>inbox</em> and <em>outbox</em> events.<br />  Example of data:<br />  <code>{\"client_id\": 11910, \"operator_id\": 1, \"dialog_id\": 331, \"request_id\": 2343, \"channel_id\": 1, \"message_id\": 8205 [event_time] =&gt; 2022-07-28T23:01:40Z}</code><br />  In return, AI provider should send hints (suggestions) in the following format:<br />  \"message_id\": 8205, \"hints\": <code>[{\"id\": 1, \"text\": \"answer 1\", \"url\": \"\", \"relevance\": 90, \"link\": \"\"},{\"id\": 2, \"text\": \"answer 2\", \"url\": \"\", \"relevance\": 97, \"link\": \"\"}]</code></p>\n</li>\n<li><p>An operator (agent) has chosen one AI hint from the list above. Used to teach AI engine on correct answers.<br />  Example of data:</p>\n</li>\n</ul>\n</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n \"client_id\": 11910, \n \"message_id\": 8205, \n \"hint_id\": 2, \n \"hook_type\": \"ai_hints_requested\",\n \"event_time\": 2022-07-28T23:01:40Z\n}\n\n</code></pre>\n<h3 id=\"webhook-signature-verification\">Webhook Signature Verification</h3>\n<p>To ensure that webhook events are coming from a trusted source and have not been tampered with, we use HMAC-based signature verification.</p>\n<h4 id=\"how-it-works\">How it works</h4>\n<p>Each webhook request contains the following headers:</p>\n<ul>\n<li><p><code>X-Signature</code> — the HMAC signature (hex-encoded)</p>\n</li>\n<li><p><code>X-Timestamp</code> — a UNIX timestamp (seconds since epoch)</p>\n</li>\n</ul>\n<p>To verify the request, the recipient should:</p>\n<ol>\n<li><p>signature_data = <code>raw_body</code>+<code>X-Timestamp</code></p>\n</li>\n<li><p><strong>Generate HMAC-SHA256</strong> using a secret key:</p>\n<ul>\n<li><p>The key is your API token, hashed with MD5.</p>\n</li>\n<li><p>The algorithm used is HMAC with SHA-256.</p>\n</li>\n</ul>\n</li>\n<li><p><strong>Compare</strong> the computed signature with the value of the <code>X-Signature</code> header.</p>\n</li>\n</ol>\n<p>If the signatures match, the request is considered valid.</p>\n<h3 id=\"implementation-examples\">Implementation examples:</h3>\n<ul>\n<li><strong>Ruby</strong></li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-ruby\">def verify_signature(data, timestamp, received_signature)\n  secret = \"md5_api_token\"\n  json_data_with_timestamp = data + timestamp\n  digest = OpenSSL::Digest.new('sha256')\n  calculated_signature = OpenSSL::HMAC.hexdigest(digest, secret, json_data_with_timestamp)\n  calculated_signature == received_signature\nend\ndata = '{\"message_id\":28780,\"type\":\"from_client\",\"text\":\"test7\",\"transport\":\"widget\",\"client_id\":12568,\"operator_id\":null,\"dialog_id\":942,\"channel_id\":1,\"photo\":null,\"coordinates\":null,\"audio\":null,\"pdf\":null,\"client\":{\"id\":12568,\"phone\":\"[chat] 1d0bb2e221762cfcc05c\",\"client_phone\":null,\"name\":\"[chat] 1d0bb2e221762cfcc05c\",\"assigned_name\":null,\"external_id\":null},\"hook_type\":\"inbox\",\"request_id\":5357,\"attachments\":[],\"is_new_request\":false,\"is_new_client\":false,\"insta_comment\":false,\"extra_data\":{},\"is_new\":true,\"event_time\":\"2025-04-03T11:50:06.984494Z\"}'\ntimestamp = \"1743681006\"\nreceived_signature = \"88b574d8237e1b7740f88102018b734d3dd5bc6803c509a3694eff9721b0c595\"\nverify_signature(data, timestamp, received_signature)\n\n</code></pre>\n<ul>\n<li><strong>Elixir</strong></li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-erlang\">defmodule WebhookValidator do\n  def verify_signature(data, timestamp, received_signature) do\n    json_data_with_timestamp = data &lt;&gt; timestamp\n    secret = \"md5_api_token\"\n    calculated_signature =\n      :crypto.mac(:hmac, :sha256, secret, json_data_with_timestamp)\n      |&gt; Base.encode16(case: :lower)\n    calculated_signature == received_signature\n  end\nend\ndata = \"{\\\"message_id\\\":28780,\\\"type\\\":\\\"from_client\\\",\\\"text\\\":\\\"test7\\\",\\\"transport\\\":\\\"widget\\\",\\\"client_id\\\":12568,\\\"operator_id\\\":null,\\\"dialog_id\\\":942,\\\"channel_id\\\":1,\\\"photo\\\":null,\\\"coordinates\\\":null,\\\"audio\\\":null,\\\"pdf\\\":null,\\\"client\\\":{\\\"id\\\":12568,\\\"phone\\\":\\\"[chat] 1d0bb2e221762cfcc05c\\\",\\\"client_phone\\\":null,\\\"name\\\":\\\"[chat] 1d0bb2e221762cfcc05c\\\",\\\"assigned_name\\\":null,\\\"external_id\\\":null},\\\"hook_type\\\":\\\"inbox\\\",\\\"request_id\\\":5357,\\\"attachments\\\":[],\\\"is_new_request\\\":false,\\\"is_new_client\\\":false,\\\"insta_comment\\\":false,\\\"extra_data\\\":{},\\\"is_new\\\":true,\\\"event_time\\\":\\\"2025-04-03T11:50:06.984494Z\\\"}\"\ntimestamp = \"1743681006\"\nreceived_signature = \"88b574d8237e1b7740f88102018b734d3dd5bc6803c509a3694eff9721b0c595\"\nWebhookValidator.verify_signature(data, timestamp, received_signature)\n\n</code></pre>\n<ul>\n<li><strong>PHP</strong></li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-php\">function verify_signature($data, $timestamp, $received_signature) {\n    $secret = \"md5_api_token\";\n    $json_data_with_timestamp = $data . $timestamp;\n    $calculated_signature = hash_hmac('sha256', $json_data_with_timestamp, $secret);\n    return $calculated_signature === $received_signature;\n}\n$data = \"{\\\"message_id\\\":28780,\\\"type\\\":\\\"from_client\\\",\\\"text\\\":\\\"test7\\\",\\\"transport\\\":\\\"widget\\\",\\\"client_id\\\":12568,\\\"operator_id\\\":null,\\\"dialog_id\\\":942,\\\"channel_id\\\":1,\\\"photo\\\":null,\\\"coordinates\\\":null,\\\"audio\\\":null,\\\"pdf\\\":null,\\\"client\\\":{\\\"id\\\":12568,\\\"phone\\\":\\\"[chat] 1d0bb2e221762cfcc05c\\\",\\\"client_phone\\\":null,\\\"name\\\":\\\"[chat] 1d0bb2e221762cfcc05c\\\",\\\"assigned_name\\\":null,\\\"external_id\\\":null},\\\"hook_type\\\":\\\"inbox\\\",\\\"request_id\\\":5357,\\\"attachments\\\":[],\\\"is_new_request\\\":false,\\\"is_new_client\\\":false,\\\"insta_comment\\\":false,\\\"extra_data\\\":{},\\\"is_new\\\":true,\\\"event_time\\\":\\\"2025-04-03T11:50:06.984494Z\\\"}\";\n$timestamp = \"1743681006\";\n$received_signature = \"88b574d8237e1b7740f88102018b734d3dd5bc6803c509a3694eff9721b0c595\";\nif (verify_signature($data, $timestamp, $received_signature)) {\n    echo \"Signature is valid.\";\n} else {\n    echo \"Signature is invalid.\";\n}\n\n</code></pre>\n<ul>\n<li><strong>JS</strong></li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-javascript\">const crypto = require('crypto');\nfunction verifySignature(data, timestamp, receivedSignature) {\n  const secret = \"md5_api_token\"; \n  const jsonDataWithTimestamp = data + timestamp;\n  const calculatedSignature = crypto\n    .createHmac('sha256', secret)\n    .update(jsonDataWithTimestamp)\n    .digest('hex');\n  return calculatedSignature === receivedSignature;\n}\nconst data = \"{\\\"message_id\\\":28780,\\\"type\\\":\\\"from_client\\\",\\\"text\\\":\\\"test7\\\",\\\"transport\\\":\\\"widget\\\",\\\"client_id\\\":12568,\\\"operator_id\\\":null,\\\"dialog_id\\\":942,\\\"channel_id\\\":1,\\\"photo\\\":null,\\\"coordinates\\\":null,\\\"audio\\\":null,\\\"pdf\\\":null,\\\"client\\\":{\\\"id\\\":12568,\\\"phone\\\":\\\"[chat] 1d0bb2e221762cfcc05c\\\",\\\"client_phone\\\":null,\\\"name\\\":\\\"[chat] 1d0bb2e221762cfcc05c\\\",\\\"assigned_name\\\":null,\\\"external_id\\\":null},\\\"hook_type\\\":\\\"inbox\\\",\\\"request_id\\\":5357,\\\"attachments\\\":[],\\\"is_new_request\\\":false,\\\"is_new_client\\\":false,\\\"insta_comment\\\":false,\\\"extra_data\\\":{},\\\"is_new\\\":true,\\\"event_time\\\":\\\"2025-04-03T11:50:06.984494Z\\\"}\";\nconst timestamp = \"1743681006\";\nconst receivedSignature = \"88b574d8237e1b7740f88102018b734d3dd5bc6803c509a3694eff9721b0c595\";\nverifySignature(data, timestamp, receivedSignature)\n\n</code></pre>\n<h3 id=\"testing-your-webhooks\">Testing your webhooks</h3>\n<p>To test your webhoook you can use this service: <a href=\"https://\">https://webhook.site/</a></p>\n<p><strong>Important!</strong> Do not forget to change your webhook URL after testing.</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"fd48af25-7842-46a7-8b99-4ec44abe4e86"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"89bcfd2a-debe-484b-a4b1-1f2572f0d075"}}],"_postman_id":"c156e2a3-3e11-44dd-8ad7-852cd6cf7740"},{"name":"Operators & Access rights","item":[{"name":"operators","id":"ab521470-bb04-4b23-b7e9-4fb243d5cc65","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/operators/","description":"<p>Returns a list of your operators (agents) in the System.</p>\n","urlObject":{"path":["v1","operators",""],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":""},{"disabled":true,"description":{"content":"<p>Phone number of operator.</p>\n","type":"text/plain"},"key":"phone","value":""},{"disabled":true,"description":{"content":"<p>Email of operator.</p>\n","type":"text/plain"},"key":"email","value":""},{"disabled":true,"description":{"content":"<p>Operator is considered online (online = 1) if he or she if logged in in\nany status. If an operator manually logs out or the system turns him or her offline\nbecause of inactivity, online becomes 0.</p>\n","type":"text/plain"},"key":"online","value":""},{"disabled":true,"description":{"content":"<p>Id of operator’s status (see GET operators/statuses)</p>\n","type":"text/plain"},"key":"status_id","value":""},{"disabled":true,"description":{"content":"<p>Shows operators who cannot receive new chats (true) or who can receive new chats (false).</p>\n","type":"text/plain"},"key":"disableNewChats","value":null},{"disabled":true,"description":{"content":"<p>Operators role in the chat center (for example: operator or supervisor).</p>\n","type":"text/plain"},"key":"role","value":null}],"variable":[]}},"response":[{"id":"59a27a84-a1b4-4a1e-b7d3-0b1bfecb8048","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/operators/","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"limit","value":"","description":"Number of records returned (maximum is 200, default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true},{"key":"phone","value":"","description":"Phone number of operator.","type":"text","disabled":true},{"key":"email","value":"","description":"Email of operator.","type":"text","disabled":true},{"key":"online","value":"","description":"Operator is considered online (online = 1) if he or she if logged in in\nany status. If an operator manually logs out or the system turns him or her offline\nbecause of inactivity, online becomes 0.","type":"text","disabled":true},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses)","type":"text","disabled":true},{"key":"disableNewChats","value":null,"description":"Shows operators who cannot receive new chats (true) or who can receive new chats (false).","type":"text","disabled":true},{"key":"role","value":null,"description":"Operators role in the chat center (for example: operator or supervisor).","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 1123,\n            \"email\": \"example@mail.com\",\n            \"phone\": \"\",\n            \"role\": \"admin\",\n            \"access_right_id\": null,\n            \"online\": 1,\n            \"offline_type\": \"busy\",\n            \"avatar\": \"null\",\n            \"opened_dialogs\": 48,\n            \"first_name\": \"Administrator\",\n            \"last_name\": \"null\",\n            \"external_id\": \"null\",\n            \"last_visit\": \"2026-01-28T10:17:20 UTC\",\n            \"status_id\": 1,\n            \"two_factor\": true,\n            \"status\": \"admin\",\n            \"access_right_name\": null\n        },\n        {\n            \"id\": 5813,\n            \"email\": \"example2@mail.com\",\n            \"phone\": \"\",\n            \"role\": \"operator\",\n            \"access_right_id\": 129102,\n            \"online\": 1,\n            \"offline_type\": \"break\",\n            \"avatar\": null,\n            \"opened_dialogs\": 4,\n            \"first_name\": \"John\",\n            \"last_name\": \"Wick\",\n            \"external_id\": \"\",\n            \"last_visit\": \"2024-11-26T21:12:16 UTC\",\n            \"status_id\": 2,\n            \"two_factor\": false,\n            \"status\": \"enabled\",\n            \"access_right_name\": \"Operator\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 2,\n        \"limit\": 20,\n        \"offset\": 0\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"ab521470-bb04-4b23-b7e9-4fb243d5cc65"},{"name":"operators","id":"ef4eefb7-5452-4a48-9690-b815e2d9b8d9","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"},{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.chat2desk.com/v1/operators/?email=&access_rights_id&first_name&last_name&status_id=","description":"<p>Creates a new operator (agent) in the System.</p>\n","urlObject":{"path":["v1","operators",""],"host":["https://api.chat2desk.com"],"query":[{"description":{"content":"<p>Email of operator.</p>\n","type":"text/plain"},"key":"email","value":""},{"description":{"content":"<p>Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights).</p>\n","type":"text/plain"},"key":"access_rights_id","value":null},{"disabled":true,"description":{"content":"<p>Operator avatar. Specify a publicly available image URL.</p>\n","type":"text/plain"},"key":"avatar","value":null},{"disabled":true,"description":{"content":"<p>External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.</p>\n","type":"text/plain"},"key":"external_id","value":null},{"description":{"content":"<p>First name of operator.</p>\n","type":"text/plain"},"key":"first_name","value":null},{"description":{"content":"<p>Last name of operator.</p>\n","type":"text/plain"},"key":"last_name","value":null},{"description":{"content":"<p>Id of operator’s status (see GET operators/statuses).</p>\n","type":"text/plain"},"key":"status_id","value":""}],"variable":[]}},"response":[{"id":"b0735b5e-011e-41dd-9c7c-929caaaa9575","name":"Successful Response","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/?email=example@mail.com&access_rights_id=55540&first_name=Jane&last_name=Doe&status_id=1","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"email","value":"example@mail.com","description":"Email of operator."},{"key":"access_rights_id","value":"55540","description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights)."},{"key":"avatar","value":null,"description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":null,"description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":"Jane","description":"First name of operator."},{"key":"last_name","value":"Doe","description":"Last name of operator."},{"key":"status_id","value":"1","description":"Id of operator’s status (see GET operators/statuses)."}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": 326452,\n        \"email\": \"example@mail.com\",\n        \"phone\": null,\n        \"role\": \"supervisor\",\n        \"access_right_id\": 55540,\n        \"online\": 0,\n        \"offline_type\": \"busy\",\n        \"avatar\": null,\n        \"first_name\": \"Jane\",\n        \"last_name\": \"Doe\",\n        \"external_id\": null,\n        \"last_visit\": null,\n        \"status_id\": 1,\n        \"two_factor\": false,\n        \"status\": \"enabled\",\n        \"access_right_name\": \"Супервайзер\"\n    },\n    \"status\": \"success\"\n}"},{"id":"54846cdd-d71e-4042-b789-dca3f91b7617","name":"error Operators limit","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/?email=&access_rights_id&first_name&last_name&status_id=","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"email","value":"","description":"Email of operator."},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights)."},{"key":"avatar","value":null,"description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":null,"description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator."},{"key":"last_name","value":null,"description":"Last name of operator."},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses)."}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"operators_limit\": [\n        \"operators limit\"\n    ]\n}"},{"id":"05be404c-2c2a-401a-8229-b2e6872efa69","name":"error Email must be uniqueness","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/?email=&access_rights_id&first_name&last_name&status_id=","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"email","value":"","description":"Email of operator."},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights)."},{"key":"avatar","value":null,"description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":null,"description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator."},{"key":"last_name","value":null,"description":"Last name of operator."},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses)."}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"email\": [\n        \"must be uniqueness\"\n    ]\n}"},{"id":"7f5f6396-826c-43c0-8c2c-e298f9ca9ccc","name":"error Access rights not found","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/?email=&access_rights_id&first_name&last_name&status_id=","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"email","value":"","description":"Email of operator."},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights)."},{"key":"avatar","value":null,"description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":null,"description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator."},{"key":"last_name","value":null,"description":"Last name of operator."},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses)."}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"access_rights_id\": [\n        {\n            \"error\": \"Access rights not found for this company!\"\n        }\n    ]\n}"},{"id":"f69651df-8f70-4691-b63c-90d5489a2dc0","name":"error Status id is not correct","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/?email=&access_rights_id&first_name&last_name&status_id=","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"email","value":"","description":"Email of operator."},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights)."},{"key":"avatar","value":null,"description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":null,"description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator."},{"key":"last_name","value":null,"description":"Last name of operator."},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses)."}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"status_id\": [\n        {\n            \"error\": \"This status id is not correct!\"\n        }\n    ]\n}"}],"_postman_id":"ef4eefb7-5452-4a48-9690-b815e2d9b8d9"},{"name":"operators/<id>","id":"410d373b-8322-4d24-80a9-11ba55de86e5","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"},{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.chat2desk.com/v1/operators/:id","description":"<p>Returns a list of your operators (agents) in the System.</p>\n","urlObject":{"path":["v1","operators",":id"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Email of operator.</p>\n","type":"text/plain"},"key":"email","value":""},{"disabled":true,"description":{"content":"<p>Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights).</p>\n","type":"text/plain"},"key":"access_rights_id","value":null},{"disabled":true,"description":{"content":"<p>Operator avatar. Specify a publicly available image URL.</p>\n","type":"text/plain"},"key":"avatar","value":""},{"disabled":true,"description":{"content":"<p>External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.</p>\n","type":"text/plain"},"key":"external_id","value":""},{"disabled":true,"description":{"content":"<p>First name of operator.</p>\n","type":"text/plain"},"key":"first_name","value":null},{"disabled":true,"description":{"content":"<p>Last name of operator.</p>\n","type":"text/plain"},"key":"last_name","value":null},{"disabled":true,"description":{"content":"<p>Id of operator’s status (see GET operators/statuses).</p>\n","type":"text/plain"},"key":"status_id","value":""}],"variable":[{"type":"any","value":"","key":"id"}]}},"response":[{"id":"1b21f916-b9cc-4bfb-b6f4-31341370d4e3","name":"Successful Response","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/:id","host":["https://api.chat2desk.com"],"path":["v1","operators",":id"],"query":[{"key":"email","value":"","description":"Email of operator.","disabled":true},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights).","disabled":true},{"key":"avatar","value":"","description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":"","description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator.","disabled":true},{"key":"last_name","value":null,"description":"Last name of operator.","disabled":true},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses).","disabled":true}],"variable":[{"key":"id","value":""}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"status\": \"success\"\n}"},{"id":"747f8151-fe03-41c3-8f6a-709647c0448f","name":"error Email has already been taken","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/11111","host":["https://api.chat2desk.com"],"path":["v1","operators","11111"],"query":[{"key":"email","value":"","description":"Email of operator.","disabled":true},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights).","disabled":true},{"key":"avatar","value":"","description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":"","description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator.","disabled":true},{"key":"last_name","value":null,"description":"Last name of operator.","disabled":true},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses).","disabled":true}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"email\": [\n        \"has already been taken\"\n    ]\n}"},{"id":"2d2b1315-e4bd-430b-a8b6-d716de18f2f3","name":"error Access rights not found","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"email","value":"","description":"Email of operator.","disabled":true},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights).","disabled":true},{"key":"avatar","value":null,"description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":null,"description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator.","disabled":true},{"key":"last_name","value":null,"description":"Last name of operator.","disabled":true},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses).","disabled":true}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"access_rights_id\": [\n        {\n            \"error\": \"Access rights not found for this company!\"\n        }\n    ]\n}"},{"id":"75e8aa8e-28bf-4a2e-979e-dcc3d49e36d8","name":"error Status id is not correct","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/operators/","host":["https://api.chat2desk.com"],"path":["v1","operators",""],"query":[{"key":"email","value":"","description":"Email of operator.","disabled":true},{"key":"access_rights_id","value":null,"description":"Access rights ID. Defines operator role in the chat center. Can be Supervisor, Operator, or a custom role (see GET Access rights).","disabled":true},{"key":"avatar","value":null,"description":"Operator avatar. Specify a publicly available image URL.","type":"text","disabled":true},{"key":"external_id","value":null,"description":"External system operator identifier. If you have an operator in another platform or CRM system, you can save the operator ID in the external system in this field.","type":"text","disabled":true},{"key":"first_name","value":null,"description":"First name of operator.","disabled":true},{"key":"last_name","value":null,"description":"Last name of operator.","disabled":true},{"key":"status_id","value":"","description":"Id of operator’s status (see GET operators/statuses).","disabled":true}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"status_id\": [\n        {\n            \"error\": \"This status id is not correct!\"\n        }\n    ]\n}"}],"_postman_id":"410d373b-8322-4d24-80a9-11ba55de86e5"},{"name":"operators/statuses","id":"6baffa53-afb9-4b1c-92bc-ee37079d8c71","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/operators/statuses","description":"<p>Returns a list of available operators’ working statuses.</p>\n","urlObject":{"path":["v1","operators","statuses"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"af32cd41-770e-463d-854c-ebeaa14fc479","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/operators/statuses"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"[\n    {\n        \"id\": 0,\n        \"name\": {\n            \"en\": \"Working\",\n            \"ru\": \"Работает\"\n        }\n    },\n    {\n        \"id\": 1,\n        \"name\": {\n            \"en\": \"Busy\",\n            \"ru\": \"Занят\"\n        }\n    },\n    {\n        \"id\": 2,\n        \"name\": {\n            \"en\": \"Having break\",\n            \"ru\": \"Перерыв\"\n        }\n    },\n    {\n        \"id\": 3,\n        \"name\": {\n            \"en\": \"On training\",\n            \"ru\": \"На обучении\"\n        }\n    },\n    {\n        \"id\": 4,\n        \"name\": {\n            \"en\": \"Tech. brake\",\n            \"ru\": \"Тех. перерыв\"\n        }\n    },\n    {\n        \"id\": 5,\n        \"name\": {\n            \"en\": \"Away on holiday\",\n            \"ru\": \"В отпуске\"\n        }\n    }\n]"}],"_postman_id":"6baffa53-afb9-4b1c-92bc-ee37079d8c71"},{"name":"operators_groups","id":"d58f23ad-11c8-4b07-b067-e4954351d5de","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/operators_groups","description":"<p>Returns a list of operator groups in the System. For operators groups see <em>Settings &gt; Operators</em> section on the site.</p>\n","urlObject":{"path":["v1","operators_groups"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"a92afd0f-097d-4257-9421-0c91c2ff8cfc","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/operators_groups"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 3373,\n            \"name\": \"Group_name\",\n            \"operator_ids\": [\n                261199,\n                255491\n            ]\n        },\n        {\n            \"id\": 3739,\n            \"name\": \"Operators\",\n            \"operator_ids\": [\n                255491,\n                255496,\n                261199,\n                314569\n            ]\n        }\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"d58f23ad-11c8-4b07-b067-e4954351d5de"},{"name":"access rights","id":"0e49bc44-e2d7-4d4c-bb96-f271a3f66696","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"},{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.chat2desk.com/v1/access_rights","description":"<p>Returns a list of your operators (agents) in the System.</p>\n","urlObject":{"path":["v1","access_rights"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"4e05bda9-76a8-4d56-9378-3665c46a92b6","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.chat2desk.com/v1/access_rights"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 55540,\n            \"name\": \"Supervisor\",\n            \"role\": \"supervisor\",\n            \"base_role\": true,\n            \"permissions\": {\n                \"balance\": true,\n                \"dashboard\": true,\n                \"manage_dashboards\": true,\n                \"manage_custom_reports\": true,\n                \"bulk_messanging_and_mass_ops\": true,\n                \"sales_tunnel\": true,\n                \"account_settings\": true,\n                \"macroses\": true,\n                \"workmode\": true,\n                \"auto_answer\": true,\n                \"long_answer_notification\": true,\n                \"auto_closing\": true,\n                \"offline_period\": true,\n                \"auto_assignment_of_chats\": true,\n                \"broadcast_to_tg\": true,\n                \"settings_other\": true,\n                \"operators\": true,\n                \"create_and_manage_operators\": false,\n                \"customization\": true,\n                \"accounts\": true,\n                \"online_chat\": true,\n                \"widget\": true,\n                \"templates\": true,\n                \"tags_and_requests\": true,\n                \"self_service_menu\": true,\n                \"chat_bot\": true,\n                \"api\": true,\n                \"rating\": true,\n                \"integrations\": true,\n                \"smart_scripts\": true,\n                \"url_tracking\": true,\n                \"blacklist\": true,\n                \"info\": true,\n                \"news\": true,\n                \"widget_v2\": true,\n                \"billing_thresholds\": true,\n                \"assign_dialog\": true,\n                \"export_dialog\": true,\n                \"manage_status\": true,\n                \"manage_avatar\": true,\n                \"tg_application\": true,\n                \"close_dialog\": true,\n                \"manage_requests\": true,\n                \"attach_tags_to_client\": true,\n                \"attach_tags_to_request\": true,\n                \"manage_comments\": true,\n                \"add_to_blacklist\": true,\n                \"edit_client_phone\": true,\n                \"write_first\": true,\n                \"realtime_dashboard\": true,\n                \"system_messages\": true,\n                \"tickets_view\": false,\n                \"tickets_create_and_edit\": false,\n                \"tickets_partial_edit\": true,\n                \"tickets_delete\": true,\n                \"enable_technical_support_access\": true,\n                \"manage_user_sessions\": false,\n                \"group_clients\": true,\n                \"manage_channels\": false,\n                \"create_and_manage_messengers\": false,\n                \"pin_messages\": false,\n                \"telephony\": true,\n                \"telephony_call\": false\n            }\n        },\n        {\n            \"id\": 111338,\n            \"name\": \"Оператор\",\n            \"role\": \"operator\",\n            \"base_role\": true,\n            \"permissions\": {\n                \"balance\": false,\n                \"dashboard\": true,\n                \"manage_dashboards\": true,\n                \"manage_custom_reports\": true,\n                \"bulk_messanging_and_mass_ops\": false,\n                \"sales_tunnel\": true,\n                \"account_settings\": true,\n                \"macroses\": true,\n                \"workmode\": true,\n                \"auto_answer\": true,\n                \"long_answer_notification\": true,\n                \"auto_closing\": true,\n                \"offline_period\": true,\n                \"auto_assignment_of_chats\": true,\n                \"broadcast_to_tg\": true,\n                \"settings_other\": true,\n                \"operators\": true,\n                \"create_and_manage_operators\": false,\n                \"customization\": true,\n                \"accounts\": true,\n                \"online_chat\": true,\n                \"widget\": true,\n                \"templates\": true,\n                \"tags_and_requests\": true,\n                \"self_service_menu\": true,\n                \"chat_bot\": true,\n                \"api\": true,\n                \"rating\": true,\n                \"integrations\": true,\n                \"smart_scripts\": true,\n                \"url_tracking\": true,\n                \"blacklist\": true,\n                \"info\": true,\n                \"news\": true,\n                \"widget_v2\": true,\n                \"billing_thresholds\": false,\n                \"assign_dialog\": true,\n                \"export_dialog\": true,\n                \"manage_status\": true,\n                \"manage_avatar\": true,\n                \"tg_application\": true,\n                \"close_dialog\": true,\n                \"manage_requests\": true,\n                \"attach_tags_to_client\": true,\n                \"attach_tags_to_request\": true,\n                \"manage_comments\": true,\n                \"add_to_blacklist\": true,\n                \"edit_client_phone\": true,\n                \"write_first\": true,\n                \"realtime_dashboard\": true,\n                \"system_messages\": true,\n                \"tickets_view\": true,\n                \"tickets_create_and_edit\": true,\n                \"tickets_partial_edit\": true,\n                \"tickets_delete\": true,\n                \"enable_technical_support_access\": false,\n                \"manage_user_sessions\": false,\n                \"group_clients\": false,\n                \"manage_channels\": false,\n                \"create_and_manage_messengers\": false,\n                \"pin_messages\": false,\n                \"telephony\": false,\n                \"telephony_call\": false\n            }\n        },\n        {\n            \"id\": 153611,\n            \"name\": \"Custom Role\",\n            \"role\": \"operator\",\n            \"base_role\": null,\n            \"permissions\": {\n                \"balance\": false,\n                \"dashboard\": false,\n                \"manage_dashboards\": false,\n                \"manage_custom_reports\": false,\n                \"bulk_messanging_and_mass_ops\": false,\n                \"sales_tunnel\": false,\n                \"account_settings\": false,\n                \"macroses\": false,\n                \"workmode\": false,\n                \"auto_answer\": false,\n                \"long_answer_notification\": false,\n                \"auto_closing\": false,\n                \"offline_period\": false,\n                \"auto_assignment_of_chats\": false,\n                \"broadcast_to_tg\": false,\n                \"settings_other\": false,\n                \"operators\": false,\n                \"create_and_manage_operators\": false,\n                \"customization\": false,\n                \"accounts\": false,\n                \"online_chat\": false,\n                \"widget\": false,\n                \"templates\": false,\n                \"tags_and_requests\": false,\n                \"self_service_menu\": false,\n                \"chat_bot\": false,\n                \"api\": false,\n                \"rating\": false,\n                \"integrations\": false,\n                \"smart_scripts\": false,\n                \"url_tracking\": false,\n                \"blacklist\": false,\n                \"info\": false,\n                \"news\": false,\n                \"widget_v2\": false,\n                \"billing_thresholds\": false,\n                \"assign_dialog\": false,\n                \"export_dialog\": false,\n                \"manage_status\": false,\n                \"manage_avatar\": false,\n                \"tg_application\": false,\n                \"close_dialog\": false,\n                \"manage_requests\": false,\n                \"attach_tags_to_client\": false,\n                \"attach_tags_to_request\": false,\n                \"manage_comments\": false,\n                \"add_to_blacklist\": false,\n                \"edit_client_phone\": false,\n                \"write_first\": false,\n                \"realtime_dashboard\": false,\n                \"system_messages\": false,\n                \"tickets_view\": false,\n                \"tickets_create_and_edit\": false,\n                \"tickets_partial_edit\": false,\n                \"tickets_delete\": false,\n                \"enable_technical_support_access\": false,\n                \"manage_user_sessions\": false,\n                \"group_clients\": false,\n                \"manage_channels\": false,\n                \"create_and_manage_messengers\": false,\n                \"pin_messages\": false,\n                \"telephony\": false,\n                \"telephony_call\": false\n            }\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"0e49bc44-e2d7-4d4c-bb96-f271a3f66696"},{"name":"access rights/<id>","id":"48ec1a07-5a68-4c80-888a-c7c0c1899bb5","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"},{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.chat2desk.com/v1/access_rights/:id","description":"<p>Returns a list of your operators (agents) in the System.</p>\n","urlObject":{"path":["v1","access_rights",":id"],"host":["https://api.chat2desk.com"],"query":[],"variable":[{"id":"a1aac853-78e6-472c-bcba-d3046a9b7eed","type":"any","value":"","key":"id"}]}},"response":[{"id":"a9e274d4-a460-4b82-ace7-004fa57f6ae3","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.chat2desk.com/v1/access_rights/111338"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": 111338,\n        \"name\": \"Оператор\",\n        \"role\": \"operator\",\n        \"base_role\": true,\n        \"permissions\": {\n            \"balance\": false,\n            \"dashboard\": true,\n            \"manage_dashboards\": true,\n            \"manage_custom_reports\": true,\n            \"bulk_messanging_and_mass_ops\": false,\n            \"sales_tunnel\": true,\n            \"account_settings\": true,\n            \"macroses\": true,\n            \"workmode\": true,\n            \"auto_answer\": true,\n            \"long_answer_notification\": true,\n            \"auto_closing\": true,\n            \"offline_period\": true,\n            \"auto_assignment_of_chats\": true,\n            \"broadcast_to_tg\": true,\n            \"settings_other\": true,\n            \"operators\": true,\n            \"create_and_manage_operators\": false,\n            \"customization\": true,\n            \"accounts\": true,\n            \"online_chat\": true,\n            \"widget\": true,\n            \"templates\": true,\n            \"tags_and_requests\": true,\n            \"self_service_menu\": true,\n            \"chat_bot\": true,\n            \"api\": true,\n            \"rating\": true,\n            \"integrations\": true,\n            \"smart_scripts\": true,\n            \"url_tracking\": true,\n            \"blacklist\": true,\n            \"info\": true,\n            \"news\": true,\n            \"widget_v2\": true,\n            \"billing_thresholds\": false,\n            \"assign_dialog\": true,\n            \"export_dialog\": true,\n            \"manage_status\": true,\n            \"manage_avatar\": true,\n            \"tg_application\": true,\n            \"close_dialog\": true,\n            \"manage_requests\": true,\n            \"attach_tags_to_client\": true,\n            \"attach_tags_to_request\": true,\n            \"manage_comments\": true,\n            \"add_to_blacklist\": true,\n            \"edit_client_phone\": true,\n            \"write_first\": true,\n            \"realtime_dashboard\": true,\n            \"system_messages\": true,\n            \"tickets_view\": true,\n            \"tickets_create_and_edit\": true,\n            \"tickets_partial_edit\": true,\n            \"tickets_delete\": true,\n            \"enable_technical_support_access\": false,\n            \"manage_user_sessions\": false,\n            \"group_clients\": false,\n            \"manage_channels\": false,\n            \"create_and_manage_messengers\": false,\n            \"pin_messages\": false,\n            \"telephony\": false,\n            \"telephony_call\": false\n        }\n    },\n    \"status\": \"success\"\n}"},{"id":"4b66c11c-b7be-4988-9d86-e6c85cd81794","name":"error Access rights not found","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.chat2desk.com/v1/access_rights/11"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"message\": \"not_found\",\n    \"errors\": {\n        \"text\": \"Access rights id #11 not found\"\n    },\n    \"status\": \"error\"\n}"}],"_postman_id":"48ec1a07-5a68-4c80-888a-c7c0c1899bb5"}],"id":"dc3c3a54-0cd0-4182-848c-a2ef5d42c528","description":"<p>Working with operators (agents) and Access rights.</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"71497a8f-1a63-4fbd-b230-adc2e1bdbfc7"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"dffb3b5a-181f-41d8-adb3-8db541c79b95"}}],"_postman_id":"dc3c3a54-0cd0-4182-848c-a2ef5d42c528"},{"name":"Tags","item":[{"name":"tags","id":"4679eb81-5d87-4804-ade2-609dca8302bf","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Get this token in Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/tags/","description":"<p>Returns a list of your tags with their info like label, description and tag group. These tags can be applied both to clients and to requests (see <a href=\"#intro\">TERMS</a> for <em>request</em>).</p>\n","urlObject":{"path":["v1","tags",""],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":""}],"variable":[]}},"response":[{"id":"b6e728bb-ff93-4f8e-bcbc-0c24d319b25f","name":"tags","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Get this token in Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/tags/","host":["https://api.chat2desk.com"],"path":["v1","tags",""],"query":[{"key":"limit","value":"","description":"Number of records returned (maximum is 200, default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true}]}},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[{'description': '01',\n  'group_id': 1425,\n  'group_name': 'Tags',\n  'id': 5931,\n  'label': 'Tag 01'}]"}],"_postman_id":"4679eb81-5d87-4804-ade2-609dca8302bf"},{"name":"tags/<id>","id":"ad610b13-100a-43ce-9099-f5deeb807394","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Get this token in Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/tags/103429","description":"<p>Returns an info on a tag specified. 103429 here is an example of tag id.</p>\n","urlObject":{"path":["v1","tags","103429"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"883b3569-ff54-4de5-91f7-7d6d300e4f69","name":"tags/<id>","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Get this token in Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/tags/103429"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{'description': '01',\n 'group_id': 1425,\n 'group_name': 'Tags',\n 'id': 5931,\n 'label': 'Tag 01'}"}],"_postman_id":"ad610b13-100a-43ce-9099-f5deeb807394"},{"name":"tags","id":"42adde4c-a4f1-4d8f-b80c-ef7d7e034e39","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{   \n    \"tag_group_id\": 1,\n    \"tag_label\": \"ABC1\",\n    \"tag_description\": \"My tag description\",\n    \"tag_bg_color\": \"5b9ee6\",\n    \"tag_text_color\": \"ffffff\",\n    \"order_show\": 5\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tags","description":"<p>Creates a new tag. Tags can also be created manually on the site in <em>Settings &gt; Tags</em> section.</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:\n{\n\"tag_group_id\": 1,\n\"tag_label\": \"ABC1\",\n\"tag_description\": \"My tag description\",\n\"tag_bg_color\": \"5b9ee6\",\n\"tag_text_color\": \"ffffff\",\n\"order_show\": 5\n}</p>\n<ul>\n<li>tag_group_id – id of tag group inside which the new tag will be created. Every tag should belong to a group.</li>\n<li>tag_label – tag label (ticket), 20 chars max.</li>\n<li>tag_description – tag description.</li>\n<li>tag_bg_color – tag background color number.</li>\n<li>tag_text_color – tag foreground color number.</li>\n<li>order_show – is used to sort tags in UI on the site.</li>\n</ul>\n","urlObject":{"path":["v1","tags"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"557baeef-6808-4d61-915f-c7118d05ccc3","name":"tags","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{   \n    \"tag_group_id\": 67504,\n    \"tag_label\": \"ABC1\",\n    \"tag_description\": \"My tag description\",\n    \"tag_bg_color\": \"5b9ee6\",\n    \"tag_text_color\": \"ffffff\",\n    \"order_show\": 5\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tags"},"status":"Created","code":201,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 202569,\n            \"label\": \"ABC1\",\n            \"description\": \"My tag description\",\n            \"group_id\": 67504,\n            \"group_name\": \"1\"\n        }\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"42adde4c-a4f1-4d8f-b80c-ef7d7e034e39"},{"name":"tags/assign_to","id":"ffe91b51-806b-47fd-a676-89c09c3d051f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"},{"key":"Content-Type","value":"application/json"}],"body":{"mode":"raw","raw":"{\n    \"tag_ids\": [103429,103430],\n    \"assignee_type\": \"request\",\n    \"assignee_id\": \"165505634\"\n}"},"url":"https://api.chat2desk.com/v1/tags/assign_to","description":"<p>Assigns one or more tags to a client or a request.</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:<br />{<br />\"tag_ids\": [1,2],<br />\"assignee_type\": \"client\" or \"request\",<br />\"assignee_id\": \"1020\"<br />}</p>\n<ul>\n<li>tag_ids – list of tags ids. See <code>tags (GET)</code>.</li>\n<li>assignee_type – to what you want to assign specified tags: to a client or to a request.</li>\n<li>assignee_id – id of a client or a request to which you want to assign specified tags.</li>\n</ul>\n","urlObject":{"path":["v1","tags","assign_to"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"51548963-1116-4f14-b7bd-49f6d724346c","name":"tags/assign_to","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"tag_ids\": [\n        103429,\n        103430\n    ],\n    \"assignee_type\": \"request\",\n    \"assignee_id\": \"165505634\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tags/assign_to"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\r\n    \"status\": \"success\"\r\n}"}],"_postman_id":"ffe91b51-806b-47fd-a676-89c09c3d051f"},{"name":"tag_groups","id":"9dfbb673-9067-40ae-92e3-51680c474d17","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"tag_group_name\": \"Tags group 1\",\n    \"order_show\": 1,\n    \"display\": 1\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tag_groups","description":"<p>Creates a new tag group. Tag groups can also be created manually on the site in <em>Settings &gt; Tags</em> section.</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:\n{\n\"tag_group_name\": \"Name of the group\"\n\"order_show\": 5,\n\"display\": 0 or 1\n}</p>\n<ul>\n<li>tag_group_name – name of the group.</li>\n<li>order_show – is used to sort tags in UI on the site.</li>\n<li>display – display (1) or not (0) this tag group in UI when manually editing a client or a request.</li>\n</ul>\n","urlObject":{"path":["v1","tag_groups"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"c16aff7b-0543-44c3-b83e-388d7bd898b3","name":"tag_groups","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"tag_group_name\": \"new_tag_group\",\n    \"order_show\": 1,\n    \"display\": 1\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tag_groups"},"status":"OK","code":200,"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\r\n    \"data\": {\r\n        \"id\": 67552,\r\n        \"group_name\": \"new_tag_group\",\r\n        \"order_show\": 1,\r\n        \"display\": 1\r\n    },\r\n    \"status\": \"success\"\r\n}"}],"_postman_id":"9dfbb673-9067-40ae-92e3-51680c474d17"},{"name":"tags/<id>","id":"0e6895b0-c6f2-40a5-be6a-21cae7ffb32c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"request_id\": 165505634\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tags/103429/delete_from","description":"<p>Deletes a tag from a client or a request. The tag is not deleted from the available tags list.</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:\n{\n\"client_id\": 1020\nor\n\"request_id\": 627172\n}</p>\n<ul>\n<li>client_id – id of a client where you want to delete the specified tag.</li>\n<li>request_id – id of a request where you want to delete the specified tag.</li>\n</ul>\n","urlObject":{"path":["v1","tags","103429","delete_from"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"0e6895b0-c6f2-40a5-be6a-21cae7ffb32c"}],"id":"b8b7af3c-7845-462b-8a91-a652e7c491bb","description":"<p>Working with client's and request's tags.</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"e1415c4a-ecf0-48da-b429-e0a454e911ba"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"a1776567-7575-4ade-9fec-65a16a10afb7"}}],"_postman_id":"b8b7af3c-7845-462b-8a91-a652e7c491bb"},{"name":"Tickets","item":[{"name":"tickets","id":"39c6cc2c-4938-4f8e-973f-b6fe3534623a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/tickets/","description":"<p>Returns a list of your tickets with their info. You can filter the list of tickets by reporter, assignee, status priority and request.</p>\n<p>Some fields in response:</p>\n","urlObject":{"path":["v1","tickets",""],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Ticket status, number from 1 to 4 (see /v1/help/tickets)</p>\n","type":"text/plain"},"key":"status","value":"1"},{"disabled":true,"description":{"content":"<p>Ticket priority, number from 1 to 3 (see /v1/help/tickets)</p>\n","type":"text/plain"},"key":"priority","value":"2"},{"disabled":true,"description":{"content":"<p>ID of the operator assigned for the ticket</p>\n","type":"text/plain"},"key":"assignee_id","value":"110889"},{"disabled":true,"description":{"content":"<p>ID of the operator who last modified the ticket</p>\n","type":"text/plain"},"key":"updater_id","value":"110889"},{"disabled":true,"description":{"content":"<p>ID of the operator who created the ticket</p>\n","type":"text/plain"},"key":"reporter_id","value":"12321"},{"disabled":true,"description":{"content":"<p>ID of request linked to the ticket, only one allowed</p>\n","type":"text/plain"},"key":"request_id","value":"49284"},{"disabled":true,"description":{"content":"<p>Order of records returned (asc, desc). Default is ascending order.</p>\n","type":"text/plain"},"key":"order","value":"asc"},{"disabled":true,"description":{"content":"<p>Number of records returned. Default is 20, maximum is 200.</p>\n","type":"text/plain"},"key":"limit","value":"40"},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list. Default is 0.</p>\n","type":"text/plain"},"key":"offset","value":"80"}],"variable":[]}},"response":[{"id":"1ae0e82c-0976-4184-ae60-e79418b60572","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"API token","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/tickets/","protocol":"https","host":["api","chat2desk","com"],"path":["v1","tickets",""],"query":[{"key":"status","value":"1","description":"Ticket status, number from 1 to 4 (see /v1/help/tickets)","disabled":true},{"key":"priority","value":"2","description":"Ticket priority, number from 1 to 3 (see /v1/help/tickets)","disabled":true},{"key":"assignee_id","value":"110889","description":"ID of the operator assigned for the ticket","disabled":true},{"key":"updater_id","value":"110889","description":"ID of the operator who last modified the ticket","type":"text","disabled":true},{"key":"reporter_id","value":"12321","description":"ID of the operator who created the ticket","disabled":true},{"key":"request_id","value":"49284","description":"ID of request linked to the ticket, only one allowed","type":"text","disabled":true},{"key":"order","value":"asc","description":"Order of records returned (asc, desc). Default is ascending order.","disabled":true},{"key":"limit","value":"40","description":"Number of records returned. Default is 20, maximum is 200.","type":"text","disabled":true},{"key":"offset","value":"80","description":"Offset from the 1st record of the list. Default is 0.","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": \"TICK-1\",\n            \"deadline\": \"2005-07-19T12:00:00Z\",\n            \"summary\": \"Delivery problem\",\n            \"description\": \"Problem with delivery with package 49284 to Mel Gibson\",\n            \"status\": 1,\n            \"priority\": 2,\n            \"created_at\": \"1956-01-03T10:00:00Z\",\n            \"updated_at\": \"1995-05-18T11:00:00Z\",\n            \"assignee_id\": 110889,\n            \"updater_id\": 110889,\n            \"reporter_id\": 12321,\n            \"request_ids\": [\n                \"49284\",\n                \"443556\"\n            ]\n        },\n        {\n            \"id\": \"TICK-2\",\n            \"deadline\": \"2005-07-19T12:00:00Z\",\n            \"summary\": \"Non-compliance with the Pantone color palette\",\n            \"description\": \"A large batch of Malibu Blue paint did not comply with the color palette. The paint had a maroon tint.\",\n            \"status\": 1,\n            \"priority\": 2,\n            \"created_at\": \"1956-01-03T10:00:00Z\",\n            \"updated_at\": \"1995-05-18T11:00:00Z\",\n            \"assignee_id\": 12321,\n            \"updater_id\": 12321,\n            \"reporter_id\": 110889,\n            \"request_ids\": [\n                \"49284\",\n                \"443556\"\n            ]\n        }\n    ],\n    \"meta\": {\n        \"total\": 2,\n        \"limit\": 20,\n        \"offset\": 0\n    },\n    \"status\": \"success\"\n}"},{"id":"be1ddbf6-5237-4e79-b379-5b4381356ad4","name":"Unsuccessful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"API token","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/tickets/?priority=Urgent&status=To do&assignee_id=Catherine&reporter_id=Sophie&updater_id=Mel&request_id=49284, 443556&order=positive&limit=201&offset=next","protocol":"https","host":["api","chat2desk","com"],"path":["v1","tickets",""],"query":[{"key":"priority","value":"Urgent","description":"Ticket status, number from 1 to 4 (see /v1/help/tickets)"},{"key":"status","value":"To do","description":"Ticket priority, number from 1 to 3 (see /v1/help/tickets)"},{"key":"assignee_id","value":"Catherine","description":"ID of the operator assigned for the ticket"},{"key":"reporter_id","value":"Sophie","description":"ID of the operator who created the ticket"},{"key":"updater_id","value":"Mel","description":"ID of the operator who last modified the ticket"},{"key":"request_id","value":"49284, 443556","description":"ID of request linked to the ticket, only one allowed"},{"key":"order","value":"positive","description":"Order of records returned (asc, desc). Default is ascending order."},{"key":"limit","value":"201","description":"Number of records returned. Default is 20, maximum is 200."},{"key":"offset","value":"next","description":"Offset from the 1st record of the list. Default is 0."}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"bad_request\",\n    \"errors\": {\n        \"reporter_id\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"updater_id\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"assignee_id\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"priority\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"status\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"request_id\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"order\": [\n            {\n                \"text\": \"Only 'asc' or 'desc' are allowed.\",\n                \"error\": \"invalid_filter_and_sorting_params\"\n            }\n        ],\n        \"limit\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"offset\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"invalid_filter_and_sorting_params\"\n            }\n        ],\n        \"id\": [\n            {\n                \"text\": \"Parameter 'id' cannot be specified. Use /v1/tickets/<id> instead.\",\n                \"error\": \"invalid_filter_and_sorting_params\"\n            }\n        ]\n    },\n    \"status\": \"error\"\n}"}],"_postman_id":"39c6cc2c-4938-4f8e-973f-b6fe3534623a"},{"name":"tickets/<id>","id":"cce30147-b4d7-45c8-9fd2-2e9f3b52dbe2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/tickets/2","description":"<p>Returns a list of your tickets with their info. You can filter the list of tickets by reporter, assignee, status priority and request.</p>\n<p>Some fields in response:</p>\n","urlObject":{"path":["v1","tickets","2"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"d80d9474-3665-4efb-9a5e-3beb7a2f9490","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/tickets/2"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": \"TICK-2\",\n        \"deadline\": \"2005-07-19T12:00:00Z\",\n        \"summary\": \"Non-compliance with the Pantone color palette\",\n        \"description\": \"A large batch of Malibu Blue paint did not comply with the color palette. The paint had a maroon tint.\",\n        \"status\": 1,\n        \"priority\": 2,\n        \"created_at\": \"1956-01-03T10:00:00Z\",\n        \"updated_at\": \"1995-05-18T11:00:00Z\",\n        \"assignee_id\": 12321,\n        \"updater_id\": 12321,\n        \"reporter_id\": 110889,\n        \"request_ids\": [\n            \"49284\",\n            \"443556\"\n        ]\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"cce30147-b4d7-45c8-9fd2-2e9f3b52dbe2"},{"name":"tickets","id":"92e0e844-bc51-4945-8bc9-0f4322416494","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"summary\": \"Delivery problem\",\n    \"description\": \"Problem with delivery with package 49284 to Mel Gibson\",\n    \"priority\": 2,\n    \"assignee_id\": 110889,\n    \"reporter_id\": 197136,\n    \"deadline\": \"2005-07-19T12:00:00Z\",\n    \"request_ids\": [\n        \"49284\",\n        \"443556\"\n    ],\n    \"status\": 1\n}\n\n/*\n    \"summary\" — Ticket title (up to 255 characters)\n    \"description\" — Ticket description\n    \"priority\" — Ticket priority. Check /v1/help/tickets in Data types and values for available values\n    \"assignee_id\" — (Optional) ID of the operator who will be assigned for the ticket\n    \"reporter_id\" — (Optional) ID of the operator by whom the ticket will be created. If ommited, Administrator will be used.\n    \"deadline\" — (Optional) Deadline date and time in ISO 8601 format\n    \"issue_ids\" — (Optional) Array of request IDs which will be linked to the ticket\n    \"status\" — (Optional) Ticket status. Check /v1/help/tickets in Data types and values for available values. If omitted, \"To do\" will be used.\n*/","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tickets/","description":"<p>Returns a list of your tickets with their info. You can filter the list of tickets by reporter, assignee, status priority and request.</p>\n<p>Some fields in response:</p>\n","urlObject":{"path":["v1","tickets",""],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"43542f81-19bb-4c6e-9037-944d22f894c4","name":"Successful Response","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"summary\": \"Non-compliance with the Pantone color palette\",\n    \"description\": \"A large batch of Malibu Blue paint did not comply with the color palette. The paint had a maroon tint.\",\n    \"priority\": 2,\n    \"reporter_id\": 197136,\n    \"assignee_id\": 12321,\n    \"deadline\": \"2095-07-19T12:00:00Z\",\n    \"request_ids\": [\n        \"49284\",\n        \"443556\"\n    ],\n    \"status\": 1\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tickets/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": \"TICK-1\",\n        \"deadline\": \"2005-07-19T12:00:00Z\",\n        \"summary\": \"Delivery problem\",\n        \"description\": \"Problem with delivery with package 49284 to Mel Gibson\",\n        \"status\": 1,\n        \"priority\": 2,\n        \"created_at\": \"1956-01-03T10:00:00Z\",\n        \"updated_at\": \"1956-01-03T10:00:00Z\",\n        \"assignee_id\": 110889,\n        \"updater_id\": 197136,\n        \"reporter_id\": 197136,\n        \"request_ids\": [\n            \"49284\",\n            \"443556\"\n        ]\n    },\n    \"status\": \"success\"\n}"},{"id":"a0638af0-890d-45f7-a5d2-4e57c920a3d2","name":"Unsuccessful Response","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"description\": \"\",\n    \"priority\": \"major\",\n    \"reporter_id\": 1,\n    \"assignee_id\": 2,\n    \"deadline\": \"yesterday\",\n    \"request_ids\": [\n        \"iOS\",\n        \"android\"\n    ],\n    \"status\": \"to do\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tickets/"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"bad_request\",\n    \"errors\": {\n        \"summary\": [\n            {\n                \"text\": \"Parameter 'summary' cannot be empty and must not exceed 255 characters.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"description\": [\n            {\n                \"text\": \"Parameter 'description' cannot be empty\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"priority\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"status\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"request_ids\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            },\n            {\n                \"text\": \"One of provided request_ids is not found\",\n                \"error\": \"not_found\"\n            }\n        ],\n        \"deadline\": [\n            {\n                \"text\": \"Parameter must be in ISO 8601 format\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"assignee_id\": [\n            {\n                \"text\": \"Not found\",\n                \"error\": \"not_found\"\n            }\n        ],\n        \"reporter_id\": [\n            {\n                \"text\": \"Not found\",\n                \"error\": \"not_found\"\n            }\n        ]\n    },\n    \"status\": \"error\"\n}"}],"_postman_id":"92e0e844-bc51-4945-8bc9-0f4322416494"},{"name":"tickets/<id>","id":"b8f411ba-7eba-4f1c-90bb-6f0acc14ce0a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"summary\": \"URGENT Delivery problem\",\n    \"description\": \"Problem with delivery with package 49284 to Mel Gibson and Sophie Marceau\",\n    \"priority\": 2,\n    \"assignee_id\": 443556,\n    \"deadline\": \"2005-07-19T12:00:00Z\",\n    \"request_ids\": [\n        \"1123\",\n        \"5813\",\n        \"2134\"\n    ],\n    \"status\": 2\n}\n\n\n/*\n    \"summary\" — Ticket title (up to 255 characters)\n    \"description\" — Ticket description\n    \"priority\" — Ticket priority. Check /v1/help/tickets in Data types and values for available values\n    \"assignee_id\" — (Optional) ID of the operator who will be assigned for the ticket\n    \"deadline\" — (Optional) Deadline date and time in ISO 8601 format\n    \"issue_ids\" — (Optional) Array of request IDs which will be linked to the ticket\n    \"status\" — (Optional) Ticket status. Check /v1/help/tickets in Data types and values for available values. If omitted, \"To do\" will be used.\n*/","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tickets/<id>","description":"<p>Returns a list of your tickets with their info. You can filter the list of tickets by reporter, assignee, status priority and request.</p>\n<p>Some fields in response:</p>\n","urlObject":{"path":["v1","tickets","<id>"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"6c8713ce-acb2-4a0b-ae7a-69d69103c5ca","name":"Successful Response","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"summary\": \"URGENT Delivery problem\",\n    \"description\": \"Problem with delivery with package 49284 to Mel Gibson and Sophie Marceau\",\n    \"priority\": 3,\n    \"reporter_id\": 12321,\n    \"assignee_id\": 443556,\n    \"deadline\": \"2005-07-10T12:00:00Z\",\n    \"request_ids\": [\n        \"1123\",\n        \"5813\",\n        \"2134\"\n    ],\n    \"status\": 2\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tickets/<id>"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": \"TICK-1\",\n        \"deadline\": \"2005-07-10T12:00:00Z\",\n        \"summary\": \"URGENT Delivery problem\",\n        \"description\": \"Problem with delivery with package 49284 to Mel Gibson and Sophie Marceau\",\n        \"status\": 2,\n        \"priority\": 3,\n        \"created_at\": \"1956-01-03T10:00:00Z\",\n        \"updated_at\": \"1995-05-18T11:00:00Z\",\n        \"assignee_id\": 443556,\n        \"updater_id\": \"Public API\",\n        \"reporter_id\": \"Public API\",\n        \"request_ids\": [\n            \"1123\",\n            \"5813\",\n            \"2134\"\n        ]\n    },\n    \"status\": \"success\"\n}"},{"id":"044324eb-6b62-4355-8d8b-c7d741951d48","name":"Unsuccessful Response","originalRequest":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"description\": \"\",\n    \"priority\": \"major\",\n    \"reporter_id\": 1,\n    \"assignee_id\": 2,\n    \"deadline\": \"yesterday\",\n    \"request_ids\": [\n        \"iOS\",\n        \"android\"\n    ],\n    \"status\": \"to do\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/tickets/<id>"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"bad_request\",\n    \"errors\": {\n        \"summary\": [\n            {\n                \"text\": \"Parameter must not exceed 255 characters.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],        \n        \"priority\": [\n            {\n                \"text\": \"Parameter must be a numeric value between 1 and 3.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"status\": [\n            {\n                \"text\": \"Parameter must be a numeric value between 1 and 4.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"request_ids\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            },\n            {\n                \"text\": \"One of provided request_ids is not found\",\n                \"error\": \"not_found\"\n            }\n        ],\n        \"deadline\": [\n            {\n                \"text\": \"Parameter must be in ISO 8601 format\",\n                \"error\": \"unsupported_value\"\n            },\n            {\n                \"text\": \"Parameter must be later than the current date\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"description\": [\n            {\n                \"text\": \"Parameter cannot be empty.\",\n                \"error\": \"unsupported_value\"\n            }\n        ],\n        \"assignee_id\": [\n            {\n                \"text\": \"Parameter must be a numeric value.\",\n                \"error\": \"unsupported_value\"\n            },\n            {\n                \"text\": \"Not found\",\n                \"error\": \"not_found\"\n            }\n        ]\n    },\n    \"status\": \"error\"\n}"}],"_postman_id":"b8f411ba-7eba-4f1c-90bb-6f0acc14ce0a"},{"name":"tickets/<id>","id":"9eb054ab-ce9f-4f7a-bacf-c4c7464572c6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/tickets/2","description":"<p>Deletes specified webhook.<br />222421 here is an example of webhook id.</p>\n","urlObject":{"path":["v1","tickets","2"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"8be5390c-63f8-4227-bc61-e7e38f309002","name":"Successful Response","originalRequest":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/tickets/{id}"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"success\"\n}"},{"id":"ead52db2-03d6-4544-83b3-4f1f84f27966","name":"Unsuccessful Response","originalRequest":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/tickets/{id}"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"bad_request\",\n    \"errors\": {\n        \"text\": \"Ticket #1245654 not found\",\n        \"error\": \"not_found\"\n    },\n    \"status\": \"error\"\n}"}],"_postman_id":"9eb054ab-ce9f-4f7a-bacf-c4c7464572c6"}],"id":"950efef1-40eb-47aa-936a-4eff7d43ce01","description":"<p>Working with Tickets</p>\n","_postman_id":"950efef1-40eb-47aa-936a-4eff7d43ce01"},{"name":"Templates","item":[{"name":"templates","id":"c8734159-606e-4913-8b48-3d4ee12c7ac0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates","urlObject":{"path":["v1","templates"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":null},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":null}],"variable":[]}},"response":[{"id":"07de73b5-dfdc-4efa-bf0a-b6917efe9b3e","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":"https://api.chat2desk.com/v1/templates/"},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 1,\n            \"shortcut\": \"universe\",\n            \"text\": \"42\",\n            \"name\": \"Ultimate Question\",\n            \"file\": \"https://upload.wikimedia.org/wikipedia/commons/5/56/Answer_to_Life.png\",\n            \"group_id\": 1,\n            \"type\": \"common\",\n            \"user_id\": null,\n            \"created\": \"1979-10-12T20:29:36 UTC\"\n        },\n        {\n            \"id\": 2,\n            \"shortcut\": \"off\",\n            \"text\": \"Have you tried turning it off and on again?\",\n            \"name\": \"first question\",\n            \"file\": \"https://cdn.comedy.co.uk/images/library/people/180x200/t/the_it_crowd_roy.jpg\",\n            \"group_id\": 1,\n            \"type\": \"common\",\n            \"user_id\": null,\n            \"created\": \"2006-02-03T16:57:00 UTC\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 2,\n        \"limit\": 20,\n        \"offset\": 0\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"c8734159-606e-4913-8b48-3d4ee12c7ac0"},{"name":"templates/<id>","id":"860a968d-5e13-40b2-ba15-20ccc199fb5a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates/1","urlObject":{"path":["v1","templates","1"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"f703eada-7440-4306-bbda-7eed43a4b64b","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates/1"},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": 1,\n        \"shortcut\": \"universe\",\n        \"text\": \"42\",\n        \"name\": \"The Answer to the Ultimate Question of Life, The Universe, and Everything\",\n        \"file\": \"https://upload.wikimedia.org/wikipedia/commons/5/56/Answer_to_Life.png\",\n        \"group_id\": 2,\n        \"type\": \"common\",\n        \"user_id\": null,\n        \"created\": \"1979-10-12T20:29:36 UTC\"\n    },\n    \"status\": \"success\"\n}"},{"id":"295bd13c-2c17-4f11-baca-1b6e3bfae6ad","name":"Unsuccesful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates/999"},"status":"Not Found","code":404,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"not_found\",\n    \"errors\": \"Template #999 not found\",\n    \"status\": \"error\"\n}"}],"_postman_id":"860a968d-5e13-40b2-ba15-20ccc199fb5a"},{"name":"templates","id":"c3005fa8-996d-497c-b7f2-7438a5f56eb6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"shortcut\": \"universe\",\n    \"text\": \"42\",\n    \"name\": \"Ultimate Question\",\n    \"file\": \"https://upload.wikimedia.org/wikipedia/commons/5/56/Answer_to_Life.png\",\n    \"group_id\": 1, // Either the group ID or the user ID must be provided. Specifying both is not allowed\n    \"user_id\": 1 // Either the group ID or the user ID must be provided. Specifying both is not allowed\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/templates","description":"<p>Шаблон не может одновременно принадлежать пользователю и быть в группе</p>\n","urlObject":{"path":["v1","templates"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"c6eddee7-c620-4a76-9c54-4616812beea4","name":"Successful Response","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"shortcut\": \"universe\",\n    \"text\": \"42\",\n    \"name\": \"Ultimate Question\",\n    \"file\": \"https://upload.wikimedia.org/wikipedia/commons/5/56/Answer_to_Life.png\",\n    \"group_id\": 1\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/templates"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": 185973,\n        \"shortcut\": \"universe\",\n        \"text\": \"42\",\n        \"name\": \"Ultimate Question\",\n        \"file\": \"https://storage-test7.chat2desk.com/companies/company_1/templates/2024-10/b0ffbf0f2e37046ff081.png\",\n        \"group_id\": 1,\n        \"type\": \"common\",\n        \"user_id\": null,\n        \"created\": \"2024-10-03T21:28:57 UTC\"\n    },\n    \"status\": \"success\"\n}"},{"id":"4e6d5270-61bb-4c99-98b7-d182906be464","name":"Unsuccessful Response","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"shortcut\": \"universe\",\n    \"text\": \"42\",\n    \"name\": \"The Answer to the Ultimate Question of Life, The Universe, and Everything\",\n    \"file\": \"https://upload.wikimedia.org/wikipedia/commons/5/56/Answer_to_Life.png\",\n    \"group_id\": 1,\n    \"user_id\": 1\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/templates"},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"name\": [\n        \"Parameter 'name' cannot be empty and must not exceed 60 characters.\"\n    ],\n    \"group_id\": [\n        \"Cannot specify both groups_template_id and user_id\"\n    ],\n    \"user_id\": [\n        \"Cannot specify both groups_template_id and user_id\"\n    ]\n}"}],"_postman_id":"c3005fa8-996d-497c-b7f2-7438a5f56eb6"},{"name":"templates/<id>","id":"2c2ce7e3-f031-4750-9b24-36248b357a8a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"shortcut\": \"universe\",\n    \"text\": \"42\",\n    \"name\": \"Ultimate Question\",\n    \"file\": \"https://upload.wikimedia.org/wikipedia/commons/5/56/Answer_to_Life.png\",\n    \"group_id\": 1, // Either the group ID or the user ID must be provided. Specifying both is not allowed\n    \"user_id\": 1 // Either the group ID or the user ID must be provided. Specifying both is not allowed\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/templates/1","description":"<p>Шаблон не может одновременно принадлежать пользователю и быть в группе</p>\n","urlObject":{"path":["v1","templates","1"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"2c2ce7e3-f031-4750-9b24-36248b357a8a"},{"name":"templates/<id>","id":"50c9ff84-6780-4808-9631-ecaee4bfbccd","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates/1","urlObject":{"path":["v1","templates","1"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"50c9ff84-6780-4808-9631-ecaee4bfbccd"},{"name":"templates_groups","id":"ba313939-5b1e-4f44-aa75-fd2f974232c2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates_groups","urlObject":{"path":["v1","templates_groups"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":null},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":null}],"variable":[]}},"response":[],"_postman_id":"ba313939-5b1e-4f44-aa75-fd2f974232c2"},{"name":"templates_groups/<id>","id":"ca36ed65-032d-4202-8699-c81d90d96bdd","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates_groups/1","urlObject":{"path":["v1","templates_groups","1"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"ca36ed65-032d-4202-8699-c81d90d96bdd"},{"name":"templates_groups","id":"275a0a63-33c6-4e28-8b36-33a2493561b3","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"name\": \"name\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/templates_groups","urlObject":{"path":["v1","templates_groups"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"275a0a63-33c6-4e28-8b36-33a2493561b3"},{"name":"templates_groups/<id>","id":"73b7b86e-8cb5-42c7-9178-2f2a64bc4c99","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"name\": \"name\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/templates_groups/1","urlObject":{"path":["v1","templates_groups","1"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"73b7b86e-8cb5-42c7-9178-2f2a64bc4c99"},{"name":"templates_groups/<id>","id":"d7d64de2-4491-41fc-8ff5-bece0336d4c2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/templates_groups/15","urlObject":{"path":["v1","templates_groups","15"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"d7d64de2-4491-41fc-8ff5-bece0336d4c2"}],"id":"ae23093a-e5a1-4c70-8811-3d72a5d9a80d","_postman_id":"ae23093a-e5a1-4c70-8811-3d72a5d9a80d","description":""},{"name":"Self-service menu","item":[{"name":"scenarios","id":"9c5634f5-48cf-41d2-baa7-3f4290d58d83","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"channel_id\": 44413\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/scenarios/menu_items","description":"<p>Returns a list of available self-service menu items. Self-service menu is a set of commands which your client can select in messenger to receive predefined replies. In messengers that support buttons, the menu can be shown using them. See <em>Settings &gt; Self-service menu</em> section on the site).</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:</p>\n<p>{\n    \"channel_id\": 57270\n}</p>\n<ul>\n<li>channel_id — (optional) id of a channel. Self-service menu is different for each channel.</li>\n</ul>\n<p>Some fields in the results:</p>\n<ul>\n<li>command – quick command for a client to call this menu item from the messenger.</li>\n<li>parentID – id of parent menu item. If the current menu item is root item, <em>null</em> is returned.</li>\n<li>position – position of current menu item at it’s level.</li>\n<li>level – level of current menu item.</li>\n<li>url – url to call when this menu item is chosen by a client.</li>\n<li>url_enabled – if equals 1, then the system will send back to the client the text response that above url returns.</li>\n<li>assign_id – if not <em>null</em>, then the chat with the client will be assigned to specified operator (if not assigned yet).</li>\n<li>image – link to image or PDF which is sent when this menu item is chosen.</li>\n<li>tags – an array of tags to assign or remove from the client and request when this menu item is chosen. See <em>Settings &gt; Self service menu</em> section on the site.</li>\n<li>smart_method_name – a name of our built-in Python script to call when this menu item is chosen by the client. In the script this function should be inside class <em>Handler</em> and have such arguments: self, input_data, c2d. Name of the function in the script should be as specified here plus \"_handler\" at the end.\nExample: <em>def macro_call_handler(self, input_data, c2d)</em>.</li>\n</ul>\n","urlObject":{"path":["v1","scenarios","menu_items"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"bf45f654-b069-4f7f-90bc-79985bf4d76f","name":"scenarios","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"{\n    \"channel_id\": 44413\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/scenarios/menu_items"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"[{'assign_id': None,\n  'assign_subject': None,\n  'channelID': 21085,\n  'command': 'End',\n  'id': 61528,\n  'image': None,\n  'level': 1,\n  'name': 'End this chat',\n  'parentID': None,\n  'position': 1,\n  'smart_method_name': None,\n  'tags': [],\n  'text': 'See you!',\n  'url': None,\n  'url_enabled': 0}]"}],"_postman_id":"9c5634f5-48cf-41d2-baa7-3f4290d58d83"},{"name":"scenarios","id":"143131ce-5b3f-4011-a62b-2205facf9e7c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","type":"text","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"client_id\":17340089,\n    \"menu_item_id\":179617\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/scenarios/send_menu_item","description":"<p>Sends self-service menu item to a client. \nSelf-service menu is a set of commands which your client can select in messenger to receive predefined replies. In messengers that support buttons, the menu can be shown using them. See <em>Settings &gt; Self-service menu</em> section on the site).</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Example:\n{\n    \"client_id\":17340089,\n    \"menu_item_id\":179617\n}</p>\n<ul>\n<li>client_id — id of a client to whom to send the specified menu item.</li>\n<li>menu_item_id — a menu item id to send to specified client. If omitted, root menu item from last client message channel will be sent.</li>\n</ul>\n","urlObject":{"path":["v1","scenarios","send_menu_item"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"143131ce-5b3f-4011-a62b-2205facf9e7c"}],"id":"3296344a-a419-482a-ab84-a96e7913441e","description":"<p>Working with self-service menu items.</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"040d69f1-3a5c-4ee6-839c-c5b4075e5603"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"e9a58a49-1631-40db-a9e4-ed5634f2f657"}}],"_postman_id":"3296344a-a419-482a-ab84-a96e7913441e"},{"name":"Data types and values","item":[{"name":"api_modes","id":"ab301ff4-3cc1-4cdb-bd3d-d270e34794e6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/help/api_modes","description":"<p>Returns a list of available API access levels.</p>\n","urlObject":{"path":["v1","help","api_modes"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"14c6a840-8434-4764-814b-3da9e4fe3811","name":"api_modes","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/help/api_modes"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:07:13 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"8b8e6a580b47b07f7305f7a53dc2ab3f\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"b05ef3fe-d6ac-4f48-9616-7b47525f0d4e"},{"key":"X-Runtime","value":"0.016125"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"name\": \"locked\",\n            \"description\": \"translation missing: ru.modes.locked\"\n        },\n        {\n            \"name\": \"demo\",\n            \"description\": \"10000 requests per month\"\n        },\n        {\n            \"name\": \"normal\",\n            \"description\": \"250000 requests per month\"\n        },\n        {\n            \"name\": \"unlimited\",\n            \"description\": \"unlimited requests per month\"\n        }\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"ab301ff4-3cc1-4cdb-bd3d-d270e34794e6"},{"name":"transports","id":"cf4da9fa-daa3-4e2f-81a5-6ee628db6ebb","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/help/transports","description":"<p>Returns a list of available <em>transports</em> (see <a href=\"#intro\">TERMS</a>) and their supported attachments.</p>\n","urlObject":{"path":["v1","help","transports"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"d2942577-3ae4-43e9-8213-4c35f88c825c","name":"transports","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/help/transports"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:12:33 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"3711d38eb933b7afe132a28268882e7c\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"9c71e248-8c62-4da7-a9f4-93b7cb56b050"},{"key":"X-Runtime","value":"0.040598"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"whatsapp\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"wa_clickatell\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"viber\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"viber_business\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"viber_public\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"viber_tr\": {\n            \"from_client\": {\n                \"text\": \"no\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"yandex_dialogs\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"wa_infobip\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"wa_cm\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"wa_tr\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"wa_wavy\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"wa_botmaker\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"viber_infobip\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"wa_dialog\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"telegram\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"sms\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"facebook\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"vk\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"external\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"widget\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"insta_i2crm\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"ok\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"skype\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"email\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"wechat\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"insta_local\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"yes\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"tg_user\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"yes\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"yes\",\n                \"pdf\": \"yes\",\n                \"location\": \"no\"\n            }\n        },\n        \"vox_implant\": {\n            \"from_client\": {\n                \"text\": \"no\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"no\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"sms_infobip\": {\n            \"from_client\": {\n                \"text\": \"no\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"no\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        },\n        \"insta_official\": {\n            \"from_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"yes\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            },\n            \"to_client\": {\n                \"text\": \"yes\",\n                \"image\": \"yes\",\n                \"audio\": \"no\",\n                \"video\": \"no\",\n                \"pdf\": \"no\",\n                \"location\": \"no\"\n            }\n        }\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"cf4da9fa-daa3-4e2f-81a5-6ee628db6ebb"},{"name":"message_types","id":"12233a0d-25cd-4bf6-8b7f-8254ac13c70a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/help/message_types","description":"<p>Returns a list of available message types.</p>\n","urlObject":{"path":["v1","help","message_types"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"d58ac962-caf3-4165-822d-c0c296b88812","name":"message_types","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/help/message_types"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:19:56 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"a23942ed01800b17ae8899177abe74df\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"8b4640ee-784c-471b-9aaa-4a1c81561992"},{"key":"X-Runtime","value":"0.007803"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": \"system\",\n            \"description\": \"System message to client\"\n        },\n        {\n            \"id\": \"autoreply\",\n            \"description\": \"Auto message\"\n        },\n        {\n            \"id\": \"to_client\",\n            \"description\": \"Message for client\"\n        },\n        {\n            \"id\": \"from_client\",\n            \"description\": \"Message from client\"\n        },\n        {\n            \"id\": \"comment\",\n            \"description\": \"translation missing: ru.message_types.comment\"\n        }\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"12233a0d-25cd-4bf6-8b7f-8254ac13c70a"},{"name":"dialog_states","id":"2ea5e8cd-28e0-417b-a034-f4e2bb5dbfe1","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/help/dialog_states","description":"<p>Returns a list of available dialog states.</p>\n","urlObject":{"path":["v1","help","dialog_states"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"cc673ed4-8854-4b3d-9ebe-44ac98e09311","name":"dialog_states","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/help/dialog_states"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:20:55 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"ddc81200666bef412099cfd2dbddcdee\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"6ddcb2d5-92e9-4528-acc8-0a4ae0ef4217"},{"key":"X-Runtime","value":"0.008093"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        \"open\",\n        \"closed\"\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"2ea5e8cd-28e0-417b-a034-f4e2bb5dbfe1"},{"name":"roles","id":"37da91da-1b60-44a1-a943-4c0b18b7c0af","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/help/roles","description":"<p>Returns a list of available operator (agent) roles.</p>\n","urlObject":{"path":["v1","help","roles"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"31223501-8a5c-43cd-908d-f6913a4949d4","name":"roles","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":{"raw":"https://api.chat2desk.com/v1/help/roles?=","host":["https://api.chat2desk.com"],"path":["v1","help","roles"],"query":[{"key":"","value":""}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:22:13 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"1cdc01c70e76fc4504d3e112dcdb1ac0\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"1026c069-7441-4436-9754-f4b3fb0dc8b6"},{"key":"X-Runtime","value":"0.024896"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        \"unconfirmed\",\n        \"operator\",\n        \"supervisor\",\n        \"admin\",\n        \"disabled\",\n        \"deleted\"\n    ],\n    \"status\": \"success\"\n}"}],"_postman_id":"37da91da-1b60-44a1-a943-4c0b18b7c0af"},{"name":"tickets","id":"c1828b23-9e34-4b1b-9b7d-e49c134bb258","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/help/tickets","urlObject":{"path":["v1","help","tickets"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"0e3b0cad-3bd2-4cc7-b930-f0f2d8a883b8","name":"tickets","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","type":"text"}],"url":"https://api.chat2desk.com/v1/help/tickets"},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"status list\": [\n            {\n                \"id\": 1,\n                \"name\": \"To do\"\n            },\n            {\n                \"id\": 2,\n                \"name\": \"In Progress\"\n            },\n            {\n                \"id\": 3,\n                \"name\": \"Waiting\"\n            },\n            {\n                \"id\": 4,\n                \"name\": \"Closed\"\n            }\n        ],\n        \"priority list\": [\n            {\n                \"id\": 1,\n                \"name\": \"Minor\"\n            },\n            {\n                \"id\": 2,\n                \"name\": \"Normal\"\n            },\n            {\n                \"id\": 3,\n                \"name\": \"Major\"\n            }\n        ]\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"c1828b23-9e34-4b1b-9b7d-e49c134bb258"},{"name":"countries","id":"58f4049a-fbc2-4208-b296-1b741ffd9c38","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://api.chat2desk.com/v1/countries","description":"<p>Returns a list of available countries in the System. This list is used to display in client's infocard on the site based on client's mobile number (where known).</p>\n","urlObject":{"path":["v1","countries"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":null},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":null}],"variable":[]}},"response":[{"id":"620e74b2-d135-4333-8596-42d7bcb84e8f","name":"countries","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"","value":"","type":"text","disabled":true}],"url":{"raw":"https://api.chat2desk.com/v1/countries","host":["https://api.chat2desk.com"],"path":["v1","countries"],"query":[{"key":"limit","value":null,"description":"Number of records returned (maximum is 200, default is 20).","disabled":true},{"key":"offset","value":null,"description":"Offset from the 1st record of the list (default is 0).","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:24:17 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"d36a1903ac2362ec5f71eac750f64895\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"d42f9850-7293-4fee-9fd7-44a95dc83d81"},{"key":"X-Runtime","value":"0.008558"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 1,\n            \"code\": 1,\n            \"name_ru\": \"США\",\n            \"name_en\": \"USA\",\n            \"iso_code\": \"us\",\n            \"currency_id\": 3,\n            \"timezone_id\": 7\n        },\n        {\n            \"id\": 2,\n            \"code\": 79,\n            \"name_ru\": \"Россия\",\n            \"name_en\": \"Russia\",\n            \"iso_code\": \"ru\",\n            \"currency_id\": 1,\n            \"timezone_id\": 23\n        },\n        {\n            \"id\": 3,\n            \"code\": 20,\n            \"name_ru\": \"Египет\",\n            \"name_en\": \"Egypt\",\n            \"iso_code\": \"eg\",\n            \"currency_id\": 3,\n            \"timezone_id\": 18\n        },\n        {\n            \"id\": 4,\n            \"code\": 27,\n            \"name_ru\": \"Южная Африка\",\n            \"name_en\": \"South Africa\",\n            \"iso_code\": \"za\",\n            \"currency_id\": 3,\n            \"timezone_id\": 18\n        },\n        {\n            \"id\": 5,\n            \"code\": 30,\n            \"name_ru\": \"Греция\",\n            \"name_en\": \"Greece\",\n            \"iso_code\": \"gr\",\n            \"currency_id\": 2,\n            \"timezone_id\": 18\n        },\n        {\n            \"id\": 6,\n            \"code\": 32,\n            \"name_ru\": \"Бельгия\",\n            \"name_en\": \"Belgium\",\n            \"iso_code\": \"be\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 7,\n            \"code\": 33,\n            \"name_ru\": \"Франция\",\n            \"name_en\": \"France\",\n            \"iso_code\": \"fr\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 8,\n            \"code\": 34,\n            \"name_ru\": \"Испания\",\n            \"name_en\": \"Spain\",\n            \"iso_code\": \"es\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 9,\n            \"code\": 36,\n            \"name_ru\": \"Венгрия\",\n            \"name_en\": \"Hungary\",\n            \"iso_code\": \"hu\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 10,\n            \"code\": 37,\n            \"name_ru\": \"Молдавия\",\n            \"name_en\": \"Moldavia\",\n            \"iso_code\": \"md\",\n            \"currency_id\": 3,\n            \"timezone_id\": 18\n        },\n        {\n            \"id\": 11,\n            \"code\": 39,\n            \"name_ru\": \"Италия\",\n            \"name_en\": \"Italy\",\n            \"iso_code\": \"it\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 12,\n            \"code\": 40,\n            \"name_ru\": \"Румыния\",\n            \"name_en\": \"Romania\",\n            \"iso_code\": \"ro\",\n            \"currency_id\": 2,\n            \"timezone_id\": 18\n        },\n        {\n            \"id\": 13,\n            \"code\": 41,\n            \"name_ru\": \"Швейцария\",\n            \"name_en\": \"Switzerland\",\n            \"iso_code\": \"ch\",\n            \"currency_id\": 3,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 14,\n            \"code\": 43,\n            \"name_ru\": \"Австрия\",\n            \"name_en\": \"Austria\",\n            \"iso_code\": \"at\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 15,\n            \"code\": 44,\n            \"name_ru\": \"Великобритания\",\n            \"name_en\": \"United Kingdom\",\n            \"iso_code\": \"gb\",\n            \"currency_id\": 3,\n            \"timezone_id\": 12\n        },\n        {\n            \"id\": 16,\n            \"code\": 45,\n            \"name_ru\": \"Дания\",\n            \"name_en\": \"Denmark\",\n            \"iso_code\": \"dk\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 17,\n            \"code\": 46,\n            \"name_ru\": \"Швеция\",\n            \"name_en\": \"Sweden\",\n            \"iso_code\": \"se\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 18,\n            \"code\": 47,\n            \"name_ru\": \"Норвегия\",\n            \"name_en\": \"Norway\",\n            \"iso_code\": \"no\",\n            \"currency_id\": 3,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 19,\n            \"code\": 48,\n            \"name_ru\": \"Польша\",\n            \"name_en\": \"Poland\",\n            \"iso_code\": \"pl\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        },\n        {\n            \"id\": 20,\n            \"code\": 49,\n            \"name_ru\": \"Германия\",\n            \"name_en\": \"Germany\",\n            \"iso_code\": \"de\",\n            \"currency_id\": 2,\n            \"timezone_id\": 14\n        }\n    ],\n    \"meta\": {\n        \"total\": 242,\n        \"limit\": 20,\n        \"offset\": 0\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"58f4049a-fbc2-4208-b296-1b741ffd9c38"},{"name":"regions","id":"c9f5c1a4-0be4-455f-a9f1-823a7ad758a4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/regions","description":"<p>Returns a list of available regions. This list is used to display in client's infocard on the site based on client's mobile number (where known).</p>\n","urlObject":{"path":["v1","regions"],"host":["https://api.chat2desk.com"],"query":[{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":null}],"variable":[]}},"response":[{"id":"0cf24b5c-ba66-41eb-be7e-33f0756389d9","name":"regions","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/regions","host":["https://api.chat2desk.com"],"path":["v1","regions"],"query":[{"key":"limit","value":"","description":"Number of records returned (maximum is 200, default is 20).","disabled":true},{"key":"offset","value":null,"description":"Offset from the 1st record of the list (default is 0).","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:36:44 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"6c3f839d7ac854d086067e26e6b13943\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"48d7bf8f-4d73-4503-b7b5-650f794ece5d"},{"key":"X-Runtime","value":"0.106792"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 1,\n            \"country\": \"Россия\",\n            \"region\": \"Краснодар\"\n        },\n        {\n            \"id\": 2,\n            \"country\": \"Россия\",\n            \"region\": \"Тверь\"\n        },\n        {\n            \"id\": 3,\n            \"country\": \"Россия\",\n            \"region\": \"Челябинск\"\n        },\n        {\n            \"id\": 4,\n            \"country\": \"Россия\",\n            \"region\": \"Екатеринбург\"\n        },\n        {\n            \"id\": 5,\n            \"country\": \"Россия\",\n            \"region\": \"Кемерово\"\n        },\n        {\n            \"id\": 6,\n            \"country\": \"Россия\",\n            \"region\": \"Челябинск\"\n        },\n        {\n            \"id\": 7,\n            \"country\": \"Россия\",\n            \"region\": \"Челябинск\"\n        },\n        {\n            \"id\": 8,\n            \"country\": \"Россия\",\n            \"region\": \"Тверь\"\n        },\n        {\n            \"id\": 9,\n            \"country\": \"Россия\",\n            \"region\": \"Ростов-на-Дону\"\n        },\n        {\n            \"id\": 10,\n            \"country\": \"Россия\",\n            \"region\": \"Грозный\"\n        },\n        {\n            \"id\": 11,\n            \"country\": \"Россия\",\n            \"region\": \"Екатеринбург\"\n        },\n        {\n            \"id\": 12,\n            \"country\": \"Россия\",\n            \"region\": \"Грозный\"\n        },\n        {\n            \"id\": 13,\n            \"country\": \"Россия\",\n            \"region\": \"Смоленск\"\n        },\n        {\n            \"id\": 14,\n            \"country\": \"Россия\",\n            \"region\": \"Краснодар\"\n        },\n        {\n            \"id\": 15,\n            \"country\": \"Россия\",\n            \"region\": \"Воронеж\"\n        },\n        {\n            \"id\": 16,\n            \"country\": \"Россия\",\n            \"region\": \"Воронеж\"\n        },\n        {\n            \"id\": 17,\n            \"country\": \"Россия\",\n            \"region\": \"Саратов\"\n        },\n        {\n            \"id\": 18,\n            \"country\": \"Россия\",\n            \"region\": \"Пенза\"\n        },\n        {\n            \"id\": 19,\n            \"country\": \"Россия\",\n            \"region\": \"Казань\"\n        },\n        {\n            \"id\": 20,\n            \"country\": \"Россия\",\n            \"region\": \"Чебоксары\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 4615,\n        \"limit\": 20,\n        \"offset\": 0\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"c9f5c1a4-0be4-455f-a9f1-823a7ad758a4"}],"id":"6ff7a29a-6c0c-4e5f-b38f-436b7c390659","description":"<p>Working with data types and possible values.</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"216da7bb-6d4d-4b20-8127-63ef34df7f28"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"69cdd0ab-b78f-4f65-ad14-c9ea4064cc15"}}],"_postman_id":"6ff7a29a-6c0c-4e5f-b38f-436b7c390659"},{"name":"Other","item":[{"name":"companies/info","id":"f7c77547-5e31-4afe-87d3-c17db1f7a1e7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/companies/info","description":"<p>Stores any text info which relates to your company as a whole – unlike per-client basis.</p>\n<p>There are 3 text fields to store the info. To read back the info, use <code>api_info (GET)</code>.</p>\n","urlObject":{"path":["v1","companies","info"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"7697cae1-a63b-4ec6-98e5-4492fb453d0b","name":"Successful Response","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/companies/info"},"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"id\": 123,\n        \"name\": \"Chat2Desk\",\n        \"workingHours\": [\n            {\n                \"begin\": \"09 : 00\",\n                \"end\": \"21 : 00\"\n            },\n            {\n                \"begin\": \"09 : 00\",\n                \"end\": \"20 : 00\"\n            },\n            {\n                \"begin\": \"10 : 00\",\n                \"end\": \"19 : 00\"\n            },\n            {\n                \"begin\": \"11 : 00\",\n                \"end\": \"18 : 00\"\n            }\n        ],\n        \"timezone\": \"Волгоград, Москва, С-Петербург (UTC+3:00)\",\n        \"online\": true\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"f7c77547-5e31-4afe-87d3-c17db1f7a1e7"},{"name":"api_info","id":"8337b55e-a9da-4507-91bc-fa4641212350","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/companies/api_info","description":"<p>Returns current API version, your API access level, number of API requests per month and more.</p>\n<p>The following API packages are available for connection:</p>\n<ol>\n<li>large one-time packages (1 000 000, 5 000 000, 20 000 000 requests)</li>\n<li>large packages with auto-renewal (1 000 000, 5 000 000, 20 000 000 requests)</li>\n<li>small packages with auto-renewal (1000 requests)</li>\n</ol>\n<p>Some fields in the reply:</p>\n<ul>\n<li>CompanyID – unique identifier of the company account.</li>\n<li>PartnerID - unique identifier of the partner account that this company belongs to.</li>\n<li>Current API version.</li>\n<li>Your current API access level – see <code>api_modes (GET)</code>.</li>\n<li>Number of available channels.</li>\n<li>Custom info (see <code>companies (PUT)</code>).</li>\n<li><em>Write first</em> feature status.</li>\n<li>URLs of web user interface.</li>\n<li>API calls limit and other parameters.</li>\n</ul>\n","urlObject":{"path":["v1","companies","api_info"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"fe2d750c-9627-4280-8bc5-785132912d25","name":"api_info","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/companies/api_info"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:39:47 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"80641cbe2a5e52acd1bf9a28d8761ba3\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"31837d4c-f492-4bc0-901c-8c4c0a155e02"},{"key":"X-Runtime","value":"0.163764"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": {\n        \"companyID\": 62980,\n        \"partnerID\": 1,\n        \"partner_type\": \"partner_client\",\n        \"company_mode\": \"standard\",\n        \"hook\": null,\n        \"hook_preferences\": null,\n        \"current_version\": 1,\n        \"channels\": 1,\n        \"company_name\": \"TestTest_api_methods\",\n        \"company_lang\": \"ru\",\n        \"admin_email\": \"testtest_api_methods@mail.ru\",\n        \"custom_info\": null,\n        \"write_first_option\": true,\n        \"domain_urls\": [\n            \"https://test20.chat2desk.com\"\n        ],\n        \"api_calls\": {\n            \"used_this_month\": 0,\n            \"left_free_requests\": 99979,\n            \"left_paid_requests\": 1000000\n        }\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"8337b55e-a9da-4507-91bc-fa4641212350"},{"name":"statistics","id":"58ba32ef-d720-4701-a9f7-10a12dd0af54","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/statistics?report=request_stats&date=2021-11-22","description":"<p>Returns aggregated statistics data such as operators’ reaction and reply times, number of (new) clients and requests per day, operators activity, ratings, requests and more. See <em>Reports &gt; General reports &gt; Aggregated statistics</em> section on the site.</p>\n<p><strong>Important!</strong> You must have <em>Aggregated statistics</em> paid feature turned on for your company. Contact administration.</p>\n","urlObject":{"path":["v1","statistics"],"host":["https://api.chat2desk.com"],"query":[{"description":{"content":"<p>Name of 5 available statistic reports:</p>\n<ul>\n<li>operator_replies</li>\n<li>request_stats</li>\n<li>operator_stats</li>\n<li>operator_events</li>\n<li>rating</li>\n</ul>\n","type":"text/plain"},"key":"report","value":"request_stats"},{"description":{"content":"<p>Day (in your company’s time zone) for which statistics will be returned. You can specify 1 day only. Keep in mind, that statistics for current day is calculated next day (tomorrow) at around 2 a.m.</p>\n","type":"text/plain"},"key":"date","value":"2021-11-22"},{"disabled":true,"description":{"content":"<p>Number of records returned (default is 20).</p>\n","type":"text/plain"},"key":"limit","value":""},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":""}],"variable":[]}},"response":[{"id":"1113e174-e18e-4da3-8355-6356121305ea","name":"request_stats","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/statistics?report=request_stats&date=2025-04-28","host":["https://api.chat2desk.com"],"path":["v1","statistics"],"query":[{"key":"report","value":"request_stats","description":"Name of 5 available statistic reports:\n* operator_replies\n* request_stats\n* operator_stats\n* operator_events\n* rating"},{"key":"date","value":"2025-04-28","description":"Day (in your company’s time zone) for which statistics will be returned. You can specify 1 day only. Keep in mind, that statistics for current day is calculated next day (tomorrow) at around 2 a.m."},{"key":"limit","value":"","description":"Number of records returned (default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"request_id\": 597464634,\n            \"request_tags\": \"\",\n            \"client_id\": 28028541,\n            \"client_name\": \"Martin McFly\",\n            \"assigned_name\": \"Marty McFly\",\n            \"phone\": \"55520151021\",\n            \"transport\": \"external\",\n            \"client_comment\": \"Cool Nike Mags\",\n            \"client_custom_fields\": \"{\\\"1\\\": \\\"Text 1\\\", \\\"2\\\": \\\"Text 2\\\", \\\"3\\\": \\\"Text 3\\\"}\",\n            \"client_country\": \"USA\",\n            \"client_region\": \"\",\n            \"client_tags\": \"\",\n            \"client_is_new\": \"false\",\n            \"channel_id\": 89763,\n            \"channel_name\": \"VIP Clients\",\n            \"channel_phone\": \"55519851026\",\n            \"operator_id\": \"\",\n            \"operator_name\": \"\",\n            \"operator_role\": \"\",\n            \"reply_start\": \"\",\n            \"working_reaction_time\": \"\",\n            \"request_start\": \"2025-04-28 14:16:46\",\n            \"request_end\": \"\",\n            \"request_time\": \"\",\n            \"request_starter\": \"other\",\n            \"incoming_messages\": 7,\n            \"outgoing_messages\": 0,\n            \"incoming_menu_messages\": 0,\n            \"outgoing_menu_messages\": 0,\n            \"working_request_time\": \"\",\n            \"reaction_time\": \"\",\n            \"request_start_mode\": \"online\",\n            \"request_terminator\": \"\",\n            \"replies\": 0,\n            \"total_replies_time\": \"\",\n            \"average_replies_time\": \"\",\n            \"score_operator_id\": \"\",\n            \"score_operator_name\": \"\",\n            \"rating_scale_name\": \"\",\n            \"rating_scale_score\": \"\",\n            \"rating_text\": \"\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 1,\n        \"limit\": 20,\n        \"offset\": 0\n    }\n}"},{"id":"4bd87538-00b6-484a-9a60-89edc8082afa","name":"operator_replies","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/statistics?report=operator_replies&date=2025-04-28","host":["https://api.chat2desk.com"],"path":["v1","statistics"],"query":[{"key":"report","value":"operator_replies","description":"Name of 5 available statistic reports:\n* operator_replies\n* request_stats\n* operator_stats\n* operator_events\n* rating"},{"key":"date","value":"2025-04-28","description":"Day (in your company’s time zone) for which statistics will be returned. You can specify 1 day only. Keep in mind, that statistics for current day is calculated next day (tomorrow) at around 2 a.m."},{"key":"limit","value":"","description":"Number of records returned (default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"request_id\": 597464634,\n            \"request_terminator\": \"\",\n            \"request_starter\": \"other\",\n            \"request_tags\": \"\",\n            \"client_id\": 28028541,\n            \"client_name\": \"Martin McFly\",\n            \"assigned_name\": \"Marty McFly\",\n            \"phone\": \"55520151021\",\n            \"transport\": \"external\",\n            \"client_comment\": \"Cool Nike Mags\",\n            \"client_custom_fields\": \"{\\\"1\\\": \\\"Text 1\\\", \\\"2\\\": \\\"Text 2\\\", \\\"3\\\": \\\"Text 3\\\"}\",\n            \"client_country\": \"USA\",\n            \"client_region\": \"\",\n            \"client_tags\": \"\",\n            \"client_is_new\": \"false\",\n            \"ban_status\": \"\",\n            \"operator_id\": 277589,\n            \"operator_name\": \"Emmett Brown\",\n            \"operator_role\": \"admin\",\n            \"operator_groups\": \"\",\n            \"channel_id\": 89763,\n            \"channel_name\": \"VIP Clients\",\n            \"channel_phone\": \"55519851026\",\n            \"request_start\": \"2025-04-28 14:16:46\",\n            \"request_end\": \"\",\n            \"request_time\": \"\",\n            \"request_start_mode\": \"online\",\n            \"reply_start\": \"2025-04-29 17:08:39\",\n            \"working_reaction_time\": 96681,\n            \"reaction_time\": 96713,\n            \"incoming_messages\": 7,\n            \"outgoing_messages\": 1,\n            \"incoming_menu_messages\": 0,\n            \"outgoing_menu_messages\": 0,\n            \"working_request_time\": \"\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 1,\n        \"limit\": 20,\n        \"offset\": 0\n    }\n}"},{"id":"db55f7e7-0ba9-4786-82a5-5ba23115bded","name":"operator_stats","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/statistics?report=operator_stats&date=2025-04-28","host":["https://api.chat2desk.com"],"path":["v1","statistics"],"query":[{"key":"report","value":"operator_stats","description":"Name of 5 available statistic reports:\n* operator_replies\n* request_stats\n* operator_stats\n* operator_events\n* rating"},{"key":"date","value":"2025-04-28","description":"Day (in your company’s time zone) for which statistics will be returned. You can specify 1 day only. Keep in mind, that statistics for current day is calculated next day (tomorrow) at around 2 a.m."},{"key":"limit","value":"","description":"Number of records returned (default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"operator_id\": 277589,\n            \"operator_name\": \"Emmett Brown\",\n            \"operator_role\": \"admin\",\n            \"channel_id\": 89763,\n            \"channel_name\": \"VIP Clients\",\n            \"channel_phone\": \"55519851026\",\n            \"transport\": \"external\",\n            \"date\": \"2025-04-28\",\n            \"requests\": 1,\n            \"requests_took_part\": 0,\n            \"messages\": 0,\n            \"clients\": 1,\n            \"operator_groups\": \"\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 0,\n        \"limit\": 20,\n        \"offset\": 0\n    }\n}"},{"id":"97b6d60f-c5b2-47e2-bc55-b2bcf62900f4","name":"operator_events","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/statistics?report=operator_events&date=2025-04-28","host":["https://api.chat2desk.com"],"path":["v1","statistics"],"query":[{"key":"report","value":"operator_events","description":"Name of 5 available statistic reports:\n* operator_replies\n* request_stats\n* operator_stats\n* operator_events\n* rating"},{"key":"date","value":"2025-04-28","description":"Day (in your company’s time zone) for which statistics will be returned. You can specify 1 day only. Keep in mind, that statistics for current day is calculated next day (tomorrow) at around 2 a.m."},{"key":"limit","value":"","description":"Number of records returned (default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"operator_id\": 277589,\n            \"operator_name\": \"Emmett Brown\",\n            \"operator_role\": \"admin\",\n            \"operator_groups\": \"\",\n            \"event\": \"take_chat\",\n            \"dialog_id\": 105295767,\n            \"created_at\": \"2025-04-28 14:17:18\",\n            \"status_duration\": \"\"\n        },\n        {\n            \"operator_id\": 277589,\n            \"operator_name\": \"Emmett Brown\",\n            \"operator_role\": \"admin\",\n            \"operator_groups\": \"\",\n            \"event\": \"login\",\n            \"dialog_id\": \"\",\n            \"created_at\": \"2025-04-28 14:16:58\",\n            \"status_duration\": 20\n        }\n    ],\n    \"meta\": {\n        \"total\": 2,\n        \"limit\": 20,\n        \"offset\": 0\n    }\n}"},{"id":"ad373e52-405a-4da8-8dcf-0709c6b59201","name":"rating","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":{"raw":"https://api.chat2desk.com/v1/statistics?report=rating&date=2025-04-28","host":["https://api.chat2desk.com"],"path":["v1","statistics"],"query":[{"key":"report","value":"rating","description":"Name of 5 available statistic reports:\n* operator_replies\n* request_stats\n* operator_stats\n* operator_events\n* rating"},{"key":"date","value":"2025-04-28","description":"Day (in your company’s time zone) for which statistics will be returned. You can specify 1 day only. Keep in mind, that statistics for current day is calculated next day (tomorrow) at around 2 a.m."},{"key":"limit","value":"","description":"Number of records returned (default is 20).","type":"text","disabled":true},{"key":"offset","value":"","description":"Offset from the 1st record of the list (default is 0).","type":"text","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"client_id\": 4899,\n            \"client_name\": \"Martin McFly\",\n            \"assigned_name\": \"Marty McFly\",\n            \"phone\": \"55520151021\",\n            \"transport\": \"external\",\n            \"client_comment\": \"Cool Nike Mags\",\n            \"client_custom_fields\": \"\",\n            \"client_country\": \"USA\",\n            \"client_region\": \"\",\n            \"client_tags\": \"\",\n            \"operator_id\": 277589,\n            \"operator_name\": \"Emmett Brown\",\n            \"operator_role\": \"admin\",\n            \"operator_groups\": \"\",\n            \"channel_id\": 89763,\n            \"channel_name\": \"VIP Clients\",\n            \"channel_phone\": \"55519851026\",\n            \"created_at\": \"2025-04-28 21:14:14\",\n            \"rating_id\": 54269,\n            \"rating_name\": \"42\",\n            \"request_id\": 601769309,\n            \"valuation_request_id\": 584439487,\n            \"rating_scale_id\": 270589,\n            \"rating_scale_name\": \"Super\",\n            \"rating_scale_score\": 5,\n            \"rating_text\": \"5\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 1,\n        \"limit\": 20,\n        \"offset\": 0\n    }\n}"}],"_postman_id":"58ba32ef-d720-4701-a9f7-10a12dd0af54"},{"name":"web_analytics_data","id":"5775d128-e5f8-482f-a50b-9fe9fbf9d959","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/web_analytics_data?date_from=2021-11-20&date_from=2021-11-21&order=asc","description":"<p>Returns a list of URLs and UTM marks of clients’ chats along with Google, Yandex, Comagic and Roistat user ids. Useful for marketing purposes.</p>\n<p>To obtain this data, you must have <em>URL/UTM tracking</em> feature turned on. See <em>Settings &gt; URL tracking</em> section on the site.</p>\n<p>Also, your clients must start chats using our widget with messengers — see <em>Settings &gt; Widget</em>.</p>\n","urlObject":{"path":["v1","web_analytics_data"],"host":["https://api.chat2desk.com"],"query":[{"description":{"content":"<p>Starting date of the data</p>\n","type":"text/plain"},"key":"date_from","value":"2021-11-20"},{"description":{"content":"<p>Ending date</p>\n","type":"text/plain"},"key":"date_from","value":"2021-11-21"},{"description":{"content":"<p>Order: asc or desc</p>\n","type":"text/plain"},"key":"order","value":"asc"},{"disabled":true,"description":{"content":"<p>Number of records returned (maximum is 200, default is 20).</p>\n","type":"text/plain"},"key":"limit","value":null},{"disabled":true,"description":{"content":"<p>Offset from the 1st record of the list (default is 0).</p>\n","type":"text/plain"},"key":"offset","value":null}],"variable":[]}},"response":[{"id":"232a14d8-0d81-405d-a405-50d80e03b8e8","name":"web_analytics_data","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."},{"key":"Content-Type","name":"Content-Type","value":"application/javascript","type":"text"}],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"javascript"}}},"url":{"raw":"https://api.chat2desk.com/v1/web_analytics_data?date_from=2023-10-17&date_from=2021-09-01&order=asc","host":["https://api.chat2desk.com"],"path":["v1","web_analytics_data"],"query":[{"key":"date_from","value":"2023-10-17","description":"Starting date of the data"},{"key":"date_from","value":"2021-09-01","description":"Ending date"},{"key":"order","value":"asc","description":"Order: asc or desc"},{"key":"limit","value":null,"description":"Number of records returned (maximum is 200, default is 20).","disabled":true},{"key":"offset","value":null,"description":"Offset from the 1st record of the list (default is 0).","disabled":true}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","description":"","type":"text"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"message_id\": 11233,\n            \"client_id\": 12122,\n            \"url\": \"http://yoursite.html\",\n            \"click_time\": \"2022-06-28T22:57:23.000Z\",\n            \"utm\": \"utm\",\n            \"google_id\": null,\n            \"yandex_id\": null,\n            \"comagic_id\": null,\n            \"utm_source\": \"utm_source\",\n            \"utm_medium\": null,\n            \"utm_campaign\": null,\n            \"utm_content\": null,\n            \"utm_term\": null,\n            \"utm_custom\": \"\",\n            \"roistat_visit\": null\n        },\n        {\n            \"message_id\": 12434,\n            \"client_id\": 15732,\n            \"url\": \"http://yoursite.html\",\n            \"click_time\": \"2022-06-28T05:12:23.000Z\",\n            \"utm\": \"utm\",\n            \"google_id\": null,\n            \"yandex_id\": null,\n            \"comagic_id\": null,\n            \"utm_source\": \"utm_source\",\n            \"utm_medium\": null,\n            \"utm_campaign\": null,\n            \"utm_content\": null,\n            \"utm_term\": null,\n            \"utm_custom\": \"\",\n            \"roistat_visit\": null\n        }\n    ],\n    \"meta\": {\n        \"total\": 2,\n        \"limit\": 20,\n        \"offset\": 0\n    }\n}"}],"_postman_id":"5775d128-e5f8-482f-a50b-9fe9fbf9d959"},{"name":"templates","id":"314840be-9b57-40c9-865a-b30c51309cee","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/templates/","description":"<p>Returns a list of templates for quick answers by your operators (agents). See <em>Settings &gt; Templates</em> section on the site.</p>\n<p>Specify <em>template id</em> (for example <em>templates/1</em>) to get an info on an individual template.</p>\n","urlObject":{"path":["v1","templates",""],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"bf33d3ff-aff5-4f3c-9d5b-4ea50b5383cf","name":"templates","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account)."}],"url":"https://api.chat2desk.com/v1/templates/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:41:24 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"c42b4604175f53d34c463ab8317b0589\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"436d333e-8017-4c48-aea9-ebf26ce0dabc"},{"key":"X-Runtime","value":"0.026507"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 30553,\n            \"command\": \"111\",\n            \"text\": \"Тест\",\n            \"name\": \"Кликаем на шаблон в списке\",\n            \"created\": \"2019-11-07T10:01:23 UTC\"\n        },\n        {\n            \"id\": 30554,\n            \"command\": \"777\",\n            \"text\": \"Клик-клик\",\n            \"name\": \"Кликнем много раз\",\n            \"created\": \"2019-11-11T06:55:25 UTC\"\n        },\n        {\n            \"id\": 30555,\n            \"command\": \"ест\",\n            \"text\": \"двыал\",\n            \"name\": \"Федор\",\n            \"created\": \"2021-03-24T12:48:58 UTC\"\n        },\n        {\n            \"id\": 30556,\n            \"command\": \"schedule\",\n            \"text\": \"We work from 10 AM to 10 PM\",\n            \"name\": \"Schedule\",\n            \"created\": \"2019-08-05T11:35:32 UTC\"\n        },\n        {\n            \"id\": 30557,\n            \"command\": \"io\",\n            \"text\": \"%io\",\n            \"name\": \"%io\",\n            \"created\": \"2019-08-16T14:01:29 UTC\"\n        },\n        {\n            \"id\": 30558,\n            \"command\": \"aaa\",\n            \"text\": \"%hello!\",\n            \"name\": \"приветствие\",\n            \"created\": \"2019-09-11T09:54:02 UTC\"\n        },\n        {\n            \"id\": 30559,\n            \"command\": \"222\",\n            \"text\": \"Тест 2 ---------\",\n            \"name\": \"3 раза в чт, + пт изменила текст, добавила картинку\",\n            \"created\": \"2019-11-07T10:01:54 UTC\"\n        },\n        {\n            \"id\": 30560,\n            \"command\": \"333\",\n            \"text\": \"Тест 3\",\n            \"name\": \"3 раза в чт, сделала личным шаблоном\",\n            \"created\": \"2019-11-07T10:04:23 UTC\"\n        },\n        {\n            \"id\": 30561,\n            \"command\": \"444\",\n            \"text\": \"Hello, %client!\",\n            \"name\": \"Greeting\",\n            \"created\": \"2019-11-07T10:06:10 UTC\"\n        },\n        {\n            \"id\": 30562,\n            \"command\": \"666\",\n            \"text\": \"Тест 6\",\n            \"name\": \"2 раза в чт, + пт\",\n            \"created\": \"2019-11-07T10:23:04 UTC\"\n        },\n        {\n            \"id\": 30563,\n            \"command\": \"client\",\n            \"text\": \"%client %hello\",\n            \"name\": \"%client\",\n            \"created\": \"2019-11-11T06:49:15 UTC\"\n        },\n        {\n            \"id\": 30564,\n            \"command\": \"v\",\n            \"text\": \"В дополнение к 2 переменным %client и %hello добавить еще 2:\\n%operator_name - имя текущего оператора чата\\n%operator_surname - фамилия текущего оператора чата\\n%client_id - id клиента внутри нашей системы\\n%client_number - номер клиента\\n%dialog_id - id диалога внутри нашей системы\",\n            \"name\": \"Variablies\",\n            \"created\": \"2020-02-18T05:27:55 UTC\"\n        },\n        {\n            \"id\": 30565,\n            \"command\": \"2\",\n            \"text\": \"‘%phone’, ‘%transport’, ‘%account’, ‘%client’, ‘%comment’, ‘%menu_item’\",\n            \"name\": \"еще переменные\",\n            \"created\": \"2020-02-19T17:38:32 UTC\"\n        },\n        {\n            \"id\": 30566,\n            \"command\": \"фб1\",\n            \"text\": \"@FB-tag <EVENT_UPDATE>@ enet update template\",\n            \"name\": \"Шаблон для ФБ\",\n            \"created\": \"2020-03-21T11:42:53 UTC\"\n        },\n        {\n            \"id\": 30567,\n            \"command\": \"фб2\",\n            \"text\": \"@FB-tag <POST_PURCHASE_UPDATE>@ purchase update template\",\n            \"name\": \"Шаблон для ФБ 2\",\n            \"created\": \"2020-03-21T11:44:02 UTC\"\n        },\n        {\n            \"id\": 30568,\n            \"command\": \"фб3\",\n            \"text\": \"@FB-tag <ACCOUNT_UPDATE>@ %hello account update template 😎\",\n            \"name\": \"Шаблон для ФБ 3\",\n            \"created\": \"2020-03-21T11:45:26 UTC\"\n        },\n        {\n            \"id\": 30569,\n            \"command\": \"игорь\",\n            \"text\": \"\",\n            \"name\": \"вложение пдф\",\n            \"created\": \"2020-04-06T11:29:45 UTC\"\n        },\n        {\n            \"id\": 30570,\n            \"command\": \"пост\",\n            \"text\": \"тест с гиф\",\n            \"name\": \"с зипом\",\n            \"created\": \"2020-04-06T12:50:07 UTC\"\n        },\n        {\n            \"id\": 30571,\n            \"command\": \"поп\",\n            \"text\": \"тест с экселем\",\n            \"name\": \"тест с экселем\",\n            \"created\": \"2020-04-06T12:51:51 UTC\"\n        },\n        {\n            \"id\": 30572,\n            \"command\": \"поп1\",\n            \"text\": \"тест с xlsx\",\n            \"name\": \"тест с xlsx\",\n            \"created\": \"2020-04-06T12:52:11 UTC\"\n        }\n    ],\n    \"meta\": {\n        \"total\": 21,\n        \"limit\": 20,\n        \"offset\": 0\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"314840be-9b57-40c9-865a-b30c51309cee"},{"name":"channels","id":"1248303b-cff5-4e81-a118-421eecc04124","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n","type":"text"}],"url":"https://api.chat2desk.com/v1/channels","description":"<p>Returns list of your channels with info such as connected transports (messengers) on each channel.</p>\n","urlObject":{"path":["v1","channels"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[{"id":"82179025-ae74-46de-a887-904bb784c7c4","name":"channels","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"Token from Settings > API section (under admin account).","type":"text"}],"url":"https://api.chat2desk.com/v1/channels"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"nginx/1.16.1"},{"key":"Date","value":"Wed, 15 Feb 2023 14:42:00 GMT"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Transfer-Encoding","value":"chunked"},{"key":"Connection","value":"keep-alive"},{"key":"X-Frame-Options","value":"SAMEORIGIN"},{"key":"X-XSS-Protection","value":"1; mode=block"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"X-Download-Options","value":"noopen"},{"key":"X-Permitted-Cross-Domain-Policies","value":"none"},{"key":"Referrer-Policy","value":"strict-origin-when-cross-origin"},{"key":"Vary","value":"Accept-Encoding, Origin"},{"key":"Content-Encoding","value":"gzip"},{"key":"ETag","value":"W/\"f0ffe9da1eedb765ea53aa713d9e0965\""},{"key":"Cache-Control","value":"max-age=0, private, must-revalidate"},{"key":"X-Request-Id","value":"0356c29e-bfa2-4b14-9c58-a23c98bb1944"},{"key":"X-Runtime","value":"0.182915"}],"cookie":[],"responseTime":null,"body":"{\n    \"data\": [\n        {\n            \"id\": 21750,\n            \"name\": \"Channel fbe77d12e6b0 (auto)\",\n            \"phone\": \"1676531532\",\n            \"transports\": [\n                \"whatsapp\",\n                \"widget\",\n                \"telegram\"\n            ],\n            \"whatsapp_daily_new_clients_limit\": {\n                \"limit\": 10,\n                \"used\": 1\n            }\n        }\n    ],\n    \"meta\": {\n        \"total\": 1,\n        \"limit\": 20,\n        \"offset\": 0\n    },\n    \"status\": \"success\"\n}"}],"_postman_id":"1248303b-cff5-4e81-a118-421eecc04124"},{"name":"companies","id":"13613ac1-7acd-4c09-9621-490507f4ee44","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\r\n    \"custom_fields\": {\"1\":\"Field 1\",\"2\":\"Field 2\",\"3\":\"Field 3\"}\r\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/companies","description":"<p>Stores any text info which relates to your company as a whole – unlike per-client basis.</p>\n<p>There are 3 text fields to store the info. To read back the info, use <code>api_info (GET)</code>.</p>\n","urlObject":{"path":["v1","companies"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"13613ac1-7acd-4c09-9621-490507f4ee44"},{"name":"companies/switch_mode","id":"eb6e5983-277f-49a3-b971-96ae78fcaade","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"mode\": \"online\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/companies/switch_mode","description":"<p>Switches company’s current working mode. Working mode affects autoreplies (see <em>Settings &gt; General</em> section on the site).</p>\n<h5 id=\"body-parameters\">Body parameters</h5>\n<p>Status can be <em>online</em> and <em>offline</em>.</p>\n","urlObject":{"path":["v1","companies","switch_mode"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"eb6e5983-277f-49a3-b971-96ae78fcaade"},{"name":"qr_decode","id":"6e2b2c4e-0ca2-4a01-8320-082e445c9ad1","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"body":{"mode":"raw","raw":"{\n    \"image_path\": \"https://cdn.britannica.com/17/155017-050-9AC96FC8/Example-QR-code.jpg\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chat2desk.com/v1/qr_decode","description":"<p>Decodes QR code for direct URL with QR code picture.</p>\n","urlObject":{"path":["v1","qr_decode"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"6e2b2c4e-0ca2-4a01-8320-082e445c9ad1"},{"name":"delete_outbox","id":"63a0acfb-5aaf-4d51-b106-da3881f6be95","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"<API Token>","description":"<p>Token from Settings &gt; API section (under admin account).</p>\n"}],"url":"https://api.chat2desk.com/v1/gateway/delete_outbox","description":"<p>Deletes all outgoing messages that yet have not been sent.</p>\n","urlObject":{"path":["v1","gateway","delete_outbox"],"host":["https://api.chat2desk.com"],"query":[],"variable":[]}},"response":[],"_postman_id":"63a0acfb-5aaf-4d51-b106-da3881f6be95"}],"id":"ccf840e0-d217-49b0-84e1-1cca4e5b40ec","description":"<p>Other API functions.</p>\n","event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"e0bef60f-8f57-4848-81a0-9d6567af7fbe"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"f50bd4cd-d46c-4eb4-8a40-1f836124af16"}}],"_postman_id":"ccf840e0-d217-49b0-84e1-1cca4e5b40ec"}],"event":[{"listen":"prerequest","script":{"id":"0cf7431c-39c8-4d5d-8da8-066b059a7e3a","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"0f861b3f-ad24-43cd-b1cf-99a25c1bdc59","type":"text/javascript","exec":[""]}}],"variable":[{"key":"brand","value":"Chat2Desk","type":"string"},{"key":"token","value":"<API Token>","type":"string"},{"key":"url","value":"https://api.chat2desk.com","type":"string"}]}