Skip to main content

Command

sb0 login

Description

Authenticates your CLI with the sb0 platform. Required before you can push agents or query deployed agents.

Usage

sb0 login
This will open your browser to complete authentication, or provide a link if the browser doesn’t open automatically.

Expected Flow

Opening browser for authentication...
Waiting for authentication to complete...
✔ Successfully authenticated!

Your credentials have been saved locally.

When to Login

You need to login:
  • Before first push - To deploy agents to the platform
  • Before querying - To access your deployed agents
  • After logout - If you previously logged out
  • New machine - When setting up on a new computer
You do NOT need to login for:
  • Local development - Using sb0 init, sb0 run, sb0 build
  • Reading documentation - Accessing public resources

Credentials Storage

Authentication credentials are stored locally in:
~/.sb0/credentials
These credentials are used automatically for sb0 push and sb0 query commands.
Keep your credentials secure. Don’t share them or commit them to version control.

Session Duration

Sessions remain active until you explicitly logout or the token expires.

Logout

To logout and remove stored credentials:
sb0 logout

Common Issues

Browser Doesn’t Open

If the browser doesn’t open automatically, copy the URL from the terminal and paste it into your browser manually.

Authentication Fails

Error: Authentication failed
Possible solutions:
  • Check your network connection
  • Ensure you’re using the latest version of the CLI
  • Try logging out and logging in again

Permission Denied

Error: Could not write credentials
Solution: Ensure you have write permissions to ~/.sb0/ directory:
mkdir -p ~/.sb0
chmod 700 ~/.sb0

Next Steps

After logging in:
  1. Build your agent:
    sb0 build
    
  2. Push to platform:
    sb0 push
    
  3. Query your agent:
    sb0 query "test question"