{"type":"api","title":"Query statistics of detections","meta":{"id":"/apps/pubhub/media/cisco-xdr-api-docs/f4e065ff5977829c89df289df08411f83205f526/c863f2ae-5ca3-3d27-9fd9-e536d4b0ebeb","info":{"title":"XDR Query Service API","version":"1.0.0"},"x-parser-conf":{"serverConfig":"select","overview":{"markdownPath":"reference/findings-query/overview.md","uri":"findings-query-api-guide"},"disableAuthEditing":true,"exampleAsDefault":true,"oAuth2":{"clientId":"client-546e34fc-c6bf-4951-ac69-f6d7987a7814","clientSecret":"MYw4_E_tBdFwUwrX6WFYKVD5LQrG2k7XrJ5J046wWE0s1gAKCxJ8VA","proxyEnabled":false},"meta":{"useProxy":true}},"openapi":"3.1.0","servers":[{"url":"https://queryservice.us.security.cisco.com"}],"securitySchemes":{"bearer":{"bearerFormat":"JWT","scheme":"bearer","type":"http"}}},"spec":{"description":"Query statistics of detections in data lake with filters","operationId":"get_statistics","parameters":[{"description":"The start time filter for the detection time field in UTC format. If not provided, defaults to 7 days before 'end_time'. If 'end_time' is also not provided, defaults to 7 days before the current time.","explode":false,"in":"query","name":"start_time","schema":{"description":"The start time filter for the detection time field in UTC format. If not provided, defaults to 7 days before 'end_time'. If 'end_time' is also not provided, defaults to 7 days before the current time.","format":"date-time","type":"string"}},{"description":"The end time filter for the detection time field in UTC format. If not provided, defaults to 7 days after 'start_time'. If 'start_time' is also not provided, defaults to the current time.","explode":false,"in":"query","name":"end_time","schema":{"description":"The end time filter for the detection time field in UTC format. If not provided, defaults to 7 days after 'start_time'. If 'start_time' is also not provided, defaults to the current time.","format":"date-time","type":"string"}},{"description":"The list of severities to filter by. Multiple values are combined using an IN clause.","explode":false,"in":"query","name":"severity","schema":{"description":"The list of severities to filter by. Multiple values are combined using an IN clause.","items":{"enum":["Low","Medium","High","Critical","Unknown"],"type":"string"},"type":["array","null"]}},{"description":"The list of ids of the products to filter by. Multiple values are combined using an IN clause.","explode":false,"in":"query","name":"source","schema":{"description":"The list of ids of the products to filter by. Multiple values are combined using an IN clause.","items":{"type":"string"},"type":["array","null"]}},{"description":"The title of the detection to filter by, it can be partial or full match","explode":false,"in":"query","name":"title","schema":{"description":"The title of the detection to filter by, it can be partial or full match","type":"string"}},{"description":"The id of the detection to filter by","explode":false,"in":"query","name":"detection_id","schema":{"description":"The id of the detection to filter by","type":"string"}},{"description":"The label to filter detections by. Multiple values are combined using an IN clause.","explode":false,"in":"query","name":"label","schema":{"description":"The label to filter detections by. Multiple values are combined using an IN clause.","items":{"enum":["regular-finding","non-regular-finding","intake-api-finding"],"type":"string"},"type":["array","null"]}},{"description":"The field to get statistics. Default is detections","explode":false,"in":"query","name":"field","schema":{"default":"detections","description":"The field to get statistics. Default is detections","enum":["detections"],"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"additionalProperties":false,"properties":{"total_count":{"description":"The total count of the entity specified by the field in the request","format":"int64","type":"integer"}},"required":["total_count"],"type":"object","$$ref":"#/components/schemas/DetectionsStatsResponse"}}},"description":"OK"},"default":{"content":{"application/json":{"schema":{"additionalProperties":false,"properties":{"details":{"items":{"type":"string"},"type":["array","null"]},"message":{"type":"string"},"status":{"format":"int64","type":"integer"}},"required":["status","message"],"type":"object","$$ref":"#/components/schemas/DataServiceError"}}},"description":"Error"}},"security":[{"bearer":[]}],"summary":"Query statistics of detections","tags":["Statistics"],"__originalOperationId":"get-statistics","method":"get","path":"/api/v1/query/statistics"}}