< Fleets latest API Documentation Submit API issue

Fleets API (1.0.0)

Download OpenAPI specification:

Fleets IoT Device Management Platform — API for device registry, shadow, query, and job/command dispatch.

Commands

List command executions

Returns paginated real-time command execution history.

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

thingId
string

Filter by target thing ID

status
string

Filter by command execution status

action
string

Filter by command action

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Send a command

Sends a real-time command via EMQX API publish.

Provide exactly one of thingId or targets (mutually exclusive). Response body is always BatchCommandResponse: {commands: [{thingName, executionId, status, error?}], totalTargets, succeeded, failed}.

  • thingId: single-target; commands has one entry, totalTargets is 1.
  • targets: batch (thingNames / thingGroupNames / savedQueryIds); one entry per matched device. Batch partial failures return HTTP 200 with per-device commands[].status=FAILED and error set.
Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
action
required
string

Command action

object

Command parameters

object (JobTargets)

Batch targets: thingNames, thingGroupNames, savedQueryIds

thingId
string

Target thing ID (mutually exclusive with targets)

ttl
integer <int64>

Command TTL in seconds

Responses

Request samples

Content type
application/json
{
  • "action": "string",
  • "params": {
    },
  • "targets": {
    },
  • "thingId": "string",
  • "ttl": 0
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/BatchCommandResponse.json",
  • "commands": [
    ],
  • "failed": 0,
  • "succeeded": 0,
  • "totalTargets": 0
}

Get command execution status

Returns the status and result of a previously sent command.

Authorizations:
basicAuthbearerAuth
path Parameters
executionId
required
string

Command execution ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJobExecution.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "errorMessage": "string",
  • "executionId": "string",
  • "executionNumber": 0,
  • "id": "string",
  • "inProgressTimeoutAt": "2019-08-24T14:15:22Z",
  • "job": {
    },
  • "jobId": "string",
  • "publicJobId": "string",
  • "queuedAt": "2019-08-24T14:15:22Z",
  • "shadowVersion": 0,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "stepTimeoutAt": "2019-08-24T14:15:22Z",
  • "terminalAt": "2019-08-24T14:15:22Z",
  • "thing": {
    },
  • "thingId": "string",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "versionNumber": 0
}

Device Query

System

Health check with per-service status and endpoint info

Returns the health status of the Fleets backend including instance ID and detailed connectivity status, endpoint URLs, and error details for EMQX, PostgreSQL, and EMQX Tables (TSDB).

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/HealthBody.json",
  • "emqx": {
    },
  • "instanceId": "string",
  • "postgresql": {
    },
  • "status": "ok",
  • "tables": {
    }
}

Jobs

List all job executions

Lists job executions across jobs and things.

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

status
string

Filter by execution status

jobId
string

Filter by public job ID

thingName
string

Filter by thing name

Responses

Response samples

Content type
application/json
[
  • {
    }
]

List thing job executions

Lists job executions for a thing.

Authorizations:
basicAuthbearerAuth
path Parameters
thingName
required
string

Thing name

query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

status
string

Filter by execution status

jobId
string

Filter by public job ID

Responses

Response samples

Content type
application/json
[
  • {
    }
]

List jobs

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

status
string

Filter by job status

jobType
string

Filter by job type

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create a job

Creates a job and materializes per-thing executions for the Jobs protocol.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
object
description
string

Job description

required
object

Job document

jobId
string

Public Job ID

jobType
string
Enum: "SNAPSHOT" "CONTINUOUS"

Job type

name
string

Job name

object
object
object
object
required
object (JobTargets)

Job targets by thingNames or thingGroupNames

object

Responses

Request samples

Content type
application/json
{
  • "abortConfig": {
    },
  • "description": "string",
  • "document": {
    },
  • "jobId": "string",
  • "jobType": "SNAPSHOT",
  • "name": "string",
  • "retryConfig": {
    },
  • "rolloutConfig": {
    },
  • "schedulingConfig": {
    },
  • "tags": {
    },
  • "targets": {
    },
  • "timeoutConfig": {
    }
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJob.json",
  • "abortConfig": null,
  • "completedAt": "2019-08-24T14:15:22Z",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "deletedAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "document": null,
  • "documentSource": "string",
  • "errorMessage": "string",
  • "executions": [
    ],
  • "id": "string",
  • "jobId": "string",
  • "jobProcessDetails": {
    },
  • "jobType": "string",
  • "kind": "string",
  • "name": "string",
  • "retryConfig": null,
  • "rolloutConfig": null,
  • "scheduledAt": "2019-08-24T14:15:22Z",
  • "schedulingConfig": null,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "tags": null,
  • "targetSnapshot": null,
  • "targetsJson": null,
  • "timeoutConfig": null,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Delete a job

Soft-deletes terminal jobs or marks active jobs for deletion when force=true.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

query Parameters
force
boolean
Default: false

Force deleting active jobs

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJob.json",
  • "abortConfig": null,
  • "completedAt": "2019-08-24T14:15:22Z",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "deletedAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "document": null,
  • "documentSource": "string",
  • "errorMessage": "string",
  • "executions": [
    ],
  • "id": "string",
  • "jobId": "string",
  • "jobProcessDetails": {
    },
  • "jobType": "string",
  • "kind": "string",
  • "name": "string",
  • "retryConfig": null,
  • "rolloutConfig": null,
  • "scheduledAt": "2019-08-24T14:15:22Z",
  • "schedulingConfig": null,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "tags": null,
  • "targetSnapshot": null,
  • "targetsJson": null,
  • "timeoutConfig": null,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Get a job

Returns job details including per-thing execution status.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJob.json",
  • "abortConfig": null,
  • "completedAt": "2019-08-24T14:15:22Z",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "deletedAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "document": null,
  • "documentSource": "string",
  • "errorMessage": "string",
  • "executions": [
    ],
  • "id": "string",
  • "jobId": "string",
  • "jobProcessDetails": {
    },
  • "jobType": "string",
  • "kind": "string",
  • "name": "string",
  • "retryConfig": null,
  • "rolloutConfig": null,
  • "scheduledAt": "2019-08-24T14:15:22Z",
  • "schedulingConfig": null,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "tags": null,
  • "targetSnapshot": null,
  • "targetsJson": null,
  • "timeoutConfig": null,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Update a job

Updates mutable job metadata and configuration.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

Request Body schema: application/json
required
object
description
string or null
object
object
object
object

Responses

Request samples

Content type
application/json
{
  • "abortConfig": {
    },
  • "description": "string",
  • "retryConfig": {
    },
  • "rolloutConfig": {
    },
  • "schedulingConfig": {
    },
  • "timeoutConfig": {
    }
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJob.json",
  • "abortConfig": null,
  • "completedAt": "2019-08-24T14:15:22Z",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "deletedAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "document": null,
  • "documentSource": "string",
  • "errorMessage": "string",
  • "executions": [
    ],
  • "id": "string",
  • "jobId": "string",
  • "jobProcessDetails": {
    },
  • "jobType": "string",
  • "kind": "string",
  • "name": "string",
  • "retryConfig": null,
  • "rolloutConfig": null,
  • "scheduledAt": "2019-08-24T14:15:22Z",
  • "schedulingConfig": null,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "tags": null,
  • "targetSnapshot": null,
  • "targetsJson": null,
  • "timeoutConfig": null,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Cancel a job

Cancels scheduled and queued executions, or in-progress executions when force=true.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

Request Body schema: application/json
required
comment
string
force
boolean
reasonCode
string

Responses

Request samples

Content type
application/json
{
  • "comment": "string",
  • "force": true,
  • "reasonCode": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJob.json",
  • "abortConfig": null,
  • "completedAt": "2019-08-24T14:15:22Z",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "deletedAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "document": null,
  • "documentSource": "string",
  • "errorMessage": "string",
  • "executions": [
    ],
  • "id": "string",
  • "jobId": "string",
  • "jobProcessDetails": {
    },
  • "jobType": "string",
  • "kind": "string",
  • "name": "string",
  • "retryConfig": null,
  • "rolloutConfig": null,
  • "scheduledAt": "2019-08-24T14:15:22Z",
  • "schedulingConfig": null,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "tags": null,
  • "targetSnapshot": null,
  • "targetsJson": null,
  • "timeoutConfig": null,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Get a job document

Returns the immutable job document.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

Responses

Response samples

Content type
application/json
{
  • "property1": null,
  • "property2": null
}

List job executions

Lists per-thing executions for a job.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

status
string

Filter by execution status

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Get job execution

Gets one thing execution for a job.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

thingName
required
string

Thing name

query Parameters
executionNumber
integer <int64>
Default: 1

Execution attempt number

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJobExecution.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "errorMessage": "string",
  • "executionId": "string",
  • "executionNumber": 0,
  • "id": "string",
  • "inProgressTimeoutAt": "2019-08-24T14:15:22Z",
  • "job": {
    },
  • "jobId": "string",
  • "publicJobId": "string",
  • "queuedAt": "2019-08-24T14:15:22Z",
  • "shadowVersion": 0,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "stepTimeoutAt": "2019-08-24T14:15:22Z",
  • "terminalAt": "2019-08-24T14:15:22Z",
  • "thing": {
    },
  • "thingId": "string",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "versionNumber": 0
}

Cancel job execution

Cancels one execution.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

thingName
required
string

Thing name

Request Body schema: application/json
required
executionNumber
integer <int64>
expectedVersion
integer <int64>
force
boolean
object

Responses

Request samples

Content type
application/json
{
  • "executionNumber": 0,
  • "expectedVersion": 0,
  • "force": true,
  • "statusDetails": {
    }
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJobExecution.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "errorMessage": "string",
  • "executionId": "string",
  • "executionNumber": 0,
  • "id": "string",
  • "inProgressTimeoutAt": "2019-08-24T14:15:22Z",
  • "job": {
    },
  • "jobId": "string",
  • "publicJobId": "string",
  • "queuedAt": "2019-08-24T14:15:22Z",
  • "shadowVersion": 0,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "stepTimeoutAt": "2019-08-24T14:15:22Z",
  • "terminalAt": "2019-08-24T14:15:22Z",
  • "thing": {
    },
  • "thingId": "string",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "versionNumber": 0
}

Delete job execution

Marks one execution as removed.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

thingName
required
string

Thing name

executionNumber
required
integer <int64>

Execution attempt number

query Parameters
force
boolean
Default: false

Force removing active executions

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingJobExecution.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "errorMessage": "string",
  • "executionId": "string",
  • "executionNumber": 0,
  • "id": "string",
  • "inProgressTimeoutAt": "2019-08-24T14:15:22Z",
  • "job": {
    },
  • "jobId": "string",
  • "publicJobId": "string",
  • "queuedAt": "2019-08-24T14:15:22Z",
  • "shadowVersion": 0,
  • "startedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "statusDetails": null,
  • "stepTimeoutAt": "2019-08-24T14:15:22Z",
  • "terminalAt": "2019-08-24T14:15:22Z",
  • "thing": {
    },
  • "thingId": "string",
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "versionNumber": 0
}

Overview

Get fleets overview

Authorizations:
basicAuthbearerAuth

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/Overview.json",
  • "thingCount": 0,
  • "thingOfflineCount": 0,
  • "thingOnlineCount": 0,
  • "thingTypeCount": 0
}

Saved Queries

List saved device queries

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create a saved device query

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
description
string or null

Query description

name
required
string

Query name

object (SavedQueryConfig)

Structured filter config

queryText
required
string

DSL query text

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string",
  • "queryConfig": {
    },
  • "queryText": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/SavedDeviceQuery.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "queryConfig": {
    },
  • "queryText": "string",
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Delete a saved device query

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Saved query ID

Responses

Response samples

Content type
application/problem+json
{}

Get a saved device query

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Saved query ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/SavedDeviceQuery.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "queryConfig": {
    },
  • "queryText": "string",
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Update a saved device query

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Saved query ID

Request Body schema: application/json
required
description
string or null

Query description

name
string or null

Query name

object (SavedQueryConfig)

Structured filter config

queryText
string or null

DSL query text

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string",
  • "queryConfig": {
    },
  • "queryText": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/SavedDeviceQuery.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "queryConfig": {
    },
  • "queryText": "string",
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Tags

List tags

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create a tag

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
description
string

Tag description

name
required
string

Tag name

type
required
integer or null <int32> >= 0

Tag type: 0=thing, 1=thingType (default 0)

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string",
  • "type": 0
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/Tag.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": 0,
  • "name": "string",
  • "type": 0,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Batch create tags

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
required
Array of objects or null (TagEntry) non-empty

List of tags to create

Responses

Request samples

Content type
application/json
{
  • "tags": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CreateTagsBatchOutputBody.json",
  • "errors": [
    ],
  • "tags": [
    ]
}

Get a tag by ID

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Tag ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/Tag.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": 0,
  • "name": "string",
  • "type": 0,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Get a tag by name

Authorizations:
basicAuthbearerAuth
path Parameters
name
required
string

Tag name

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/Tag.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": 0,
  • "name": "string",
  • "type": 0,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Delete a tag

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Tag ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Update a tag

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Tag ID

Request Body schema: application/json
required
description
string

Tag description

name
required
string or null

Tag name

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/Tag.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": 0,
  • "name": "string",
  • "type": 0,
  • "updatedAt": "2019-08-24T14:15:22Z"
}

ThingDatas

Device reports command execution result

Writes command execution response to PostgreSQL.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
executionId
required
string
object
status
required
string
thingName
required
string
timestamp
integer <int64>

Responses

Request samples

Content type
application/json
{
  • "executionId": "string",
  • "result": {
    },
  • "status": "string",
  • "thingName": "string",
  • "timestamp": 0
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CommandResponseOutputBody.json",
  • "executionId": "string",
  • "status": "string",
  • "updatedAt": 0
}

Device reports event

Writes event data to GreptimeDB.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
appId
string
object
eventType
required
string
severity
string
thingName
required
string
timestamp
required
integer <int64>

Responses

Request samples

Content type
application/json
{
  • "appId": "string",
  • "data": {
    },
  • "eventType": "string",
  • "severity": "string",
  • "thingName": "string",
  • "timestamp": 0
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/EventOutputBody.json",
  • "inserted": true
}

Device requests pending jobs

Returns the list of pending and in-progress job executions for a thing.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
clientToken
string
thingName
required
string

Responses

Request samples

Content type
application/json
{
  • "clientToken": "string",
  • "thingName": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/JobsGetOutput.json",
  • "clientToken": "string",
  • "inProgressJobs": [
    ],
  • "queuedJobs": [
    ],
  • "timestamp": 0
}

Device requests next pending job

Returns the next QUEUED job execution and transitions it to IN_PROGRESS.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
clientToken
string
object
stepTimeoutInMinutes
integer <int64>
thingName
required
string

Responses

Request samples

Content type
application/json
{
  • "clientToken": "string",
  • "statusDetails": {
    },
  • "stepTimeoutInMinutes": 0,
  • "thingName": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/JobsStartNextOutput.json",
  • "clientToken": "string",
  • "execution": {
    },
  • "timestamp": 0
}

Device describes one job execution

Returns the current execution state and job document for one job.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

Request Body schema: application/json
required
clientToken
string
executionNumber
integer <int64>
thingName
required
string

Responses

Request samples

Content type
application/json
{
  • "clientToken": "string",
  • "executionNumber": 0,
  • "thingName": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/JobsExecutionGetOutput.json",
  • "clientToken": "string",
  • "execution": {
    },
  • "timestamp": 0
}

Device reports job execution status

Updates the execution status for a job.

Authorizations:
basicAuthbearerAuth
path Parameters
jobId
required
string

Job ID

Request Body schema: application/json
required
clientToken
string
executionNumber
integer <int64>
expectedVersion
integer <int64>
status
required
string
object
stepTimeoutInMinutes
integer <int64>
thingName
required
string

Responses

Request samples

Content type
application/json
{
  • "clientToken": "string",
  • "executionNumber": 0,
  • "expectedVersion": 0,
  • "status": "string",
  • "statusDetails": {
    },
  • "stepTimeoutInMinutes": 0,
  • "thingName": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/JobUpdateOutput.json",
  • "clientToken": "string",
  • "execution": {
    },
  • "timestamp": 0
}

Device lifecycle events

Updates thing connectivity status from EMQX lifecycle events.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
clientId
required
string
disconnectReason
string
eventType
required
string
thingName
string
timestamp
required
integer <int64>

Responses

Request samples

Content type
application/json
{
  • "clientId": "string",
  • "disconnectReason": "string",
  • "eventType": "string",
  • "thingName": "string",
  • "timestamp": 0
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/LifecycleOutputBody.json",
  • "updated": true
}

Device reports shadow state (HTTPS uplink)

Writes reported shadow history to EMQX Tables and latest state to PostgreSQL.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
clientToken
string
required
object (ShadowReportedState)
thingName
required
string
version
integer <int64>

Responses

Request samples

Content type
application/json
{
  • "clientToken": "string",
  • "state": {
    },
  • "thingName": "string",
  • "version": 0
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ShadowReportedOutputBody.json",
  • "thingName": "string",
  • "timestamp": 0,
  • "version": 0
}

EMQX rule callback (POST): update shadow reported in PostgreSQL only

Updates PostgreSQL shadow reported state only; used by EMQX HTTP bridge actions (POST-only).

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
clientToken
string
required
object (ShadowReportedState)
thingName
required
string
version
integer <int64>

Responses

Request samples

Content type
application/json
{
  • "clientToken": "string",
  • "state": {
    },
  • "thingName": "string",
  • "version": 0
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ShadowReportedOutputBody.json",
  • "thingName": "string",
  • "timestamp": 0,
  • "version": 0
}

Device retrieves shadow

Returns the current shadow document for a thing by name.

Authorizations:
basicAuthbearerAuth
path Parameters
thingName
required
string

Thing name

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingShadowBody.json",
  • "delta": {
    },
  • "desired": {
    },
  • "id": "string",
  • "reported": {
    },
  • "thingId": "string",
  • "updatedAt": "string",
  • "version": 0
}

Thing Groups

List thing groups

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

tagId
integer <int64> >= 0

When set, list groups whose tag_ids contains this tag ID

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create a thing group

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
description
string or null

Group description

name
required
string

Group name

tagFilter
required
Array of strings or null

Tag names for dynamic membership (at least one)

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string",
  • "tagFilter": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingGroup.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "tagIds": [
    ],
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Delete a thing group

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Group ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Get a thing group

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Group ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingGroup.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "tagIds": [
    ],
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Update a thing group

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Group ID

Request Body schema: application/json
required
description
string or null

Group description

name
string or null

Group name

tagFilter
Array of strings or null

Tag names for dynamic membership

Responses

Request samples

Content type
application/json
{
  • "description": "string",
  • "name": "string",
  • "tagFilter": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingGroup.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "tagIds": [
    ],
  • "updatedAt": "2019-08-24T14:15:22Z"
}

List group members

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Group ID

query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Thing Types

List thing types

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create a thing type

Creates a thing type with a full JSON schema. Required field: name (globally unique). Device grouping is tag-driven via Thing Groups (see thing-model.md). For the shape and semantics of the schema JSON blob, see https://github.com/emqx/fleets/blob/main/docs/thing-model.md#thingtype-schema

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
category
string

Category (e.g. HVAC, Sensor)

description
string or null

Description

name
required
string

Globally unique thing type name (e.g. com.example.hvac.air-conditioner)

parentTypeId
string or null

Parent thing type ID for inheritance

schema
any

JSON object persisted as thing_types.schema (JSONB). Optional sections include metadata, connectivity, properties (with optional writable flag), events, commands, security, lifecycle, edge, and relations as defined in the ThingType Schema spec. A top-level "telemetry" key is rejected (model properties under properties; use custom MQTT + rules for high-rate time series). OpenAPI lists this as an untyped object only; see https://github.com/emqx/fleets/blob/main/docs/thing-model.md#thingtype-schema

tags
Array of strings or null

Tag names to attach

version
string
Default: "1.0.0"

Semantic version

Responses

Request samples

Content type
application/json
{
  • "category": "string",
  • "description": "string",
  • "name": "string",
  • "parentTypeId": "string",
  • "schema": null,
  • "tags": [
    ],
  • "version": "1.0.0"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingType.json",
  • "category": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "parentTypeId": "string",
  • "schema": null,
  • "status": "string",
  • "tags": [
    ],
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "version": "string"
}

Import a thing type from a JSON file

Upload a JSON file (form field 'file') containing a thing type definition. Rejects if name already exists. Schema validation applies (no top-level telemetry). The file format is the same as the export format.

Authorizations:
basicAuthbearerAuth
Request Body schema: multipart/form-data
file
required
string <binary> <binary> <application/octet-stream>

ThingType JSON file

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ImportThingTypeOutputBody.json",
  • "name": "string",
  • "success": true,
  • "thingType": {
    }
}

Replace tags on thing types

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
tags
required
Array of strings or null

Full tag name list

thingTypeIds
required
Array of strings or null

Thing type UUIDs

Responses

Request samples

Content type
application/json
{
  • "tags": [
    ],
  • "thingTypeIds": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Add tags to thing types

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
tags
required
Array of strings or null

Tag names to add

thingTypeIds
required
Array of strings or null

Thing type UUIDs

Responses

Request samples

Content type
application/json
{
  • "tags": [
    ],
  • "thingTypeIds": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Remove tags from thing types

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
tags
required
Array of strings or null

Tag names to remove

thingTypeIds
required
Array of strings or null

Thing type UUIDs

Responses

Request samples

Content type
application/json
{
  • "tags": [
    ],
  • "thingTypeIds": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Delete a thing type

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing type ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Get a thing type

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing type ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingType.json",
  • "category": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "parentTypeId": "string",
  • "schema": null,
  • "status": "string",
  • "tags": [
    ],
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "version": "string"
}

Update a thing type

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing type ID

Request Body schema: application/json
required
category
string or null

Category

description
string or null

Description

name
string or null

Globally unique thing type name

parentTypeId
string or null

Parent thing type ID

schema
any

JSON object for thing_types.schema (JSONB); same semantics as on create. Properties use flat structure with optional writable flag. Top-level "telemetry" is rejected. OpenAPI shows an untyped object only; see https://github.com/emqx/fleets/blob/main/docs/thing-model.md#thingtype-schema

status
string or null

Status (active, inactive, deprecated)

tags
Array of strings or null

Tag names

version
string or null

Version

Responses

Request samples

Content type
application/json
{
  • "category": "string",
  • "description": "string",
  • "name": "string",
  • "parentTypeId": "string",
  • "schema": null,
  • "status": "string",
  • "tags": [
    ],
  • "version": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingType.json",
  • "category": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "id": "string",
  • "name": "string",
  • "parentTypeId": "string",
  • "schema": null,
  • "status": "string",
  • "tags": [
    ],
  • "updatedAt": "2019-08-24T14:15:22Z",
  • "version": "string"
}

Export a thing type as a downloadable JSON file

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing type ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ThingTypeExport.json",
  • "category": "string",
  • "description": "string",
  • "name": "string",
  • "parentTypeId": "string",
  • "schema": null,
  • "status": "string",
  • "tags": [
    ],
  • "version": "string"
}

Get thing type tags

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing type ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/GetThingTypeTagsOutputBody.json",
  • "tags": [
    ]
}

Things

List things

Authorizations:
basicAuthbearerAuth
query Parameters
page
integer <int64> >= 1
Default: 1

Page number

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

thingTypeId
string

Filter by thing type: UUID (thing_types.id) or globally unique thing type name

tagId
Array of integers or null <int64> [ items <int64 > >= 0 ]

Repeat for AND: thing must have every listed tag (by tag ID)

tagName
Array of strings or null

Repeat for AND: thing must have every listed tag (by tag name)

status
string
Enum: "online" "offline"

Filter by connectivity status: online or offline

search
string

Case-insensitive substring match on thing name or MQTT client ID

thingGroupId
string

Filter by thing group UUID (members of thing_group_members)

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Create a thing

Creates a thing. If thingTypeId is omitted, null, or empty, the system auto-binds reserved unassigned-device-type. When bound to a ThingType, the thing inherits schema sections: properties, events, commands, and connectivity.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
metadata
any

Metadata (JSON object)

mqttClientId
required
string

MQTT client ID

name
required
string

Thing name

tags
Array of strings or null

Tag names to attach

thingTypeId
string or null

Thing type reference: UUID (thing_types.id) or globally unique type name; when omitted or empty, auto-binds to reserved unassigned-device-type

Responses

Request samples

Content type
application/json
{
  • "metadata": null,
  • "mqttClientId": "string",
  • "name": "string",
  • "tags": [
    ],
  • "thingTypeId": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CreateThingResponseBody.json",
  • "cert": {
    },
  • "createdAt": "2019-08-24T14:15:22Z",
  • "credential": {
    },
  • "groups": [
    ],
  • "id": "string",
  • "lastOfflineAt": "2019-08-24T14:15:22Z",
  • "lastOnlineAt": "2019-08-24T14:15:22Z",
  • "metadata": null,
  • "mqttClientId": "string",
  • "name": "string",
  • "schema": null,
  • "shadow": {
    },
  • "status": "string",
  • "tags": [
    ],
  • "thingType": {
    },
  • "thingTypeId": "string",
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Export things to a JSON array file

Export selected things by IDs as a downloadable .json file whose content is an array of thing objects.

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
thingIds
required
Array of strings or null

Thing UUID list to export

Responses

Request samples

Content type
application/json
{
  • "thingIds": [
    ]
}

Response samples

Content type
application/json
[
  • {
    }
]

Import things from a JSON file

Upload a single .json file (form field 'file') containing an array of thing objects. Import is partial-success: successful rows are created and failed rows are reported in errors.

Authorizations:
basicAuthbearerAuth
Request Body schema: multipart/form-data
file
required
string <binary> <binary> <application/octet-stream>

Things JSON file (array of thing objects)

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ImportThingsOutputBody.json",
  • "errors": [
    ],
  • "failureCount": 0,
  • "successCount": 0,
  • "things": [
    ]
}

List thing events

Returns event history for one thing from EMQX Tables.

Authorizations:
basicAuthbearerAuth
path Parameters
thingName
required
string

Thing name

query Parameters
from
string

Start time, RFC3339 or RFC3339Nano

to
string

End time, RFC3339 or RFC3339Nano

eventType
string

Filter by event type

severity
string

Filter by severity

limit
integer <int64> [ 1 .. 100 ]
Default: 20

Items per page

offset
integer <int64> >= 0
Default: 0

Items to skip

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Replace tags on things

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
tags
required
Array of strings or null

Full tag name list

thingIds
required
Array of strings or null

Thing UUIDs

Responses

Request samples

Content type
application/json
{
  • "tags": [
    ],
  • "thingIds": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Add tags to things

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
tags
required
Array of strings or null

Tag names to add

thingIds
required
Array of strings or null

Thing UUIDs

Responses

Request samples

Content type
application/json
{
  • "tags": [
    ],
  • "thingIds": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Remove tags from things

Authorizations:
basicAuthbearerAuth
Request Body schema: application/json
required
tags
required
Array of strings or null

Tag names to remove

thingIds
required
Array of strings or null

Thing UUIDs

Responses

Request samples

Content type
application/json
{
  • "tags": [
    ],
  • "thingIds": [
    ]
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Delete a thing

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Get a thing

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/Thing.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "groups": [
    ],
  • "id": "string",
  • "lastOfflineAt": "2019-08-24T14:15:22Z",
  • "lastOnlineAt": "2019-08-24T14:15:22Z",
  • "metadata": null,
  • "mqttClientId": "string",
  • "name": "string",
  • "schema": null,
  • "shadow": {
    },
  • "status": "string",
  • "tags": [
    ],
  • "thingType": {
    },
  • "thingTypeId": "string",
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Update a thing

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing ID

Request Body schema: application/json
required
metadata
any

Metadata (JSON object)

mqttClientId
string or null

MQTT client ID

name
string or null

Thing name

tags
Array of strings or null

Tag names to attach

thingTypeId
string or null

Thing type reference: UUID or globally unique name; null/empty auto-binds to reserved unassigned-device-type

Responses

Request samples

Content type
application/json
{
  • "metadata": null,
  • "mqttClientId": "string",
  • "name": "string",
  • "tags": [
    ],
  • "thingTypeId": "string"
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/Thing.json",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "groups": [
    ],
  • "id": "string",
  • "lastOfflineAt": "2019-08-24T14:15:22Z",
  • "lastOnlineAt": "2019-08-24T14:15:22Z",
  • "metadata": null,
  • "mqttClientId": "string",
  • "name": "string",
  • "schema": null,
  • "shadow": {
    },
  • "status": "string",
  • "tags": [
    ],
  • "thingType": {
    },
  • "thingTypeId": "string",
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Get thing tags

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/GetThingTagsOutputBody.json",
  • "tags": [
    ]
}

Device Certificates

Revoke device certificate

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Get device certificate metadata

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CertBrief.json",
  • "cn": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "fingerprint": "string",
  • "keyAlgorithm": "string",
  • "notAfter": "2019-08-24T14:15:22Z",
  • "notBefore": "2019-08-24T14:15:22Z",
  • "revoked": true,
  • "revokedAt": "2019-08-24T14:15:22Z",
  • "serial": "string",
  • "thingName": "string"
}

Issue device certificate

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

Request Body schema: application/json
required

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CertResponse.json",
  • "certPem": "string",
  • "fingerprint": "string",
  • "keyAlgorithm": "string",
  • "keyPem": "string",
  • "message": "string",
  • "notAfter": "2019-08-24T14:15:22Z",
  • "notBefore": "2019-08-24T14:15:22Z",
  • "serial": "string",
  • "thingName": "string"
}

Download device certificate PEM (certPem + keyPem as JSON strings)

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CertResponse.json",
  • "certPem": "string",
  • "fingerprint": "string",
  • "keyAlgorithm": "string",
  • "keyPem": "string",
  • "message": "string",
  • "notAfter": "2019-08-24T14:15:22Z",
  • "notBefore": "2019-08-24T14:15:22Z",
  • "serial": "string",
  • "thingName": "string"
}

Renew device certificate

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

Request Body schema: application/json
required

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CertResponse.json",
  • "certPem": "string",
  • "fingerprint": "string",
  • "keyAlgorithm": "string",
  • "keyPem": "string",
  • "message": "string",
  • "notAfter": "2019-08-24T14:15:22Z",
  • "notBefore": "2019-08-24T14:15:22Z",
  • "serial": "string",
  • "thingName": "string"
}

Device Credentials

List device credentials

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Generate MQTT password credential

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

Request Body schema: application/json
required

Responses

Request samples

Content type
application/json
{ }

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CredentialResponse.json",
  • "authIdentity": "string",
  • "authType": "string",
  • "id": "string",
  • "password": "string",
  • "status": "string",
  • "thingName": "string",
  • "username": "string"
}

Revoke device credential

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

credId
required
string

Credential ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/DeleteResponse.json",
  • "message": "deleted"
}

Get device credential metadata

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

credId
required
string

Credential ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CredentialBrief.json",
  • "authIdentity": "string",
  • "authType": "string",
  • "createdAt": "2019-08-24T14:15:22Z",
  • "id": "string",
  • "lastResetAt": "2019-08-24T14:15:22Z",
  • "revokedAt": "2019-08-24T14:15:22Z",
  • "status": "string",
  • "thingName": "string",
  • "updatedAt": "2019-08-24T14:15:22Z"
}

Reset device credential password

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing name

credId
required
string

Credential ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/CredentialResponse.json",
  • "authIdentity": "string",
  • "authType": "string",
  • "id": "string",
  • "password": "string",
  • "status": "string",
  • "thingName": "string",
  • "username": "string"
}

Device Shadow

Clear shadow desired state

Clears the desired state of the shadow, effectively cancelling any pending desired changes.

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ShadowBody.json",
  • "delta": {
    },
  • "desired": {
    },
  • "id": "string",
  • "reported": {
    },
  • "thingId": "string",
  • "updatedAt": "string",
  • "version": 0
}

Get device shadow

Returns the full shadow document for a thing including reported, desired, and delta states.

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing ID

Responses

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ShadowBody.json",
  • "delta": {
    },
  • "desired": {
    },
  • "id": "string",
  • "reported": {
    },
  • "thingId": "string",
  • "updatedAt": "string",
  • "version": 0
}

Update device shadow desired state

Merges the given desired state into the shadow. Computes and publishes a delta via MQTT if differences exist.

Authorizations:
basicAuthbearerAuth
path Parameters
id
required
string

Thing ID

Request Body schema: application/json
required
required
object

Desired state to merge

Responses

Request samples

Content type
application/json
{
  • "desired": {
    }
}

Response samples

Content type
application/json
{
  • "$schema": "//schemas/ShadowBody.json",
  • "delta": {
    },
  • "desired": {
    },
  • "id": "string",
  • "reported": {
    },
  • "thingId": "string",
  • "updatedAt": "string",
  • "version": 0
}