- Access 600+ models from OpenAI, Anthropic, Google, Mistral, and many other providers through one API key.
- Get automatic prompt caching on Anthropic models, reducing cost significantly on multi-turn conversations.
- Track and manage your spend in a single location.
- Apply fallback policies, load balancing, and latency routing to keep your agent responsive.
Prerequisites
- Pi installed on your machine. See pi.dev for installation instructions.
- A Requesty API key from the API Keys page.
Configuration
1
Install Pi
Follow the instructions at pi.dev to download and install Pi on your machine.
2
Install the Requesty extension
pi update --extensions and restart Pi.3
Add your API key
Store the key in Pi’s credentials file, Get a key from the API Keys page. With the environment variable option, export
~/.pi/agent/auth.json. The key value can point at an environment variable, run a command that prints the key, or be the key itself:REQUESTY_API_KEY in the shell that starts Pi. A !command runs in your shell and can be any password manager CLI; it runs twice when Pi starts, so some password managers ask twice.Keys in
~/.pi/agent/models.json (providers.requesty.apiKey) still work. When both files hold a key, auth.json wins. If you set PI_CODING_AGENT_DIR, both files are read from that folder instead of ~/.pi/agent.4
Start Pi
Selecting a model
Run/model inside Pi and type requesty to filter the list to Requesty models. You can also pick one when starting Pi:
- Discrete models, e.g.
anthropic/claude-opus-4-7. - Your organization’s policies, e.g.
policy/opus-europe. - Managed models, e.g.
gpt-6.1-terra, including@euvariants.
The extension sends
HTTP-Referer: https://pi.dev and X-Title: Pi with every request. The referer is what enables Requesty’s automatic prompt caching for Pi: on Anthropic models Requesty injects cache-control breakpoints so Pi’s large system prompt and tool definitions are reused across turns, cutting cost by up to 90% on long conversations. See Auto-Caching for details.Optional settings
To change the provider settings, add arequesty entry to ~/.pi/agent/models.json. Every field is optional; these are the defaults:
models.json, for example to keep it when Requesty can’t be reached, run /requesty-models-sync inside Pi and then /reload. The command keeps the file private to your user and never copies a key from auth.json into it.
Troubleshooting
startup discovery failed: HTTP 403 Forbidden: the key is wrong or revoked. Pi still starts, but without the Requesty model list.- No Requesty models in
/model: the extension found no key. Check thatauth.jsonis in~/.pi/agent(or inPI_CODING_AGENT_DIR), and thatREQUESTY_API_KEYis exported if you used$REQUESTY_API_KEY.