CLI

Authentication

oblien login

The fastest way to authenticate. Opens your browser, you log in with your Oblien account, and API credentials are created and saved automatically.

oblien login

This is a top-level shortcut for oblien auth login. It:

  1. Creates a session via the Oblien API
  2. Opens a browser window with the login URL
  3. Waits for you to complete authentication
  4. Auto-creates API credentials (client ID + secret)
  5. Saves them to ~/.oblien/credentials.json

After login, the CLI, SDK, and MCP server all work automatically.

If the browser can't open (e.g., SSH session), the URL is printed so you can copy-paste it into any browser.

oblien auth

Full auth subcommands:

# Log in via browser
oblien auth login

# Check current auth status
oblien auth status

# Remove stored credentials
oblien auth logout

oblien auth status

Shows whether you're logged in and which credentials are in use:

oblien auth status
# Logged in
# Client ID:  obl_abc123def456…
# Config:     /home/user/.oblien/credentials.json

oblien auth logout

Removes stored credentials:

oblien auth logout
# ✓ Logged out. Credentials removed.

This is equivalent to oblien logout.

oblien logout

Top-level shortcut for oblien auth logout:

oblien logout

Manual authentication

If you already have API credentials (from the dashboard), you can set them directly:

oblien config set --client-id <id> --client-secret <secret>

Or use environment variables:

export OBLIEN_CLIENT_ID=your-client-id
export OBLIEN_CLIENT_SECRET=your-client-secret

Credential priority

Credentials are resolved in this order (first match wins):

PrioritySourceHow to set
1CLI flags--client-id <id> --client-secret <s>
2Environment variablesOBLIEN_CLIENT_ID + OBLIEN_CLIENT_SECRET
3Config fileoblien login or oblien config set

MCP server auth

The MCP server (oblien-mcp) uses the exact same credential resolution, so oblien login is sufficient to authenticate both the CLI and MCP:

{
  "mcpServers": {
    "oblien": {
      "command": "npx",
      "args": ["oblien-mcp"]
    }
  }
}

No extra configuration needed — it reads from ~/.oblien/credentials.json.