Back to blog
SetupJanuary 18, 2026

Connect Claude Code to Custom Endpoint

How to configure Claude Code to use the EcomAgent custom API endpoint.

The Configuration

Add this to your ~/.claude/settings.json (or %USERPROFILE%\.claude\settings.json on Windows):

{
  "env": {
    "ANTHROPIC_BASE_URL": "https://api.ecomagent.in/",
    "ANTHROPIC_AUTH_TOKEN": "YOUR_API_KEY"
  }
}

Why Custom Endpoints?

Custom endpoints let you route Claude traffic through optimized infrastructure with better pricing and unlimited token capacity.