curl --request POST \
--url https://api.unibee.dev/merchant/subscription/payment/new \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"gatewayId": 123,
"cancelUrl": "<string>",
"countryCode": "<string>",
"currency": "<string>",
"description": "<string>",
"email": "<string>",
"externalPaymentId": "<string>",
"externalUserId": "<string>",
"gasPayer": "<string>",
"items": [
{
"amount": 123,
"amountExcludingTax": 123,
"currency": "<string>",
"description": "<string>",
"name": "<string>",
"quantity": 123,
"tax": 123,
"taxPercentage": 123,
"unitAmountExcludingTax": 123
}
],
"metadata": {},
"name": "<string>",
"planId": 123,
"redirectUrl": "<string>",
"totalAmount": 123,
"userId": 123
}
'{
"code": 123,
"data": {
"action": {},
"externalPaymentId": "<string>",
"link": "<string>",
"paymentId": "<string>",
"status": 123
},
"message": "<string>",
"redirect": "<string>",
"requestId": "<string>"
}curl --request POST \
--url https://api.unibee.dev/merchant/subscription/payment/new \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"gatewayId": 123,
"cancelUrl": "<string>",
"countryCode": "<string>",
"currency": "<string>",
"description": "<string>",
"email": "<string>",
"externalPaymentId": "<string>",
"externalUserId": "<string>",
"gasPayer": "<string>",
"items": [
{
"amount": 123,
"amountExcludingTax": 123,
"currency": "<string>",
"description": "<string>",
"name": "<string>",
"quantity": 123,
"tax": 123,
"taxPercentage": 123,
"unitAmountExcludingTax": 123
}
],
"metadata": {},
"name": "<string>",
"planId": 123,
"redirectUrl": "<string>",
"totalAmount": 123,
"userId": 123
}
'{
"code": 123,
"data": {
"action": {},
"externalPaymentId": "<string>",
"link": "<string>",
"paymentId": "<string>",
"status": 123
},
"message": "<string>",
"redirect": "<string>",
"requestId": "<string>"
}Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
GatewayId
CancelUrl
CountryCode
Currency, either Currency&TotalAmount or PlanId needed
Description
Email, either ExternalUserId&Email or UserId needed
ExternalPaymentId should unique for payment
ExternalUserId, unique, either ExternalUserId&Email or UserId needed
who pay the gas, merchant|user
Items
Show child attributes
item total amount, sum(item.amount) should equal to totalAmount, cent
amountExcludingTax = unitAmountExcludingTax * quantity
The item currency of payment
The item description of payment
The item name of payment
The item quantity of payment
tax = amount - amountExcludingTax
The tax percentage of payment,1000 = 10%
Name
PlanId, either TotalAmount&Currency or PlanId needed
Redirect Url
Total PaymentAmount, Cent, either TotalAmount&Currency or PlanId needed
UserId, either ExternalUserId&Email or UserId needed