UtilitiesUpgrade

upgradeSiteDevices

POST
/api/v1/sites/{site_id}/devices/upgrade

Upgrade Site Device

Note: this call doesn’t guarantee the devices to be upgraded right away (they may be offline)

Authorization

Authorization<token>

Preferred authentication method for automation and integrations. Send the API token in the HTTP Authorization header.

Format: Authorization: Token {apitoken}

Notes:

  • An API token generated for a specific admin has the same privileges as that admin
  • An API token is automatically removed if it is not used for more than 90 days
  • SSO admins cannot generate admin API tokens. Use organization API tokens when scoped Org/Site privileges are needed.

In: header

Path Parameters

site_id*string
Formatuuid

Request Body

application/json

Request Body

Site device upgrade request

canary_phases?array<integer>

Only if strategy==canary. Canary phase percentages for the site upgrade

Default

[  1,  10,  50,  100]
device_ids?array<>

Specific device IDs selected for the site upgrade

enable_p2p?boolean

For APs only. Whether to allow local AP-to-AP FW upgrade

force?boolean

force==true will force upgrade when requested version is same as running version

Defaultfalse
max_failure_percentage?upgrade_devices_max_failure_percentage

If strategy!=big_bang. Allowed failure percentage across the site upgrade

Range0 <= value <= 100
Default5
max_failures?array<integer>

If strategy==canary. Per-phase failure limits for the site upgrade

models?array<string>

Device models selected for the site upgrade

p2p_cluster_size?integer

For APs only and if enable_p2p==true. Size to split devices for peer-to-peer download batches; default 10

Range0 <= value
Default10
p2p_parallelism?integer

For APs only and if enable_p2p==true. Number of parallel peer-to-peer download batches to create. If not set, automatically determined based on device count (<=50 uses 1, 51-100 uses 3, >100 uses 10)

reboot?boolean

For Switches and Gateways only (APs are automatically rebooted). Reboot device immediately after upgrade is completed

Defaultfalse
reboot_at?integer

For Switches and Gateways only and if reboot==true. Reboot start time in epoch seconds, default is start_time

rrm_first_batch_percentage?integer

For APs only and if strategy==rrm. Percentage of APs that need to be present in the first RRM batch

rrm_max_batch_percentage?integer

For APs only and if strategy==rrm. Max percentage of APs that need to be present in each RRM batch

rrm_mesh_upgrade?upgrade_device_rrm_mesh_upgrade

For APs only and if strategy==rrm. Mesh AP upgrade order for the site upgrade. enum: parallel, sequential.

Default"sequential"

Value in

  • "parallel"
  • "sequential"
rrm_node_order?upgrade_device_rrm_node_order

For APs only and if strategy==rrm. AP ordering direction for RRM upgrade batches. enum: center_to_fringe, fringe_to_center.

Default"fringe_to_center"

Value in

  • "center_to_fringe"
  • "fringe_to_center"
rrm_slow_ramp?boolean

For APs only and if strategy==rrm. True will make rrm batch sizes slowly ramp up

rules?array<>

Selection rules used to choose devices for this site upgrade

snapshot?boolean

For Junos devices only. Perform recovery snapshot after device is rebooted

Defaultfalse
start_time?integer

Upgrade start time in epoch seconds, default is now

strategy?upgrade_device_strategy

Upgrade orchestration strategy for selected devices. enum: big_bang, canary, rrm, serial.

Default"big_bang"

Value in

  • "big_bang"
  • "canary"
  • "rrm"
  • "serial"
version?string

Specific version / stable, default is to use the latest available version

Response Body

curl -X POST "https://example.com/api/v1/sites/000000ab-00ab-00ab-00ab-0000000000ab/devices/upgrade" \  -H "Content-Type: application/json" \  -d '{}'
{  "upgrade_id": "4316c116-0acb-4c43-8f06-6723154e741e"}