post
https://sandbox.saner.secpod.com/AncorWebService/perform
Add more accounts to an existing benchmark provision.
This method can be used to update accounts for an existing compliance provision. The benchmark will be added to the specified accounts; however, the newly added accounts will continue to get existing compliance provision.
| Key | Meaning | Mandatory | Data Type |
|---|---|---|---|
| adminId | The admin user ID (email) of the source account initiating the update | Yes | string |
| benchmarkname | The name of the existing benchmark to be updated | Yes | string |
| target_organization | The name of the target organization where the benchmark provision will be updated | Yes | string |
| target_account_name | The target account name within the organization; use 'ALL' to apply to all accounts | Yes | string |
| target_group | The group within the target account to which the benchmark applies (e.g., a device group like 'debian') | No | string |
| apifilters | Optional filters to narrow down targets using tags with 'in' and 'not in' conditions | No | array |
Python SDK code
Install:
pip install secpod-saner-sdkCall this endpoint:
from saner.cvem import CvemClient
client = CvemClient(
api_key="<YOUR_API_KEY>",
accountid="<YOUR_ACCOUNT_ID>",
base_url="https://saner.secpod.com"
)
response=client.Compliance.updateProvisionBenchmark(
adminId="[email protected]",
benchmarkname="Test",
target_account_name="Default",
target_organization="Demo Org",
target_group="windows 11",
apifilters={
"tags": {
"in": {
"Owner": [
"Default",
"Default 1"
]
},
"not in": {
"Category": [
"Finance"
]
}
}
})
print(response)
client.close()Requires Python 3.9 or later.