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

# Ingest Conversation

> Ingest a multi-turn conversation into the knowledge graph.
- Each turn is converted into a source with provenance metadata.



## OpenAPI

````yaml https://api.crosmos.dev/openapi.json post /api/v1/conversations
openapi: 3.1.0
info:
  title: Crosmos Memory API
  description: Agent memory system with hybrid retrieval
  version: 0.1.0
servers: []
security: []
paths:
  /api/v1/conversations:
    post:
      tags:
        - conversations
      summary: Ingest Conversation
      description: |-
        Ingest a multi-turn conversation into the knowledge graph.
        - Each turn is converted into a source with provenance metadata.
      operationId: ingest_conversation_api_v1_conversations_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/IngestConversationRequest'
        required: true
      responses:
        '202':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IngestConversationResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    IngestConversationRequest:
      properties:
        space_id:
          type: string
          format: uuid
          title: Space Id
          description: Memory space to ingest into
        messages:
          items:
            $ref: '#/components/schemas/ConversationMessage'
          type: array
          maxItems: 500
          minItems: 1
          title: Messages
          description: Ordered conversation messages
        session_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Session Id
          description: Session identifier. Auto-generated if not provided.
        session_date:
          anyOf:
            - type: string
            - type: 'null'
          title: Session Date
          description: ISO date string for when the session occurred
        meta:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Meta
          description: Optional metadata attached to all created sources
      type: object
      required:
        - space_id
        - messages
      title: IngestConversationRequest
    IngestConversationResponse:
      properties:
        job_id:
          type: string
          format: uuid
          title: Job Id
        status:
          type: string
          title: Status
          default: pending
        source_id:
          type: string
          format: uuid
          title: Source Id
      type: object
      required:
        - job_id
        - source_id
      title: IngestConversationResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ConversationMessage:
      properties:
        role:
          type: string
          maxLength: 50
          minLength: 1
          title: Role
          description: Speaker role (e.g. 'user', 'assistant')
        content:
          type: string
          maxLength: 100000
          minLength: 1
          title: Content
          description: Message content
      type: object
      required:
        - role
        - content
      title: ConversationMessage
    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
  securitySchemes:
    HTTPBearer:
      type: http
      description: JWT access token or API key (csk_…)
      scheme: bearer

````