Get device batch

Description

Get a specified batch of devices. This list is currently not paginated and capped at 10.000 devices, meaning it is not possible to properly list batches larger than 10.000.

Request

GET /v1/n5/products/:productId/devices/batch/:batch

Response

Successful response contains the following JSON formated body:

{
   productId: string,
  deviceId: string,
  name: string|null,
  batchId: number,
  created: string,
  tags: {
    [key: string]: string
  },
  deleted: boolean
}[]

Response Status codes:

  • 200 on success

Request headers

This request must have the following headers:

  • Authorization: bearer <ApiKey>
  • X-Nabto-Organization: <organizationId>

Example

Request

curl "https://api.cloud.nabto.com/v1/n5/products/:productId/devices/batch/:batch" \
  -H "Authorization: Bearer <ApiKey>" \
  -H "X-Nabto-Organization: <OrganizationId>"

Response

{
   productId: "pr-abcdefgh",
  deviceId: "de-efghijkl",
  name: "friendly name",
  batchId: 42,
  created: "2022-10-18T10:17:24.299Z",
  tags: {
    "foo": "bar" 
  },
  deleted: true