Data (removed)

❗️

Removed

This API has been removed.

/data/{uuid}

Stores sensor data for a particular UUID. You can pass any key/value pairs.

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

📘

Payload: token=value&key=value (i.e. temperature=78&humity=30)

{"timestamp":"2014-03-23T18:57:16.093Z","uuid":"0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc","temperature":"78","ipAddress":"127.0.0.1","eventCode":700,"_id":"532f2e8c9c23809e93000002"}

/data/{uuid}?token={token}

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.

coap get -H "meshblu_auth_uuid={:UUID}&meshblu_auth_token={:TOKEN}" coap://meshblu-coap.octoblu.com/data/0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc?token=123
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
{"data":[{"timestamp":"2014-03-23T18:57:16.093Z","uuid":"0d3a53a0-2a0b-11e3-b09c-ff4de847b2cc","temperature":"78","ipAddress":"127.0.0.1","id":"532f2e8c9c23809e93000001"}]}