Hey, this is a known issue. Sub-agents currently don’t inherit the custom OpenAI base URL and BYOK credentials. The main agent correctly uses your LiteLLM gateway, but sub-agents fall back to Cursor servers, which triggers resource_exhausted.
So your analysis is right. Cursor isn’t sending requests to your endpoint for sub-agent calls.
There are already threads about the same bug:
- Sub-agents are not using custom OpenAI base URLs
- Subagents ignore user's own API key. Always bill against Cursor plan
Sadly, there’s no workaround yet. The team is aware, and your report helps with prioritization. I’ll update the thread once there’s progress.