v1

latestOpenAPI 3.1.02026-07-228956435.8 KB
Payment links

Create a payment link

Creates a payment link in the live or test mode of the API key used. The response includes the url of the page where your customer pays. The payment link accepts payments until you cancel it or, when expires_after_seconds is sent, until it expires.

post/payment_links

Request body

amountinteger required

Amount to collect, in the smallest unit of currency. For example, 5000 represents 5000 CLP, since CLP has no minor unit, or 50.00 MXN. Must be greater than 0.

currency'CLP' | 'MXN' required

Three-letter ISO 4217 currency code. One of CLP (Chilean peso) or MXN (Mexican peso). Case-insensitive.

customer_emailstring

Email address of your customer, used for transaction notifications, including refunds.

expires_after_secondsinteger

Number of seconds after which the payment link expires. Must be greater than 0. If omitted, the payment link never expires.

metadataobject

Set of key-value pairs you can attach to the payment link to store additional information in a structured format.

Example request

{
  "amount": 5000,
  "currency": "CLP",
  "business_profile": {
    "category": "620200",
    "name": "Tienda Ejemplo",
    "tax_id": "111111111"
  },
  "checkout": {
    "description": "Premium subscription"
  },
  "customer_email": "customer@example.com",
  "expires_after_seconds": 86400,
  "metadata": {
    "order_id": "1234"
  },
  "recipient_account": {
    "holder_id": "111111111",
    "institution_id": "cl_banco_de_chile",
    "number": "123456789",
    "type": "checking_account"
  }
}

Response

Payment link created. Share the returned url with your customer to collect the payment.

idstring required

Unique identifier of the payment link.

object'payment_link' required

Type of the object. Always payment_link.

amountinteger required

Amount to collect, in the smallest unit of currency. For example, 5000 represents 5000 CLP, since CLP has no minor unit, or 50.00 MXN.

checkoutobject required

Checkout customization. The description key holds the text shown next to the buy button, or null when you do not set it.

created_atstring date-time required

ISO 8601 datetime in UTC of when the payment link was created.

currency'CLP' | 'MXN' required

Three-letter ISO 4217 currency code. One of CLP (Chilean peso) or MXN (Mexican peso).

customer_emailstring nullable required

Email address of your customer, used for transaction notifications. null when not provided on creation.

expires_atstring date-time nullable required

ISO 8601 datetime in UTC of when the payment link expires. null when the payment link does not expire.

metadataobject required

Set of key-value pairs attached to the payment link on creation.

mode'test' | 'live' required

Mode of the object. live objects use real institution data, test objects use fake data for integration testing.

status'active' | 'expired' | 'canceled' required

Status of the payment link. One of active (accepts payments), expired (the expiration date passed), or canceled (you canceled the link).

urlstring required

URL of the page where your customer pays.

Example response

{
  "id": "plink_K2zwNNSxPyx8w3GZ",
  "amount": 5000,
  "checkout": {
    "description": "Premium subscription"
  },
  "created_at": "2024-04-04T15:23:11.474Z",
  "currency": "CLP",
  "customer_email": "customer@example.com",
  "expires_at": "2024-04-05T15:23:11.474Z",
  "metadata": {
    "order_id": "1234"
  },
  "mode": "live",
  "recipient_account": {
    "holder_id": "111111111",
    "institution_id": "cl_banco_de_chile",
    "number": "123456789",
    "type": "checking_account"
  },
  "status": "active",
  "url": "https://pay.fintoc.com/plink_K2zwNNSxPyx8w3GZ"
}