This endpoints retrieves a specific Device Group.
Request
To retrieve a single Device Group please make a GET request to the following URL:
| HTTP Method | URL |
|---|---|
| GET | https://industrial.api.ubidots.com/api/v2.0/device_groups/<device_group_key>/ |
Path Parameters
| Parameter | Type | Description |
|---|---|---|
| device_group_key | String | The id or label of the Device Group, label should use the prefix ~ |
Header
| Parameter | Required? | Description |
|---|---|---|
| X-Auth-Header | Yes | Authentication Token of account |
$ curl -X GET 'https://industrial.api.ubidots.com/api/v2.0/device_groups/<device_group_key>' \
-H 'X-Auth-Token: oaXBo6ODhIjPsusNRPUGIK4d72bc73'{
"url": "https://industrial.api.ubidots.com/api/v2.0/device_groups/5e1c8daf89f9bd33017e05e9",
"id": "5e1c8daf89f9bd33017e05e9",
"label": "group-test",
"name": "Group Test",
"organization": null,
"devices": "https://industrial.api.ubidots.com/api/v2.0/device_groups/5e1c8daf89f9bd33017e05e9/devices",
"devicesNumber": 1,
"createdAt": "2020-01-13T15:33:03.655965Z"
}{
"code": 400001,
"message": "Validation Error.",
"detail": {
....
}
}{
"code": 401001,
"message": "Authentication credentials were not provided.",
"detail": "Authentication credentials were not provided."
}Response
Returns a Device Group object with the requested Device Group.
