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

# Ask Reedapt for a change

> Hand a request in plain words to Reedapt's dubbing agent, as in the editor's chat
("make the French less formal", "speaker 2 should sound angrier"). It uses the same
monthly allowance as the chat.



## OpenAPI

````yaml /openapi.json post /dubs/{dub_id}/requests
openapi: 3.1.0
info:
  title: Reedapt Dubbing API
  description: >-
    Dub video and audio into other languages in the speaker's own voice.
    Authenticate with `Authorization: Bearer <key>`; make keys in Reedapt under
    Developers.
  version: 1.0.0
servers:
  - url: https://api.reedapt.com/v1
security:
  - apiKey: []
paths:
  /dubs/{dub_id}/requests:
    post:
      tags:
        - Agent
      summary: Ask Reedapt for a change
      description: >-
        Hand a request in plain words to Reedapt's dubbing agent, as in the
        editor's chat

        ("make the French less formal", "speaker 2 should sound angrier"). It
        uses the same

        monthly allowance as the chat.
      operationId: dub_request_dubs__dub_id__requests_post
      parameters:
        - name: dub_id
          in: path
          required: true
          schema:
            type: string
            title: Dub Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AgentRequestIn'
      responses:
        '201':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Run'
        '401':
          description: The key is missing, wrong or revoked.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '403':
          description: The key's account can't use this yet.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '404':
          description: Nothing with this id belongs to the key's account.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '409':
          description: The request conflicts with the object's state; the code says which.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '422':
          description: The request is invalid; the code and `fields` say why.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '429':
          description: >-
            Too many requests, or a plan limit was reached. Wait for
            `Retry-After` seconds.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
components:
  schemas:
    AgentRequestIn:
      properties:
        text:
          type: string
          maxLength: 2000
          minLength: 1
          title: Text
          examples:
            - Make the French less formal.
        autonomy:
          type: string
          enum:
            - ask
            - decide
          title: Autonomy
          description: >-
            `ask`: changes wait as `needs_input` until you answer. `decide`:
            Reedapt applies them.
          default: ask
      type: object
      required:
        - text
      title: AgentRequestIn
    Run:
      properties:
        id:
          type: string
          title: Id
          examples:
            - run_4f1a9c2e7b3d5a8c0e6f1b2d
        object:
          type: string
          const: run
          title: Object
          default: run
        dub_id:
          type: string
          title: Dub Id
        status:
          type: string
          enum:
            - done
            - needs_input
            - applied
            - declined
            - failed
          title: Status
          description: >-
            `done`: answered, nothing to change. `needs_input`: waiting for your
            answer. `applied`: changes made; the lines are re-voiced and the
            files rebuilt in the background.
        request:
          type: string
          title: Request
        reply:
          type: string
          title: Reply
          description: The agent's answer, in the language of the request.
        proposal:
          anyOf:
            - $ref: '#/components/schemas/RunProposal'
            - type: 'null'
        options:
          anyOf:
            - items:
                $ref: '#/components/schemas/RunOption'
              type: array
            - type: 'null'
          title: Options
        applied_lines:
          anyOf:
            - type: integer
            - type: 'null'
          title: Applied Lines
        created_at:
          type: string
          format: date-time
          title: Created At
      type: object
      required:
        - id
        - dub_id
        - status
        - request
        - reply
        - created_at
      title: Run
      description: A request handed to Reedapt's dubbing agent, and where it got to.
    ErrorBody:
      properties:
        error:
          $ref: '#/components/schemas/ErrorDetail'
      type: object
      required:
        - error
      title: ErrorBody
    RunProposal:
      properties:
        kind:
          type: string
          title: Kind
          examples:
            - changes
        summary:
          type: string
          title: Summary
        lines:
          type: integer
          title: Lines
          description: How many lines it would change.
      type: object
      required:
        - kind
        - summary
        - lines
      title: RunProposal
    RunOption:
      properties:
        id:
          type: string
          enum:
            - apply
            - decline
          title: Id
        label:
          type: string
          title: Label
      type: object
      required:
        - id
        - label
      title: RunOption
    ErrorDetail:
      properties:
        code:
          type: string
          title: Code
          description: Stable and machine-readable; branch on this, not on the message.
          examples:
            - UPLOAD_INCOMPLETE
        message:
          type: string
          title: Message
          description: What went wrong and what to do, in plain English.
          examples:
            - Complete the upload before dubbing it.
        request_id:
          type: string
          title: Request Id
          description: Quote it when you contact us about this request.
          examples:
            - req_8f2c1e0a9b7d6c5e4f3a
        fields:
          anyOf:
            - items:
                additionalProperties:
                  type: string
                type: object
              type: array
            - type: 'null'
          title: Fields
          description: >-
            On INVALID_REQUEST from validation: each field that is missing or
            invalid.
          examples:
            - - field: target_languages
                message: Field required
      type: object
      required:
        - code
        - message
        - request_id
      title: ErrorDetail
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: '`rk_live_…` or `rk_test_…`, made in Reedapt under Developers.'

````

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