get_config_backup
const url = 'https://example.com/api/v1/nodes/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/config-backup';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/api/v1/nodes/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/config-backup \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Node id
Responses
Section titled “Responses”The node’s config backup: configuration, whether it is fetched, the login being tried or that works, the latest attempts
One node’s config backup.
object
The newest attempts, newest first.
One login attempt.
object
The login tried; null when it has since been deleted.
For a success: whether a new version was stored. null otherwise.
How one login attempt ended.
Yagra saves it on its own after a fetch finds it unsaved (ADR-222 Inc.11). Switched with
POST /api/v1/config-backups/auto-save.
Whether this deployment has an oxidized at all.
The logins this node tries, in order (login_order with deleted ones dropped, or every CLI
login).
The login handed to oxidized: the one being tried, or the one that works.
Every candidate failed in this pass; nothing is tried until a fetch is asked for, the order changes, or a CLI login is added or changed.
How the device’s command line is reached: ssh_then_telnet lets Yagra pick SSH or telnet
for each attempt (ADR-242); ssh or telnet fixes it.
When a fetch last worked, from every attempt rather than the newest few; null when none
has or the backup is switched off.
credential_id has fetched successfully.
The node’s own order of CLI logins; null means every CLI login in the try order.
The model a person picked; null means “from the profile”.
The models a person may pick.
Yagra asked oxidized for a fetch and has not heard how it ended.
The model the node’s profile maps to, if any.
Whether it is fetched, or the one thing to fix.
Whether Yagra can save this node’s model (ADR-222): the model it is fetched with has a save command in Yagra’s table.
The newest saves, newest first.
One save, as a screen lists it.
object
Whether the startup configuration the save replaced was kept.
Who asked for a save.
Where a save stands.
How fast it tries its logins: one set of lockout limits each (stage 3 decision 27).
The node has gone without a fetch that worked for longer than core allows, or its “config
backup not fetched” alert is open and no fetch has worked since - the judgement that opens
and closes that alert (ADR-240 decision 6), whether or not a maintenance window holds it
back. false while switched off.
What oxidized last reported.
object
When Yagra last read it. Older than ten minutes means oxidized has not been answering.
Oxidized’s word: success, no_connection, fail, timelimit or never.
When the lockout limits allow the next try; null when one may be tried now, or none is due.
Running and startup differ, from the save script’s last comparison (Inc.9); null ⇒ they
agreed, or this model is not compared over the command line.
object
When the script last compared them.
What the device printed for that comparison is kept, and
GET …/config-backup/unsaved returns it.
The first time running and startup were seen to differ.
Example
{ "attempts": [ { "input": "ssh", "outcome": "success" } ], "input": "ssh", "protocol": "ssh", "readiness": "ready", "saves": [ { "failure": "auth", "origin": "person", "state": "pending" } ], "scan_mode": "rapid"}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" }}No such node the caller can see
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" }}This deployment has no write side (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" }}