Bulk delete package policies

POST /api/fleet/package_policies/delete

[Required authorization] Route required privileges: fleet-agent-policies-all AND integrations-all.

Headers

  • kbn-xsrf string Required

    A required header to protect against CSRF attacks

application/json

Body

  • force boolean
  • packagePolicyIds array[string] Required

Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • body object

      Additional properties are NOT allowed.

      Hide body attribute Show body attribute object
      • message string Required
    • id string Required
    • name string
    • output_id string | null
    • package object Required

      Additional properties are NOT allowed.

      Hide package attributes Show package attributes object
      • experimental_data_stream_features array[object]
        Hide experimental_data_stream_features attributes Show experimental_data_stream_features attributes object
        • data_stream string Required
        • features object Required

          Additional properties are NOT allowed.

          Hide features attributes Show features attributes object
          • doc_value_only_numeric boolean
          • doc_value_only_other boolean
          • synthetic_source boolean
          • tsdb boolean
      • name string Required

        Package name

      • requires_root boolean
      • title string
      • version string Required

        Package version

    • policy_id string | null Deprecated

      Use policy_ids instead

    • policy_ids array[string] Required
    • statusCode number
    • success boolean Required
  • 400 application/json
    Hide response attributes Show response attributes object
    • error string
    • errorType string
    • message string Required
    • statusCode number
POST /api/fleet/package_policies/delete
curl \
 --request POST 'https://<KIBANA_URL>/api/fleet/package_policies/delete' \
 --header "Authorization: $API_KEY" \
 --header "Content-Type: application/json" \
 --header "kbn-xsrf: true" \
 --data '{"force":true,"packagePolicyIds":["string"]}'