{"info":{"_postman_id":"f143c61a-233a-4419-9cb3-f7dee0bf3147","name":"Axon Desk Open API v1.0","description":"<html><head></head><body><p>These APIs can be useful for our users Third party application developers (integrators).</p>\n<p>In order to access the below listed APIs, you must have valid client_id and secret.</p>\n<h3 id=\"scope-of-openapis\"><strong>Scope of OpenAPIs</strong></h3>\n<p>To perform the operations that will be required to perform read and write operations. <em>Example of Read operations:</em> Get the desk information, Get the status of the desk, Get the status of the device, etc. <em>Example of Write operations:</em> desks height.</p>\n<h3 id=\"api-security\">API Security</h3>\n<p><strong>Signature algorithm for token management operations:</strong></p>\n<p>sign = HMAC-SHA256(client_id + t , secret).toUpperCase()</p>\n<p><strong>Procedure to create a sign request:</strong></p>\n<p>UUID (sign) is generated by the API caller by Concatenating the value of client_id with the 13-digit standard timestamp (t) of the specified request to create a string.<br>Create a hash digest value (HMAC-SHA256) based on the string and the value of secret. Encode the hash digest value into a new string followed by capitalizing all letters of the new string.</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Parameter</th>\n<th>Type</th>\n<th>Location</th>\n<th>Required</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>client_id</td>\n<td>String</td>\n<td>header</td>\n<td>Yes</td>\n<td>The user ID.</td>\n</tr>\n<tr>\n<td>sign</td>\n<td>String</td>\n<td>header</td>\n<td>Yes</td>\n<td>The signature that is generated by a specified signature algorithm.</td>\n</tr>\n<tr>\n<td>t</td>\n<td>Long</td>\n<td>header</td>\n<td>Yes</td>\n<td>The 13-digit standard timestamp.</td>\n</tr>\n<tr>\n<td>access_token</td>\n<td>String</td>\n<td>header</td>\n<td>Yes</td>\n<td>The information about the token.</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"how-to-use-apis-in-postman\">How to use APIs in postman:</h3>\n<ul>\n<li><p>postman web</p>\n</li>\n<li><p>postman application for windows/MAC</p>\n</li>\n</ul>\n<p>The postman collection is ready to use with the <em>OpenAPI</em> environment attached. On this documentation page, you will find run in postman on the top right, once you click on any of the above options, it will allow you to create a free account in postman and clone the collection and environment to your workspace (Collection consists all API requests and environment consists of variables used within collection).</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"40689992","collectionId":"f143c61a-233a-4419-9cb3-f7dee0bf3147","publishedId":"2sAYdkFoAG","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"publishDate":"2025-05-11T16:31:12.000Z"},"item":[{"name":"Auth","item":[{"name":"token","event":[{"listen":"prerequest","script":{"exec":["\r","(function () { \r","    var timestamp = getTime();\r","    pm.environment.set(\"timestamp\",timestamp);\r","    var clientId = pm.environment.get(\"client_id\");\r","    var secret = pm.environment.get(\"secret\");\r","    var sign = calcSign(clientId,secret,timestamp);\r","    pm.environment.set('easy_sign', sign);\r","})();\r","\r","function getTime(){\r","    var timestamp = new Date().getTime();\r","    return timestamp;\r","}\r","\r","function calcSign(clientId,secret,timestamp){\r","    var CryptoJSlib = require('crypto-js')\r","    var str = clientId + timestamp;\r","    var hash = CryptoJSlib.HmacSHA256(str, secret);\r","    var hashInBase64 = hash.toString();\r","    var signUp = hashInBase64.toUpperCase();\r","    return signUp;\r","}"],"type":"text/javascript","packages":{},"id":"6c25c2de-5792-406a-960f-d246da27822f"}},{"listen":"test","script":{"exec":["pm.test(\"Your test name\", function () {\r","    var jsonData = pm.response.json();\r","    if(jsonData.state){\r","       pm.environment.set('access_token', jsonData.access_token); \r","    }\r","});"],"type":"text/javascript","packages":{},"id":"eeac28f5-94d1-41ad-af58-8bd547b7c876"}}],"id":"7622186f-2fa1-416a-8be0-d1e49497c9c8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"client_id","value":"{{client_id}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"url":"{{host}}/v1.0/auth/token","description":"<p>CreateToken API will generate access token .</p>\n<ul>\n<li><p><strong>Token API:</strong></p>\n<ul>\n<li><p>Issues an access token upon successful user authentication.</p>\n</li>\n<li><p>Generates a new access token with each request to the Token API.</p>\n</li>\n</ul>\n</li>\n</ul>\n<p>Store the generated access token in below variables as pre/post-scripts are programmed to use them.</p>\n<ul>\n<li>access_token = access_token</li>\n</ul>\n<p><em>Default expiry of token is is {{expire_in}} in seconds.</em></p>\n","urlObject":{"path":["v1.0","auth","token"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[{"id":"5647f3fd-4d79-4be9-8253-555f81b0ca1d","name":"token","originalRequest":{"method":"GET","header":[{"key":"client_id","value":"{{client_id}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"url":"{{host}}/v1.0/auth/token"},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"access_token\": \"{{access_token}}\",\r\n    \"expire_in\": 7200 //default 7200\r\n}"}],"_postman_id":"7622186f-2fa1-416a-8be0-d1e49497c9c8"}],"id":"340cf632-6d58-41b1-9390-07e34ff6661e","description":"<p>The below APIs will help you fetch access token . These token are to be used in the APIs listed below.</p>\n","_postman_id":"340cf632-6d58-41b1-9390-07e34ff6661e"},{"name":"Devices","item":[{"name":"getDevices","event":[{"listen":"prerequest","script":{"id":"8ed69c35-38bf-4ee4-bbdc-710af0d5f52c","exec":["(function () { \r","    var timestamp = getTime();\r","    pm.environment.set(\"timestamp\",timestamp);\r","    var clientId = pm.environment.get(\"client_id\");\r","    var secret = pm.environment.get(\"secret\");\r","    var sign = calcSign(clientId,secret,timestamp);\r","    pm.environment.set('easy_sign', sign);\r","})();\r","\r","function getTime(){\r","    var timestamp = new Date().getTime();\r","    return timestamp;\r","}\r","\r","function calcSign(clientId,secret,timestamp){\r","    var CryptoJSlib = require('crypto-js')\r","    var str = clientId + timestamp;\r","    var hash = CryptoJSlib.HmacSHA256(str, secret);\r","    var hashInBase64 = hash.toString();\r","    var signUp = hashInBase64.toUpperCase();\r","    return signUp;\r","}"],"type":"text/javascript","packages":{}}}],"id":"e5b6cca9-363d-49d8-9b8c-2081ae0db2a7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"url":"{{host}}/v1.0/devices/get?device_type={{device_type}}","description":"<p>This API must be used to get all device_type controller devices using a valid access token by passing in the request of the API.</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>query params</strong></th>\n<th><strong>value</strong></th>\n<th><strong>description</strong></th>\n<th><strong>requied</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>device_type</td>\n<td>desk/display</td>\n<td>desk controller devices</td>\n<td>default while be desk</td>\n</tr>\n<tr>\n<td>name</td>\n<td></td>\n<td>search by device name</td>\n<td>optional</td>\n</tr>\n</tbody>\n</table>\n</div>","urlObject":{"path":["v1.0","devices","get"],"host":["{{host}}"],"query":[{"description":{"content":"<p>desk/display</p>\n","type":"text/plain"},"key":"device_type","value":"{{device_type}}"}],"variable":[]}},"response":[{"id":"656f2da6-3130-4ecf-939c-ea153d73de31","name":"getDeskControllerDevices","originalRequest":{"method":"GET","header":[{"key":"access_token","value":"","type":"text"},{"key":"sign","value":"","type":"text"},{"key":"t","value":"","type":"text"}],"url":{"raw":"{{host}}/v1.0/devices/get?device_type={{device_type}}","host":["{{host}}"],"path":["v1.0","devices","get"],"query":[{"key":"device_type","value":"{{device_type}}","description":"desk"}]}},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": [\r\n        {\r\n            \"uuid\": \"{{device unique id}}\",\r\n            \"name\": \"{{name of the device}}\",\r\n            \"mac_id\": \"{{Mac Address}}\",\r\n            \"online\": {{true/false}},\r\n            \"date\": \"{{created date}}\"\r\n            \"version\": {{version}},\r\n            \"ssid\": {{wifi name}}\r\n        }\r\n    ]\r\n}"},{"id":"7dc2df5b-cb7c-4410-839f-c999e4249860","name":"getDisplayDevices","originalRequest":{"method":"GET","header":[{"key":"access_token","value":"","type":"text"},{"key":"sign","value":"","type":"text"},{"key":"t","value":"","type":"text"}],"url":{"raw":"{{host}}/v1.0/devices/get?device_type={{device_type}}","host":["{{host}}"],"path":["v1.0","devices","get"],"query":[{"key":"device_type","value":"{{device_type}}"}]}},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": [\r\n        {\r\n            \"uuid\": \"{{device unique id}}\",\r\n            \"name\": \"{{name of the device}}\",\r\n            \"mac_id\": \"{{Mac Address}}\",\r\n            \"online\": {{true/false}},\r\n            \"date\": \"{{created date}}\"\r\n            \"version\": {{version}},\r\n            \"ssid\": {{wifi name}}\r\n        }\r\n    ]\r\n}"},{"id":"1eb58ead-b54a-47fa-8b38-deba7d7f8655","name":"getDisplayDevicesName","originalRequest":{"method":"GET","header":[{"key":"access_token","value":"","type":"text"},{"key":"sign","value":"","type":"text"},{"key":"t","value":"","type":"text"}],"url":{"raw":"{{host}}/v1.0/devices/get?device_type={{device_type}}&name={{name}}","host":["{{host}}"],"path":["v1.0","devices","get"],"query":[{"key":"device_type","value":"{{device_type}}"},{"key":"name","value":"{{name}}"}]}},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": [\r\n        {\r\n            \"uuid\": \"{{device unique id}}\",\r\n            \"name\": \"{{name of the device}}\",\r\n            \"mac_id\": \"{{Mac Address}}\",\r\n            \"online\": {{true/false}},\r\n            \"date\": \"{{created date}}\"\r\n            \"version\": {{version}},\r\n            \"ssid\": {{wifi name}}\r\n        }\r\n    ]\r\n}"},{"id":"bf4a2f95-5683-4499-97c9-58219eea551c","name":"getDeskControllerDevicesbyName","originalRequest":{"method":"GET","header":[{"key":"access_token","value":"","type":"text"},{"key":"sign","value":"","type":"text"},{"key":"t","value":"","type":"text"}],"url":{"raw":"{{host}}/v1.0/devices/get?device_type={{device_type}}&name={{name}}","host":["{{host}}"],"path":["v1.0","devices","get"],"query":[{"key":"device_type","value":"{{device_type}}"},{"key":"name","value":"{{name}}","type":"text"}]}},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": [\r\n        {\r\n            \"uuid\": \"{{device unique id}}\",\r\n            \"name\": \"{{name of the device}}\",\r\n            \"mac_id\": \"{{Mac Address}}\",\r\n            \"online\": {{true/false}},\r\n            \"date\": \"{{created date}}\"\r\n            \"version\": {{version}},\r\n            \"ssid\": {{wifi name}}\r\n        }\r\n    ]\r\n}"}],"_postman_id":"e5b6cca9-363d-49d8-9b8c-2081ae0db2a7"},{"name":"getDevice","event":[{"listen":"prerequest","script":{"id":"4acc810f-2a58-4474-b486-5d3419456f1b","exec":["(function () { \r","    var timestamp = getTime();\r","    pm.environment.set(\"timestamp\",timestamp);\r","    var clientId = pm.environment.get(\"client_id\");\r","    var secret = pm.environment.get(\"secret\");\r","    var sign = calcSign(clientId,secret,timestamp);\r","    pm.environment.set('easy_sign', sign);\r","})();\r","\r","function getTime(){\r","    var timestamp = new Date().getTime();\r","    return timestamp;\r","}\r","\r","function calcSign(clientId,secret,timestamp){\r","    var CryptoJSlib = require('crypto-js')\r","    var str = clientId + timestamp;\r","    var hash = CryptoJSlib.HmacSHA256(str, secret);\r","    var hashInBase64 = hash.toString();\r","    var signUp = hashInBase64.toUpperCase();\r","    return signUp;\r","}"],"type":"text/javascript","packages":{}}}],"id":"fc7314e8-c562-4ad1-bca5-99e733be888a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"url":"{{host}}/v1.0/devices/{{uuid}}/get","description":"<p>This API must be used to get any one device using in a particular {{uuid}} using a valid access token by passing in the request of the API.</p>\n","urlObject":{"path":["v1.0","devices","{{uuid}}","get"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[{"id":"0f8cebad-69ca-4528-b704-d2493026477c","name":"getDevice","originalRequest":{"method":"GET","header":[{"key":"access_token","value":"","type":"text"},{"key":"sign","value":"","type":"text"},{"key":"t","value":"","type":"text"}],"url":"{{host}}/v1.0/devices/{{uuid}}/get"},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": {\r\n            \"uuid\": \"{{device unique id}}\",\r\n            \"name\": \"{{name of the device}}\",\r\n            \"mac_id\": \"{{Mac Address}}\",\r\n            \"online\": {{true/false}},\r\n            \"date\": \"{{created date}}\"\r\n            \"version\": {{version}},\r\n            \"ssid\": {{wifi name}}\r\n        }\r\n}"}],"_postman_id":"fc7314e8-c562-4ad1-bca5-99e733be888a"}],"id":"0c92778a-786c-4d6f-84c9-6e267f6f5e6a","description":"<p>By using below APIs we can get the device information.</p>\n","_postman_id":"0c92778a-786c-4d6f-84c9-6e267f6f5e6a"},{"name":"Control Devices","item":[{"name":"set height","event":[{"listen":"prerequest","script":{"id":"080d106e-3463-4f04-b914-8dec196e99db","exec":["(function () { \r","    var timestamp = getTime();\r","    pm.environment.set(\"timestamp\",timestamp);\r","    var clientId = pm.environment.get(\"client_id\");\r","    var secret = pm.environment.get(\"secret\");\r","    var sign = calcSign(clientId,secret,timestamp);\r","    pm.environment.set('easy_sign', sign);\r","})();\r","\r","function getTime(){\r","    var timestamp = new Date().getTime();\r","    return timestamp;\r","}\r","\r","function calcSign(clientId,secret,timestamp){\r","    var CryptoJSlib = require('crypto-js')\r","    var str = clientId + timestamp;\r","    var hash = CryptoJSlib.HmacSHA256(str, secret);\r","    var hashInBase64 = hash.toString();\r","    var signUp = hashInBase64.toUpperCase();\r","    return signUp;\r","}"],"type":"text/javascript","packages":{}}}],"id":"c7690516-cefd-4253-9e0f-90b79a7c877d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"height\":{{value}}\r\n}","options":{"raw":{"language":"json"}}},"url":"{{host}}/v1.0/devices/{{uuid}}/command","description":"<p>To set height of the device using {{uuid}} and body pass the height value.</p>\n","urlObject":{"path":["v1.0","devices","{{uuid}}","command"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[{"id":"716c9e0f-8d25-4fef-9134-26dea95837ae","name":"setDeviceCommand","originalRequest":{"method":"POST","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"height\":{{value}}\r\n}","options":{"raw":{"language":"json"}}},"url":"{{host}}/v1.0/devices/{{uuid}}/height"},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": {\r\n        \"$metadata\": {\r\n            \"httpStatusCode\": 200,\r\n            \"requestId\": \"713ff43a-6505-4d49-4e29-9b72aaab3186\",\r\n            \"attempts\": 1,\r\n            \"totalRetryDelay\": 0\r\n        }\r\n    }\r\n}"}],"_postman_id":"c7690516-cefd-4253-9e0f-90b79a7c877d"},{"name":"display state","event":[{"listen":"prerequest","script":{"id":"080d106e-3463-4f04-b914-8dec196e99db","exec":["(function () { \r","    var timestamp = getTime();\r","    pm.environment.set(\"timestamp\",timestamp);\r","    var clientId = pm.environment.get(\"client_id\");\r","    var secret = pm.environment.get(\"secret\");\r","    var sign = calcSign(clientId,secret,timestamp);\r","    pm.environment.set('easy_sign', sign);\r","})();\r","\r","function getTime(){\r","    var timestamp = new Date().getTime();\r","    return timestamp;\r","}\r","\r","function calcSign(clientId,secret,timestamp){\r","    var CryptoJSlib = require('crypto-js')\r","    var str = clientId + timestamp;\r","    var hash = CryptoJSlib.HmacSHA256(str, secret);\r","    var hashInBase64 = hash.toString();\r","    var signUp = hashInBase64.toUpperCase();\r","    return signUp;\r","}"],"type":"text/javascript","packages":{},"requests":{}}}],"id":"9fdcc848-cc42-4935-83fd-8636c48e6eea","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"state\":\"{{value}}\",\r\n    \"qr_data\":\"welcome\",\r\n    \"brightness\":75,\r\n    \"booked_name\":\"ryan d\",\r\n    \"booked_time\":\"until 5PM\",\r\n    \"image_url\":\"https://axonsolutions.com.au/logo.svg\"\r\n}","options":{"raw":{"language":"json"}}},"url":"{{host}}/v1.0/devices/{{uuid}}/command","description":"<p>To set state of the device using {{uuid}} and body pass the state value.</p>\n<p>To set brightness of the device using {{uuid}} and body pass the brightness value.</p>\n<p>To set qr data of the device using {{uuid}} and body pass the qr data value.</p>\n<p>To set booked time of the device using {{uuid}} and body pass the booked time value.</p>\n<p>To set booked name of the device using {{uuid}} and body pass the booked name value.</p>\n<p>To set profile image of thr device useing {{uuid}} and body pass the image url value.</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>keys</strong></th>\n<th><strong>value</strong></th>\n<th><strong>requried(any one should be in body)</strong></th>\n<th><strong>example</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>state</td>\n<td>available  <br />in use  <br />booked  <br />evacuation</td>\n<td>NO</td>\n<td>available</td>\n</tr>\n<tr>\n<td>brightness</td>\n<td>0-100</td>\n<td>NO</td>\n<td>any value 0 to 100</td>\n</tr>\n<tr>\n<td>qr_data</td>\n<td>200 character limit</td>\n<td>NO</td>\n<td>url or any valid data</td>\n</tr>\n<tr>\n<td>booked_time</td>\n<td>20 character limit</td>\n<td>NO</td>\n<td>ex: 2 PM - 3 PM</td>\n</tr>\n<tr>\n<td>booked_name</td>\n<td>30 character limit</td>\n<td>NO</td>\n<td>ex: JACK</td>\n</tr>\n<tr>\n<td>message</td>\n<td>60 character limit</td>\n<td>NO</td>\n<td>ex: Welcome</td>\n</tr>\n<tr>\n<td>image_url</td>\n<td>500 character limit</td>\n<td>NO</td>\n<td>ex:<a href=\"https://axonsolutions.com.au/logo.svg\">https://axonsolutions.com.au/logo.svg</a></td>\n</tr>\n</tbody>\n</table>\n</div>","urlObject":{"path":["v1.0","devices","{{uuid}}","command"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[{"id":"f24aea1d-37dd-421c-a789-e6b37ce84beb","name":"display state","originalRequest":{"method":"POST","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"state\":\"available/in use/booked/evacuation\",\r\n    \"brightness\":\"0 to 100\",\r\n    \"message\":\"40 character message\",\r\n    \"qr_data\":\"200 character QR code data\",\r\n    \"booked_time\":\"20 character booked time\",\r\n    \"booked_name\":\"20 character booked name\",\r\n    \"image_url\":\"https://axonsolutions.com.au/logo.svg\"\r\n}","options":{"raw":{"language":"json"}}},"url":"{{host}}/v1.0/devices/{{uuid}}/command"},"_postman_previewlanguage":null,"header":null,"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": {\r\n        \"$metadata\": {\r\n            \"httpStatusCode\": 200,\r\n            \"requestId\": \"c83d0b73-61cf-acab-1c47-505ca3c73b4a\",\r\n            \"attempts\": 1,\r\n            \"totalRetryDelay\": 0\r\n        }\r\n    }\r\n}"}],"_postman_id":"9fdcc848-cc42-4935-83fd-8636c48e6eea"},{"name":"getDeviceState","event":[{"listen":"prerequest","script":{"id":"0aa1e0b5-0c6a-4f26-8aec-8c8b24c64744","exec":["(function () { \r","    var timestamp = getTime();\r","    pm.environment.set(\"timestamp\",timestamp);\r","    var clientId = pm.environment.get(\"client_id\");\r","    var secret = pm.environment.get(\"secret\");\r","    var sign = calcSign(clientId,secret,timestamp);\r","    pm.environment.set('easy_sign', sign);\r","})();\r","\r","function getTime(){\r","    var timestamp = new Date().getTime();\r","    return timestamp;\r","}\r","\r","function calcSign(clientId,secret,timestamp){\r","    var CryptoJSlib = require('crypto-js')\r","    var str = clientId + timestamp;\r","    var hash = CryptoJSlib.HmacSHA256(str, secret);\r","    var hashInBase64 = hash.toString();\r","    var signUp = hashInBase64.toUpperCase();\r","    return signUp;\r","}"],"type":"text/javascript","packages":{}}}],"id":"8d60fd11-761f-46ee-a85b-a2161f726de3","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"url":"{{host}}/v1.0/devices/{{uuid}}/state","description":"<p>To get status of the device using {{uuid}}.</p>\n","urlObject":{"path":["v1.0","devices","{{uuid}}","state"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[{"id":"ddf06ed0-b25e-4415-9363-95037bcc2df6","name":"getDeviceHeight","originalRequest":{"method":"GET","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"url":"{{host}}/v1.0/devices/{{uuid}}/state"},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": {\r\n        \"online\": true,\r\n        \"height\": \"82\"\r\n    }\r\n}"},{"id":"a85805c4-ba79-46a5-8c02-e593d53e2f8a","name":"getDeviceState","originalRequest":{"method":"GET","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"url":"{{host}}/v1.0/devices/{{uuid}}/state"},"_postman_previewlanguage":"","header":[],"cookie":[{"expires":"Invalid Date","domain":"","path":""}],"responseTime":null,"body":"{\r\n    \"state\": true,\r\n    \"data\": {\r\n        \"brightness\": 25,\r\n        \"message\": \"\",\r\n        \"booked_time\": \"\",\r\n        \"state\": \"available\",\r\n        \"qr_data\": \"\",\r\n        \"ts\": 1756300817189\r\n    }\r\n}"}],"_postman_id":"8d60fd11-761f-46ee-a85b-a2161f726de3"}],"id":"9cf48e56-ad6e-4650-bf36-58e586cd0809","description":"<p>The below APIs will help to control the device.</p>\n","_postman_id":"9cf48e56-ad6e-4650-bf36-58e586cd0809"},{"name":"Image","item":[{"name":"imageupload","event":[{"listen":"prerequest","script":{"id":"4acc810f-2a58-4474-b486-5d3419456f1b","exec":["(function () { \r","    var timestamp = getTime();\r","    pm.environment.set(\"timestamp\",timestamp);\r","    var clientId = pm.environment.get(\"client_id\");\r","    var secret = pm.environment.get(\"secret\");\r","    var sign = calcSign(clientId,secret,timestamp);\r","    pm.environment.set('easy_sign', sign);\r","})();\r","\r","function getTime(){\r","    var timestamp = new Date().getTime();\r","    return timestamp;\r","}\r","\r","function calcSign(clientId,secret,timestamp){\r","    var CryptoJSlib = require('crypto-js')\r","    var str = clientId + timestamp;\r","    var hash = CryptoJSlib.HmacSHA256(str, secret);\r","    var hashInBase64 = hash.toString();\r","    var signUp = hashInBase64.toUpperCase();\r","    return signUp;\r","}"],"type":"text/javascript","packages":{},"requests":{}}}],"id":"58d1520b-08a2-4744-8688-e299dca3f765","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"access_token","value":"{{access_token}}","type":"text"},{"key":"sign","value":"{{easy_sign}}","type":"text"},{"key":"t","value":"{{timestamp}}","type":"text"}],"body":{"mode":"formdata","formdata":[{"key":"image","type":"file","uuid":"5d594296-0833-4208-9cfc-188d7c10e288","src":"/C:/Users/pnave/Downloads/products-2-2.png"}]},"url":"{{host}}/v1.0/devices/profile/{{uuid}}/upload","description":"<p>This API must be used to get any one device using in a particular {{uuid}} using a valid access token by passing in the request of the API.</p>\n","urlObject":{"path":["v1.0","devices","profile","{{uuid}}","upload"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"58d1520b-08a2-4744-8688-e299dca3f765"}],"id":"4b905be0-4eeb-433e-a06f-12000ed0d5e0","_postman_id":"4b905be0-4eeb-433e-a06f-12000ed0d5e0","description":""},{"name":"health","id":"0403e7e9-8174-4794-970a-092e14235e13","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"{{host}}/v1.0/health","description":"<p>This API is to check whether the server is up or not.</p>\n","urlObject":{"path":["v1.0","health"],"host":["{{host}}"],"query":[],"variable":[]}},"response":[{"id":"bb98ad24-9830-431c-9cb9-efad3ca5945c","name":"health","originalRequest":{"method":"GET","header":[],"url":"{{host}}/v1.0/health"},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"OK"}],"_postman_id":"0403e7e9-8174-4794-970a-092e14235e13"}],"event":[{"listen":"prerequest","script":{"type":"text/javascript","packages":{},"exec":[""],"id":"c2a8466e-0704-4ff3-9705-d7d4c51df824"}},{"listen":"test","script":{"type":"text/javascript","packages":{},"exec":[""],"id":"25a8f65f-b25d-44d5-9daa-ad66a5007870"}}]}