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

# Create Transaction

> direct creation of transactions



## OpenAPI

````yaml api-reference/openapi.json post /v1/api/deposit/
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: https://api.lygosapp.com
    description: Production Server
security: []
paths:
  /v1/api/deposit/:
    post:
      tags:
        - Collecte
      summary: Create Transaction
      description: direct creation of transactions
      operationId: create_transaction_api_v1_api_deposit__post
      parameters:
        - name: dependencies
          in: query
          required: false
          schema:
            title: Dependencies
        - name: api-key
          in: header
          required: true
          schema:
            type: string
            description: Clé API pour l'authentification
            title: Api-Key
          description: Clé API pour l'authentification
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TransactionSchemas'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransactionResponseSchemas'
        '400':
          description: Invalid data
          content:
            application/json:
              examples:
                invalid operator:
                  summary: invalid operator
                  value:
                    detail:
                      message: invalid operator.
                      type: INVALID_OPERATOR
                track_id taken:
                  summary: track_id taken
                  value:
                    detail:
                      message: track_id taken.
                      type: TRACK_ID_TAKEN
                Invalid phone number:
                  summary: Invalid phone number
                  value:
                    detail:
                      message: Invalid phone number.
                      type: PHONE_NUMBER_INVALID
                Deposit response missing:
                  summary: Deposit response missing 'id'
                  value:
                    detail:
                      message: Deposit response missing 'id'.
                      type: DEPOSIT_ID_MISSING
                Deposit status is missing:
                  summary: Deposit status is missing
                  value:
                    detail:
                      message: The deposit status is missing or the response is empty.
                      type: DEPOSIT_STATUS_VALIDATION_FAILED
                Invalid country code:
                  summary: Invalid ISO 3 country code
                  value:
                    detail:
                      message: Invalid ISO 3 country code.
                      type: BUYER_COUNTRY_VALIDATION_FAILED
        '404':
          description: Unknown Not Found
          content:
            application/json:
              examples:
                No API Key:
                  summary: No API Key
                  value:
                    detail:
                      message: No API Key.
                      type: NO_API_KEY_PROVIDED
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    TransactionSchemas:
      properties:
        track_id:
          type: string
          title: Track Id
        amount:
          type: number
          title: Amount
        phone_number:
          type: string
          title: Phone Number
        country:
          type: string
          title: Country
        currency:
          type: string
          title: Currency
        operator:
          type: string
          title: Operator
      type: object
      required:
        - track_id
        - amount
        - phone_number
        - country
        - currency
        - operator
      title: TransactionSchemas
      example:
        track_id: TRX-2024-001234
        amount: 10000
        phone_number: '237657843901'
        country: CMR
        currency: XAF
        operator: MTN_MOMO_CMR
    TransactionResponseSchemas:
      properties:
        track_id:
          type: string
          title: Track Id
        amount:
          type: number
          title: Amount
        phone_number:
          type: string
          title: Phone Number
        country:
          type: string
          title: Country
        currency:
          type: string
          title: Currency
        operator:
          type: string
          title: Operator
        status:
          type: string
          title: Status
        created_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Created At
          default: '2025-12-12T09:15:34.448314'
      type: object
      required:
        - track_id
        - amount
        - phone_number
        - country
        - currency
        - operator
        - status
      title: TransactionResponseSchemas
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````