Skip to main content

Browser login

oanim login
Opens your browser for OAuth authentication via Clerk. After signing in, an API key is generated and saved to ~/.oanim/credentials.yaml (file permissions: 0600).
1
CLI starts a local server
2
The CLI opens a local HTTP server on a random port to receive the callback.
3
Browser authenticates
4
Your browser opens api.oanim.dev/api/v1/auth/cli/login?port=<port> where you sign in via Clerk OAuth.
5
API key is issued
6
After authentication, the platform generates a new API key (prefixed anim_) and sends it back to the local server.
7
Credentials are saved
8
The CLI saves the key to ~/.oanim/credentials.yaml. All subsequent commands use it automatically.

Token-based login

For CI/CD environments or headless use:
oanim login --token <your-api-key>
This verifies the key against the API and saves it to credentials. No browser required.

Credential resolution

When the CLI makes API calls, credentials resolve in this order:
PrioritySourceDescription
1ANIMATE_API_KEY env varEnvironment variable — highest priority
2api_key in ~/.oanim/credentials.yamlSaved by oanim login
For asset generation only, there’s an additional bypass:
PrioritySourceDescription
SpecialANIMATE_FAL_KEY env varGoes direct to fal.ai, skipping the platform entirely

Check who you’re logged in as

oanim whoami
Shows your email, user ID, credit balance, and account creation date.

Log out

oanim logout
Clears saved credentials from ~/.oanim/credentials.yaml.

Configuration

The API URL defaults to https://api.oanim.dev. Override it for self-hosted instances:
  • ANIMATE_API_URL environment variable (highest priority)
  • api_url field in ~/.oanim/config.yaml
# ~/.oanim/config.yaml
api_url: http://localhost:8000
The full resolution order: ANIMATE_API_URL env var → config.yamlhttps://api.oanim.dev.