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

> ## Agent Instructions
> Test in the sandbox first: base URL https://api-sandbox.y.uno (Test Mode in the Dashboard). Production is https://api.y.uno (Live Mode).
> Every API request needs the public-api-key and private-secret-key headers. Get them in the Dashboard at https://dashboard.y.uno/developers (Developers > Credentials); sandbox and production keys are different.
> Send an X-Idempotency-Key (a UUID) when creating payments, refunds and cancels, so retries do not create duplicates.
> Start with the Quickstart (https://docs.y.uno/docs/quickstart.md) and the agent guide (https://docs.y.uno/agents.md). To search these docs from a coding agent, connect the docs MCP server at https://docs.y.uno/mcp.

# Capturar autorización

> Captura un pago previamente autorizado, de forma parcial o total según el proveedor.

> [!WARNING]
>
> No ejecutes una captura mientras otra está en curso. Espera a que la operación actual termine antes de iniciar una nueva.

Esta solicitud captura un pago que fue autorizado previamente. Esta acción es necesaria para finalizar un pago cuando una autorización se creó con la opción de captura en `false`. Según el proveedor de pago, la captura puede ser parcial (incluidas varias capturas) o total. El `amount` es opcional: si lo omites, la API captura el monto autorizado completo. Una captura mayor que la autorización se envía al proveedor, que decide si la acepta.

> [!NOTE]
>
> **Pagos con una promoción de Yuno**
>
> El monto autorizado es lo que paga el cliente, `amount.value` menos `discount_amount`, por lo que una captura completa toma ese monto y `payment.amount.captured` lo refleja. Consulta [Promotions](https://docs.y.uno/es/docs/payment-features/promotions#refunds-captures-and-cancellations).

> [!NOTE]
>
> **Pagos aprobados parcialmente**
>
> Para un pago enviado con `payment_method.detail.card.partial_approval: true` y aprobado por menos de lo solicitado, el monto autorizado es `payment.amount.authorized`. Una captura sin `amount` captura `amount.authorized`, y capturarlo todo completa la captura. Una captura por encima de `amount.authorized` se rechaza con `400 INVALID_PARAMETERS` y el mensaje "Amount to capture exceeds the authorized amount." Para cualquier otro pago, la captura funciona como se describe arriba.

Si la autorización se aumentó con [autorizaciones incrementales](https://docs.y.uno/es/reference/payments/increment-authorization.md), un `amount` explícito puede liquidar hasta el total aumentado, y una captura sin `amount` liquida la retención actual completa de la transacción: el monto autorizado original más todos los incrementos exitosos de esa transacción.

Ten en cuenta que esta solicitud requiere un `X-Idempotency-Key`. Consulta la página [Authentication](https://docs.y.uno/es/reference/getting-started/authentication.md#idempotency) para obtener más información.


## OpenAPI

````yaml openapi/es/payments/capture-authorization.json POST /payments/{payment_id}/transactions/{transaction_id}/capture
openapi: 3.1.0
info:
  title: payment-api-refundcancel-payment
  version: 1.0.2
servers:
  - url: https://api-sandbox.y.uno/v1
    description: Sandbox
  - url: https://api.y.uno/v1
    description: Production (US)
security:
  - sec0: []
    sec1: []
    sec2: []
paths:
  /payments/{payment_id}/transactions/{transaction_id}/capture:
    post:
      summary: Capturar autorización
      operationId: capture-authorization
      parameters:
        - name: payment_id
          in: path
          description: El identificador único del pago (UUID, 36 caracteres).
          schema:
            type: string
          required: true
        - name: transaction_id
          in: path
          description: El identificador único de la transacción (UUID, 36 caracteres)
          schema:
            type: string
          required: true
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - merchant_reference
                - reason
              properties:
                merchant_reference:
                  type: string
                  description: >-
                    Identificación de la transacción de pago definida por el
                    comercio (MAX 255; MIN 3)
                amount:
                  type: object
                  description: >-
                    Especifica el objeto de monto para la captura. Opcional: si
                    lo omites, la API captura el monto autorizado completo.
                  required:
                    - currency
                    - value
                  properties:
                    currency:
                      type: string
                      description: >-
                        La moneda con la que se hace el pago. Para ver la lista
                        completa de códigos de moneda, consulta [Country
                        reference](/es/reference/country-reference) (MAX 3; MIN
                        3; ISO 4217).
                    value:
                      type: number
                      description: El monto del pago (múltiplo de 0.0001).
                      format: float
                reason:
                  type: string
                  description: >-
                    Indica el motivo de la captura. Por ejemplo:
                    PRODUCT_CONFIRMED y REQUESTED_BY_CUSTOMER.
                additional_data:
                  type: object
                  description: Datos adicionales para complementar la captura del pago
                  properties:
                    order:
                      type: object
                      description: Indica el objeto order.
                      properties:
                        shipping_amount:
                          type: number
                          description: El monto de envío de la orden (múltiplo de 0.0001)
                          format: float
                        fee_amount:
                          type: number
                          description: >-
                            El monto de la comisión de la orden (múltiplo de
                            0.0001)
                          format: float
                        items:
                          type: array
                          description: Indica el array de objetos items.
                          items:
                            properties:
                              id:
                                type: string
                                description: >-
                                  El identificador único del artículo (MAX 255;
                                  MIN 3).
                              name:
                                type: string
                                description: El nombre del artículo (MAX 255; MIN 3).
                              quantity:
                                type: integer
                                description: La cantidad del artículo.
                                format: int32
                              unit_amount:
                                type: number
                                description: >-
                                  El monto unitario del artículo (múltiplo de
                                  0.0001).
                                format: float
                              category:
                                type: string
                                description: >-
                                  La categoría del artículo. Consulta [Item
                                  category
                                  reference](/es/reference/items-category-list).
                                enum:
                                  - art
                                  - baby
                                  - coupons
                                  - beauty_&_personal_care
                                  - donations
                                  - computing
                                  - books
                                  - grocery_&_gourmet_food
                                  - cameras
                                  - video_games
                                  - television
                                  - car_electronics
                                  - electronics
                                  - automotive
                                  - toys_&_games
                                  - musical_instruments
                                  - handmade
                                  - garden_&_outdoor
                                  - entertainment
                                  - industrial_&_scientific
                                  - fashion
                                  - games
                                  - pet_supplies
                                  - home
                                  - musical
                                  - phones
                                  - services
                                  - learnings
                                  - tickets
                                  - travels
                                  - virtual_goods
                                  - others
                              brand:
                                type: string
                                description: La marca del artículo (MAX 255; MIN 3).
                              sku_code:
                                type: string
                                description: >-
                                  La unidad de mantenimiento de stock (SKU) del
                                  artículo (MAX 255; MIN 3).
                              manufacture_part_number:
                                type: string
                                description: El número de parte del fabricante del artículo
                            required:
                              - id
                              - name
                              - quantity
                              - unit_amount
                            type: object
                    airline:
                      type: object
                      description: Indica el objeto airline.
                      properties:
                        pnr:
                          type: string
                          description: >-
                            Registro del nombre del pasajero (PNR) (MAX 10; MIN
                            1).
                        legs:
                          type: array
                          description: Indica el array de objetos legs.
                          items:
                            properties:
                              departure_airport:
                                type: string
                                description: >-
                                  Código IATA. Consulta http://www.iata.org (MAX
                                  3; MIN 3).
                              departure_datetime:
                                type: string
                                description: >-
                                  La fecha y la hora de salida en UTC ([ISO
                                  8601](https://en.wikipedia.org/wiki/ISO_8601),
                                  MAX 27; MIN 27).
                                format: date-time
                              departure_airport_timezone:
                                type: string
                                description: Zona horaria del aeropuerto (MAX 6; MIN 6).
                              arrival_airport:
                                type: string
                                description: >-
                                  Código IATA del aeropuerto. Consulta
                                  http://www.iata.org (MAX 3; MIN 3).
                              carrier_code:
                                type: string
                                description: >-
                                  Código IATA de la aerolínea. Consulta
                                  http://www.iata.org (MAX 2; MIN 2).
                              carrier_name:
                                type: string
                                description: El nombre de la aerolínea (MAX 100; MIN 1).
                              flight_number:
                                type: string
                                description: >-
                                  El número de vuelo asignado por la aerolínea
                                  (MAX 5; MIN 1).
                              fare_basis_code:
                                type: string
                                description: >-
                                  El código de tarifa base da información
                                  específica sobre la tarifa además de la clase
                                  de servicio; ambos son necesarios para la
                                  reserva (MAX 15; MIN 1).
                              fare_class_code:
                                type: string
                                description: >-
                                  El código de clase tarifaria de la aerolínea
                                  (MAX 1; MIN 1). Los valores pueden ser una
                                  letra (A-Z), pero pueden variar según la
                                  definición de cada aerolínea. Consulta la
                                  [Airline information
                                  reference](/es/reference/airline-information#fare-class-code).
                                enum:
                                  - F
                                  - FR
                                  - B
                                  - CR
                                  - 'Y'
                                  - YD
                              base_fare:
                                type: number
                                description: >-
                                  El monto de la transacción, sin impuestos ni
                                  cargos, en la unidad más pequeña de la moneda
                                  (multipleOf 0.0001).
                                format: float
                              base_fare_currency:
                                type: string
                                description: >-
                                  La moneda usada para el monto de la
                                  transacción (MAX 3; MIN 3; [ISO
                                  4217](country-reference)).
                              stopover_code:
                                type: string
                                description: >-
                                  Código de 1 letra que indica si el pasajero
                                  puede hacer una escala. Solo se permiten dos
                                  caracteres: O: escala permitida (la letra “O”,
                                  no el cero) / X: escala no permitida. (MAX 1;
                                  MIN 1)
                            required:
                              - departure_airport
                              - departure_datetime
                              - departure_airport_timezone
                              - arrival_airport
                              - carrier_code
                              - flight_number
                              - fare_basis_code
                              - fare_class_code
                            type: object
                        passengers:
                          type: array
                          description: >-
                            Especifica el arreglo de objetos de pasajeros
                            asociados a los boletos.
                          items:
                            properties:
                              first_name:
                                type: string
                                description: El nombre del pasajero (MAX 255; MIN 3).
                              last_name:
                                type: string
                                description: El apellido del pasajero (MAX 255; MIN 3)
                              middle_name:
                                type: string
                                description: >-
                                  El segundo nombre del pasajero (MAX 255; MIN
                                  3).
                              type:
                                type: string
                                description: >-
                                  El tipo de pasajero (MAX 1; MIN 1). Consulta
                                  la [Airline information
                                  reference](/es/reference/airline-information#passenger-type).
                                enum:
                                  - A
                                  - C
                                  - I
                              date_of_birth:
                                type: string
                                description: >-
                                  La fecha de nacimiento del pasajero en formato
                                  YYYY-MM-DD (MAX 10; MIN 10).
                                format: date
                              nationality:
                                type: string
                                description: >-
                                  La nacionalidad del pasajero (MAX 2; MIN 2;
                                  [ISO 3166-1](country-reference)).
                                enum:
                                  - AR
                                  - BO
                                  - BR
                                  - CL
                                  - CO
                                  - CR
                                  - EC
                                  - SV
                                  - GT
                                  - HN
                                  - MX
                                  - NI
                                  - PA
                                  - PY
                                  - PE
                                  - US
                                  - UY
                              document:
                                type: object
                                description: >-
                                  Especifica el objeto de documento de los
                                  pasajeros.
                                properties:
                                  document_number:
                                    type: string
                                    description: >-
                                      Número de documento del pasajero (MAX 40;
                                      MIN 3).
                                  document_type:
                                    type: string
                                    description: >-
                                      El tipo de documento del pasajero (MAX 6,
                                      MIN 2; ([referencia de
                                      países](country-reference))).
                                    enum:
                                      - DNI
                                      - CI
                                      - LC
                                      - LE
                                      - CUIT
                                      - CUIL
                                      - PAS
                                      - CPF
                                      - RG
                                      - CNH
                                      - CNPJ
                                      - RUT
                                      - RUN
                                      - CC
                                      - CE
                                      - NIT
                                      - DUI
                                      - PIC
                                      - DPI
                                      - IFR
                                      - INE
                                      - CP
                                      - RFC
                                      - CURP
                                      - CIP
                                      - CIC
                                      - CUI
                                      - RUC
                                      - ''
                                  country:
                                    type: string
                                    description: >-
                                      País donde se emitió el documento (MAX 2;
                                      MIN 2; [ISO 3166-1](country-reference)).
                                    enum:
                                      - AR
                                      - BO
                                      - BR
                                      - CL
                                      - CO
                                      - CR
                                      - EC
                                      - SV
                                      - GT
                                      - HN
                                      - MX
                                      - NI
                                      - PA
                                      - PY
                                      - PE
                                      - US
                                      - UY
                              loyalty_number:
                                type: string
                                description: Número del programa de fidelidad del pasajero.
                              loyalty_tier:
                                type: string
                                description: >-
                                  Nivel del programa de fidelidad del pasajero.
                                  Consulta la [Airline information
                                  reference](/es/reference/airline-information#loyalty-tier).
                                enum:
                                  - '1'
                                  - '2'
                                  - '3'
                              phone:
                                type: object
                                description: Indica el objeto del teléfono del pasajero.
                            type: object
                        tickets:
                          type: array
                          description: >-
                            Especifica el arreglo de objetos de boletos
                            asociados a los pasajeros.
                          items:
                            properties:
                              ticket_number:
                                type: string
                                description: Número de boleto (MAX 14; MIN 1).
                              e_ticket:
                                type: boolean
                                description: ¿Es un boleto electrónico?  (true) (false).
                              restricted:
                                type: boolean
                                description: >-
                                  Indica si el boleto es reembolsable o no
                                  (true/false)
                              total_fare_amount:
                                type: number
                                description: >-
                                  Monto total de la tarifa en la unidad más
                                  pequeña de la moneda (múltiplo de 0.0001).
                                format: float
                              total_tax_amount:
                                type: number
                                description: >-
                                  Monto total de impuestos en la unidad más
                                  pequeña de la moneda (múltiplo de 0.0001).
                                format: float
                              total_fee_amount:
                                type: number
                                description: >-
                                  Monto total de cargos en la unidad más pequeña
                                  de la moneda (múltiplo de 0.0001).
                                format: float
                              issue:
                                type: object
                                description: Indica el objeto issue.
                                properties:
                                  carrier_prefix_code:
                                    type: string
                                    description: >-
                                      Aerolínea emisora o validadora. Es el
                                      código numérico de 3 dígitos del prefijo
                                      AWB (Air waybill) (MAX 3; MIN 3).
                                  travel_agent_code:
                                    type: string
                                    description: >-
                                      Código del agente de viajes que emite el
                                      boleto (MAX 9; MIN 8).
                                  travel_agent_name:
                                    type: string
                                    description: >-
                                      El nombre con el que aparece el punto de
                                      venta en la lista de agencias, o el nombre
                                      de la franquicia (MAX 32; MIN 1).
                                  date:
                                    type: string
                                    description: >-
                                      Fecha de emisión del boleto (MAX 27; MIN
                                      27).
                                    format: date-time
                                  address:
                                    type: string
                                    description: >-
                                      Dirección del agente que vendió el boleto
                                      (MAX 255; MIN 3).
                                  city:
                                    type: string
                                    description: >-
                                      Ciudad del agente que vendió el boleto
                                      (MAX 255; MIN 3).
                                  country:
                                    type: string
                                    description: >-
                                      Código de país alpha-2 donde se emitió el
                                      boleto (MAX 2; MIN 2; [ISO
                                      3166-1](country-reference)).
                                    enum:
                                      - AR
                                      - BO
                                      - BR
                                      - CL
                                      - CO
                                      - CR
                                      - EC
                                      - SV
                                      - GT
                                      - HN
                                      - MX
                                      - NI
                                      - PA
                                      - PY
                                      - PE
                                      - US
                                      - UY
                            type: object
                    seller_details:
                      type: object
                      description: Especifica el objeto con los detalles del vendedor.
                      properties:
                        name:
                          type: string
                          description: La razón social del vendedor (MAX 255; MIN 3).
                        email:
                          type: string
                          description: El email del vendedor (MAX 255; MIN 3).
                        reference:
                          type: number
                          description: >-
                            El código de identificación del vendedor (MAX 255;
                            MIN 3).
                          format: float
                        website:
                          type: string
                          description: La URL del sitio web del vendedor (MAX 255; MIN 3).
                        industry:
                          type: string
                          description: >-
                            La industria del vendedor (MAX 235; MIN 1). Para más
                            información, consulta la [Industry category
                            reference](/es/reference/industry-category-list).
                        merchant_category_code:
                          type: string
                          description: >-
                            MCC: el código de categoría del comercio (MAX 235;
                            MIN 1).
                        country:
                          type: string
                          description: >-
                            El país del vendedor (MAX 255; MIN 3; [ISO
                            3166-1](/es/reference/country-reference)).
                          enum:
                            - AR
                            - BO
                            - BR
                            - CL
                            - CO
                            - CR
                            - EC
                            - SV
                            - GT
                            - HN
                            - MX
                            - NI
                            - PA
                            - PY
                            - PE
                            - US
                            - UY
                            - ''
                        document:
                          type: object
                          description: Indica el objeto del documento del vendedor.
                          properties:
                            document_number:
                              type: string
                              description: >-
                                El número de documento del vendedor (MAX 40; MIN
                                3).
                            document_type:
                              type: string
                              description: >-
                                El tipo de documento del vendedor (MAX 6, MIN 2;
                                [lista de tipos de
                                documento](/es/reference/country-reference)).
                              enum:
                                - DNI
                                - CI
                                - LC
                                - LE
                                - CUIT
                                - CUIL
                                - PAS
                                - CPF
                                - RG
                                - CNH
                                - CNPJ
                                - RUT
                                - RUN
                                - CC
                                - CE
                                - NIT
                                - DUI
                                - PIC
                                - DPI
                                - IFR
                                - INE
                                - CP
                                - RFC
                                - CURP
                                - CIP
                                - CIC
                                - CUI
                                - RUC
                                - ''
                        phone:
                          type: object
                          description: >-
                            Indica el objeto del número de teléfono del
                            vendedor.
                          properties:
                            country_code:
                              type: string
                              description: >-
                                El código de país del teléfono del vendedor (MAX
                                3; MIN 1). Consulta la [Country
                                reference](country-reference) para ver los
                                códigos telefónicos.
                            number:
                              type: string
                              description: >-
                                El número de teléfono del vendedor, sin el
                                código de país (MAX 32; MIN 1).
                        address:
                          type: object
                          description: Indica el objeto de la dirección del vendedor.
                          properties:
                            address_line_1:
                              type: string
                              description: >-
                                La línea principal de la dirección del vendedor
                                (MAX 255; MIN 3).
                            address_line_2:
                              type: string
                              description: >-
                                La línea secundaria de la dirección de
                                facturación del vendedor (MAX 255; MIN 3).
                            city:
                              type: string
                              description: >-
                                La ciudad de la dirección del vendedor (MAX 255;
                                MIN 3).
                            country:
                              type: string
                              description: >-
                                El país de la dirección del vendedor (MAX 2; MIN
                                2; [ISO
                                3166-1](/es/reference/country-reference)).
                              enum:
                                - AR
                                - BO
                                - BR
                                - CL
                                - CO
                                - CR
                                - EC
                                - SV
                                - GT
                                - HN
                                - MX
                                - NI
                                - PA
                                - PY
                                - PE
                                - US
                                - UY
                                - ''
                            state:
                              type: string
                              description: >-
                                El estado considerado para la dirección del
                                vendedor (MAX 255; MIN 3).
                            zip_code:
                              type: string
                              description: >-
                                El código postal de la dirección del vendedor
                                (MAX 11; MIN 4).
                simplified_mode:
                  type: boolean
                  description: >-
                    Determina si Yuno debe intentar capturar automáticamente un
                    pago después de un error o rechazo inicial. Cuando se
                    establece en `true`, Yuno reintenta el proceso si el primer
                    intento falla. Por defecto, es `false`. Accede a [Reintentos
                    de
                    transacciones](https://docs.y.uno/es/docs/payment-features/transaction-retries)
                    para más detalles.
            examples:
              Full Capture:
                value:
                  amount:
                    currency: USD
                    value: 5000
                  description: Confirmed
                  reason: PRODUCT_CONFIRMED
                  merchant_reference: AAB01-432245
              Card Direct (with Airline Data):
                value:
                  merchant_reference: EJEMPLO_DE_REFERENCIA
                  amount:
                    currency: USD
                    value: '2000'
                  reason: PRODUCT_CONFIRMED
                  additional_data:
                    airline:
                      pnr: ABC123
                      legs:
                        - departure_airport: JFK
                          departure_datetime: '2023-10-31T01:30:00.000-05:00'
                          departure_airport_timezone: GMT-05
                          arrival_airport: LAX
                          carrier_code: AA
                          carrier_name: American Airlines
                          flight_number: AA348
                          fare_basis_code: 'Y'
                          fare_class_code: S
                          base_fare: 18000
                          base_fare_currency: USD
                          stopover_code: O
                      passengers:
                        - first_name: JOHN
                          last_name: DOE
                          middle_name: STEPHEN
                          type: A
                          date_of_birth: '1998-01-01'
                          nationality: US
                          document:
                            document_number: '123456789'
                            document_type: PASSPORT
                            country: US
                          loyalty_number: '79250001'
                          loyalty_tier: DIAMOND
                      tickets:
                        - ticket_number: AA0001
                          e_ticket: true
                          restricted: false
                          total_fare_amount: 20000
                          total_tax_amount: 18000
                          total_fee_amount: 1000
                          issue:
                            carrier_prefix_code: AA
                            travel_agent_code: A104121
                            travel_agent_name: TRAVELPRO
                            date: '2023-10-31T01:30:00.000-05:00'
                            address: 123 Main Street
                            city: NEW YORK
                            country: US
                            zip_code: '10001'
              Partial Capture:
                value:
                  amount:
                    currency: USD
                    value: 3000
                  description: Confirmed Partially
                  reason: PRODUCT_CONFIRMED
                  merchant_reference: AAB01-432245
      responses:
        '201':
          description: '201'
          content:
            application/json:
              examples:
                Full Capture:
                  value:
                    id: 89fd7fd0-951d-4335-ad1b-ef899a79630d
                    type: CAPTURE
                    status: SUCCEEDED
                    category: CARD
                    amount:
                      captured: 0
                      currency: USD
                      refunded: 0
                      value: 5000
                    merchant_reference: AAB01-432245
                    created_at: '2024-06-06T14:26:41.535489Z'
                    updated_at: '2024-06-06T14:26:41.615608Z'
                    provider_data:
                      id: YUNO_TEST_PAYMENT_GW
                      transaction_id: 1173513e-2422-4ba0-ba40-fd568a4904f9
                      account_id: 493e9374-510a-4201-9e09-de669d75f256
                      status: SUCCEEDED
                      status_detail: ''
                      response_message: Transaction successful
                      response_code: ''
                      iso8583_response_code: '00'
                      iso8583_response_message: Approved or completed successfully
                      raw_request:
                        amount:
                          currency: BRL
                          value: 2100
                        reference: '34343434'
                      raw_response: null
                      third_party_transaction_id: null
                      third_party_account_id: null
                    connection_data:
                      id: 58cc35f4-faef-4107-8e09-d18d60121d38
                      name: Connection name
                    response_code: SUCCEEDED
                    response_message: Transaction successful
                    payment:
                      id: af170f9d-e8c1-47e4-a988-25535e0f88a1
                      account_id: ''
                      description: Test
                      country: US
                      status: SUCCEEDED
                      sub_status: CAPTURED
                      merchant_order_id: '0000023'
                      created_at: '2024-06-06T14:26:22.933194Z'
                      updated_at: '2024-06-06T14:26:41.655119Z'
                      amount:
                        captured: 5000
                        currency: USD
                        refunded: 0
                        value: 5000
                      additional_data:
                        airline: null
                        order: null
                        seller_details: null
                CARD DIRECT (with Airline Data):
                  value:
                    id: 230292dd-b3e9-41e4-ae09-0a54e2f7a6d4
                    type: CAPTURE
                    status: SUCCEEDED
                    category: CARD
                    amount:
                      currency: USD
                      value: 20000
                      refunded: 0
                      captured: 0
                    merchant_reference: EJEMPLO_DE_REFERENCIA
                    created_at: '2023-04-27T02:51:52.213075Z'
                    updated_at: '2023-04-27T02:51:52.284381Z'
                    provider_data:
                      id: YUNO_TEST_PAYMENT_GW
                      transaction_id: a9a47e01-2dc1-4d5f-af23-11ab7164cd03
                      account_id: 493e9374-510a-4201-9e09-de669d75f256
                      status: SUCCEEDED
                      status_detail: ''
                      response_message: Transaction successful
                      response_code: ''
                      iso8583_response_code: '00'
                      iso8583_response_message: Approved or completed successfully
                      raw_response: null
                      third_party_transaction_id: null
                      third_party_account_id: null
                    connection_data:
                      id: 58cc35f4-faef-4107-8e09-d18d60121d38
                      name: Connection name
                    response_code: SUCCEEDED
                    response_message: Transaction successful
                    payment:
                      id: 637dffe9-5d18-4cdc-a5bf-95b8cd12bbd5
                      account_id: ''
                      description: SUCCESSFUL
                      country: US
                      status: SUCCEEDED
                      sub_status: CAPTURED
                      merchant_order_id: Order_id
                      created_at: '2023-04-27T02:51:24.470834Z'
                      updated_at: '2023-04-27T02:51:52.312297Z'
                      amount:
                        value: 20000
                        captured: 20000
                        refunded: 0
                        currency: USD
                      additional_data:
                        airline:
                          pnr: ABC123
                          legs:
                            - departure_airport: BOG
                              departure_datetime: '2023-10-31T01:30:00.000-05:00'
                              departure_airport_timezone: GMT-05
                              arrival_airport: BOM
                              carrier_code: PR
                              carrier_name: Philippine Airlines
                              flight_number: AV348
                              fare_basis_code: 'Y'
                              fare_class_code: S
                              base_fare: 18000
                              base_fare_currency: USD
                              stopover_code: O
                          passengers:
                            - first_name: JOHN
                              last_name: DOE
                              middle_name: STEPHEN
                              type: A
                              date_of_birth: '1998-01-01'
                              nationality: US
                              document:
                                document_type: SSN
                                document_number: 123-45-6789
                              country: null
                              loyalty_number: '79250001'
                              loyalty_tier: DIAMOND
                          tickets:
                            - ticket_number: BRB0001
                              e_ticket: true
                              restricted: false
                              total_fare_amount: 20000
                              total_tax_amount: 18000
                              total_fee_amount: 1000
                              issue:
                                carrier_prefix_code: '134'
                                travel_agent_code: A104121
                                travel_agent_name: AEROVIAJES
                                date: '2023-10-31T01:30:00.000-05:00'
                                address: 123 Main Street
                                city: New York
                                country: US
                                zip_code: '10001'
                        order: null
                        seller_details: null
                Partial Capture:
                  value:
                    id: c8104f4b-30d6-476f-8e6b-49daa110e31f
                    type: CAPTURE
                    status: SUCCEEDED
                    category: CARD
                    amount:
                      captured: 0
                      currency: USD
                      refunded: 0
                      value: 3000
                    merchant_reference: AAB01-432245
                    created_at: '2024-06-06T14:27:53.594183Z'
                    updated_at: '2024-06-06T14:27:53.705858Z'
                    provider_data:
                      id: YUNO_TEST_PAYMENT_GW
                      transaction_id: a9a47e01-2dc1-4d5f-af23-11ab7164cd03
                      account_id: 493e9374-510a-4201-9e09-de669d75f256
                      status: SUCCEEDED
                      status_detail: ''
                      response_message: Transaction successful
                      response_code: ''
                      iso8583_response_code: '00'
                      iso8583_response_message: Approved or completed successfully
                      raw_response: null
                      third_party_transaction_id: null
                      third_party_account_id: null
                    connection_data:
                      id: 58cc35f4-faef-4107-8e09-d18d60121d38
                      name: Connection name
                    response_code: SUCCEEDED
                    response_message: Transaction successful
                    payment:
                      id: 60915b59-e403-4c00-8404-15ececa9b5dd
                      account_id: ''
                      description: Test
                      country: US
                      status: SUCCEEDED
                      sub_status: PARTIALLY_CAPTURED
                      merchant_order_id: '0000023'
                      created_at: '2024-06-06T14:27:22.8355Z'
                      updated_at: '2024-06-06T14:27:53.74127Z'
                      amount:
                        captured: 3000
                        currency: USD
                        refunded: 0
                        value: 30000
                      additional_data:
                        airline: null
                        order: null
                        seller_details: null
              schema:
                oneOf:
                  - title: Captura total
                    type: object
                    properties:
                      id:
                        type: string
                        example: 89fd7fd0-951d-4335-ad1b-ef899a79630d
                      type:
                        type: string
                        example: CAPTURE
                      status:
                        type: string
                        example: SUCCEEDED
                      category:
                        type: string
                        example: CARD
                      amount:
                        type: object
                        properties:
                          captured:
                            type: integer
                            example: 0
                            default: 0
                          currency:
                            type: string
                            example: USD
                          refunded:
                            type: integer
                            example: 0
                            default: 0
                          value:
                            type: integer
                            example: 30000
                            default: 0
                      merchant_reference:
                        type: string
                        example: AAB01-432245
                      created_at:
                        type: string
                        example: '2024-06-06T14:26:41.535489Z'
                      updated_at:
                        type: string
                        example: '2024-06-06T14:26:41.615608Z'
                      provider_data:
                        type: object
                        properties:
                          id:
                            type: string
                            example: YUNO_TEST_PAYMENT_GW
                          transaction_id:
                            type: string
                            example: 1173513e-2422-4ba0-ba40-fd568a4904f9
                          account_id:
                            type: string
                            example: 493e9374-510a-4201-9e09-de669d75f256
                          status:
                            type: string
                            example: SUCCEEDED
                          status_detail:
                            type: string
                            example: ''
                          response_message:
                            type: string
                            example: Transaction successful
                          response_code:
                            type: string
                            example: ''
                          iso8583_response_code:
                            type: string
                            example: '00'
                          iso8583_response_message:
                            type: string
                            example: Approved or completed successfully
                          raw_request:
                            type: object
                            description: >-
                              Copia ofuscada de la solicitud que Yuno envió al
                              proveedor. Solo se devuelve para organizaciones
                              autorizadas.
                          raw_response: {}
                          third_party_transaction_id: {}
                          third_party_account_id: {}
                      connection_data:
                        type: object
                        properties:
                          id:
                            type: string
                            example: 58cc35f4-faef-4107-8e09-d18d60121d38
                          name:
                            type: string
                            example: Connection name
                      response_code:
                        type: string
                        example: SUCCEEDED
                      response_message:
                        type: string
                        example: Transaction successful
                      payment:
                        type: object
                        properties:
                          id:
                            type: string
                            example: af170f9d-e8c1-47e4-a988-25535e0f88a1
                          account_id:
                            type: string
                            example: ''
                          description:
                            type: string
                            example: Test
                          country:
                            type: string
                            example: US
                          status:
                            type: string
                            example: SUCCEEDED
                          sub_status:
                            type: string
                            example: CAPTURED
                          merchant_order_id:
                            type: string
                            example: '0000023'
                          created_at:
                            type: string
                            example: '2024-06-06T14:26:22.933194Z'
                          updated_at:
                            type: string
                            example: '2024-06-06T14:26:41.655119Z'
                          amount:
                            type: object
                            properties:
                              captured:
                                type: integer
                                example: 30000
                                default: 0
                              currency:
                                type: string
                                example: USD
                              refunded:
                                type: integer
                                example: 0
                                default: 0
                              value:
                                type: integer
                                example: 30000
                                default: 0
                          discount_amount:
                            type: object
                            description: >-
                              El descuento total de la promoción de Yuno
                              aplicada al pago: la suma de las líneas
                              `YUNO_PROMOTION` de
                              `additional_data.order.discounts`. No aparece
                              cuando no se aplicó ninguna promoción. El monto
                              cobrado es `amount.value` menos este valor, y está
                              en `transactions.amount`. Consulta
                              [Promociones](/es/docs/payment-features/promotions).
                            properties:
                              currency:
                                type: string
                                description: >-
                                  La moneda del descuento, la misma que
                                  `amount.currency`.
                              value:
                                type: number
                                description: El descuento.
                          additional_data:
                            type: object
                            properties:
                              airline: {}
                              order: {}
                              seller_details: {}
                  - title: CARD DIRECT (con datos de aerolínea)
                    type: object
                    properties:
                      id:
                        type: string
                        example: 230292dd-b3e9-41e4-ae09-0a54e2f7a6d4
                      type:
                        type: string
                        example: CAPTURE
                      status:
                        type: string
                        example: SUCCEEDED
                      category:
                        type: string
                        example: CARD
                      amount:
                        type: object
                        properties:
                          currency:
                            type: string
                            example: USD
                          value:
                            type: integer
                            example: 20000
                            default: 0
                          refunded:
                            type: integer
                            example: 0
                            default: 0
                          captured:
                            type: integer
                            example: 0
                            default: 0
                      merchant_reference:
                        type: string
                        example: EJEMPLO_DE_REFERENCIA
                      created_at:
                        type: string
                        example: '2023-04-27T02:51:52.213075Z'
                      updated_at:
                        type: string
                        example: '2023-04-27T02:51:52.284381Z'
                      provider_data:
                        type: object
                        properties:
                          id:
                            type: string
                            example: YUNO_TEST_PAYMENT_GW
                          transaction_id:
                            type: string
                            example: a9a47e01-2dc1-4d5f-af23-11ab7164cd03
                          account_id:
                            type: string
                            example: 493e9374-510a-4201-9e09-de669d75f256
                          status:
                            type: string
                            example: SUCCEEDED
                          status_detail:
                            type: string
                            example: ''
                          response_message:
                            type: string
                            example: Transaction successful
                          response_code:
                            type: string
                            example: ''
                          iso8583_response_code:
                            type: string
                            example: '00'
                          iso8583_response_message:
                            type: string
                            example: Approved or completed successfully
                          raw_request:
                            type: object
                            description: >-
                              Copia ofuscada de la solicitud que Yuno envió al
                              proveedor. Solo se devuelve para organizaciones
                              autorizadas.
                          raw_response: {}
                          third_party_transaction_id: {}
                          third_party_account_id: {}
                      connection_data:
                        type: object
                        properties:
                          id:
                            type: string
                            example: 58cc35f4-faef-4107-8e09-d18d60121d38
                          name:
                            type: string
                            example: Connection name
                      response_code:
                        type: string
                        example: SUCCEEDED
                      response_message:
                        type: string
                        example: Transaction successful
                      payment:
                        type: object
                        properties:
                          id:
                            type: string
                            example: 637dffe9-5d18-4cdc-a5bf-95b8cd12bbd5
                          account_id:
                            type: string
                            example: ''
                          description:
                            type: string
                            example: SUCCESSFUL
                          country:
                            type: string
                            example: US
                          status:
                            type: string
                            example: SUCCEEDED
                          sub_status:
                            type: string
                            example: CAPTURED
                          merchant_order_id:
                            type: string
                            example: Order_id
                          created_at:
                            type: string
                            example: '2023-04-27T02:51:24.470834Z'
                          updated_at:
                            type: string
                            example: '2023-04-27T02:51:52.312297Z'
                          amount:
                            type: object
                            properties:
                              value:
                                type: integer
                                example: 20000
                                default: 0
                              captured:
                                type: integer
                                example: 20000
                                default: 0
                              refunded:
                                type: integer
                                example: 0
                                default: 0
                              currency:
                                type: string
                                example: USD
                          discount_amount:
                            type: object
                            description: >-
                              El descuento total de la promoción de Yuno
                              aplicada al pago: la suma de las líneas
                              `YUNO_PROMOTION` de
                              `additional_data.order.discounts`. No aparece
                              cuando no se aplicó ninguna promoción. El monto
                              cobrado es `amount.value` menos este valor, y está
                              en `transactions.amount`. Consulta
                              [Promociones](/es/docs/payment-features/promotions).
                            properties:
                              currency:
                                type: string
                                description: >-
                                  La moneda del descuento, la misma que
                                  `amount.currency`.
                              value:
                                type: number
                                description: El descuento.
                          additional_data:
                            type: object
                            properties:
                              airline:
                                type: object
                                properties:
                                  pnr:
                                    type: string
                                    example: ABC123
                                  legs:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        departure_airport:
                                          type: string
                                          example: BOG
                                        departure_datetime:
                                          type: string
                                          example: '2023-10-31T01:30:00.000-05:00'
                                        departure_airport_timezone:
                                          type: string
                                          example: GMT-05
                                        arrival_airport:
                                          type: string
                                          example: BOM
                                        carrier_code:
                                          type: string
                                          example: PR
                                        carrier_name:
                                          type: string
                                          example: Philippine Airlines
                                        flight_number:
                                          type: string
                                          example: AV348
                                        fare_basis_code:
                                          type: string
                                          example: 'Y'
                                        fare_class_code:
                                          type: string
                                          example: S
                                        base_fare:
                                          type: integer
                                          example: 18000
                                          default: 0
                                        base_fare_currency:
                                          type: string
                                          example: USD
                                        stopover_code:
                                          type: string
                                          example: O
                                  passengers:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        first_name:
                                          type: string
                                          example: JOHN
                                        last_name:
                                          type: string
                                          example: DOE
                                        middle_name:
                                          type: string
                                          example: STEPHEN
                                        type:
                                          type: string
                                          example: A
                                        date_of_birth:
                                          type: string
                                          example: '1998-01-01'
                                        nationality:
                                          type: string
                                          example: US
                                        document:
                                          type: object
                                          properties:
                                            document_type:
                                              type: string
                                              example: SSN
                                            document_number:
                                              type: string
                                              example: 123-45-6789
                                        country: {}
                                        loyalty_number:
                                          type: string
                                          example: '79250001'
                                        loyalty_tier:
                                          type: string
                                          example: DIAMOND
                                  tickets:
                                    type: array
                                    items:
                                      type: object
                                      properties:
                                        ticket_number:
                                          type: string
                                          example: BRB0001
                                        e_ticket:
                                          type: boolean
                                          example: true
                                          default: true
                                        restricted:
                                          type: boolean
                                          example: false
                                          default: true
                                        total_fare_amount:
                                          type: integer
                                          example: 20000
                                          default: 0
                                        total_tax_amount:
                                          type: integer
                                          example: 18000
                                          default: 0
                                        total_fee_amount:
                                          type: integer
                                          example: 1000
                                          default: 0
                                        issue:
                                          type: object
                                          properties:
                                            carrier_prefix_code:
                                              type: string
                                              example: '134'
                                            travel_agent_code:
                                              type: string
                                              example: A104121
                                            travel_agent_name:
                                              type: string
                                              example: AEROVIAJES
                                            date:
                                              type: string
                                              example: '2023-10-31T01:30:00.000-05:00'
                                            address:
                                              type: string
                                              example: 123 Main Street
                                            city:
                                              type: string
                                              example: New York
                                            country:
                                              type: string
                                              example: US
                                            zip_code:
                                              type: string
                                              example: '10001'
                              order: {}
                              seller_details: {}
                  - title: Captura parcial
                    type: object
                    properties:
                      id:
                        type: string
                        example: c8104f4b-30d6-476f-8e6b-49daa110e31f
                      type:
                        type: string
                        example: CAPTURE
                      status:
                        type: string
                        example: SUCCEEDED
                      category:
                        type: string
                        example: CARD
                      amount:
                        type: object
                        properties:
                          captured:
                            type: integer
                            example: 0
                            default: 0
                          currency:
                            type: string
                            example: USD
                          refunded:
                            type: integer
                            example: 0
                            default: 0
                          value:
                            type: integer
                            example: 3000
                            default: 0
                      merchant_reference:
                        type: string
                        example: AAB01-432245
                      created_at:
                        type: string
                        example: '2024-06-06T14:27:53.594183Z'
                      updated_at:
                        type: string
                        example: '2024-06-06T14:27:53.705858Z'
                      provider_data:
                        type: object
                        properties:
                          id:
                            type: string
                            example: YUNO_TEST_PAYMENT_GW
                          transaction_id:
                            type: string
                            example: a9a47e01-2dc1-4d5f-af23-11ab7164cd03
                          account_id:
                            type: string
                            example: 493e9374-510a-4201-9e09-de669d75f256
                          status:
                            type: string
                            example: SUCCEEDED
                          status_detail:
                            type: string
                            example: ''
                          response_message:
                            type: string
                            example: Transaction successful
                          response_code:
                            type: string
                            example: ''
                          iso8583_response_code:
                            type: string
                            example: '00'
                          iso8583_response_message:
                            type: string
                            example: Approved or completed successfully
                          raw_request:
                            type: object
                            description: >-
                              Copia ofuscada de la solicitud que Yuno envió al
                              proveedor. Solo se devuelve para organizaciones
                              autorizadas.
                          raw_response: {}
                          third_party_transaction_id: {}
                          third_party_account_id: {}
                      connection_data:
                        type: object
                        properties:
                          id:
                            type: string
                            example: 58cc35f4-faef-4107-8e09-d18d60121d38
                          name:
                            type: string
                            example: Connection name
                      response_code:
                        type: string
                        example: SUCCEEDED
                      response_message:
                        type: string
                        example: Transaction successful
                      payment:
                        type: object
                        properties:
                          id:
                            type: string
                            example: 60915b59-e403-4c00-8404-15ececa9b5dd
                          account_id:
                            type: string
                            example: ''
                          description:
                            type: string
                            example: Test
                          country:
                            type: string
                            example: US
                          status:
                            type: string
                            example: SUCCEEDED
                          sub_status:
                            type: string
                            example: PARTIALLY_CAPTURED
                          merchant_order_id:
                            type: string
                            example: '0000023'
                          created_at:
                            type: string
                            example: '2024-06-06T14:27:22.8355Z'
                          updated_at:
                            type: string
                            example: '2024-06-06T14:27:53.74127Z'
                          amount:
                            type: object
                            properties:
                              captured:
                                type: integer
                                example: 3000
                                default: 0
                              currency:
                                type: string
                                example: USD
                              refunded:
                                type: integer
                                example: 0
                                default: 0
                              value:
                                type: integer
                                example: 30000
                                default: 0
                          discount_amount:
                            type: object
                            description: >-
                              El descuento total de la promoción de Yuno
                              aplicada al pago: la suma de las líneas
                              `YUNO_PROMOTION` de
                              `additional_data.order.discounts`. No aparece
                              cuando no se aplicó ninguna promoción. El monto
                              cobrado es `amount.value` menos este valor, y está
                              en `transactions.amount`. Consulta
                              [Promociones](/es/docs/payment-features/promotions).
                            properties:
                              currency:
                                type: string
                                description: >-
                                  La moneda del descuento, la misma que
                                  `amount.currency`.
                              value:
                                type: number
                                description: El descuento.
                          additional_data:
                            type: object
                            properties:
                              airline: {}
                              order: {}
                              seller_details: {}
        '400':
          description: '400'
          content:
            application/json:
              examples:
                Result:
                  value:
                    code: INVALID_REQUEST
                    messages:
                      - Invalid request
                Invalid status:
                  summary: >-
                    The payment is already in a final state (for example,
                    already captured)
                  value:
                    code: INVALID_STATUS
                    messages:
                      - Invalid transaction status.
              schema:
                type: object
                properties:
                  code:
                    type: string
                    example: INVALID_REQUEST
                  messages:
                    type: array
                    items:
                      type: string
                      example: Invalid request
        '401':
          description: '401'
          content:
            application/json:
              examples:
                Unauthorized:
                  value:
                    code: INVALID_CREDENTIALS
                    messages:
                      - Invalid credentials
              schema:
                type: object
                properties:
                  code:
                    type: string
                    example: INVALID_CREDENTIALS
                  messages:
                    type: array
                    items:
                      type: string
                      example: Invalid credentials
        '403':
          description: '403'
          content:
            application/json:
              examples:
                Result:
                  value:
                    code: AUTHORIZATION_REQUIRED
                    messages:
                      - The merchant has no authorization to use this API.
              schema:
                type: object
                properties:
                  code:
                    type: string
                    example: AUTHORIZATION_REQUIRED
                  messages:
                    type: array
                    items:
                      type: string
                      example: The merchant has no authorization to use this API.
      deprecated: false
components:
  securitySchemes:
    sec0:
      type: apiKey
      in: header
      x-default: <Your public-api-key>
      name: public-api-key
    sec1:
      type: apiKey
      in: header
      x-default: <Your private-secret-key>
      name: private-secret-key
    sec2:
      type: apiKey
      in: header
      x-default: <Your X-Idempotency-Key>
      name: X-Idempotency-Key

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.