Authentication
The CLI authenticates with an S2 access token. Generate one from the dashboard, then store it securely:Scripts and CI
For a non-persistent override, setS2_ACCESS_TOKEN. It takes precedence over any saved access token:
Headless systems
The CLI does not silently fall back to plaintext when an OS credential store is unavailable. To explicitly use a private local file on a headless system, add--insecure-storage:
Migrate an existing token
Access tokens previously saved asaccess_token in config.toml remain readable but are deprecated. Move one into the OS credential store with:
Remove a stored token
s2 revoke-access-token when the token must stop working everywhere.
Managing Config
s2 config list reports a configured access token as <redacted>, and s2 config get access_token does not reveal the credential. Use the s2 auth access-token commands to manage access tokens.
Default Location
Whencreate-basin is called without --location, the basin uses the account’s default location.

