{"info":{"_postman_id":"42e42f86-61ac-4f7c-ad9b-53002ac59c9e","name":"API Qampo","description":"<html><head></head><body><p>Api Qampo</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"4336969","collectionId":"42e42f86-61ac-4f7c-ad9b-53002ac59c9e","publishedId":"SzYdUcMn","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2022-11-02T11:43:29.000Z"},"item":[{"name":"Authentication","id":"7c87f8cd-c52c-4f17-ad18-20f97505d775","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{ \"username\": \"USUARIO\", \"password\": \"PASSWORD\"}"},"url":"https://api.qampo.es/qampov2/rest/login/auth","description":"<p>Summary:</p>\n<ul>\n<li>Request to obtain the token of a specific user account.</li>\n</ul>\n<p>Request type:</p>\n<ul>\n<li>POST</li>\n</ul>\n<p>URL:</p>\n<ul>\n<li><a href=\"https://api.qampo.es/qampov2/rest/login/auth\">https://api.qampo.es/qampov2/rest/login/auth</a></li>\n</ul>\n<p>Parameters to take into consideration:</p>\n<ul>\n<li>Header Content-Type application/json</li>\n<li>Body type JSON with the following structure -&gt;\n{ \n  \"username\": \"xxxxx\", \n  \"password\": \"xxxxx\"\n}</li>\n</ul>\n","urlObject":{"protocol":"https","path":["qampov2","rest","login","auth"],"host":["api","qampo","es"],"query":[],"variable":[]}},"response":[],"_postman_id":"7c87f8cd-c52c-4f17-ad18-20f97505d775"},{"name":"Devices assigned","id":"a31573c9-0833-4806-bdca-8d472f1a9c49","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"method":"GET","header":[],"url":"https://api.qampo.es/qampov2/rest/api/nodes","description":"<p>Summary:</p>\n<ul>\n<li>Request to obtain all devices assigned to the account selected.</li>\n</ul>\n<p>Request type:</p>\n<ul>\n<li>GET</li>\n</ul>\n<p>URL:</p>\n<ul>\n<li><a href=\"https://api.qampo.es/qampov2/rest/api/nodes\">https://api.qampo.es/qampov2/rest/api/nodes</a></li>\n</ul>\n<p>Parameters to take into consideration:</p>\n<ul>\n<li>The token obtained in the \"Authentication\" request.</li>\n</ul>\n","urlObject":{"protocol":"https","path":["qampov2","rest","api","nodes"],"host":["api","qampo","es"],"query":[],"variable":[]}},"response":[],"_postman_id":"a31573c9-0833-4806-bdca-8d472f1a9c49"},{"name":"Variables of a device","id":"76599881-6329-475d-890c-d4c7d75273a2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"method":"GET","header":[],"url":"https://api.qampo.es/qampov2/rest/api/:node_id/variables","description":"<p>Summary:</p>\n<ul>\n<li>Request to obtain all variables of a specific device.</li>\n</ul>\n<p>Request type:</p>\n<ul>\n<li>GET</li>\n</ul>\n<p>URL:</p>\n<ul>\n<li><a href=\"https://api.qampo.es/qampov2/rest/api/%7Bnode_id%7D/variables\">https://api.qampo.es/qampov2/rest/api/{node_id}/variables</a></li>\n</ul>\n<p>Parameters to take into consideration:</p>\n<ul>\n<li>The token obtained in the \"Authentication\" request.</li>\n<li>A device ID from the list obtained in the \"Devices assigned\" request.</li>\n</ul>\n","urlObject":{"protocol":"https","path":["qampov2","rest","api",":node_id","variables"],"host":["api","qampo","es"],"query":[],"variable":[{"type":"any","value":"node id","key":"node_id"}]}},"response":[],"_postman_id":"76599881-6329-475d-890c-d4c7d75273a2"},{"name":"Variable + UTS -> Using labels","id":"a35addc3-edd4-4201-8741-a2d1277d2a34","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"method":"GET","header":[],"url":"https://api.qampo.es/qampov2/rest/api/:node_label/:var_label/values?start=1625391417000&end=1625485025000","description":"<p>Summary:</p>\n<ul>\n<li>Request to obtain all values of a sensor, where both device label and variable label are necessary. It also must be indicated the start and the end of a date.</li>\n</ul>\n<p>Request type:</p>\n<ul>\n<li>GET</li>\n</ul>\n<p>URL:</p>\n<ul>\n<li><a href=\"https://api.qampo.es/qampov2/rest/api/%7Bnode_label%7D/%7Bvariable_label%7D/values?start=%7BUTS_init%7D&amp;end=%7BUTS_end%7D\">https://api.qampo.es/qampov2/rest/api/{node_label}/{variable_label}/values?start={UTS_init}&amp;end={UTS_end}</a></li>\n</ul>\n<p>Parameters to take into consideration:</p>\n<ul>\n<li>The token obtained in the \"Authentication\" request.</li>\n<li>A device label from the list obtained in the \"Devices assigned\" request.</li>\n<li>A variable label from the list obtained in the \"Variables of a device\" request.</li>\n</ul>\n","urlObject":{"protocol":"https","path":["qampov2","rest","api",":node_label",":var_label","values"],"host":["api","qampo","es"],"query":[{"key":"start","value":"1625391417000"},{"key":"end","value":"1625485025000"}],"variable":[{"type":"any","value":"","key":"node_label"},{"type":"any","value":"","key":"var_label"}]}},"response":[],"_postman_id":"a35addc3-edd4-4201-8741-a2d1277d2a34"},{"name":"Variable + UTS -> ID variable","id":"9b792ba3-317b-473a-844e-5e6d533baa97","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"method":"GET","header":[],"url":"https://api.qampo.es/qampov2/rest/api/:var_id/values?start=1625391417000&end=1625485025000","description":"<p>Summary:</p>\n<ul>\n<li>Request to obtain all sensor values from the unique id of the variable. It also must be indicated the start and the end of a date.</li>\n</ul>\n<p>Request type:</p>\n<ul>\n<li>GET</li>\n</ul>\n<p>URL:</p>\n<ul>\n<li><a href=\"https://api.qampo.es/qampov2/rest/api/%7Bvariable_id%7D/values?start=%7BUTS_init%7D&amp;end=%7BUTS_end%7D\">https://api.qampo.es/qampov2/rest/api/{variable_id}/values?start={UTS_init}&amp;end={UTS_end}</a></li>\n</ul>\n<p>Parameters to take into consideration:</p>\n<ul>\n<li>The token obtained in the \"Authentication\" request.</li>\n<li>A variable label from the list obtained in the \"Variables of a device\" request.</li>\n</ul>\n","urlObject":{"protocol":"https","path":["qampov2","rest","api",":var_id","values"],"host":["api","qampo","es"],"query":[{"key":"start","value":"1625391417000"},{"key":"end","value":"1625485025000"}],"variable":[{"type":"any","value":"","key":"var_id"}]}},"response":[],"_postman_id":"9b792ba3-317b-473a-844e-5e6d533baa97"},{"name":"Variable data by period and filter","id":"37501b4e-9ff8-441d-9973-a7161e6d6d30","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"method":"GET","header":[{"key":"Content-Type","value":"application/json","type":"text"}],"url":"https://api.qampo.es/qampov2/rest/api/:node_id/data?start=1625391417000&end=1625485025000&filter=weather","description":"<p>Summary:</p>\n<ul>\n<li>Request to obtain all values of a device from its unique ID. It also must be indicated the start and the end of a date.</li>\n</ul>\n<p>Request tyoe:</p>\n<ul>\n<li>GET</li>\n</ul>\n<p>URL:</p>\n<ul>\n<li><a href=\"https://api.qampo.es/qampov2/rest/api/%7Bnode_id%7D/data?start=%7BUTS_init%7D&amp;end=%7BUTS_end%7D&amp;filter=%7Bfilters%7D\">https://api.qampo.es/qampov2/rest/api/{node_id}/data?start={UTS_init}&amp;end={UTS_end}&amp;filter={filters}</a></li>\n</ul>\n<p>*Filters:\nall\nsoil\nirrigation\nenvironmental</p>\n<p>Parameters to take into consideration:</p>\n<ul>\n<li>The token obtained in the \"Authentication\" request.</li>\n<li>A variable label from the list obtained in the \"Variables of a device\" request.</li>\n</ul>\n","urlObject":{"protocol":"https","path":["qampov2","rest","api",":node_id","data"],"host":["api","qampo","es"],"query":[{"key":"start","value":"1625391417000"},{"key":"end","value":"1625485025000"},{"key":"filter","value":"weather"}],"variable":[{"type":"any","value":"","key":"node_id"}]}},"response":[],"_postman_id":"37501b4e-9ff8-441d-9973-a7161e6d6d30"}],"event":[{"listen":"prerequest","script":{"id":"8c152ec4-eea0-4a1c-8c2e-923218600f6d","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"41f0d283-d955-4f95-8822-e99156fbd007","type":"text/javascript","exec":[""]}}]}