SwarmOps
ReferenceCommandsswarmops auth status

Page kind: Reference

swarmops auth status#

Describes v0.13.0Last changed View as Markdown

List the logins your login file holds, without their tokens.

It reads the login file alone, and reaches no network: no token is checked with its provider. No file is no logins. A login of a provider this build does not know is listed too. A file that is a symbolic link, that its group or others can read or write, or that is not a login file of this version is E_INVALID_ARG, with the file in details.auth_file.

Metadata
Group
auth
Since
0.12.0
Mutates
no
Identity required
no
MCP tool
none
Envelope op
auth_status
Exit codes
02

Syntax#

Syntax
swarmops auth status [OPTIONS]

Required arguments#

None.

Optional arguments#

The command also takes the global options.

Examples#

Shell
SWARMOPS_AUTH_FILE=[tmp]/state/swarmops/auth.toml swarmops auth status
Output
{ "ok": true, "op": "auth_status", "api": 1, "result": { "file": "[tmp]/state/swarmops/auth.toml", "logins": [] },
Show 6 more lines "meta": { "elapsed_ms": "[elapsed_ms]", "resolved": {}, "auth": "trust" } }

Exit code 0. Recorded by the CLI tests. A name in square brackets, such as [tmp] or [c1], stands for what differs from run to run: the test's temporary directory, an id, a time.

Return information#

result is a AuthStatus (swarmops schema AuthStatus prints its JSON Schema).

FieldTypeRequiredDescription
filestring or nullnoThe login file, a path on the caller's host, whether or not it exists. Omitted on a host that names no directory for it.
loginsarray of AuthEntryyesThe logins, in the file's order; empty when there is no file or it holds none.

Envelope op: auth_status.

Exit codes:

  • 0: Success.
  • 2: The request or the command line is malformed.

Errors#

  • E_INVALID_ARG (exit 2): A malformed argument or request, including a command-line usage error.

Any command that opens a store may also fail with a store error, such as E_NOT_A_REPO, E_IO or E_STORE_CORRUPT; a command line the grammar refuses is E_INVALID_ARG (exit 2).

See also#

On this page