Update an existing monitors relation. To execute this query, the user must be a member of an authorizing role which satisfies both of the following conditions: One of the following role-related conditions is true: The authorizing role has direct or indirect deviceManagement rights for the role from which the monitors relation is updated The authorizing role has indirect roleManagement rights for the role from which the monitors relation is updated The authorizing role has monitorManagement rights for the device to which the monitors relation is updated
accessBearerAuth In the value field below, fill in the access token. It has a 10 minutes validity period. A valid token can be obtained via the /accesstoken endpoint (call), AFTER authorization with refreshBearerAuth and the refresh token.
In: header
Id of the role of the updated monitors relation
0 <= valueId of the updated monitors relation
application/json
TypeScript Definitions
Use the request body type in TypeScript.
application/json
application/json
application/json
application/json
application/json
curl -X PUT "https://example.com/v1/role/0/monitors/0" \ -H "Content-Type: application/json" \ -d '{ "monitorManagement": true, "reads": [ "string" ], "edits": [ "string" ] }'{ "monitors": { "id": 0, "roleId": 0, "deviceId": 0, "monitorManagement": true, "reads": [ "string" ], "edits": [ "string" ] }}Create or update a monitors relation PUT
Create a monitors relation (or update the existing one) between a role and a device.<br><br> To execute this query, the user must be a member of an authorizing role which satisfies both of the following conditions: <ol> <li> One of the following role-related conditions is true: <ul> <li> The authorizing role has *direct or indirect* deviceManagement rights for the role from which the monitors relation is created (or updated) </li> <li> The authorizing role has *indirect* roleManagement rights for the role from which the monitors relation is created (or updated) </li> </ul> </li> <li> The authorizing role has monitorManagement rights for the device to which the monitors relation is created </li> </ol>
Collect telemetry data POST
Execute up to 1000 telemetry queries. A leaky bucket rate limiting mechanism is applied based on the calculated cost of each request. The cost is a linear combination of the number of requests, the number of queries per request, the estimated number of returned datapoints and the number of scanned shards. To minimize cost: - **Requests**: Send multiple queries in a single request (up to 1000). Make sure the total cost does not exceed your tier's bucket capacity. - **Queries per request**: Use a single query to select multiple fields instead of one query per field. - **Returned datapoints**: The estimate is based on the selected time range, the expected datapoint frequency and the provided `limit`. When no range is provided, a worst-case range is assumed. Always specify a time range and set `limit` as low as possible. - **Scanned shards**: Depends on the time range and expected datapoint frequency, but is unaffected by `limit`. A tight time range minimizes this component as well. If a request's cost would overflow the bucket, a `429` response is returned with a `Retry-After` header indicating how long to wait. If the cost exceeds the bucket's total capacity entirely, a `422` is returned. Ignoring `Retry-After` headers will result in a temporary 5-minute IP ban. Helper scripts for estimating request cost are available at [/assets/estimateCost.ts](/assets/estimateCost.ts) (TypeScript) and [/assets/estimateCost.py](/assets/estimateCost.py) (Python).
Indicates whether the role has the right to create new monitors relations to the monitored device. If true, the role may read and edit any device property.
A list of device properties which may be read by the role monitoring the device
A list of device properties which may be both read and edited by the role monitoring the device