Subscription Links
Create Subscription Link
Changed onCreate a new card-on-file subscription enrollment link
post/subscription-links
Request
- The document declares no server URL.
- Authnone declared. Required headers: ApiKey, MerchantId, Environment
Headers
ApiKeystring required
Your api key. To create a key, please get into our dashboard. If you don't have access to it, please reach the Support team.
MerchantIdstring required
Your merchant ID. This information is available in our dashboard. If you don't have access to it, please reach the Support team.
Environment'live' | 'sandbox' required
Allow you to choose between the sandbox mode to perform some tests or the live mode for real world transactions.
Request body
Example request
{
"amount": 5000,
"currency": "XOF",
"purchaseReference": "SUB_2024_001",
"frequency": "monthly",
"startDate": "2026-08-01",
"country": "CI",
"expirationDate": "2026-12-31T23:59:59.000Z",
"successUrl": "https://merchant.com/success",
"failureUrl": "https://merchant.com/failure"
}Response
Subscription link created successfully
Example response
{
"id": "pl_z1urYtVFgEebtcj8fxp4v",
"url": "https://pay.hub2.com/pl_z1urYtVFgEebtcj8fxp4v",
"status": "active",
"purchaseReference": "ORDER-12345",
"minAmount": 500,
"maxAmount": 100000,
"currency": "XOF",
"maximumPayments": 50,
"maximumAttempts": 3,
"createdAt": "2024-01-15T12:00:00.000Z",
"updatedAt": "2024-01-15T12:30:00.000Z",
"expirationDate": "2024-01-15T14:30:00.000Z",
"customerPhoneNumber": "123456789",
"type": "single_use",
"providers": [
"orange",
"mtn"
],
"customerFields": [
{
"fieldName": "national_id",
"fieldLabel": "National ID"
}
]
}Changes
- info
endpoint added
- info