mirror of
https://github.com/NousResearch/hermes-agent.git
synced 2026-04-28 06:51:16 +08:00
The Anthropic provider entry in PROVIDER_REGISTRY is the only standard API-key provider missing a base_url_env_var. This causes the credential pool to hardcode base_url to https://api.anthropic.com, ignoring ANTHROPIC_BASE_URL from the environment. When using a proxy (e.g. LiteLLM, custom gateway), subagent delegation fails with 401 because: 1. _seed_from_env() creates pool entries with the hardcoded base_url 2. On error recovery, _swap_credential() overwrites the child agent's proxy URL with the pool entry's api.anthropic.com 3. The proxy API key is sent to real Anthropic → authentication_error Adding base_url_env_var="ANTHROPIC_BASE_URL" aligns Anthropic with the 20+ other providers that already have this field set (alibaba, gemini, deepseek, xai, etc.).
132 KiB
132 KiB