chainabit auth keys scopes
List the scopes an API key can be granted and the expiry presets you can choose.
Synopsis
chainabit auth keys scopes [options]Options shared by every command are described in Global options and shared behavior.
Alias of: chainabit auth developer-token scopes.
Behavior
Reads your account's API key permission catalog from the server and prints the scopes you can grant with --scope and the expiry presets you can choose with --expires when you run auth developer-token create. It does not create, change or reveal a key. scopes and permissions are two names for the same command, under both auth developer-token and auth keys.
The catalog is the source of truth for scopes and presets, and it can change. Developer access explains each permission field and the expiry presets.
Output
Human output prints two tables. The scope table shows Scope, Label, Risk, Approval and Requires; Requires lists the scopes that must be granted together with that scope. The expiry table shows Expiry, Days, Available and Reason; a preset you cannot choose now shows no with its reason. When the server reports a custom expiry range, a line states the times --expires-at accepts, or that it is unavailable for the account. Two auth keys create command patterns follow.
--json prints one JSON object containing catalogVersion, scopes, expiry and, when the server reports a custom expiry range, customExpiry. The scopes and expiry entries carry the table values, including display text such as never expires, yes and no, not the raw catalog fields. Help exits 0; errors exit with the codes in Exit codes.
Authentication and permissions
A credential is required: a signed-in session or CHAINABIT_TOKEN. Without one, the command stops before contacting the server. The server decides which credentials may read the catalog; see Developer access.
Examples
chainabit auth keys scopes
chainabit --json auth keys scopes