Track Device Variables

Stores metadata for a specific device.

Endpoint

  • Method: POST

  • Path: /api/v4/track_device_variables

  • Description: Stores metadata variables for a specific device.

Authentication

See License API Authorization.

Required headers

  • Date (string) — RFC7231 GMT date string

  • Authorization (string)

  • Accept: application/json

  • Content-Type: application/json

Request

Body parameters

  • hardware_id (string, required) — Unique hardware ID generated for the client device

  • product (string, required) — Product short code

  • variables (object, required) — JSON key-value object, with keys being variable names and values being the values to set for those variables. Values may be string, number or boolean

  • license_key (string, optional) — Required if product is key-based

  • username (string, optional) — Required if product is user-based

  • license_id (number, optional) — Ensures that the action affects only the license with the specified ID. Useful if you have multiple licenses for the same product assigned to the same user.

Hints

circle-info

Variables are sent as a JSON object, where parameter is the variable name and value is the value of the variable, e.g.:

"variables": { "some_variable_name": "some value", "another_variable_name": "another value" }

triangle-exclamation
circle-info

Device variables can also be set during activation by providing a variables parameter in the activation payload. For examples, see: Activate License (Online Method) and Deactivate Bundle (Offline Method).

Schema

chevron-rightRequest schema (TypeScript + JSON Schema)hashtag

TypeScript

JSON Schema

chevron-rightResponse schema (TypeScript + JSON Schema)hashtag

TypeScript

JSON Schema

Examples

Successful and error responses

chevron-rightSuccess response example (200)hashtag
chevron-rightError response example (400)hashtag

License Authorization Method

There are two types of product licenses based on how the client application authorizes itself to interact with a license:

  • Key-based product licenses: client interactions with the license have to be authorized using a license_key

  • User-based product licenses: the license has a corresponding "license user" instead of a license key. Client interactions with the license have to be authorized using a username

Errors

If an error occurs, the response will have an HTTP status code of 400 or higher, and the response body will contain an error description in the following format:

JSON Schema

List of exceptions

chevron-rightunknown_product (400)hashtag

Provided product was not found

chevron-rightlicense_not_found (400)hashtag

License with the provided license user not found

chevron-rightlicense_not_active (400)hashtag

The license is not active

chevron-rightlicense_not_enabled (400)hashtag

The license is not enabled

chevron-rightdevice_not_found (400)hashtag

An active device matching the hardware_id not found

chevron-rightblacklisted (400)hashtag

This device is blacklisted

Last updated

Was this helpful?