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

# Crear venta

> Registra una venta y devuelve la operación creada junto con sus efectos fiscales, de stock, pagos y contabilidad. Idempotency-Key solo protege reintentos; si necesitás guardar una referencia externa visible, enviá integration_source e integration_id en el cuerpo.



## OpenAPI

````yaml /api-reference/openapi.json post /api/v1/sales
openapi: 3.1.0
info:
  title: La Pyme API
  description: >-
    Resources and workflows for purchases, sales, inventory, contacts, products,
    reports, and settings.
  version: 1.0.0
  contact:
    name: La Pyme Support
    email: hola@lapyme.com.ar
  license:
    name: Proprietary
    url: https://lapyme.com.ar/terminos
servers:
  - url: https://api.lapyme.com.ar
    description: Servidor de producción
security:
  - bearerAuth: []
tags:
  - name: API
    description: Public API operations for La Pyme integrations.
paths:
  /api/v1/sales:
    post:
      tags:
        - API
      summary: Crear venta
      description: >-
        Registra una venta y devuelve la operación creada junto con sus efectos
        fiscales, de stock, pagos y contabilidad. Idempotency-Key solo protege
        reintentos; si necesitás guardar una referencia externa visible, enviá
        integration_source e integration_id en el cuerpo.
      operationId: createApiSale
      parameters:
        - name: Idempotency-Key
          in: header
          description: >-
            Clave única para evitar duplicados al reintentar la misma creación
            de venta.
          required: true
          schema:
            type: string
        - name: X-Request-Id
          in: header
          description: >-
            ID opcional de la solicitud para trazabilidad. Si se omite, el
            servidor genera uno.
          required: false
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ApiSaleTransactionRequest'
            examples:
              service_sale_pending_payment:
                summary: Service sale with pending balance
                value:
                  voucher_type: 90
                  point_of_sale_id: 550e8400-e29b-41d4-a716-446655440002
                  invoice_date: '2026-04-18'
                  due_date: '2026-04-18'
                  currency: PES
                  is_full_amount_pending: true
                  items:
                    - name: Technical service
                      product_type: service
                      quantity: 1
                      unit_price: 10000
                      tax_rate_id: 5
              product_sale_with_payment:
                summary: Product sale paid at checkout
                value:
                  customer_id: 550e8400-e29b-41d4-a716-446655440101
                  integration_source: ERP
                  integration_id: SO-10045
                  voucher_type: 6
                  point_of_sale_id: 550e8400-e29b-41d4-a716-446655440002
                  invoice_date: '2026-04-18'
                  due_date: '2026-04-18'
                  currency: PES
                  items:
                    - product_id: 9c692e8b-0f9a-4f7c-8b99-061a2eb188ae
                      warehouse_id: 550e8400-e29b-41d4-a716-446655440010
                      quantity: 2
                      unit_price: 12500
                      tax_rate_id: 5
                  payment_methods:
                    - method_id: 550e8400-e29b-41d4-a716-446655440301
                      amount: 25000
                      cash_source:
                        type: register
                        id: 550e8400-e29b-41d4-a716-446655440701
      responses:
        '200':
          description: Venta creada exitosamente
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiSaleTransactionSuccessResponse'
              examples:
                created:
                  summary: Venta creada
                  value:
                    request_id: req_sale_commit_1
                    data:
                      sale:
                        sale_id: cf19b3ae-4c08-48be-b9d7-e6f2f5baf609
                        customer_id: null
                        voucher_type: '90'
                        point_of_sale_id: 550e8400-e29b-41d4-a716-446655440002
                        invoice_number: 84
                        formatted_invoice_number: PRES-00001-00000084
                        invoice_status: not_required
                        invoice_date: '2026-04-18'
                        due_date: '2026-04-18'
                        currency: PES
                        subtotal: 8264
                        tax_amount: 1736
                        total: 10000
                        exempt_amount: 0
                        non_taxed_amount: 0
                        tributes_amount: 0
                        discount_amount: 0
                        balance: 10000
                        created_at: '2026-04-18T12:00:00.000Z'
                      normalized_sale:
                        customer_id: null
                        customer_tax_category_override: null
                        voucher_type: 90
                        point_of_sale_id: 550e8400-e29b-41d4-a716-446655440002
                        register_id: null
                        operator_id: null
                        invoice_date: '2026-04-18'
                        due_date: '2026-04-18'
                        service_from: null
                        service_to: null
                        currency: PES
                        exchange_rate: null
                        same_currency_payment: false
                        notes: null
                        subtotal: 8264
                        tax_amount: 1736
                        total: 10000
                        exempt_amount: 0
                        non_taxed_amount: 0
                        tributes_amount: 0
                        national_perception_amount: 0
                        gross_income_perception_amount: 0
                        gross_income_tax_breakdown: []
                        municipal_perception_amount: 0
                        internal_tribute_amount: 0
                        uncategorized_vat_perception_amount: 0
                        other_tribute_amount: 0
                        discount_type: null
                        discount_value: null
                        discount_amount: 0
                        balance: 10000
                        is_full_amount_pending: false
                        items:
                          - product_id: null
                            product_name: null
                            sku: null
                            warehouse_id: null
                            name: Technical service
                            product_type: service
                            quantity: 1
                            unit_price: 10000
                            unit_cost: null
                            tax_rate_id: 5
                            is_exempt: false
                            discount: null
                            notes: null
                            account_id: null
                            cost_center1_id: null
                            cost_center2_id: null
                            cost_center3_id: null
                        payment_methods: []
                      projected_effects:
                        inventory:
                          will_affect_stock: false
                          warehouse_ids: []
                          product_line_count: 0
                          total_quantity: 0
                        accounting:
                          will_create_sale_entry: true
                          will_create_payment_entry: false
                        fiscal:
                          invoice_status: not_required
                        payments:
                          will_create_payments: false
                          payment_method_count: 0
                          total_amount: 0
                          pending_amount: 10000
                      idempotent_replay: false
                    warnings: []
        '400':
          description: Solicitud inválida
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: INVALID_REQUEST
                  value:
                    request_id: req_sale_1
                    error:
                      code: INVALID_REQUEST
                      message: Invalid request for creating sales
                      retryable: false
                      type: invalid_request_error
                      details: []
        '401':
          description: API key faltante o inválida
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: AUTHENTICATION_REQUIRED
                  value:
                    request_id: req_sale_1
                    error:
                      code: AUTHENTICATION_REQUIRED
                      message: API key is required in the Authorization header
                      retryable: false
                      type: invalid_request_error
                      details: []
        '403':
          description: Scopes insuficientes
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: FORBIDDEN
                  value:
                    request_id: req_sale_1
                    error:
                      code: FORBIDDEN
                      message: Your API key does not have permission for this operation
                      retryable: false
                      type: invalid_request_error
                      details: []
        '409':
          description: Conflicto de idempotencia
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: IDEMPOTENCY_CONFLICT
                  value:
                    request_id: req_sale_1
                    error:
                      code: IDEMPOTENCY_CONFLICT
                      message: >-
                        The same Idempotency-Key was already used with a
                        different sale.
                      retryable: false
                      type: invalid_request_error
                      details: []
        '412':
          description: Business precondition not satisfied
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: PRECONDITION_FAILED
                  value:
                    request_id: req_sale_1
                    error:
                      code: PRECONDITION_FAILED
                      message: >-
                        The sale could not be created because a business
                        precondition failed.
                      retryable: false
                      details:
                        - field: input.payment_methods
                          code: VALIDATION
                          message: >-
                            You cannot send payment_methods when
                            is_full_amount_pending=true
                      type: invalid_request_error
        '429':
          description: Límite de solicitudes excedido para la organización
          headers:
            Retry-After:
              description: Segundos a esperar antes de volver a intentar la solicitud.
              schema:
                type: string
                example: '30'
            X-RateLimit-Limit:
              description: Límite de la ventana activa.
              schema:
                type: string
                example: '5000'
            X-RateLimit-Remaining:
              description: Solicitudes restantes en la ventana activa.
              schema:
                type: string
                example: '0'
            X-RateLimit-Reset:
              description: Segundos restantes hasta el reset de la ventana activa.
              schema:
                type: string
                example: '30'
            RateLimit-Limit:
              description: Límite de la ventana activa en formato estándar.
              schema:
                type: string
                example: '5000'
            RateLimit-Remaining:
              description: Solicitudes restantes en la ventana activa en formato estándar.
              schema:
                type: string
                example: '0'
            RateLimit-Reset:
              description: >-
                Segundos hasta el reset de la ventana activa en formato
                estándar.
              schema:
                type: string
                example: '30'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: RATE_LIMITED
                  value:
                    request_id: req_rate_limit_1
                    error:
                      type: rate_limit_error
                      code: RATE_LIMITED
                      message: >-
                        The organization request limit was reached. Try again
                        later.
                      retryable: true
                      details: []
        '500':
          description: Error interno del servidor
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: INTERNAL_ERROR
                  value:
                    request_id: req_sale_1
                    error:
                      code: INTERNAL_ERROR
                      message: Could not process the sale transaction
                      retryable: false
                      type: invalid_request_error
                      details: []
components:
  schemas:
    ApiSaleTransactionRequest:
      type: object
      properties:
        customer_id:
          type: string
          format: uuid
        customer_tax_category_override:
          type: string
        voucher_type:
          anyOf:
            - type: integer
              minimum: 1
              maximum: 95
            - type: number
              const: 201
            - type: number
              const: 206
            - type: number
              const: 211
        point_of_sale_id:
          type: string
          format: uuid
        register_id:
          type: string
          format: uuid
        operator_id:
          type: string
          format: uuid
        integration_source:
          description: >-
            Fuente de integracion externa para buscar/conciliar la venta. Debe
            enviarse junto con integrationId.
          type: string
        integration_id:
          description: >-
            ID de referencia externa visible en la venta. Debe enviarse junto
            con integrationSource; no se deriva del header Idempotency-Key.
          type: string
        invoice_date:
          type: string
          format: date
        due_date:
          type: string
          format: date
        service_from:
          type: string
          format: date
        service_to:
          type: string
          format: date
        currency:
          $ref: '#/components/schemas/ApiSharedEnum6cfb146157'
        exchange_rate:
          type: number
          exclusiveMinimum: 0
        same_currency_payment:
          type: boolean
        notes:
          type: string
        items:
          minItems: 1
          type: array
          items:
            type: object
            properties:
              product_id:
                type: string
                format: uuid
              warehouse_id:
                type: string
                format: uuid
              unit_cost:
                type: integer
                minimum: 0
              name:
                type: string
              product_type:
                type: string
                enum:
                  - product
                  - service
              tax_rate_id:
                type: integer
                minimum: 0
              is_exempt:
                type: boolean
              quantity:
                type: number
                exclusiveMinimum: 0
              unit_price:
                type: integer
                minimum: 0
              discount:
                $ref: '#/components/schemas/ApiSharedObject16c3799d74'
              notes:
                type: string
              account_id:
                type: string
                format: uuid
              line_type:
                $ref: '#/components/schemas/ApiSharedEnum4e55733f20'
              cost_center1_id:
                type: string
                format: uuid
              cost_center2_id:
                type: string
                format: uuid
              cost_center3_id:
                type: string
                format: uuid
            required:
              - quantity
              - unit_price
            additionalProperties: false
        discount_type:
          $ref: '#/components/schemas/ApiSharedEnum539fdceccc'
        discount_value:
          type: number
          minimum: 0
        discount_amount:
          type: integer
          minimum: 0
        subtotal:
          type: integer
          minimum: 0
        tax_amount:
          type: integer
          minimum: 0
        total:
          type: integer
          minimum: 0
        exempt_amount:
          type: integer
          minimum: 0
        non_taxed_amount:
          type: integer
          minimum: 0
        tributes_amount:
          type: integer
          minimum: 0
        national_perception_amount:
          type: integer
          minimum: 0
        gross_income_perception_amount:
          type: integer
          minimum: 0
        gross_income_tax_breakdown:
          type: array
          items:
            $ref: '#/components/schemas/ApiSharedObject95929ea589'
        municipal_perception_amount:
          type: integer
          minimum: 0
        internal_tribute_amount:
          type: integer
          minimum: 0
        uncategorized_vat_perception_amount:
          type: integer
          minimum: 0
        other_tribute_amount:
          type: integer
          minimum: 0
        payment_methods:
          type: array
          items:
            type: object
            properties:
              method_id:
                type: string
                format: uuid
              amount:
                type: integer
                exclusiveMinimum: 0
              description:
                type: string
              reference:
                type: string
              fee_amount:
                type: integer
                minimum: 0
              terminal_id:
                type: string
                format: uuid
              card_batch_number:
                type: string
              card_coupon_number:
                type: string
              card_installment_plan_code:
                type: string
              card_brand:
                type: string
              register_id:
                description: >-
                  ID de caja para pagos en efectivo. Usá cashSource en
                  integraciones nuevas.
                type: string
                format: uuid
              safe_id:
                description: >-
                  ID de caja fuerte para pagos en efectivo. Usá cashSource en
                  integraciones nuevas.
                type: string
                format: uuid
              cash_source:
                description: >-
                  Origen de efectivo para pagos cash. No combinar con registerId
                  o safeId.
                type: object
                properties:
                  type:
                    $ref: '#/components/schemas/ApiSharedEnum459535dab3'
                  id:
                    type: string
                    format: uuid
                    description: ID de la caja o caja fuerte.
                required:
                  - type
                  - id
                additionalProperties: false
            required:
              - method_id
              - amount
            additionalProperties: false
        is_full_amount_pending:
          type: boolean
      required:
        - voucher_type
        - point_of_sale_id
        - invoice_date
        - currency
        - items
      additionalProperties: false
    ApiSaleTransactionSuccessResponse:
      $ref: '#/components/schemas/ApiSaleCommitResponse'
    ApiErrorEnvelope:
      type: object
      properties:
        request_id:
          type: string
        error:
          type: object
          properties:
            type:
              type: string
              enum:
                - api_error
                - authentication_error
                - authorization_error
                - business_error
                - external_dependency_error
                - idempotency_error
                - invalid_request_error
                - rate_limit_error
            code:
              type: string
            message:
              type: string
            retryable:
              type: boolean
            details:
              type: array
              items:
                $ref: '#/components/schemas/ApiSharedObjectc671832641'
          required:
            - type
            - code
            - message
            - retryable
            - details
          additionalProperties: false
      required:
        - request_id
        - error
      additionalProperties: false
    ApiSharedEnum6cfb146157:
      type: string
      enum:
        - PES
        - DOL
    ApiSharedObject16c3799d74:
      type: object
      properties:
        type:
          $ref: '#/components/schemas/ApiSharedEnum539fdceccc'
        value:
          type: number
          minimum: 0
      required:
        - type
        - value
      additionalProperties: false
    ApiSharedEnum4e55733f20:
      type: string
      enum:
        - product
        - shipping
        - custom
    ApiSharedEnum539fdceccc:
      type: string
      enum:
        - percentage
        - amount
    ApiSharedObject95929ea589:
      type: object
      properties:
        province_id:
          type: integer
        amount:
          type: integer
          minimum: 0
      required:
        - province_id
        - amount
      additionalProperties: false
    ApiSharedEnum459535dab3:
      type: string
      enum:
        - register
        - safe
      description: 'Tipo de origen de efectivo: caja operativa o caja fuerte.'
    ApiSaleCommitResponse:
      type: object
      properties:
        request_id:
          type: string
        data:
          type: object
          properties:
            sale:
              type: object
              properties:
                sale_id:
                  type: string
                  format: uuid
                customer_id:
                  anyOf:
                    - type: string
                      format: uuid
                    - type: 'null'
                voucher_type:
                  type: string
                point_of_sale_id:
                  type: string
                  format: uuid
                invoice_number:
                  anyOf:
                    - type: integer
                    - type: 'null'
                formatted_invoice_number:
                  anyOf:
                    - type: string
                    - type: 'null'
                invoice_status:
                  $ref: '#/components/schemas/ApiSharedEnum9ac70a3316'
                invoice_date:
                  type: string
                  format: date
                due_date:
                  type: string
                  format: date
                currency:
                  type: string
                subtotal:
                  type: integer
                  minimum: 0
                tax_amount:
                  type: integer
                  minimum: 0
                total:
                  type: integer
                  minimum: 0
                exempt_amount:
                  type: integer
                  minimum: 0
                non_taxed_amount:
                  type: integer
                  minimum: 0
                tributes_amount:
                  type: integer
                  minimum: 0
                discount_amount:
                  type: integer
                balance:
                  type: number
                created_at:
                  type: string
                  format: date-time
              required:
                - sale_id
                - customer_id
                - voucher_type
                - point_of_sale_id
                - invoice_number
                - formatted_invoice_number
                - invoice_status
                - invoice_date
                - due_date
                - currency
                - subtotal
                - tax_amount
                - total
                - exempt_amount
                - non_taxed_amount
                - tributes_amount
                - discount_amount
                - balance
                - created_at
              additionalProperties: false
            normalized_sale:
              type: object
              properties:
                customer_id:
                  anyOf:
                    - type: string
                      format: uuid
                    - type: 'null'
                customer_tax_category_override:
                  anyOf:
                    - type: string
                    - type: 'null'
                voucher_type:
                  anyOf:
                    - type: integer
                      minimum: 1
                      maximum: 95
                    - type: number
                      const: 201
                    - type: number
                      const: 206
                    - type: number
                      const: 211
                point_of_sale_id:
                  type: string
                  format: uuid
                register_id:
                  anyOf:
                    - type: string
                      format: uuid
                    - type: 'null'
                operator_id:
                  anyOf:
                    - type: string
                      format: uuid
                    - type: 'null'
                invoice_date:
                  type: string
                  format: date
                due_date:
                  type: string
                  format: date
                service_from:
                  anyOf:
                    - type: string
                      format: date
                    - type: 'null'
                service_to:
                  anyOf:
                    - type: string
                      format: date
                    - type: 'null'
                currency:
                  $ref: '#/components/schemas/ApiSharedEnum6cfb146157'
                exchange_rate:
                  anyOf:
                    - type: number
                      exclusiveMinimum: 0
                    - type: 'null'
                same_currency_payment:
                  type: boolean
                notes:
                  anyOf:
                    - type: string
                    - type: 'null'
                subtotal:
                  type: integer
                  minimum: 0
                tax_amount:
                  type: integer
                  minimum: 0
                total:
                  type: integer
                  minimum: 0
                exempt_amount:
                  type: integer
                  minimum: 0
                non_taxed_amount:
                  type: integer
                  minimum: 0
                tributes_amount:
                  type: integer
                  minimum: 0
                national_perception_amount:
                  type: integer
                  minimum: 0
                gross_income_perception_amount:
                  type: integer
                  minimum: 0
                gross_income_tax_breakdown:
                  type: array
                  items:
                    $ref: '#/components/schemas/ApiSharedObject95929ea589'
                municipal_perception_amount:
                  type: integer
                  minimum: 0
                internal_tribute_amount:
                  type: integer
                  minimum: 0
                uncategorized_vat_perception_amount:
                  type: integer
                  minimum: 0
                other_tribute_amount:
                  type: integer
                  minimum: 0
                discount_type:
                  anyOf:
                    - $ref: '#/components/schemas/ApiSharedEnum539fdceccc'
                    - type: 'null'
                discount_value:
                  anyOf:
                    - type: number
                      minimum: 0
                    - type: 'null'
                discount_amount:
                  type: integer
                  minimum: 0
                balance:
                  type: number
                is_full_amount_pending:
                  type: boolean
                items:
                  type: array
                  items:
                    $ref: '#/components/schemas/ApiSharedObject55e2bcf4a7'
                payment_methods:
                  type: array
                  items:
                    $ref: '#/components/schemas/ApiSharedObjecte4ddc41067'
              required:
                - customer_id
                - customer_tax_category_override
                - voucher_type
                - point_of_sale_id
                - register_id
                - operator_id
                - invoice_date
                - due_date
                - service_from
                - service_to
                - currency
                - exchange_rate
                - same_currency_payment
                - notes
                - subtotal
                - tax_amount
                - total
                - exempt_amount
                - non_taxed_amount
                - tributes_amount
                - national_perception_amount
                - gross_income_perception_amount
                - gross_income_tax_breakdown
                - municipal_perception_amount
                - internal_tribute_amount
                - uncategorized_vat_perception_amount
                - other_tribute_amount
                - discount_type
                - discount_value
                - discount_amount
                - balance
                - is_full_amount_pending
                - items
                - payment_methods
              additionalProperties: false
            projected_effects:
              type: object
              properties:
                inventory:
                  $ref: '#/components/schemas/ApiSharedObject6a71e7888b'
                accounting:
                  $ref: '#/components/schemas/ApiSharedObject9428e7100c'
                fiscal:
                  $ref: '#/components/schemas/ApiSharedObject3563932f8e'
                payments:
                  $ref: '#/components/schemas/ApiSharedObject8e516a9b19'
              required:
                - inventory
                - accounting
                - fiscal
                - payments
              additionalProperties: false
            idempotent_replay:
              type: boolean
          required:
            - sale
            - normalized_sale
            - projected_effects
            - idempotent_replay
          additionalProperties: false
        warnings:
          type: array
          items:
            $ref: '#/components/schemas/ApiSharedObjectc671832641'
      required:
        - request_id
        - data
        - warnings
      additionalProperties: false
    ApiSharedObjectc671832641:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
        field:
          type: string
      required:
        - code
        - message
      additionalProperties: false
    ApiSharedEnum9ac70a3316:
      type: string
      enum:
        - not_required
        - pending
        - issued
    ApiSharedObject55e2bcf4a7:
      type: object
      properties:
        product_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        product_name:
          anyOf:
            - type: string
            - type: 'null'
        sku:
          anyOf:
            - type: string
            - type: 'null'
        warehouse_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        name:
          anyOf:
            - type: string
            - type: 'null'
        product_type:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedEnumff49232140'
            - type: 'null'
        quantity:
          type: number
          exclusiveMinimum: 0
        unit_price:
          type: integer
          minimum: 0
        unit_cost:
          anyOf:
            - type: integer
              minimum: 0
            - type: 'null'
        tax_rate_id:
          anyOf:
            - type: integer
              minimum: 0
            - type: 'null'
        is_exempt:
          type: boolean
        discount:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedObject16c3799d74'
            - type: 'null'
        notes:
          anyOf:
            - type: string
            - type: 'null'
        account_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        line_type:
          $ref: '#/components/schemas/ApiSharedEnum4e55733f20'
        cost_center1_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        cost_center2_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        cost_center3_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
      required:
        - product_id
        - product_name
        - sku
        - warehouse_id
        - name
        - product_type
        - quantity
        - unit_price
        - unit_cost
        - tax_rate_id
        - is_exempt
        - discount
        - notes
        - account_id
        - line_type
        - cost_center1_id
        - cost_center2_id
        - cost_center3_id
      additionalProperties: false
    ApiSharedObjecte4ddc41067:
      type: object
      properties:
        method_id:
          type: string
          format: uuid
        amount:
          type: integer
          exclusiveMinimum: 0
        description:
          anyOf:
            - type: string
            - type: 'null'
        reference:
          anyOf:
            - type: string
            - type: 'null'
        fee_amount:
          anyOf:
            - type: integer
              minimum: 0
            - type: 'null'
        terminal_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        card_batch_number:
          anyOf:
            - type: string
            - type: 'null'
        card_coupon_number:
          anyOf:
            - type: string
            - type: 'null'
        card_installment_plan_code:
          anyOf:
            - type: string
            - type: 'null'
        card_brand:
          anyOf:
            - type: string
            - type: 'null'
        cash_source:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedObjectf61e74f9c5'
            - type: 'null'
      required:
        - method_id
        - amount
        - description
        - reference
        - fee_amount
        - terminal_id
        - card_batch_number
        - card_coupon_number
        - card_installment_plan_code
        - card_brand
        - cash_source
      additionalProperties: false
    ApiSharedObject6a71e7888b:
      type: object
      properties:
        will_affect_stock:
          type: boolean
        warehouse_ids:
          type: array
          items:
            type: string
            format: uuid
        product_line_count:
          type: integer
          minimum: 0
        total_quantity:
          type: number
          minimum: 0
      required:
        - will_affect_stock
        - warehouse_ids
        - product_line_count
        - total_quantity
      additionalProperties: false
    ApiSharedObject9428e7100c:
      type: object
      properties:
        will_create_sale_entry:
          type: boolean
        will_create_payment_entry:
          type: boolean
      required:
        - will_create_sale_entry
        - will_create_payment_entry
      additionalProperties: false
    ApiSharedObject3563932f8e:
      type: object
      properties:
        invoice_status:
          $ref: '#/components/schemas/ApiSharedEnumd8087f784e'
      required:
        - invoice_status
      additionalProperties: false
    ApiSharedObject8e516a9b19:
      type: object
      properties:
        will_create_payments:
          type: boolean
        payment_method_count:
          type: integer
          minimum: 0
        total_amount:
          type: number
        pending_amount:
          type: number
      required:
        - will_create_payments
        - payment_method_count
        - total_amount
        - pending_amount
      additionalProperties: false
    ApiSharedEnumff49232140:
      type: string
      enum:
        - product
        - service
        - combo
        - kit
    ApiSharedObjectf61e74f9c5:
      type: object
      properties:
        type:
          $ref: '#/components/schemas/ApiSharedEnum459535dab3'
        id:
          type: string
          format: uuid
          description: ID de la caja o caja fuerte.
      required:
        - type
        - id
      additionalProperties: false
    ApiSharedEnumd8087f784e:
      type: string
      enum:
        - not_required
        - pending
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: Incluí tu API key en el header Authorization con el prefijo Bearer.

````