Create Payment Link
Creates a new payment link that generates unique wallet addresses for customers to make cryptocurrency payments. Supported networks: Bitcoin (BTC), Tron (TRC20 USDT), and BNB Smart Chain (BEP20 USDT). You can either pre-generate wallet addresses at creation by passing the wallets parameter, or omit it to have wallets generated on demand when the customer starts a payment session (via the payment link session endpoint). See Get Supported Networks above for the list of valid network/token combinations.
Endpoint: POST /payment-links
Authentication: Required (x-api-key header for live, x-staging-api-key for sandbox)
Webhook Events
When a payment is processed, you will receive webhook notifications with the following event types:
payment_link_completed: Triggered when payment is successfully completed (exact amount)
payment_link_completed_overpaid: Triggered when payment is completed but customer overpaid
payment_link_failed: Triggered when payment fails or is underpaid
See the Webhook Events section for complete payload structures.
Request Parameters
amount
number
Yes
Payment amount (must be greater than 0)
customer_details
string
Yes
JSON string containing customer information. Required fields: email, first_name, last_name. Optional field: phone
payment_reference
string
Yes
Alphanumeric reference for this payment (1-20 characters, letters and numbers only). Used to identify the payment in your system
success_url
string
Yes
HTTPS URL to redirect customer after successful payment. Must use HTTPS protocol
cancel_url
string
Yes
HTTPS URL to redirect customer if payment is cancelled. Must use HTTPS protocol
expires_at
string
No
ISO 8601 date-time when the payment link expires. Must be a future date. If not provided, defaults to 2 hours from creation time
metadata
string
No
Optional JSON string containing additional metadata you want to store with the payment link. This will be included in webhook notifications
amount_currency
string
No
Currency code for the amount (default: 'ngn'). Must be a supported currency
wallets
array
No
Optional array of { network, token } objects. If provided and non-empty, wallet addresses are generated at creation. If omitted or empty, wallets are generated on demand when the customer starts a session. Valid combinations: bitcoin/BTC, trc20/USDT, bep20/USDT. Only one wallet per network allowed
Example Request (with pre-generated wallets)
Example Request (on-demand wallets)
Omit wallets to have wallet addresses generated when the customer starts a payment session:
Example Response (pre-generated wallets)
When wallets was provided, the response includes wallet addresses and wallet_pre_generated is 1:
Example Response (on-demand wallets)
When wallets was omitted or empty, data.wallets is empty and wallet_pre_generated is 0. Wallet addresses are created when the customer starts a session via the payment link:
Last updated