Installation
pip install foxreach-cli
Setup
# Save your API key
foxreach config set-key
# Enter: otr_your_api_key
# Verify configuration
foxreach config show
export FOXREACH_API_KEY=otr_your_api_key
export FOXREACH_BASE_URL=https://api.foxreach.io/api/v1 # optional
Commands
Leads
# List leads (with optional filters)
foxreach leads list
foxreach leads list --search "jane" --status active --limit 25
# Get a single lead
foxreach leads get cld_abc123
# Create a lead
foxreach leads create --email [email protected] --first-name Jane --last-name Smith --company "Acme"
# Update a lead
foxreach leads update cld_abc123 --company "New Corp" --title "VP Sales"
# Delete a lead
foxreach leads delete cld_abc123
# Get lead activity and campaign memberships
foxreach leads activity cld_abc123
Campaigns
# List campaigns
foxreach campaigns list
foxreach campaigns list --status active
# Get campaign details
foxreach campaigns get cmp_xyz789
# Create a campaign
foxreach campaigns create --name "Q1 Outreach" --daily-limit 100 --timezone "America/New_York"
# Update a campaign
foxreach campaigns update cmp_xyz789 --daily-limit 200
# Start / pause / resume
foxreach campaigns start cmp_xyz789
foxreach campaigns pause cmp_xyz789
foxreach campaigns resume cmp_xyz789
# Add leads and email accounts
foxreach campaigns add-leads cmp_xyz789 --lead-ids cld_1,cld_2,cld_3
foxreach campaigns add-accounts cmp_xyz789 --account-ids acc_1
# Remove leads and accounts (campaign must not be active)
foxreach campaigns remove-lead cmp_xyz789 --lead-id cld_1
foxreach campaigns remove-account cmp_xyz789 --account-id acc_1
# Delete (must be draft)
foxreach campaigns delete cmp_xyz789
Sequences
# List steps for a campaign
foxreach sequences list --campaign cmp_xyz789
# Add a step
foxreach sequences create --campaign cmp_xyz789 \
--subject "Quick question about {{company}}" \
--body "Hi {{firstName}}, ..." \
--delay-days 0
# Update a step
foxreach sequences update --campaign cmp_xyz789 --sequence seq_1 --delay-days 3
# Delete a step
foxreach sequences delete --campaign cmp_xyz789 --sequence seq_1
Templates
foxreach templates list
foxreach templates get tpl_abc123
foxreach templates create --name "Cold Intro" --body "Hi {{firstName}}, just checking in."
foxreach templates update tpl_abc123 --name "Updated Follow-up"
foxreach templates delete tpl_abc123
Email Accounts
foxreach accounts list
foxreach accounts get acc_abc123
foxreach accounts delete acc_abc123
Inbox
# List threads
foxreach inbox list
foxreach inbox list --unread --category interested
# Get a thread
foxreach inbox get rpl_abc123
# Get the full conversation (all messages in a thread)
foxreach inbox conversation rpl_abc123
# Send a reply
foxreach inbox reply rpl_abc123 --body "Thanks for your interest! Let's schedule a call."
foxreach inbox reply rpl_abc123 --body "Follow-up" --subject "Re: Custom subject"
# Update (mark read, categorize, star)
foxreach inbox update rpl_abc123 --read --category qualified --starred
# Get inbox stats (counts by category)
foxreach inbox stats
Webhooks
# List available event types
foxreach webhooks events
# List webhooks
foxreach webhooks list
# Create a webhook (secret is shown once on creation — save it!)
foxreach webhooks create --url "https://your-app.com/webhooks" --events email.sent,reply.received,campaign.completed
# Update a webhook
foxreach webhooks update cwh_abc123 --events email.sent,lead.created --active
# Disable a webhook
foxreach webhooks update cwh_abc123 --inactive
# Delete a webhook
foxreach webhooks delete cwh_abc123
Analytics
# Dashboard overview
foxreach analytics overview
# Campaign stats
foxreach analytics campaign cmp_xyz789
JSON Output
Add--json to any command to get raw JSON output, useful for scripting and piping:
foxreach leads list --json | jq '.data[].email'
foxreach campaigns get cmp_xyz789 --json
foxreach analytics overview --json
Configuration
Config is stored at~/.foxreach/config.json:
{
"api_key": "otr_your_api_key",
"base_url": "https://api.foxreach.io/api/v1"
}
| Setting | Env Var | Config Key |
|---|---|---|
| API Key | FOXREACH_API_KEY | api_key |
| Base URL | FOXREACH_BASE_URL | base_url |
Config Commands
foxreach config set-key # Prompts for API key
foxreach config set-url <url> # Override base URL
foxreach config show # Show current config (key masked)
Source Code
- GitHub: foxreach/foxreach-cli
- PyPI:
pip install foxreach-cli