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

# Update an agent

> Changes `name` and `description` at once, and writes any `config` fields into a draft of the live version: callers hear nothing new until you publish. An agent without versions gets them on its first change (warning `versioning_enabled`). The response lists `changed_fields` and points at publish.



## OpenAPI

````yaml /api-reference/openapi.json patch /agents/{id}
openapi: 3.0.0
info:
  contact: {}
  description: >-
    Public REST API for Brilo. Authenticate by sending your API key as a Bearer
    token in the `Authorization` header.
  title: Brilo API
  version: '2025-03-02'
servers:
  - description: Production
    url: https://api.brilo.ai/v1
security: []
tags: []
paths:
  /agents/{id}:
    patch:
      tags:
        - Agents (public)
      summary: Update an agent
      description: >-
        Changes `name` and `description` at once, and writes any `config` fields
        into a draft of the live version: callers hear nothing new until you
        publish. An agent without versions gets them on its first change
        (warning `versioning_enabled`). The response lists `changed_fields` and
        points at publish.
      operationId: updateAgent
      parameters:
        - description: Agent id (UUID).
          in: path
          name: id
          required: true
          schema:
            type: string
        - description: >-
            The revision from your last read or write. If the object changed
            since, you get 409 stale_revision with the current object.
          in: header
          name: If-Match
          required: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              additionalProperties: false
              properties:
                config:
                  additionalProperties: false
                  description: >-
                    Goes to the live version's draft. Callers hear it after
                    publish.
                  properties:
                    call_handling:
                      additionalProperties: false
                      properties:
                        greeting_interruptible:
                          description: Can the caller talk over the greeting.
                          type: boolean
                        idle_reminder:
                          additionalProperties: false
                          description: What the agent says when the caller goes quiet.
                          properties:
                            after_seconds:
                              maximum: 600
                              minimum: 1
                              type: integer
                            enabled:
                              type: boolean
                            message:
                              maxLength: 500
                              nullable: true
                              type: string
                          type: object
                        max_duration_seconds:
                          description: >-
                            Longest a call may run, in whole minutes as seconds.
                            0 means no limit.
                          maximum: 14400
                          minimum: 0
                          multipleOf: 60
                          type: integer
                        silence_timeout_seconds:
                          description: Hang up after this much silence.
                          maximum: 600
                          minimum: 1
                          type: integer
                      type: object
                    greeting:
                      description: >-
                        The first thing the agent says when a call connects.
                        null lets the agent open on its own.
                      maxLength: 2000
                      nullable: true
                      type: string
                    instructions:
                      description: >-
                        How the agent should behave: who it is, what it handles
                        and what it must never do.
                      maxLength: 100000
                      nullable: true
                      type: string
                    languages:
                      description: >-
                        Languages the agent speaks, main one first, for example
                        ["en", "es"].
                      items:
                        maxLength: 16
                        minLength: 2
                        type: string
                      maxItems: 10
                      minItems: 1
                      type: array
                    model:
                      additionalProperties: false
                      properties:
                        id:
                          description: Language model id.
                          format: uuid
                          pattern: >-
                            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                          type: string
                      required:
                        - id
                      type: object
                    recording:
                      additionalProperties: false
                      properties:
                        consent:
                          additionalProperties: false
                          properties:
                            prompt:
                              maxLength: 2000
                              nullable: true
                              type: string
                            type:
                              description: verbal asks the caller before recording.
                              enum:
                                - none
                                - verbal
                              type: string
                          type: object
                        enabled:
                          type: boolean
                        transcript_enabled:
                          type: boolean
                      type: object
                    timezone:
                      maxLength: 64
                      type: string
                    transcriber:
                      additionalProperties: false
                      properties:
                        id:
                          description: Speech to text model id.
                          format: uuid
                          pattern: >-
                            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                          type: string
                      required:
                        - id
                      type: object
                    voice:
                      additionalProperties: false
                      properties:
                        id:
                          description: Voice id.
                          format: uuid
                          pattern: >-
                            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                          type: string
                        speaking_rate:
                          anyOf:
                            - enum:
                                - 0.8
                              type: number
                            - enum:
                                - 1
                              type: number
                            - enum:
                                - 1.2
                              type: number
                          description: 0.8 slow, 1 normal, 1.2 fast.
                      type: object
                    voicemail:
                      additionalProperties: false
                      properties:
                        behavior:
                          enum:
                            - hang_up
                            - leave_message
                          type: string
                        message:
                          maxLength: 2000
                          nullable: true
                          type: string
                      type: object
                  type: object
                description:
                  description: A short note for people. null clears it.
                  maxLength: 2000
                  nullable: true
                  type: string
                name:
                  maxLength: 255
                  minLength: 1
                  type: string
              type: object
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                additionalProperties: false
                properties:
                  changed_fields:
                    items:
                      type: string
                    type: array
                  config:
                    additionalProperties: false
                    description: 'What callers hear now: the live version, latest commit.'
                    properties:
                      call_handling:
                        additionalProperties: false
                        properties:
                          greeting_interruptible:
                            type: boolean
                          idle_reminder:
                            additionalProperties: false
                            properties:
                              after_seconds:
                                maximum: 9007199254740991
                                minimum: -9007199254740991
                                nullable: true
                                type: integer
                              enabled:
                                type: boolean
                              message:
                                nullable: true
                                type: string
                            required:
                              - enabled
                              - after_seconds
                              - message
                            type: object
                          max_duration_seconds:
                            maximum: 9007199254740991
                            minimum: -9007199254740991
                            type: integer
                          silence_timeout_seconds:
                            maximum: 9007199254740991
                            minimum: -9007199254740991
                            nullable: true
                            type: integer
                        required:
                          - max_duration_seconds
                          - silence_timeout_seconds
                          - idle_reminder
                          - greeting_interruptible
                        type: object
                      greeting:
                        nullable: true
                        type: string
                      instructions:
                        nullable: true
                        type: string
                      languages:
                        items:
                          type: string
                        type: array
                      model:
                        additionalProperties: false
                        properties:
                          id:
                            nullable: true
                            type: string
                        required:
                          - id
                        type: object
                      recording:
                        additionalProperties: false
                        properties:
                          consent:
                            additionalProperties: false
                            properties:
                              prompt:
                                nullable: true
                                type: string
                              type:
                                type: string
                            required:
                              - type
                              - prompt
                            type: object
                          enabled:
                            type: boolean
                          transcript_enabled:
                            type: boolean
                        required:
                          - enabled
                          - consent
                          - transcript_enabled
                        type: object
                      timezone:
                        nullable: true
                        type: string
                      transcriber:
                        additionalProperties: false
                        properties:
                          id:
                            nullable: true
                            type: string
                        required:
                          - id
                        type: object
                      voice:
                        additionalProperties: false
                        properties:
                          id:
                            nullable: true
                            type: string
                          speaking_rate:
                            type: number
                        required:
                          - id
                          - speaking_rate
                        type: object
                      voicemail:
                        additionalProperties: false
                        properties:
                          behavior:
                            nullable: true
                            type: string
                          message:
                            nullable: true
                            type: string
                        required:
                          - behavior
                          - message
                        type: object
                    required:
                      - greeting
                      - instructions
                      - voice
                      - model
                      - transcriber
                      - languages
                      - timezone
                      - call_handling
                      - voicemail
                      - recording
                    type: object
                  created_at:
                    type: string
                  description:
                    nullable: true
                    type: string
                  draft_pending:
                    type: boolean
                  id:
                    type: string
                  live_version_id:
                    nullable: true
                    type: string
                  name:
                    nullable: true
                    type: string
                  next_action:
                    additionalProperties: false
                    properties:
                      body:
                        additionalProperties: {}
                        type: object
                      method:
                        type: string
                      path:
                        type: string
                      tool:
                        type: string
                    required:
                      - tool
                      - method
                      - path
                    type: object
                  phone_numbers:
                    items:
                      type: string
                    type: array
                  revision:
                    nullable: true
                    type: string
                  try_it:
                    additionalProperties: false
                    description: >-
                      Ways to hear the live agent now. Left out when nothing is
                      callable.
                    properties:
                      phone_numbers:
                        items:
                          type: string
                        type: array
                      ring_me:
                        additionalProperties: false
                        properties:
                          ask_owner_first:
                            type: string
                          body:
                            additionalProperties: false
                            properties:
                              agent_id:
                                type: string
                              to:
                                type: string
                            required:
                              - agent_id
                              - to
                            type: object
                          method:
                            enum:
                              - POST
                            type: string
                          path:
                            enum:
                              - /v1/call
                            type: string
                          tool:
                            description: >-
                              No MCP tool places a call; use the REST route in
                              method and path.
                            enum:
                              - null
                            nullable: true
                            type: string
                          warnings:
                            items:
                              additionalProperties: false
                              properties:
                                code:
                                  type: string
                                message:
                                  type: string
                              required:
                                - code
                                - message
                              type: object
                            type: array
                        required:
                          - tool
                          - method
                          - path
                          - body
                          - ask_owner_first
                        type: object
                      web_link:
                        type: string
                      web_link_serves:
                        enum:
                          - live
                        type: string
                    required:
                      - phone_numbers
                      - ring_me
                    type: object
                  versioning_enabled:
                    type: boolean
                  warnings:
                    items:
                      additionalProperties: false
                      properties:
                        code:
                          type: string
                        message:
                          type: string
                      required:
                        - code
                        - message
                      type: object
                    type: array
                required:
                  - id
                  - name
                  - description
                  - live_version_id
                  - versioning_enabled
                  - draft_pending
                  - config
                  - phone_numbers
                  - revision
                  - created_at
                type: object
          description: ''
        '400':
          content:
            application/json:
              schema:
                additionalProperties: false
                properties:
                  details:
                    additionalProperties: {}
                    type: object
                  error_code:
                    type: string
                  errors:
                    items:
                      additionalProperties: false
                      properties:
                        error_code:
                          type: string
                        field:
                          type: string
                        message:
                          type: string
                      required:
                        - field
                        - error_code
                        - message
                      type: object
                    type: array
                  hint:
                    type: string
                  message:
                    type: string
                  next_action:
                    additionalProperties: false
                    properties:
                      body:
                        additionalProperties: {}
                        type: object
                      method:
                        type: string
                      path:
                        type: string
                      tool:
                        type: string
                    required:
                      - tool
                      - method
                      - path
                    type: object
                  status:
                    maximum: 9007199254740991
                    minimum: -9007199254740991
                    type: integer
                required:
                  - status
                  - error_code
                  - message
                type: object
          description: validation_failed, voice_not_available, model_not_available
        '404':
          content:
            application/json:
              schema:
                additionalProperties: false
                properties:
                  details:
                    additionalProperties: {}
                    type: object
                  error_code:
                    type: string
                  errors:
                    items:
                      additionalProperties: false
                      properties:
                        error_code:
                          type: string
                        field:
                          type: string
                        message:
                          type: string
                      required:
                        - field
                        - error_code
                        - message
                      type: object
                    type: array
                  hint:
                    type: string
                  message:
                    type: string
                  next_action:
                    additionalProperties: false
                    properties:
                      body:
                        additionalProperties: {}
                        type: object
                      method:
                        type: string
                      path:
                        type: string
                      tool:
                        type: string
                    required:
                      - tool
                      - method
                      - path
                    type: object
                  status:
                    maximum: 9007199254740991
                    minimum: -9007199254740991
                    type: integer
                required:
                  - status
                  - error_code
                  - message
                type: object
          description: agent_not_found
        '409':
          content:
            application/json:
              schema:
                additionalProperties: false
                properties:
                  details:
                    additionalProperties: {}
                    type: object
                  error_code:
                    type: string
                  errors:
                    items:
                      additionalProperties: false
                      properties:
                        error_code:
                          type: string
                        field:
                          type: string
                        message:
                          type: string
                      required:
                        - field
                        - error_code
                        - message
                      type: object
                    type: array
                  hint:
                    type: string
                  message:
                    type: string
                  next_action:
                    additionalProperties: false
                    properties:
                      body:
                        additionalProperties: {}
                        type: object
                      method:
                        type: string
                      path:
                        type: string
                      tool:
                        type: string
                    required:
                      - tool
                      - method
                      - path
                    type: object
                  status:
                    maximum: 9007199254740991
                    minimum: -9007199254740991
                    type: integer
                required:
                  - status
                  - error_code
                  - message
                type: object
          description: >-
            stale_revision: If-Match is not the current revision;
            details.current is the agent now
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      bearerFormat: JWT
      description: Enter your API key (Bearer token)
      scheme: bearer
      type: http

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.