mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
36 lines
545 B
Markdown
36 lines
545 B
Markdown
|
source: API/DeviceGroups.md
|
||
|
|
||
|
### `get_devicegroups`
|
||
|
|
||
|
List all device groups.
|
||
|
|
||
|
Route: `/api/v0/devicegroups`
|
||
|
|
||
|
Input (JSON):
|
||
|
|
||
|
-
|
||
|
|
||
|
Examples:
|
||
|
```curl
|
||
|
curl -H 'X-Auth-Token: YOURAPITOKENHERE' https://librenms.org/api/v0/devicegroups
|
||
|
```
|
||
|
|
||
|
Output:
|
||
|
```json
|
||
|
[
|
||
|
{
|
||
|
"status": "ok",
|
||
|
"message": "Found 1 device groups",
|
||
|
"count": 1,
|
||
|
"groups": [
|
||
|
{
|
||
|
"id": "1",
|
||
|
"name": "Testing",
|
||
|
"desc": "Testing",
|
||
|
"pattern": "%devices.status = \"1\" &&"
|
||
|
}
|
||
|
]
|
||
|
}
|
||
|
]
|
||
|
```
|