Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow templates usage for deviceregistration register command #430

Closed
reubenmiller opened this issue Feb 10, 2025 · 0 comments · Fixed by #433
Closed

Allow templates usage for deviceregistration register command #430

reubenmiller opened this issue Feb 10, 2025 · 0 comments · Fixed by #433

Comments

@reubenmiller
Copy link
Owner

reubenmiller commented Feb 10, 2025

The following should be possible:

Piping a specific group (using filtering etc.), then register a manually given device id (external id):

c8y devicegroups list -p 1 | c8y deviceregistration register --id mytestdevice --template "{groupId: input.value.id}" --dry

But ideally the new Cumulocity groupId (see reference) should be supported.

c8y deviceregistration register --id mytestdevice --group

Workaround

c8y devicegroups list -p 1 \
| c8y api POST /devicecontrol/newDeviceRequests \
    --template '{id: "foo", groupId:input.value.id, type: "mytype"}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant