> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fiddler.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Update LLM provider

> Update an existing LLM provider's models and credentials. This is a replace operation - pass the complete desired state. For credentials: include existing ones (name/uuid) to keep them, add new ones (name/credential_config) to create them, omit any to remove them. For models: pass the complete list of desired models. Any fields not included will be removed.




## OpenAPI

````yaml PUT /v3/llm-gateway/providers/{provider}
openapi: 3.0.3
info:
  title: Fiddler API - 2.0
  description: APIs to interact with Fiddler
  termsOfService: https://fiddler.ai/about/terms
  contact:
    email: support@fiddler.ai
  license:
    name: Proprietary
    url: '2.0'
  version: '2.0'
servers: []
security:
  - BearerAuth: []
tags:
  - name: access-key
    description: CRUD operations for API keys
  - name: span-v3
  - name: aggregation-invalidation-request-v3
    description: Endpoints related to retrieving aggregation invalidation requests
  - name: alert-rules-v3
    description: CRUD for Alert Rules, Summary, and Stats APIs
  - name: application-v3
  - name: attribute-v3
  - name: auth
    description: Authentication strategies and login flows
  - name: baseline-v3
    description: CRUD for baseline
  - name: catalog-v3
    description: >-
      Entity catalog provides paginated, searchable discovery of entity names
      (attribute keys, agent names, span types, span names) and their distinct
      values. Powered by ClickHouse materialized views — no worker or PostgreSQL
      dependency.
  - name: chart-annotation-v3
    description: Endpoints related to retrieving chart annotations
  - name: chart-v3
    description: CRUD for chart
  - name: queries-v3
    description: v3 queries API
  - name: configuration-v3
    description: CRUD for configurations
  - name: custom-metrics-v3
  - name: dimensionality-reduction-v3
  - name: environment-v3
    description: Endpoints related to environment management
  - name: evals
  - name: datasets
  - name: evaluation-v3
  - name: evaluator-v3
  - name: rule-evaluators-v3
  - name: experiment-v3
  - name: explainability-v3
  - name: llm_rca-v3
  - name: file-upload
    description: Endpoints related to file uploading.
  - name: fql-expressions-v3
    description: >
      Endpoints for listing FQL (Fiddler Query Language) functions available for
      GenAI custom metrics. Used by the frontend for autocomplete and signature
      hints in the FQL editor.
  - name: genai-alert-rules-v3
    description: CRUD API for GenAI Alert Rules
  - name: genai-custom-metrics-v3
    description: API for GenAI Custom Metrics
  - name: genai-metrics-v3
    description: >-
      Endpoints for pre-aggregated GenAI metrics. All metric data is
      pre-aggregated by an hourly ClickHouse refreshable materialized view; no
      real-time aggregation is performed at request time.
  - name: guardrails-api
    description: Endpoints related to retrieving Guardrails specific data
  - name: ingestion-v3
  - name: intercom-api
    description: Endpoints related to intercom APIs
  - name: jobs-v3
  - name: llm-gateway-v3
  - name: auth-login
  - name: auth-logout
  - name: metrics-v3
    description: Metrics endpoints
  - name: model-v3
  - name: dashboard-v3
  - name: model-deployment-v3
  - name: monitoring-summary-v3
  - name: histograms-v3
  - name: organization-roles-v3
    description: Update user org role
  - name: organization-settings-v3
    description: Update organization settings such as timezone, email configuration, etc.
  - name: pagerduty-api
    description: CRUD for Pagerduty services.
  - name: project-v3
  - name: project-roles-v3
    description: Project role assignment management
  - name: searchable-text-key-v3
    description: >-
      Manage the global searchable text keys table that controls which OTel
      attribute keys are routed to the full-text-searchable `ValueContent`
      column in the unified attributes table. Changes propagate to the backing
      ClickHouse dictionary within 1-2 minutes and affect all tenants.
  - name: segments-v3
  - name: semantic-mapping-v3
    description: >-
      Manage the global semantic name mappings table that maps raw OTel
      attribute keys to canonical semantic concepts. Changes propagate to the
      backing ClickHouse dictionary within 1-2 minutes and affect all tenants.
  - name: server-info-v3
    description: Endpoints related to retrieving server information
  - name: sessions-v3
    description: v3 session APIs
  - name: team-roles-v3
  - name: team-v3
  - name: traces-v3
    description: v3 trace api for monitoring
  - name: fetch-sessions-v3
    description: v3 fetch sessions api for monitoring
  - name: user-access-key
    description: >
      CRUD operations for user API keys. All endpoints are user-scoped — each
      user can only operate on their own API keys. No one including Org admins
      have access to other users' API keys.
  - name: users-v3
  - name: version-compatibility-v3
  - name: webhooks
externalDocs:
  url: https://docs.fiddler.ai
  description: Find out more about Fiddler
paths:
  /v3/llm-gateway/providers/{provider}:
    put:
      tags:
        - llm-gateway-v3
      summary: Update LLM provider
      description: >
        Update an existing LLM provider's models and credentials. This is a
        replace operation - pass the complete desired state. For credentials:
        include existing ones (name/uuid) to keep them, add new ones
        (name/credential_config) to create them, omit any to remove them. For
        models: pass the complete list of desired models. Any fields not
        included will be removed.
      operationId: updateLLMProviderV3
      parameters:
        - $ref: '#/components/parameters/provider'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateLLMProviderRequest'
            examples:
              update_models_only:
                summary: Update provider models only (replace all models)
                value:
                  provider: openai
                  models:
                    - name: gpt-4
                    - name: gpt-3.5-turbo
                    - name: gpt-4o-mini
              update_credentials_only:
                summary: >-
                  Update provider credentials only (keep existing, add new,
                  remove omitted)
                value:
                  provider: openai
                  credentials:
                    - name: Production Key
                      uuid: 550e8400-e29b-41d4-a716-446655440004
                    - name: Development Key
                      credential_config:
                        credential_type: api_key
                        api_key: sk-dev-...
              update_both:
                summary: Update both models and credentials (complete replace)
                value:
                  provider: openai
                  models:
                    - name: gpt-4
                    - name: gpt-3.5-turbo
                    - name: gpt-4o-mini
                  credentials:
                    - name: Production Key
                      uuid: 550e8400-e29b-41d4-a716-446655440004
                    - name: Development Key
                      credential_config:
                        credential_type: api_key
                        api_key: sk-dev-...
              update_credentials_oauth2:
                summary: Update credentials only with OAuth2 client credentials
                value:
                  provider: databricks
                  credentials:
                    - name: Databricks Service Principal
                      uuid: 550e8400-e29b-41d4-a716-446655440021
                    - name: Databricks SP (rotated)
                      credential_config:
                        credential_type: oauth2_client_credentials
                        token_url: https://adb-xxx.azuredatabricks.net/oidc/v1/token
                        client_id: 00000000-0000-0000-0000-000000000000
                        client_secret: dose...
                        scope: all-apis
              update_both_oauth2:
                summary: >-
                  Update both models and credentials with OAuth2 client
                  credentials
                value:
                  provider: databricks
                  api_base: https://adb-xxx.azuredatabricks.net/serving-endpoints
                  models:
                    - name: databricks-meta-llama-3-1-405b-instruct
                  credentials:
                    - name: Databricks Service Principal
                      credential_config:
                        credential_type: oauth2_client_credentials
                        token_url: https://adb-xxx.azuredatabricks.net/oidc/v1/token
                        client_id: 00000000-0000-0000-0000-000000000000
                        client_secret: dose...
                        scope: all-apis
      responses:
        '200':
          description: LLM provider updated successfully
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ApiResponse'
                  - type: object
                    properties:
                      data:
                        $ref: '#/components/schemas/LLMProvider'
              examples:
                success:
                  summary: Provider updated successfully
                  value:
                    api: v3
                    data:
                      id: 1
                      uuid: 550e8400-e29b-41d4-a716-446655440000
                      provider: OpenAI
                      credentials:
                        - name: Production Key
                          uuid: 550e8400-e29b-41d4-a716-446655440004
                          credential_type: api_key
                        - name: Development Key
                          uuid: 550e8400-e29b-41d4-a716-446655440005
                          credential_type: api_key
                      models:
                        - name: gpt-4
                          uuid: 550e8400-e29b-41d4-a716-446655440008
                        - name: gpt-3.5-turbo
                          uuid: 550e8400-e29b-41d4-a716-446655440009
                        - name: gpt-4o-mini
                          uuid: 550e8400-e29b-41d4-a716-446655440010
                      created_at: '2025-01-08T00:00:00Z'
                      updated_at: '2025-01-08T13:00:00Z'
                      created_by:
                        id: 550e8400-e29b-41d4-a716-446655440002
                        full_name: Joe Schmoe
                        email: joe_schmoe@email.com
                success_oauth2:
                  summary: Provider updated successfully with OAuth2 client credentials
                  value:
                    api: v3
                    data:
                      id: 3
                      uuid: 550e8400-e29b-41d4-a716-446655440020
                      provider: Databricks
                      api_base: https://adb-xxx.azuredatabricks.net/serving-endpoints
                      credentials:
                        - name: Databricks Service Principal
                          uuid: 550e8400-e29b-41d4-a716-446655440021
                          credential_type: oauth2_client_credentials
                      models:
                        - name: databricks-meta-llama-3-1-405b-instruct
                          uuid: 550e8400-e29b-41d4-a716-446655440022
                      created_at: '2025-01-08T00:00:00Z'
                      updated_at: '2025-01-08T13:00:00Z'
                      created_by:
                        id: 550e8400-e29b-41d4-a716-446655440002
                        full_name: Joe Schmoe
                        email: joe_schmoe@email.com
        '400':
          $ref: '#/components/responses/400'
        '404':
          $ref: '#/components/responses/404'
        '500':
          $ref: '#/components/responses/500'
components:
  parameters:
    provider:
      name: provider
      in: path
      description: Name of the LLM provider (e.g., OpenAI, Anthropic)
      required: true
      schema:
        type: string
  schemas:
    UpdateLLMProviderRequest:
      type: object
      title: Update LLM Provider Request
      description: >-
        Request body for updating an LLM provider. This is a replace operation
        where you specify the complete desired state. Omitted fields will be
        removed.
      required:
        - provider
      properties:
        provider:
          description: Name of the LLM provider
          type: string
        api_base:
          description: >-
            Custom API base URL. Required for some providers (e.g., Databricks),
            optional for others (e.g., Bedrock VPC endpoints). Must use HTTPS.
          type: string
          maxLength: 512
          nullable: true
        models:
          description: >-
            Complete list of models to support. This replaces all existing
            models.
          type: array
          items:
            $ref: '#/components/schemas/ModelCompactRequest'
        credentials:
          description: >-
            Complete list of credentials. Include existing ones (name/uuid) to
            keep them, add new ones (name/credential_config) to create them.
            Omitted credentials will be removed.
          type: array
          items:
            $ref: '#/components/schemas/CredentialUpdate'
    ApiResponse:
      type: object
      description: |
        Response object for standard API responses.
      properties:
        api_version:
          type: string
          default: '3.0'
          enum:
            - '2.0'
            - '3.0'
          description: |
            API version.
        kind:
          type: string
          default: NORMAL
          enum:
            - NORMAL
          description: |
            Type of response, indicating a normal response.
    LLMProvider:
      type: object
      description: Details of an LLM provider
      required:
        - id
        - uuid
        - provider
        - credentials
        - models
        - created_by
        - created_at
        - updated_at
      allOf:
        - type: object
          properties:
            id:
              description: Unique identifier of the provider
              type: integer
              example: 1
            uuid:
              description: UUID of the provider
              type: string
              format: uuid
              example: 550e8400-e29b-41d4-a716-446655440000
            provider:
              description: Name of the provider
              type: string
              example: OpenAI
            api_base:
              description: >-
                Custom API base URL for providers with customer-specific
                endpoints
              type: string
              maxLength: 512
              nullable: true
            credentials:
              description: List of credentials for this provider
              type: array
              items:
                $ref: '#/components/schemas/CredentialCompactResponse'
            models:
              description: List of models supported by this provider
              type: array
              items:
                $ref: '#/components/schemas/UUIDAndNameCompactResponse'
            created_by:
              $ref: '#/components/schemas/UserCompact'
        - $ref: '#/components/schemas/CreateUpdateTimestamp'
    ModelCompactRequest:
      type: object
      title: Model Compact Request
      description: Request body for a model
      required:
        - name
      properties:
        name:
          description: Human-readable name for this model
          type: string
          maxLength: 128
        uuid:
          description: UUID for existing model
          type: string
          format: uuid
          nullable: true
    CredentialUpdate:
      type: object
      title: Credential Update
      description: >-
        Request body for updating a credential. Use name/uuid to keep existing
        credential, or name/credential_config to create a new one.
      properties:
        name:
          description: Human-readable name for the credential
          type: string
        uuid:
          description: UUID of existing credential to update
          type: string
          format: uuid
        credential_config:
          oneOf:
            - $ref: '#/components/schemas/APIKeyConfig'
            - $ref: '#/components/schemas/IAMConfig'
            - $ref: '#/components/schemas/GCPServiceAccountConfig'
            - $ref: '#/components/schemas/EntraIDConfig'
            - $ref: '#/components/schemas/AWSAccessKeyConfig'
            - $ref: '#/components/schemas/OAuth2ClientCredentialsConfig'
          discriminator:
            propertyName: credential_type
            mapping:
              api_key:
                $ref: '#/components/schemas/APIKeyConfig'
              iam:
                $ref: '#/components/schemas/IAMConfig'
              gcp_service_account:
                $ref: '#/components/schemas/GCPServiceAccountConfig'
              entra_id:
                $ref: '#/components/schemas/EntraIDConfig'
              aws_access_key:
                $ref: '#/components/schemas/AWSAccessKeyConfig'
              oauth2_client_credentials:
                $ref: '#/components/schemas/OAuth2ClientCredentialsConfig'
    CredentialCompactResponse:
      title: Credential Compact Response
      description: Compact credential representation that includes the credential type
      allOf:
        - $ref: '#/components/schemas/UUIDAndNameCompactResponse'
        - type: object
          properties:
            credential_type:
              description: >-
                Credential type (e.g., api_key, gcp_service_account, iam,
                entra_id, aws_access_key, oauth2_client_credentials)
              type: string
              enum:
                - api_key
                - iam
                - gcp_service_account
                - entra_id
                - aws_access_key
                - oauth2_client_credentials
              maxLength: 64
          required:
            - credential_type
    UUIDAndNameCompactResponse:
      type: object
      title: UUID and Name Compact Response
      description: Compact representation of an entity with UUID and name
      required:
        - uuid
        - name
      properties:
        uuid:
          description: Unique identifier for this entity
          type: string
          format: uuid
        name:
          description: Human-readable name for this entity
          type: string
          maxLength: 128
    UserCompact:
      type: object
      title: UserCompactV3
      description: >
        Compact version of a user which can be included in the response of
        relevant APIs.
      required:
        - id
        - email
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
          description: |
            Unique identifier for the user.
        full_name:
          type: string
          readOnly: true
          description: |
            Full name of the user.
        email:
          type: string
          format: email
          description: |
            Email address of the user.
    CreateUpdateTimestamp:
      type: object
      required:
        - created_at
        - updated_at
      properties:
        created_at:
          type: string
          format: date-time
          readOnly: true
          description: |
            Date and time when the object was created.
        updated_at:
          type: string
          format: date-time
          readOnly: true
          description: |
            Date and time when the object was last updated.
    ErrorResponse:
      type: object
      description: |
        Response object for errors returned by the API.
      properties:
        api_version:
          type: string
          default: '3.0'
          enum:
            - '2.0'
            - '3.0'
          description: |
            API version of the response.
        kind:
          type: string
          default: ERROR
          enum:
            - ERROR
          description: |
            Type of response, usually indicating an error.
        error:
          type: object
          properties:
            code:
              type: integer
              format: int32
              description: >
                Represents the code for this error, typically an HTTP response
                code.
              default: 400
              enum:
                - 400
                - 403
                - 404
                - 500
            message:
              type: string
              description: >
                A human-readable message providing more details about the error.
                If there are multiple errors, it will be the message for the
                first error.
              example: Resource Not Found
            errors:
              type: array
              description: >
                Container for additional information regarding the error,
                especially for multiple errors.
              items:
                type: object
                properties:
                  reason:
                    type: string
                    description: >
                      Unique identifier for this error, different from the error
                      code.
                    example: ResourceNotFoundException
                  message:
                    type: string
                    description: >
                      A human-readable message providing more details about the
                      error. If there is only one error, this field will match
                      error.message.
                    example: Resource Not Found
                  help:
                    type: string
                    description: >
                      Link to support or documentation providing more
                      information on the error.
    APIKeyConfig:
      type: object
      title: API Key Configuration
      description: Configuration for API key-based authentication
      required:
        - credential_type
        - api_key
      properties:
        credential_type:
          description: Type of credential configuration
          type: string
          enum:
            - api_key
          example: api_key
        api_key:
          description: API key for the provider
          type: string
          format: password
          writeOnly: true
          maxLength: 4096
          example: sk-...
    IAMConfig:
      type: object
      title: IAM Configuration
      description: Configuration for AWS cross-account role-based authentication
      required:
        - credential_type
        - cross_account_role_arn
        - external_id
        - region
      properties:
        credential_type:
          description: Type of credential configuration
          type: string
          enum:
            - iam
          example: iam
        cross_account_role_arn:
          description: ARN of the cross-account role
          type: string
          example: arn:aws:iam::CUSTOMER-ACCOUNT:role/BedrockAccessRole
        external_id:
          description: Unique external ID for the customer
          type: string
          format: password
          writeOnly: true
          example: unique-external-id-for-customer-123
        region:
          description: AWS region for the service
          type: string
          example: us-east-1
    GCPServiceAccountConfig:
      type: object
      title: GCP Service Account Configuration
      description: Configuration for GCP service account authentication (Vertex AI)
      required:
        - credential_type
        - service_account_json
        - vertex_project
        - vertex_location
      properties:
        credential_type:
          description: Type of credential configuration
          type: string
          enum:
            - gcp_service_account
          example: gcp_service_account
        service_account_json:
          description: GCP service account key JSON (used for authentication)
          type: string
          format: password
          writeOnly: true
          maxLength: 65536
          example: '{"type":"service_account","project_id":"my-project"}'
        vertex_project:
          description: Target GCP project for Vertex AI requests (e.g., my-project-123)
          type: string
          maxLength: 256
          example: my-project-123
        vertex_location:
          description: >-
            Target Vertex AI region for requests (e.g., us-central1,
            europe-west1)
          type: string
          maxLength: 64
          example: us-central1
    EntraIDConfig:
      type: object
      title: Microsoft Entra ID Configuration
      description: >-
        Configuration for Microsoft Entra ID client credentials authentication
        (Azure OpenAI / Azure AI)
      required:
        - credential_type
        - tenant_id
        - client_id
        - client_secret
      properties:
        credential_type:
          description: Type of credential configuration
          type: string
          enum:
            - entra_id
          example: entra_id
        tenant_id:
          description: Microsoft Entra ID tenant ID (directory ID)
          type: string
          maxLength: 256
          example: 00000000-0000-0000-0000-000000000000
        client_id:
          description: Microsoft Entra ID application (client) ID
          type: string
          maxLength: 256
          example: 00000000-0000-0000-0000-000000000000
        client_secret:
          description: Microsoft Entra ID client secret value
          type: string
          format: password
          writeOnly: true
          maxLength: 512
    AWSAccessKeyConfig:
      type: object
      title: AWS Access Key Configuration
      description: Configuration for static AWS access key authentication (Bedrock)
      required:
        - credential_type
        - aws_access_key_id
        - aws_secret_access_key
        - region
      properties:
        credential_type:
          description: Type of credential configuration
          type: string
          enum:
            - aws_access_key
          example: aws_access_key
        aws_access_key_id:
          description: AWS access key ID
          type: string
          maxLength: 256
          example: AKIAIOSFODNN7EXAMPLE
        aws_secret_access_key:
          description: AWS secret access key
          type: string
          format: password
          writeOnly: true
          maxLength: 256
        region:
          description: AWS region (e.g., us-east-1)
          type: string
          maxLength: 32
          example: us-east-1
    OAuth2ClientCredentialsConfig:
      type: object
      title: OAuth2 Client Credentials Configuration
      description: >-
        Generic, provider-agnostic OAuth2 client-credentials (M2M)
        configuration. The gateway exchanges client_id/client_secret for a
        short-lived bearer token at token_url and sends it as an Authorization
        Bearer header. Works for any standard OAuth2 client-credentials provider
        (Databricks, etc. for now) — only the field values differ per provider,
        not the schema. The example values below are for a Databricks service
        principal (token_url = {workspace-host}/oidc/v1/token, scope =
        all-apis).
      required:
        - credential_type
        - token_url
        - client_id
        - client_secret
        - scope
      properties:
        credential_type:
          description: Type of credential configuration
          type: string
          enum:
            - oauth2_client_credentials
          example: oauth2_client_credentials
        token_url:
          description: >-
            OAuth2 token endpoint (e.g., Databricks
            {workspace-host}/oidc/v1/token). Must use HTTPS.
          type: string
          maxLength: 512
          example: https://adb-xxx.azuredatabricks.net/oidc/v1/token
        client_id:
          description: OAuth2 client ID (service principal application ID)
          type: string
          maxLength: 256
          example: 00000000-0000-0000-0000-000000000000
        client_secret:
          description: OAuth2 client secret value
          type: string
          format: password
          writeOnly: true
          maxLength: 512
        scope:
          description: OAuth2 scope to request (e.g., Databricks 'all-apis')
          type: string
          maxLength: 512
          example: all-apis
  responses:
    '400':
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    '404':
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    '500':
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````