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

# Transfer between ledgers

> Create a transfer between two ledgers



## OpenAPI

````yaml post /v1/ledgers/{id}/transfer
openapi: 3.0.0
info:
  title: Ledgers API
  version: 1.0.0
  description: API for managing accounting ledgers and entries
servers: []
security:
  - bearerAuth: []
tags:
  - name: Ledgers
    description: Ledger management operations
paths:
  /v1/ledgers/{id}/transfer:
    post:
      tags:
        - Ledger Operations
      summary: Transfer between ledgers
      description: Create a transfer between two ledgers
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: Source ledger UUID
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TransferRequest'
      responses:
        '201':
          description: Transfer created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransferResponse'
        '400':
          description: Invalid transfer request
        '404':
          description: Ledger not found
        '422':
          description: Insufficient funds
components:
  schemas:
    TransferRequest:
      type: object
      required:
        - destination_ledger_id
        - amount
        - transaction_id
      properties:
        destination_ledger_id:
          type: string
          format: uuid
          description: Destination ledger UUID
        amount:
          type: integer
          description: Transfer amount in cents
          minimum: 1
        transaction_id:
          type: string
          format: uuid
          description: Unique transaction identifier
        description:
          type: string
          description: Transfer description
        metadata:
          type: object
          additionalProperties: true
          description: Additional transfer metadata
    TransferResponse:
      type: object
      properties:
        transfer_id:
          type: string
          format: uuid
        source_entry:
          $ref: '#/components/schemas/LedgerEntry'
        destination_entry:
          $ref: '#/components/schemas/LedgerEntry'
        timestamp:
          type: string
          format: date-time
    LedgerEntry:
      type: object
      properties:
        id:
          type: string
          format: uuid
        ledger_id:
          type: string
          format: uuid
        transaction_id:
          type: string
          format: uuid
        amount:
          type: integer
          description: Amount in cents
        type:
          type: string
          enum:
            - credit
            - debit
        description:
          type: string
        balance:
          type: integer
          description: Running balance in cents
        timestamp:
          type: string
          format: date-time
        metadata:
          type: object
          nullable: true
        created_at:
          type: string
          format: date-time
        created_by:
          type: string
          format: uuid
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````