Quick Start

Prerequisites

Create an Identity

ravi identity create --name "my-agent" --json

This provisions:

  • A unique email address (e.g. my-agent@in.ravi.app)
  • A phone number for SMS
  • An empty credential vault

Set the active Identity

ravi identity use my-agent

All subsequent commands operate against this Identity.

Get your Identity details

# Get your agent's email address
ravi get email --json

# Get your agent's phone number
ravi get phone --json

Sign up for a service

Here’s a typical agent workflow — signing up for a service, receiving a verification code, and storing credentials:

# 1. Get your email and phone
EMAIL=$(ravi get email --json | jq -r '.email')
PHONE=$(ravi get phone --json | jq -r '.phone_number')

# 2. Generate and store credentials
CREDS=$(ravi passwords create example.com --username "$EMAIL" --json)
PASSWORD=$(echo "$CREDS" | jq -r '.password')

# 3. Use $EMAIL, $PHONE, and $PASSWORD to fill the signup form

# 4. Wait for verification code
sleep 5

# 5. Check for SMS OTP
ravi inbox sms --unread --json | jq -r '.[].preview'

# 6. Or check for email verification
THREAD_ID=$(ravi inbox email --unread --json | jq -r '.[0].thread_id')
ravi inbox email "$THREAD_ID" --json | jq -r '.messages[].text_content'

Check your inbox

# All messages (SMS + email combined)
ravi inbox list --json

# Unread SMS only
ravi inbox sms --unread --json

# Unread email only
ravi inbox email --unread --json

Send an email

ravi email compose \
  --to "recipient@example.com" \
  --subject "Hello from my agent" \
  --body "<p>This email was sent by an AI agent using Ravi.</p>" \
  --json

Store a secret

# Store an API key
ravi secrets set OPENAI_API_KEY "sk-abc123..." --json

# Retrieve it later
ravi secrets get OPENAI_API_KEY --json | jq -r '.value'

Key conventions

  • Always use --json — all commands support it. JSON output is stable and designed for programmatic parsing.
  • Pipe through jq — extract specific fields from JSON responses.
  • Poll with delays — SMS and email delivery takes 2–10 seconds. Use sleep 5 before checking the inbox after triggering a verification.

Next steps