Skip to content

Error updating a command to a device self-registered by a group #612

@JuanCarlosSecmotic

Description

@JuanCarlosSecmotic

I am trying to be able to receive a command when sending data, everything works fine when I create a device, but when the device is self-registered by a device group this command fails.

Create device group

Post -> http://localhost:4041/iot/services
{ "services": [ { "resource": "/iot/d", "apikey": "801230BJKL23Y9090DSFL123HJK09H324HV8732", "type": "Light", "polling": true, "attributes": [ { "object_id": "c", "name": "count", "type": "Integer" } ], "commands": [ { "name": "ring", "type": "command" } ] } ] }

I generate the device
Post -> http://localhost:7896/iot/d?i=motion1&k=801230BJKL23Y9090DSFL123HJK09H324HV8732
c|3323

then I update the command through the iot
Post -> http://localhost:4041/v2/op/update
{ "actionType": "update", "entities": [ { "type": "Light", "id": "Light:motion1", "polling": true, "ring" : { "type": "command", "value": "44423" } } ] }

it responds 204 but in orion the error has already been logged.

ring_info has this value -> There was an error in the response of a device to a command []:RequestError: Missing url property

I have been testing, the autogenerated device does not have the attribute called polling in the IoT database, if I edit it manually and add it as true, the command works

UPDATE (compose file + config + postman collection added)
environment.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions