Want instructions for a specific coding agent?
Log in to app.ngrok.ai, click Give feedback, and let the team know which one.
What you’ll need
- A coding agent that accepts a custom base URL and API key.
- An access key from app.ngrok.ai.
Connect your agent
Every agent needs the same three values:
Anthropic-format agents append
/v1/messages to the base URL themselves, so leave /v1 off for those.
Agents that fill their model picker from GET /v1/models see the models your access key is allowed to call, listed by full catalog ID such as openai/gpt-5.5.
Those IDs work as the model value, too.
The list also includes your virtual models, with owned_by set to virtual-model.
Pick an API format
The gateway serves these endpoints, so an agent can use whichever format it speaks:Each endpoint also reaches models that use other API formats.
The gateway translates the request and returns the response in the agent’s format.
See Use any model with any SDK for what translates.
Authorization: Bearer and x-api-key headers, so you don’t need to match the header your agent sends.
Test the connection
Send a prompt from the agent, then confirm the request in AI Gateway observability in app.ngrok.ai. If the agent reports an error, check Debugging and the error codes reference.Next steps
- Use with other SDKs: Raw HTTP examples for each API format
- Use a model you run yourself: Reach a model on your own machine, such as Ollama or vLLM
- Restrict providers and models: Scope what an access key can call