Integrate Portkey with Claude Code for enterprise-grade AI coding assistance with observability and governance
Create Virtual Key
Create Config (Optional)
Get Your Portkey API Key
settings.json
file for configuration. You’ll need to modify the environment variables to route requests through Portkey.
~/.claude/settings.json
for global or .claude/settings.json
in your project):CLAUDE_CODE_SKIP_BEDROCK_AUTH
and CLAUDE_CODE_USE_BEDROCK
must be set as numbers (not strings).YOUR_PORTKEY_API_KEY
with your Portkey API keyYOUR_VIRTUAL_KEY
with the virtual key ID from Step 1settings.json
example with permissions and Bedrock configuration:
Team-Based Access Control
settings.json
through your configuration management:Centralized Policy Management
/Library/Application Support/ClaudeCode/policies.json
Linux/WSL: /etc/claude-code/policies.json
Example policy file:Usage Monitoring & Alerts