Initiate a wallet topup
POSThttps://api.playbox.grow.curacel.co/api/v1/partners/wallet/init-topup
This endpoint allows you to initiate a topup. The response will contain a redirect url to the payment gateway.
Request
- application/json
Body
The request body to be sent with this request
amount numberrequired
The amount to be topped up
currency stringrequired
The currency of the amount. You should already have a wallet for this currency
Responses
- 200
- 400
- 422
OK
- application/json
- Schema
- Example (from schema)
Schema
payment_link string
The payment link to be used to make the payment
{
"payment_link": "https://checkout.paystack.com/hpq3a1iw9exaj66"
}
Bad Request. For all payment gateway errors
- application/json
- Schema
- Example (from schema)
Schema
message string
{
"message": "Currency not supported by merchant"
}
Unprocessable Content. For all input validation errors
- application/json
- Schema
- Example (from schema)
Schema
message string
errors object
{
"message": "The given data was invalid",
"errors": {
"amount": [
"The amount field is required"
],
"currency": [
"You do not have a wallet for this currency"
]
}
}
Authorization: http
name: bearerAuthtype: httpscheme: bearerbearerFormat: API KEY from your account dashboard
- curl
- python
- go
- nodejs
- ruby
- csharp
- php
- java
- powershell
- CURL
curl -L -X POST 'https://api.playbox.grow.curacel.co/api/v1/partners/wallet/init-topup' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"amount": 10000.2,
"currency": "NGN"
}'
ResponseClear