{"_id":"55674e4c77c15523002fd5bb","version":{"_id":"55674b187acd550d0075eb13","__v":1,"project":"55674b177acd550d0075eb10","createdAt":"2015-05-28T17:06:32.083Z","releaseDate":"2015-05-28T17:06:32.083Z","categories":["55674b187acd550d0075eb14"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"1.0.0","version":"1.0"},"project":"55674b177acd550d0075eb10","user":"5564f227f0f70f0d00a9ab20","__v":4,"category":{"_id":"55674b187acd550d0075eb14","pages":["55674b197acd550d0075eb16","55674c1d77c15523002fd5a3","55674c2d7acd550d0075eb1d","55674c9a77c15523002fd5a9","55674ce31c38390d006980c7","55674d1d7acd550d0075eb22","55674d7a77c15523002fd5b4","55674dac77c15523002fd5b6","55674e4c77c15523002fd5bb"],"__v":9,"project":"55674b177acd550d0075eb10","version":"55674b187acd550d0075eb13","sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-05-28T17:06:32.570Z","from_sync":false,"order":9999,"slug":"documentation","title":"Documentation"},"updates":[],"next":{"pages":[],"description":""},"createdAt":"2015-05-28T17:20:12.615Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":1,"body":"[block:callout]\n{\n  \"type\": \"danger\",\n  \"title\": \"Removed\",\n  \"body\": \"This API has been removed.\"\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"post\",\n  \"title\": \"/data/{uuid}\"\n}\n[/block]\nStores sensor data for a particular UUID. You can pass any key/value pairs. \n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"coap post -p \\\"token=123&temperature=78\\\" -H \\\"meshblu_auth_uuid={:UUID}&meshblu_auth_token={:TOKEN}\\\" coap://meshblu-coap.octoblu.com/data/0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n\n[block:callout]\n{\n  \"type\": \"info\",\n  \"title\": \"Payload: token=value&key=value (i.e. temperature=78&humity=30)\"\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\\"timestamp\\\":\\\"2014-03-23T18:57:16.093Z\\\",\\\"uuid\\\":\\\"0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc\\\",\\\"temperature\\\":\\\"78\\\",\\\"ipAddress\\\":\\\"127.0.0.1\\\",\\\"eventCode\\\":700,\\\"_id\\\":\\\"532f2e8c9c23809e93000002\\\"}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"get\",\n  \"title\": \"/data/{uuid}?token={token}\"\n}\n[/block]\nReturns last 10 data updates related to a specific device or node \nOptional query parameters include: start (time to start from), finish (time to end), limit (overrides the default 10 updates) \nYou can make this API stream sensor data by adding stream=true to the querystring. Notice the comma at the end of the response. Meshblu doesn't close the stream.\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"coap get -H \\\"meshblu_auth_uuid={:UUID}&meshblu_auth_token={:TOKEN}\\\" coap://meshblu-coap.octoblu.com/data/0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc?token=123\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"coap get -H \\\"meshblu_auth_uuid={:UUID}&meshblu_auth_token={:TOKEN}\\\" coap://coap.octoblu.com/data/0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc?token=123&stream=true  -o\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\\"data\\\":[{\\\"timestamp\\\":\\\"2014-03-23T18:57:16.093Z\\\",\\\"uuid\\\":\\\"0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc\\\",\\\"temperature\\\":\\\"78\\\",\\\"ipAddress\\\":\\\"127.0.0.1\\\",\\\"id\\\":\\\"532f2e8c9c23809e93000001\\\"}]}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]","excerpt":"","slug":"data","type":"basic","title":"Data (removed)"}
[block:callout] { "type": "danger", "title": "Removed", "body": "This API has been removed." } [/block] [block:api-header] { "type": "post", "title": "/data/{uuid}" } [/block] Stores sensor data for a particular UUID. You can pass any key/value pairs. [block:code] { "codes": [ { "code": "coap post -p \"token=123&temperature=78\" -H \"meshblu_auth_uuid={:UUID}&meshblu_auth_token={:TOKEN}\" coap://meshblu-coap.octoblu.com/data/0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc", "language": "shell" } ] } [/block] [block:callout] { "type": "info", "title": "Payload: token=value&key=value (i.e. temperature=78&humity=30)" } [/block] [block:code] { "codes": [ { "code": "{\"timestamp\":\"2014-03-23T18:57:16.093Z\",\"uuid\":\"0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc\",\"temperature\":\"78\",\"ipAddress\":\"127.0.0.1\",\"eventCode\":700,\"_id\":\"532f2e8c9c23809e93000002\"}", "language": "json" } ] } [/block] [block:api-header] { "type": "get", "title": "/data/{uuid}?token={token}" } [/block] Returns last 10 data updates related to a specific device or node Optional query parameters include: start (time to start from), finish (time to end), limit (overrides the default 10 updates) You can make this API stream sensor data by adding stream=true to the querystring. Notice the comma at the end of the response. Meshblu doesn't close the stream. [block:code] { "codes": [ { "code": "coap get -H \"meshblu_auth_uuid={:UUID}&meshblu_auth_token={:TOKEN}\" coap://meshblu-coap.octoblu.com/data/0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc?token=123", "language": "shell" } ] } [/block] [block:code] { "codes": [ { "code": "coap get -H \"meshblu_auth_uuid={:UUID}&meshblu_auth_token={:TOKEN}\" coap://coap.octoblu.com/data/0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc?token=123&stream=true -o", "language": "shell" } ] } [/block] [block:code] { "codes": [ { "code": "{\"data\":[{\"timestamp\":\"2014-03-23T18:57:16.093Z\",\"uuid\":\"0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc\",\"temperature\":\"78\",\"ipAddress\":\"127.0.0.1\",\"id\":\"532f2e8c9c23809e93000001\"}]}", "language": "json" } ] } [/block]