> For the complete documentation index, see [llms.txt](https://docs.cortecs.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cortecs.ai/web-console/bring-your-own-key.md).

# Bring Your Own Key \[BETA]

Bring your own provider API keys

BYOK lets you connect your own provider credentials to Cortecs, allowing requests to be routed through your own provider account.

When BYOK is enabled for a provider, Cortecs can use your API key either before or after the Cortecs-managed endpoints, depending on the selected usage mode. This gives you more control over provider billing and quota while still using Cortecs routing, model selection, and API interface.

{% hint style="info" %}
**BETA NOTICE:**

BYOK is currently in beta. For requests served using your own provider key, EUR spend tracking and EUR budget enforcement are currently unavailable. The Activity view records token usage only and does not report EUR spend. Cortecs EUR [budget limits](https://docs.cortecs.ai/web-console/budgets) therefore do not cap spending incurred through your BYOK provider account.
{% endhint %}

### Adding a Provider Key

To add your own provider key:

1. Go to [**Settings**](https://cortecs.ai/userArea/console)
2. Select the [**BYOK**](https://cortecs.ai/userArea/console?tab=byok) tab
3. Click **Add provider key**
4. Select the provider
5. Enter the required credential fields
6. Choose a usage mode
7. Click **Save**

Only project administrators can add, update, or delete provider keys.

### BYOK Usage Modes

Cortecs supports two BYOK modes:

<table><thead><tr><th>Mode</th><th width="187">Behavior</th><th>Platform Key Used?</th><th>Balance Check</th></tr></thead><tbody><tr><td><strong>Prefer my key</strong></td><td>Cortecs tries your provider key first. If the request fails, Cortecs retries using the Cortecs-managed endpoints.</td><td>Yes, as backup</td><td>Required</td></tr><tr><td><strong>Fallback to my key</strong></td><td>Cortecs first tries its managed endpoints. If those endpoints fail, Cortecs retries the request using your provider key.</td><td>Yes, first</td><td>Required</td></tr></tbody></table>

### Billing

{% hint style="info" %}
Cortecs currently charges no usage fee for requests served using your own provider key. Your provider’s charges still apply. Cortecs may introduce BYOK fees in the future with advance notice. This fee exemption applies only to requests served using your own key, including when BYOK is configured as a fallback.
{% endhint %}

### BYOK Responsibility

Cortecs’ [Inference Settings](https://docs.cortecs.ai/web-console/inference-settings) do not configure or enforce these safeguards in your BYOK provider account. For requests served using your own provider key, you must independently establish and verify the required safeguards directly with your provider. You are solely responsible for selecting your provider, managing provider charges, and verifying and maintaining the provider-side agreements and settings required for your use, including, but not limited to, data sovereignty, processing location, zero data retention, restrictions on model training, security, and regulatory compliance.

### Supported Providers

#### Providers Requiring Only an API Key

For the following providers, you only need to provide the provider API key:

* Mistral
* OVH
* Nebius
* Tensorix
* Inceptron
* Infercom
* Ionos
* Scaleway
* AKI
* Berget
* Entrim

#### Amazon Bedrock

Cortecs currently supports Bedrock API keys for BYOK. AWS key authentication is not supported yet for BYOK, but may be added in the future.

#### Google Vertex AI

For Google Vertex AI, you need to provide a **Google service account JSON** file. You can download this file from the *Google Cloud Console*.

{% hint style="warning" %}
Ensure the service account has permission to access Vertex AI and the models you intend to use.
{% endhint %}

You do not need to specify a region. Cortecs automatically routes through supported EU regions. Ensure the models you plan to use are enabled in the appropriate EU regions of your Google Cloud project.

#### Azure OpenAI

Cortecs currently supports Azure OpenAI resources for BYOK using:

```
*.openai.azure.com
```

You need to provide:

* Resource name
* API key
* API version, optional

Cortecs automatically constructs the Azure endpoint from the resource name.

Example:

```
Resource name: my-azure-resource
Endpoint used: https://my-azure-resource.openai.azure.com
```

{% hint style="warning" %}
Azure OpenAI requires explicit model deployments. The deployment name in your Azure resource must match the Cortecs model ID you are requesting.
{% endhint %}

{% hint style="info" %}
More advanced BYOK configuration options will be added over time based on user needs.
{% endhint %}
