Droid Configuration - Lessons Learned
Overview
Configuration of Factory Droid to work with Claude Max, Codex, and Antigravity models via CLIProxyAPI.
Key Lessons
1. Port Configuration
- CLIProxyAPI runs on port 8317 (not 8318)
- Initially configured port 8317 correctly, then accidentally changed to 8318
- Always verify which port the proxy server is actually listening on using
lsof -i :<port>
2. Model Discovery
- CLIProxyAPI provides a
/v1/modelsendpoint to list all available models - Use
curl http://127.0.0.1:8317/v1/models | jqto see all available models - Not all models listed in the API work with authentication
3. Authentication Methods
- Claude: Uses
/v1/messagesendpoint withx-api-keyheader and dummy key - GPT/Codex/Gemini: Uses
/v1/chat/completionsendpoint withAuthorization: Bearerheader and dummy key - CLIProxyAPI handles OAuth token management automatically when configured with
--claude-loginor similar auth commands
4. Model Testing Strategy
Test models individually before adding to config:
# Claude models
# GPT/Codex/Gemini models
5. Working Models (as of 2026-01-01)
Claude Models (Anthropic)
claude-opus-4-5-20251101βclaude-sonnet-4-5-20250929βclaude-haiku-4-5-20251001βclaude-3-7-sonnet-20250219βclaude-opus-4-1-20250805β
GPT/Codex Models (OpenAI)
gpt-5.2βgpt-5.2-codexβgpt-5.1-codex-maxβgpt-5-codex-miniβgpt-5-miniβgpt-4.1β
Gemini/Antigravity Models
gemini-2.5-flashβgemini-claude-opus-4-5-thinkingβ
Other Models
grok-code-fast-1β
6. Non-Working Models
antigravity-1β Unknown provider (token exists but not mapped)antigravity-1-previewβ Unknown providergemini-3-proβ Model not supportedraptor-miniβ Model not supported- All
-high,-medium,-lowvariants β Unknown provider
7. Droid Configuration File
Location: ~/.factory/config.json
Example configuration:
Important notes:
- Claude models use provider
"anthropic"without/v1in base_url - All other models use provider
"openai"with/v1in base_url api_keyis required by Factory but ignored by CLIProxyAPI (use"sk-dummy")- Validate JSON with
python3 -m json.tool ~/.factory/config.json
8. Common Issues
Issue: Models not showing in Droid
Solution: Restart Droid completely (not just tmux session). Droid caches config on startup.
Issue: "402 status code (no body)" error
Solution: This is a Factory billing error, not a configuration issue. Check your Factory.ai subscription.
Issue: "Unknown provider for model" error
Solution: The model name is not mapped to a provider in CLIProxyAPI authentication. Check available models via /v1/models endpoint.
Issue: "OAuth token has expired" error
Solution: Re-authenticate with CLIProxyAPI:
9. Testing Workflow
- List available models from API
- Test each model individually via curl
- Add only working models to config.json
- Validate JSON syntax
- Restart Droid completely
- Use
/modelcommand to select model in Droid
10. CLIProxyAPI Management
- Process name:
cli-proxy-api-plus - Running from:
/Applications/VibeProxy.app/Contents/Resources/ - Auth tokens stored in:
~/.cli-proxy-api/ - Config file:
/Applications/VibeProxy.app/Contents/Resources/config.yaml
View running processes:
|
Verification Commands
# Check proxy is running
# List all available models
|
# Validate config JSON
# Test a model
References
- CLIProxyAPI GitHub: https://github.com/luispater/CLIProxyAPI
- Factory Droid: https://factory.ai/
- VibeProxy (CLIProxyAPI wrapper): /Applications/VibeProxy.app/