Create General Payment Link
This creates a reusable payment link with items and amount.
The link:
- Does not expire
- Is not tied to any customer
- Allows customers to select their local currency at checkout
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| metadata | array | Yes | Items being paid for |
| metadata[].name | string | Yes | Item name |
| metadata[].amount | number | Yes | Item amount (settlement currency, base units) |
| metadata[].quantity | number | Yes | Quantity of item |
| feeBearer | enum | No | Who pays transaction fees: CUSTOMER or MERCHANT |
| taxChargeable | enum | No | Tax handling: INCLUSIVE or EXCLUSIVE |
After collecting the necessary item and and amount, make a POST request to our General Payment Link endpoint.
Note: Before making a POST request, the secret key must be specified in the header.
x-api-key: your_secret_key
POST {{host}}/v1/pay/general
{
"metadata": [
{
"name": "Book",
"amount": 600,
"quantity": 1
}
],
"feeBearer": "CUSTOMER",
"taxChargeable": "EXCLUSIVE"
}
{
"status": true,
"code": 201,
"message": "Success",
"data": {
"reference": "KYSHI-1770114609126",
"status": "PENDING",
"paymentLink": {
"id": "09930725-2fb3-473a-978d-e395de858c04",
"code": "2cuAo76LgS8KUnA",
"url": "https://merchant.kyshi.co/payment/2cuAo76LgS8KUnA",
"expiresAt": null
},
"amount": {
"value": 600,
"currency": "USD"
}
}
}
Updated about 23 hours ago
