@Endpoint functions.
Example
Authenticate with Runpod (opens browser automatically):How it works
- Flash generates an authorization request.
- Your browser opens to the Runpod console authorization page.
- You approve the request in your browser.
- Flash saves your API key to
~/.runpod/credentials.toml.
Flags
--no-open
Don’t automatically open the browser. Instead, manually copy the authorization URL and open it yourself.
Maximum time in seconds to wait for authorization. Default is 600 seconds (10 minutes).
Credential storage
After successful login, your API key is saved to~/.config/runpod/credentials.toml. This file is used by:
- All Flash CLI commands (
flash run,flash deploy, etc.) - Standalone Python scripts using
@Endpointfunctions - Any code using the Flash SDK
Keep your API key secure. Never commit it to version control. The credentials file is stored in your home directory, outside of project directories.
Alternative: Environment variable authentication
Instead of usingflash login, you can set your API key directly as an environment variable:
.env file:
Related commands
flash init- Create a new Flash projectflash run- Start the development serverflash deploy- Build and deploy to Runpod