getSiteInsightMetricsForSwitch
Get Switch Insight Metrics See metrics possibilities at List Insight Metrics
Preferred authentication method for automation and integrations. Send the API token in the HTTP Authorization header.
Format:
Authorization: Token {apitoken}
Notes:
- An API token generated for a specific admin has the same privileges as that admin
- An API token is automatically removed if it is not used for more than 90 days
- SSO admins cannot generate admin API tokens. Use organization API tokens when scoped Org/Site privileges are needed.
In: header
Path Parameters
uuidSee List Insight Metrics for available metrics
^[0-9a-fA-F]{12}$Query Parameters
Port ID of the switch device, e.g. ge-0/0/1. Can be used with metrics related to interfaces, e.g. rx_bytes.
Lower bound of the time range, as an epoch timestamp in seconds or a relative value such as -1d or -1w
Upper bound of the time range, as an epoch timestamp in seconds or a relative value such as -1d, -2h, or now
Time range duration for the query, using relative units such as 10m, 7d, or 2w
"1d"Aggregation works by giving a time range plus interval (e.g. 1d, 1h, 10m) where aggregation function would be applied to.
Maximum number of results to return per page
0 <= value100Select the page number to return when using page-based pagination; starts at 1
1 <= value1Response Body
curl -X GET "https://example.com/api/v1/sites/000000ab-00ab-00ab-00ab-0000000000ab/insights/switch/0000000000ab/string"{ "end": 1604347200, "interval": 3600, "limit": 168, "page": 1, "results": [ 10, 11, 12, 12, 10, 9, 9, 9, 10, 10, 11, 11, 11, 11, 11, 11, 11, 10, 11, 11, 10, 11, 11, 10 ], "rt": [ "2020-11-01 20:00:00+00:00", "2020-11-01 21:00:00+00:00", "2020-11-01 22:00:00+00:00", "2020-11-01 23:00:00+00:00", "2020-11-02 00:00:00+00:00", "2020-11-02 01:00:00+00:00", "2020-11-02 02:00:00+00:00", "2020-11-02 03:00:00+00:00", "2020-11-02 04:00:00+00:00", "2020-11-02 05:00:00+00:00", "2020-11-02 06:00:00+00:00", "2020-11-02 07:00:00+00:00", "2020-11-02 08:00:00+00:00", "2020-11-02 09:00:00+00:00", "2020-11-02 10:00:00+00:00", "2020-11-02 11:00:00+00:00", "2020-11-02 12:00:00+00:00", "2020-11-02 13:00:00+00:00", "2020-11-02 14:00:00+00:00", "2020-11-02 15:00:00+00:00", "2020-11-02 16:00:00+00:00", "2020-11-02 17:00:00+00:00", "2020-11-02 18:00:00+00:00", "2020-11-02 19:00:00+00:00" ], "start": 1604260800}