Skip to content

Commit

Permalink
API/Resources: Add examples for device pinning by UUID
Browse files Browse the repository at this point in the history
Change-type: minor
  • Loading branch information
thgreasi committed Sep 19, 2023
1 parent 64ffbcb commit 90470f1
Showing 1 changed file with 27 additions and 18 deletions.
45 changes: 27 additions & 18 deletions config/dictionaries/resource.json
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,33 @@
"endpoint": "/v6/device(<ID>)",
"filters": "?\\$select=overall_status"
},
{
"id": "get-target-release",
"summary": "Get the release device is pinned to",
"description": "Note: should_be_running__release will be unset or null if the device isn't pinned to any release. For an unpinned device, the device.is_running__release field may be used to obtain the device's current state.",
"method": "GET",
"endpoint": "/v6/device(<ID>)",
"filters": "?\\$select=should_be_running__release",
"data": ""
},
{
"id": "set-device-to-release-by-id",
"summary": "Pin device to a specific release by ID",
"description": "",
"method": "PATCH",
"endpoint": "/v6/device(<ID>)",
"filters": "",
"data": "{\n \"should_be_running__release\": \"<RELEASE ID>\"\n}"
},
{
"id": "set-device-to-release-by-uuid",
"summary": "Pin device to a specific release by UUID",
"description": "",
"method": "PATCH",
"endpoint": "/v6/device(uuid='<UUID>')",
"filters": "",
"data": "{\n \"should_be_running__release\": \"<RELEASE ID>\"\n}"
},
{
"id": "rename-device",
"summary": "Rename device",
Expand Down Expand Up @@ -359,24 +386,6 @@
"filters": "",
"data": "{\n \"belongs_to__application\": \"<FLEET ID>\"\n}"
},
{
"id": "get-target-release",
"summary": "Get the release device is pinned to",
"description": "Note: should_be_running__release will be unset or null if the device isn't pinned to any release. For an unpinned device, the device.is_running__release field may be used to obtain the device's current state.",
"method": "GET",
"endpoint": "/v6/device(<ID>)",
"filters": "?\\$select=should_be_running__release",
"data": ""
},
{
"id": "set-device-to-release",
"summary": "Pin device to a specific release",
"description": "",
"method": "PATCH",
"endpoint": "/v6/device(<ID>)",
"filters": "",
"data": "{\n \"should_be_running__release\": \"<RELEASE ID>\"\n}"
},
{
"id": "deactivate-device",
"summary": "Deactivate an offline device (CHARGEABLE)",
Expand Down

0 comments on commit 90470f1

Please sign in to comment.