Skip to content

Suggested

API Dashboard

RecipesCreate a purchase

Create a purchase

Charge a customer and settle the value into an internal merchant account.

A PURCHASE payment is used when an end customer pays for goods, services, invoices, or a checkout event. The origin is the customer’s pay-in rail. The destination is the merchant or platform ACCOUNT that should receive the collected value.

Note

Use PURCHASE when the payment represents a commercial event. Use TOPUP_ACCOUNT when the user is only funding an internal balance.

01
Discover rails

Call available products for the customer currency.

02
Create purchase

Send a PURCHASE payment with a pay-in origin and account destination.

03
Send customer

Redirect or show the provider instruction returned by the rail.

04
Capture

Capture when authorization is complete.

05
Fulfill

Use webhooks as the final source of truth.

Request
POST /sandbox/payments HTTP/1.1
Host: api.conomyhq.com
x-api-key: {YOUR_API_KEY}
Authorization: Bearer {ACCESS_TOKEN}
conomyhq-api-version: 24-04-2025
User-Agent: MyApp/1.0
Content-Type: application/json
Accept: application/json

{
  "externalId": "order-1001",
  "identityId": "<MERCHANT_IDENTITY_ID>",
  "accountNumber": "<MERCHANT_ACCOUNT_NUMBER>",
  "product": "CLP:CLP",
  "type": "PURCHASE",
  "purchaseAmount": "49990",
  "purchaseCurrency": "CLP",
  "currency": "CLP",
  "origins": [
    {
      "type": "ETPAY",
      "currency": "CLP",
      "etpay": {
        "successUrl": "https://yourapp.com/orders/1001/success",
        "failedUrl": "https://yourapp.com/orders/1001/failed",
        "customer": {
          "firstName": "Jane",
          "email": "jane@example.com"
        }
      }
    }
  ],
  "destinations": [
    {
      "type": "ACCOUNT",
      "amount": "49990",
      "currency": "CLP",
      "identity": {
        "identityId": "<MERCHANT_IDENTITY_ID>"
      },
      "account": {
        "accountNumber": "<MERCHANT_ACCOUNT_NUMBER>"
      }
    }
  ]
}
Response
{
  "id": "<PAYMENT_ID>",
  "externalId": "order-1001",
  "type": "PURCHASE",
  "status": "CREATED",
  "product": "CLP:CLP",
  "origins": [
    {
      "type": "ETPAY",
      "etpay": {
        "url": "https://provider.example/authorize"
      }
    }
  ]
}
Request
POST /sandbox/payments/{PAYMENT_ID}/captured HTTP/1.1
Host: api.conomyhq.com
x-api-key: {YOUR_API_KEY}
Authorization: Bearer {ACCESS_TOKEN}
conomyhq-api-version: 24-04-2025
User-Agent: MyApp/1.0
Content-Type: application/json
Accept: application/json

{}
Response
{
  "id": "<PAYMENT_ID>",
  "type": "PURCHASE",
  "status": "CAPTURED",
  "capturedAt": "2026-05-18T10:00:00Z"
}

Do not fulfill the order only because the browser returned to successUrl. Use payment.settled, payment.failed, or GET /payments/{id} to mirror the final state in your own system.