Skip to main content

CSPM policies

CSPM policy details is the CSPM Registration collection for this CID — GetCspmPoliciesDetails (SOURCE GetCSPMPoliciesDetails, PEP 8 get_policy_details), GetCspmPolicy (SOURCE GetCSPMPolicy, PEP 8 get_policy), GetCspmPolicySettings (SOURCE GetCSPMPolicySettings, PEP 8 get_policy_settings), and UpdateCspmPolicySettings (SOURCE UpdateCSPMPolicySettings, PEP 8 update_policy_settings). The paths are GET /settings/entities/policy-details/v2, GET /settings/entities/policy-details/v1, GET /settings/entities/policy/v1, and PATCH /settings/entities/policy/v1 (same path as GET settings, method PATCH; distinct from GET settings, GetCspmPolicy, GetCspmPoliciesDetails, and Prevention policies). Image assessment policies / remaining cloud and other cloud/container collections are not implemented (not yet). This is not GetCSPMScanSchedule, not GetIOAEvents (/ioa/entities/events/v1), not Prevention policies (/policy/…), not Cloud IOM (/detects/entities/iom/…), and not Cloud IOA (/detects/entities/ioa/…). Prevention policies is a separate collection: Prevention policies. Cloud IOM is a separate collection: CSPM IOM. Cloud IOA is a separate collection: CSPM IOA. Cloud IOA events is a separate collection: CSPM IOA events. This is not the HelloService template sample (GET /api/hello).

This collection is not CrowdStrike production. It does not call Falcon cloud. It is not CrowdStrike Falcon Cloud or Horizon.

RPC field notes: CspmRegistrationService. REST schemas: API reference. GetCspmPoliciesDetails, GetCspmPolicy, and GetCspmPolicySettings use query params, not FQL. Filter this slice is integer ids (repeated) on policy-details, and optional integer policy-id plus optional cloud-platform on settings. Extra unused query keys are ignored (including service on settings). Clone success is JSON MSA 200 CspmPolicy for policy-details (not SOURCE 207) and 200 MSA CspmPolicySetting for settings. Policy-details fields are ID, policy_type, cloud_platform_type, default_severity, is_enabled, description (not the full SOURCE object). Settings fields are policy_id, name, cloud_provider, default_severity, policy_type. DESIGN name is the stored description. JSON ID and policy_id may be a number or a string (protojson int64). v2 ids is optional. v1 ids is required (one or more). Empty v1 ids → 400. Settings policy-id and cloud-platform are optional. PATCH update (/settings/entities/policy/v1) uses JSON body {policy_id, severity}. Required policy_id, severity. Extra unused keys including enabled, account_id, account_ids, region, regions, tag_excluded, resources, and parameters are ignored. The clone does not persist enabled. Clone PATCH success is JSON MSA 200 CspmPolicySetting. PATCH is distinct from GET settings (same path, method GET), GetCspmPolicy /policy-details/v1, GetCspmPoliciesDetails /policy-details/v2, and Prevention policies /policy/…. Unknown policy_id → 404. Missing policy_id or empty severity → 400.

These curls use Host: crowdstrike-api.localhost against Compose Traefik on :8088. If the hostname already resolves to Traefik, you can omit the Host header and call http://crowdstrike-api.localhost instead.

Auth​

Every call needs a console session or a Bearer token:

  • Cookie cs_console from CreateSession (POST /identity/entities/sessions/v1)
  • Authorization: Bearer with cspm-registration:read (GET list, GET one, GET settings) or cspm-registration:write (PATCH update settings)

A session cookie bypasses OAuth scopes. Seed client cs-local-hosts (hosts:read only) cannot list policy details, get a policy, list policy settings, or update policy settings (403). GetCspmPoliciesDetails, GetCspmPolicy, and GetCspmPolicySettings stay cspm-registration:read (not write). UpdateCspmPolicySettings needs cspm-registration:write. cspm-registration:read can list policy details, get a policy, and list policy settings and cannot PATCH (403). Unit tests use a client named cs-local-cspm with cspm-registration:read; that client can list policy details, get a policy, and list policy settings (200) and cannot PATCH (403). Unit tests use cs-local-cspmw with cspm-registration:write; that client can PATCH (200). Neither is in the production seed. There is no seeded production client with cspm-registration:read or cspm-registration:write — use the console cookie, or a client you created with that scope. Missing or revoked token → 401.

HTTP paths​

MethodPathUse
GET/settings/entities/policy-details/v2List CSPM policy details. RPC GetCspmPoliciesDetails (SOURCE GetCSPMPoliciesDetails). PEP 8 get_policy_details. Query: optional integer ids (repeated). Success 200 MSA CspmPolicy. Extra unused query keys ignored. Distinct from GetCSPMPolicy /settings/entities/policy-details/v1, GetCSPMPolicySettings /settings/entities/policy/v1, Prevention policies /policy/…, Cloud IOM /detects/entities/iom/…, and Cloud IOA /detects/entities/ioa/….
GET/settings/entities/policy-details/v1Get CSPM policies. RPC GetCspmPolicy (SOURCE GetCSPMPolicy). PEP 8 get_policy. Query: required integer ids (one or more). Empty ids → 400. Success 200 MSA CspmPolicy. Extra unused query keys ignored. Distinct from GetCSPMPoliciesDetails /settings/entities/policy-details/v2, GetCSPMPolicySettings /settings/entities/policy/v1, Prevention policies /policy/…, Cloud IOM /detects/entities/iom/…, and Cloud IOA /detects/entities/ioa/….
GET/settings/entities/policy/v1List CSPM policy settings. RPC GetCspmPolicySettings (SOURCE GetCSPMPolicySettings). PEP 8 get_policy_settings. Query: optional integer policy-id, optional cloud-platform. Success 200 MSA CspmPolicySetting. Extra unused query keys including service ignored. Distinct from PATCH update same path, GetCSPMPolicy /settings/entities/policy-details/v1, GetCSPMPoliciesDetails /settings/entities/policy-details/v2, Prevention policies /policy/…, Cloud IOM /detects/entities/iom/…, and Cloud IOA /detects/entities/ioa/….
PATCH/settings/entities/policy/v1Update CSPM policy setting. RPC UpdateCspmPolicySettings (SOURCE UpdateCSPMPolicySettings). PEP 8 update_policy_settings. Body JSON {policy_id, severity}. Required policy_id, severity. Success 200 MSA CspmPolicySetting. Extra unused keys ignored. Does not persist enabled. Distinct from GET settings same path, GetCspmPolicy /settings/entities/policy-details/v1, GetCspmPoliciesDetails /settings/entities/policy-details/v2, Prevention policies /policy/…. cspm-registration:write.

Empty v2 ids returns every policy in this CID ordered by ID ASC. Unknown ids are omitted (empty 200 if none match). Invalid non-integer ids → 400. Extra unused query keys are ignored.

JSON for policy-details is ID, policy_type, cloud_platform_type, default_severity, is_enabled, description. This is not the full SOURCE policy object.

Empty settings filters list every setting in this CID ordered by policy_id ASC. Unknown policy-id is omitted (empty 200 if none match). Invalid non-integer policy-id → 400. If cloud-platform is set, it must be aws, azure, or gcp; otherwise 400. Extra unused query keys including service are ignored.

JSON for settings is policy_id, name, cloud_provider, default_severity, policy_type. DESIGN name is the stored description. PATCH body is JSON {policy_id, severity}. Extra unused keys including enabled are ignored. The clone does not persist enabled. GET policy-id=101 after PATCH matches that default_severity.

This is not GetCSPMScanSchedule, Prevention policies, Cloud IOM, Cloud IOA, or the HelloService template. Image assessment policies / remaining cloud and other cloud collections are not implemented (not yet). Prevention policies uses /policy/…: Prevention policies. Cloud IOM uses /detects/entities/iom/…: CSPM IOM. Cloud IOA uses /detects/entities/ioa/…: CSPM IOA.

Seed policies​

IDpolicy_typecloud_platform_typedefault_severityis_enableddescription
101managedawsHightrueS3 buckets must block public access
102managedazureMediumfalseStorage accounts must disable public blob access

Empty v2 ids returns both (order ID ASC). v2 ids=101 returns 101. v1 ids=101 returns 101. Empty v1 ids is 400.

Empty settings filters return both (order policy_id ASC). Settings policy-id=101 returns 101. Settings cloud-platform=aws returns 101. PATCH policy_id=101 / severity=Informational updates 101 to Informational. Seed stored severity for 101 is High until PATCH.

curl -sS -c cookies.txt -H 'Host: crowdstrike-api.localhost' \
-H 'Content-Type: application/json' \
-d '{"email":"[email protected]","password":"FalconLocal!1","cloud":"us-1"}' \
http://127.0.0.1:8088/identity/entities/sessions/v1

Empty ids returns at least the two seed ids, including 101 and 102:

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v2'

ids=101 returns 101:

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v2?ids=101'

Unknown ids are omitted (empty 200 if none match):

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v2?ids=999'

Invalid non-integer ids is 400:

curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v2?ids=not-an-id'

Extra unused query keys are ignored (limit does not paginate this slice):

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v2?limit=1'

cs-local-hosts (hosts:read only) is 403:

TOKEN='<access_token from cs-local-hosts>'
curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
'http://127.0.0.1:8088/settings/entities/policy-details/v2'

No cookie and no Bearer is 401:

curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' \
'http://127.0.0.1:8088/settings/entities/policy-details/v2'

Image assessment policies / remaining cloud and other cloud collections are not implemented (not yet). Prevention policies is a separate collection: Prevention policies. Cloud IOM is a separate collection: CSPM IOM. Cloud IOA is a separate collection: CSPM IOA. This is not the HelloService template (GET /api/hello).

ids=101 returns 101:

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v1?ids=101'

Empty ids is 400:

curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v1'

Unknown ids are omitted (empty 200 if none match):

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v1?ids=999'

Invalid non-integer ids is 400:

curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v1?ids=not-an-id'

Extra unused query keys are ignored (limit does not paginate this slice):

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy-details/v1?ids=101&limit=1'

cs-local-hosts (hosts:read only) is 403:

TOKEN='<access_token from cs-local-hosts>'
curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
'http://127.0.0.1:8088/settings/entities/policy-details/v1'

No cookie and no Bearer is 401:

curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' \
'http://127.0.0.1:8088/settings/entities/policy-details/v1'

Image assessment policies / remaining cloud and other cloud collections are not implemented (not yet). Prevention policies is a separate collection: Prevention policies. Cloud IOM is a separate collection: CSPM IOM. Cloud IOA is a separate collection: CSPM IOA. This is not the HelloService template (GET /api/hello).

Empty filters return at least the two seed policy ids, including 101 and 102, ordered by policy_id ASC:

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy/v1'

policy-id=101 returns 101:

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy/v1?policy-id=101'

Unknown policy-id is omitted (empty 200 if none match):

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy/v1?policy-id=999'

Invalid non-integer policy-id is 400:

curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy/v1?policy-id=not-an-id'

If cloud-platform is set, it must be aws, azure, or gcp. cloud-platform=aws returns 101. Other values are 400:

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy/v1?cloud-platform=aws'
curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy/v1?cloud-platform=foo'

Extra unused query keys including service are ignored:

curl -sS -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
'http://127.0.0.1:8088/settings/entities/policy/v1?service=ignored'

cs-local-hosts (hosts:read only) is 403:

TOKEN='<access_token from cs-local-hosts>'
curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
'http://127.0.0.1:8088/settings/entities/policy/v1'

No cookie and no Bearer is 401:

curl -sS -o /dev/null -w '%{http_code}\n' \
-H 'Host: crowdstrike-api.localhost' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

Image assessment policies / remaining cloud and other cloud collections are not implemented (not yet). Prevention policies is a separate collection: Prevention policies. Cloud IOM is a separate collection: CSPM IOM. Cloud IOA is a separate collection: CSPM IOA. This is not the HelloService template (GET /api/hello).

PATCH policy_id=101 / severity=Informational on /settings/entities/policy/v1 returns that setting with default_severity Informational. Success is 200 MSA CspmPolicySetting. This is not GET settings (same path, method GET), not GetCspmPolicy (GET /settings/entities/policy-details/v1), not GetCspmPoliciesDetails (GET /settings/entities/policy-details/v2), and not Prevention policies (/policy/…). Required policy_id, severity. Extra unused keys including enabled, account_id, account_ids, region, regions, tag_excluded, resources, and parameters are ignored. The clone does not persist enabled. is_enabled stays unchanged. GET policy-id=101 after PATCH matches that default_severity:

curl -sS -X PATCH -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
-H 'Content-Type: application/json' \
-d '{"policy_id":101,"severity":"Informational"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

Missing policy_id is 400:

curl -sS -o /dev/null -w '%{http_code}\n' \
-X PATCH -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
-H 'Content-Type: application/json' \
-d '{"severity":"Informational"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

Missing severity is 400:

curl -sS -o /dev/null -w '%{http_code}\n' \
-X PATCH -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
-H 'Content-Type: application/json' \
-d '{"policy_id":101}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

Unknown policy_id is 404:

curl -sS -o /dev/null -w '%{http_code}\n' \
-X PATCH -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
-H 'Content-Type: application/json' \
-d '{"policy_id":999,"severity":"Informational"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

Extra unused keys including enabled are ignored (enabled is not persisted):

curl -sS -X PATCH -H 'Host: crowdstrike-api.localhost' -b cookies.txt \
-H 'Content-Type: application/json' \
-d '{"policy_id":101,"severity":"Informational","enabled":false,"account_id":"ignored","account_ids":[],"region":"ignored","regions":[],"tag_excluded":true,"resources":[],"parameters":"ignored"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

cs-local-hosts (hosts:read only) is 403 on PATCH:

TOKEN='<access_token from cs-local-hosts>'
curl -sS -o /dev/null -w '%{http_code}\n' \
-X PATCH -H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
-H 'Content-Type: application/json' \
-d '{"policy_id":101,"severity":"Informational"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

cs-local-cspm (cspm-registration:read) is 403 on PATCH:

TOKEN='<access_token from cs-local-cspm>'
curl -sS -o /dev/null -w '%{http_code}\n' \
-X PATCH -H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
-H 'Content-Type: application/json' \
-d '{"policy_id":101,"severity":"Informational"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

No cookie and no Bearer is 401 on PATCH:

curl -sS -o /dev/null -w '%{http_code}\n' \
-X PATCH -H 'Host: crowdstrike-api.localhost' \
-H 'Content-Type: application/json' \
-d '{"policy_id":101,"severity":"Informational"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

Image assessment policies / remaining cloud and other cloud collections are not implemented (not yet). Prevention policies is a separate collection: Prevention policies. Cloud IOM is a separate collection: CSPM IOM. Cloud IOA is a separate collection: CSPM IOA. This is not the HelloService template (GET /api/hello).

List (Bearer)​

TOKEN='<access_token from a client with cspm-registration:read>'
curl -sS -H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
'http://127.0.0.1:8088/settings/entities/policy-details/v2'

cspm-registration:read → 200 (including unit-test client cs-local-cspm). A token without that scope (including hosts:read only, e.g. cs-local-hosts) → 403. Missing or revoked token → 401. GetCspmPoliciesDetails stays cspm-registration:read. PEP 8 get_policy_details. There is no seeded production client with cspm-registration:read — use the console cookie, or a client you created with that scope.

Get (Bearer)​

TOKEN='<access_token from a client with cspm-registration:read>'
curl -sS -H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
'http://127.0.0.1:8088/settings/entities/policy-details/v1?ids=101'

cspm-registration:read → 200 (including unit-test client cs-local-cspm). A token without that scope (including hosts:read only, e.g. cs-local-hosts) → 403. Missing or revoked token → 401. GetCspmPolicy stays cspm-registration:read. PEP 8 get_policy. There is no seeded production client with cspm-registration:read — use the console cookie, or a client you created with that scope.

List settings (Bearer)​

TOKEN='<access_token from a client with cspm-registration:read>'
curl -sS -H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
'http://127.0.0.1:8088/settings/entities/policy/v1'

cspm-registration:read → 200 (including unit-test client cs-local-cspm). A token without that scope (including hosts:read only, e.g. cs-local-hosts) → 403. Missing or revoked token → 401. GetCspmPolicySettings stays cspm-registration:read. PEP 8 get_policy_settings. There is no seeded production client with cspm-registration:read — use the console cookie, or a client you created with that scope.

Update settings (Bearer)​

TOKEN='<access_token from a client with cspm-registration:write>'
curl -sS -X PATCH -H 'Host: crowdstrike-api.localhost' \
-H "Authorization: Bearer ${TOKEN}" \
-H 'Content-Type: application/json' \
-d '{"policy_id":101,"severity":"Informational"}' \
'http://127.0.0.1:8088/settings/entities/policy/v1'

cspm-registration:write → 200 on PATCH (including unit-test client cs-local-cspmw). A token without that scope (including hosts:read only, e.g. cs-local-hosts, or cspm-registration:read such as cs-local-cspm) → 403. Missing or revoked token → 401. There is no product-seeded write client with cspm-registration:write — use the console cookie, or a client you created with that scope. UpdateCspmPolicySettings stays cspm-registration:write. SOURCE UpdateCSPMPolicySettings. PEP 8 update_policy_settings. Distinct from GET settings /settings/entities/policy/v1, GetCspmPolicy /settings/entities/policy-details/v1, GetCspmPoliciesDetails /settings/entities/policy-details/v2, and Prevention policies /policy/…. Extra unused keys ignored. Required body policy_id, severity. The clone does not persist enabled.

OAuth2 mint/revoke: OAuth2. Accessible scopes: API clients.