> ## Documentation Index
> Fetch the complete documentation index at: https://yn-c9bb3266.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Capture Payment

> Captures a previously authorized payment. You must provide both the payment ID and the transaction ID from the authorization response.



## OpenAPI

````yaml POST /v1/payments/{payment_id}/transactions/{transaction_id}/capture
openapi: 3.1.0
info:
  title: Yuno Payments API
  description: >-
    Yuno payment orchestration platform — unified REST API for payments,
    checkout sessions, customers, payment methods, subscriptions, payouts,
    marketplace transfers, and banking connectivity across Latin America.
  version: 1.0.0
  contact:
    name: Yuno Support
    email: support@y.uno
    url: https://docs.y.uno
  license:
    name: Proprietary
    url: https://y.uno
servers:
  - url: https://api-sandbox.y.uno
    description: Sandbox
  - url: https://api.y.uno
    description: Production
security:
  - publicApiKey: []
    privateSecretKey: []
paths:
  /v1/payments/{payment_id}/transactions/{transaction_id}/capture:
    post:
      tags:
        - Payments
      summary: Capture authorization
      description: >-
        Captures a previously authorized payment. You must provide both the
        payment ID and the transaction ID from the authorization response.
      operationId: capturePayment
      parameters:
        - name: payment_id
          in: path
          required: true
          description: The unique identifier of the payment
          schema:
            type: string
            format: uuid
        - name: transaction_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: The transaction ID from the authorization response
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                amount:
                  $ref: '#/components/schemas/Amount'
                  description: >-
                    Optional partial capture amount. If omitted, captures the
                    full authorized amount.
            example:
              amount:
                currency: BRL
                value: 150
      responses:
        '200':
          description: Payment captured successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Payment'
              example:
                id: f47ac10b-58cc-4372-a567-0e02b2c3d479
                status: SUCCEEDED
                amount:
                  currency: BRL
                  value: 150
        '400':
          description: Invalid request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - publicApiKey: []
          privateSecretKey: []
components:
  schemas:
    Amount:
      type: object
      required:
        - currency
        - value
      properties:
        currency:
          type: string
          description: ISO 4217 currency code
          example: BRL
        value:
          type: number
          description: >-
            Payment amount in major currency units (e.g., 150.00 means 150 BRL,
            not cents). For zero-decimal currencies like CLP and PYG, use whole
            numbers (e.g., 15000 means 15,000 CLP).
          example: 100
      example:
        currency: BRL
        value: 100
    Payment:
      type: object
      properties:
        id:
          type: string
          format: uuid
          description: Unique payment identifier
          example: f47ac10b-58cc-4372-a567-0e02b2c3d479
        checkout_session:
          type: string
          format: uuid
          example: a1b2c3d4-e5f6-7890-abcd-ef1234567890
        status:
          type: string
          enum:
            - SUCCEEDED
            - PENDING
            - DECLINED
            - REJECTED
            - CANCELLED
            - REFUNDED
            - PARTIALLY_REFUNDED
            - AUTHORIZED
          description: Current payment status
          example: SUCCEEDED
        amount:
          $ref: '#/components/schemas/Amount'
        country:
          type: string
          example: BR
        payment_method:
          type: object
          properties:
            type:
              type: string
              example: CARD
        provider:
          type: object
          properties:
            name:
              type: string
              description: Payment provider name
              example: stripe_connect
            transaction_id:
              type: string
              description: Provider transaction reference
              example: pi_3abc123def456
        merchant_order_id:
          type: string
          example: order-20260301-001
        created_at:
          type: string
          format: date-time
          example: '2026-03-01T14:31:00.000Z'
        updated_at:
          type: string
          format: date-time
          example: '2026-03-01T14:31:02.000Z'
        transactions:
          type: array
          description: Individual processing attempts for this payment
          items:
            $ref: '#/components/schemas/Transaction'
        refunds:
          type: array
          description: Refund records associated with this payment
          items:
            $ref: '#/components/schemas/RefundRecord'
        three_ds:
          type: object
          description: 3DS authentication details, present for card payments
          properties:
            required:
              type: boolean
              description: Whether 3DS authentication is required
            version:
              type: string
              description: 3DS protocol version
              example: 2.2.0
            status:
              type: string
              enum:
                - AUTHENTICATED
                - CHALLENGED
                - ATTEMPTED
                - FAILED
                - UNAVAILABLE
            eci:
              type: string
              description: Electronic Commerce Indicator
              example: '05'
            redirect_url:
              type: string
              format: uri
              description: URL to redirect the customer for 3DS challenge
        metadata:
          type: object
          description: Custom key-value pairs set by the merchant
          additionalProperties:
            type: string
        failure_reason:
          type: object
          description: Decline details when status is DECLINED or REJECTED
          properties:
            code:
              type: string
              description: Machine-readable decline code
              example: insufficient_funds
            message:
              type: string
              description: Human-readable decline reason
            provider_code:
              type: string
              description: Raw decline code from the payment provider
        customer_id:
          type: string
          format: uuid
          description: ID of the associated customer record
        installments:
          type: object
          description: Installment details if payment was split into installments
          properties:
            count:
              type: integer
              description: Number of installments
              example: 3
            plan_id:
              type: string
              description: Installment plan ID if using merchant installments
      example:
        id: f47ac10b-58cc-4372-a567-0e02b2c3d479
        checkout_session: a1b2c3d4-e5f6-7890-abcd-ef1234567890
        status: SUCCEEDED
        amount:
          currency: BRL
          value: 150
        country: BR
        payment_method:
          type: CARD
        provider:
          name: stripe_connect
          transaction_id: pi_3abc123def456
        merchant_order_id: order-20260301-001
        customer_id: cust_9a8b7c6d-5e4f-3210-abcd-ef0987654321
        transactions:
          - id: txn_1a2b3c4d-5e6f-7890-abcd-ef1234567890
            status: APPROVED
            provider: stripe_connect
            provider_transaction_id: pi_3abc123def456
            response_code: '00'
            response_message: Approved
            created_at: '2026-03-01T14:31:01.000Z'
        refunds: []
        three_ds:
          version: '2.2'
          eci: '05'
          status: AUTHENTICATED
        metadata:
          order_source: web
          campaign: spring-2026
        installments: null
        failure_reason: null
        created_at: '2026-03-01T14:31:00.000Z'
        updated_at: '2026-03-01T14:31:02.000Z'
    Error:
      type: object
      description: >-
        Standard error envelope returned by every Yuno service for any 4xx or
        5xx response. Top level. `code` is a stable SCREAMING_SNAKE_CASE
        identifier. `messages` is always an array of strings, even when there is
        only one entry. There is no `error` wrapper, no singular `message`, no
        `type`, no `details`. See the Error handling guide for the full code
        catalog.
      required:
        - code
        - messages
      properties:
        code:
          type: string
          description: >-
            Stable, machine readable identifier. Branch on this in your client.
            Common values include `BAD_REQUEST`, `VALIDATION_ERROR`,
            `INVALID_REQUEST`, `UNAUTHORIZED`, `FORBIDDEN`, `NOT_FOUND`,
            `TOO_MANY_REQUESTS`, `INTERNAL_ERROR`, `BAD_GATEWAY`,
            `SERVICE_UNAVAILABLE`, plus business codes like
            `CUSTOMER_ID_DUPLICATED`, `RECIPIENT_NOT_FOUND`, `INVALID_STATE`,
            and the `PROVIDER_*` family for downstream provider errors.
          example: VALIDATION_ERROR
        messages:
          type: array
          description: >-
            Human readable details. Validation errors put one entry per failed
            field, formatted `"fieldName message"`.
          items:
            type: string
          example:
            - merchant_customer_id must not be blank
      example:
        code: VALIDATION_ERROR
        messages:
          - amount must be greater than 0
          - country must not be blank
    Transaction:
      type: object
      properties:
        id:
          type: string
          format: uuid
        status:
          type: string
          enum:
            - APPROVED
            - DECLINED
            - ERROR
            - PENDING
        provider:
          type: string
          description: Provider that processed this attempt
        provider_transaction_id:
          type: string
        response_code:
          type: string
        response_message:
          type: string
        created_at:
          type: string
          format: date-time
    RefundRecord:
      type: object
      properties:
        id:
          type: string
          format: uuid
        amount:
          $ref: '#/components/schemas/Amount'
        status:
          type: string
          enum:
            - PENDING
            - SUCCEEDED
            - FAILED
        reason:
          type: string
        created_at:
          type: string
          format: date-time
  securitySchemes:
    publicApiKey:
      type: apiKey
      in: header
      name: public-api-key
      description: Your public API key from the Yuno Dashboard
    privateSecretKey:
      type: apiKey
      in: header
      name: private-secret-key
      description: Your private secret key (server-side only)

````