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

> Registra una compra y devuelve la operación creada junto con sus efectos de stock y contabilidad.



## OpenAPI

````yaml /api-reference/openapi.json post /api/v1/purchases
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/purchases:
    post:
      tags:
        - API
      summary: Crear compra
      description: >-
        Registra una compra y devuelve la operación creada junto con sus efectos
        de stock y contabilidad.
      operationId: createApiPurchase
      parameters:
        - name: Idempotency-Key
          in: header
          description: >-
            Clave única para evitar duplicados al reintentar la misma creación
            de compra.
          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/ApiPurchaseTransactionRequest'
            examples:
              purchase_without_receipt:
                summary: Purchase invoice without receiving stock
                value:
                  supplier_id: afafcbec-9d94-4174-8d5c-ec8d72780947
                  voucher_type: 1
                  supplier_invoice_number: 0001-00000001
                  invoice_date: '2026-03-10'
                  currency: PES
                  exchange_rate: 1
                  products_received: false
                  update_product_variant_cost: true
                  items:
                    - product_id: 9c692e8b-0f9a-4f7c-8b99-061a2eb188ae
                      quantity: 1
                      unit_cost: 8250
                      tax_rate_id: 5
              service_expense_with_accounting_allocation:
                summary: Service expense with account and cost center
                value:
                  supplier_id: afafcbec-9d94-4174-8d5c-ec8d72780947
                  voucher_type: 1
                  supplier_invoice_number: 0001-00000003
                  invoice_date: '2026-03-10'
                  currency: PES
                  products_received: false
                  items:
                    - name: Meta Ads
                      quantity: 1
                      unit_cost: 100000
                      tax_rate_id: 5
                      account_id: 550e8400-e29b-41d4-a716-446655440301
                      cost_center_1_id: 550e8400-e29b-41d4-a716-446655440401
              totals_only_with_manual_accounts:
                summary: Totals-only purchase with manual account allocation
                value:
                  supplier_id: afafcbec-9d94-4174-8d5c-ec8d72780947
                  voucher_type: 1
                  supplier_invoice_number: 0001-00000004
                  invoice_date: '2026-03-10'
                  currency: PES
                  subtotal: 100000
                  tax_amount: 21000
                  total: 121000
                  iva_breakdown:
                    - tax_rate_id: 5
                      base_amount: 100000
                      tax_amount: 21000
                  manual_account_allocations:
                    gravado21: 550e8400-e29b-41d4-a716-446655440301
              purchase_with_receipt:
                summary: Purchase invoice receiving stock
                value:
                  supplier_id: afafcbec-9d94-4174-8d5c-ec8d72780947
                  voucher_type: 1
                  supplier_invoice_number: 0001-00000002
                  invoice_date: '2026-03-10'
                  currency: PES
                  exchange_rate: 1
                  products_received: true
                  warehouse_id: 550e8400-e29b-41d4-a716-446655440010
                  update_product_variant_cost: true
                  items:
                    - product_id: 9c692e8b-0f9a-4f7c-8b99-061a2eb188ae
                      quantity: 3
                      unit_cost: 8250
                      tax_rate_id: 5
      responses:
        '200':
          description: Compra creada exitosamente
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiPurchaseTransactionSuccessResponse'
              examples:
                created:
                  summary: Compra creada
                  value:
                    request_id: req_purchase_commit_1
                    data:
                      purchase_id: cf19b3ae-4c08-48be-b9d7-e6f2f5baf609
                      receipt_created: false
                      idempotent_replay: false
                      normalized_purchase:
                        supplier_id: afafcbec-9d94-4174-8d5c-ec8d72780947
                        voucher_type: 1
                        supplier_invoice_number: 0001-00000001
                        invoice_date: '2026-03-10'
                        account_date: null
                        due_date: null
                        payment_term_id: null
                        payment_term_days: null
                        import_document_role: null
                        import_source_purchase_id: null
                        import_nationalization_status: null
                        customs_dispatch_number: null
                        warehouse_id: null
                        products_received: false
                        update_product_variant_cost: true
                        currency: PES
                        exchange_rate: 1
                        subtotal: 8250
                        tax_amount: 1733
                        total: 9983
                        discount: 0
                        exempt_amount: 0
                        non_taxed_amount: null
                        base_amount: null
                        vat_perception_amount: null
                        national_tax_amount: null
                        gross_income_tax_amount: null
                        municipal_tax_amount: null
                        internal_tax_amount: null
                        other_tax_amount: null
                        notes: null
                        pdf_path: null
                        items: []
                      projected_effects:
                        inventory:
                          will_receive_products: false
                          will_create_receipt: false
                          will_increase_direct_stock: false
                          warehouse_id: null
                          product_line_count: 1
                          total_quantity: 1
                          purchase_order_ids: []
                        accounting:
                          will_create_journal_entry: true
                          currency: PES
                          exchange_rate: 1
                    warnings: []
        '400':
          description: Solicitud inválida
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiErrorEnvelope'
              examples:
                default:
                  summary: INVALID_REQUEST
                  value:
                    request_id: req_purchase_1
                    error:
                      code: INVALID_REQUEST
                      message: Invalid request for creating purchases
                      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_purchase_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_purchase_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_purchase_1
                    error:
                      code: IDEMPOTENCY_CONFLICT
                      message: >-
                        The same Idempotency-Key was already used with a
                        different purchase.
                      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_purchase_1
                    error:
                      code: PRECONDITION_FAILED
                      message: >-
                        The purchase could not be created because a business
                        precondition failed.
                      retryable: false
                      details:
                        - field: input.items
                          code: INVENTORY
                          message: >-
                            Stock insuficiente. Stock actual: -34, cambio
                            solicitado: 1
                      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_purchase_1
                    error:
                      code: INTERNAL_ERROR
                      message: Could not process the purchase transaction
                      retryable: false
                      type: invalid_request_error
                      details: []
components:
  schemas:
    ApiPurchaseTransactionRequest:
      type: object
      properties:
        supplier_id:
          type: string
          format: uuid
        voucher_type:
          type: integer
          minimum: 1
        import_document_role:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedEnum9e7af09974'
            - type: 'null'
          description: Rol del comprobante dentro del flujo de importacion.
        import_source_purchase_id:
          description: ID de la factura comercial asociada al despacho aduanero.
          type: string
          format: uuid
        import_nationalization_status:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedEnumf0d69c3d87'
            - type: 'null'
          description: Estado de nacionalizacion de la factura comercial de importacion.
        customs_dispatch_number:
          description: >-
            Numero de despacho aduanero informado por el proveedor. Hasta 32
            caracteres.
          type: string
        supplier_invoice_number:
          description: Numero de comprobante del proveedor. Hasta 120 caracteres.
          type: string
        invoice_date:
          description: Fecha del comprobante en formato YYYY-MM-DD.
          type: string
          format: date
        account_date:
          description: Fecha contable de la compra en formato YYYY-MM-DD.
          type: string
          format: date
        due_date:
          description: Fecha de vencimiento en formato YYYY-MM-DD.
          type: string
          format: date
        payment_term_id:
          anyOf:
            - anyOf:
                - $ref: '#/components/schemas/ApiSharedEnumd34af90520'
                - type: 'null'
            - type: 'null'
        payment_term_days:
          anyOf:
            - type: integer
              minimum: 0
              maximum: 365
              description: >-
                Cantidad de días hasta el vencimiento. Usá 0 para Contado. Se
                prefiere sobre paymentTermId.
            - type: 'null'
        vat_perception_amount:
          type: integer
          minimum: 0
        national_tax_amount:
          type: integer
          minimum: 0
        gross_income_tax_amount:
          type: integer
          minimum: 0
        gross_income_tax_breakdown:
          type: array
          items:
            $ref: '#/components/schemas/ApiSharedObject95929ea589'
        municipal_tax_amount:
          type: integer
          minimum: 0
        internal_tax_amount:
          type: integer
          minimum: 0
        other_tax_amount:
          type: integer
          minimum: 0
        warehouse_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        products_received:
          type: boolean
        update_product_variant_cost:
          type: boolean
        items:
          type: array
          items:
            $ref: '#/components/schemas/ApiSharedObject65e544dba2'
        subtotal:
          type: integer
          minimum: 0
        tax_amount:
          type: integer
          minimum: 0
        total:
          type: integer
          minimum: 0
        discount:
          type: integer
          minimum: 0
        exempt_amount:
          type: integer
          minimum: 0
        non_taxed_amount:
          type: integer
          minimum: 0
        base_amount:
          type: integer
          minimum: 0
        vat_breakdown:
          type: array
          items:
            $ref: '#/components/schemas/ApiSharedObjectfb7405a472'
        manual_account_allocations:
          $ref: '#/components/schemas/ApiSharedObjectbea003a73d'
        notes:
          type: string
        currency:
          $ref: '#/components/schemas/ApiSharedEnum6cfb146157'
        exchange_rate:
          type: number
          exclusiveMinimum: 0
        pdf_path:
          type: string
        vat_category:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedEnum822a963f55'
            - type: 'null'
        status:
          type: string
          enum:
            - draft
            - confirmed
      required:
        - voucher_type
        - currency
      additionalProperties: false
    ApiPurchaseTransactionSuccessResponse:
      $ref: '#/components/schemas/ApiPurchaseCommitResponse'
    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
    ApiSharedEnum9e7af09974:
      type: string
      enum:
        - commercial_invoice
        - customs_dispatch
        - customs_dispatch_reversal
    ApiSharedEnumf0d69c3d87:
      type: string
      enum:
        - pending_nationalization
        - partially_nationalized
        - fully_nationalized
    ApiSharedEnumd34af90520:
      type: string
      enum:
        - days_7
        - days_15
        - days_30
        - days_45
        - days_60
        - days_90
        - days_30_60
        - days_30_60_90
    ApiSharedObject95929ea589:
      type: object
      properties:
        province_id:
          type: integer
        amount:
          type: integer
          minimum: 0
      required:
        - province_id
        - amount
      additionalProperties: false
    ApiSharedObject65e544dba2:
      type: object
      properties:
        product_id:
          type: string
          format: uuid
        name:
          type: string
        quantity:
          type: number
          exclusiveMinimum: 0
        unit_cost:
          type: integer
          minimum: 0
        subtotal:
          type: integer
          minimum: 0
        total:
          type: integer
          minimum: 0
        tax_rate_id:
          type: integer
          minimum: 0
        is_exempt:
          type: boolean
        discount_percentage:
          type: number
          minimum: 0
          maximum: 100
        purchase_order_item_id:
          type: string
          format: uuid
        vat_category:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedEnum822a963f55'
            - type: 'null'
        account_id:
          description: ID de cuenta contable imputable de Activo o Gasto para este renglon.
          type: string
          format: uuid
        cost_center1_id:
          type: string
          format: uuid
        cost_center2_id:
          type: string
          format: uuid
        cost_center3_id:
          type: string
          format: uuid
      required:
        - quantity
        - unit_cost
      additionalProperties: false
    ApiSharedObjectfb7405a472:
      type: object
      properties:
        tax_rate_id:
          type: integer
          minimum: 0
        base_amount:
          type: integer
          minimum: 0
        tax_amount:
          type: integer
          minimum: 0
      required:
        - tax_rate_id
        - base_amount
        - tax_amount
      additionalProperties: false
    ApiSharedObjectbea003a73d:
      type: object
      properties:
        gravado21:
          type: string
          format: uuid
        gravado27:
          type: string
          format: uuid
        gravado105:
          type: string
          format: uuid
        gravado25:
          type: string
          format: uuid
        gravado5:
          type: string
          format: uuid
        non_taxed_amount:
          type: string
          format: uuid
        exento:
          type: string
          format: uuid
        base_amount:
          type: string
          format: uuid
      additionalProperties: false
    ApiSharedEnum6cfb146157:
      type: string
      enum:
        - PES
        - DOL
    ApiSharedEnum822a963f55:
      type: string
      enum:
        - goods
        - fixed_assets
        - leases
        - services
    ApiPurchaseCommitResponse:
      type: object
      properties:
        request_id:
          type: string
        data:
          type: object
          properties:
            purchase_id:
              type: string
              format: uuid
            receipt_created:
              type: boolean
            idempotent_replay:
              type: boolean
            normalized_purchase:
              type: object
              properties:
                supplier_id:
                  anyOf:
                    - type: string
                      format: uuid
                    - type: 'null'
                voucher_type:
                  type: integer
                  minimum: 1
                supplier_invoice_number:
                  anyOf:
                    - type: string
                    - type: 'null'
                  description: Numero de comprobante del proveedor. Hasta 120 caracteres.
                invoice_date:
                  anyOf:
                    - type: string
                    - type: 'null'
                  description: Fecha del comprobante en formato YYYY-MM-DD.
                account_date:
                  anyOf:
                    - type: string
                    - type: 'null'
                  description: Fecha contable de la compra en formato YYYY-MM-DD.
                due_date:
                  anyOf:
                    - type: string
                    - type: 'null'
                  description: Fecha de vencimiento en formato YYYY-MM-DD.
                payment_term_id:
                  anyOf:
                    - $ref: '#/components/schemas/ApiSharedEnumd34af90520'
                    - type: 'null'
                payment_term_days:
                  anyOf:
                    - type: integer
                      minimum: 0
                      maximum: 365
                      description: >-
                        Cantidad de días hasta el vencimiento. Usá 0 para
                        Contado. Se prefiere sobre paymentTermId.
                    - type: 'null'
                import_document_role:
                  anyOf:
                    - $ref: '#/components/schemas/ApiSharedEnum9e7af09974'
                    - type: 'null'
                  description: Rol del comprobante dentro del flujo de importacion.
                import_source_purchase_id:
                  anyOf:
                    - type: string
                      format: uuid
                    - type: 'null'
                  description: ID de la factura comercial asociada al despacho aduanero.
                import_nationalization_status:
                  anyOf:
                    - $ref: '#/components/schemas/ApiSharedEnumf0d69c3d87'
                    - type: 'null'
                  description: >-
                    Estado de nacionalizacion de la factura comercial de
                    importacion.
                customs_dispatch_number:
                  anyOf:
                    - type: string
                    - type: 'null'
                  description: >-
                    Numero de despacho aduanero informado por el proveedor.
                    Hasta 32 caracteres.
                warehouse_id:
                  anyOf:
                    - type: string
                      format: uuid
                    - type: 'null'
                products_received:
                  type: boolean
                update_product_variant_cost:
                  type: boolean
                currency:
                  $ref: '#/components/schemas/ApiSharedEnum6cfb146157'
                exchange_rate:
                  type: number
                  exclusiveMinimum: 0
                subtotal:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                tax_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                total:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                discount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                exempt_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                non_taxed_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                base_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                vat_perception_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                national_tax_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                gross_income_tax_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                municipal_tax_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                internal_tax_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                other_tax_amount:
                  anyOf:
                    - type: integer
                      minimum: 0
                    - type: 'null'
                notes:
                  anyOf:
                    - type: string
                    - type: 'null'
                pdf_path:
                  anyOf:
                    - type: string
                    - type: 'null'
                manual_account_allocations:
                  type: object
                  propertyNames:
                    type: string
                  additionalProperties:
                    type: string
                items:
                  type: array
                  items:
                    $ref: '#/components/schemas/ApiSharedObjectbf19ed87b4'
              required:
                - supplier_id
                - voucher_type
                - supplier_invoice_number
                - invoice_date
                - account_date
                - due_date
                - payment_term_id
                - payment_term_days
                - import_document_role
                - import_source_purchase_id
                - import_nationalization_status
                - customs_dispatch_number
                - warehouse_id
                - products_received
                - update_product_variant_cost
                - currency
                - exchange_rate
                - subtotal
                - tax_amount
                - total
                - discount
                - exempt_amount
                - non_taxed_amount
                - base_amount
                - vat_perception_amount
                - national_tax_amount
                - gross_income_tax_amount
                - municipal_tax_amount
                - internal_tax_amount
                - other_tax_amount
                - notes
                - pdf_path
                - manual_account_allocations
                - items
              additionalProperties: false
            projected_effects:
              type: object
              properties:
                inventory:
                  $ref: '#/components/schemas/ApiSharedObjectdafaa4a9ee'
                accounting:
                  $ref: '#/components/schemas/ApiSharedObject3c43192c61'
              required:
                - inventory
                - accounting
              additionalProperties: false
          required:
            - purchase_id
            - receipt_created
            - idempotent_replay
            - normalized_purchase
            - projected_effects
          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
    ApiSharedObjectbf19ed87b4:
      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'
        name:
          anyOf:
            - type: string
            - type: 'null'
        quantity:
          type: number
          exclusiveMinimum: 0
        unit_cost:
          type: integer
          minimum: 0
        subtotal:
          anyOf:
            - type: integer
              minimum: 0
            - type: 'null'
        total:
          anyOf:
            - type: integer
              minimum: 0
            - type: 'null'
        tax_rate_id:
          anyOf:
            - type: integer
              minimum: 0
            - type: 'null'
        is_exempt:
          type: boolean
        discount_percentage:
          anyOf:
            - type: number
              minimum: 0
              maximum: 100
            - type: 'null'
        purchase_order_item_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        vat_category:
          anyOf:
            - $ref: '#/components/schemas/ApiSharedEnum822a963f55'
            - type: 'null'
        account_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        account_name:
          anyOf:
            - type: string
            - type: 'null'
        cost_center1_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        cost_center1_name:
          anyOf:
            - type: string
            - type: 'null'
        cost_center2_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        cost_center2_name:
          anyOf:
            - type: string
            - type: 'null'
        cost_center3_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        cost_center3_name:
          anyOf:
            - type: string
            - type: 'null'
      required:
        - product_id
        - product_name
        - sku
        - name
        - quantity
        - unit_cost
        - subtotal
        - total
        - tax_rate_id
        - is_exempt
        - discount_percentage
        - purchase_order_item_id
        - vat_category
        - account_id
        - account_name
        - cost_center1_id
        - cost_center1_name
        - cost_center2_id
        - cost_center2_name
        - cost_center3_id
        - cost_center3_name
      additionalProperties: false
    ApiSharedObjectdafaa4a9ee:
      type: object
      properties:
        will_receive_products:
          type: boolean
        will_create_receipt:
          type: boolean
        will_increase_direct_stock:
          type: boolean
        warehouse_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
        product_line_count:
          type: integer
          minimum: 0
        total_quantity:
          type: number
          minimum: 0
        purchase_order_ids:
          type: array
          items:
            type: string
            format: uuid
      required:
        - will_receive_products
        - will_create_receipt
        - will_increase_direct_stock
        - warehouse_id
        - product_line_count
        - total_quantity
        - purchase_order_ids
      additionalProperties: false
    ApiSharedObject3c43192c61:
      type: object
      properties:
        will_create_journal_entry:
          type: boolean
        currency:
          $ref: '#/components/schemas/ApiSharedEnum6cfb146157'
        exchange_rate:
          type: number
          exclusiveMinimum: 0
      required:
        - will_create_journal_entry
        - currency
        - exchange_rate
      additionalProperties: false
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: Incluí tu API key en el header Authorization con el prefijo Bearer.

````