...
Examples of how to use the request modifiers can be found in the response blocks below. In general, the queries will look something like this:
GET of opcharts/v2/inventory for List
GET /omk/opCharts/v2/inventory
You will get a list of all the Inventory subconcepts in your database.
Successful Response
HTTP Status | Body | Description |
---|---|---|
200 | Possibly empty JSON array of strings | Each array element is a JSON string object with the subconcept name |
Unsuccessful Response
HTTP Status | Body | Description |
---|---|---|
401 Unauthorized | JSON object with an error property | You are not authenticated. |
403 Forbidden | JSON object with an error property | You are not authorized. |
Example
Code Block |
---|
GET HTTP://server/omk/opCharts/v2/inventory.json Output:- List of all the distinct subconcepts present in inventory [ "health", "Host_Health", "laload", "mib2ip", "systemStats", "tcp", "WindowsProcessor", "hrwin", "nodehealth", "NetFlowStats", "RouteNumber", "Buffers" ] |
GET of opcharts/v2/inventory/
...
subconcept for List
GET /omk/opCharts/v2/inventory/
...
subconcept
You will get a list of the first 25 inventory objects for the given subconcept in your database.
You can use Request Modifiers (see above) for filtering, pagination, and selecting properties.
Successful Response
HTTP Status | Body | Description |
---|---|---|
200 | Possibly empty JSON array of strings | Each array element is a JSON string object with the subconcept name |
Unsuccessful Response
HTTP Status | Body | Description |
---|---|---|
400 Bad Request | JSON object with an error property | |
401 Unauthorized | JSON object with an error property | You are not authenticated. |
403 Forbidden | JSON object with an error property | You are not authorized. |
404 Not Found | JSON object with an error property | You are authenticated but not authorised to view this Enterprise Service in opChartsobject. |
404 Not Found | JSON object with an error property | The |
Example
Code Block |
---|
GET HTTP://server/omk/opCharts/v2/inventory/interface.json
Output :- List of first 25 interface inventory objects ("_id" and "nodes.uuid") sorted by nodes.name in ascending order.
[
{
"_id": "63958e8d41073d2dd381d606",
"nodes": {
"uuid": "08098577-5d8c-11e9-9614-8a6323fe4840"
}
},
{
"_id": "63958e9441073d2dd3822365",
"nodes": {
"uuid": "08098577-5d8c-11e9-9614-8a6323fe4840"
}
},
{
"_id": "63958e9041073d2dd381fbb7",
"nodes": {
"uuid": "08098577-5d8c-11e9-9614-8a6323fe4840"
}
},
{
"_id": "63958e9641073d2dd3823095",
"nodes": {
"uuid": "08098577-5d8c-11e9-9614-8a6323fe4840"
}
},
]
|
...
Request | Response |
---|---|
GET HTTP://server/omk/opCharts/v2/inventory/interface.json?limit=50 | First 50 elements sorted by nodes.name ("_id" and "nodes.uuid") |
GET HTTP://server/omk/opCharts/v2/inventory/interface.json?limit=50&page=2 | Next 50 elements sorted by nodes.name ("_id" and "nodes.uuid") |
GET HTTP://server/omk/opCharts/v2/inventory/interface.json?limit=50&properties=["nodes.name"] | First 50 elements sorted by nodes.name ("_id" , "nodes.uuid", "nodes.name") |
GET HTTP://server/omk/opCharts/v2/inventory/interface.json?limit=50&page=2&properties=["inventory.data"] | First NEXT 50 elements sorted by nodes.name ("_id" , "nodes.uuid", "inventory.data") |
GET HTTP://server/omk/opCharts/v2/inventory/interface.json?limit=50&properties=["nodes.name"]&filter={"inventory.data.ifIndex":3} | First 50 elements sorted by nodes.name, filtered by inventory.data.ifIndex => 3 ("_id" , "nodes.uuid", "nodes.name") |
GET of opcharts/v2/inventory/
...
id
...
GET /omk/opCharts/v2/inventory/
...
id
You will get a list of the first 25 inventory objects for the given subconcept in your database.
You can use Request Modifiers (see above) for filtering, pagination, and selecting properties.
Successful Response
HTTP Status | Body | Description |
---|---|---|
200 | Possibly empty JSON array of strings | Each array element is a JSON string object with the subconcept name |
Unsuccessful Response
HTTP Status | Body | Description |
---|---|---|
401 Unauthorized | JSON object with an error property | You are not authenticated. |
403 Forbidden | JSON object with an error property | You are not authorized. |
Example
Code Block |
---|
Need an example or request and response |
...