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

# Upload a conversation

> Upload a conversation using multipart form data. Recommended for smaller files (up to 100MB).



## OpenAPI

````yaml /rulebase_api_openapi.yaml post /conversations/upload
openapi: 3.0.1
info:
  title: Rulebase API
  version: 1.0.0
  description: Rulebase API
servers:
  - url: https://api.rulebase.co
security: []
paths:
  /conversations/upload:
    post:
      tags:
        - Conversations
      summary: Upload a conversation
      description: >-
        Upload a conversation using multipart form data. Recommended for smaller
        files (up to 100MB).
      operationId: uploadConversation
      parameters: []
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                upload[source]:
                  type: string
                  enum:
                    - xcally
                  description: >-
                    The source system or platform from which the call is being
                    uploaded
                upload[metadata][unique_id]:
                  type: string
                  description: Unique identifier for the call
                upload[metadata][type]:
                  type: string
                  enum:
                    - inbound
                    - outbound
                  description: The direction of the call (inbound or outbound)
                upload[metadata][agent]:
                  type: string
                  description: >-
                    The agent email address. Used to identify the employee on
                    the call for both inbound and outbound uploads.
                upload[metadata][caller]:
                  type: string
                  description: >-
                    Inbound: customer phone number. Outbound: agent email (may
                    duplicate upload[metadata][agent]).
                upload[metadata][called]:
                  type: string
                  description: >-
                    Inbound: trunk or extension phone number. Outbound: customer
                    phone number.
                upload[metadata][recorded_at]:
                  type: string
                  description: The date and time the call was recorded
                upload[file]:
                  type: string
                  format: binary
                  description: >-
                    The audio recording file (WAV, MP3, or M4A format, max
                    100MB)
              required:
                - upload[source]
                - upload[file]
                - upload[metadata][unique_id]
                - upload[metadata][type]
                - upload[metadata][agent]
                - upload[metadata][caller]
                - upload[metadata][called]
                - upload[metadata][recorded_at]
      responses:
        '201':
          description: Conversation uploaded successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/conversation_upload'
                required:
                  - data
      security:
        - bearer_auth: []
components:
  schemas:
    conversation_upload:
      type: object
      properties:
        id:
          type: string
        status:
          type: string
          enum:
            - pending
            - processing
            - completed
            - failed
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
      required:
        - id
        - status
        - created_at
        - updated_at
  securitySchemes:
    bearer_auth:
      type: http
      scheme: bearer
      description: API key authentication using Bearer Token

````