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

# Change an agent's ASR model

> Set the speech recognition model the voice channel uses on a draft branch, with a `provider` and `model` pair from `GET /v1/asr-models`. Sending the Auto row’s pair clears the setting instead of storing it, and the response is the Auto row. Any other pair is refused while the voice channel’s language model is end to end, since it then handles speech itself. Changes reach the live agent when the branch is merged.



## OpenAPI

````yaml PATCH /v1/agents/{agentId}/branches/{branchId}/asr-model
openapi: 3.1.0
info:
  title: PolyAI Agents API
  version: 1.0.11
  description: Manage PolyAI agents, telephony, deployments, and real-time configs.
servers:
  - url: https://api.us.poly.ai
    description: US region
  - url: https://api.eu.poly.ai
    description: EU region
  - url: https://api.uk.poly.ai
    description: UK region
  - url: https://api.studio.poly.ai
    description: Studio region
security:
  - polyApiKey: []
paths:
  /v1/agents/{agentId}/branches/{branchId}/asr-model:
    parameters:
      - name: agentId
        in: path
        required: true
        schema:
          type: string
      - name: branchId
        in: path
        required: true
        schema:
          type: string
    patch:
      tags:
        - Models
      summary: Change an agent's ASR model
      description: >-
        Set the speech recognition model the voice channel uses on a draft
        branch, with a `provider` and `model` pair from `GET /v1/asr-models`.
        Sending the Auto row’s pair clears the setting instead of storing it,
        and the response is the Auto row. Any other pair is refused while the
        voice channel’s language model is end to end, since it then handles
        speech itself. Changes reach the live agent when the branch is merged.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateBranchAsrModelBody'
      responses:
        '200':
          description: The voice channel's new ASR model
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BranchAsrModelResponse'
components:
  schemas:
    UpdateBranchAsrModelBody:
      type: object
      properties:
        provider:
          type: string
          minLength: 1
          description: A `provider` from `GET /v1/asr-models`.
        model:
          type: string
          minLength: 1
          description: The `model` that goes with it.
      required:
        - provider
        - model
      additionalProperties: false
      description: >-
        The voice channel's ASR model, as a pair from `GET /v1/asr-models`. The
        Auto row's pair lets the platform pick a model for each call.
      title: UpdateBranchAsrModelBody
    BranchAsrModelResponse:
      anyOf:
        - type: object
          properties:
            id:
              type: string
              description: >-
                The ASR model's ID. IDs differ between regions, so set a model
                by `provider` and `model`.
            name:
              type: string
              description: The name Agent Studio shows.
            provider:
              type: string
              description: The speech recognition provider.
            model:
              type: string
              description: The provider's model name.
          required:
            - id
            - name
            - provider
            - model
          additionalProperties: false
          description: A speech recognition model the voice channel can use.
        - type: object
          properties:
            id:
              enum:
                - 'null'
              nullable: true
            name:
              enum:
                - 'null'
              nullable: true
            provider:
              type: string
              description: The provider the voice channel stores.
            model:
              type: string
              description: The model the voice channel stores.
          required:
            - id
            - name
            - provider
            - model
          additionalProperties: false
          description: >-
            A provider and model pair the voice channel stores that isn't in
            this region's list.
      description: >-
        The voice channel's ASR model on a branch, in the same shape as `GET
        /v1/asr-models`. With no model set, it's the row named Auto. When the
        stored pair isn't listed, only `provider` and `model` are known.
      title: BranchAsrModelResponse
  securitySchemes:
    polyApiKey:
      type: apiKey
      in: header
      name: X-API-KEY

````