Skip to main content
POST
/
v1
/
payments
Create payment
curl --request POST \
  --url https://api-sandbox.y.uno/v1/payments \
  --header 'Content-Type: application/json' \
  --header 'account-code: <api-key>' \
  --header 'private-secret-key: <api-key>' \
  --header 'public-api-key: <api-key>' \
  --data '
{
  "checkout_session": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "payment_method": {
    "type": "CARD",
    "token": "tok_4a8b9c2d-1e3f-5678-90ab-cdef12345678"
  },
  "amount": {
    "currency": "BRL",
    "value": 150
  },
  "country": "BR",
  "customer": {
    "document": {
      "document_type": "CPF",
      "document_number": "12345678901"
    },
    "email": "maria.silva@example.com",
    "first_name": "Maria",
    "last_name": "Silva",
    "phone": "+5511999990000"
  },
  "description": "Premium subscription - March 2026",
  "installments": 1,
  "metadata": {
    "order_source": "web",
    "campaign": "spring-2026"
  }
}
'
{
  "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",
  "created_at": "2026-03-01T14:31:00.000Z",
  "updated_at": "2026-03-01T14:31:02.000Z"
}
This request allows you to authorize a payment after you created a checkout session. It just authorizes the amount on the credit_card (the client is not charged). If you want to make an authorization for a payment, you will need to send the capture as “false” within the card object, which is located inside the payment_method object.

Authorizations

public-api-key
string
header
required

Your public API key from the Yuno Dashboard

private-secret-key
string
header
required

Your private secret key (server-side only)

account-code
string
header
required

Your account identifier. The alias X-Account-Code is also accepted.

Body

application/json
checkout_session
string<uuid>
required

The checkout session ID from the create session response

Example:

"a1b2c3d4-e5f6-7890-abcd-ef1234567890"

payment_method
object
required
amount
object
required
Example:
{ "currency": "BRL", "value": 100 }
country
string
required

ISO 3166-1 alpha-2 country code

Pattern: ^[A-Z]{2}$
Example:

"BR"

customer
object
description
string

Payment description

Example:

"Premium subscription - March 2026"

installments
integer

Number of installments (for card payments)

Required range: x >= 1
Example:

1

three_ds
object

3DS authentication preferences

merchant_order_id
string

Your unique order reference. If not provided, inherits from the checkout session.

Example:

"order-12345"

metadata
object

Custom key-value pairs for storing additional information. Keys and values must be strings. Maximum 50 keys, each key max 40 characters, each value max 500 characters.

Example:
{
"order_source": "web",
"campaign": "spring-2026"
}

Response

Payment created successfully

id
string<uuid>

Unique payment identifier

Example:

"f47ac10b-58cc-4372-a567-0e02b2c3d479"

checkout_session
string<uuid>
Example:

"a1b2c3d4-e5f6-7890-abcd-ef1234567890"

status
enum<string>

Current payment status

Available options:
SUCCEEDED,
PENDING,
DECLINED,
REJECTED,
CANCELLED,
REFUNDED,
PARTIALLY_REFUNDED,
AUTHORIZED
Example:

"SUCCEEDED"

amount
object
Example:
{ "currency": "BRL", "value": 100 }
country
string
Example:

"BR"

payment_method
object
provider
object
merchant_order_id
string
Example:

"order-20260301-001"

created_at
string<date-time>
Example:

"2026-03-01T14:31:00.000Z"

updated_at
string<date-time>
Example:

"2026-03-01T14:31:02.000Z"

transactions
object[]

Individual processing attempts for this payment

refunds
object[]

Refund records associated with this payment

three_ds
object

3DS authentication details, present for card payments

metadata
object

Custom key-value pairs set by the merchant

failure_reason
object

Decline details when status is DECLINED or REJECTED

customer_id
string<uuid>

ID of the associated customer record

installments
object

Installment details if payment was split into installments