---
title: "Add AI Provider"
method: POST
path: "/ai/providers"
tags: ["AI"]
---

# Add AI Provider

`POST /ai/providers`

## Request

- Base URL: `https://api.crowdin.com/api/v2`
- URL: `https://api.crowdin.com/api/v2/ai/providers`
- Auth: none declared
- TypeScript: <https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2/docs/ai/providers/post.ts> (a function with typed inputs; its response is checked against the schema)

**Required scopes:** `ai.provider` (Read and Write).

## Request body

- EnterpriseAiProviderCreateForm
  - `name` string, required: AI provider name
  - `type` 'open_ai' | 'azure_open_ai' | 'google_gemini' | 'google_gemini_ai_studio' | 'mistral_ai' | 'anthropic' | 'x_ai' | 'watsonx' | 'deepseek' | 'microsoft_foundry' | 'custom_ai', required: AI provider type
  - `credentials` union: User’s own AI provider credentials. __Note__: Use only if `useSystemCredentials` is set to false.
    - AiProviderCredentialsOpenAi
      - `apiKey` string, required: Api key
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsAzureOpenAi
      - `resourceName` string, required: Resource name
      - `apiKey` string, required: Api key
      - `deploymentName` string, required: Deployment name
      - `apiVersion` string, required: Api version
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`api-key`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsGoogleGemini
      - `project` string, required: Project
      - `region` string, required: Region
      - `serviceAccountKey` object: Service account key. Required if `workloadIdentityFederationAudience` is not provided.
      - `workloadIdentityFederationAudience` string: Workload Identity Federation audience. Required if `serviceAccountKey` is not provided.
      - `serviceAccountEmail` string: Optional service account email to impersonate when using Workload Identity Federation.
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header. Can't be used with `workloadIdentityFederationAudience`
    - AiProviderCredentialsGoogleGeminiAiStudio
      - `apiKey` string, required: API key from Google AI Studio
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`x-goog-api-key`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsMistralAi
      - `apiKey` string, required: Api key
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`, `Accept`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsAnthropic
      - `apiKey` string, required: Api key
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`x-api-key`, `anthropic-version`, `accept`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsXAi
      - `apiKey` string, required: Api key
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsWatsonx
      - `apiKey` string, required: API key
      - `projectId` string, required: Project ID
      - `region` string, required: Region
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsDeepseek
      - `apiKey` string, required: API key
      - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsMicrosoftFoundry
      - `deployments` object[], required: Deployed models of the Foundry project. Each entry is self-contained — copy its Target URI and API key from the deployment details page in the Foundry portal (deployments of one project may live on different connected Azure resources)
        - `deploymentName` string, required: Deployment name (used as the model id)
        - `targetUri` string, required: Deployment Target URI (its path encodes the API the deployment is served by, e.g. /anthropic/v1/messages or /openai/v1/chat/completions)
        - `apiKey` string, required: API key of the Azure resource hosting the deployment
      - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
      - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`api-key` on the OpenAI route, `x-api-key`, `anthropic-version` and `accept` on the Anthropic route) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
    - AiProviderCredentialsCustomAi
      - `identifier` string, required: Crowdin App identifier
      - `key` string, required: AI Provider module key
  - `config` object: AI provider configuration
    - `actionRules` AiProviderEnterpriseConfigurationActionRule[]: Configuration of available models for actions
      - `action` 'pre_translate' | 'alignment' | 'qa_check'
      - `availableAiModelIds` string[]: Available AI provider model ids. Get via [List AI Provider Models](#operation/api.ai.providers.models.getMany)
  - `isEnabled` boolean: Defines whether to AI provider is enabled.
  - `useSystemCredentials` boolean: Enables the paid service AI provider via Crowdin. __Note__: Set to true if `credentials` is not provided. Not supported for `custom_ai`, `x_ai`, `watsonx`, `deepseek`, `microsoft_foundry` and `google_gemini_ai_studio` types.

## Response `201`

AI provider was successfully added

- EnterpriseAiProviderResource: Base schema of resource container. Container is a wrapper object that contains payload in required `data` property and provides space for adding any other metadata.
  - `data` EnterpriseAiProvider, required
    - `id` integer
    - `name` string
    - `type` string
    - `credentials` union
      - object
        - `apiKey` string, required: Api key
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `resourceName` string, required: Resource name
        - `apiKey` string, required: Api key
        - `deploymentName` string, required: Deployment name
        - `apiVersion` string, required: Api version
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`api-key`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `project` string, required: Project
        - `region` string, required: Region
        - `serviceAccountKey` object: Service account key. Required if `workloadIdentityFederationAudience` is not provided.
        - `workloadIdentityFederationAudience` string: Workload Identity Federation audience. Required if `serviceAccountKey` is not provided.
        - `serviceAccountEmail` string: Optional service account email to impersonate when using Workload Identity Federation.
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header. Can't be used with `workloadIdentityFederationAudience`
      - object
        - `apiKey` string, required: Api key
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`, `Accept`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `apiKey` string, required: Api key
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`x-api-key`, `anthropic-version`, `accept`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `apiKey` string, required: Api key
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `apiKey` string, required: API key
        - `projectId` string, required: Project ID
        - `region` string, required: Region
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `apiKey` string, required: API key
        - `baseUrl` string: Override the provider API base URL (e.g. a self-hosted proxy or third-party gateway)
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`Authorization`) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `deployments` object[], required: Deployed models of the Foundry project. Each entry is self-contained — copy its Target URI and API key from the deployment details page in the Foundry portal (deployments of one project may live on different connected Azure resources)
          - `deploymentName` string, required: Deployment name (used as the model id)
          - `targetUri` string, required: Deployment Target URI (its path encodes the API the deployment is served by, e.g. /anthropic/v1/messages or /openai/v1/chat/completions)
          - `apiKey` string, required: API key of the Azure resource hosting the deployment
        - `headers` object: Custom HTTP headers sent with every request to the provider. Authorization headers are managed by the provider and can't be overridden unless `sendCustomHeadersOnly` is `true`.
        - `sendCustomHeadersOnly` boolean: If `true`, only the headers from `headers` are sent — the headers Crowdin manages for this provider (`api-key` on the OpenAI route, `x-api-key`, `anthropic-version` and `accept` on the Anthropic route) are skipped, so the request must carry everything the endpoint requires. Default is `false`. __Note:__ Can only be set to `true` when `headers` contains at least one header
      - object
        - `identifier` string, required: Crowdin App identifier
        - `key` string, required: AI Provider module key
    - `config` object: AI provider configuration
      - `actionRules` AiProviderEnterpriseConfigurationActionRule[]: Configuration of available models for actions
        - `action` 'pre_translate' | 'alignment' | 'qa_check'
        - `availableAiModelIds` string[]: Available AI provider model ids. Get via [List AI Provider Models](#operation/api.ai.providers.models.getMany)
    - `isEnabled` boolean
    - `useSystemCredentials` boolean
    - `createdAt` string, date-time
    - `updatedAt` string, date-time
    - `promptsCount` number

## Other responses

- `400`: Invalid Request Parameters
- `401`: Unauthorized
- `403`: Forbidden
- `405`: Method Not Allowed

---

[API](https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2.md) - [All operations](https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2/llms.txt) - [OpenAPI document](https://skmtc.dev/crowdin/apis/crowdin-enterprise-api-v2/revisions/dc68744c5384?raw)
