Skip to content

Device Configuration

The device.json5 configuration file contains device identification and descriptive properties to uniquely identify a device. It is used during device registration and cloud provisioning.

The device.json5 contains properties for:

  • The device unique ID
  • A product token indicating which product on which the device is based
  • When the device was made
  • Identifying description and model strings
  • Whether the device is a test device

You can also add any other properties to the device.json5 that may provide useful device context. These properties will be saved in the cloud device database and will be available to device managers.

Example

js
{
    id: "731KPY4BA6",
    product: "01GHTB33NJZXYZ1XA80GY5SZSN",
    name: "Acme Router",
    created: "2022-12-14T03:20:39.347Z",
    description: "Acme Router for Home Office",
    model: "Office-Hub",
    test: false,
    ports: 16,
    memory: "256MB"
}

created

Namecreated
DescriptionAn ISO date for when the device was manufactured.
Synopsiscreated: 'ISO Date'.

Example

js
created: '2022-12-14T03:20:39.347Z'

description

Namedescription
DescriptionA short description of your product.
Synopsisdescription: 'Short sentence'
NotesThis should be a one sentence description of your product.

Example

js
description: 'Acme Router for Home Office'

id

Nameid
DescriptionThe unique device claim ID.
Synopsisid: "Unique device ID"
NotesThe id property defines a unique per-device ID. This must be a globally unique ID. This should have a minimum of 80-bits of entropy. For more information, see Builder Serialization.

Example

js
id: '731KPY4BA6'

model

Namemodel
DescriptionA product model string.
Synopsismodel: 'Short model string'
NotesThis should be a short identifier that describes your device model type.

Example

js
model: 'Office-Hub-32'

name

Namename
DescriptionThe name of your product.
Synopsisname: 'Few words'
NotesThis should be the short, public name of your product.

Example

js
name: 'Acme Rocket'

product

Nameproduct
DescriptionThe product ID token is a Builder token that identifies the product on which the device was based.
Synopsisproduct: 'product-id'
NotesTo obtain a product token, use the Builder to create a product definition and then get the ProductID token from the token list.

Example

js
product: '01GHTB33NJZXYZ1XA80GY5SZSN'

test

Nametest
DescriptionDetermine if the device is a test device
Synopsis`test: true
NotesThis defaults to false.

Example

js
test: true