ONE

Charge from your code

Create a checkout link with one API call. Your customer pays with the methods available in their country. You get notified when the money clears.

What you can do with the API

The API is small on purpose. Almost everything starts with creating a checkout and listening for payment updates.

01

Create payment links

POST a Checkout Preference and get a checkout_url you can send to any customer.

02

Accept local payment methods

Checkout detects the payer's country and shows cards, bank transfer, PIX, or crypto when available. Currency conversion is handled for you.

03

Know when you got paid

Receive webhooks on every Payment Order status change, then fetch the full order when you need the details.

Two objects you need to know

Checkout Preference is the link you create. Payment Order is what appears once a customer starts paying.

  1. You create a Checkout Preference

    Your backend calls the API with amount, currency, and title. ONE returns a checkout_url.

  2. Your customer pays

    They open the link, pick a local method, and complete the payment. That creates a Payment Order.

  3. You get a webhook

    ONE POSTs a small event to your URL when the order status changes (opened, closed, expired…).

  4. You fetch the order

    Use the entity_id from the webhook to GET the Payment Order and confirm the final state.

Go live in three steps

You do not need an SDK. Keys, a staging base URL, and one POST are enough to see a real checkout.

  1. 01

    Create API keys

    In the ONE Dashboard go to Integrations and generate your x-api-key and x-api-secret.

  2. 02

    Use staging first

    Build against api.stg.one.lat. You can only request a staging account if you already have an approved, active production account — contact support.

  3. 03

    Create your first checkout

    POST /v1/checkout_preferences, open the checkout_url, complete a test payment, and watch the webhook arrive.

Authentication

Every request to the API must include both security headers.

Send x-api-key and x-api-secret on every call. Create and rotate keys from the dashboard under Integrations.

Environments

Same paths in staging and production. Only the host changes.

https://api.stg.one.lat
https://api.one.lat

Create a checkout

This is the main endpoint. It creates a one-time payment request and returns the URL your customer uses to pay.

POST/v1/checkout_preferences

Request body

FieldTypeRequiredDescription
amountfloatYesCharge amount. Equivalent limits apply around 10–1500 USD.
currencystringYesISO currency of the amount (USD, ARS, BRL, COP, MXN).
titlestringYesWhat the customer sees on checkout, e.g. course name.
originstringYesAPI
external_idstringNoYour own unique id to reconcile the payment later.
expiration_datestring (RFC3339)NoRFC3339 date. Max 1 week ahead. Defaults to 15 minutes if omitted.
payer.emailstringNoIf provided, checkout can skip asking for email.
payer.first_namestringNoPayer first name.
payer.last_namestringNoPayer last name.
payer.phone_numberstringNoPayer phone with country code.
selected_payment_method_idstringNoSkip method selection and lock a specific payment method.
custom_urls.status_changes_webhookstring (URL)NoYour endpoint for Payment Order status-change notifications.

Example request

cURL
curl 'https://api.one.lat/v1/checkout_preferences' \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'x-api-secret: YOUR_API_SECRET' \
  --header 'Content-Type: application/json' \
  --data '{
    "amount": 25,
    "currency": "USD",
    "origin": "API",
    "title": "Introductory course to Blockchain",
    "external_id": "order_1234",
    "payer": {
      "email": "luca@test.com",
      "first_name": "Luca",
      "last_name": "Dorain",
      "phone_number": "+521142567689"
    },
    "custom_urls": {
      "status_changes_webhook": "https://api.mycompany.io/webhook"
    }
  }'

Example response

Share checkout_url with your customer. Checkout shows only the payment methods available in their country.

200 JSON
{
  "id": "qwDsh9aMoywPOiUx0O",
  "amount": 25,
  "currency": "USD",
  "created_at": "2025-02-25T14:11:29Z",
  "expiration_date": "2025-02-26T15:02:50Z",
  "origin": "API",
  "external_id": "order_1234",
  "title": "Introductory course to Blockchain",
  "type": "PAYMENT",
  "checkout_url": "https://one.lat/checkout/qwDsh9aMoywPOiUx0O",
  "payer": {
    "email": "luca@test.com",
    "first_name": "Luca",
    "last_name": "Dorain",
    "phone_number": "+521142567689"
  }
}

Lookup endpoints

Use these after creating a checkout, or when a webhook tells you something changed.

Get a Checkout Preference

Retrieve a preference you already created by id.

GET/v1/checkout_preferences/:id

Get a Payment Order

A Payment Order is created when the payer enters checkout, selects a method, and submits their details. Fetch it to confirm status after a webhook.

GET/v1/payment_orders/:id
200 JSON
{
  "id": "gRV8xTZHPv9lNxSLPw",
  "amount": 16.9,
  "currency": "USD",
  "created_at": "2024-06-12T15:26:47Z",
  "expired_at": "2024-06-12T15:56:47Z",
  "updated_at": "2024-06-12T15:31:28Z",
  "status": "CLOSED",
  "title": "Test product",
  "origin": "PAYMENT_LINK",
  "external_id": "1234",
  "payment_method_type": "BANK_TRANSFER",
  "payer": {
    "email": "payer@gmail.com",
    "first_name": "Joan",
    "last_name": "Kohler",
    "phone_number": "+542614215688"
  }
}

Get a Refund

When you receive REFUND.SUCCEEDED, use the entity_id to fetch the refund and confirm amount, currency, and linked payment order.

GET/v1/refunds/:id
cURL
curl 'https://api.one.lat/v1/refunds/1dUPlZbsDABq3bIEOG' \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'x-api-secret: YOUR_API_SECRET'
200 JSON
{
  "id": "1dUPlZbsDABq3bIEOG",
  "payment_order_id": "IwyOQSzfuEt80W9WNS",
  "amount": 100,
  "currency": "USD",
  "status": "SUCCEEDED",
  "created_at": "2025-12-08T22:42:52Z",
  "updated_at": "2025-12-08T23:12:48Z"
}

List payment methods

See which methods are enabled for your account, with limits, currency, and country.

GET/v1/payment_methods
200 JSON
[
  {
    "id": "vJKtkYs8Vf",
    "status": "ENABLED",
    "type": "BANK_TRANSFER",
    "country_id": "ARG",
    "currency": "ARS",
    "max_amount": 10000000,
    "min_amount": 0
  },
  {
    "id": "qacV3z31cz",
    "status": "ENABLED",
    "type": "CRYPTO_ONCHAIN",
    "country_id": "ALL",
    "currency": "USDT",
    "network": { "id": "TRON", "name": "Tron" },
    "min_amount": 0.1,
    "max_amount": 100000
  }
]

Common types: BANK_TRANSFER · PIX · CRYPTO_ONCHAIN

Webhooks

Webhooks are status-change alerts. They are intentionally small: treat them as a signal, then fetch the entity.

Configure a webhook URL

Pass custom_urls.status_changes_webhook when you create the Checkout Preference.

JSON
{
  "custom_urls": {
    "status_changes_webhook": "https://api.mycompany.io/webhook"
  }
}

Need one URL for every notification on the account? Contact support to set it at account level.

Notification payload

For Payment Order events, call GET /v1/payment_orders/:id with entity_id to get the latest version.

PAYMENT_ORDER
{
  "id": "uCEarm1kXJsroMQ6dt",
  "event_type": "PAYMENT_ORDER.CLOSED",
  "entity_type": "PAYMENT_ORDER",
  "entity_id": "rcAaNfKdKJRmrnj4l5"
}

Refund notifications

When a refund completes you get REFUND.SUCCEEDED. Then call GET /v1/refunds/:id with entity_id.

REFUND
{
  "id": "nR8kLm2pQxYtVw4HsZ",
  "event_type": "REFUND.SUCCEEDED",
  "entity_type": "REFUND",
  "entity_id": "1dUPlZbsDABq3bIEOG"
}

Event types

Payment Order

  • PAYMENT_ORDER.OPENED
  • PAYMENT_ORDER.CLOSED
  • PAYMENT_ORDER.REJECTED
  • PAYMENT_ORDER.EXPIRED

Refund

  • REFUND.SUCCEEDED

Your webhook handler should be idempotent. The id field is unique per notification.

Status codes & currencies

Quick lookup tables for Payment Order statuses, refunds, and supported currencies.

Payment Order statuses

CodeDescription
OPENEDCreated and waiting for the customer to pay.
CLOSEDPaid successfully. The process is complete.
REJECTEDDeclined by the processor or the customer's bank.
EXPIREDExpired before payment was received.

Refund statuses

CodeDescription
SUCCEEDEDThe refund completed successfully.

Currencies

CodeDescription
USDUS dollars
ARSArgentine pesos
BRLBrazilian reais
COPColombian pesos
MXNMexican pesos