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

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" }

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

Request schema (TypeScript + JSON Schema)

TypeScript

JSON Schema

Response schema (TypeScript + JSON Schema)

TypeScript

JSON Schema

Examples

Successful and error responses

Success response example (200)
Error response example (400)

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

unknown_product (400)

Provided product was not found

license_not_found (400)

License with the provided license user not found

license_not_active (400)

The license is not active

license_not_enabled (400)

The license is not enabled

device_not_found (400)

An active device matching the hardware_id not found

blacklisted (400)

This device is blacklisted

Last updated

Was this helpful?