Documentation Index
Fetch the complete documentation index at: https://porter-mintlify-4369f078.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
porter auth contains commands for authenticating with Porter.
porter auth login
Authenticate with your Porter account. By default, this opens your browser to complete authentication.
Usage:
| Flag | Description |
|---|---|
--token | Log in using an existing token |
After logging in, Porter automatically sets your default project and cluster if you have access to any. You can view these with
porter config.Login methods
porter auth login supports two browser-based flows. Switch between them with porter config set-login-method.
| Method | Credential stored locally | Token lifetime |
|---|---|---|
v1 (default) | Long-lived Porter JWT | Does not expire |
v2 | Short-lived WorkOS access token issued via PKCE | Refreshed automatically; expires after a short window |
v2 flow signs in through your Porter SSO identity provider and authenticates subsequent API requests with a short-lived access token. Use it when your organization requires session-bound credentials on developer machines. The v1 flow remains the default and is recommended for CI/CD and other automated environments that need a stable long-lived token.
Both flows use the same
porter auth login command — only the credential stored in ~/.porter/config.json and sent on each request differs. No changes are required to existing scripts when staying on v1.
