Skip to content

Reference

Products

REST API reference for Products: manage products and their profile, properties, firmwares and services. 38 operations.

Reference45 min read

For the base URL, authentication and errors, see the REST API overview.

GET /v1/users/{user}/products ​

  • Request: GET /v1/users/{user}/products
  • Operation: ListProducts
  • Operation ID: Product_List
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

POST /v1/users/{user}/products ​

  • Request: POST /v1/users/{user}/products
  • Operation: CreateProduct
  • Operation ID: Product_Create
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
configobjectnoConfiguration schema for a product
config.fieldsarray of objectno
config.fields[].iconobjectnoIcon schema for a product
config.fields[].icon.backgroundstringno
config.fields[].icon.colorstringno
config.fields[].icon.sizenumberno
config.fields[].icon.sourcestringyes
config.fields[].icon.typestringyesOne of: fa, svgIcon type: font-awesome or svg
config.fields[].namestringyesLength: 1 to 255
config.fields[].primarybooleanno
config.fields[].typestringnoOne of: string, number, date, time, datetime, timeago
config.fields[].valuestringyesLength: 1 to 255
config.iconsarray of objectno
config.icons[].conditionsarray of objectno
config.icons[].conditions[]objectnoVariant 1:
config.icons[].conditions[].comparisonstringnoOne of: above, below, equal, not_equal, inside, outside, present, absentVariant 1: Comparison expressions for conditional evaluation. Every comparison but present / absent is false on a missing field.
config.icons[].conditions[].fieldstringnoLength: 1 to 255Variant 1:
config.icons[].conditions[].operatorstringnoOne of: and, orVariant 1: Operator expressions for conditional evaluation
config.icons[].conditions[].tagstringnoVariant 1:
config.icons[].conditions[].valuestringyesLength: 1 to 255Variant 1:
config.icons[].conditions[]objectnoVariant 2:
config.icons[].conditions[].comparisonstringnoOne of: above, below, equal, not_equal, inside, outside, present, absentVariant 2: Comparison expressions for conditional evaluation. Every comparison but present / absent is false on a missing field.
config.icons[].conditions[].fieldstringnoLength: 1 to 255Variant 2:
config.icons[].conditions[].maxstringyesLength: 1 to 255Variant 2:
config.icons[].conditions[].minstringyesLength: 1 to 255Variant 2:
config.icons[].conditions[].operatorstringnoOne of: and, orVariant 2: Operator expressions for conditional evaluation
config.icons[].conditions[].tagstringnoVariant 2:
config.icons[].iconobjectyesIcon schema for a product
config.icons[].icon.backgroundstringno
config.icons[].icon.colorstringno
config.icons[].icon.sizenumberno
config.icons[].icon.sourcestringyes
config.icons[].icon.typestringyesOne of: fa, svgIcon type: font-awesome or svg
config.typestringnoOne of: ``, thinremoteProduct type that determines the device status view
descriptionstringnoMaximum length: 255A brief description of the resource, providing context or additional information, limited to 255 characters.
enabledbooleanno
namestringyesMaximum length: 255The name of the resource, limited to 255 characters. It can include any character.
productstringyesPattern: ^[a-zA-Z0-9_-]{1,32}$A unique identifier for resources, consisting of alphanumeric characters, underscores, or hyphens, and limited to 32 characters.
profileobjectno
servicesobjectno

Example request (skeleton generated from the schema: required fields only, neutral values)

bash
curl -X POST 'https://YOUR_SERVER/v1/users/YOUR_USER/products' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "product": "",
  "name": ""
}'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product} ​

  • Request: GET /v1/users/{user}/products/
  • Operation: ReadProductConfig
  • Operation ID: Product_ReadConfig
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product} ​

  • Request: PUT /v1/users/{user}/products/
  • Operation: UpdateProduct
  • Operation ID: Product_Update
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
configobjectnoConfiguration schema for a product
config.fieldsarray of objectno
config.fields[].iconobjectnoIcon schema for a product
config.fields[].icon.backgroundstringno
config.fields[].icon.colorstringno
config.fields[].icon.sizenumberno
config.fields[].icon.sourcestringyes
config.fields[].icon.typestringyesOne of: fa, svgIcon type: font-awesome or svg
config.fields[].namestringyesLength: 1 to 255
config.fields[].primarybooleanno
config.fields[].typestringnoOne of: string, number, date, time, datetime, timeago
config.fields[].valuestringyesLength: 1 to 255
config.iconsarray of objectno
config.icons[].conditionsarray of objectno
config.icons[].conditions[]objectnoVariant 1:
config.icons[].conditions[].comparisonstringnoOne of: above, below, equal, not_equal, inside, outside, present, absentVariant 1: Comparison expressions for conditional evaluation. Every comparison but present / absent is false on a missing field.
config.icons[].conditions[].fieldstringnoLength: 1 to 255Variant 1:
config.icons[].conditions[].operatorstringnoOne of: and, orVariant 1: Operator expressions for conditional evaluation
config.icons[].conditions[].tagstringnoVariant 1:
config.icons[].conditions[].valuestringyesLength: 1 to 255Variant 1:
config.icons[].conditions[]objectnoVariant 2:
config.icons[].conditions[].comparisonstringnoOne of: above, below, equal, not_equal, inside, outside, present, absentVariant 2: Comparison expressions for conditional evaluation. Every comparison but present / absent is false on a missing field.
config.icons[].conditions[].fieldstringnoLength: 1 to 255Variant 2:
config.icons[].conditions[].maxstringyesLength: 1 to 255Variant 2:
config.icons[].conditions[].minstringyesLength: 1 to 255Variant 2:
config.icons[].conditions[].operatorstringnoOne of: and, orVariant 2: Operator expressions for conditional evaluation
config.icons[].conditions[].tagstringnoVariant 2:
config.icons[].iconobjectyesIcon schema for a product
config.icons[].icon.backgroundstringno
config.icons[].icon.colorstringno
config.icons[].icon.sizenumberno
config.icons[].icon.sourcestringyes
config.icons[].icon.typestringyesOne of: fa, svgIcon type: font-awesome or svg
config.typestringnoOne of: ``, thinremoteProduct type that determines the device status view
descriptionstringnoMaximum length: 255A brief description of the resource, providing context or additional information, limited to 255 characters.
enabledbooleanno
namestringnoMaximum length: 255The name of the resource, limited to 255 characters. It can include any character.

Example request (skeleton generated from the schema: required fields only, neutral values)

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{}'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

DELETE /v1/users/{user}/products/{product} ​

  • Request: DELETE /v1/users/{user}/products/
  • Operation: DeleteProduct
  • Operation ID: Product_Delete
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl -X DELETE 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/clone ​

  • Request: GET /v1/users/{user}/products/{product}/clone
  • Operation: CloneProductConfig
  • Operation ID: Product_CloneConfig
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/clone' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

POST /v1/users/{user}/products/{product}/clone ​

  • Request: POST /v1/users/{user}/products/{product}/clone
  • Operation: CloneProduct
  • Operation ID: Product_Clone
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
descriptionstringnoMaximum length: 255A brief description of the resource, providing context or additional information, limited to 255 characters.
enabledbooleanno
namestringnoMaximum length: 255The name of the resource, limited to 255 characters. It can include any character.
productstringyesPattern: ^[a-zA-Z0-9_-]{1,32}$A unique identifier for resources, consisting of alphanumeric characters, underscores, or hyphens, and limited to 32 characters.

Example request: Copy with a new id

bash
curl -X POST 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/clone' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "product": "copy_of_product"
}'

Example body: Copy with name and description

json
{
  "description": "Same configuration as the original, for production line 2",
  "name": "Line 2 copy",
  "product": "line_2_product"
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/export ​

  • Request: GET /v1/users/{user}/products/{product}/export
  • Operation: ExportProduct
  • Operation ID: Product_Export
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/export' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/firmwares ​

  • Request: GET /v1/users/{user}/products/{product}/firmwares
  • Operation: ListProductFirmwares
  • Operation ID: Product_ListFirmwares
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

POST /v1/users/{user}/products/{product}/firmwares ​

  • Request: POST /v1/users/{user}/products/{product}/firmwares
  • Operation: CreateProductFirmware
  • Operation ID: Product_CreateFirmware
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
firmwarestringyesPattern: ^[a-zA-Z0-9_]{1,25}$
namestringnoMaximum length: 255
versionstringyesPattern: (?:0|[1-9]\d*)\.(?:0|[1-9]\d*)\.(?:0|[1-9]\d*)(?:-[\da-z-]+(?:\.[\da-z-]+)*)?(?:\+[\da-z-]+(?:\.[\da-z-]+)*)?

Example request (skeleton generated from the schema: required fields only, neutral values)

bash
curl -X POST 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "firmware": "",
  "version": ""
}'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version} ​

  • Request: GET /v1/users/{user}/products/{product}/firmwares/{firmware}/
  • Operation: ReadProductFirmwareConfig
  • Operation ID: Product_ReadFirmwareConfig
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
firmwarepathstringyes
firmware_versionpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares/YOUR_FIRMWARE/YOUR_FIRMWARE_VERSION' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version} ​

  • Request: PUT /v1/users/{user}/products/{product}/firmwares/{firmware}/
  • Operation: UpdateProductFirmware
  • Operation ID: Product_UpdateFirmware
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
firmwarepathstringyes
firmware_versionpathstringyes

Request body (application/json, required)

A JSON object.

Example request (skeleton generated from the schema: required fields only, neutral values)

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares/YOUR_FIRMWARE/YOUR_FIRMWARE_VERSION' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{}'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

DELETE /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version} ​

  • Request: DELETE /v1/users/{user}/products/{product}/firmwares/{firmware}/
  • Operation: DeleteProductFirmware
  • Operation ID: Product_DeleteFirmware
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
firmwarepathstringyes
firmware_versionpathstringyes

Example request

bash
curl -X DELETE 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares/YOUR_FIRMWARE/YOUR_FIRMWARE_VERSION' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version}/flash ​

  • Request: GET /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version}/flash
  • Operation: FlashProductFirmware
  • Operation ID: Product_FlashFirmware
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
firmwarepathstringyes
firmware_versionpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares/YOUR_FIRMWARE/YOUR_FIRMWARE_VERSION/flash' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version}/stream ​

  • Request: GET /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version}/stream
  • Operation: UpdateProductFirmware
  • Operation ID: Product_UpdateFirmwareStream
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
firmwarepathstringyes
firmware_versionpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares/YOUR_FIRMWARE/YOUR_FIRMWARE_VERSION/stream' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version}/toolchain ​

  • Request: GET /v1/users/{user}/products/{product}/firmwares/{firmware}/{firmware_version}/toolchain
  • Operation: UpdateProductFirmware
  • Operation ID: Product_UpdateFirmwareToolchain
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
firmwarepathstringyes
firmware_versionpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/firmwares/YOUR_FIRMWARE/YOUR_FIRMWARE_VERSION/toolchain' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/profile/code ​

  • Request: GET /v1/users/{user}/products/{product}/profile/code
  • Operation: ReadProductProfile
  • Operation ID: Product_ReadProfileCode
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/code' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product}/profile/code ​

  • Request: PUT /v1/users/{user}/products/{product}/profile/code
  • Operation: UpdateProductProfile
  • Operation ID: Product_UpdateProfileCode
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
(body)object or nullnoJavaScript run by the server for this product: functions referenced by payload_function, device_id_resolver and function targets. Inline in code, or the files of a file storage in storage (takes precedence): its index.js, or <path>/index.js with path, so one storage can hold a whole application (dashboard, product code…).
(body).codestring or nullno
(body).pathstring or nullnoFolder of the storage with the code (its index.js and node_modules), relative to the storage root, e.g. "code/meter". Empty: the storage root.
(body).storagestring or nullnoFile storage id with the product code.

Example request: Code from a file storage

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/code' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "storage": "meter_product_code"
}'

Example body: Code from a folder of an application storage

json
{
  "path": "code/meter",
  "storage": "fleet_app"
}

Example body: Inline code

json
{
  "code": "function resolveDevice(payload) {\n  // device id from the serial sent by the caller\n  return 'meter_' + payload.serial;\n}\n\nfunction toCelsius(payload) {\n  return { temperature: (payload.temperature_f - 32) * 5 / 9 };\n}\n"
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/profile/console ​

  • Request: GET /v1/users/{user}/products/{product}/profile/console
  • Operation: ReadProductProfile
  • Operation ID: Product_ReadProfileConsole
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/console' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/profile/{category} ​

  • Request: GET /v1/users/{user}/products/{product}/profile/
  • Operation: ReadProductProfile
  • Operation ID: Product_ReadProfile
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
categorypathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/YOUR_CATEGORY' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product}/profile/{category} ​

  • Request: PUT /v1/users/{user}/products/{product}/profile/
  • Operation: UpdateProductProfile
  • Operation ID: Product_UpdateProfile
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Replace every entry of a profile category. Entries missing from the body are removed; to change one entry use PUT .../profile/{category}/{resource}.

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
categorypathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
(body)object or nullnoEvery entry of a category, by id. Replaces the whole category: entries missing from the body are removed (for properties, also the default property on the devices).
(body).*object or nullnoOne entry of a product profile category; its id is the {resource} path parameter (or the key in a category body). Entries only run when enabled is true. Fields by category. properties: data fills the device property of the same id (optional), default.value (any value but null: {}, [], "", 0 and false count) / form / perm make it a property of the product, which every device of the product inherits (source: product) until it sets its own. buckets: data writes into the bucket with the entry id, created on the first write, outside any project (devices read it through GET /devices/{device}/buckets/{bucket}/data); an id containing {{device}} gives one bucket per device (such ids only fit the whole-category PUT, as the {resource} path parameter cannot hold braces), otherwise one shared bucket tagged with device (and group); tags, backend, retention. flows: data → sink, split_data sends each array element separately. api: resources added to every device of the product: request.data (target), response.data (response), device_id_resolver (function of the product code that returns the device id from the payload, needed to call the resource through POST /products/{product}/resources/{resource}), handle_connectivity (validate / auto-provision the device on calls; default true for resource_stream targets). autoprovisions: config. endpoints: deprecated, use flows with an endpoint_call sink.
(body).*.backendanynobuckets: storage backend of the bucket when it is created (mongodb, influxdb, dynamodb; default the server's).
(body).*.configobject or nullnoautoprovisions: when a device that does not exist authenticates or calls a resource and its id matches pattern, it is created in this product (HTTP, or Subdevice for MQTT), with asset type / group and project if given.
(body).*.config.groupstring or nullnoAsset group for the new devices.
(body).*.config.modestring or nullnopattern
(body).*.config.patternstring or nullnoRegular expression on the device id, e.g. ^meter_[0-9]{6}$.
(body).*.config.projectstring or nullnoProject for the new devices.
(body).*.config.typestring or nullnoAsset type for the new devices.
(body).*.dataobject or null or array of object or null or null or nullnoData source, or an array of sources.
(body).*.dataobject or nullnoVariant 1: Where a properties / buckets / flows entry gets its data. source selects the fields used: topic → topic (MQTT topic, + and # wildcards; {{name}} placeholders match one level, and in buckets each one becomes a tag of the record, with {{field}} naming the record field so several topics merge into one record); resource → resource, update (interval | events) with interval + magnitude; resource_stream → resource_stream (the device pushes it); product_stream → product_stream; event → event with optional filter. Only devices of this product are listened to. The received data can then be transformed with payload_type / payload and payload_function.
(body).*.data.eventstring or nullnoVariant 1: source event: server event name, e.g. device_state_change, device_property_update, bucket_write.
(body).*.data.filterobject or nullnoVariant 1: source event: extra filters (event field: value or regex). The product filter is always added.
(body).*.data.intervalnumber or string or nullnoVariant 1: source resource with update interval: number of magnitude units between reads, e.g. 60.
(body).*.data.magnitudestring or nullnoVariant 1: second (default) | minute | hour | day | week | month | year
(body).*.data.patchboolean or nullnoVariant 1: properties only: merge the value into the device property instead of replacing it.
(body).*.data.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).*.data.payload_functionstring or nullnoVariant 1: Name of a function of the product code that receives the payload and returns the value to use.
(body).*.data.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).*.data.product_streamstring or nullnoVariant 1: source product_stream: stream published by an API resource or flow of this product (target product_stream).
(body).*.data.resourcestring or nullnoVariant 1: source resource: device resource read by the server.
(body).*.data.resource_streamstring or nullnoVariant 1: source resource_stream: device resource the device streams on its own.
(body).*.data.sourcestring or nullnoVariant 1: topic | resource | resource_stream | product_stream | event
(body).*.data.topicstring or nullnoVariant 1: source topic: MQTT topic of the device messages, e.g. devices/{{device}}/telemetry.
(body).*.data.updatestring or nullnoVariant 1: source resource: interval (default, read every interval magnitude) | events (the device streams it when it changes).
(body).*.dataarray of object or null or nullnoVariant 2:
(body).*.data[].eventstring or nullnoVariant 2: source event: server event name, e.g. device_state_change, device_property_update, bucket_write.
(body).*.data[].filterobject or nullnoVariant 2: source event: extra filters (event field: value or regex). The product filter is always added.
(body).*.data[].intervalnumber or string or nullnoVariant 2: source resource with update interval: number of magnitude units between reads, e.g. 60.
(body).*.data[].magnitudestring or nullnoVariant 2: second (default) | minute | hour | day | week | month | year
(body).*.data[].patchboolean or nullnoVariant 2: properties only: merge the value into the device property instead of replacing it.
(body).*.data[].payloadanynoVariant 2: Template string (payload_type template_payload) or JSON value.
(body).*.data[].payload_functionstring or nullnoVariant 2: Name of a function of the product code that receives the payload and returns the value to use.
(body).*.data[].payload_typestring or null or nullnoVariant 2: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).*.data[].product_streamstring or nullnoVariant 2: source product_stream: stream published by an API resource or flow of this product (target product_stream).
(body).*.data[].resourcestring or nullnoVariant 2: source resource: device resource read by the server.
(body).*.data[].resource_streamstring or nullnoVariant 2: source resource_stream: device resource the device streams on its own.
(body).*.data[].sourcestring or nullnoVariant 2: topic | resource | resource_stream | product_stream | event
(body).*.data[].topicstring or nullnoVariant 2: source topic: MQTT topic of the device messages, e.g. devices/{{device}}/telemetry.
(body).*.data[].updatestring or nullnoVariant 2: source resource: interval (default, read every interval magnitude) | events (the device streams it when it changes).
(body).*.datanullnoVariant 3:
(body).*.defaultobject or nullnoproperties: value of the product property that the devices inherit until they set their own, in value. Any value but null counts, {} and [] included.
(body).*.default.valueanyno
(body).*.descriptionstring or nullno
(body).*.device_id_resolverstring or nullno
(body).*.enabledboolean or nullno
(body).*.formobject or nullnoproperties: form used by the console to edit the value (fields).
(body).*.handle_connectivityboolean or nullno
(body).*.namestring or nullno
(body).*.permobject or nullnoproperties: console permissions, as the roles that do not see the property (hidden) or cannot edit it (readOnly); as in device properties.
(body).*.perm.hiddenarray of string or nullnoUnique items
(body).*.perm.readOnlyarray of string or nullnoUnique items
(body).*.requestobject or nullno
(body).*.request.dataobject or null or nullno
(body).*.request.dataobject or nullnoVariant 1: What an API resource request (request.data) or a flow (sink) does. target selects the fields used: topic → topic (+ retain): publish to the device over MQTT; resource → resource: call a device resource (IOTMP devices); resource_stream → resource_stream; property → property: set a device property; function → function: run a function of the product code; endpoint_call → endpoint: call an endpoint; plugin_endpoint → plugin + path; product_stream → product_stream (and optional product): publish to a product stream; none. The body sent is built from payload / payload_type / payload_function. A target needs a device: the one in the URL, the source device, or the one returned by the entry's device_id_resolver.
(body).*.request.data.endpointstring or nullnoVariant 1: target endpoint_call: endpoint id (may use placeholders).
(body).*.request.data.functionstring or nullnoVariant 1:
(body).*.request.data.pathstring or nullnoVariant 1: target plugin_endpoint: path inside the plugin, e.g. /api/process.
(body).*.request.data.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).*.request.data.payload_functionstring or nullnoVariant 1:
(body).*.request.data.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).*.request.data.pluginstring or nullnoVariant 1:
(body).*.request.data.productstring or nullnoVariant 1:
(body).*.request.data.product_streamstring or nullnoVariant 1:
(body).*.request.data.propertystring or nullnoVariant 1:
(body).*.request.data.resourcestring or nullnoVariant 1:
(body).*.request.data.resource_streamstring or nullnoVariant 1:
(body).*.request.data.retainboolean or nullnoVariant 1: target topic: publish as a retained MQTT message.
(body).*.request.data.targetstring or nullnoVariant 1: topic | resource | resource_stream | property | function | endpoint_call | plugin_endpoint | product_stream | none
(body).*.request.data.topicstring or nullnoVariant 1:
(body).*.request.datanullnoVariant 2:
(body).*.responseobject or nullno
(body).*.response.dataobject or null or nullno
(body).*.response.dataobject or nullnoVariant 1: What an API resource answers (response.data). source selects it: request_response: what the request target returned; topic → topic: wait for a message on that MQTT topic (from the same device, or any with publish_source: any); property → property; resource → resource; function → function; endpoint_call → endpoint; none. The answer can be shaped with payload / payload_type / payload_function.
(body).*.response.data.endpointstring or nullnoVariant 1:
(body).*.response.data.functionstring or nullnoVariant 1:
(body).*.response.data.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).*.response.data.payload_functionstring or nullnoVariant 1:
(body).*.response.data.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).*.response.data.propertystring or nullnoVariant 1:
(body).*.response.data.publish_sourcestring or nullnoVariant 1: source topic: empty (only the same device) or any.
(body).*.response.data.resourcestring or nullnoVariant 1:
(body).*.response.data.sourcestring or nullnoVariant 1: request_response | topic | property | resource | function | endpoint_call | none
(body).*.response.data.topicstring or nullnoVariant 1:
(body).*.response.datanullnoVariant 2:
(body).*.retentionobject or nullnobuckets: retention of the bucket when it is created.
(body).*.retention.periodinteger or string or nullno0 = unlimited.
(body).*.retention.unitstring or nullnohours | days | weeks | months | years
(body).*.sinkobject or null or nullno
(body).*.sinkobject or nullnoVariant 1: What an API resource request (request.data) or a flow (sink) does. target selects the fields used: topic → topic (+ retain): publish to the device over MQTT; resource → resource: call a device resource (IOTMP devices); resource_stream → resource_stream; property → property: set a device property; function → function: run a function of the product code; endpoint_call → endpoint: call an endpoint; plugin_endpoint → plugin + path; product_stream → product_stream (and optional product): publish to a product stream; none. The body sent is built from payload / payload_type / payload_function. A target needs a device: the one in the URL, the source device, or the one returned by the entry's device_id_resolver.
(body).*.sink.endpointstring or nullnoVariant 1: target endpoint_call: endpoint id (may use placeholders).
(body).*.sink.functionstring or nullnoVariant 1:
(body).*.sink.pathstring or nullnoVariant 1: target plugin_endpoint: path inside the plugin, e.g. /api/process.
(body).*.sink.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).*.sink.payload_functionstring or nullnoVariant 1:
(body).*.sink.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).*.sink.pluginstring or nullnoVariant 1:
(body).*.sink.productstring or nullnoVariant 1:
(body).*.sink.product_streamstring or nullnoVariant 1:
(body).*.sink.propertystring or nullnoVariant 1:
(body).*.sink.resourcestring or nullnoVariant 1:
(body).*.sink.resource_streamstring or nullnoVariant 1:
(body).*.sink.retainboolean or nullnoVariant 1: target topic: publish as a retained MQTT message.
(body).*.sink.targetstring or nullnoVariant 1: topic | resource | resource_stream | property | function | endpoint_call | plugin_endpoint | product_stream | none
(body).*.sink.topicstring or nullnoVariant 1:
(body).*.sinknullnoVariant 2:
(body).*.split_databoolean or nullno
(body).*.tagsarray or nullnobuckets: record fields stored as tags (filterable), e.g. ["line"].
(body).*.typestring or nullnoproperties: "" or configuration.

Example request: All buckets of the product, one of them per device (PUT …/profile/buckets)

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/YOUR_CATEGORY' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "telemetry": {
    "data": {
      "interval": 60,
      "magnitude": "second",
      "payload_type": "source_payload",
      "resource": "telemetry",
      "source": "resource",
      "update": "interval"
    },
    "description": "One shared bucket, tagged with each device",
    "enabled": true,
    "name": "Telemetry",
    "retention": {
      "period": 6,
      "unit": "months"
    }
  },
  "{{device}}_readings": {
    "data": {
      "payload_type": "source_payload",
      "source": "topic",
      "topic": "plant/{{line}}/{{device}}/{{field}}"
    },
    "enabled": true,
    "name": "Readings",
    "tags": [
      "line"
    ]
  }
}'

Example body: Remove every flow (PUT …/profile/flows)

json
{}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/profile/{category}/{resource} ​

  • Request: GET /v1/users/{user}/products/{product}/profile/{category}/
  • Operation: ReadProductProfile
  • Operation ID: Product_ReadProductProfileResource
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
categorypathstringyes
resourcepathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/YOUR_CATEGORY/YOUR_RESOURCE' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product}/profile/{category}/{resource} ​

  • Request: PUT /v1/users/{user}/products/{product}/profile/{category}/
  • Operation: UpdateProductProfile
  • Operation ID: Product_UpdateProductProfileResource
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Create or replace one entry of a profile category (properties, buckets, flows, api, autoprovisions; endpoints is deprecated). The product is reinitialized, so the change applies at once to its devices.

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
categorypathstringyes
resourcepathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
(body)object or nullnoOne entry of a product profile category; its id is the {resource} path parameter (or the key in a category body). Entries only run when enabled is true. Fields by category. properties: data fills the device property of the same id (optional), default.value (any value but null: {}, [], "", 0 and false count) / form / perm make it a property of the product, which every device of the product inherits (source: product) until it sets its own. buckets: data writes into the bucket with the entry id, created on the first write, outside any project (devices read it through GET /devices/{device}/buckets/{bucket}/data); an id containing {{device}} gives one bucket per device (such ids only fit the whole-category PUT, as the {resource} path parameter cannot hold braces), otherwise one shared bucket tagged with device (and group); tags, backend, retention. flows: data → sink, split_data sends each array element separately. api: resources added to every device of the product: request.data (target), response.data (response), device_id_resolver (function of the product code that returns the device id from the payload, needed to call the resource through POST /products/{product}/resources/{resource}), handle_connectivity (validate / auto-provision the device on calls; default true for resource_stream targets). autoprovisions: config. endpoints: deprecated, use flows with an endpoint_call sink.
(body).backendanynobuckets: storage backend of the bucket when it is created (mongodb, influxdb, dynamodb; default the server's).
(body).configobject or nullnoautoprovisions: when a device that does not exist authenticates or calls a resource and its id matches pattern, it is created in this product (HTTP, or Subdevice for MQTT), with asset type / group and project if given.
(body).config.groupstring or nullnoAsset group for the new devices.
(body).config.modestring or nullnopattern
(body).config.patternstring or nullnoRegular expression on the device id, e.g. ^meter_[0-9]{6}$.
(body).config.projectstring or nullnoProject for the new devices.
(body).config.typestring or nullnoAsset type for the new devices.
(body).dataobject or null or array of object or null or null or nullnoData source, or an array of sources.
(body).dataobject or nullnoVariant 1: Where a properties / buckets / flows entry gets its data. source selects the fields used: topic → topic (MQTT topic, + and # wildcards; {{name}} placeholders match one level, and in buckets each one becomes a tag of the record, with {{field}} naming the record field so several topics merge into one record); resource → resource, update (interval | events) with interval + magnitude; resource_stream → resource_stream (the device pushes it); product_stream → product_stream; event → event with optional filter. Only devices of this product are listened to. The received data can then be transformed with payload_type / payload and payload_function.
(body).data.eventstring or nullnoVariant 1: source event: server event name, e.g. device_state_change, device_property_update, bucket_write.
(body).data.filterobject or nullnoVariant 1: source event: extra filters (event field: value or regex). The product filter is always added.
(body).data.intervalnumber or string or nullnoVariant 1: source resource with update interval: number of magnitude units between reads, e.g. 60.
(body).data.magnitudestring or nullnoVariant 1: second (default) | minute | hour | day | week | month | year
(body).data.patchboolean or nullnoVariant 1: properties only: merge the value into the device property instead of replacing it.
(body).data.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).data.payload_functionstring or nullnoVariant 1: Name of a function of the product code that receives the payload and returns the value to use.
(body).data.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).data.product_streamstring or nullnoVariant 1: source product_stream: stream published by an API resource or flow of this product (target product_stream).
(body).data.resourcestring or nullnoVariant 1: source resource: device resource read by the server.
(body).data.resource_streamstring or nullnoVariant 1: source resource_stream: device resource the device streams on its own.
(body).data.sourcestring or nullnoVariant 1: topic | resource | resource_stream | product_stream | event
(body).data.topicstring or nullnoVariant 1: source topic: MQTT topic of the device messages, e.g. devices/{{device}}/telemetry.
(body).data.updatestring or nullnoVariant 1: source resource: interval (default, read every interval magnitude) | events (the device streams it when it changes).
(body).dataarray of object or null or nullnoVariant 2:
(body).data[].eventstring or nullnoVariant 2: source event: server event name, e.g. device_state_change, device_property_update, bucket_write.
(body).data[].filterobject or nullnoVariant 2: source event: extra filters (event field: value or regex). The product filter is always added.
(body).data[].intervalnumber or string or nullnoVariant 2: source resource with update interval: number of magnitude units between reads, e.g. 60.
(body).data[].magnitudestring or nullnoVariant 2: second (default) | minute | hour | day | week | month | year
(body).data[].patchboolean or nullnoVariant 2: properties only: merge the value into the device property instead of replacing it.
(body).data[].payloadanynoVariant 2: Template string (payload_type template_payload) or JSON value.
(body).data[].payload_functionstring or nullnoVariant 2: Name of a function of the product code that receives the payload and returns the value to use.
(body).data[].payload_typestring or null or nullnoVariant 2: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).data[].product_streamstring or nullnoVariant 2: source product_stream: stream published by an API resource or flow of this product (target product_stream).
(body).data[].resourcestring or nullnoVariant 2: source resource: device resource read by the server.
(body).data[].resource_streamstring or nullnoVariant 2: source resource_stream: device resource the device streams on its own.
(body).data[].sourcestring or nullnoVariant 2: topic | resource | resource_stream | product_stream | event
(body).data[].topicstring or nullnoVariant 2: source topic: MQTT topic of the device messages, e.g. devices/{{device}}/telemetry.
(body).data[].updatestring or nullnoVariant 2: source resource: interval (default, read every interval magnitude) | events (the device streams it when it changes).
(body).datanullnoVariant 3:
(body).defaultobject or nullnoproperties: value of the product property that the devices inherit until they set their own, in value. Any value but null counts, {} and [] included.
(body).default.valueanyno
(body).descriptionstring or nullno
(body).device_id_resolverstring or nullno
(body).enabledboolean or nullno
(body).formobject or nullnoproperties: form used by the console to edit the value (fields).
(body).handle_connectivityboolean or nullno
(body).namestring or nullno
(body).permobject or nullnoproperties: console permissions, as the roles that do not see the property (hidden) or cannot edit it (readOnly); as in device properties.
(body).perm.hiddenarray of string or nullnoUnique items
(body).perm.readOnlyarray of string or nullnoUnique items
(body).requestobject or nullno
(body).request.dataobject or null or nullno
(body).request.dataobject or nullnoVariant 1: What an API resource request (request.data) or a flow (sink) does. target selects the fields used: topic → topic (+ retain): publish to the device over MQTT; resource → resource: call a device resource (IOTMP devices); resource_stream → resource_stream; property → property: set a device property; function → function: run a function of the product code; endpoint_call → endpoint: call an endpoint; plugin_endpoint → plugin + path; product_stream → product_stream (and optional product): publish to a product stream; none. The body sent is built from payload / payload_type / payload_function. A target needs a device: the one in the URL, the source device, or the one returned by the entry's device_id_resolver.
(body).request.data.endpointstring or nullnoVariant 1: target endpoint_call: endpoint id (may use placeholders).
(body).request.data.functionstring or nullnoVariant 1:
(body).request.data.pathstring or nullnoVariant 1: target plugin_endpoint: path inside the plugin, e.g. /api/process.
(body).request.data.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).request.data.payload_functionstring or nullnoVariant 1:
(body).request.data.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).request.data.pluginstring or nullnoVariant 1:
(body).request.data.productstring or nullnoVariant 1:
(body).request.data.product_streamstring or nullnoVariant 1:
(body).request.data.propertystring or nullnoVariant 1:
(body).request.data.resourcestring or nullnoVariant 1:
(body).request.data.resource_streamstring or nullnoVariant 1:
(body).request.data.retainboolean or nullnoVariant 1: target topic: publish as a retained MQTT message.
(body).request.data.targetstring or nullnoVariant 1: topic | resource | resource_stream | property | function | endpoint_call | plugin_endpoint | product_stream | none
(body).request.data.topicstring or nullnoVariant 1:
(body).request.datanullnoVariant 2:
(body).responseobject or nullno
(body).response.dataobject or null or nullno
(body).response.dataobject or nullnoVariant 1: What an API resource answers (response.data). source selects it: request_response: what the request target returned; topic → topic: wait for a message on that MQTT topic (from the same device, or any with publish_source: any); property → property; resource → resource; function → function; endpoint_call → endpoint; none. The answer can be shaped with payload / payload_type / payload_function.
(body).response.data.endpointstring or nullnoVariant 1:
(body).response.data.functionstring or nullnoVariant 1:
(body).response.data.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).response.data.payload_functionstring or nullnoVariant 1:
(body).response.data.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).response.data.propertystring or nullnoVariant 1:
(body).response.data.publish_sourcestring or nullnoVariant 1: source topic: empty (only the same device) or any.
(body).response.data.resourcestring or nullnoVariant 1:
(body).response.data.sourcestring or nullnoVariant 1: request_response | topic | property | resource | function | endpoint_call | none
(body).response.data.topicstring or nullnoVariant 1:
(body).response.datanullnoVariant 2:
(body).retentionobject or nullnobuckets: retention of the bucket when it is created.
(body).retention.periodinteger or string or nullno0 = unlimited.
(body).retention.unitstring or nullnohours | days | weeks | months | years
(body).sinkobject or null or nullno
(body).sinkobject or nullnoVariant 1: What an API resource request (request.data) or a flow (sink) does. target selects the fields used: topic → topic (+ retain): publish to the device over MQTT; resource → resource: call a device resource (IOTMP devices); resource_stream → resource_stream; property → property: set a device property; function → function: run a function of the product code; endpoint_call → endpoint: call an endpoint; plugin_endpoint → plugin + path; product_stream → product_stream (and optional product): publish to a product stream; none. The body sent is built from payload / payload_type / payload_function. A target needs a device: the one in the URL, the source device, or the one returned by the entry's device_id_resolver.
(body).sink.endpointstring or nullnoVariant 1: target endpoint_call: endpoint id (may use placeholders).
(body).sink.functionstring or nullnoVariant 1:
(body).sink.pathstring or nullnoVariant 1: target plugin_endpoint: path inside the plugin, e.g. /api/process.
(body).sink.payloadanynoVariant 1: Template string (payload_type template_payload) or JSON value.
(body).sink.payload_functionstring or nullnoVariant 1:
(body).sink.payload_typestring or null or nullnoVariant 1: How the payload is built. template_payload (default): payload is a template that may use {{payload}}, {{payload.field}}, {{device}}, {{property.<name>}}, {{api.<resource>}} or {{meta.<device field>}}; without payload it yields nothing, so a properties or buckets entry writes nothing. source_payload: the data as received (the same as payload "{{payload}}"). source_event: the whole event (device, product, timestamps, payload…). none: no payload.
(body).sink.pluginstring or nullnoVariant 1:
(body).sink.productstring or nullnoVariant 1:
(body).sink.product_streamstring or nullnoVariant 1:
(body).sink.propertystring or nullnoVariant 1:
(body).sink.resourcestring or nullnoVariant 1:
(body).sink.resource_streamstring or nullnoVariant 1:
(body).sink.retainboolean or nullnoVariant 1: target topic: publish as a retained MQTT message.
(body).sink.targetstring or nullnoVariant 1: topic | resource | resource_stream | property | function | endpoint_call | plugin_endpoint | product_stream | none
(body).sink.topicstring or nullnoVariant 1:
(body).sinknullnoVariant 2:
(body).split_databoolean or nullno
(body).tagsarray or nullnobuckets: record fields stored as tags (filterable), e.g. ["line"].
(body).typestring or nullnoproperties: "" or configuration.

Example request: API resource that calls an endpoint (PUT …/profile/api/notify)

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/YOUR_CATEGORY/YOUR_RESOURCE' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "description": "Sends a notification from the device",
  "enabled": true,
  "name": "Notify",
  "request": {
    "data": {
      "endpoint": "notify_email",
      "payload": "{\"device\": \"{{device}}\", \"message\": \"{{payload.message}}\"}",
      "payload_type": "template_payload",
      "target": "endpoint_call"
    }
  },
  "response": {
    "data": {
      "source": "request_response"
    }
  }
}'

Example body: API resource to configure a device by serial, with device_id_resolver (PUT …/profile/api/configure)

json
{
  "device_id_resolver": "resolveDevice",
  "enabled": true,
  "name": "Configure",
  "request": {
    "data": {
      "payload": "{{payload.settings}}",
      "property": "settings",
      "target": "property"
    }
  },
  "response": {
    "data": {
      "source": "request_response"
    }
  }
}

Example body: Autoprovision devices by id pattern (PUT …/profile/autoprovisions/meters)

json
{
  "config": {
    "group": "plant_a",
    "mode": "pattern",
    "pattern": "^meter_[0-9]{6}$",
    "type": "meter"
  },
  "description": "Creates meter_XXXXXX devices on their first connection",
  "enabled": true,
  "name": "Meters"
}

Example body: Bucket fed from a device resource every 60 s (PUT …/profile/buckets/telemetry)

json
{
  "data": {
    "interval": 60,
    "magnitude": "second",
    "payload_type": "source_payload",
    "resource": "telemetry",
    "source": "resource",
    "update": "interval"
  },
  "description": "One shared bucket, tagged with each device",
  "enabled": true,
  "name": "Telemetry",
  "retention": {
    "period": 6,
    "unit": "months"
  }
}

Example body: Bucket from MQTT topics with tags (PUT …/profile/buckets/readings)

json
{
  "data": {
    "payload_type": "source_payload",
    "source": "topic",
    "topic": "plant/{{line}}/{{device}}/{{field}}"
  },
  "enabled": true,
  "name": "Readings",
  "tags": [
    "line"
  ]
}

Example body: Configuration property with a default (PUT …/profile/properties/settings)

json
{
  "default": {
    "value": {
      "report_interval": 60,
      "threshold": 25.5
    }
  },
  "enabled": true,
  "name": "Settings",
  "perm": {
    "hidden": [],
    "readOnly": [
      "member"
    ]
  },
  "type": "configuration"
}

Example body: Flow: email when a device disconnects (PUT …/profile/flows/offline_alert)

json
{
  "data": {
    "event": "device_state_change",
    "filter": {
      "state": "disconnected"
    },
    "payload_type": "source_event",
    "source": "event"
  },
  "enabled": true,
  "name": "Offline alert",
  "sink": {
    "endpoint": "notify_email",
    "payload": "{\"text\": \"{{device}} is offline\"}",
    "target": "endpoint_call"
  }
}

Example body: Property set from an MQTT topic (PUT …/profile/properties/status)

json
{
  "data": {
    "payload_type": "source_payload",
    "source": "topic",
    "topic": "devices/{{device}}/status"
  },
  "default": {
    "value": {
      "state": "unknown"
    }
  },
  "description": "Last status message",
  "enabled": true,
  "name": "Status"
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

DELETE /v1/users/{user}/products/{product}/profile/{category}/{resource} ​

  • Request: DELETE /v1/users/{user}/products/{product}/profile/{category}/
  • Operation: UpdateProductProfile
  • Operation ID: Product_DeleteProductProfileResource
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
categorypathstringyes
resourcepathstringyes

Example request

bash
curl -X DELETE 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/profile/YOUR_CATEGORY/YOUR_RESOURCE' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product}/projects ​

  • Request: PUT /v1/users/{user}/products/{product}/projects
  • Operation: UpdateProductProjects
  • Operation ID: Product_UpdateProjects
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
(body)array of stringnoProjects the resource belongs to, as <owner>@<project> ids. Replaces the whole list: read the current one first to add or remove a single project; [] removes it from every project.

Example request: No projects

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/projects' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '[]'

Example body: One project

json
[
  "YOUR_USER@greenhouse"
]

Example body: Two projects

json
[
  "YOUR_USER@greenhouse",
  "YOUR_USER@maintenance"
]

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/properties ​

  • Request: GET /v1/users/{user}/products/{product}/properties
  • Operation: ListProductProperties
  • Operation ID: Product_ListProperties
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

Response example (200)

json
[
  {
    "created": 1792263090737,
    "description": "Sampling and alert thresholds",
    "modified": 1792263090737,
    "name": "Settings",
    "property": "settings",
    "type": "configuration",
    "value": {
      "alerts": true,
      "interval": 60,
      "max_temperature": 28.5
    }
  },
  {
    "created": 1792263090737,
    "modified": 1792263090737,
    "name": "Location",
    "property": "location",
    "value": {
      "lat": 40.4168,
      "lon": -3.7038
    }
  },
  {
    "created": 1792263090737,
    "modified": 1792263090737,
    "name": "Calibration",
    "perm": {
      "readOnly": [
        "member"
      ]
    },
    "property": "calibration",
    "value": {
      "gain": 1.02,
      "offset": -0.4
    }
  },
  {
    "created": 1792263090737,
    "modified": 1792263090737,
    "name": "Dashboard",
    "property": "dashboard",
    "value": {
      "source": "url",
      "url": "/v1/users/YOUR_USER/storages/fleet_app/files/"
    }
  }
]

POST /v1/users/{user}/products/{product}/properties ​

  • Request: POST /v1/users/{user}/products/{product}/properties
  • Operation: CreateProductProperty
  • Operation ID: Product_CreateProperty
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Request body (application/json, required)

The body matches one of these 2 variants.

Variant 1

FieldTypeRequiredConstraintsDescription
(body)array of objectno
(body)[].descriptionstringnoMaximum length: 255A brief description of the resource, providing context or additional information, limited to 255 characters.
(body)[].formobjectno
(body)[].form.fieldsanyyes
(body)[].namestringnoMaximum length: 255The name of the resource, limited to 255 characters. It can include any character.
(body)[].permobjectno
(body)[].perm.hiddenarray of stringnoUnique items
(body)[].perm.readOnlyarray of stringnoUnique items
(body)[].propertystringyesPattern: ^[a-zA-Z0-9_-]{1,32}$A unique identifier for resources, consisting of alphanumeric characters, underscores, or hyphens, and limited to 32 characters.
(body)[].typestringnoOne of: ``, configuration
(body)[].valueanyyes

Variant 2: Property Create. Schema for creating a property

Schema for creating a property

FieldTypeRequiredConstraintsDescription
descriptionstringnoMaximum length: 255A brief description of the resource, providing context or additional information, limited to 255 characters.
formobjectno
form.fieldsanyyes
namestringnoMaximum length: 255The name of the resource, limited to 255 characters. It can include any character.
permobjectno
perm.hiddenarray of stringnoUnique items
perm.readOnlyarray of stringnoUnique items
propertystringyesPattern: ^[a-zA-Z0-9_-]{1,32}$A unique identifier for resources, consisting of alphanumeric characters, underscores, or hyphens, and limited to 32 characters.
typestringnoOne of: ``, configuration
valueanyyes

Example request: Configuration value

bash
curl -X POST 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "description": "Sampling and alert thresholds",
  "name": "Settings",
  "property": "settings",
  "type": "configuration",
  "value": {
    "alerts": true,
    "interval": 60,
    "max_temperature": 28.5
  }
}'

Example body: Location

json
{
  "name": "Location",
  "property": "location",
  "value": {
    "lat": 40.4168,
    "lon": -3.7038
  }
}

Example body: Read-only for project members

json
{
  "name": "Calibration",
  "perm": {
    "readOnly": [
      "member"
    ]
  },
  "property": "calibration",
  "value": {
    "gain": 1.02,
    "offset": -0.4
  }
}

Example body: Url dashboard of the resource

json
{
  "name": "Dashboard",
  "property": "dashboard",
  "value": {
    "source": "url",
    "url": "/v1/users/YOUR_USER/storages/fleet_app/files/"
  }
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/properties/{property} ​

  • Request: GET /v1/users/{user}/products/{product}/properties/
  • Operation: ReadProductProperty
  • Operation ID: Product_ReadProperty
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
propertypathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties/YOUR_PROPERTY' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product}/properties/{property} ​

  • Request: PUT /v1/users/{user}/products/{product}/properties/
  • Operation: UpdateProductProperty
  • Operation ID: Product_UpdateProperty
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
propertypathstringyes

Request body (application/json, required)

Schema for updating a property

FieldTypeRequiredConstraintsDescription
descriptionstringnoMaximum length: 255A brief description of the resource, providing context or additional information, limited to 255 characters.
formobjectno
form.fieldsanyyes
namestringnoMaximum length: 255The name of the resource, limited to 255 characters. It can include any character.
permobjectno
perm.hiddenarray of stringnoUnique items
perm.readOnlyarray of stringnoUnique items
propertystringnoPattern: ^[a-zA-Z0-9_-]{1,32}$A unique identifier for resources, consisting of alphanumeric characters, underscores, or hyphens, and limited to 32 characters.
typestringnoOne of: ``, configuration
valueanyyes

Example request: Hide from project members

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties/YOUR_PROPERTY' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "perm": {
    "hidden": [
      "member"
    ]
  },
  "value": "internal note"
}'

Example body: Replace the value

json
{
  "value": {
    "alerts": true,
    "interval": 30,
    "max_temperature": 27
  }
}

Example body: Value, name and description

json
{
  "description": "Faster sampling during commissioning",
  "name": "Settings",
  "value": {
    "alerts": false,
    "interval": 10,
    "max_temperature": 28.5
  }
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PATCH /v1/users/{user}/products/{product}/properties/{property} ​

  • Request: PATCH /v1/users/{user}/products/{product}/properties/
  • Operation: UpdateProductProperty
  • Operation ID: Product_PatchProperty
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
propertypathstringyes

Request body (application/json, required)

The body matches one of these 2 variants.

Variant 1

FieldTypeRequiredConstraintsDescription
valueanyyes

Variant 2

FieldTypeRequiredConstraintsDescription
*anyno

Example request: Change some fields of the value

bash
curl -X PATCH 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties/YOUR_PROPERTY' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "value": {
    "interval": 30
  }
}'

Example body: Flattened fields

json
{
  "value.alerts": false,
  "value.max_temperature": 27
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

DELETE /v1/users/{user}/products/{product}/properties/{property} ​

  • Request: DELETE /v1/users/{user}/products/{product}/properties/
  • Operation: DeleteProductProperty
  • Operation ID: Product_DeleteProperty
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
propertypathstringyes

Example request

bash
curl -X DELETE 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties/YOUR_PROPERTY' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/properties/{property}/clone ​

  • Request: GET /v1/users/{user}/products/{product}/properties/{property}/clone
  • Operation: CloneProductPropertyConfig
  • Operation ID: Product_ClonePropertyConfig
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
propertypathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties/YOUR_PROPERTY/clone' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

POST /v1/users/{user}/products/{product}/properties/{property}/clone ​

  • Request: POST /v1/users/{user}/products/{product}/properties/{property}/clone
  • Operation: CloneProductProperty
  • Operation ID: Product_CloneProperty
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
propertypathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
descriptionstringnoMaximum length: 255A brief description of the resource, providing context or additional information, limited to 255 characters.
enabledbooleanno
namestringnoMaximum length: 255The name of the resource, limited to 255 characters. It can include any character.
propertystringyesPattern: ^[a-zA-Z0-9_-]{1,32}$A unique identifier for resources, consisting of alphanumeric characters, underscores, or hyphens, and limited to 32 characters.

Example request: Copy with a new id

bash
curl -X POST 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/properties/YOUR_PROPERTY/clone' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "property": "copy_of_property"
}'

Example body: Copy with name and description

json
{
  "description": "Same configuration as the original, for production line 2",
  "name": "Line 2 copy",
  "property": "line_2_property"
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

POST /v1/users/{user}/products/{product}/resources/{resource} ​

  • Request: POST /v1/users/{user}/products/{product}/resources/
  • Operation: AccessProductResources
  • Operation ID: Product_AccessResources
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Call an API resource of the product (profile api) without naming a device. The body is free (any JSON, or an array to call it once per element) and is the {{payload}} of the resource. A device is only reached when the resource defines device_id_resolver, a product code function that returns the device id from the payload.

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
resourcepathstringyes

Request body (application/json, required)

A JSON object.

Example request (skeleton generated from the schema: required fields only, neutral values)

bash
curl -X POST 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/resources/YOUR_RESOURCE' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{}'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/services ​

  • Request: GET /v1/users/{user}/products/{product}/services
  • Operation: ReadProductServices
  • Operation ID: Product_ReadServices
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/services' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

GET /v1/users/{user}/products/{product}/services/{service} ​

  • Request: GET /v1/users/{user}/products/{product}/services/
  • Operation: ReadProductServices
  • Operation ID: Product_ReadServices
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
servicepathstringyes

Example request

bash
curl 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/services/YOUR_SERVICE' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden

PUT /v1/users/{user}/products/{product}/services/{service} ​

  • Request: PUT /v1/users/{user}/products/{product}/services/
  • Operation: UpdateProductServices
  • Operation ID: Product_UpdateServices
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
servicepathstringyes

Request body (application/json, required)

FieldTypeRequiredConstraintsDescription
(body)object or nullnoA service the devices of the product expose, reached through the server: web (HTTP proxy) or vnc (remote desktop). The target is the address and port as seen from the device.
(body).descriptionstring or nullno
(body).enabledboolean or nullno
(body).namestring or nullno
(body).securityobject or nullno
(body).security.ip_filteringboolean or nullno
(body).security.timeout_minutesnumber or nullno
(body).targetobject or nullno
(body).target.addressstring or nullnoe.g. 127.0.0.1
(body).target.portinteger or string or nullnoe.g. 8080
(body).target.secureboolean or nullnoThe target uses TLS.
(body).typestring or nullnoweb (default) | vnc
(body).vncobject or nullno
(body).vnc.compressionnumber or nullno
(body).vnc.qualitynumber or nullno
(body).vnc.scaleboolean or nullno
(body).vnc.sharedboolean or nullno
(body).vnc.viewonlyboolean or nullno

Example request: Remote desktop (PUT …/services/desktop)

bash
curl -X PUT 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/services/YOUR_SERVICE' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{
  "enabled": true,
  "name": "Desktop",
  "target": {
    "address": "127.0.0.1",
    "port": 5900
  },
  "type": "vnc",
  "vnc": {
    "compression": 2,
    "quality": 6,
    "scale": true,
    "shared": true,
    "viewonly": false
  }
}'

Example body: Web interface of the device (PUT …/services/web_ui)

json
{
  "description": "Device configuration page",
  "enabled": true,
  "name": "Web UI",
  "security": {
    "ip_filtering": false,
    "timeout_minutes": 60
  },
  "target": {
    "address": "127.0.0.1",
    "port": 8080,
    "secure": false
  },
  "type": "web"
}

Responses

StatusDescription
200ok
401unauthorized
403forbidden

DELETE /v1/users/{user}/products/{product}/services/{service} ​

  • Request: DELETE /v1/users/{user}/products/{product}/services/
  • Operation: DeleteProductServices
  • Operation ID: Product_DeleteServices
  • Authentication: access token, Authorization: Bearer YOUR_TOKEN

Parameters

NameInTypeRequiredDescription
userpathstringyes
productpathstringyes
servicepathstringyes

Example request

bash
curl -X DELETE 'https://YOUR_SERVER/v1/users/YOUR_USER/products/YOUR_PRODUCT/services/YOUR_SERVICE' \
  -H 'Authorization: Bearer YOUR_TOKEN'

Responses

StatusDescription
200ok
401unauthorized
403forbidden