Export Devices in a Benchmark Set
POST {{cb_url}}/compliance/assessment/api/v1/orgs/{{cb_org_key}}/benchmark_sets/{{cb_benchmark_set_id}}/inventory/devices/_export
Export the Device Summary for devices in a Benchmark Set in CSV or JSON format.
To receive the actual JSON or CSV results, you need to use the Job Service API. First, use the Get Job Details to get the status of the async job, then Download Job Output call to download the actual content.
RBAC Permissions Required
Permission (.notation name) | Operation(s) |
---|---|
complianceAssessment.data | READ |
Request Schema
{
"query": "<string>",
"rows": "<integer>",
"start": "<integer>",
"criteria": {
"<fieldname>": [
"<string>"
]},
"exclusions": {
"<fieldname>": [
"<string>"
]},
"sort": [
{
"field": "<string>",
"order": "<string>"
}
],
"format": "<string>"
}
Request Body
{"query"=>"windows", "rows"=>20, "start"=>0, "criteria"=>{"os_type"=>["WINDOWS"]}, "exclusions"=>{"cis_version"=>["1.4.0"]}, "sort"=>[{"field"=>"create_time", "order"=>"DESC"}], "format"=>"json"}
RESPONSES
status: OK
[{"VM Name":"TEST\\DEMO-MACHINE","OS Version":"Windows Server 2019 x64","Sensor Version":"4.0.0.1292","Asset Type":"WORKLOAD","Last Checkin Time":"2023-12-19","Reason":"ASSESSMENT_SCHEDULED"}]