Skip to main content

Overview

ARouter supports both platform credits and the option to bring your own provider keys (BYOK). When you use your own keys, requests are routed through your provider account while keeping all ARouter features — unified API, failover, analytics, and spend controls. Your provider keys are securely encrypted and automatically prioritized for routing. No code changes needed — just add your keys in the dashboard and your existing ARouter API key works as before.

How It Works

  1. Add your provider API key in Settings → Integrations.
  2. ARouter automatically uses your key for that provider.
  3. If your key is unavailable, ARouter can fall back to platform keys (configurable).
  4. Usage is tracked separately: BYOK vs. platform.

Supported Providers

ARouter supports BYOK for any provider with one of these credential types:

Adding a BYOK Key

Dashboard

  1. Go to Settings → Integrations.
  2. Click Add Provider Key.
  3. Select your provider and credential type.
  4. Enter your key/credentials.
  5. (Optional) Click Test Key to verify it works.
  6. Click Save.

Advanced Options

When adding a key, you can configure:

Fallback Behavior

By default, if your BYOK key encounters a rate limit or error, ARouter falls back to platform keys seamlessly. You can change this per key: Enable “Always use this key” in the dashboard to set deny fallback.

Multiple Keys

You can add multiple BYOK keys for the same provider. ARouter uses weighted random selection across all available keys. Configure the weight field to control traffic distribution.

BYOK Usage Tracking

BYOK requests are tracked separately in your usage dashboard:
  • BYOK Requests — number of requests using your keys
  • Estimated BYOK Spend — estimated cost based on provider pricing
  • Platform Spend — cost of requests using platform keys
The per-model usage table shows a Source column indicating whether each model’s requests came from BYOK, platform, or a mix.

Azure Configuration

For Azure OpenAI, provide your key configuration as JSON:

AWS Bedrock Configuration

For AWS Bedrock, provide your AWS credentials:

Google Vertex AI Configuration

For Vertex AI, provide your service account credentials:

Debugging BYOK Issues

If BYOK requests fail:
  1. Go to Settings → Integrations and check the key health status.
  2. Click the key to see the last error message.
  3. Use the Test Key button to verify the key is still valid.
  4. Check the Usage page for BYOK-specific error rates.
Common issues: