{"type":"api","title":"Retrieves top N items of a metric","meta":{"id":"/apps/pubhub/media/crosswork-network-controller-7-1/f445c17e25a1120e8fbde4bd413083d0fd88b2b3/f117fa98-ad23-3ca8-adf8-21349b86b3ff","info":{"title":"Crosswork Performance APIs","description":"Performance APIs allow the user to perform CRUD operations on performance service","contact":{"name":"Crosswork Team, Cisco","email":"support@cisco.com"},"license":{"name":"Cisco Software License Agreement","url":"http://www.cisco.com/public/sw-license-agreement.html"},"version":"7.1.0"},"x-parser-conf":{"overview":{"markdownPath":"reference/EMF/performance-api-overview.md"}},"openapi":"3.0.1","servers":[{"url":"http://localhost:8080/crosswork/performance","description":"Generated server url"}]},"spec":{"tags":["top-n-controller"],"summary":"Retrieves top N items of a metric","description":"The search is executed over a given period. The list can be filtered for a specific device group or port group. Supported metrics are listed under 'dashboards-metrics' API","operationId":"getTopN","parameters":[{"name":"metric","in":"query","description":"The metric for which Top is requested in the format SCHEMA_metricName","required":true,"schema":{"type":"string"}},{"name":"deviceGroups","in":"query","description":"The device group(s) by which to filter the result","required":false,"schema":{"type":"string"}},{"name":"portGroups","in":"query","description":"The port group(s) by which to filter the result","required":false,"schema":{"type":"string"}},{"name":"from","in":"query","description":"The requested start time in the format YYYY-MM-DDTHH:mm:ss.XXXZ","required":true,"schema":{"type":"string"}},{"name":"to","in":"query","description":"The requested end time in the format YYYY-MM-DDTHH:mm:ss.XXXZ","required":true,"schema":{"type":"string"}},{"name":"sort","in":"query","description":"The attribute by which to sort the response. (-) before the value will sort reversly. Sorting options are: avaerage/minimum/maximum","required":false,"schema":{"type":"string"}},{"name":"pageSize","in":"query","description":"The number of records to fetch","required":false,"schema":{"type":"integer","format":"int32","default":15}},{"name":"page","in":"query","description":"The page number to fetch","required":false,"schema":{"type":"integer","format":"int32","default":1}},{"name":"severity","in":"query","description":"The severity by which to filter results","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"string"}}}},"400":{"description":"Bad Request"},"500":{"description":"Internal Server Error"}},"__originalOperationId":"getTopN","method":"get","path":"/v1/dashboards/topn"}}