allocdata.json
allocdata.json is loaded when the device transitions to the
allocated state (assigned to a user). It can override the
global baseline, define which apps are active, and inject
user‑specific data.
When fetched from the IES, the file includes a result/
httpResponseCode envelope. The local version (/allocdata.json)
may use the same envelope; the device parses the data object
regardless.
{ "result": "true", "httpResponseCode": 200, "data": { "global": { "dev": { "alert": { "cancelByReplace": true } } }, "network": { "networkOrder": ["k1", "q1"] }, "user": { "visitor": "john.doe", "apps": { "allocated_home": { "id": "home", "src": "local", "data": { "logo": "site_logo" } } } }, "apps": {}, "dicts": [ "config/locations.json", "config/names.json" ] }}result / httpResponseCode
Section titled “result / httpResponseCode”Status wrapper returned by the IES. result is a string "true"
or "false", and httpResponseCode mirrors the HTTP status.
Configuration variables
- Type: string / number
- Required: when fetched from IES; optional for local files
{ "result": "true", "httpResponseCode": 200, "data": { /* … */ }}The payload that configures the device.
data.global
Section titled “data.global”Contains device‑wide overrides that are merged with the
global.json baseline. Any key that exists in both files will
use the value from allocdata.json during the allocated state.
Configuration variables
- Type: object
- Required: no
{ "data": { "global": { "dev": { "alert": { "cancelByReplace": true } } } }}data.global.dev
Section titled “data.global.dev”A container for devcfg keys that should be active for this
specific allocation. See Device Config
for the complete set of supported keys.
{ "data": { "global": { "dev": { "core": { "update_period_mins": 5 }, "nfc": { "emul": false } } } }}If a key is present in both
allocdata.jsonandglobal.json, the value fromallocdata.jsonwins. Only the keys you specify are overridden; everything else remains as defined globally.
data.network
Section titled “data.network”Controls which networks are active during the allocated state.
Configuration variables
- Type: object
- Required: no
{ "data": { "network": { "networkOrder": ["k1", "b1"] } }}
networkOrderis typically the only field set here. The actual network definitions (SSIDs, passwords) are usually kept inglobal.jsonto avoid duplication. However, you can also include anetworksblock if you need state‑specific WiFi credentials.
data.user
Section titled “data.user”User‑specific information and the list of active apps (Device Views).
Configuration variables
- Type: object
- Required: no
{ "data": { "user": { "visitor": "john.doe", "apps": { /* … */ } } }}data.user.visitor
Section titled “data.user.visitor”An identifier string for the current user. Appears in logs and can be shown on the device UI.
Configuration variables
- Type: string
- Required: no
- Default:
""
{ "data": { "user": { "visitor": "Dr. Smith" } } }data.user.apps
Section titled “data.user.apps”Defines which Device Views (DVs) are active during allocation. Each key is the source name (how the DV is known on the IES or on the filesystem), and the value is an object that can rename the DV and set its initial data.
Configuration variables
- Type: object of DV objects
- Required: no
{ "data": { "user": { "apps": { "allocated_home": { "id": "home", "src": "local", "data": { "logo": "site_logo" } }, "my_custom_app": { "id": "custom", "src": "local" } } } }}Each app object has the following fields:
| Field | Type | Required | Description |
|---|---|---|---|
id | string | yes | The DV name used on the device (e.g. "home", "lock", "duress") |
src | string | yes | "local" (from /dvs/<source_name>.json) or "inline" (from the allocdata itself) |
data | object | no | Initial widget values for the DV (keyed by widget name) |
The
idfield allows you to have multiple source DVs with different names but map them to the same functional role on the device. For example,allocated_homeandunallocated_homecan both become"home".
data.apps
Section titled “data.apps”Reserved top‑level key. Present for IES compatibility, normally left as an empty object.
Configuration variables
- Type: object
- Required: no
{ "data": { "apps": {} } }data.dicts
Section titled “data.dicts”Array of dictionary file paths relative to the USB filesystem root. These files map two‑character keys to human‑readable strings and are used for TLV message encoding/decoding.
Configuration variables
- Type: array of strings
- Required: no
{ "data": { "dicts": [ "config/locations.json", "config/names.json", "config/tlv_down.json", "config/tlv_up.json" ] }}Dictionary files are loaded at boot and remain active until the device state changes. See Dictionary Files for the exact format.
Related
Section titled “Related”- Global.json – the always‑loaded baseline
- Unallocdata.json – the unallocated‑state counterpart
- Device Config – all keys available inside
dev - App Downlink – how DVs are referenced in MQTT commands