Get device configuration schemas

GET/devices/{deviceId}/configSchemas

Base URL: https://api.tinkermode.com

Get all configuration schemas associated with a specified device. Each returned item includes the applicable firmware component name, component version name, and the device configuration schema.

Authentication

Send an Authorization header of the form ModeCloud <AUTH_CODE>.

Must contain a user key, service account token, project API key, or API key of the matching device.

Path parameters

NameTypeRequiredConstraintsDescription
deviceIdintegerYesDevice ID

Responses

200 Successful retrieval of the device's configuration schemas.

Content type: application/json

Represents the configuration schema associated with a device component.

An array of objects with the following shape:

PropertyTypeRequiredConstraintsDescription
componentNamestringNoread-only (server-generated)Display name of component and is unique per project.
componentVersionNamestringNoread-only (server-generated)Display name of component version e.g. 1.0.1
deviceConfigSchemaarrayNoread-only (server-generated)A template used to create a configuration for a firmware component.

Response example

[
  {
    "componentName": "generic-file-transfer",
    "componentVersionName": "generic-file-transfer-v1.0.5",
    "deviceConfigSchema": [
      {
        "description": "File transfer driver settings for Customer X.",
        "keyName": "ug::customer_x_ft_driver[{{instanceId}}]::configurations",
        "name": "Customer X's file transfer driver settings",
        "parameters": [
          {
            "key": "instanceId",
            "label": "Instance ID",
            "required": true,
            "type": "string"
          },
          {
            "default": "host1.example.com",
            "key": "sshHost",
            "label": "SSH Host",
            "required": true,
            "type": "string"
          },
          {
            "default": "password1234",
            "key": "sshPassword",
            "label": "SSH Password",
            "required": true,
            "type": "string"
          }
        ],
        "repeatable": true
      },
      {
        "description": "Configuration schema for log retrieval.",
        "keyName": "ug::{{peripheralModelId}}:{{peripheralModuleId}}::configurations",
        "name": "Log retrieval module schema",
        "parameters": [
          {
            "key": "peripheralModelId",
            "label": "Model ID",
            "required": true,
            "type": "string"
          },
          {
            "key": "peripheralModuleId",
            "label": "Module ID",
            "required": true,
            "type": "string"
          },
          {
            "default": "/var/log",
            "key": "coreDirectory",
            "label": "SSH Host",
            "required": true,
            "type": "string"
          }
        ],
        "repeatable": false
      }
    ]
  },
  {
    "componentName": "generic-time-series-injector",
    "componentVersionName": "generic-time-series-injector-v2.04",
    "deviceConfigSchema": [
      {
        "description": "Time series injector driver settings for Customer X.",
        "keyName": "ug::customer_x_tsdb_injector[{{instanceId}}]::configurations",
        "name": "Customer X's time series injector driver settings",
        "parameters": [
          {
            "key": "instanceId",
            "label": "Instance ID",
            "required": true,
            "type": "string"
          },
          {
            "default": 1000,
            "key": "maxDataPointsPerSecond",
            "label": "Maximum Data Points Per Second",
            "required": true,
            "type": "number"
          }
        ],
        "repeatable": true
      }
    ]
  }
]

401 Authorization is required to access this resource.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

403 Request failed because of denied permission.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

429 Request failed because of rate limit.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

500 An unexpected error has occurred.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

503 The service is temporarily unavailable.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.