> ## 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.

# Create transaction

> Create a new transaction



## OpenAPI

````yaml post /v1/customers/{customer_id}/transaction
openapi: 3.0.0
info:
  title: Transactions API
  version: 1.0.0
  description: API for managing financial transactions
servers: []
security:
  - bearerAuth: []
tags:
  - name: Transactions
    description: Transaction management operations
paths:
  /v1/customers/{customer_id}/transaction:
    post:
      tags:
        - Transactions
      summary: Create transaction
      description: Create a new transaction
      parameters:
        - name: customer_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateTransactionRequest'
      responses:
        '201':
          description: Transaction created successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Transaction'
        '400':
          $ref: '#/components/responses/ValidationError'
components:
  schemas:
    CreateTransactionRequest:
      type: object
      required:
        - recipient_type
        - sender_id
        - sender_type
        - destination_currency
        - source_currency
        - channel
      properties:
        recipient_id:
          type: string
          format: uuid
        recipient_type:
          type: string
          enum:
            - recipient
            - account
        sender_id:
          type: string
          format: uuid
        sender_type:
          type: string
          enum:
            - recipient
            - account
        destination_currency:
          $ref: '#/components/schemas/TransactionCurrency'
        source_currency:
          $ref: '#/components/schemas/TransactionCurrency'
        channel:
          type: string
        description:
          type: string
        scheduled_date:
          type: integer
          format: int64
        assignees:
          type: array
          items:
            type: string
            format: uuid
    Transaction:
      type: object
      properties:
        id:
          type: string
          format: uuid
        recipient_id:
          type: string
          format: uuid
        recipient_name:
          type: string
        recipient_type:
          type: string
          enum:
            - recipient
            - account
        recipient:
          type: object
          additionalProperties: true
        sender_id:
          type: string
          format: uuid
        sender_name:
          type: string
        sender_type:
          type: string
          enum:
            - recipient
            - account
        destination_currency:
          $ref: '#/components/schemas/TransactionCurrency'
        source_currency:
          $ref: '#/components/schemas/TransactionCurrency'
        status:
          type: string
          enum:
            - waiting-for-signature
            - pending
            - in-progress
            - completed
            - cancelled
            - failed
            - suspended
        channel:
          type: string
        tariff_id:
          type: string
          format: uuid
        task_id:
          type: string
          format: uuid
        customer_id:
          type: string
          format: uuid
        fee:
          type: string
        tax:
          type: string
        type:
          type: string
          enum:
            - iwt
            - owt
            - int
        created_at:
          type: string
          format: date-time
        modified_at:
          type: string
          format: date-time
    TransactionCurrency:
      type: object
      required:
        - currency
        - amount
      properties:
        currency:
          type: string
        amount:
          type: string
    Error:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
        message:
          type: string
  responses:
    ValidationError:
      description: Invalid input data
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: transactions.invalid_transaction_data
            message: Invalid transaction data
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````