Create a payment link
create_payment_linkCreate a shareable payment link that sells a single price on its own page, with options for quantity, coupons, success URL, and buyer name collection. Test keys only.
Instructions
Create a payment link.
A page at /l/ that sells one price. Share it anywhere, or open it with pay.js.
Test keys only: refused with a live key.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| slug | No | Default: random. | |
| price | Yes | A price id, `price_…`. | |
| metadata | No | Your own key–value pairs (≤ 50 keys, values ≤ 500 characters). On an update they are merged in; an empty value removes its key. | |
| quantity | No | ||
| success_url | No | Where the buyer goes after paying. | |
| collect_name | No | ||
| allow_coupons | No | ||
| adjustable_quantity | No |