{"info":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","description":"<html><head></head><body><h3 id=\"about-messaging-api\">About Messaging API</h3>\n<p>This Messaging API provides a mechanism to send text messages and files to Ringotel users from a third-party web service or application, as well as receive messages and notifications to the specified webhook.</p>\n<h3 id=\"transport\">Transport</h3>\n<p>This Messaging API uses JSON as its communication format. You can use HTTP as a transport protocol. The server is listening to the HTTP requests over the SSL/TLS protocol on the 443 port.</p>\n<h3 id=\"authentication-and-authorization\">Authentication and Authorization</h3>\n<p>Use API Key generated in your Ringotel Shell admin portal as a Bearer token to authenticate requests on the server.</p>\n<p>All API calls should be made to the admin portal URL:</p>\n<p><code>https://shell.ringotel.co/api</code></p>\n<h3 id=\"requests-format\">Requests format</h3>\n<p>The requests format includes <code>method</code> and <code>params</code> fields.<br>The successful response from the server includes the <code>result</code> object. In case of error, the <code>error</code> object will be returned.</p>\n<h3 id=\"example\">Example</h3>\n<p>Request:</p>\n<p><code>{“method”: “getChatUsers”, “params”: { \"orgid\":\"16029670196176812345\" }}</code></p>\n<p>Response:</p>\n<p><code>{ “result”: [ { \"phone\": \"9001\", \"name\": \"9001\", \"id\": \"16266023844241412565\", \"state\": 2 }, { \"phone\": \"9002\", \"name\": \"9002\", \"id\": \"16271184912873588819\", \"state\": 2 }, ]}</code></p>\n<h3 id=\"important\"><strong>IMPORTANT</strong></h3>\n<p>Ringotel's APIs are not intended for code learning, and our support team does not have the ability for code mentoring. Using the Ringotel API means that the developer has at least a basic understanding of the HTTP protocol and the coding skills to implement API integration using the programming language of their choice.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"3136743","collectionId":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","publishedId":"U16bvofV","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2021-08-30T06:14:50.000Z"},"item":[{"name":"Webhook Notifications","item":[{"name":"Text Message","id":"6c23dd3e-049d-4ecc-beb1-5c529de473b8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n\t\"method\":\"message\",\n\t\"params\":{\n\t\t\"to\": \"1234567890\",\n\t\t\"from\": \"502\",\n\t\t\"orgid\": \"16287540703457500320\",\n\t\t\"userid\": \"16287541154521992797\",\n\t\t\"messageid\": \"1630253837469-a887a7c51d060d078a\",\n\t    \"sessionid\": \"1630253837483-3fb8b0b9c7e935684a\",\n\t\t\"content\":\"Hello World!\",\n\t\t\"type\": 1\n\t},\n\t\"api_key\": \"<Ringotel API Key>\"\n}\n","options":{"raw":{"language":"json"}}},"url":"https://api.example.com/webhook","description":"<p>Provide parameter <code>senderid</code> instead of <code>to</code> where applicable.</p>\n<p><code>\"type\": 1</code> - text message</p>\n<p><code>\"type\": 2</code> - file</p>\n","auth":{"type":"noauth","isInherited":true,"source":{"_postman_id":"700489e7-1587-4873-90ac-12a782627f95","id":"700489e7-1587-4873-90ac-12a782627f95","name":"Webhook Notifications","type":"folder"}},"urlObject":{"host":["https://api.example.com/webhook"],"query":[],"variable":[]}},"response":[],"_postman_id":"6c23dd3e-049d-4ecc-beb1-5c529de473b8"},{"name":"File","id":"8ccaefec-8800-4366-84cf-75d23a5a5fcf","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n\t\"method\":\"message\",\n\t\"params\":{\n\t\t\"to\": \"1234567890\",\n\t\t\"from\": \"502\",\n\t\t\"orgid\": \"16287540703457500320\",\n\t\t\"userid\": \"16287541154521992797\",\n\t\t\"messageid\": \"1630253837469-a887a7c51d060d078a\",\n\t    \"sessionid\": \"1630253837483-3fb8b0b9c7e935684a\",\n\t\t\"content\": \"...file content...\",\n\t\t\"type\": 2\n\t},\n\t\"api_key\": \"<Ringotel API Key>\"\n}\n","options":{"raw":{"language":"json"}}},"url":"https://api.example.com/webhook","auth":{"type":"noauth","isInherited":true,"source":{"_postman_id":"700489e7-1587-4873-90ac-12a782627f95","id":"700489e7-1587-4873-90ac-12a782627f95","name":"Webhook Notifications","type":"folder"}},"urlObject":{"host":["https://api.example.com/webhook"],"query":[],"variable":[]}},"response":[],"_postman_id":"8ccaefec-8800-4366-84cf-75d23a5a5fcf"},{"name":"Delivery report","id":"5db56bd5-3dfe-443e-a63a-f8c31f56109e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n\t\"method\":\"delivered\",\n\t\"params\":{\n\t\t\"messageid\": \"1630253837469-a887a7c51d060d078a\",\n\t    \"sessionid\": \"1630253837483-3fb8b0b9c7e935684a\"\n\t},\n\t\"api_key\": \"<Ringotel API Key>\"\n}\n","options":{"raw":{"language":"json"}}},"url":"https://api.example.com/webhook","auth":{"type":"noauth","isInherited":true,"source":{"_postman_id":"700489e7-1587-4873-90ac-12a782627f95","id":"700489e7-1587-4873-90ac-12a782627f95","name":"Webhook Notifications","type":"folder"}},"urlObject":{"host":["https://api.example.com/webhook"],"query":[],"variable":[]}},"response":[],"_postman_id":"5db56bd5-3dfe-443e-a63a-f8c31f56109e"},{"name":"Read report","id":"3dbcbc48-b3b9-4665-8047-fda7f30179eb","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n\t\"method\":\"read\",\n\t\"params\":{\n\t    \"sessionid\": \"1630253837483-3fb8b0b9c7e935684a\"\n\t},\n\t\"api_key\": \"<Ringotel API Key>\"\n}\n","options":{"raw":{"language":"json"}}},"url":"https://api.example.com/webhook","auth":{"type":"noauth","isInherited":true,"source":{"_postman_id":"700489e7-1587-4873-90ac-12a782627f95","id":"700489e7-1587-4873-90ac-12a782627f95","name":"Webhook Notifications","type":"folder"}},"urlObject":{"host":["https://api.example.com/webhook"],"query":[],"variable":[]}},"response":[],"_postman_id":"3dbcbc48-b3b9-4665-8047-fda7f30179eb"},{"name":"Typing indication","id":"f7a7c4c5-27b9-4eec-86a7-568213d15d36","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n\t\"method\":\"typing\",\n\t\"params\":{\n\t    \"sessionid\": \"1630253837483-3fb8b0b9c7e935684a\",\n        \"state\": \"on\"\n\t},\n\t\"api_key\": \"<Ringotel API Key>\"\n}\n","options":{"raw":{"language":"json"}}},"url":"https://api.example.com/webhook","auth":{"type":"noauth","isInherited":true,"source":{"_postman_id":"700489e7-1587-4873-90ac-12a782627f95","id":"700489e7-1587-4873-90ac-12a782627f95","name":"Webhook Notifications","type":"folder"}},"urlObject":{"host":["https://api.example.com/webhook"],"query":[],"variable":[]}},"response":[],"_postman_id":"f7a7c4c5-27b9-4eec-86a7-568213d15d36"},{"name":"Message updated","id":"6ff76d96-31c8-4338-b3cd-1905aa8b1eaf","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n\t\"method\":\"updated\",\n\t\"params\":{\n\t\t\"messageid\": \"1630253837469-a887a7c51d060d078a\",\n\t\t\"content\":\"Hello World!\"\n\t},\n\t\"api_key\": \"<Ringotel API Key>\"\n}\n","options":{"raw":{"language":"json"}}},"url":"https://api.example.com/webhook","auth":{"type":"noauth","isInherited":true,"source":{"_postman_id":"700489e7-1587-4873-90ac-12a782627f95","id":"700489e7-1587-4873-90ac-12a782627f95","name":"Webhook Notifications","type":"folder"}},"urlObject":{"host":["https://api.example.com/webhook"],"query":[],"variable":[]}},"response":[],"_postman_id":"6ff76d96-31c8-4338-b3cd-1905aa8b1eaf"},{"name":"Message deleted","id":"14920176-77fc-4c50-bfd6-20d26a904601","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n\t\"method\":\"deleted\",\n\t\"params\":{\n\t\t\"messageid\": \"1630253837469-a887a7c51d060d078a\"\n\t},\n\t\"api_key\": \"<Ringotel API Key>\"\n}\n","options":{"raw":{"language":"json"}}},"url":"https://api.example.com/webhook","auth":{"type":"noauth","isInherited":true,"source":{"_postman_id":"700489e7-1587-4873-90ac-12a782627f95","id":"700489e7-1587-4873-90ac-12a782627f95","name":"Webhook Notifications","type":"folder"}},"urlObject":{"host":["https://api.example.com/webhook"],"query":[],"variable":[]}},"response":[],"_postman_id":"14920176-77fc-4c50-bfd6-20d26a904601"}],"id":"700489e7-1587-4873-90ac-12a782627f95","description":"<p>To receive messages and notifications from the Ringotel platform, provide <code>webhook</code> parameter when creating an API Key. To authenticate requests coming to your webhook, map the <code>api_key</code> parameter that is included in the body of each request with the Ringotel API Key created in your Ringotel account. </p>\n<p>You web server can receive the following notifications:</p>\n<ul>\n<li><a href=\"#1\">Message</a></li>\n<li><a href=\"#2\">Delivery report</a></li>\n<li><a href=\"#3\">Read report</a></li>\n<li><a href=\"#4\">Typing indication</a></li>\n<li><a href=\"#5\">Message updated</a></li>\n<li><a href=\"#6\">Message deleted</a></li>\n</ul>\n","auth":{"type":"noauth","isInherited":false},"event":[{"listen":"prerequest","script":{"id":"3038250e-7098-4ab9-9661-8af20d77f823","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"ec2e17cd-355b-4058-9e2a-484306f6a5ca","type":"text/javascript","exec":[""]}}],"_postman_id":"700489e7-1587-4873-90ac-12a782627f95"},{"name":"API Methods","item":[{"name":"Get a list of users","id":"1ea4c228-2944-46a0-8f95-24201cdcfd4c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"getChatUsers\",\n    \"params\": {\n            \"orgid\": \"16287540703457500320\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"1ea4c228-2944-46a0-8f95-24201cdcfd4c"},{"name":"Send a message","id":"d928f80f-bd7c-408f-9279-6e98f9b5d4f8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"from\": \"1234567890\",\n        \"to\": \"502\",\n        \"content\": \"Hi there 👋\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","description":"<p>Sends a message to a Ringotel user via the Ringotel Messaging API.</p>\n<h2 id=\"authentication\">Authentication</h2>\n<p>This request uses <strong>Bearer Token</strong> authentication. Include a valid <a href=\"https://help.ringotel.com/en/articles/11187571-manage-api-key\">Ringotel API Key</a> in the <code>Authorization</code> header:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>Authorization: Bearer &lt;token&gt;\n\n</code></pre><h2 id=\"request-body\">Request Body</h2>\n<p>The request body must be sent as JSON (<code>Content-Type: application/json</code>).</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Field</th>\n<th>Type</th>\n<th>Required</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><code>method</code></td>\n<td>string</td>\n<td>Yes</td>\n<td>Must be <code>\"message\"</code></td>\n</tr>\n<tr>\n<td><code>params.orgid</code></td>\n<td>string</td>\n<td>No</td>\n<td>The organization ID. Alternatively use <code>params.domain</code></td>\n</tr>\n<tr>\n<td><code>params.domain</code></td>\n<td>string</td>\n<td>No</td>\n<td>The organization domain. Alternatively use <code>params.orgid</code></td>\n</tr>\n<tr>\n<td><code>params.from</code></td>\n<td>string</td>\n<td>Yes</td>\n<td>The sender's phone number.</td>\n</tr>\n<tr>\n<td><code>params.to</code></td>\n<td>string</td>\n<td>Yes</td>\n<td>The recipient Ringotel user's extension number</td>\n</tr>\n<tr>\n<td><code>params.content</code></td>\n<td>string</td>\n<td>Yes</td>\n<td>The text content of the message to send.</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"example-request-body\">Example Request Body</h3>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"method\": \"message\",\n    \"params\": {\n        \"orgid\": \"16648054657987889107\",\n        \"from\": \"101\",\n        \"to\": \"1234567890\",\n        \"content\": \"Hi there 👋\"\n    }\n}\n\n</code></pre>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[{"id":"e7aead05-98ac-48b4-8fe8-b6652ada8b2f","name":"Send a message","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"from\": \"1234567890\",\n        \"to\": \"502\",\n        \"content\": \"Hi there 👋\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null},{"id":"7aae92d5-1650-46f7-9d51-b3bb5f9f64c0","name":"Send a message (advanced)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"senderid\": \"1a2b3c4d5e6f\",\n        \"sendername\": \"John Smith\",\n        \"senderinfo\": {\n            \"phone\": \"1234567890\",\n            \"email\": \"johnsmith@example.com\"\n        },\n        \"userid\": \"16287541154521992797\",\n        \"content\": \"Hello World!\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null}],"_postman_id":"d928f80f-bd7c-408f-9279-6e98f9b5d4f8"},{"name":"Send a file","id":"ab74ef2c-f7fd-4164-ad17-a8e32ed8222e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n\t    \"domain\": \"companyabc\",\n        \"from\": \"1234567890\",\n        \"to\": \"501\",\n        \"content\": \"https://example.com/b003-21ab-cd73-ef91-4890b8399f64.jpg\",\n        \"type\": 7\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[{"id":"d33bdc4b-466c-4d54-aa45-1e81bd4d9533","name":"Send a file","originalRequest":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"orgid","value":"16287540703457500320","type":"text"},{"key":"to","value":"502\n","type":"text"},{"key":"from","value":"1234567890","type":"text"},{"key":"file","type":"file","value":null}]},"url":"https://shell.ringotel.co/api"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null},{"id":"0c9a3942-caa2-470d-a46d-d580005a052b","name":"Send a file using link","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"from\": \"1234567890\",\n        \"to\": \"502\",\n        \"content\": \"https://ringotel-app-distribution.s3.eu-west-1.amazonaws.com/assets/ringotel-logo.png\",\n        \"type\": 7\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null},{"id":"7ffda1a8-1ddb-4e27-aa5d-86c3c10621ce","name":"Send a file (advanced)","originalRequest":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"orgid","value":"16287540703457500320","type":"text"},{"key":"userid","value":"16287541154521992797","type":"text"},{"key":"senderid","value":"1a2b3c4d5e6f","type":"text"},{"key":"file","type":"file","value":null}]},"url":"https://shell.ringotel.co/api"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":null}],"_postman_id":"ab74ef2c-f7fd-4164-ad17-a8e32ed8222e"},{"name":"Send indication - Delivered","id":"2f3fe2d7-6c84-435e-80ad-4295c3fcb0f3","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"delivered\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"messageid\": \"1630253837469-a887a7c51d060d078a\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"2f3fe2d7-6c84-435e-80ad-4295c3fcb0f3"},{"name":"Send indication - Deleted","id":"7161f90f-975f-4f55-ad20-a9f987392c8f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"deleted\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"messageid\": \"1630253837469-a887a7c51d060d078a\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"7161f90f-975f-4f55-ad20-a9f987392c8f"},{"name":"Send indication - Read","id":"c277ffd2-ceb9-41a1-8757-19f04ada32c4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"read\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"sessionid\": \"1630253837483-3fb8b0b9c7e935684a\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"c277ffd2-ceb9-41a1-8757-19f04ada32c4"},{"name":"Send indication - Typing","id":"8d7ab747-e0a5-429a-8116-149de6e50761","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"typing\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"sessionid\": \"1630253837483-3fb8b0b9c7e935684a\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"8d7ab747-e0a5-429a-8116-149de6e50761"},{"name":"Send indication - Updated","id":"2582e8aa-83ac-4021-a5e1-9b3c5df7e319","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"updated\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"messageid\": \"1630253837469-a887a7c51d060d078a\",\n        \"content\": \"Hello Everyone!\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"2582e8aa-83ac-4021-a5e1-9b3c5df7e319"},{"name":"Send indication - Message","id":"6f64d924-a097-4364-82a7-489a1fe07ab4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n\t    \"orgid\": \"16287540703457500320\",\n        \"from\": \"1234567890\",\n        \"to\": \"502\",\n        \"content\": \"Hello World!\",\n        \"sessionid\": \"1710004869211-d3103a34bd2ce6023a\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"6f64d924-a097-4364-82a7-489a1fe07ab4"}],"id":"2bf779a0-2d74-4dc8-a009-5c996f3fe474","description":"<p>Use these API methods to send messages and files to the Ringotel users.</p>\n","_postman_id":"2bf779a0-2d74-4dc8-a009-5c996f3fe474","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}}},{"name":"Sync messages from external services","item":[{"name":"Create an empty session with a contact","id":"a7988f82-9087-4111-a471-697ea8bd40e6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n        \"from\": \"1234567890\",\n        \"to\": \"511\",\n        \"orgid\": \"17629027527954336546\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"a7988f82-9087-4111-a471-697ea8bd40e6"},{"name":"Create a new call activity","id":"ba10edc2-4c44-44be-9f8e-088fe3f67862","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"method\": \"message\",\n    \"params\":{\n        \"sessionid\": \"1763994283649-b99833518dce684f7c\",\n        \"content\": {\n            \"duration\":100,\n            \"caller\":\"511\",\n            \"called\":\"1234567890\",\n            \"subject\":\"Brief Utterances\",\n            \"comment\":\"The conversation consists of brief, repetitive utterances from both speakers, primarily 'Oh' and 'I don't know'.\",\n            \"transcription\":\"17191774976125638450-1759295823160-e4984da8007a55ac96.json\"\n        },\n        \"type\": 8,\n        \"timestamp\": 1733829203832,\n        \"orgid\": \"17629027527954336546\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://shell.ringotel.co/api","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}},"urlObject":{"host":["https://shell.ringotel.co/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"ba10edc2-4c44-44be-9f8e-088fe3f67862"}],"id":"1b174904-862f-45ed-b716-b744e86ea122","description":"<p>To sync a message with a specific chat session, please use the standard “message“ method with the <code>sessionid</code> parameter:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"method\": \"message\",\n    \"params\":{\n        \"from\": \"9003\",\n        \"to\": \"234567668\",\n        \"content\": \"Hello\",\n        \"orgid\": \"17076444409917912922\",\n        \"sessionid\": \"1710004869211-d3103a34bd2ce6023a\",\n        \"timestamp\": 1770118887507\n    }\n}\n\n</code></pre>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"result\": {\n        \"messageid\": \"1710100373597-8b065154afbbddfb96\"\n    }\n}\n\n</code></pre>\n<p><code>sessionid</code> refers to the existing chat session, which you receive as a response from the API server once a chat has been created.</p>\n<p>A new “sessionid“ will be returned if a message is sent to a session which is already closed.</p>\n<p>In addition, you can implicitly create a chat session for other users (if you need to sync messages with the users who don't have a chat session with an external number yet) by sending a <code>message</code> method without the <code>content</code> and <code>sessionid</code> parameters. Specify the external contact number in the <code>from</code> parameter and user’s extension number (for whom a chat session will be created) or an SMS number (DID) added via SMS integration in the <code>to</code> field:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"method\": \"message\",\n    \"params\":{\n        \"from\": \"234567668\",\n        \"to\": \"9004\",\n        \"orgid\": \"17076444409917912922\"\n    }\n}\n\n</code></pre>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"result\": {\n        \"sessionid\": \"1710098613465-02d8b0a8b078cf73e5\"\n    }\n}\n\n</code></pre>\n<p>Now you can use the provided 'sessionid' in the follow-up API request to sync the message with the user's chat session:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"method\": \"message\",\n    \"params\":{\n        \"from\": \"9003\",\n        \"to\": \"234567668\",\n        \"content\": \"Hello\",\n        \"orgid\": \"17076444409917912922\",\n        \"sessionid\": \"1710098613465-02d8b0a8b078cf73e5\"\n    }\n}\n\n</code></pre>\n<p>Alternatively, instead of <code>content</code> you can specify the <code>messageid</code> parameter, which is particularly useful for syncing files:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"method\": \"message\",\n    \"params\":{\n        \"from\": \"9003\",\n        \"to\": \"234567668\",\n        \"orgid\": \"17076444409917912922\",\n        \"messageid\": \"1710100665847-a1f4a223ffd202a9ea\",\n        \"sessionid\": \"1710098613465-02d8b0a8b078cf73e5\"\n    }\n}\n\n</code></pre>\n","_postman_id":"1b174904-862f-45ed-b716-b744e86ea122","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]},"isInherited":true,"source":{"_postman_id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","id":"29f463dc-2310-43fa-9734-a9a2d43b4a7a","name":"Ringotel Messaging API","type":"collection"}}}],"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<Ringotel API Key>"}]}},"event":[{"listen":"prerequest","script":{"id":"3e515fa3-f0f3-40b8-affb-1f9c3ce5d4d9","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"6f9e3e2d-4666-42ff-836c-b643dbe5a570","type":"text/javascript","exec":[""]}}],"variable":[{"key":"token","value":"<Ringotel API Key>"},{"key":"request_url","value":"https://shell.ringotel.co/api"},{"key":"webhook_url","value":"https://api.example.com/webhook"},{"key":"orgid","value":"16287540703457500320"},{"key":"userid","value":"16287541154521992797"},{"key":"senderid","value":"1a2b3c4d5e6f"},{"key":"user_phone","value":"502"},{"key":"sendername","value":"John Smith"},{"key":"sender_phone","value":"1234567890"},{"key":"sender_email","value":"johnsmith@example.com"},{"key":"messageid","value":"1630253837469-a887a7c51d060d078a"},{"key":"sessionid","value":"1630253837483-3fb8b0b9c7e935684a"}]}