Set how a wireless controller's access points are imported as nodes.
const url = 'https://example.com/api/v1/nodes/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/wireless-controller';const options = { method: 'PUT', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"ap_group_id":"2489E9AD-2EE2-8E00-8EC9-32D5F69181C0","import_aps":true,"max_aps":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://example.com/api/v1/nodes/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/wireless-controller \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "ap_group_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "import_aps": true, "max_aps": 1 }'Import is off until switched on here. An imported AP is a node of kind wireless_ap: it is never
polled itself — the controller’s AP walk reports it — and it goes down when the controller serving
it reports it down. A node deleted afterwards is not imported again automatically; use
POST /api/v1/wireless/aps/{ap_id}/import to bring it back.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The controller’s node id
Request Bodyrequired
Section titled “Request Bodyrequired”How a controller’s access points are imported.
object
The folder to file imported AP nodes in. Omitted or null ⇒ the folder this controller is
in; no folder is created. AP nodes already imported stay where they are.
Whether access points this controller reports become nodes (on unless someone turned it off). Only APs that have been in service at least once are imported automatically; importing starts within a minute.
The most access points this controller imports, 1–2048. Omitted ⇒ 1024.
Examplegenerated
{ "ap_group_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "import_aps": true, "max_aps": 1}Responses
Section titled “Responses”Settings stored; the controller as it now stands
What a controller’s last complete AP inventory said about the controller itself, and how its access points are imported as nodes.
object
The folder imported AP nodes are filed in. null ⇒ the folder this controller is in. No
folder is created for them.
How many access points the max_aps cap left out on the last import pass.
How many APs its last inventory carried.
Set when the controller reported more APs than one inventory may carry: how many it reported. The list then holds only the first ones by MAC address.
Whether access points this controller reports become nodes. On by default for a controller Yagra has just started reading; only APs that have been in service at least once are imported automatically.
When its last complete inventory arrived (RFC 3339). null if none has.
The most access points this controller imports (1–2048).
The controller’s node.
Example
{ "flavor": "huawei"}Max_aps outside 1–2048
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}No valid bearer token
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}Role lacks ManageConfig
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}No such node or folder, or one outside the caller’s scope
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}Inventory storage is unavailable (skeleton mode)
The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI
document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies
undescribed — a client that has to guess the failure shape ends up parsing the success shape and
reading undefined.
object
object
Stable machine-readable code. Clients branch on this, never on the message.
Operator-facing sentence. Safe to display; never carries an internal error’s own text.
Examplegenerated
{ "error": { "code": "example", "message": "example" }}