{"info":{"_postman_id":"5f7f9bf5-6ec0-4074-9a2c-ee397ef3c22d","name":"Chathive api","description":"<html><head></head><body><h1 id=\"api-endpoint\">API endpoint</h1>\n<p>All API requests must be directed to the following base endpoint: <a href=\"https://api.chathive.app\">https://api.chathive.app</a></p>\n<h1 id=\"authentication\">Authentication</h1>\n<p>To authenticate your requests, you must include your API key in the request header:</p>\n<p>| <strong>Header</strong> | <strong>Value</strong> |<br>| <code>x-api-key</code> | <code>YOUR_API_KEY</code> |</p>\n<p>You can create, rotate, and manage your API keys directly from your <a href=\"https://chathive.app/api_key\">Chathive dashboard</a>.</p>\n<h1 id=\"status-codes\">Status codes</h1>\n<ul>\n<li><p><code>200</code> OK: The request was successfully</p>\n</li>\n<li><p><code>201</code> Created: The resource was successfully created</p>\n</li>\n<li><p><code>202</code> Accepted: The request was accepted for processing</p>\n</li>\n<li><p><code>204</code> No Content: The request was successfully but does not return anything</p>\n</li>\n<li><p><code>400</code> Bad request: The endpoint was called using invalid data</p>\n</li>\n<li><p><code>401</code> Unauthorized: The API key is missing, invalid, or lacks necessary permissions.</p>\n</li>\n<li><p><code>404</code> Resource not found: Make sure the correct URL was used</p>\n</li>\n<li><p><code>429</code> Too many requests: See Rate limits for more inforation</p>\n</li>\n<li><p><code>500</code> Internal Server Error: An unexpected error occurred. <a href=\"https://support@chathive.co\">Contact support</a> if this problem keeps occurring.</p>\n</li>\n</ul>\n<h1 id=\"rate-limit\">Rate limit</h1>\n<p>Rate limiting is enforced per API key using a <strong>sliding window</strong>.</p>\n<ul>\n<li><p><strong>Standard Limit</strong>: 512 requests per minute.</p>\n</li>\n<li><p><strong>Knowledge Set Operations</strong>: <code>POST</code>, <code>PUT</code>, <code>PATCH</code>, and <code>DELETE</code> requests for are limited to <strong>32 requests per minute</strong>.</p>\n</li>\n</ul>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[{"content":"API endpoint","slug":"api-endpoint"},{"content":"Authentication","slug":"authentication"},{"content":"Status codes","slug":"status-codes"},{"content":"Rate limit","slug":"rate-limit"}],"owner":"21518222","collectionId":"5f7f9bf5-6ec0-4074-9a2c-ee397ef3c22d","publishedId":"2s9YC31uAP","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"publishDate":"2023-09-12T12:42:45.000Z"},"item":[{"name":"Analytics","item":[{"name":"Get total conversations","id":"1ddf506a-2269-42ee-947b-964968f296f6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/analytics/conversation/statistics","description":"<p>Get conversation statistics for a project</p>\n<ul>\n<li><p>TotalMessages</p>\n</li>\n<li><p>TotalConversations</p>\n</li>\n<li><p>AvgMessages</p>\n</li>\n</ul>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>analytics.read</li>\n</ul>\n<h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>from</strong></td>\n<td>timestamp</td>\n<td>Calculate statistics from this timestamp</td>\n</tr>\n<tr>\n<td><strong>to</strong></td>\n<td>timestamp</td>\n<td>Calculate statistics until this timestamp</td>\n</tr>\n<tr>\n<td><strong>projectId</strong></td>\n<td>string</td>\n<td>Necessary if api key has no specific or multiple projects</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n\"TotalMessages\": 10,\n\"TotalConversations\": 5,\n\"AvgMessages\": 2\n}\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","analytics","conversation","statistics"],"host":["https://api.chathive.app"],"query":[{"disabled":true,"description":{"content":"<p>timestamp</p>\n","type":"text/plain"},"key":"from","value":""},{"disabled":true,"description":{"content":"<p>timestamp</p>\n","type":"text/plain"},"key":"to","value":""},{"disabled":true,"description":{"content":"<p>Necessary if api key has no specific </p>\n","type":"text/plain"},"key":"projectId","value":""}],"variable":[]}},"response":[],"_postman_id":"1ddf506a-2269-42ee-947b-964968f296f6"}],"id":"ae702bcb-b9e5-4469-8dc7-cef00e504fc5","_postman_id":"ae702bcb-b9e5-4469-8dc7-cef00e504fc5","description":""},{"name":"Chat","item":[{"name":"Get welcomes message","id":"d6cc9517-bf40-4bb3-8bd0-4ff8ca49fc3c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/chat/welcome_message?language=nl&stream=true","description":"<p>Get the welcome message for a specific language.<br />If language is not provided the default language from the project will be used.</p>\n<h2 id=\"query-parameters\">Query parameters</h2>\n<ul>\n<li><strong>language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</li>\n<li><strong>stream</strong>: boolean value default false (optional)<br />  If true the response will stream the welcome message in chunks as a response</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<h3 id=\"welcome-message-found\">Welcome message found</h3>\n<p>Stream: false</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"👋 Welcome to our website! Need assistance?. Don't hesitate to start the conversation. 😊\"\n}\n\n</code></pre>\n<p>Stream: true</p>\n<p>Streams the welcome message in parts</p>\n<blockquote>\n<p>Stream responses can result in abnormal response in Postman. </p>\n</blockquote>\n<h3 id=\"no-welcome-message\">No welcome message</h3>\n<p>status code: <strong>404</strong></p>\n","urlObject":{"path":["api","v1.0","chat","welcome_message"],"host":["https://api.chathive.app"],"query":[{"key":"language","value":"nl"},{"key":"stream","value":"true"}],"variable":[]}},"response":[],"_postman_id":"d6cc9517-bf40-4bb3-8bd0-4ff8ca49fc3c"},{"name":"Get lead generation fields","id":"3b8fad3d-b982-40ca-a1b3-77e2d639c90b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/chat/lead_generation/fields?language=en","description":"<p>Get the lead generation fields for the given language.</p>\n<p>If language is not set, the default language will be used.</p>\n<h2 id=\"query-parameters\">Query parameters</h2>\n<ul>\n<li><strong>language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p>Each fields contains the following configurations</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>Field</strong></th>\n<th><strong>Description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Index</td>\n<td>Order in which field must be displayed</td>\n</tr>\n<tr>\n<td>Key</td>\n<td>The key of the field that is used when sending the lead generation back through the API</td>\n</tr>\n<tr>\n<td>Type</td>\n<td>The type of input is expected</td>\n</tr>\n<tr>\n<td>IsRequired</td>\n<td>If the field is required or is optional</td>\n</tr>\n<tr>\n<td>Config.label</td>\n<td>Label of the field</td>\n</tr>\n<tr>\n<td>Config.placeholder</td>\n<td>Placeholder for the field (optional)</td>\n</tr>\n<tr>\n<td>Config.helpText</td>\n<td>Extra information for the customer to help them fill in the field (optional)</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"reponse-body\">Reponse body</h3>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"language\": \"en\",\n    \"fields\": [{\n        \"index\": 0,\n        \"key\": \"email\",\n        \"type\": \"email\" | \"text\" | \"number\" | \"textarea\",\n        \"isRequired\": true,\n        \"config\": {\n            \"label\": \"Email\",\n            \"placeholder\": \"johndoe@vlaio.be\",\n            \"helpText\": \"Optional help text\",\n        },\n    }],\n}\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","chat","lead_generation","fields"],"host":["https://api.chathive.app"],"query":[{"key":"language","value":"en"}],"variable":[]}},"response":[],"_postman_id":"3b8fad3d-b982-40ca-a1b3-77e2d639c90b"},{"name":"Get message resource","id":"1e98fd23-b67f-403e-ba51-1a79a3308af3","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/chat/session/:sessionId/message/:messageId/source_reference","description":"<p>Get source references from a message</p>\n<h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">[\n    {\n        \"_id\": \"650046d782aa54000862e299\",\n        \"url\": \"https://chathive.co/platform\",\n        \"title\": \"platform - chathive\",\n        \"rootUrl\": \"https://chathive.co\",\n        \"type\": \"website\",\n        \"createdAt\": \"2023-09-12T11:09:11.727Z\",\n        \"updatedAt\": \"2023-09-12T11:09:12.650Z\",\n        \"score\": 0.760878384,\n        \"chunkId\": \"650046d782aa54000862e299_0\"\n    }\n]\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","chat","session",":sessionId","message",":messageId","source_reference"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"NHoM8frF-ncDcZEaYi1ed_GT","key":"sessionId"},{"type":"any","value":"6920fc81a82c3dc46095fbc0","key":"messageId"}]}},"response":[],"_postman_id":"1e98fd23-b67f-403e-ba51-1a79a3308af3"},{"name":"Send message","event":[{"listen":"prerequest","script":{"id":"f342a895-28fd-46fd-ba18-225e586cf6e2","exec":["const interval = setTimeout(() => {}, Number.MAX_SAFE_INTEGER);","","let promiseNumber = 0;","","function resolvedPromise() {","    return new Promise((resolve, reject) => {","        pm.sendRequest(\"http://localhost:5050/external_todo_rename/v1/send_message\", (err, res) => {","            if (err) {","                console.log(err);","                reject();","            } else {","                console.log(`Resolved promise ${++promiseNumber}`);","                resolve();","            }","        });","    });","}","","resolvedPromise()","    .then(resolvedPromise)","    .then(resolvedPromise)","    .then(() => clearTimeout(interval))","    .catch(err => {","        console.log(err);","        clearTimeout(interval);","    });"],"type":"text/javascript","packages":{},"requests":{}}}],"id":"0d56d68b-8561-4bc4-bcaf-059f107f445c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"x-api-key","value":"your_api_key"}],"body":{"mode":"raw","raw":"{\n    \"message\": \"Hallo\",\n    \"language\": \"en\",\n    \"allowToolCall\": true,\n    \"sessionId\": \"postman_test\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/chat/send_message","description":"<p>Send message and get a GPT generated reply</p>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li><p><strong>message</strong>: Message prompt</p>\n</li>\n<li><p><strong>language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</p>\n</li>\n<li><p><strong>sessionId</strong>: Unique string generated by you to distindistinguish conversations. When sessionId change all previous conversation context will be lost and it will be like a new conversation has started</p>\n</li>\n<li><p><strong>allowToolCall</strong>: enabled or disable tool calls (optional)<br />  Default true</p>\n</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p>Api returns a stream event where the response is sent back incrementally in chunks.</p>\n<ul>\n<li><p><strong>Data:</strong> partial string of the resposne</p>\n<ul>\n<li>can contain markdown formatting</li>\n</ul>\n</li>\n<li><p><strong>End</strong>: when all chunks are send</p>\n</li>\n<li><p><strong>Error</strong>: When something went wrong</p>\n</li>\n</ul>\n<h3 id=\"response-header\">Response header</h3>\n<p>The response header contains the following values</p>\n<ul>\n<li><p><strong>messageId</strong>: the id of the response message</p>\n<ul>\n<li><em>Tip can be used to fetch the message sources</em></li>\n</ul>\n</li>\n<li><p><strong>sessionId:</strong> the session id to which the message belongs to.</p>\n</li>\n</ul>\n<blockquote>\n<p>Stream responses are not supported in postman, postman test can result in abnormal response.</p>\n</blockquote>\n","urlObject":{"path":["api","v1.0","chat","send_message"],"host":["https://api.chathive.app"],"query":[],"variable":[]}},"response":[],"_postman_id":"0d56d68b-8561-4bc4-bcaf-059f107f445c"},{"name":"Send lead generation","event":[{"listen":"prerequest","script":{"id":"f342a895-28fd-46fd-ba18-225e586cf6e2","exec":["const interval = setTimeout(() => {}, Number.MAX_SAFE_INTEGER);","","let promiseNumber = 0;","","function resolvedPromise() {","    return new Promise((resolve, reject) => {","        pm.sendRequest(\"http://localhost:5050/external_todo_rename/v1/send_message\", (err, res) => {","            if (err) {","                console.log(err);","                reject();","            } else {","                console.log(`Resolved promise ${++promiseNumber}`);","                resolve();","            }","        });","    });","}","","resolvedPromise()","    .then(resolvedPromise)","    .then(resolvedPromise)","    .then(() => clearTimeout(interval))","    .catch(err => {","        console.log(err);","        clearTimeout(interval);","    });"],"type":"text/javascript","packages":{}}}],"id":"4b2deb63-79b4-444d-94b1-67638e7b7711","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"x-api-key","value":"your_api_key"}],"body":{"mode":"raw","raw":"{\n    \"language\": \"nl\",\n    \"fields\": { \"email\": \"\", [key]: \"value\" }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/chat/session/:sessionId/lead_generation","description":"<p>Send lead generation field data and get a GPT generated reply.</p>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li><strong>language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</li>\n<li><strong>fields</strong>: key value object where the keys should match the field keys given in the lead generation fields.</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p>Api returns a stream where each chunk is part of the response message</p>\n<blockquote>\n<p>Stream responses are not supported in postman, postman test can result in abnormal response.</p>\n</blockquote>\n","urlObject":{"path":["api","v1.0","chat","session",":sessionId","lead_generation"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"sessionId"}]}},"response":[],"_postman_id":"4b2deb63-79b4-444d-94b1-67638e7b7711"},{"name":"Vote message","event":[{"listen":"prerequest","script":{"id":"f342a895-28fd-46fd-ba18-225e586cf6e2","exec":["const interval = setTimeout(() => {}, Number.MAX_SAFE_INTEGER);","","let promiseNumber = 0;","","function resolvedPromise() {","    return new Promise((resolve, reject) => {","        pm.sendRequest(\"http://localhost:5050/external_todo_rename/v1/send_message\", (err, res) => {","            if (err) {","                console.log(err);","                reject();","            } else {","                console.log(`Resolved promise ${++promiseNumber}`);","                resolve();","            }","        });","    });","}","","resolvedPromise()","    .then(resolvedPromise)","    .then(resolvedPromise)","    .then(() => clearTimeout(interval))","    .catch(err => {","        console.log(err);","        clearTimeout(interval);","    });"],"type":"text/javascript","packages":{}}}],"id":"d8ab70da-be0e-4bce-8295-aba386724db8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"vote\": \"positive | negative\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/chat/session/:sessionId/message/:messageId/vote","description":"<p>Let the chat contact vote on a message</p>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li>vote: positive | negative</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p>status code 201 on success</p>\n","urlObject":{"path":["api","v1.0","chat","session",":sessionId","message",":messageId","vote"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"postman_test","key":"sessionId"},{"type":"any","value":"","key":"messageId"}]}},"response":[],"_postman_id":"d8ab70da-be0e-4bce-8295-aba386724db8"},{"name":"Update conversation","event":[{"listen":"prerequest","script":{"id":"f342a895-28fd-46fd-ba18-225e586cf6e2","exec":["const interval = setTimeout(() => {}, Number.MAX_SAFE_INTEGER);","","let promiseNumber = 0;","","function resolvedPromise() {","    return new Promise((resolve, reject) => {","        pm.sendRequest(\"http://localhost:5050/external_todo_rename/v1/send_message\", (err, res) => {","            if (err) {","                console.log(err);","                reject();","            } else {","                console.log(`Resolved promise ${++promiseNumber}`);","                resolve();","            }","        });","    });","}","","resolvedPromise()","    .then(resolvedPromise)","    .then(resolvedPromise)","    .then(() => clearTimeout(interval))","    .catch(err => {","        console.log(err);","        clearTimeout(interval);","    });"],"type":"text/javascript","packages":{}}}],"id":"0eeb36f7-99a8-4990-bf5b-fee9e33e51aa","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"customer\": {\n        \"id\": \"string\",\n        \"email\": \"string\",\n        \"lastName\": \"string\",\n        \"firstName\": \"string\",\n        \"avatar\": \"string\"\n    },\n    \"context\": {\n        \"key\": \"string | number | undefined | boolean\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/chat/session/:sessionId","description":"<p>Update a conversation and provide extra information to the conversation.</p>\n<blockquote>\n<p>This is a experimental API and may be subjected to changes </p>\n</blockquote>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li><p>Customer: Information about the person who is sending a message (optional)</p>\n<ul>\n<li><p>id: Unique id of the customer from you (optional)</p>\n</li>\n<li><p>email (optional)</p>\n</li>\n<li><p>lastName (optional)</p>\n</li>\n<li><p>firstName (optional)</p>\n</li>\n<li><p>avatar (optional)</p>\n</li>\n</ul>\n</li>\n<li><p>Context: extra context that will be given to the agent to provide beter responses (optional)<br />  this is a object with key and string value</p>\n</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p>status code 204 on success</p>\n","urlObject":{"path":["api","v1.0","chat","session",":sessionId"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"postman_test","key":"sessionId"}]}},"response":[],"_postman_id":"0eeb36f7-99a8-4990-bf5b-fee9e33e51aa"}],"id":"8ac66b55-307a-4312-a95c-f8aebebfdc4d","_postman_id":"8ac66b55-307a-4312-a95c-f8aebebfdc4d","description":""},{"name":"Documents","item":[{"name":"Create text document","id":"268914c3-fea3-4833-9c20-104af08bf36a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"x-api-key","value":"your_api_key"}],"body":{"mode":"raw","raw":"{\n    \"type\": \"text\",\n    \"title\": \"\",\n    \"text\": \"\",\n    \"projectId\": \"\",\n    \"priority\": \"veryLow | low | default | high | veryHigh | topPriority\",\n    \"language\": \"en\",\n    \"documentDate\": \"2024-08-24\",\n    \"meta\": {\n        \"key\": \"string | number | undefined\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/document","description":"<p>Update a text document</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>document.write</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li><p><strong>Title</strong>: title of the document</p>\n</li>\n<li><p><strong>Text:</strong> content of the document</p>\n</li>\n<li><p><strong>ProjectId:</strong> project where this document must be added to, only necessary when API key has access multiple projects (optional)</p>\n</li>\n<li><p><strong>Type</strong>: text</p>\n</li>\n<li><p><strong>Priority:</strong> default to <strong>default</strong> (optional)</p>\n</li>\n<li><p><strong>Language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</p>\n</li>\n<li><p><strong>DocumentDate</strong>: Date of the content not the date of creation (optional)</p>\n</li>\n<li><p><strong>Meta</strong>: Object with extra values that can be used to improve document detection</p>\n</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 201</p>\n<h2 id=\"response-1\">Response</h2>\n<p><strong>Status</strong>: 200</p>\n<ul>\n<li><strong>DocumentId</strong>: id of the document</li>\n</ul>\n","urlObject":{"path":["api","v1.0","document"],"host":["https://api.chathive.app"],"query":[],"variable":[]}},"response":[],"_postman_id":"268914c3-fea3-4833-9c20-104af08bf36a"},{"name":"Create faq document","id":"8b9ee91c-44ac-44f8-a721-f6054e3761f4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"x-api-key","value":"your_api_key"}],"body":{"mode":"raw","raw":"{\n    \"type\": \"faq\",\n    \"answer\": \"\",\n    \"question\": \"\",\n    \"projectId\": \"\",\n    \"priority\": \"veryLow | low | default | high | veryHigh | topPriority\",\n    \"language\": \"en\",\n    \"documentDate\": \"2024-08-24\",\n    \"meta\": {\n        \"key\": \"string | number | undefined\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/document","description":"<p>Update a text document</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>document.write</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li><p><strong>Question</strong> (optional)</p>\n</li>\n<li><p><strong>Answer:</strong> (optional)<br />  <em>if answer is not set, no new training tokens will be used</em></p>\n</li>\n<li><p><strong>ProjectId:</strong> project where this document must be added to, only necessary when API key has access multiple projects (optional)</p>\n</li>\n<li><p><strong>Type</strong>: faq</p>\n</li>\n<li><p><strong>Priority:</strong> default to <strong>default</strong> (optional)</p>\n</li>\n<li><p><strong>Language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</p>\n</li>\n<li><p><strong>DocumentDate</strong>: Date of the content not the date of creation (optional)</p>\n</li>\n<li><p><strong>Meta</strong>: Object with extra values that can be used to improve document detection</p>\n</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 201</p>\n<ul>\n<li><strong>DocumentId</strong>: id of the document</li>\n</ul>\n","urlObject":{"path":["api","v1.0","document"],"host":["https://api.chathive.app"],"query":[],"variable":[]}},"response":[],"_postman_id":"8b9ee91c-44ac-44f8-a721-f6054e3761f4"},{"name":"Update text document","id":"d0d3c623-37e5-4f4e-aae1-bb38b37aa435","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"x-api-key","value":"your_api_key"}],"body":{"mode":"raw","raw":"{\n    \"title\": \"d\",\n    \"text\": \"d\",\n    \"type\": \"text\",\n    \"priority\": \"veryLow | low | default | high | veryHigh | topPriority\",\n    \"language\": \"en\",\n    \"documentDate\": \"2024-08-24\",\n    \"meta\": {\n        \"key\": \"string | number | undefined\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/document/:documentId","description":"<p>Update a text document</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>document.write</li>\n</ul>\n<h2 id=\"params\">params</h2>\n<ul>\n<li><strong>DocumentId</strong>: id of the document you want to update</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li><p><strong>Title</strong>: title of the document (optional)</p>\n</li>\n<li><p><strong>Text:</strong> content of the document (optional)<br />  <em>if text is not set, no new training tokens will be used</em></p>\n</li>\n<li><p><strong>Type</strong>: text</p>\n</li>\n<li><p><strong>Priority:</strong> default to <strong>default</strong> (optional)</p>\n</li>\n<li><p><strong>Language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</p>\n</li>\n<li><p><strong>DocumentDate</strong>: Date of the content not the date of creation (optional)</p>\n</li>\n<li><p><strong>Meta</strong>: Object with extra values that can be used to improve document detection</p>\n</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 200</p>\n<h2 id=\"response-1\">Response</h2>\n<p><strong>Status</strong>: 200</p>\n<ul>\n<li><p><strong>DocumentId</strong>: previous document id</p>\n</li>\n<li><p><strong>NewDocumentId</strong>: if document id has changed this will be the id of the new document</p>\n</li>\n</ul>\n","urlObject":{"path":["api","v1.0","document",":documentId"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"documentId"}]}},"response":[],"_postman_id":"d0d3c623-37e5-4f4e-aae1-bb38b37aa435"},{"name":"Update FAQ document","id":"00d5aef4-1cbe-47e1-908d-584a46bc395c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"x-api-key","value":"your_api_key"}],"body":{"mode":"raw","raw":"{\n    \"answer\": \"\",\n    \"question\": \"\",\n    \"type\": \"faq\",\n    \"priority\": \"veryLow | low | default | high | veryHigh | topPriority\",\n    \"language\": \"en\",\n    \"documentDate\": \"2024-08-24\",\n    \"meta\": {\n        \"key\": \"string | number | undefined\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/document/:documentId","description":"<p>Update a text document</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>document.write</li>\n</ul>\n<h2 id=\"params\">params</h2>\n<ul>\n<li><strong>DocumentId</strong>: id of the document you want to update</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<ul>\n<li><p><strong>Question</strong> (optional)</p>\n</li>\n<li><p><strong>Answer:</strong> (optional)<br />  <em>if answer is not set, no new training tokens will be used</em></p>\n</li>\n<li><p><strong>Type</strong>: faq</p>\n</li>\n<li><p><strong>Priority:</strong> default to <strong>default</strong> (optional)</p>\n</li>\n<li><p><strong>Language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</p>\n</li>\n<li><p><strong>DocumentDate</strong>: Date of the content not the date of creation (optional)</p>\n</li>\n<li><p><strong>Meta</strong>: Object with extra values that can be used to improve document detection</p>\n</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 200</p>\n<h2 id=\"response-1\">Response</h2>\n<p><strong>Status</strong>: 200</p>\n<ul>\n<li><p><strong>DocumentId</strong>: previous document id</p>\n</li>\n<li><p><strong>NewDocumentId</strong>: if document id has changed this will be the id of the new document</p>\n</li>\n</ul>\n","urlObject":{"path":["api","v1.0","document",":documentId"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"documentId"}]}},"response":[],"_postman_id":"00d5aef4-1cbe-47e1-908d-584a46bc395c"},{"name":"Delete document","id":"c2754603-46b9-4410-91aa-879eac6b60c7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/document/:documentId","description":"<p>Delete document by id</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>document.delete</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p><strong>status</strong>: 200</p>\n","urlObject":{"path":["api","v1.0","document",":documentId"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"documentId"}]}},"response":[],"_postman_id":"c2754603-46b9-4410-91aa-879eac6b60c7"}],"id":"1066c1df-8169-4533-b896-bbbd09ea3203","_postman_id":"1066c1df-8169-4533-b896-bbbd09ea3203","description":""},{"name":"Projects","item":[{"name":"Get list of projects","id":"013543f8-401d-42ba-a163-4e16aef3ff03","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/project?limit=20&offset=0","description":"<p>Get list of all projects in the organization</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>project.read</li>\n</ul>\n<h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>limit</strong></td>\n<td>number</td>\n<td>Total number of projects to return</td>\n</tr>\n<tr>\n<td><strong>offset</strong></td>\n<td>number</td>\n<td>Form which position start to return projects</td>\n</tr>\n<tr>\n<td><strong>q</strong></td>\n<td>string</td>\n<td>Search on project name</td>\n</tr>\n<tr>\n<td><strong>type</strong></td>\n<td>\"chatbot\", \"aiForm\", \"llmAgent\"</td>\n<td>Filter on project type</td>\n</tr>\n<tr>\n<td>includePrivate</td>\n<td>boolean</td>\n<td>Include private projects in the results.  <br />API key must have permission to access private projects.</td>\n</tr>\n<tr>\n<td>folderId</td>\n<td>string</td>\n<td>Get projects within the folder</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"data\": [{\n    \"_id\": 1,\n    \"organizationId\": 2,\n    \"name\": \"project name\",\n    \"avatar\": \"icon.png\",\n    \"agent\": {\n      \"name\": \"agent name\",\n      \"avatar\": \"agent_avatar.png\",\n    },\n    \"isPrivate\": false,\n    \"folderId\": 1,\n    \"businessScope\": \"external\",\n    \"apiKey\": \"aiek893kaikd-32cd\",\n    \"createdAt\": \"2024-10-07T09:40:00.000+00:00\",\n    \"updatedAt\": \"2024-10-07T09:40:00.000+00:00\",\n  }],\n  \"meta\": {\n    \"limit\": 20,\n    \"offset\":0,\n    \"total\":1,\n  }\n}\n\n</code></pre>\n","auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"api-key"},{"key":"value","value":"<value>"}]},"isInherited":true,"source":{"_postman_id":"fcc8d167-8983-4532-b2de-8519c2846f87","id":"fcc8d167-8983-4532-b2de-8519c2846f87","name":"Projects","type":"folder"}},"urlObject":{"path":["api","v1.0","project"],"host":["https://api.chathive.app"],"query":[{"key":"limit","value":"20"},{"key":"offset","value":"0"},{"disabled":true,"key":"q","value":""},{"disabled":true,"key":"type","value":"chatbot | aiForm | llmAgent"},{"disabled":true,"key":"includePrivate","value":"true"},{"disabled":true,"key":"folderId","value":""}],"variable":[]}},"response":[],"_postman_id":"013543f8-401d-42ba-a163-4e16aef3ff03"},{"name":"Get list of project folders","id":"2f923bbe-e015-4163-9e25-7a284ce2b64d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/project/folders?limit=20&offset=0","description":"<p>Get list of all projects in the organization</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>project.read</li>\n</ul>\n<h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>limit</strong></td>\n<td>number</td>\n<td>Total number of projects to return</td>\n</tr>\n<tr>\n<td><strong>offset</strong></td>\n<td>number</td>\n<td>Form which position start to return projects</td>\n</tr>\n<tr>\n<td><strong>q</strong></td>\n<td>string</td>\n<td>Search on project name</td>\n</tr>\n<tr>\n<td><strong>type</strong></td>\n<td>\"chatbot\", \"aiForm\", \"llmAgent\"</td>\n<td>Filter on project type</td>\n</tr>\n<tr>\n<td>includePrivate</td>\n<td>boolean</td>\n<td>Include private projects in the results.  <br />API key must have permission to access private projects.</td>\n</tr>\n<tr>\n<td>folderId</td>\n<td>string</td>\n<td>Get projects within the folder</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"data\": [{\n    \"_id\": 1,\n    \"organizationId\": 2,\n    \"name\": \"project name\",\n    \"avatar\": \"icon.png\",\n    \"agent\": {\n      \"name\": \"agent name\",\n      \"avatar\": \"agent_avatar.png\",\n    },\n    \"isPrivate\": false,\n    \"folderId\": 1,\n    \"businessScope\": \"external\",\n    \"apiKey\": \"aiek893kaikd-32cd\",\n    \"createdAt\": \"2024-10-07T09:40:00.000+00:00\",\n    \"updatedAt\": \"2024-10-07T09:40:00.000+00:00\",\n  }],\n  \"meta\": {\n    \"limit\": 20,\n    \"offset\":0,\n    \"total\":1,\n  }\n}\n\n</code></pre>\n","auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"api-key"},{"key":"value","value":"<value>"}]},"isInherited":true,"source":{"_postman_id":"fcc8d167-8983-4532-b2de-8519c2846f87","id":"fcc8d167-8983-4532-b2de-8519c2846f87","name":"Projects","type":"folder"}},"urlObject":{"path":["api","v1.0","project","folders"],"host":["https://api.chathive.app"],"query":[{"key":"limit","value":"20"},{"key":"offset","value":"0"},{"disabled":true,"key":"q","value":""},{"disabled":true,"key":"includePrivate","value":"true"},{"disabled":true,"key":"folderId","value":""}],"variable":[]}},"response":[],"_postman_id":"2f923bbe-e015-4163-9e25-7a284ce2b64d"}],"id":"fcc8d167-8983-4532-b2de-8519c2846f87","auth":{"type":"apikey","apikey":{"basicConfig":[{"key":"key","value":"api-key"},{"key":"value","value":"<value>"}]},"isInherited":false},"event":[{"listen":"prerequest","script":{"id":"13ae1512-a53e-4291-8c9c-9c44e894ddaf","type":"text/javascript","packages":{},"exec":[""]}},{"listen":"test","script":{"id":"834bdae8-2aef-4445-842d-c40efb4f8320","type":"text/javascript","packages":{},"exec":[""]}}],"_postman_id":"fcc8d167-8983-4532-b2de-8519c2846f87","description":""},{"name":"Sessions","item":[{"name":"Get list of sessions","id":"a9b70a03-bedf-4570-8f31-f71d9a5f2e7b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/session?offset=0&limit=20","description":"<p>Get list of all sessions in the project</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>session.read</li>\n</ul>\n<h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>limit</strong></td>\n<td>number</td>\n<td>Total number of sessions to return</td>\n</tr>\n<tr>\n<td><strong>offset</strong></td>\n<td>number</td>\n<td>Form which position start to return sessions</td>\n</tr>\n<tr>\n<td><strong>cursor</strong></td>\n<td>string</td>\n<td>Provided cursor from your previous request to return the next batch of sessions</td>\n</tr>\n<tr>\n<td><strong>archivedOnly</strong></td>\n<td>boolean</td>\n<td>Only return archived sessions</td>\n</tr>\n<tr>\n<td><strong>status</strong></td>\n<td>\"created\" , \"inProgress\",</td>\n<td>\"stopped\", \"started\", \"completed\"</td>\n</tr>\n<tr>\n<td><strong>seen</strong></td>\n<td>\"seen\", \"unseen\", \"all</td>\n<td>seen: only return session that has been reviewed by a user  <br />unseen: only retun session that has been reviewed  <br />all: return both seen and unseen sessions</td>\n</tr>\n<tr>\n<td><strong>from</strong></td>\n<td>timestamp</td>\n<td>Return session from this timestamp</td>\n</tr>\n<tr>\n<td><strong>to</strong></td>\n<td>timestamp</td>\n<td>Return session until this timestamp</td>\n</tr>\n<tr>\n<td><strong>projectId</strong></td>\n<td>string</td>\n<td>Necessary if api key has no specific or multiple projects</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"data\": [{\n    \"projectId\": \"3lkcsd3yyb6gx0r8jy9ugsap\",\n    \"sessionId\": \"8syyfp6r6vg4et9h4czebvud\",\n    \"organizationId\": \"gq0950c4yikccepvzzar9x6f\",\n    \"customer\": {\n        \"id\": \"ym6civsf9i2cphcoma5x9j8a\",\n        \"email\": \"customer@email.co\",\n        \"lastName\": \"doe\",\n        \"firstName\": \"john\",\n        \"avatar\": \"avatar.png\",\n    },\n    \"status\": \"completed\",\n    \"seenBy\": false,\n    \"createdAt\": \"2024-10-07T09:40:00.000+00:00\",\n    \"updatedAt\": \"2024-10-07T09:40:00.000+00:00\",\n    \"completedAt\": undefined,\n    \"stoppedAt\": undefined,\n    \"archivedAt\": undefined,\n}],\n  \"meta\": {\n    \"limit\": 20,\n    \"offset\":0,\n    \"total\":1,\n    \"cursor\": \"next-cursor\",\n  }\n}\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","session"],"host":["https://api.chathive.app"],"query":[{"description":{"content":"<p>Form which position start to return session.</p>\n","type":"text/plain"},"key":"offset","value":"0"},{"description":{"content":"<p>Total number of sessions to return.</p>\n","type":"text/plain"},"key":"limit","value":"20"},{"disabled":true,"description":{"content":"<p>Provided cursor from your previous request to return the next batch of sessions.</p>\n","type":"text/plain"},"key":"cursor","value":""},{"disabled":true,"description":{"content":"<p>true | false</p>\n","type":"text/plain"},"key":"archivedOnly","value":""},{"disabled":true,"description":{"content":"<p>\"created\" | \"inProgress\" | \"stopped\" | \"started\" | \"completed\"</p>\n","type":"text/plain"},"key":"status","value":""},{"disabled":true,"description":{"content":"<p>timestamp</p>\n","type":"text/plain"},"key":"from","value":""},{"disabled":true,"description":{"content":"<p>timestamp</p>\n","type":"text/plain"},"key":"to","value":""},{"disabled":true,"description":{"content":"<p>\"seen\" | \"unseen\" | \"all\"</p>\n","type":"text/plain"},"key":"seen","value":""},{"disabled":true,"description":{"content":"<p>Necessary if api key has no specific </p>\n","type":"text/plain"},"key":"projectId","value":""}],"variable":[]}},"response":[],"_postman_id":"a9b70a03-bedf-4570-8f31-f71d9a5f2e7b"},{"name":"Get session detail","id":"da5b5bc9-04c2-424b-9cce-1c03b9872f02","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/session/:sessionId","description":"<p>Get session detail</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>session.read</li>\n</ul>\n<h2 id=\"params\">params</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>sessionId</strong></td>\n<td>string</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>projectId</strong></td>\n<td>string</td>\n<td>Necessary if api key has no specific or multiple projects</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"data\": {\n    \"projectId\": \"3lkcsd3yyb6gx0r8jy9ugsap\",\n    \"sessionId\": \"8syyfp6r6vg4et9h4czebvud\",\n    \"organizationId\": \"gq0950c4yikccepvzzar9x6f\",\n    \"customer\": {\n        \"id\": \"ym6civsf9i2cphcoma5x9j8a\",\n        \"email\": \"customer@email.co\",\n        \"lastName\": \"doe\",\n        \"firstName\": \"john\",\n        \"avatar\": \"avatar.png\",\n    },\n    \"status\": \"completed\",\n    \"seenBy\": false,\n    \"createdAt\": \"2024-10-07T09:40:00.000+00:00\",\n    \"updatedAt\": \"2024-10-07T09:40:00.000+00:00\",\n    \"completedAt\": undefined,\n    \"stoppedAt\": undefined,\n    \"archivedAt\": undefined,\n  }\n}\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","session",":sessionId"],"host":["https://api.chathive.app"],"query":[{"disabled":true,"key":"projectId","value":""}],"variable":[{"type":"any","value":"684350847df520b0c1d8a473","key":"sessionId"}]}},"response":[],"_postman_id":"da5b5bc9-04c2-424b-9cce-1c03b9872f02"},{"name":"Add tags","id":"8fb1fa5b-7eae-4a27-bf9c-4abf8e2be8e1","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"tagIds\": [ \"67f786d3adbb349ed7550eea\", \"67f78648d61dbb1b5e00fad4\"]\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/session/:sessionId/tags","description":"<p>Add 1 or more tags to a session.</p>\n<p>If any of the provided tags are not part of the API’s organization, none of the tags will be added.</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>session.write</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>tagIds</strong></td>\n<td>string array</td>\n<td>List of tagIds</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 204</p>\n","urlObject":{"path":["api","v1.0","session",":sessionId","tags"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"sessionId"}]}},"response":[],"_postman_id":"8fb1fa5b-7eae-4a27-bf9c-4abf8e2be8e1"},{"name":"Archive session","id":"c1c87fd2-54f6-4e4f-b30a-5e41124d0e5f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{ \"archive\": true }","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/session/:sessionId/archive","description":"<p>Archive / unarchive session</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>session.read</li>\n</ul>\n<h2 id=\"params\">params</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>sessionId</strong></td>\n<td>string</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>projectId</strong></td>\n<td>string</td>\n<td>Necessary if api key has no specific or multiple projects</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"body\">Body</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n<th><strong>required</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>archive</strong></td>\n<td>boolean</td>\n<td>True: archive session  <br />False: unarchive session</td>\n<td>true</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 200</p>\n","urlObject":{"path":["api","v1.0","session",":sessionId","archive"],"host":["https://api.chathive.app"],"query":[{"disabled":true,"key":"projectId","value":""}],"variable":[{"type":"any","value":"","key":"sessionId"}]}},"response":[],"_postman_id":"c1c87fd2-54f6-4e4f-b30a-5e41124d0e5f"},{"name":"Update session","id":"ee63c5ed-bf7f-4d46-af2b-1738e91f7f17","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[{"key":"x-api-key","value":"1929099fb102fj0k8lMiYb523mKZpIXeVA9heL01WIicF4b1IBO6MerfXZMohp1PPeRSa2zKDMq7iybn8i0GOkHwZQT-bg1A7WS1vlxYzJKhWU7NTzB8LCaS0EhEwbtxFKiBSbZKLqtRcQPrL7IIr8RfjYEMkcturmuIQoBJ1jnNvfFaiMn2biBtx6JNzJVEQiU274F9U1t0wmAXGB8XLmEsYY4jxVsRRf2UL45d8UzYrkUc856wEgtNUaKt0QBnZrJ4fktdjhK","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"meta\": {\n        \"letsgo\": true,\n        \"nice\": false\n    },\n    \"customerData\": {\n        \"id\": \"d\",\n        \"email\": \"qf\",\n        \"lastName\": \"\",\n        \"firstName\": \"sfd\",\n        \"avatar\": \"\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/session/1924cb98172EnMfyp2Bmiewkw_ZOC2t4-rw","description":"<p>Session has limited fields that can be updated.</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>session.read</li>\n</ul>\n<h2 id=\"params\">params</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>sessionId</strong></td>\n<td>string</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>projectId</strong></td>\n<td>string</td>\n<td>Necessary if api key has no specific or multiple projects</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"body\">Body</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>meta</strong></td>\n<td>object</td>\n<td>Meta data to save extra data with the session</td>\n</tr>\n<tr>\n<td><strong>customerData</strong></td>\n<td>customerObject</td>\n<td>Information about the customer who filled in the session</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"customerobject\">CustomerObject</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>id</strong></td>\n<td>string</td>\n<td>Id of the customer in your system</td>\n</tr>\n<tr>\n<td><strong>email</strong></td>\n<td>string</td>\n<td></td>\n</tr>\n<tr>\n<td><strong>firstName</strong></td>\n<td>string</td>\n<td></td>\n</tr>\n<tr>\n<td><strong>lastName</strong></td>\n<td>string</td>\n<td></td>\n</tr>\n<tr>\n<td><strong>avatar</strong></td>\n<td>string</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 200</p>\n","urlObject":{"path":["api","v1.0","session","1924cb98172EnMfyp2Bmiewkw_ZOC2t4-rw"],"host":["https://api.chathive.app"],"query":[{"disabled":true,"key":"projectId","value":""}],"variable":[]}},"response":[],"_postman_id":"ee63c5ed-bf7f-4d46-af2b-1738e91f7f17"},{"name":"Delete tags","id":"4e205c94-2eeb-4614-bb80-b4faae6bfe66","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"tagIds\": [ \"67f78648d61dbb1b5e00fad4\"]\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/session/:sessionId/tags","description":"<p><strong>Remove one or more tags from a session</strong><br />If any of the provided tags are not part of the API’s organization, none of the tags will be removed.</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>session.write</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>tagIds</strong></td>\n<td>string array</td>\n<td>List of tagIds</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<p><strong>Status</strong>: 204</p>\n","urlObject":{"path":["api","v1.0","session",":sessionId","tags"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"sessionId"}]}},"response":[],"_postman_id":"4e205c94-2eeb-4614-bb80-b4faae6bfe66"}],"id":"24f86077-7849-4687-88b4-47a460bc6964","_postman_id":"24f86077-7849-4687-88b4-47a460bc6964","description":""},{"name":"Tags","item":[{"name":"Get list of tags","id":"a2b79ec5-5116-46be-b15e-a8a66a6d7c54","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/tag?offset=0&limit=20","description":"<p>Get list of all tags in the organization</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>tag.read</li>\n</ul>\n<h2 id=\"query-parameters\">Query parameters</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>limit</strong></td>\n<td>number</td>\n<td>Total number of tags to return. Must be smaller than 1000</td>\n</tr>\n<tr>\n<td><strong>offset</strong></td>\n<td>number</td>\n<td>Form which position start to return projects</td>\n</tr>\n<tr>\n<td><strong>q</strong></td>\n<td>string</td>\n<td>Search on tag name</td>\n</tr>\n<tr>\n<td><strong>compact</strong></td>\n<td>Boolean</td>\n<td>When true, conversation count is not included. Default this is false.</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"data\": [\n        {\n            \"_id\": \"Pq0950c4yikcca32zzargxp9\",\n            \"color\": \"#000000\",\n            \"name\": \"tagName\",\n            \"description\": \"tagDescription\",\n            \"organizationId\": \"gq0950c4yikccepvzzar9x6f\",\n            \"createdBy\": {\n                \"_id\": \"3\",\n                \"lastName\": \"creatorLastName\",\n                \"firstName\": \"creatorFirstName\"\n            },\n            \"createdAt\": \"2025-03-20T14:50:33.159Z\",\n            \"updatedAt\": \"2025-03-20T14:50:33.159Z\",\n            \"__v\": 0,\n            \"conversationCount\": 0\n        }\n    ],\n    \"total\": 3,\n    \"tagCountAllTags\": 3\n}\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","tag"],"host":["https://api.chathive.app"],"query":[{"description":{"content":"<p>Total number of tags to return. Must be smaller than 1 000.</p>\n","type":"text/plain"},"key":"offset","value":"0"},{"description":{"content":"<p>Form which position start to return projects.</p>\n","type":"text/plain"},"key":"limit","value":"20"},{"disabled":true,"description":{"content":"<p>Search on tag name.</p>\n","type":"text/plain"},"key":"q","value":""},{"disabled":true,"description":{"content":"<p>true | false\nWhen true, conversation count is not included.</p>\n","type":"text/plain"},"key":"compact","value":"true"}],"variable":[]}},"response":[],"_postman_id":"a2b79ec5-5116-46be-b15e-a8a66a6d7c54"},{"name":"Create tag","id":"b00f35e5-700d-4843-8358-beb37aa08734","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"name\": \"Tag name\",\n    \"description\": \"When to use the tag\",\n    \"color\": \"#F8C945\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/tag","description":"<p>Create a new tag in the organization</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>tag.write</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>Name</strong></td>\n<td>string</td>\n<td>Name of the tag.</td>\n</tr>\n<tr>\n<td><strong>Description</strong></td>\n<td>string</td>\n<td>Description of the tag (optional).</td>\n</tr>\n<tr>\n<td><strong>Color</strong></td>\n<td>hex</td>\n<td>color of the tag (optional).</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"_id\": \"Pq0950c4yikcca32zzargxp9\",\n    \"color\": \"#F8C945\",\n    \"name\": \"tagName\",\n    \"description\": \"tagDescription\",\n    \"organizationId\": \"gq0950c4yikccepvzzar9x6f\",\n    \"createdBy\": \"loP910c4yi1c4ar1poa3g5ae\",\n    \"createdAt\": \"2025-03-25T10:59:02.927Z\",\n    \"updatedAt\": \"2025-03-25T10:59:02.927Z\",\n    \"__v\": 0\n}\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","tag"],"host":["https://api.chathive.app"],"query":[],"variable":[]}},"response":[],"_postman_id":"b00f35e5-700d-4843-8358-beb37aa08734"},{"name":"Update tag","id":"aad7576d-ee2f-4daa-bb0a-057f2bd75809","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"name\": \"Tag name\",\n    \"description\": \"\",\n    \"color\": \"#002140\"\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/tag/:tagId","description":"<p>Update a tag by id</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>tag.write</li>\n</ul>\n<h2 id=\"body\">Body</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>key</strong></th>\n<th><strong>type</strong></th>\n<th><strong>description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td><strong>Name</strong></td>\n<td>string</td>\n<td>Name of the tag (optional)..</td>\n</tr>\n<tr>\n<td><strong>Description</strong></td>\n<td>string</td>\n<td>Description of the tag (optional).</td>\n</tr>\n<tr>\n<td><strong>Color</strong></td>\n<td>hex</td>\n<td>color of the tag (optional).</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"response\">Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"_id\": \"Pq0950c4yikcca32zzargxp9\",\n    \"name\": \"tagName\",\n    \"description\": \"\",\n    \"color\": \"#F8C945\",\n    \"organizationId\": \"gq0950c4yikccepvzzar9x6f\",\n    \"createdAt\": \"2025-03-26T10:23:33.507Z\",\n    \"updatedAt\": \"2025-03-26T11:51:46.396Z\",\n    \"__v\": 0\n}\n\n</code></pre>\n","urlObject":{"path":["api","v1.0","tag",":tagId"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"tagId"}]}},"response":[],"_postman_id":"aad7576d-ee2f-4daa-bb0a-057f2bd75809"},{"name":"Delete tag","id":"43547146-9882-485e-946c-e60f0d9374fa","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/tag/:tagId","description":"<p>Delete a tag by id</p>\n<h2 id=\"permissions\">Permissions</h2>\n<ul>\n<li>tag.write</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<p>Status: 204</p>\n","urlObject":{"path":["api","v1.0","tag",":tagId"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"","key":"tagId"}]}},"response":[],"_postman_id":"43547146-9882-485e-946c-e60f0d9374fa"}],"id":"f06aef04-54e1-41f5-aef6-af6d8b1aa9da","_postman_id":"f06aef04-54e1-41f5-aef6-af6d8b1aa9da","description":""},{"name":"Trigger","item":[{"name":"Execute trigger","id":"f93073cf-19c0-4742-ab4b-749964f53b4f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"body":{"mode":"raw","raw":"{\n    \"instruction\": \"string | object\",\n    \"sessionId\": \"string\",\n    \"environment\": \"string\",\n    \"language\": \"en\",\n    \"timezone\": \"Europe/Brussels\",\n    \"customer\": {\n        \"id\": \"string\",\n        \"email\": \"string\",\n        \"lastName\": \"string\",\n        \"firstName\": \"string\",\n        \"avatar\": \"string\"\n    },\n    \"context\": {\n        \"key\": \"string | number | undefined | boolean\"\n    }\n}","options":{"raw":{"language":"json"}}},"url":"https://api.chathive.app/api/v1.0/project/:projectId/trigger/:key","description":"<ul>\n<li><p><strong>Instruction</strong>: Extra instruction that will be provided to the agent, can be a string or object (optional)</p>\n</li>\n<li><p><strong>language</strong>: <a href=\"https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes\">ISO 639-1 language codes</a> (optional)</p>\n</li>\n<li><p><strong>sessionId</strong>: Unique string generated by you to distindistinguish conversations. When sessionId change all previous conversation context will be lost and it will be like a new conversation has started (optional)</p>\n</li>\n<li><p><strong>Environment</strong>: String that can be used to identify in the analytics from where the request came. Default: \"api\" (optional)</p>\n</li>\n<li><p><strong>Timezone</strong>: Override the default timezone of your project. (optional)</p>\n</li>\n<li><p><strong>Customer</strong>: Customer information that should be used and linked to the conversation.(optional)</p>\n<ul>\n<li><p>id: Unique id of the customer from you (optional)</p>\n</li>\n<li><p>email (optional)</p>\n</li>\n<li><p>lastName (optional)</p>\n</li>\n<li><p>firstName (optional)</p>\n</li>\n<li><p>avatar (optional)</p>\n</li>\n</ul>\n</li>\n<li><p><strong>Context</strong>: Extra context that will be given to the agent to provide beter responses (optional)<br />  this is a object with key and string value</p>\n</li>\n</ul>\n","urlObject":{"path":["api","v1.0","project",":projectId","trigger",":key"],"host":["https://api.chathive.app"],"query":[],"variable":[{"type":"any","value":"6899a03c6a0d062b110026b8","key":"projectId"},{"type":"any","value":"test_api","key":"key"}]}},"response":[],"_postman_id":"f93073cf-19c0-4742-ab4b-749964f53b4f"}],"id":"9948075c-a24f-438a-95b1-dc38f64f090b","_postman_id":"9948075c-a24f-438a-95b1-dc38f64f090b","description":""},{"name":"verify","id":"9b502257-c703-48a6-9f8b-12eba77ab169","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"your_api_key","type":"text"}],"url":"https://api.chathive.app/api/v1.0/verify","description":"<p>Verify if the API key is valid</p>\n<h2 id=\"response\">Response</h2>\n<p>status code: <strong>200</strong></p>\n","urlObject":{"path":["api","v1.0","verify"],"host":["https://api.chathive.app"],"query":[],"variable":[]}},"response":[],"_postman_id":"9b502257-c703-48a6-9f8b-12eba77ab169"},{"name":"New Request","id":"9b736c03-c804-4fe7-ba2e-953fdf993991","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"urlObject":{"query":[],"variable":[]},"url":""},"response":[],"_postman_id":"9b736c03-c804-4fe7-ba2e-953fdf993991"}],"event":[{"listen":"prerequest","script":{"id":"5ded0802-6293-4a89-b580-57d6a31d155d","type":"text/javascript","requests":{},"exec":[""]}},{"listen":"test","script":{"id":"fbaddfc3-6834-43fb-8b1b-300779feef17","type":"text/javascript","requests":{},"exec":[""]}}],"variable":[{"key":"api-key","value":"your_api_key"},{"key":"base_url","value":"https://api.chathive.app"}]}