Devices API
Update device information
Update the name and/or metadata of a tracked device.
The Devices API is deprecated. New integrations should use the Workers API instead.
PATCH /devices/{device_id}
Patch the name and/or metadata for a tracked device. The request body must be a JSON formatted string with name and/or metadata as keys, where metadata is a valid JSON object.
Path parameters
| Name | Type | Description |
|---|---|---|
device_id | string | A string representing the ID of a tracked device, case sensitive. |
Request body
| Name | Type | Description |
|---|---|---|
name | string | The new device name. Optional. |
metadata | object | An additional JSON object. Optional. |
{
"name": "string",
"metadata": {}
}Response
Returns 200 when the device information was updated successfully.