GET /api/fleet/agent_policies/{agentPolicyId}/download

Spaces method and path for this operation:

get /s/{space_id}/api/fleet/agent_policies/{agentPolicyId}/download

Refer to Spaces for more information.

Download an agent policy by ID.

[Required authorization] Route required privileges: fleet-agent-policies-read OR fleet-setup.

Path parameters

  • agentPolicyId string Required

Query parameters

  • download boolean

    If true, returns the policy as a downloadable file

  • standalone boolean

    If true, returns the policy formatted for standalone agents

  • kubernetes boolean

    If true, returns the policy formatted for Kubernetes deployment

  • revision number

    If provided, returns the policy at the specified revision. Cannot be used with standalone or kubernetes flags.

Responses

  • 200 application/json

    OK: A successful request.

  • 400 application/json

    A bad request.

    Hide response attributes Show response attributes object
    • error string
    • errorType string
    • message string Required
    • statusCode number
  • 404 application/json

    Not found.

    Hide response attributes Show response attributes object
    • error string
    • errorType string
    • message string Required
    • statusCode number
GET /api/fleet/agent_policies/{agentPolicyId}/download
curl \
 --request GET 'https://localhost:5601/api/fleet/agent_policies/{agentPolicyId}/download' \
 --header "Authorization: $API_KEY"