POST /api/fleet/agents/bulk_upgrade

Spaces method and path for this operation:

post /s/{space_id}/api/fleet/agents/bulk_upgrade

Refer to Spaces for more information.

Headers

  • kbn-xsrf string Required

    Kibana's anti Cross-Site Request Forgery token. Can be any string value.

application/json

Body Required

  • agents string | array[string] Required

    One of:

    KQL query string, leave empty to action all agents

    list of agent IDs

  • force boolean

    Force upgrade, skipping validation (should be used with caution)

  • rollout_duration_seconds number

    rolling upgrade window duration in seconds

  • skipRateLimitCheck boolean

    Skip rate limit check for upgrade

  • source_uri string

    alternative upgrade binary download url

  • start_time string

    start time of upgrade in ISO 8601 format

  • version string Required

    version to upgrade to

Responses

  • 200 application/json

    OK

    Hide response attribute Show response attribute object
    • actionId string
  • 400 application/json

    Generic Error

    Hide response attributes Show response attributes object
    • error string
    • message string
    • statusCode number
POST /api/fleet/agents/bulk_upgrade
curl \
 --request POST 'https://localhost:5601/api/fleet/agents/bulk_upgrade' \
 --header "Authorization: $API_KEY" \
 --header "Content-Type: application/json" \
 --header "kbn-xsrf: string" \
 --data '{"agents":["agent1","agent2"],"version":"8.4.0","source_uri":"https://artifacts.elastic.co/downloads/beats/elastic-agent","start_time":"2022-08-03T14:00:00.000Z","rollout_duration_seconds":3600}'
Request example
{
  "agents": [
    "agent1",
    "agent2"
  ],
  "version": "8.4.0",
  "source_uri": "https://artifacts.elastic.co/downloads/beats/elastic-agent",
  "start_time": "2022-08-03T14:00:00.000Z",
  "rollout_duration_seconds": 3600
}