How routing works
AgentKey maintains a live view of every upstream provider’s health and uses it to decide where each call is sent. Within a capability — web search, for example — multiple providers are registered behind the same interface. At any moment, one is active and the others are on standby, ready to take over.find_tools("web search") resolves to a web-search tool regardless of which provider is active — stays the same. The routing change is invisible at the interface level: your agent sends the same call and receives the same response envelope regardless of which provider handled it underneath.
What this means for you
- No code changes — failover is handled entirely at the routing layer inside AgentKey. You do not need to implement retry logic, circuit breakers, or provider fallback in your own code.
- One stable interface — your agent calls a capability, not a specific vendor. Adding or swapping out a backup provider behind the scenes never affects how your agent interacts with AgentKey.
- Higher uptime — a single provider’s outage no longer breaks your agent or your users’ experience. As long as at least one provider for a capability is healthy, calls continue to succeed.
Check Upstream Health
Call
execute_tool("agentkey_account") — always free — to get your remaining credits and the current health status of every upstream provider. Useful for diagnosing issues or confirming routing status before a critical task.