GET
/
devices
curl --request GET \
  --url https://api.flatpeak.com/devices \
  --header 'Authorization: Bearer <token>'
{
  "object": "list",
  "url": "/devices",
  "has_more": true,
  "data": [
    {
      "id": "dev_63a6087272941ef077a8fd3e",
      "object": "device",
      "live_mode": true,
      "reference_id": "DEV1234567890",
      "last_seen": "2022-03-22T11:12:21Z",
      "time_created": "2022-01-24T14:15:22Z",
      "account_id": "acc_661677911f2197045e6cf1b1"
    }
  ]
}

Authorizations

Authorization
string
header
required

Authenticate with bearer_token you obtained from /login endpoint.

Query Parameters

reference_id
string

A reference that is meaningful to you, for example, an ID from your system.

ending_before
string

Specifies a cursor for pagination use; provider_id defines the place in the list. To retrieve the previous page in the list include ending_before where is the first ID in the currently retrieved list.

limit
integer

A limit on the number of objects to be returned. Can range between 1 and 100, and the default is 30.

starting_after
string

Specifies a cursor for pagination use; provider_id defines the place in the list. To retrieve the next page in the list include starting_after where ID is the last ID in the currently retrieved list.

Response

200
application/json
object
string

Represents the object’s type. i.e. list.

Example:

"list"

url
string

Represents url slug for the object.

Example:

"/devices"

has_more
boolean

Is set to true if more objects are available.

data
object[]

This object represents a device or another asset of a compatible type.