Skip to main content

๐Ÿ’ณ Payment API Documentation

๐Ÿ” Authorizationโ€‹

All API requests must include the following body:

public_key: <Website Public Key>
Base Url
https://api.listopays.com

๐Ÿงพ Create a Paymentโ€‹

POST payments

Requestโ€‹

{
"customer": "9e4d09cb-2913-4020-a0b5-a905dcc9f35c",
"order": "Something about order",
"amount": 128,
"public_key": <Website Public Key>
}

Responseโ€‹

{
"success": true,
"error": null,
"data": {
"url": "https://pay.listopays.com/payment/0MvVe7YnAEnoXJIaboADpF4rocb2AknJ"
}
}

โ†ฉ๏ธ Refund a Paymentโ€‹

POST payment/{payment_token}/refund

Requestโ€‹

{
"public_key": <Website Public Key>
}

Responseโ€‹

{
"success": true
}

๐Ÿ‘ค Create a Customerโ€‹

POST customers

Requestโ€‹

{
"name": "John",
"email": "[email protected]",
"public_key": <Website Public Key>
}

Responseโ€‹

{
"success": true,
"data": {
"uuid": "2dcace1d-2846-4242-8596-0ebfbd1a8379"
}
}

๐Ÿ‘ฅ Get All Customersโ€‹

GET customers

Requestโ€‹

{
"public_key": <Website Public Key>
}

Responseโ€‹

{
"success": true,
"data": [
{
"uuid": "2dcace1d-2846-4242-8596-0ebfbd1a8379",
"name": "John",
"email": "[email protected]"
}
]
}

Customer Chargeโ€‹

POST charge

Requestโ€‹

{
"customer": "9e4d09cb-2913-4020-a0b5-a905dcc9f35c",
"order": "Something about order",
"amount": 128,
"public_key": <Website Public Key>
}

Responseโ€‹

{
"success": true,
"error": null,
"data": null
}

โ„น๏ธ Notesโ€‹

  • All responses contain a success field indicating operation result.
  • On error, an error field may be included with the description.
  • All requests require a valid X-PUBLIC-KEY header.