Payment links
A shareable page that takes payments without any code: a fixed price or an amount the payer types, with the fields you ask for.
A payment link is a page at bezanbecard.com/l/<slug> you can send in a chat, print as a QR code or put in your Instagram bio. Each visitor who pays gets their own payment with its own unique amount, then goes through the usual hosted checkout: they pay card to card or by bank transfer and send the receipt, and your team approves it.
Create links in the dashboard under Payment links, or with the API.
Creating a link
| Parameter | Description |
|---|---|
title | Required. Shown at the top of the page. |
description | Optional text under the title. |
amount | { "type": "fixed", "value": 5000000 }, or { "type": "open", "min", "max", "presets" } for an amount the payer chooses (up to 10 presets inside the bounds). |
collect | name, phone and email, each off, optional or required. |
max_uses | Stop after this many successful payments. |
expires_at | Unix seconds after which the link stops taking payments. |
after_completion | { "type": "message", "message" } shown on the confirmation once the payment succeeds, or { "type": "redirect", "url" } to send the payer to your site. |
card | A destination card or account for this link's payments, instead of your routing. It must take one of your enabled payment methods. |
metadata | Your own keys, as on payments. |
curl https://a.bezanbecard.com/v1/payment_links \
-H "Authorization: Bearer sk_test_…" \
-H "Idempotency-Key: link-workshop-1" \
-H "Content-Type: application/json" \
-d '{"title":"Workshop ticket","amount":{"type":"fixed","value":5000000},"collect":{"name":"required","phone":"required","email":"off"},"max_uses":40}'An open amount needs min not greater than max (link_amount_range_invalid); without bounds it falls back to the payment limits of 10,000 to 2,000,000,000 rial.
What the payer sees
The link page shows your name and logo, the title, the image and description, the amount or the amount field with its presets, and the fields you collect. When the payer continues, a payment is created with source: "link" and they move to its checkout. A link that cannot take payments says why: archived, expired, used up, or your account is not accepting payments.
Use limits
max_uses counts payments that succeeded and payments still open, checked the moment a visitor starts paying, so two people cannot take the last place at once. A payment that expires or is canceled gives its place back. A transfer cannot be refused once it is sent, so a late deposit inside a canceled payment's grace period can still take a link past its limit.
The link's page in the dashboard shows its uses and revenue, recomputed from its successful payments.
Changing and archiving
POST /v1/payment_links/:id changes any field. Send null (or an empty string) for card, max_uses or expires_at to remove it, and "active": false to archive the link. Links are never deleted, because their payments keep pointing at them.
Link changes emit payment_link.created and payment_link.updated; their payments emit the usual payment events.