Devices
List projects for device assignment
List projects for device assignment using Ovok’s Slim API.
| Method | Path |
|---|---|
GET | /v1/slim/device/assign/project |
Authentication · Access policies
Lists the projects you can move a device into: your own project, its parent project and its sub-projects.
Auth: bearer token. The caller must be a practitioner, an admin or a System Owner, and needs Device:update.
Scope: the caller's project (from the token) and its parent and sub-projects.
Request
No parameters.
Behaviour
- Each entry is
{ project: { id, name } }.nameis an empty string when the project has none. totalis the number of projects returned.- Read-only.
Example
curl -X GET 'https://api.sandbox.ovok.com/v1/slim/device/assign/project' \
-H "Authorization: Bearer ${OVOK_TOKEN}"Successful response
200 — Projects a device can be moved into.
{
"total": 2,
"resources": [
{ "project": { "id": "b7a3d915-6e20-4c8f-9a14-3d5f7b9c1e68", "name": "Example project" } },
{ "project": { "id": "c6e2a4f8-0b3d-4719-a5c7-9e1f3b5d7a20", "name": "Parent project" } }
]
}| Field | Type | Description |
|---|---|---|
total | integer | Number of projects returned. |
resources | object[] | Your project, its parent project and its sub-projects. |
resources[].project | object | One project. |
resources[].project.id | string (uuid) | Project id. |
resources[].project.name | string | Project name. Empty string when the project has none. |
Errors
Last updated on