Skip to main content

GET /switches/metrics/{uuid}

Use this method to return a set of sample metrics for a specific Flex System switch. Each sample is represented in terms of when the sample was taken (timeStamp) and the value of the sample (metricValue).

Authentication

Authentication with username and password is required.

Request URL

GET https://{management_server_IP}/switches/metrics/{uuid}

where {uuid} is the UUID of the switch to be retrieved. To obtain the switch UUID, use the GET /switches method.

Query parameters

ParametersRequired / OptionalDescription
excludeAttributes={attributes}OptionalReturns a response that excludes the specified attributes for each resource. You can specify one or more attributes that are listed in the response body, separated by a comma.
Note
  • When the includeAttributes query parameter is specified, the excludeAttributes query parameter is ignored.
  • The response is filtered based on attribute name, not the attribute value.
  • Base attributes cannot be excluded.
includeAttributes=<attributes}OptionalReturns a response that includes the base attributes and the specified attributes for each resource. You can specify one or more attributes that are listed in the response body, separated by a comma.
Note
  • The response is filtered based on attribute name, not the attribute value.
  • If this attribute is not specified, all attributes are returned by default.

Response codes

CodeDescriptionComments
200OKThe request completed successfully.
400Bad RequestA query parameter or request attribute is missing or not valid, or the operation is not supported. A descriptive error message is returned in the response body.
403ForbiddenThe orchestrator server was prevented from fulfilling the request. A descriptive error message is returned in the response body. Ensure that you have privileges to perform the request.
409ConflictThere is a conflict with the current state of the resource. A descriptive error message is returned in the response body.
500Internal Server ErrorAn internal error occurred. A descriptive error message is returned in the response body.

Response body

Each energy metric contains one or more arrays that include when the sample was taken (timeStamp) and the value of the sample (metricValue).

AttributesTypeDescription
energyMetricsObjectEnergy metrics for the Flex System switch
 averageSwitchModulePowerArray of objectsAverage switch-module power samples
 minimumSwitchModulePowerArray of objectsMinimum switch-module power samples
 maximumSwitchModulePowerArray of objectsMaximum switch-module power samples
nameStringSwitch name
parentObjectInformation about the chassis that contains the switch
 uuidStringChassis UUID
 uriStringChassis URI
uuidStringSwitch UUID
uriStringSwitch URI
The following example is returned if the request is successful
{
"energyMetrics": {
"averageSwitchModulePower": [
{
"timeStamp": "2015-02-06T18:35:00Z",
"metricValue": 29
},
...
{
"timeStamp": "2015-02-06T18:49:59Z",
"metricValue": 30
},
],
"minimumSwitchModulePower": [
{
"timeStamp": "2015-02-06T18:35:00Z",
"metricValue": 29
},
...
{
"timeStamp": "2015-02-06T18:45:00Z",
"metricValue": 28
},
],
"maximumSwitchModulePower": [
{
"timeStamp": "2015-02-06T18:35:00Z",
"metricValue": 31
},
...
{
"timeStamp": "2015-02-06T18:45:00Z",
"metricValue": 32
},
]
},
"name": "IO Module 02",
"parent": {
"uuid": "3D1D5931BDF84D30ADA976E21F08CB91",
"uri": "chassis/3D1D5931BDF84D30ADA976E21F08CB91"
},
"uuid": "1E3B957727F8E11180000002C96317EC",
"uri": "switch/1E3B957727F8E11180000002C96317EC"
}