Payment links
A payment link is a hosted page with a fixed amount, to share on WhatsApp, by email or on social media. You can create them from the dashboard or through the API.
POST
/v1/payment-linksCreate a payment link| Parameter | Type | Required | Description |
|---|---|---|---|
title |
string | Yes | Title shown to the customer |
amount |
number | Yes | Fixed amount |
currency |
string | No | XOF by default |
description |
string | No | Details of the product or service |
curl -X POST https://cartflox.com/api/v1/payment-links \ -H "Authorization: Bearer af_live_sec_YOUR_KEY" \ -H "Content-Type: application/json" \ -d '{ "title": "Odoo training", "amount": 25000, "currency": "XOF" }'{ "success": true, "id": "cmf3lz...", "url": "https://cartflox.com/pay/k3j9x2ab", "slug": "k3j9x2ab", "amount": 25000, "currency": "XOF"}GET
/v1/payment-links/{id}/checkFind out whether the link has been paid{ "success": true, "paid": true, "status": "SUCCESS", "transaction": { "id": "cmf3m1...", "amount": 25000, "customerName": "Awa Koné", "customerEmail": "awa@example.com" }}As long as no payment has succeeded, the response is { "success": true, "paid": false, "status": "WAITING" } (or the status of the latest attempt). The customer’s phone number is always requested on the page, for Mobile Money.