> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://contentful.com/developers/docs/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://contentful.com/developers/docs/_mcp/server.

AI Providers allow organizations to configure their own AI service credentials for use with Contentful's AI features. You can use your own accounts with: OpenAI, AWS Bedrock, Google Gemini, and Google Vertex AI.

Each provider requires specific credentials and configuration based on the AI service being used. Once configured, providers can be used to power AI Actions.

#### Supported Provider Types

| Provider          | Type                | Credentials                             | Config                                                   |
| ----------------- | ------------------- | --------------------------------------- | -------------------------------------------------------- |
| AWS Bedrock       | `aws_bedrock`       | AWS access key ID and secret access key | AWS region (e.g., `us-east-1`)                           |
| Google Gemini     | `google-gemini`     | API key                                 | None required                                            |
| Google Vertex AI  | `google-vertex-ai`  | Full GCP service account JSON file      | GCP location/region (e.g., `us-central1`)                |
| OpenAI            | `openai`            | API key                                 | OpenAI organization ID and project ID                    |
| OpenAI-Compatible | `openai-compatible` | API key                                 | Provider name, endpoint URL, and optional custom headers |

## AI Providers collection

[Get all AI providers for an organization](/references/content-management-api/ai-providers/get-all-ai-providers-for-an-organization)

Returns all the AI Providers that exist in a given organization.

[Create an AI provider](/references/content-management-api/ai-providers/create-an-ai-provider)

Use this endpoint to create a new AI Provider of a specified type for an organization. Specify the appropriate type and credentials in the request body for the provider, see examples:

**AWS Bedrock**: Create an AWS Bedrock provider with access credentials

```
{
  "type": "aws_bedrock",
  "credentials": {
    "accessKeyId": "AKIAIOSFODNN7EXAMPLE",
    "secretAccessKey": "wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY"
  },
  "config": {
    "region": "us-east-1"
  },
  "selectedModels": [
    {
      "id": "anthropic.claude-3-5-sonnet-20241022-v2:0",
      "name": "Claude 3.5 Sonnet v2"
    },
    {
      "id": "anthropic.claude-3-sonnet-20240229-v1:0",
      "name": "Claude 3 Sonnet"
    }
  ]
}
```

**Google Gemini**: Create a Google Gemini provider with API key credentials

```
{
  "type": "google-gemini",
  "credentials": {
    "apiKey": "your-google-api-key"
  },
  "selectedModels": [
    {
      "id": "gemini-2.0-flash-exp",
      "name": "Gemini 2.0 Flash"
    },
    {
      "id": "gemini-1.5-pro",
      "name": "Gemini 1.5 Pro"
    }
  ]
}
```

**Google Vertex AI**: Create a Google Vertex AI provider with GCP service account credentials

```
{
  "type": "google-vertex-ai",
  "credentials": {
    "type": "service_account",
    "project_id": "your-project-id",
    "private_key_id": "key-id",
    "private_key": "-----BEGIN PRIVATE KEY-----\\n...\\n-----END PRIVATE KEY-----\\n",
    "client_email": "service-account@project.iam.gserviceaccount.com",
    "client_id": "123456789",
    "auth_uri": "https://accounts.google.com/o/oauth2/auth",
    "token_uri": "https://oauth2.googleapis.com/token",
    "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs",
    "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/service-account%40project.iam.gserviceaccount.com"
  },
  "config": {
    "location": "us-central1"
  },
  "selectedModels": [
    {
      "id": "gemini-2.0-flash-exp",
      "name": "Gemini 2.0 Flash"
    },
    {
      "id": "gemini-1.5-pro",
      "name": "Gemini 1.5 Pro"
    }
  ]
}
```

**OpenAI**: Create an OpenAI provider with API key and organization credentials

```
{
  "type": "openai",
  "credentials": {
    "apiKey": "sk-..."
  },
  "config": {
    "openAiOrganizationId": "org-...",
    "projectId": "proj_..."
  },
  "selectedModels": [
    {
      "id": "gpt-4o",
      "name": "GPT-4o"
    },
    {
      "id": "gpt-4",
      "name": "GPT-4"
    }
  ]
}
```

**OpenAI Compatible**: Create an OpenAI-compatible provider with custom endpoint configuration

```
{
  "type": "openai-compatible",
  "credentials": {
    "apiKey": "your-api-key"
  },
  "config": {
    "name": "My Custom Provider",
    "endpoint": "https://api.example.com/v1",
    "headers": {
      "x-custom-header": "value"
    }
  },
  "selectedModels": [
    {
      "id": "custom-model-v1",
      "name": "Custom Model v1"
    },
    {
      "id": "custom-model-v2",
      "name": "Custom Model v2"
    }
  ]
}
```

## AI Provider

[Get an AI provider](/references/content-management-api/ai-providers/get-an-ai-provider)

Use this endpoint to read an AI Provider for a specified organization.

[Update an AI provider](/references/content-management-api/ai-providers/update-an-ai-provider)

Use this endpoint to update a specific AI provider using [JSON Patch](http://jsonpatch.com/) format. This is useful for updating credentials, configuration, or selected models without replacing the entire provider configuration.

[Delete an AI provider](/references/content-management-api/ai-providers/delete-an-ai-provider)

Use this endpoint to delete an AI Provider for a specified organization.