IotHub
  1. Device Class
IotHub
  • API
    • TALQ
      • Device Class
        • Create a Talq Device Class
          POST
        • Update Talq Device Class
          PUT
        • Delete a Talq Device Class
          DELETE
        • Update a Talq Device Class
          PUT
      • Device
        • Create a Talq Device
        • List Talq Devices
        • Modify a Talq Device
        • Update Talq Devices
        • Delete a Talq Device
        • Get a Talq Device
        • Modify a Talq Device patch
        • Update a Talq Device
        • Get a Talq Device Function
        • Get a Talq Device Attribute
      • Group
        • List Talq Groups
        • Get a Talq Group
      • Create a Talq Service
        POST
  • Docs TALQ
    • Visão Geral do Projeto
    • Processo de Inicialização - Bootstrap Process
    • API TALQ
    • API GUIA
    • Tratamento de Erros
    • Configurações da instância
    • Agendamentos
    • Configuração de logger
    • Gerenciamento de grupos
    • Alertas, Configurações de Alertas e Medições
  1. Device Class

Create a Talq Device Class

POST
/talq/device-classes
TALQ[TALQ] device-classesNouvenn
Announce all device classes supported by the gateway and still not announced

Request

Body Params application/json
array of:
name
string 
required
The name of the device class
<= 50 characters
functions
array[object (TalqFunctionDescDto) {5}] 
required
Supported functions of the device class
functionId
string 
required
The unique identifier of the FunctionDesc. The 'id' field of a Function described by this FunctionDesc will match this 'functionId' value. e.g. 'BasicFunction02'.
<= 50 characters
Example:
BasicFunction02
type
enum<string> 
required
The TALQ function type (e.g. 'BasicFunction', 'LampActuatorFunction')
Allowed values:
BasicFunctionGatewayFunctionCommunicationFunctionTimeFunctionSimpleActuatorFunctionGenericActuatorFunctionLampActuatorFunctionLampMonitorFunctionElectricalMeterFunctionPhotocellFunctionLightSensorFunctionBinarySensorFunctionGenericSensorFunctionTemperatureSensorFunctionHumiditySensorFunctionParticulateMatterSensorFunctionPresenceSensorFunctionMovementSensorFunctionLocationSensorFunctionAccelerometerFunctionOrientationFunctionBatteryLevelSensorFunctionFillingLevelSensorFunctionSolarBatteryChargerFunctionBatteryManagementSystemFunctionTrafficCounterFunctionFluidLevelSensorFunctionWasteContainerFunctionWeightSensorFunctionGasSensorFunctionSegmentMonitorFunctionNoiseMonitoringSensorFunctionAtmosphericSensorFunctionWindSensorFunctionPrecipitationSensorFunctionSkySensorFunctionGullySensorFunctionWaterFlowSensorFunctionWaterQualitySensorFunctionTextDisplayActuatorFunctionParkingSensorFunctionParkingCameraSensorFunctionLuminaireAssetFunctionDriverAssetFunctionControllerAssetFunctionCabinetConfigurationFunctionCabinetMonitorFunction
Example:
BasicFunction
vendorAttributes
array[object (AttributeDto) {13}] 
optional
The list of vendor attributes available in the function.
attributes
array[object (TalqAttributeDescDto) {10}] 
optional
The list of all attributes of the referred TALQ function that are available in this function. All attributes used by the end point shall be announced, whether they are optional or mandatory.
events
array[object (IotEventDto) {5}] 
optional
The list of events of the referred TALQ function that are available in this function.
Example
[
    {
        "name": "string",
        "functions": [
            {
                "functionId": "BasicFunction02",
                "type": "BasicFunction",
                "vendorAttributes": [
                    {
                        "name": "string",
                        "description": "string",
                        "minValue": 0,
                        "maxValue": 0,
                        "regex": "string",
                        "readOnly": true,
                        "enumValues": [
                            "string"
                        ],
                        "unit": "string",
                        "vendorUuid": "string",
                        "scope": "measurement",
                        "type": "AttributeBinary",
                        "commands": {},
                        "types": {}
                    }
                ],
                "attributes": [
                    {
                        "name": "string",
                        "description": "string",
                        "minValue": 0,
                        "maxValue": 0,
                        "regEx": "string",
                        "readOnly": true,
                        "enumValues": [
                            "string"
                        ],
                        "unit": "string",
                        "commands": {
                            "scope": "default",
                            "attributes": "reason",
                            "states": {},
                            "levels": {}
                        },
                        "types": {
                            "address": "string",
                            "name": "LuminaireType",
                            "properties": [
                                {
                                    "name": "string",
                                    "description": "string",
                                    "minValue": 0,
                                    "maxValue": 0,
                                    "regEx": "string",
                                    "readOnly": true,
                                    "enumValues": [
                                        "string"
                                    ],
                                    "unit": "string"
                                }
                            ]
                        }
                    }
                ],
                "events": [
                    {
                        "name": "string",
                        "description": "string",
                        "uuid": "string",
                        "functionUuid": "string",
                        "type": "string"
                    }
                ]
            }
        ]
    }
]

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://iot.exati.com.br/talq/device-classes' \
--header 'Content-Type: application/json' \
--data-raw '[
    {
        "name": "string",
        "functions": [
            {
                "functionId": "BasicFunction02",
                "type": "BasicFunction",
                "vendorAttributes": [
                    {
                        "name": "string",
                        "description": "string",
                        "minValue": 0,
                        "maxValue": 0,
                        "regex": "string",
                        "readOnly": true,
                        "enumValues": [
                            "string"
                        ],
                        "unit": "string",
                        "vendorUuid": "string",
                        "scope": "measurement",
                        "type": "AttributeBinary",
                        "commands": {},
                        "types": {}
                    }
                ],
                "attributes": [
                    {
                        "name": "string",
                        "description": "string",
                        "minValue": 0,
                        "maxValue": 0,
                        "regEx": "string",
                        "readOnly": true,
                        "enumValues": [
                            "string"
                        ],
                        "unit": "string",
                        "commands": {
                            "scope": "default",
                            "attributes": "reason",
                            "states": {},
                            "levels": {}
                        },
                        "types": {
                            "address": "string",
                            "name": "LuminaireType",
                            "properties": [
                                {
                                    "name": "string",
                                    "description": "string",
                                    "minValue": 0,
                                    "maxValue": 0,
                                    "regEx": "string",
                                    "readOnly": true,
                                    "enumValues": [
                                        "string"
                                    ],
                                    "unit": "string"
                                }
                            ]
                        }
                    }
                ],
                "events": [
                    {
                        "name": "string",
                        "description": "string",
                        "uuid": "string",
                        "functionUuid": "string",
                        "type": "string"
                    }
                ]
            }
        ]
    }
]'

Responses

🟢201Created
application/json
The list of device classes that has been received
Body
array of:
name
string 
required
The name of the device class
<= 50 characters
functions
array[object (TalqFunctionDescDto) {5}] 
required
Supported functions of the device class
functionId
string 
required
The unique identifier of the FunctionDesc. The 'id' field of a Function described by this FunctionDesc will match this 'functionId' value. e.g. 'BasicFunction02'.
<= 50 characters
Example:
BasicFunction02
type
enum<string> 
required
The TALQ function type (e.g. 'BasicFunction', 'LampActuatorFunction')
Allowed values:
BasicFunctionGatewayFunctionCommunicationFunctionTimeFunctionSimpleActuatorFunctionGenericActuatorFunctionLampActuatorFunctionLampMonitorFunctionElectricalMeterFunctionPhotocellFunctionLightSensorFunctionBinarySensorFunctionGenericSensorFunctionTemperatureSensorFunctionHumiditySensorFunctionParticulateMatterSensorFunctionPresenceSensorFunctionMovementSensorFunctionLocationSensorFunctionAccelerometerFunctionOrientationFunctionBatteryLevelSensorFunctionFillingLevelSensorFunctionSolarBatteryChargerFunctionBatteryManagementSystemFunctionTrafficCounterFunctionFluidLevelSensorFunctionWasteContainerFunctionWeightSensorFunctionGasSensorFunctionSegmentMonitorFunctionNoiseMonitoringSensorFunctionAtmosphericSensorFunctionWindSensorFunctionPrecipitationSensorFunctionSkySensorFunctionGullySensorFunctionWaterFlowSensorFunctionWaterQualitySensorFunctionTextDisplayActuatorFunctionParkingSensorFunctionParkingCameraSensorFunctionLuminaireAssetFunctionDriverAssetFunctionControllerAssetFunctionCabinetConfigurationFunctionCabinetMonitorFunction
Example:
BasicFunction
vendorAttributes
array[object (AttributeDto) {13}] 
optional
The list of vendor attributes available in the function.
attributes
array[object (TalqAttributeDescDto) {10}] 
optional
The list of all attributes of the referred TALQ function that are available in this function. All attributes used by the end point shall be announced, whether they are optional or mandatory.
events
array[object (IotEventDto) {5}] 
optional
The list of events of the referred TALQ function that are available in this function.
Example
[
    {
        "name": "string",
        "functions": [
            {
                "functionId": "BasicFunction02",
                "type": "BasicFunction",
                "vendorAttributes": [
                    {
                        "name": "string",
                        "description": "string",
                        "minValue": 0,
                        "maxValue": 0,
                        "regex": "string",
                        "readOnly": true,
                        "enumValues": [
                            "string"
                        ],
                        "unit": "string",
                        "vendorUuid": "string",
                        "scope": "measurement",
                        "type": "AttributeBinary",
                        "commands": {},
                        "types": {}
                    }
                ],
                "attributes": [
                    {
                        "name": "string",
                        "description": "string",
                        "minValue": 0,
                        "maxValue": 0,
                        "regEx": "string",
                        "readOnly": true,
                        "enumValues": [
                            "string"
                        ],
                        "unit": "string",
                        "commands": {
                            "scope": "default",
                            "attributes": "reason",
                            "states": {},
                            "levels": {}
                        },
                        "types": {
                            "address": "string",
                            "name": "LuminaireType",
                            "properties": [
                                {
                                    "name": "string",
                                    "description": "string",
                                    "minValue": 0,
                                    "maxValue": 0,
                                    "regEx": "string",
                                    "readOnly": true,
                                    "enumValues": [
                                        "string"
                                    ],
                                    "unit": "string"
                                }
                            ]
                        }
                    }
                ],
                "events": [
                    {
                        "name": "string",
                        "description": "string",
                        "uuid": "string",
                        "functionUuid": "string",
                        "type": "string"
                    }
                ]
            }
        ]
    }
]
🟠400Bad Request
🟠403Forbidden
🟠404Record Not Found
🟠409409
🟠422Parameter Error
Modified at 2025-03-14 11:12:57
Next
Update Talq Device Class