Update Multiple Datastreams Values

Update Multiple Datastreams Values

POST https://{server_address}/api/v1/organization/device/datastreams

Headers

NameTypeDescription

Authorization*

Bearer {access_token}

Content-Type*

application/json

Request Body

NameTypeDescription

deviceId*

1

Device identifier.

values*

{"1":5}

Map with datastream identifier as a key and datastream value as a value.

{
    "error": {
        "message": "Device with identifier 1 is not found or belong to another organization."
    }
}

Request examples:

# curl command example:
$ curl -X POST -H "Content-Type: application/json" \
      -H "Authorization: Bearer {accessToken}" \
      -d '{"deviceId":1,"values":{"1":5,"2":"new value"}}' \
      https://fra1.blynk.cloud/api/v1/organization/device/datastreams

$ curl -X POST -H "Content-Type: application/json" \
      -H "Authorization: Bearer eIdWHQqRfFmvP5LDDh-IGxPUzi7I27HthzCPAVmS" \
      -d '{"deviceId":1,"values":{"1":5,"2":"new value"}}' \
      https://fra1.blynk.cloud/api/v1/organization/device/datastreams

Last updated