Prevail Group of Companies

API Reference

Payments

Initiate, confirm, track and cancel payments. Every route here needs your SBU's X-SBU-Key and returns a Payment object.

Initiate hosted checkout

Returns a paymentUrl to redirect the customer to Smile&Pay's payment page.

POST/api/v1/payments/checkout/initiate
Auth: X-SBU-Key

The simplest way to take a payment: Smile&Pay hosts the payment page and handles method selection. Redirect the customer to the returned paymentUrl. You may preselect a method with paymentMethod, otherwise the customer chooses on the page.

Body — required

FieldTypeDescription
amountnumberAmount to charge. Minimum 0.01.
currencyCodestring"840" = USD, "924" = ZWG.
itemNamestringName of the item or service being paid for.
returnUrlstringWhere the customer's browser lands after payment.
Body — optional (10)
FieldTypeDescription
paymentMethodenumPreselect on the hosted page: WALLETPLUS, ECOCASH, INNBUCKS, CARD, OMARI or ONEMONEY. Omit to let the customer choose.
itemDescriptionstringDescription of the item. Defaults to itemName.
sbuReferencestringYour invoice/order number, echoed back in every response.
firstNamestringCustomer first name.
lastNamestringCustomer last name.
emailstringCustomer email address.
mobilePhoneNumberstringCustomer mobile number.
cancelUrlstringRedirect target if the customer cancels.
failureUrlstringRedirect target if the payment fails.
extraFieldsobjectExtra Smile&Pay fields not modelled here; passed through verbatim.
Request
curl -X POST https://13-247-53-102.sslip.io/api/v1/payments/checkout/initiate \
  -H 'X-SBU-Key: sbu_your_key_here' \
  -H 'Content-Type: application/json' \
  -d '{
    "amount": 25.50,
    "currencyCode": "840",
    "itemName": "Invoice INV-1042",
    "sbuReference": "INV-1042",
    "returnUrl": "https://yourapp.example/payment/return"
  }'
Response · 200
{
  "orderReference": "PMICRO-32BB1F259960401B",
  "sbuCode": "PMICRO",
  "paymentMethod": "HOSTED",
  "status": "PENDING",
  "amount": 25.50,
  "currencyCode": "840",
  "gatewayReference": "WAJL5621BJYQ",
  "paymentUrl": "https://zbnet.zb.co.zw/wallet_sandbox_checkout?reference=WAJL5621BJYQ",
  "createdAt": "2026-07-19T02:17:20.805236Z"
}

Returns a Payment object.

  • Redirect the customer to paymentUrl to complete payment.
  • The method they actually used arrives later via webhook or status check and replaces HOSTED on the transaction.

Initiate express checkout

Charge directly — no redirect — via ecocash, innbucks, omari, smilecash or card.

POST/api/v1/payments/{method}/initiate
Auth: X-SBU-Key

Express checkout keeps the customer in your own UI. Each method needs one or two extra fields and finishes differently — see the method notes below.

Path parameters

FieldTypeDescription
methodstringinnbucks | ecocash | omari | smilecash | card

Body — required

FieldTypeDescription
amountnumberAmount to charge. Minimum 0.01.
currencyCodestring"840" = USD, "924" = ZWG.
itemNamestringName of the item or service being paid for.
walletNumberstringRequired for ecocash, omari and smilecash — the wallet mobile number to charge.
cardobjectRequired for card: { cardholderName, cardNumber, expiryMonth, expiryYear, cvv }.
Body — optional (10)
FieldTypeDescription
returnUrlstringWhere the customer lands after payment. Defaults to the gateway's public base URL.
itemDescriptionstringDescription of the item. Defaults to itemName.
sbuReferencestringYour invoice/order number, echoed back in every response.
firstNamestringCustomer first name.
lastNamestringCustomer last name.
emailstringCustomer email address.
mobilePhoneNumberstringCustomer mobile number.
cancelUrlstringRedirect target if the customer cancels.
failureUrlstringRedirect target if the payment fails.
extraFieldsobjectExtra Smile&Pay fields not modelled here; passed through verbatim.
Request
curl -X POST https://13-247-53-102.sslip.io/api/v1/payments/ecocash/initiate \
  -H 'X-SBU-Key: sbu_your_key_here' \
  -H 'Content-Type: application/json' \
  -d '{
    "amount": 10.00,
    "currencyCode": "840",
    "itemName": "Order #883",
    "walletNumber": "0771234567"
  }'
Response · 200
{
  "orderReference": "PMICRO-3FD0A655EB7A4AE7",
  "paymentMethod": "ECOCASH",
  "status": "PENDING",
  "amount": 10.00,
  "gatewayReference": "SPUJ8657IOHJ",
  "gatewayResponse": {
    "responseMessage": "Awaiting Payment",
    "status": "AWAITING_PAYMENT"
  }
}

Returns a Payment object.

  • Ecocash — the customer gets a USSD push to approve. Poll the status endpoint until PAID or FAILED.
  • InnBucks — the response carries innbucksPaymentCode and innbucksDeepLink; show them to the customer.
  • Omari & SmileCash — the customer gets an OTP; status becomes AWAITING_CONFIRMATION until you call confirm.
  • Card — gatewayResponse contains the 3DS redirect HTML for the issuer's page.

Confirm with OTP

Second leg for Omari and SmileCash — submits the customer's one-time PIN.

POST/api/v1/payments/{orderReference}/confirm
Auth: X-SBU-Key

Path parameters

FieldTypeDescription
orderReferencestringThe orderReference returned at initiation.

Body — required

FieldTypeDescription
otpstringOne-time PIN the customer received.
Request
curl -X POST https://13-247-53-102.sslip.io/api/v1/payments/PMICRO-3FD0A655EB7A4AE7/confirm \
  -H 'X-SBU-Key: sbu_your_key_here' \
  -H 'Content-Type: application/json' \
  -d '{ "otp": "123456" }'

Returns a Payment object.

  • Only OMARI and SMILECASH have a confirmation leg; other methods return 400.

Get payment status

Reads the transaction; add ?refresh=true to poll Smile&Pay for the live status.

GET/api/v1/payments/{orderReference}
Auth: X-SBU-Key

Path parameters

FieldTypeDescription
orderReferencestringThe orderReference returned at initiation.

Query parameters

FieldTypeDescription
refreshbooleantrue = also query Smile&Pay and update the local record. Default false.
Request
curl 'https://13-247-53-102.sslip.io/api/v1/payments/PMICRO-3FD0A655EB7A4AE7?refresh=true' \
  -H 'X-SBU-Key: sbu_your_key_here'

Returns a Payment object.

  • SBUs only see their own transactions — other references return 404.
  • Prefer webhooks for the final status; use refresh=true as a fallback poll.

Cancel payment

Asks Smile&Pay to cancel; the record moves to CANCELED once confirmed.

POST/api/v1/payments/{orderReference}/cancel
Auth: X-SBU-Key

Path parameters

FieldTypeDescription
orderReferencestringThe orderReference returned at initiation.
Request
curl -X POST https://13-247-53-102.sslip.io/api/v1/payments/PMICRO-3FD0A655EB7A4AE7/cancel \
  -H 'X-SBU-Key: sbu_your_key_here'

Returns a Payment object.

List payments

Your SBU's transaction history, newest first, paginated.

GET/api/v1/payments
Auth: X-SBU-Key

Query parameters

FieldTypeDescription
pageintegerZero-based page index. Default 0.
sizeintegerPage size, capped at 100. Default 20.
Request
curl 'https://13-247-53-102.sslip.io/api/v1/payments?page=0&size=20' \
  -H 'X-SBU-Key: sbu_your_key_here'

Response

FieldTypeDescription
contentPayment[]The page of Payment objects.
totalElementsintegerTotal transactions matching the query.
totalPagesintegerTotal number of pages.
numberintegerCurrent zero-based page index.