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

# Edit Async



## OpenAPI

````yaml /openapi.json post /edit_async
openapi: 3.1.0
info:
  title: Reducto API
  version: dev
servers:
  - url: https://platform.reducto.ai
security: []
paths:
  /edit_async:
    post:
      summary: Edit Async
      operationId: edit_async_edit_async_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AsyncEditConfig'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AsyncEditResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - SkippableHTTPBearer: []
components:
  schemas:
    AsyncEditConfig:
      properties:
        document_url:
          anyOf:
            - type: string
            - $ref: '#/components/schemas/UploadResponse'
          title: Document Url
          description: >
            The URL of the document to be processed. You can provide one of the
            following:

            1. A publicly available URL

            2. A presigned S3 URL

            3. A reducto:// prefixed URL obtained from the /upload endpoint
            after directly uploading a document
        edit_instructions:
          type: string
          title: Edit Instructions
          description: The instructions for the edit.
        edit_options:
          $ref: '#/components/schemas/EditOptions'
          default:
            color: '#FF0000'
            enable_overflow_pages: false
            flatten: false
        form_schema:
          anyOf:
            - items:
                $ref: '#/components/schemas/EditWidget'
              type: array
            - type: 'null'
          title: Form Schema
          description: >-
            Form schema for PDF forms. List of widgets with their types,
            descriptions, and bounding boxes. Only works for PDFs.
        priority:
          type: boolean
          title: Priority
          description: >-
            If True, attempts to process the job with priority if the user has
            priority processing budget available; by default, sync jobs are
            prioritized above async jobs.
          default: false
        webhook:
          $ref: '#/components/schemas/WebhookConfigNew'
          default:
            mode: disabled
            channels: []
      type: object
      required:
        - document_url
        - edit_instructions
      title: AsyncEditConfig
    AsyncEditResponse:
      properties:
        job_id:
          type: string
          title: Job Id
      type: object
      required:
        - job_id
      title: AsyncEditResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    UploadResponse:
      properties:
        file_id:
          type: string
          title: File Id
        presigned_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Presigned Url
      type: object
      required:
        - file_id
      title: UploadResponse
    EditOptions:
      properties:
        color:
          type: string
          pattern: ^#[0-9A-Fa-f]{6}$
          title: Color
          description: The color to use for edits, in hex format.
          default: '#FF0000'
        font_size:
          anyOf:
            - type: number
              maximum: 72
              minimum: 1
            - type: 'null'
          title: Font Size
          description: >-
            The font size (in points) to use for filled text fields. If not
            specified, font size is automatically calculated based on field
            dimensions.
        llm_provider_preference:
          anyOf:
            - type: string
              enum:
                - openai
                - anthropic
                - google
            - type: 'null'
          title: Llm Provider Preference
          description: >-
            The LLM provider to use for edit processing. If not specified,
            defaults to 'google'
        enable_overflow_pages:
          type: boolean
          title: Enable Overflow Pages
          description: >-
            If True, creates overflow pages for text that doesn't fit in form
            fields. Defaults to False.
          default: false
        flatten:
          type: boolean
          title: Flatten
          description: >-
            If True, flattens form fields after filling, converting them to
            static content. Defaults to False.
          default: false
      type: object
      title: EditOptions
    EditWidget:
      properties:
        bbox:
          $ref: '#/components/schemas/BoundingBox'
          description: Bounding box coordinates of the widget
        description:
          type: string
          title: Description
          description: Description of the widget extracted from the document
        type:
          type: string
          enum:
            - text
            - checkbox
            - radio
            - dropdown
            - barcode
          title: Type
          description: Type of the form widget
        fill:
          type: boolean
          title: Fill
          description: >-
            If True (default), the system will attempt to fill this widget. If
            False, the widget will be created but intentionally left unfilled.
          default: true
        value:
          anyOf:
            - type: string
            - type: 'null'
          title: Value
          description: >-
            If provided, this value will be used directly instead of attempting
            to intelligently determine the field value.
        font_size:
          anyOf:
            - type: number
              maximum: 72
              minimum: 1
            - type: 'null'
          title: Font Size
          description: >-
            Font size in points for this specific field. Takes priority over the
            global font_size in EditOptions. If not set, falls back to the
            global font_size, then to auto-calculated sizing.
      type: object
      required:
        - bbox
        - description
        - type
      title: EditWidget
    WebhookConfigNew:
      properties:
        mode:
          type: string
          enum:
            - disabled
            - svix
            - direct
          title: Mode
          description: >-
            The mode to use for webhook delivery. Defaults to 'disabled'. We
            recommend using 'svix' for production environments.
          default: disabled
        url:
          type: string
          title: Url
          description: The URL to send the webhook to (if using direct webhoook).
        metadata:
          title: Metadata
          description: JSON metadata included in webhook request body
        channels:
          items:
            type: string
          type: array
          title: Channels
          description: >-
            A list of Svix channels the message will be delivered down, omit to
            send to all channels.
      type: object
      title: WebhookConfigNew
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    BoundingBox:
      properties:
        left:
          type: number
          title: Left
        top:
          type: number
          title: Top
        width:
          type: number
          title: Width
        height:
          type: number
          title: Height
        page:
          type: integer
          title: Page
          description: The page number of the bounding box (1-indexed).
        original_page:
          type: integer
          title: Original Page
          description: >-
            The page number in the original document of the bounding box
            (1-indexed).
      type: object
      required:
        - left
        - top
        - width
        - height
        - page
      title: BoundingBox
  securitySchemes:
    SkippableHTTPBearer:
      type: http
      scheme: bearer

````