`. |
| Modal | `checkout.openModal({ purchaseInfo, config, callBacks })` | Checkout in a pop-up over your page. Close it with `checkout.closePopUp()`. |
```js
import CheckoutSdk from "@hubteljs/checkout";
const checkout = new CheckoutSdk();
const purchaseInfo = {
amount: 50,
purchaseDescription: "Order #1042",
customerPhoneNumber: "233249111411",
clientReference: "order-1042", // from your backend; unique per payment
};
const config = {
branding: "enabled", // "disabled" hides your business name and logo
callbackUrl: "https://example.com/hubtel/callback",
merchantAccount: 11334, // your collection account number
basicAuth: "BASE64_API_ID_AND_KEY",
};
checkout.openModal({
purchaseInfo,
config,
callBacks: {
onInit: () => {},
onLoad: () => {},
onPaymentSuccess: (data) => { checkout.closePopUp(); /* then confirm on your server */ },
onPaymentFailure: (data) => {},
onFeesChanged: (fees) => {},
onResize: (size) => {},
onClose: () => {},
},
});
```
For the iframe method, add `
` where checkout should render (it fills its container by default) and pass an `iframeStyle`, for example `{ width: "100%", height: "100%", border: "none" }`.
| Parameter | Description |
| ------------------------------------------------ | ----------------------------------------------------------------------- |
| `purchaseInfo.amount` | The purchase amount. |
| `purchaseInfo.purchaseDescription` | What the customer is paying for. |
| `purchaseInfo.customerPhoneNumber` | The customer's phone number. |
| `purchaseInfo.clientReference` | Your unique reference for the purchase. |
| `config.branding` | `"enabled"` shows your business name and logo; `"disabled"` hides them. |
| `config.callbackUrl` | Receives the final payment result. |
| `config.merchantAccount` | Your collection account number. |
| `config.basicAuth` | Base64 of `API_ID:API_KEY`, without `Basic `. |
| `config.integrationType` | Defaults to `"External"`, the type for external integrations. |
| `callBacks.onInit`, `onLoad` | Checkout initialised and loaded. |
| `callBacks.onPaymentSuccess`, `onPaymentFailure` | The payment succeeded or failed. |
| `callBacks.onFeesChanged` | The customer changed payment channel and the fees changed. |
| `callBacks.onResize` | The iframe changed size. |
| `callBacks.onClose` | The modal closed. |
## Receive the result on your server [#callback]
Hubtel POSTs the final result to your callback URL:
```json
{
"ResponseCode": "0000",
"Message": "success",
"Data": {
"Amount": 0.12,
"Charges": 0.02,
"AmountAfterCharges": 0.1,
"Description": "The Vodafone Cash payment has been approved and processed successfully",
"ClientReference": "7ee52f85-47ee-423e-b8f8-cda1a59390e1",
"TransactionId": "4a5f113ceeec419399753dc7d704454d",
"ExternalTransactionId": "0000007375832466",
"AmountCharged": 0.12,
"OrderId": "4a5f113ceeec419399753dc7d704454d",
"PaymentDate": "2024-07-24T17:18:58.6620889Z"
}
}
```
A failed payment has `"ResponseCode": "2001"` and `"Message": "failed"`. Checkout callbacks come from `108.129.40.25`. See the [callback reference](/docs/callbacks).
If no callback arrives within 5 minutes, you must [check the transaction status](/docs/guides/reconciliation) with your collection account number and `clientReference`.
## Response codes [#response-codes]
| ResponseCode | Meaning | What to do |
| ------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `0000` | The payment succeeded. | None. |
| `2001` | The payment failed: a payment processor error, wallet limits or insufficient funds, an unknown account holder, an invalid transaction ID, or a card decline. | Common causes are a missing or wrong PIN, a USSD session timeout, special characters (`&*!%@`) in the description, or a number that doesn't match the channel. |
| `4000` | Validation error. | Check the request values. |
| `4070` | Fees aren't set up for this amount or channel. | Use at least the minimum amount, or ask your Hubtel relationship manager to set up fees. |
# Choose a payment method (/docs/guides/choose-a-payment-method)
> Hubtel gives you several ways to collect payments. Pick the one that matches where your customers pay and how much of the payment experience you want to build.
| If you… | Use | Why |
| ---------------------------------------------------------- | --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- |
| Sell on a website and want Hubtel to host the payment page | **[Online Checkout](/docs/guides/online-checkout)** | Hubtel hosts the payment page: mobile money, card and Hubtel wallet. No card data touches your servers. |
| Have a mobile app, or want checkout inside your web page | **[Checkout SDK](/docs/guides/checkout-sdk)** (Android, iOS, Flutter, JavaScript) | Show Hubtel's payment screen in your app, or as a redirect, iframe or modal on your site. |
| Charge a known customer from your server, with your own UI | **[Direct Receive Money](/docs/guides/receive-money)** | You collect the number; the customer approves a prompt on their phone. |
| Bill the same customer repeatedly (loans, subscriptions) | **[Direct Debit](/docs/guides/direct-debit)** | Collect subsequent payments after the customer approves direct debits. |
| Send someone a bill to pay later | **[Invoicing](/docs/guides/invoicing)** | Itemised invoice by SMS and email with a payment link. |
If you're not sure which to use, start with Online Checkout. For a payment interface you control, review Direct Receive Money and its callback requirements.
Each method ends the same way: Hubtel sends a callback with the final result, and you check the status if the callback is late. [Build a complete payment integration](/docs/get-started/first-payment) covers this pattern.
# Airtime, data and bill payments (/docs/guides/commission-services)
> To sell airtime, data bundles or bill payments, look up the customer's account if the service needs it, then pay from your disbursement balance. You earn a commission on each sale.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Disbursement account number**: You top up this account to fund payouts and purchases. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Every commission service uses one URL pattern, paid from your **disbursement account**:
```
https://cs.hubtel.com/commissionservices/{disbursementAccount}/{serviceId}
```
For services that provide an account or bundle lookup, query the service before submitting a payment:
1. **Query** the account or bundle list (for example an ECG meter or a DStv smartcard) to confirm it exists and see the customer's name or available bundles.
2. **Pay** from your disbursement balance. The response is pending.
3. **Receive the callback** with the final result at your callback URL.
4. If no callback arrives within 5 minutes, check the purchase status. Ask your Retail Systems Engineer for the host, account type and reference to use. Do not submit another purchase while the outcome is unknown.
```bash
curl https://cs.hubtel.com/commissionservices/$HUBTEL_DISBURSEMENT_ACCOUNT/fdd76c884e614b1c8f669a3207b09a98 \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{"Destination":"233246912184","Amount":5.00,"CallbackUrl":"https://example.com/hubtel/airtime","ClientReference":"airtime-2211"}'
```
```json
{ "ResponseCode": "0001", "Message": "Transaction pending. Expect callback request for final state", "Data": { "ClientReference": "airtime-2211", "Amount": 5, "TransactionId": "b47cf67d6bd2cc1b03362ce23e232337", "Meta": { "Commission": "0.05" } } }
```
| Service | Query | Pay |
| -------------------------------------------------- | ----------- | --------------------------------------- |
| Airtime (MTN, Telecel, AT) | — | Top-up, at most **GHS 100** per request |
| Data bundles (MTN, Telecel, AT, Telecel broadband) | Bundle list | Top-up |
| DStv, GOtv, StarTimes | Account | Bill payment |
| ECG, Ghana Water | Meter | Top-up |
## Service IDs [#service-ids]
| Service ID | Service |
| ---------------------------------- | ---------------------- |
| `fdd76c884e614b1c8f669a3207b09a98` | MTN Airtime |
| `f4be83ad74c742e185224fdae1304800` | Telecel Airtime |
| `dae2142eb5a14c298eace60240c09e4b` | AirtelTigo Airtime |
| `b230733cd56b4a0fad820e39f66bc27c` | MTN Data |
| `fa27127ba039455da04a2ac8a1613e00` | Telecel Data |
| `06abd92da459428496967612463575ca` | AirtelTigo Data |
| `b9a1aa246ba748f9ba01ca4cdbb3d1d3` | Telecel Broadband |
| `297a96656b5846ad8b00d5d41b256ea7` | DStv |
| `e6ceac7f3880435cb30b048e9617eb41` | GOtv |
| `6598652d34ea4112949c93c079c501ce` | StarTimes TV |
| `e6d6bac062b5499cb1ece1ac3d742a84` | ECG Prepaid & Postpaid |
| `6c1e8a82d2e84feeb8bfd6be2790d71d` | Ghana Water |
| `a3ab78c84c6b4976b78a6f393e247a72` | Telecel Postpaid Bills |
Request fields for Telecel Postpaid Bills aren't published. Ask your Retail Systems Engineer for them.
Callbacks come from `18.202.122.131` ([payload](/docs/callbacks#commission-services)). Requests must come from an [allowlisted server IP](/docs/networking).
See the [Commission Services reference](/docs/api/v1/commission-services) for each request, and its [response codes](/docs/api/v1/commission-services#response-codes).
# Direct Debit (/docs/guides/direct-debit)
> To charge a customer repeatedly without a prompt each time, get their one-time approval, then charge their wallet through Receive Money with a direct debit channel.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Use Direct Debit for loan repayments, savings contributions and subscriptions. Pre-approval applies to a wallet and merchant account.
| Network | Channel |
| ------------- | -------------------------- |
| MTN Ghana | `mtn-gh-direct-debit` |
| Telecel Ghana | `vodafone-gh-direct-debit` |
All requests use your **collection account number** and must come from an [allowlisted server IP](/docs/networking).
## Get the customer's approval [#preapproval]
### Start the pre-approval [#start-the-pre-approval]
[Start a direct debit pre-approval](/docs/api/v1/direct-debit/initiate-preapproval) with the customer's number, the channel, a unique `clientReferenceId` (at most 36 characters) and your `callbackUrl`:
```bash
curl https://preapproval.hubtel.com/api/v2/merchant/$HUBTEL_COLLECTION_ACCOUNT/preapproval/initiate \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{"clientReferenceId":"loan-7781-mandate","customerMsisdn":"233200000000","channel":"vodafone-gh-direct-debit","callbackUrl":"https://example.com/hubtel/preapproval"}'
```
```json
{
"message": "Request received! Pending preapproval",
"responseCode": "2000",
"data": { "hubtelPreApprovalId": "5f20092321d54eefb974dbfea6de5c34", "clientReferenceId": "loan-7781-mandate", "verificationType": "OTP", "otpPrefix": "HNRM", "preapprovalStatus": "PENDING" }
}
```
Keep `hubtelPreApprovalId`.
### Let the customer approve [#let-the-customer-approve]
The response's `verificationType` tells you how. You can't choose it:
* **`USSD`**: the number is new to Direct Debit. The customer approves a USSD prompt on their phone; skip the OTP step. MTN customers who miss the prompt can find it by dialling `*170#` → **6. My Wallet** → **3. My Approvals** → **2. PreApprovals**.
* **`OTP`**: the number is already pre-approved for another merchant. The customer receives a 4-digit code. Ask for it, then [confirm the pre-approval with the OTP](/docs/api/v1/direct-debit/verify-preapproval-otp), sending `otpCode` as the `otpPrefix` from step 1, a hyphen and the code:
```bash
curl https://preapproval.hubtel.com/api/v2/merchant/$HUBTEL_COLLECTION_ACCOUNT/preapproval/verifyotp \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{"customerMsisdn":"233200000000","hubtelPreApprovalId":"5f20092321d54eefb974dbfea6de5c34","clientReferenceId":"loan-7781-mandate","otpCode":"HNRM-8852"}'
```
### Wait for the pre-approval callback [#wait-for-the-pre-approval-callback]
Hubtel POSTs the final status, `APPROVED` or `FAILED`, to your `callbackUrl` ([payload](/docs/callbacks#preapproval)). If it doesn't arrive, or to double-check, [get the pre-approval's status](/docs/api/v1/direct-debit/get-preapproval-status): `APPROVED`, `FAILED` or `EXPIRED`.
Pre-approval is a one-time process for each wallet and merchant account.
## Charge the wallet [#charge]
Charge with the [Receive Money endpoint](/docs/api/v1/receive-money/receive-mobile-money) and the direct debit channel. Pre-approved customers get no prompt.
```bash
curl https://rmp.hubtel.com/merchantaccount/merchants/$HUBTEL_COLLECTION_ACCOUNT/receive/mobilemoney \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{"CustomerMsisdn":"233200000000","Channel":"vodafone-gh-direct-debit","Amount":150.00,"Description":"Loan 7781 instalment 3","ClientReference":"loan-7781-03","PrimaryCallbackUrl":"https://example.com/hubtel/callback"}'
```
1. The response is `0001` (pending).
2. Hubtel POSTs the final result to your callback URL, usually within 30 seconds, from `18.202.122.131` ([payload](/docs/callbacks#receive-money)).
3. If no callback arrives within 5 minutes, you must [check the transaction status](/docs/guides/reconciliation#transaction-status).
## Stop or resume debits [#stop-or-resume-debits]
* [Cancel a pre-approval](/docs/api/v1/direct-debit/cancel-preapproval) when a loan is repaid or a subscription ends.
* [Reactivate a pre-approval](/docs/api/v1/direct-debit/reactivate-preapproval) when the customer resumes; they approve again.
See the [Direct Debit reference](/docs/api/v1/direct-debit#response-codes) for every response code.
# Invoices and recurring billing (/docs/guides/invoicing)
> To bill a customer, send an invoice they pay from a link, or set up a recurring invoice that debits their wallet on a schedule.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Hubtel has two invoicing APIs. Both use your **collection account number**, need an [allowlisted server IP](/docs/networking), and end with a callback plus a status check if the callback is late.
| | [Invoicing](#invoicing) | [Recurring Invoice](#recurring-invoice) |
| ------------------ | ----------------------------------------------------- | --------------------------------------- |
| Best for | One-off or repeat bills the customer pays from a link | Automatic debits on a schedule |
| Customer pays with | Mobile money, card, G-Money wallet, cash or cheque | Mobile money (MTN, Telecel) |
| Customer approval | Pays each invoice | Approves once with an OTP and a prompt |
| Callbacks from | `18.202.122.131` | `34.241.57.109` |
## Invoicing [#invoicing]
Hubtel sends the invoice to your customer by SMS and email, with a link to a payment page.
* **[Send an invoice](/docs/api/v1/invoicing/create-invoice)** (`/simple`) for a one-time payment in full.
* **[Send a repeating invoice](/docs/api/v1/invoicing/create-repeat-invoice)** (`/repeat`) for repeat payments until the due date. Auto debit is available for MTN and Telecel.
```bash
curl https://invoicing.hubtel.com/api/v2.0/invoice/$HUBTEL_COLLECTION_ACCOUNT/simple \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" -d '{
"invoiceNumber": "INV-1042",
"dueDate": "2026-12-31T23:59:59Z",
"createdBy": "Kofi",
"customerName": "Ama Mensah",
"customerPhoneNumber": "233555654321",
"customerEmail": "ama@example.com",
"items": [{ "description": "Annual subscription", "quantity": 1, "unitPrice": 120 }],
"callbackUrl": "https://example.com/hubtel/invoices"
}'
```
```json
{ "message": "Invoice has been created.", "code": 201, "data": { "invoiceId": "pY3HfCTXZb", "paymentUrl": "https://approval.biz/pY3HfCTXZb" } }
```
Each invoice can include `items`, `discounts`, `fees` and `appliedTaxes`. Item quantities must be at least 1 and prices at least 0.01. Flat discounts can't exceed the subtotal, and percentage discounts can't exceed 100. The [Invoicing reference](/docs/api/v1/invoicing/create-invoice) has every field.
Hubtel POSTs each payment's result to your callback URL ([payload](/docs/callbacks#invoicing)). If a payment's callback doesn't arrive within 5 minutes, you must call [Get an invoice's status](/docs/api/v1/invoicing/get-invoice-status) with the invoice ID. Invoicing has its own [response codes](/docs/api/v1/invoicing#response-codes) for invoice, item, discount and tax validation.
## Recurring Invoice [#recurring-invoice]
Hubtel schedules and collects each instalment from the customer's mobile money wallet. Use channel `mtn_gh_rec` (MTN) or `vodafone_gh_rec` (Telecel).
### Create the invoice [#create-the-invoice]
[Create a recurring invoice](/docs/api/v1/recurring-invoice/create-recurring-invoice):
```bash
curl https://rip.hubtel.com/api/proxy/$HUBTEL_COLLECTION_ACCOUNT/create-invoice \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" -d '{
"orderDate": "2026-11-01T08:00:00", "invoiceEndDate": "2027-10-31T08:00:00",
"description": "Gym membership", "startTime": "08:00", "paymentInterval": "MONTHLY",
"customerMobileNumber": "233249111411", "customerName": "Ama Mensah",
"paymentOption": "MobileMoney", "channel": "mtn_gh_rec",
"recurringAmount": 50, "totalAmount": 50, "initialAmount": 50, "currency": "GHS",
"callbackUrl": "https://example.com/hubtel/recurring"
}'
```
```json
{ "responseCode": "0001", "message": "Your request has been processed successfully.", "data": { "recurringInvoiceId": "0f84e20a2839482e807128e8c21d08d6", "requestId": "a6487bc44eae44849fd80326a0dd802a", "otpPrefix": "OQDM" } }
```
Replace `orderDate`, `invoiceEndDate` and `dueDate` in these examples with dates for your billing schedule.
The invoice stays temporary until it's verified. Hubtel sends the customer an OTP. Set `totalAmount` to the same value as `recurringAmount`.
### Verify it with the customer's OTP [#verify-it-with-the-customers-otp]
Ask the customer for the code and [verify the recurring invoice](/docs/api/v1/recurring-invoice/verify-recurring-invoice), sending `otpCode` as the prefix, a hyphen and the code:
```bash
curl https://rip.hubtel.com/api/proxy/verify-invoice -u "$HUBTEL_API_ID:$HUBTEL_API_KEY" \
-H "Content-Type: application/json" \
-d '{"recurringInvoiceId":"0f84e20a2839482e807128e8c21d08d6","requestId":"a6487bc44eae44849fd80326a0dd802a","otpCode":"OQDM-9514"}'
```
Hubtel then prompts the customer to approve. MTN customers who miss the prompt can find it by dialling `*170#` → **6. My Wallet** → **3. My Approvals** → **2. PreApprovals**.
### Receive the first payment [#receive-the-first-payment]
After the customer approves, Hubtel takes the first payment and sends a callback. Approval can take up to 10 minutes.
### Receive each instalment [#receive-each-instalment]
Whenever an instalment is due, Hubtel debits the wallet and sends a callback with the result ([payload](/docs/callbacks#recurring-invoice)). Store each instalment separately and prevent duplicate fulfilment. If an instalment callback doesn't arrive, confirm the result with your Retail Systems Engineer before you fulfil it.
[Cancel a recurring invoice](/docs/api/v1/recurring-invoice/cancel-recurring-invoice) to stop future debits. The "New Retry (Onetime)" and "New Retry (Custom)" retry options were discontinued in July 2024; don't build on them.
# Lending data (/docs/guides/lending)
> To assess a borrower, request their credit score and credit reports from myCreditScore, with the customer's consent.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **Lenders Portal API ID and API key**: You create these in the myCreditScore Lenders Portal. They're separate from your payment keys. [Lending data](/docs/guides/lending)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
These APIs are operated by the licensed credit bureau myCreditScore (`mycreditscore.com.gh`) on Hubtel's behalf.
## Before you start [#before-you-start]
* **Register as a lender** with myCreditScore at [mycreditscore.com.gh/register-lender](https://mycreditscore.com.gh/register-lender).
* **Create API credentials in the myCreditScore Lenders Portal.** These are separate from your Hubtel payment keys. Authenticate with HTTP Basic: Base64 of `API_ID:API_KEY`.
* **Get the customer's consent** before you request their data.
## Reports [#reports]
| Report | Use it for | Host |
| ----------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------- |
| [Credit score](/docs/api/v1/lending/check-credit-score) | A numerical creditworthiness score from repayment behaviour, credit exposure and financial behaviour | `score-api.mycreditscore.com.gh` |
| [Consumer identity report](/docs/api/v1/lending/get-consumer-identity-report) | Validated primary and associated identities, for KYC, identity verification and skip tracing | `profile-api.mycreditscore.com.gh` |
| [Consumer profile detail](/docs/api/v1/lending/get-consumer-profile) | Demographics, employment and address history, and identification numbers | `basic-credit-report-api.mycreditscore.com.gh` |
| [Compact credit report](/docs/api/v1/lending/get-credit-profile-summary) | Totals per currency: accounts, outstanding debt, arrears, judgment debts and dishonoured cheques | `basic-credit-report-api.mycreditscore.com.gh` |
| [Repayment history](/docs/api/v1/lending/get-repayment-history) | Repayment behaviour per credit facility, with overdue counts by age (1–30 days up to 180+ days) | `score-debt-api.mycreditscore.com.gh` |
A credit score request needs at least the customer's `ghanaCard`, `identifierDob` (ISO 8601) and `creditAmount`; other identifiers are optional.
Use the linked operation reference for the request fields and response.
## Collect repayments [#collect-repayments]
Disburse loans with [Send Money](/docs/guides/payouts), collect repayments with [Direct Debit](/docs/guides/direct-debit), [Receive Money](/docs/guides/receive-money) or [Recurring Invoice](/docs/guides/invoicing#recurring-invoice), and remind borrowers with [SMS](/docs/guides/sms).
# Online Checkout (/docs/guides/online-checkout)
> To accept a payment on your website, create a checkout on your server and send your customer to the checkout page. Hubtel collects the payment and sends the result to your callback URL.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Online Checkout is a payment page hosted by Hubtel. Your customer pays with mobile money, card or Hubtel wallet, and card details never touch your servers.
### Create the checkout on your server [#create-the-checkout-on-your-server]
[Create a checkout](/docs/api/v1/online-checkout/initiate-checkout) with your payment keys:
```bash
curl https://payproxyapi.hubtel.com/items/initiate -u "$HUBTEL_API_ID:$HUBTEL_API_KEY" \
-H "Content-Type: application/json" -d '{
"totalAmount": 45.00,
"description": "Order 1042",
"callbackUrl": "https://example.com/hubtel/callback",
"returnUrl": "https://example.com/orders/1042",
"cancellationUrl": "https://example.com/cart",
"merchantAccountNumber": "'"$HUBTEL_COLLECTION_ACCOUNT"'",
"clientReference": "order-1042"
}'
```
| Field | Required | Description |
| ---------------------------------------------- | -------- | -------------------------------------------------------------------- |
| `totalAmount` | Yes | Amount to charge, with at most 2 decimal places. |
| `description` | Yes | What the customer is paying for. Special characters aren't accepted. |
| `callbackUrl` | Yes | Your endpoint for the final payment result. |
| `returnUrl` | Yes | Where the customer goes after paying. |
| `cancellationUrl` | Yes | Where the customer goes if they cancel. |
| `merchantAccountNumber` | Yes | Your [collection account number](/docs/get-started/keys#accounts). |
| `clientReference` | Yes | Your unique reference for this payment, at most **32 characters**. |
| `payeeName`, `payeeMobileNumber`, `payeeEmail` | No | The customer's details. |
The response contains two URLs for the same checkout:
```json
{
"responseCode": "0000",
"status": "Success",
"data": {
"checkoutUrl": "https://pay.hubtel.com/7569a11e8b784f21baa9443b3fce31ed",
"checkoutId": "7569a11e8b784f21baa9443b3fce31ed",
"clientReference": "order-1042",
"message": "",
"checkoutDirectUrl": "https://pay.hubtel.com/7569a11e8b784f21baa9443b3fce31ed/direct"
}
}
```
`responseCode` `0000` here means the checkout was created, not that anything was paid.
### Show the payment page [#show-the-payment-page]
Choose how the customer sees the page:
* **Redirect:** send the customer to `data.checkoutUrl`. After paying they return to your `returnUrl`.
* **Onsite:** load `data.checkoutDirectUrl` in an iframe on your page, so the customer pays without leaving your site.
Pass only the URL to the browser. Your API key must never reach the page.
### Confirm the payment [#confirm-payment-from-the-callback-not-the-redirect]
The customer's return to your `returnUrl` doesn't confirm payment. Show "We're confirming your payment" until one of these tells you the result:
* **The callback.** Hubtel POSTs to your `callbackUrl` from `108.129.40.25`. `ResponseCode` `0000` with `Status` `Success` means paid; see the [payload](/docs/callbacks#checkout). Handle it as described in [Webhooks and callbacks](/docs/webhooks).
* **A status check.** If no callback arrives within 5 minutes, you must [check the status](/docs/guides/reconciliation) with your `clientReference`. `Paid` means you can fulfil the order.
If the payment fails, let the customer try again with a new checkout and a new `clientReference`.
## Response codes [#response-codes]
| Code | Meaning | What to do |
| ------ | --------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- |
| `0000` | Checkout created (in the response), or payment succeeded (in the callback). | Proceed. |
| `0005` | Hubtel couldn't reach the payment partner. The payment's state is unknown. | Ask your Retail Systems Engineer to confirm the transaction's status. |
| `2001` | The payment failed, for example a processor error, insufficient funds or wallet limits. | Let the customer try again with a new `clientReference`. |
| `4000` | Validation error. | Check the request values. |
| `4070` | Fees aren't set up for this amount or channel. | Send at least the minimum amount, or ask your Hubtel relationship manager to set up fees. |
## Reference [#reference]
* [Create a checkout](/docs/api/v1/online-checkout/initiate-checkout)
* [Check a collection's status](/docs/api/v1/transaction-status/get-transaction-status)
# Pay out to wallets and banks (/docs/guides/payouts)
> To pay someone, make sure your disbursement balance covers the amount, verify the recipient, and send the payout to their wallet or bank account. Hubtel sends the final result to your callback URL.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Disbursement account number**: You top up this account to fund payouts and purchases. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Payouts are funded from your **disbursement account**. Check the available balance with [Get your disbursement balance](/docs/api/v1/balance-transfers/get-disbursement-balance), and top it up from your collection balance with a [balance transfer](/docs/guides/balance-transfers).
### Verify the recipient [#verify-the-recipient]
For wallets, [look up the registered name](/docs/guides/verification) and compare it with the recipient name supplied by your user. For banks, use [Look up a bank account name](/docs/api/v1/verification/verify-bank-account) with the recipient's [bank code](#bank-codes).
### Send the payout [#send-the-payout]
[Pay out to a mobile money wallet](/docs/api/v1/send-money/send-mobile-money) or [to a bank account](/docs/api/v1/send-to-bank/send-to-bank) from your **disbursement** account:
```bash
curl https://smp.hubtel.com/api/merchants/$HUBTEL_DISBURSEMENT_ACCOUNT/send/mobilemoney \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{"RecipientName":"Kwame Asante","RecipientMsisdn":"233249111411","Channel":"mtn-gh","Amount":10.00,"Description":"Refund for order 1042","ClientReference":"payout-5531","PrimaryCallbackURL":"https://example.com/hubtel/payouts"}'
```
```json
{ "ResponseCode": "0001", "Data": { "AmountDebited": 0, "TransactionId": "8a545e5c7357714b80b65f76", "Description": "Your request has been accepted. We will notify you when the transaction is completed.", "ClientReference": "payout-5531", "Amount": 10, "Charges": 0 } }
```
### Wait for the callback or check the status [#wait-for-the-callback-or-check-the-status]
The final result arrives at your callback URL ([payload](/docs/callbacks#payouts)). If it hasn't arrived after 5 minutes, [check the payout's status](/docs/api/v1/send-money/get-payout-status).
If your balance can't cover the amount plus fees, the request is still accepted with `0001`. The callback then reports `"ResponseCode": "4075"` and `"Description": "Insufficient prepaid balance."`. Top up your disbursement account and send the payout again with a new `ClientReference`.
## Bank codes [#bank-codes]
Send to Bank pays out over the GhIPSS network. Put the recipient bank's code in the path, and use the same code for [Look up a bank account name](/docs/api/v1/verification/verify-bank-account). Send the bank's name, as listed here, in `BankName`.
```bash
curl https://smp.hubtel.com/api/merchants/$HUBTEL_DISBURSEMENT_ACCOUNT/send/bank/gh/300304 \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{"Amount":10.00,"BankName":"GCB BANK LIMITED","BankAccountNumber":"1234567890","BankAccountName":"Kwame Asante","ClientReference":"bank-5532","PrimaryCallbackUrl":"https://example.com/hubtel/payouts","Description":"Supplier payment"}'
```
| Bank | bankCode |
|---|---|
| STANDARD CHARTERED BANK | `300302` |
| ABSA BANK GHANA LIMITED | `300303` |
| GCB BANK LIMITED | `300304` |
| NATIONAL INVESTMENT BANK | `300305` |
| ARB APEX BANK LIMITED | `300306` |
| AGRICULTURAL DEVELOPMENT BANK | `300307` |
| UNIVERSAL MERCHANT BANK | `300309` |
| REPUBLIC BANK LIMITED | `300310` |
| ZENITH BANK GHANA LTD | `300311` |
| ECOBANK GHANA LTD | `300312` |
| CAL BANK LIMITED | `300313` |
| FIRST ATLANTIC BANK | `300316` |
| PRUDENTIAL BANK LTD | `300317` |
| STANBIC BANK | `300318` |
| FIRST BANK OF NIGERIA | `300319` |
| BANK OF AFRICA | `300320` |
| GUARANTY TRUST BANK | `300322` |
| FIDELITY BANK LIMITED | `300323` |
| SAHEL - SAHARA BANK (BSIC) | `300324` |
| UNITED BANK OF AFRICA | `300325` |
| ACCESS BANK LTD | `300329` |
| CONSOLIDATED BANK GHANA | `300331` |
| FIRST NATIONAL BANK | `300334` |
| GHL BANK | `300362` |
# Direct Receive Money (/docs/guides/receive-money)
> To charge a customer's mobile money wallet, send a Receive Money request from your server. The customer approves the prompt on their phone, and Hubtel sends the final result to your callback URL.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Use this guide for Receive Money fields and responses. [Build a complete payment integration](/docs/get-started/first-payment) covers setup, callbacks, failures and testing. For a hosted payment page, use [Online Checkout](/docs/guides/online-checkout).
The integration is a three-step process:
1. [Charge the wallet](#charge-the-wallet)
2. [Get the result](#get-the-result) from your callback
3. Check the status if no result arrives within 5 minutes
## Before you start [#before-you-start]
* **Prevent unsolicited prompts.** Charge only registered users who can't change their number at payment time, or confirm unregistered numbers with the customer before you charge them.
* **Allowlist your server IP.** Production accepts requests only from [allowlisted addresses](/docs/networking).
## Charge the wallet [#charge-the-wallet]
```bash
curl https://rmp.hubtel.com/merchantaccount/merchants/$HUBTEL_COLLECTION_ACCOUNT/receive/mobilemoney \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{
"CustomerName": "Ama Mensah",
"CustomerMsisdn": "233249111411",
"Channel": "mtn-gh",
"Amount": 45.00,
"Description": "Order #1042",
"ClientReference": "order-1042",
"PrimaryCallbackUrl": "https://example.com/hubtel/callback"
}'
```
| Field | Required | Description |
| ------------------------------- | -------- | --------------------------------------------------------------------------------------------------------------------------- |
| `CustomerMsisdn` | Yes | The customer's mobile money number in international format, for example `233249111411`. |
| `Channel` | Yes | `mtn-gh`, `vodafone-gh` or `tigo-gh`, matching the number's network. |
| `Amount` | Yes | Amount to charge, with at most 2 decimal places. |
| `Description` | Yes | What the customer is paying for. |
| `ClientReference` | Yes | Your unique reference for this payment, at most 36 characters. See [Client references](/docs/conventions#client-reference). |
| `PrimaryCallbackUrl` | Yes | Your endpoint for the final result. |
| `CustomerName`, `CustomerEmail` | No | The name on the wallet, and the customer's email. |
The response means the prompt is on its way, not that the customer has paid:
```json
{
"Message": "Transaction pending. Expect callback request for final state",
"ResponseCode": "0001",
"Data": { "TransactionId": "a1c92e8776b0964b1b2448ba16528876", "Description": "Order #1042", "ClientReference": "order-1042", "Amount": 45, "Charges": 0.88, "AmountAfterCharges": 45, "AmountCharged": 45.88, "DeliveryFee": 0 }
}
```
## Get the result [#get-the-result]
1. The customer approves or declines the prompt on their phone.
2. Hubtel POSTs the result to `PrimaryCallbackUrl` from `18.202.122.131`, usually within 30 seconds: `0000` paid, `2001` failed. See the [payload](/docs/callbacks#receive-money).
3. If no final result arrives after 5 minutes, [check the status](/docs/guides/reconciliation). This is mandatory.
After a failure, let the customer try again with a new `ClientReference`.
[Build a complete payment integration](/docs/get-started/first-payment) walks through each step, including failures and lost callbacks.
## Response codes [#response-codes]
See [Receive Money response codes](/docs/api/v1/receive-money#response-codes) and [common request errors](/docs/errors).
# Reconciliation and status checks (/docs/guides/reconciliation)
> Check the status of any payment that has no final result after 5 minutes, then update your order. Every payment integration must do this.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Callbacks usually arrive within 30 seconds, but delivery isn't guaranteed. You must check the status of any payment without a final callback after 5 minutes. Schedule a job to check unresolved orders older than 5 minutes; running it every minute is one option. Make order updates idempotent so a callback and a status check cannot fulfil the same order twice.
For each unresolved order:
1. Request its status using the original reference.
2. If the request fails or the response is incomplete, keep the order unresolved and retry on a later run. Record repeated failures for investigation.
3. For `Paid`, match the returned reference and amount to the stored order, then fulfil once.
4. For `Unpaid`, keep checking or escalate for investigation. This status alone does not distinguish pending, failed and expired payments.
5. For `Refunded`, update your records and follow your refund workflow.
The contract does not define a timeout after which `Unpaid` becomes a final failure. Don't mark a payment failed solely because 30 minutes have passed, or create another charge while its outcome is unknown.
## Check a collection's status [#transaction-status]
[Check a collection's status](/docs/api/v1/transaction-status/get-transaction-status) works for payments made through Online Checkout, the Checkout SDK, Direct Receive Money, Direct Debit and Programmable Services. Implementing it is mandatory.
```bash
curl "https://api-txnstatus.hubtel.com/transactions/$HUBTEL_COLLECTION_ACCOUNT/status?clientReference=order-1042" \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY"
```
* Put your **collection account number** in the path.
* Identify the payment with `clientReference` (recommended), `hubtelTransactionId` or `networkTransactionId`.
* Only allowlisted server IPs can reach this endpoint in production. Other addresses get `403` or a timeout; see [IP allowlisting](/docs/networking).
```json
{
"message": "Successful",
"responseCode": "0000",
"data": {
"date": "2024-04-25T21:45:48.4740964Z",
"status": "Paid",
"transactionId": "7fd01221faeb41469daec7b3561bddc5",
"externalTransactionId": "0000006824852622",
"paymentMethod": "mobilemoney",
"clientReference": "order-1042",
"currencyCode": null,
"amount": 45,
"charges": 0.88,
"amountAfterCharges": 45,
"isFulfilled": null
}
}
```
`transactionId` is Hubtel's ID and `externalTransactionId` is the network's reference. `currencyCode` and `isFulfilled` can be `null`.
Payouts and balance transfers have their own status checks: [Check a payout's status](/docs/api/v1/send-money/get-payout-status) and [Get a transfer's status](/docs/api/v1/balance-transfers/get-transfer-status). Invoices use [Get an invoice's status](/docs/api/v1/invoicing/get-invoice-status).
## Status values [#status-values]
| `status` | Meaning | Do |
| ---------- | ------------------------------------------------------- | -------------------------------------------- |
| `Paid` | Money received | Fulfil once |
| `Unpaid` | No confirmed payment; may be pending, failed or expired | Keep unresolved; check again or investigate |
| `Refunded` | The payment was [refunded](/docs/guides/refunds) | Reverse fulfilment as your business requires |
Status Check responses use camelCase (`responseCode`, `data`), unlike Receive Money's PascalCase. See [Field casing](/docs/conventions#casing).
# Refunds (/docs/guides/refunds)
> To return a payment, send a refund request with the payment's order ID. Hubtel refunds the whole amount and sends the result to your callback URL.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
A refund returns the whole order to the customer. Send the payment's `OrderId` (or `TransactionId`) from its callback or status check:
```bash
curl -X POST https://refund-api.hubtel.com/refund/$HUBTEL_COLLECTION_ACCOUNT/order/a1c92e8776b0964b1b2448ba16528876 \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY" -H "Content-Type: application/json" \
-d '{"callbackUrl":"https://example.com/hubtel/refunds"}'
```
```json
{ "message": "Transaction pending. Expect callback request for final state.", "responseCode": "0001", "data": { "orderId": "a1c92e8776b0964b1b2448ba16528876" } }
```
The response is `0001` (HTTP 202). Hubtel then POSTs the result to your `callbackUrl` ([payload](/docs/callbacks#refunds)), and a [status check on the original payment](/docs/guides/reconciliation) shows `Refunded` after completion. If no final callback arrives after 5 minutes, check that original payment before retrying a refund.
| Limit | Detail |
| --------------- | ---------------------------------------------------------------------------------------------------------------- |
| Payment types | Mobile money payments. |
| Age | Payments from the last **45 days**. For older payments, email [business@hubtel.com](mailto:business@hubtel.com). |
| Amount | Orders under GHS 1 can't be refunded (`4000`). |
| Repeat requests | A second request for an order already being refunded returns `4515` (HTTP 423). Wait for the first callback. |
| Network | Requests must come from an [allowlisted server IP](/docs/networking). |
Other codes: `3000` (order not found, HTTP 404) and `4509` (order not eligible for a refund). See the [Refunds reference](/docs/api/v1/refunds#response-codes).
# Service fulfilment (/docs/guides/service-fulfilment)
> After a customer pays, Hubtel sends the order to your Service Fulfilment URL. Deliver the service, then tell Hubtel within one hour.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Fulfilment goes both ways: Hubtel sends the paid order to **your Service Fulfilment URL**, and after you deliver the service, **you send a fulfilment callback to Hubtel**.
## Receive the paid order [#receive-the-paid-order]
After the customer pays, Hubtel POSTs the order to your Service Fulfilment URL:
```json
{
"SessionId": "example-session",
"OrderId": "example-order",
"ExtraData": {},
"OrderInfo": {
"CustomerMobileNumber": "233249111411",
"CustomerEmail": null,
"CustomerName": "Ama Mensah",
"Status": "Paid",
"OrderDate": "2023-11-06T15:16:50.3581338+00:00",
"Currency": "GHS",
"BranchName": "Haatso",
"IsRecurring": false,
"RecurringInvoiceId": null,
"Subtotal": 151.5,
"Items": [{ "ItemId": "5b8945940e1247489e34e756d8fc2dbb", "Name": "Send Money", "Quantity": 1, "UnitPrice": 150.5 }],
"Payment": {
"PaymentType": "mobilemoney",
"AmountPaid": 151.5,
"AmountAfterCharges": 150.5,
"PaymentDate": "2023-11-06T15:16:50.3581338+00:00",
"PaymentDescription": "The MTN Mobile Money payment has been approved and processed successfully.",
"IsSuccessful": true
}
}
}
```
Match `SessionId` and `OrderId` to your records, and make sure a repeated request can't deliver the service twice. These requests come from `52.50.116.54`, `18.202.122.131` and `52.31.15.68`.
## Report fulfilment [#report]
Within **one hour** of receiving the order, deliver the service and POST the result to Hubtel:
```bash
curl https://gs-callback.hubtel.com:9055/callback -H "Content-Type: application/json" \
-d '{"SessionId":"example-session","OrderId":"example-order","ServiceStatus":"success","MetaData":null}'
```
The endpoint takes no `Authorization` header and accepts requests only from your [allowlisted server IP](/docs/guides/ussd#network-access). See the [reference](/docs/api/v1/programmable-services/report-service-fulfilment).
## Check a transaction's status [#status]
If you have no final payment result **after 5 minutes**, check the status. This is mandatory. Pass the `SessionId` as `clientReference`, and your collection account number in the path:
```bash
curl "https://api-txnstatus.hubtel.com/transactions/$HUBTEL_COLLECTION_ACCOUNT/status?clientReference=example-session" \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY"
```
| `status` | Meaning | Do |
| ---------- | ------------------------- | ----------------------------------------------------------- |
| `Paid` | The customer paid. | Deliver the service if you haven't, then report fulfilment. |
| `Unpaid` | Not paid yet, or failed. | Don't create a new payment; check again later. |
| `Refunded` | The payment was refunded. | Reverse delivery as your service requires. |
`isFulfilled` shows whether Hubtel has recorded fulfilment and can be `null`. Keep your own fulfilment record. You can also look up a transaction by `hubtelTransactionId` or `networkTransactionId`. The response fields are described in [Reconciliation](/docs/guides/reconciliation#transaction-status).
# Service interactions and responses (/docs/guides/service-interactions)
> Hubtel sends each step of a customer's session to your Service Interaction URL. Reply with the next screen, end the session, or send the item to checkout.
Register your endpoint as described in [Programmable Services](/docs/guides/ussd#register). Field names and values are case-sensitive.
## Incoming request [#incoming-request]
| Field | Type | Meaning |
| ------------- | ------- | --------------------------------------------------------------------------------------------------------------- |
| `Type` | String | `Initiation` starts a session, `Response` continues it, and `Timeout` means the customer cancelled the session. |
| `Message` | String | Customer input, or the dialled USSD string at initiation. |
| `ServiceCode` | String | Service code, for example `711*2`. |
| `Operator` | String | `mtn`, `vodafone` (Telecel), `tigo` or `airtel` (AirtelTigo). |
| `ClientState` | String | The `ClientState` you returned in your last response. It's sent once, then discarded. |
| `Mobile` | String | Customer's phone number. |
| `SessionId` | String | Identifier for the current session. |
| `Sequence` | Integer | Position of this message in the session. |
| `Platform` | String | `USSD`, `Webstore` or `Hubtel-App`. |
```json
{
"Type": "Initiation",
"Mobile": "233249111411",
"SessionId": "example-session",
"ServiceCode": "713",
"Message": "*713#",
"Operator": "vodafone",
"Sequence": 1,
"ClientState": "",
"Platform": "USSD"
}
```
## Return a response [#return-a-response]
| Field | Required | Meaning |
| ------------- | --------------- | --------------------------------------------------------------------------------------------------------------------- |
| `SessionId` | Yes | Return the session identifier from the request. |
| `Type` | Yes | `response` continues the session; `release` ends it; `AddToCart` ends the interaction and sends the item to checkout. |
| `Message` | Yes | USSD display text. Use `\n` for new lines and write menu choices in the text. |
| `Mask` | No | Marks the current message as masked. |
| `Item` | For `AddToCart` | Purchase object; leave empty for other response types. |
| `ServiceCode` | No | Return the service code where needed. |
| `Label` | Yes | Title shown on app and web channels. |
| `DataType` | Yes | `display` for information or `input` for customer input. |
| `FieldType` | Yes | The input control: `text`, `phone`, `email`, `number` (whole numbers), `decimal` or `textarea`. |
| `Sequence` | No | Message position. |
| `ClientState` | No | State to return with the next request. |
## Example session [#example-session]
Return a menu for the initiation request:
```json
{
"SessionId": "example-session",
"Type": "response",
"Message": "Choose a service\n1. Buy airtime\n2. Check balance",
"Label": "Choose a service",
"ClientState": "menu",
"DataType": "input",
"FieldType": "text"
}
```
When the customer selects `1`, the next request has `Type: "Response"`, `Message: "1"`, `Sequence: 2` and `ClientState: "menu"`. Return a numeric input screen:
```json
{
"SessionId": "example-session",
"Type": "response",
"Message": "Enter the airtime amount",
"Label": "Airtime amount",
"ClientState": "amount",
"DataType": "input",
"FieldType": "decimal"
}
```
Use `ClientState` to know which question the customer is answering. Validate input such as the amount before you build an item.
## Start payment with AddToCart [#start-payment-with-addtocart]
```json
{
"SessionId": "example-session",
"Type": "AddToCart",
"Message": "Your request has been submitted. Follow the payment prompt to continue.",
"Item": { "ItemName": "Airtime", "Qty": 1, "Price": 5.0 },
"Label": "Complete payment",
"DataType": "display",
"FieldType": "text"
}
```
`AddToCart` ends the session and starts payment. It isn't proof of payment: wait for the paid order at your Service Fulfilment URL. See [Service fulfilment](/docs/guides/service-fulfilment).
## End a session and handle invalid responses [#end-a-session-and-handle-invalid-responses]
Return `Type: "release"` with the required fields to end a session without payment. A `Timeout` request means the customer left: don't create a purchase.
Don't use special characters such as `É` in `Message`. If customers see **"The response from the provider of this service is invalid. Error: UUE"**, your response body isn't in the expected format: check the required fields.
# SMS delivery and errors (/docs/guides/sms-delivery)
> A successful send only means Hubtel accepted the message. Check its status with the message ID to find out whether it reached the phone.
**Before you start**
- **Business SMS Client ID and Client Secret**: A sender ID is the name your customers see as the sender of your SMS, such as your business name. Hubtel approves each sender ID, and you create a Client ID and Client Secret for each approved one. [SMS API keys](/dashboard/api-keys#sms)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Save the `messageId` (and `batchId`, when returned) from each send. Check delivery with the same credentials you sent with:
| Lookup | Endpoint | Reference |
| ------- | -------------------------------------------------------- | -------------------------------------------------- |
| Message | `GET https://sms.hubtel.com/v1/messages/{messageId}` | [Message status](/docs/api/v1/sms/get-message) |
| Batch | `GET https://sms.hubtel.com/v1/messages/batch/{batchId}` | [Batch status](/docs/api/v1/sms/get-message-batch) |
```bash
curl https://sms.hubtel.com/v1/messages/03109b26-5be1-444d-8189-9f6fa2b4550a \
-u "$HUBTEL_SMS_CLIENT_ID:$HUBTEL_SMS_CLIENT_SECRET"
```
```json
{ "rate": 0.0309, "batchId": null, "messageId": "03109b26-5be1-444d-8189-9f6fa2b4550a", "content": "Your order is ready for pickup.", "status": "Delivered", "updateTime": "2023-05-30T16:43:15", "time": "2023-05-30T16:43:13.7208383Z", "to": "233249111411", "from": "KofiBooks" }
```
A batch result has the `batchId` and a `data` array of message results.
## Delivery states [#delivery-states]
Statuses come from the network operator's delivery receipts.
| State | Meaning |
| --------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- |
| `Delivered` | The operator reports delivery to the recipient's phone. |
| `Sent` | Forwarded to the operator; final delivery is still pending. Check again later. |
| `Pending` | Queued at Hubtel before forwarding to the operator. |
| `Blacklisted` | The operator has blocked bulk messages for the recipient, including opt-out cases. |
| `Undeliverable` / `Failed`, `Unrouteable` / `Error`, `Rejected` | Delivery failed, for example because the phone was off or out of coverage. The exact status depends on the operator. |
| `NACK` / `0x0000000b` / `Invalid Destination Address` | Check the recipient number and formatting. |
| `NACK` / `0x0000000a` / `Invalid Source Address` | Check the sender, including the 11-character limit. |
## HTTP and SMS response codes [#http-and-sms-response-codes]
A 2xx response can still carry a nonzero SMS status, so check both.
| HTTP | SMS status | Meaning |
| ---------- | ---------- | --------------------------------------------------------------------- |
| 200 or 201 | 0 | Accepted for onward delivery; this does not confirm handset delivery. |
| 201 | 100 | Missing data or malformed request. |
| 201 | 1 | Invalid destination address. |
| 201 | 2 | Invalid source address. |
| 400 | 3 | Message body too long. |
| 400 | 4 | Message cannot be routed. |
| 400 | 5 | Invalid delivery time. |
| — | 6 | Rejected or invalid content. |
| — | 7 | A parameter is not allowed; inspect the response details. |
| — | 8 | An invalid parameter was supplied; inspect the response details. |
| — | 12 | Fund the messaging account. |
| 401 | — | Authentication failed. |
| 402 | — | Insufficient messaging credit. |
| 403 | — | Recipient has not approved receipt of the message. |
| 404 | — | Message not found. |
| 500 | — | Server error. |
| 502 | — | No suitable gateway was found. |
# SMS (/docs/guides/sms)
> To send an SMS, POST the message with your SMS credentials. You can send single, batch and personalised messages, and connect over SMPP for high volumes.
**Before you start**
- **Business SMS Client ID and Client Secret**: A sender ID is the name your customers see as the sender of your SMS, such as your business name. Hubtel approves each sender ID, and you create a Client ID and Client Secret for each approved one. [SMS API keys](/dashboard/api-keys#sms)
- **An approved sender ID**: The name your customers see on your messages. Hubtel approves each one before you can use it. [Sender IDs](/docs/get-started/go-live#approve-a-sender-id)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
| Connection | Host | Credentials | Sends |
| --------------------- | ------------------------ | -------------------------------- | ---------------------------------------------- |
| [HTTP API](#send-sms) | `https://sms.hubtel.com` | SMS Client ID and Client Secret | Single, batch and personalised messages |
| [SMPP](#smpp) | `smpp.hubtel.com:2775` | SMPP Client ID and Client Secret | High-throughput messages and delivery receipts |
Every message needs an approved sender ID of at most 11 alphanumeric characters. Send numbers in international format, for example `233249111411`. Keep content under 160 characters where you can.
## Send an SMS [#send-sms]
Authenticate with your SMS Client ID and Client Secret from [Develop → API keys → SMS](/dashboard/api-keys#sms).
**One message**
```bash
curl https://sms.hubtel.com/v1/messages/send \
-u "$HUBTEL_SMS_CLIENT_ID:$HUBTEL_SMS_CLIENT_SECRET" -H "Content-Type: application/json" \
-d '{"From":"KofiBooks","To":"233249111411","Content":"Your order is ready for pickup."}'
```
```json
{ "rate": 0.03, "messageId": "03109b26-5be1-444d-8189-9f6fa2b4550a", "status": 0, "networkId": "62001", "clientReference": null, "statusDescription": "request submitted successfully" }
```
**Same message to many**
```bash
curl https://sms.hubtel.com/v1/messages/batch/simple/send \
-u "$HUBTEL_SMS_CLIENT_ID:$HUBTEL_SMS_CLIENT_SECRET" -H "Content-Type: application/json" \
-d '{"From":"KofiBooks","Recipients":["233249111411","233501431586"],"Content":"We open at 9am tomorrow."}'
```
The response has a `batchId` and a `data` array with each recipient's `messageId`.
**Personalised**
```bash
curl https://sms.hubtel.com/v1/messages/batch/personalized/send \
-u "$HUBTEL_SMS_CLIENT_ID:$HUBTEL_SMS_CLIENT_SECRET" -H "Content-Type: application/json" \
-d '{"From":"KofiBooks","personalizedRecipients":[{"To":"233249111411","Content":"Hi Ama, your book has arrived."}]}'
```
`status` `0` means Hubtel accepted the message. It doesn't mean the phone received it: [check delivery](/docs/guides/sms-delivery) with the `messageId` or `batchId`. Fields are PascalCase (`From`, `To`, `Content`), except `personalizedRecipients`.
Top up your SMS balance in your Hubtel merchant account. A send without enough credit fails with HTTP `402`; see [SMS response codes](/docs/guides/sms-delivery#http-and-sms-response-codes).
## SMPP [#smpp]
For high-throughput sending, connect to Hubtel's SMPP server:
| Setting | Value |
| ----------- | ------------------------------------------------------------------ |
| Host | `smpp.hubtel.com` |
| Port | `2775` |
| Credentials | SMPP Client ID and Client Secret from your Retail Systems Engineer |
Supported operations: Bind Transmitter (`TX`) to send, Bind Receiver (`RX`) for delivery receipts, Bind Transceiver (`TRX`) for both, `Submit_SM`, `Deliver_SM` and `Unbind`. The protocol is [SMPP 3.4](https://smpp.org/SMPP_v3_4_Issue1_2.pdf).
## Reference [#reference]
| Operation | Reference |
| ----------------------------------------------- | ------------------------------------------------------------ |
| Send with POST | [Send a message](/docs/api/v1/sms/send-sms) |
| Send with GET (credentials in the query string) | [Quick send](/docs/api/v1/sms/send-sms-quick) |
| Same content to many | [Simple batch](/docs/api/v1/sms/send-sms-batch) |
| Different content per recipient | [Personalised batch](/docs/api/v1/sms/send-sms-personalized) |
| Check a message | [Message status](/docs/api/v1/sms/get-message) |
| Check a batch | [Batch status](/docs/api/v1/sms/get-message-batch) |
Prefer the **Send with POST** endpoints over Quick send, so credentials don't appear in logged URLs.
# Programmable Services (/docs/guides/ussd)
> To sell your service on USSD, the Hubtel App and Webstore, give Hubtel two URLs: one that answers each step of the customer's session, and one that receives the paid order.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Programmable Services puts a service you host in front of customers on USSD, the Hubtel App (Android and iOS) and the Hubtel Webstore. Hubtel runs the session and takes payment; your application decides what the customer sees and delivers what they paid for.
Your application exposes two URLs:
| URL | Hubtel sends | You return |
| --------------------------- | ----------------------------------- | ------------------------------------------------------------------------------------------------- |
| **Service Interaction URL** | Each step of the customer's session | The next screen, or the item to pay for. See [Interactions](/docs/guides/service-interactions). |
| **Service Fulfilment URL** | The paid order | Deliver the service, then report it to Hubtel. See [Fulfilment](/docs/guides/service-fulfilment). |
## How it works [#how-it-works]
1. A customer dials your USSD code or opens your service in the Hubtel App or Webstore.
2. Hubtel sends each step to your Service Interaction URL, and shows the response you return.
3. When the customer is ready to pay, you return `AddToCart` with the item. Hubtel takes the payment.
4. Hubtel sends the paid order to your Service Fulfilment URL.
5. You deliver the service, then send a fulfilment callback to Hubtel **within one hour**.
6. If you have no final payment result after 5 minutes, you [check the transaction status](/docs/guides/service-fulfilment#status).
## Register your service [#register]
Add the service under **Manage Services** in your Hubtel account:
| Field | What to enter |
| ------------------------------------------- | ------------------------------------- |
| Service name, branch, category, description | How the service appears to customers. |
| Service interaction URL | Your endpoint for session requests. |
| Service callback URL | Your **Service Fulfilment URL**. |
Choose at least one selling option, **Sell in store** or **Sell online**. Online selling needs a photo. You can also publish the service to Hubtel POS as a commission service, with a fixed or percentage commission.
Then request a USSD code and attach the service to it on the Merchant Dashboard.
## Allowlist your server IP [#network-access]
Send your server's public IP address to your Retail Systems Engineer. Hubtel's fulfilment callback endpoint accepts requests only from allowlisted addresses.
To accept fulfilment requests only from Hubtel, allow `52.50.116.54`, `18.202.122.131` and `52.31.15.68`.
## Platforms [#channels]
The `Platform` field in each request is `USSD`, `Hubtel-App` or `Webstore`. USSD shows `Message`; the App and Webstore also use `Label`, `DataType` and `FieldType` to show richer screens. Betting services on the Hubtel App and Webstore must handle all three platforms.
# Verify customers (/docs/guides/verification)
> Before you pay someone or charge a new customer, look up the name on their wallet or bank account, or validate their Ghana Card or Voter ID number.
**Before you start**
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API ID and API key**: They identify you on every request. Send them using HTTP Basic authentication. [Payment keys](/dashboard/api-keys)
- **Collection account number**: This is where your customers' payments arrive. You'll add it to the request URL. [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
Compare the returned account details with the customer information you hold. A name lookup does not prove that a person controls a phone; follow the [Receive Money requirements](/docs/guides/receive-money#before-you-start) before sending a payment prompt.
| Check | Use it before |
| ------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------- |
| [Wallet registered name](/docs/api/v1/verification/verify-mobile-money-wallet) | Paying out to a wallet, or charging a new customer |
| [Bank account name](/docs/api/v1/verification/verify-bank-account) | Paying out to a bank |
| [Ghana Card](/docs/api/v1/verification/verify-ghana-card) and [Voter ID](/docs/api/v1/verification/verify-voter-id) | Onboarding customers for regulated products |
```bash
curl "https://rnv.hubtel.com/v2/merchantaccount/merchants/$HUBTEL_COLLECTION_ACCOUNT/mobilemoney/verify?channel=mtn-gh&customerMsisdn=233249111411" \
-u "$HUBTEL_API_ID:$HUBTEL_API_KEY"
```
```json
{ "message": "Success", "responseCode": "0000", "data": { "isRegistered": true, "name": "JOHN DOE", "status": "active", "profile": "Subscriber" } }
```
For the wallet example, check `responseCode` and `data.isRegistered` before using `data.name`. If the request fails or the wallet is not registered, resolve that result before paying out.
Names may differ in capitalisation or word order, such as "Kofi Mensah" and "MENSAH KOFI". Account for these differences in your verification process.
# Hubtel developer documentation (/docs)
Integrate Hubtel payments, payouts, messaging and verification into your product.
## 1. Get your credentials
What you need from Hubtel before your first request.
- **A Hubtel business with a merchant account**: Business APIs work through your business's merchant account. If you don't have one yet, sign up and set it up first. [Create one at business.hubtel.com](https://business.hubtel.com)
- **API keys and account numbers**: Your API ID and API key identify you on every request. Your Collection account receives customer payments, and your Disbursement account funds payouts. [Payment keys](/dashboard/api-keys) · [Account IDs](/dashboard/account-ids)
- **An allowlisted server IP address**: Send your server's public IP address to Hubtel to get it allowlisted. Until then, your requests return 403 Forbidden or time out. [IP allowlisting](/docs/networking)
- **Business SMS Client ID and Client Secret**: A sender ID is the name your customers see as the sender of your SMS, such as your business name. Hubtel approves each sender ID, and you create a Client ID and Client Secret for each approved one. [SMS API keys](/dashboard/api-keys#sms)
Don't have these yet? [Start in the sandbox](/dashboard/keys) with your test keys while you set them up.
## 2. Learn how requests work
Find the authentication, request conventions and callback format for your API.
* [Authentication and accounts](/docs/get-started/keys): your credentials, account numbers and each API's base URL.
* [Requests and responses](/docs/conventions): client references, amounts, channels and asynchronous results.
* [Webhooks and callbacks](/docs/webhooks): receive final results and handle missing callbacks.
## 3. Choose the API for what you're building
Accept payments, send money, verify customers or send SMS. Each API has a step-by-step guide.
See [all APIs](/docs/api) for each API's guide and reference.
## 4. Use the developer tools
Checkout SDKs, AI agent tools and the API reference for your integration.
- [SDKs](/docs/guides/checkout-sdk)
- [Build with AI](/docs/ai)
- [API reference](/docs/api)
## 5. Connect your AI agent
Let Claude Code, Cursor or VS Code read these docs and the API schemas for you.
Copy this prompt into your AI coding agent. It installs the Hubtel skill; see [Build with AI](/docs/ai) for the MCP server:
```text
Fetch https://developers.hubtel.com/skills/hubtel-integrate/SKILL.md and save it where this tool loads skills or rules (for example .claude/skills/hubtel-integrate/SKILL.md or .cursor/rules/hubtel-integrate.mdc). Follow it for any Hubtel work in this project.
```
## 6. Go live and get help
The steps before your first live request, and where to look when one fails.
* [Go live](/docs/get-started/go-live): IP allowlisting, sender IDs and the other steps before your first live request.
* [Errors](/docs/errors): start here if a request fails.
* [IP allowlisting](/docs/networking): fix allowlisting problems.
# IP allowlisting and networking (/docs/networking)
> Many Hubtel APIs accept requests only from server IP addresses you've allowlisted. Send your servers' public IPv4 addresses to your Retail Systems Engineer.
Services marked "IP allowlist" in the [API reference](/docs/api) accept requests only from server IP addresses Hubtel has allowlisted (also called whitelisting). That includes payments, payouts, status checks, refunds, balances, verification, commission services and the service fulfilment callback.
## Production allowlisting [#production]
| Rule | Detail |
| --------------- | ----------------------------------------------------------------------- |
| How to request | Send your servers' public IP addresses to your Retail Systems Engineer. |
| Address type | IPv4 only. Hubtel doesn't allowlist domain names. |
| Limit | Up to **4** IP addresses per service. |
| Not allowlisted | Requests get `403 Forbidden`, or time out. |
If you still get `403` after your IP was added, your requests are probably leaving from a different address, or your server's IP isn't static. Run `curl -4 https://ifconfig.me` on the server itself to see the address Hubtel receives.
## Get a static outbound IP address [#get-a-static-outbound-ip-address]
Serverless platforms and many PaaS hosts send requests from changing addresses. To use an allowlist, you need a fixed outbound address:
Configure your host to route Hubtel requests through a static outbound IPv4 address, for example through a NAT gateway or an outbound proxy. Ask your hosting provider which option is supported for your plan and runtime. Check the address from the same runtime that makes the API request before submitting it to Hubtel.
Add every environment that calls Hubtel (production and any staging that uses live credentials), within the limit of 4 addresses per service.
# Change logs (/docs/others/change-logs)
##### October 2026 [#october-2026]
###### Date: 12-10-2026 [#date-12-10-2026]
###### Update: [#update]
Minor updates.
***
##### September 2026 [#september-2026]
###### Date: 01-09-2026 [#date-01-09-2026]
###### Update: [#update-1]
Minor updates.
***
##### August 2026 [#august-2026]
###### Date: 05-08-2026 [#date-05-08-2026]
###### Update: [#update-2]
Minor updates.
***
##### July 2026 [#july-2026]
###### Date: 16-07-2026 [#date-16-07-2026]
###### Update: [#update-3]
Minor updates.
***
##### June 2026 [#june-2026]
###### Date: 01-06-2026 [#date-01-06-2026]
###### Update: [#update-4]
Invoicing API updated.
***
##### April 2026 [#april-2026]
###### Date: 30-04-2026 [#date-30-04-2026]
###### Update: [#update-5]
Account names updated.
***
##### February 2026 [#february-2026]
###### Date: 18-02-2026 [#date-18-02-2026]
###### Page: Lending APIs [#page-lending-apis]
###### Update: [#update-6]
Lending APIs collection updated.
***
##### January 2026 [#january-2026]
###### Date: 21-01-2026 [#date-21-01-2026]
###### Update: [#update-7]
Minor updates.
***
##### December 2025 [#december-2025]
###### Date: 19-12-2025 [#date-19-12-2025]
###### Page: Lending APIs [#page-lending-apis-1]
###### Update: [#update-8]
Face Verification and Consumer Credit Score Check API updated.
###### Date: 17-12-2025 [#date-17-12-2025]
###### Page: Lending APIs [#page-lending-apis-2]
###### Update: [#update-9]
Face Verification API updated.
###### Date: 08-12-2025 [#date-08-12-2025]
###### Page: Lending APIs, Commission Services [#page-lending-apis-commission-services]
###### Update: [#update-10]
Lending APIs collection added. MTN Fibre Broadband removed.
***
##### November 2025 [#november-2025]
###### Date: 19-11-2025 [#date-19-11-2025]
###### Page: Checkout SDK [#page-checkout-sdk]
###### Update: [#update-11]
Android SDK version updated.
***
##### August 2025 [#august-2025]
###### Date: 19-08-2025 [#date-19-08-2025]
###### Page: Verification [#page-verification]
###### Update: [#update-12]
Voter ID validation updated.
###### Date: 12-08-2025 [#date-12-08-2025]
###### Page: Verification [#page-verification-1]
###### Update: [#update-13]
Ghana ID validation updated.
***
##### July 2025 [#july-2025]
###### Date: 21-07-2025 [#date-21-07-2025]
###### Page: Online Checkout, Checkout SDK, Receive Money, Send Money, Send To Bank, Direct Debit, Verification, Refund [#page-online-checkout-checkout-sdk-receive-money-send-money-send-to-bank-direct-debit-verification-refund]
###### Update: [#update-14]
Response codes updated.
***
##### June 2025 [#june-2025]
###### Date: 26-06-2025 [#date-26-06-2025]
###### Page: Checkout SDK [#page-checkout-sdk-1]
###### Update: [#update-15]
Transaction Status Check endpoint added.
***
##### April 2025 [#april-2025]
###### Date: 17-04-2025 [#date-17-04-2025]
###### Page: Direct Debit [#page-direct-debit]
###### Update: [#update-16]
Minor updates to Cancel preapproval response.
###### Date: 14-04-2025 [#date-14-04-2025]
###### Page: Invoicing [#page-invoicing]
###### Update: [#update-17]
Invoicing API added.
***
##### February 2025 [#february-2025]
###### Date: 17-02-2025 [#date-17-02-2025]
###### Page: Commission Services [#page-commission-services]
###### Update: [#update-18]
MTN Fibre Broadband added.
***
##### November 2024 [#november-2024]
###### Date: 21-11-2024 [#date-21-11-2024]
###### Page: Programmable Services [#page-programmable-services]
###### Update: [#update-19]
Minor updates.
***
##### October 2024 [#october-2024]
###### Date: 25-10-2024 [#date-25-10-2024]
###### Page: Checkout SDK [#page-checkout-sdk-2]
###### Update: [#update-20]
Android SDK version updated.
***
##### September 2024 [#september-2024]
###### Date: 27-09-2024 [#date-27-09-2024]
###### Page: Checkout SDK [#page-checkout-sdk-3]
###### Update: [#update-21]
Android SDK version updated.
###### Date: 06-09-2024 [#date-06-09-2024]
###### Page: Verification [#page-verification-2]
###### Update: [#update-22]
Minor updates.
***
##### August 2024 [#august-2024]
###### Date: 21-08-2024 [#date-21-08-2024]
###### Page: Commission Services [#page-commission-services-1]
###### Update: [#update-23]
Minor updates.
###### Date: 20-08-2024 [#date-20-08-2024]
###### Page: Checkout SDK [#page-checkout-sdk-4]
###### Update: [#update-24]
JavaScript SDK updated.
###### Date: 16-08-2024 [#date-16-08-2024]
###### Page: Checkout SDK [#page-checkout-sdk-5]
###### Update: [#update-25]
JavaScript SDK added.
###### Date: 07-08-2024 [#date-07-08-2024]
###### Page: Transaction Status Check [#page-transaction-status-check]
###### Update: [#update-26]
Refunded status added.
###### Date: 02-08-2024 [#date-02-08-2024]
###### Page: Checkout SDK [#page-checkout-sdk-6]
###### Update: [#update-27]
Android SDK version updated.
###### Date: 01-08-2024 [#date-01-08-2024]
###### Page: Checkout SDK [#page-checkout-sdk-7]
###### Update: [#update-28]
Added CheckoutStatus cases for Android SDK.
***
##### July 2024 [#july-2024]
###### Date: 17-07-2024 [#date-17-07-2024]
###### Page: Recurring Invoice [#page-recurring-invoice]
###### Update: [#update-29]
New Retry (Onetime) and New Retry (Custom) for Recurring Billing have been discontinued.
###### Date: 17-07-2024 [#date-17-07-2024-1]
###### Page: SMS [#page-sms]
###### Update: [#update-30]
Documentation for the SMS SMPP route has been added.
***
# Others (/docs/others)
Additional reference material for Hubtel business APIs.
# Test your integration (/docs/testing)
> Use the sandbox to test requests, customer responses and callbacks without moving money or sending messages to real phones. It simulates the documented APIs; some operations return example data rather than processing a complete workflow.
## Sandbox keys [#keys]
Your sandbox API ID and key are in **Workbench → Test keys**. Send them with HTTP Basic authentication, exactly as you would your production credentials. In the sandbox, the same key also authenticates SMS requests.
To call the sandbox, put `https://developers.hubtel.com/sandbox/v1/` and the first part of the production host in front of the production path:
| Production | Sandbox |
| ------------------------------------------------- | ----------------------------------------------------------------------- |
| `https://rmp.hubtel.com/merchantaccount/…` | `https://developers.hubtel.com/sandbox/v1/rmp/merchantaccount/…` |
| `https://api-txnstatus.hubtel.com/transactions/…` | `https://developers.hubtel.com/sandbox/v1/api-txnstatus/transactions/…` |
```bash
curl https://developers.hubtel.com/sandbox/v1/rmp/merchantaccount/merchants/YOUR_COLLECTION_ACCOUNT/receive/mobilemoney \
-u "YOUR_API_ID:YOUR_TEST_KEY" \
-H "Content-Type: application/json" \
-d '{"CustomerMsisdn":"233240000001","Channel":"mtn-gh","Amount":45.00,"Description":"Order #1042","ClientReference":"order-1042","PrimaryCallbackUrl":"https://example.com/hubtel/callback"}'
```
Your API ID, test key and collection account number are in **Workbench → API keys**.
## Test numbers [#test-numbers]
For supported simulations, use these numbers to select an outcome. Check the operation’s sandbox metadata in the [OpenAPI spec](/docs/tools/openapi) before relying on a simulated result:
| Customer number | What happens | Final state |
|---|---|---|
| `233240000001` | **Approved.** Customer approves the prompt. One callback arrives about 3 seconds later. | success |
| `233240000002` | **Insufficient funds.** The wallet balance is too low. The callback reports a failure. | failed |
| `233240000003` | **Declined.** Customer declines the prompt on their phone. | failed |
| `233240000004` | **No response.** The customer does not respond. The prompt expires after 5 minutes of sandbox time. | expired |
| `233240000005` | **Callback lost.** The payment succeeds but no callback is delivered. Reconcile with the Status Check API. | success |
| `233240000006` | **Duplicate callback.** Sandbox drill: the same successful callback is delivered twice. Production sends one final callback per payment, but your handler must still fulfil the order once. | success |
| `233240000007` | **Out of order.** Sandbox drill: a pending callback arrives after the success callback. Production only sends final results, but keep the order marked as paid either way. | success |
| `233240000008` | **Not a wallet.** The number is not registered for mobile money. Rejected immediately with a validation error. | failed |
| Any other number | **You decide.** Any other number shows the prompt on the Virtual Phone. Approve or decline it yourself. | You decide |
For any other valid number, approve or decline the prompt yourself on the Workbench **Virtual Phone**.
**Cards**
| Card number | Result |
|---|---|
| `4000 0000 0000 0002` | Visa, approved. |
| `4000 0000 0000 0010` | Visa, declined by issuer. |
| `5200 0000 0000 0007` | Mastercard, asks for 3-D Secure (use code 123456). |
**Payouts**
| Recipient | Type | What happens |
|---|---|---|
| `233240000101` | Wallet | **Paid out.** The payout succeeds and a callback confirms the result. |
| `233240000102` | Wallet | **Wrong recipient.** Recipient wallet does not exist. |
| `233240000103` | Wallet | **Insufficient disbursement balance.** The payout is accepted, then fails with a 4075 callback because your disbursement balance can't cover the amount and fees. |
| `233240000105` | Wallet | **Callback lost.** The payout succeeds, but no callback is delivered. Check the payout status to reconcile it. |
| `0000000001` | Bank account | **Bank credited.** Bank transfer succeeds after 10 seconds. |
| `0000000002` | Bank account | **Name mismatch.** Account exists but the name does not match. |
**SMS**
| Recipient | Delivery status |
|---|---|
| `233240000201` | delivered. Delivered to handset. |
| `233240000202` | undelivered. The phone is switched off and the network could not deliver the message. |
| `233240000203` | rejected. Network rejected the sender ID. |
| `233240000204` | expired. Message expired before delivery. |
| Any other number | delivered |
**Wallet verification**
| Wallet | Result |
|---|---|
| `233240000301` | Name on wallet matches. Name: Kofi Mensah. |
| `233240000302` | Wallet exists under a different name. Name: Ama Owusu. |
| `233240000303` | Number is not a registered wallet. |
## Online Checkout in the sandbox [#online-checkout]
A sandbox `checkoutUrl` opens the portal’s simulated checkout page. Use it to test the payment flow; it is not the production payment service.
### Create a checkout [#create-a-checkout]
Send the request with your test key, or create the checkout from your own server:
```bash
curl https://developers.hubtel.com/sandbox/v1/payproxyapi/items/initiate \
-u "YOUR_API_ID:YOUR_TEST_KEY" \
-H "Content-Type: application/json" \
-d '{"totalAmount":45.00,"description":"Order #1042","callbackUrl":"https://example.com/hubtel/callback","returnUrl":"https://example.com/orders/1042","cancellationUrl":"https://example.com/cart","merchantAccountNumber":"YOUR_COLLECTION_ACCOUNT","clientReference":"order-'"$(date +%s)"'"}'
```
Your API ID, test key and collection account number are in **Workbench → API keys**.
### Pay on the page [#pay-on-the-page]
Open the `checkoutUrl` from the response and pay:
* **Mobile Money:** use a [test number](#test-numbers). For any other number, approve or decline the prompt on the Workbench **Virtual Phone**.
* **Card:** use a test card from the **Cards** tab above. The 3-D Secure card opens a sandbox issuer page; enter `123456` to pass, or any other code to fail.
Wallet, GHQR, PaySmallSmall and Bank Pay appear on the page but aren't available in the sandbox.
### Handle the result [#handle-the-result]
Your `callbackUrl` receives the documented callback shape, with `PaymentDetails.PaymentType` set to `mobilemoney` or `card`. When the customer finishes, the page sends them to your `returnUrl` with `checkoutid` added to the query string. Confirm the payment from the callback or a status check before you fulfil the order, as in production.
To embed the page, load the `checkoutDirectUrl` in an iframe. The mobile and JavaScript [Checkout SDKs](/docs/guides/checkout-sdk) always run against production, so test them with production keys and small amounts.
## Simulate errors and time [#errors]
Add a `Hubtel-Simulate` header to a sandbox request to test how your client handles failures: `timeout`, `500`, `503`, `rate_limit` (the simulated per-number limit) or `slow:4000`.
The sandbox implements these behaviours:
* A reused `ClientReference` is rejected for an hour of sandbox time with `Duplicate Client Reference`.
* A customer number gets at most 4 payment requests a minute. Advance the clock to reset the limit.
* Callbacks are retried 30 seconds and then 60 seconds after a failed attempt, 3 attempts in all, each allowed 30 seconds.
* A payout your disbursement balance can't cover is accepted, then fails with a `4075` callback. Payout callbacks are sent once, without retries.
* A reused payout `ClientReference` is rejected for 48 hours, and an Online Checkout `clientReference` for 7 days, across every merchant. The example above adds the time to its reference so you can run it again.
* Where production's answer gives no reason, the sandbox explains in a `Hubtel-Sandbox-Note` response header.
The hosted sandbox only sends callbacks to public addresses. To receive them on your own machine, expose your local server with a tunnel and use its public URL as the callback URL:
```bash
cloudflared tunnel --url http://localhost:3000
# or
ngrok http 3000
```
To test the 5-minute reconciliation window without waiting, ask your AI agent to move the sandbox clock forward with the MCP `advance_sandbox_clock` tool (300 seconds).
## Integration checks [#integration-checks]
Run the checks from **Workbench → Webhooks → Integration checks**, or use `run_certification` through the [Hubtel MCP server](/docs/ai).
Use a public test deployment of your handler with test data and real-world delivery disabled. The checks send synthetic callbacks, including references that are not real orders. Keep your production sender checks in place; sandbox requests come from the sandbox, not the production callback addresses.
The checks cover:
* Acknowledgement of a success callback, a duplicate and a late pending notification.
* Sandbox activity showing a failed payment and a status lookup for a payment with a lost callback (`233240000005`). These observations do not prove that your application updated its own records correctly.
* An optional lookup of your fulfilment record after the repeated callbacks.
To enable the fulfilment lookup, add this route on the same host as your test callback URL. Return the actual stored result for the requested reference, not a hardcoded response:
```text
GET /hubtel/certification/orders/:reference
```
```json
{ "fulfilments": 1, "status": "paid" }
```
Without this route, the exactly-once check reports **not checked**. A passing report is sandbox evidence, not production approval. Also verify your own order records for success, failure, duplicate delivery and a lost callback.
Normal sandbox deliveries include a `Hubtel-Signature` header; integration-check callbacks do not.
# OpenAPI specs (/docs/tools/openapi)
Each v1 service has its own OpenAPI 3.1 file. These point at production hosts, so for sandbox paths use the combined `sandbox-v1.json`.
| File | Contents |
| ------------------------------------------------------ | ---------------------------------------------------------------------------------------------------- |
| [`/openapi/v1/index.json`](/openapi/v1/index.json) | A list of all v1 services |
| `/openapi/v1/
.json` | The OpenAPI document for one service, such as [`receive-money.json`](/openapi/v1/receive-money.json) |
| [`/openapi/sandbox-v1.json`](/openapi/sandbox-v1.json) | Every v1 operation in one document, with sandbox paths |
Each v1 operation also carries `x-hubtel` metadata with:
* Its production host.
* Whether it has been reviewed (`curated`) or imported from legacy docs (`draft`).
* Whether the sandbox simulates it fully.
* Whether production needs an allowlisted server IP.
To download one service's spec:
```bash
curl -fsSO https://developers.hubtel.com/openapi/v1/receive-money.json
```
# Use Postman and other API clients (/docs/tools/postman)
## Set up Postman [#set-up-postman]
1. Import the [Hubtel v1 collection](/openapi/postman/hubtel-v1.json) and the [Hubtel Sandbox environment](/openapi/postman/sandbox.environment.json).
2. Select **Hubtel Sandbox** as the active environment.
3. In **Workbench → Test keys**, copy your sandbox API ID, API key and collection account number into `api_id`, `api_key` and `collection_account`. `sandbox_url` is already set.
4. Open a request and swap the example values for your own: customer details, references, callback URL and any path parameters still left as placeholders. Use a [test number](/docs/testing#test-numbers) to control the result.
The collection puts `collection_account` into account-number paths for you, with two exceptions. Payouts and commission services need your **disbursement** account number, so replace it in those requests. Checkout also needs `merchantAccountNumber` in the JSON body. The collection won't fill in either of these.
Start with **Charge a mobile money wallet**. A response with `ResponseCode` `0001` only means Hubtel accepted the request. The payment may still be pending, so check the final result in your callback handler, or call **Check a collection's status** with the same reference. [Test your integration](/docs/testing) covers callback setup and the test outcomes.
Your environment file contains your sandbox keys, so don't share it.
## Use another client [#use-another-client]
Any client that imports OpenAPI, such as Bruno or Insomnia, can use the service's [OpenAPI spec](/docs/tools/openapi). Check the server URL before you send a request. The service specs point at production hosts, and only `sandbox-v1.json` uses sandbox paths. If you'd rather use the command line, copy the cURL example from the service guide and convert the URL using the [sandbox URL mapping](/docs/testing#keys).
# Webhooks and callbacks (/docs/webhooks)
> Hubtel sends the final result of every payment, payout and refund to your callback URL. Respond quickly, fulfil each order once, and check the status when a callback doesn't arrive.
Hubtel reports the final result of an asynchronous request, such as a payment, payout or refund, with a POST to the callback URL you set in that request. Each product's payload is in the [callback reference](/docs/callbacks).
## Handle a callback [#handle]
Implement these steps in your callback handler and background worker:
1. Validate the sender as described below, parse the product's payload, and match its reference or order ID to your stored request. Don't create a paid order for an unknown reference.
2. Save the callback durably, then return HTTP `200`. Run status verification, emails and delivery in a background worker.
3. Confirm the payment's status and amount against the stored order before fulfilment. Use the product's documented success fields; don't treat every unrecognised code as a failure.
4. Make the order update and fulfilment scheduling atomic. Store a unique payment or transaction identifier so repeated callbacks cannot deliver twice. For recurring invoices, identify each instalment separately.
5. Keep final results when a stale pending notification arrives. Record unexpected or conflicting results for investigation.
## Secure your endpoint [#secure]
The published v1 contract does not define a callback signature you can verify. Protect the endpoint as follows:
1. **Allow the documented Hubtel callback addresses** at your firewall or trusted ingress. The [callback reference](/docs/callbacks) lists them by product. Where no address is published, confirm it with your Retail Systems Engineer before launch.
2. **Confirm before you deliver anything valuable.** [Check the transaction status](/docs/guides/reconciliation) with the `ClientReference` and act on that result.
## When a callback doesn't arrive [#missing]
The payment guides describe callbacks arriving within 30 seconds, but delivery is not guaranteed. If you have no final result after **5 minutes**, check the status. Implementing the status check is mandatory for every payment product. [Reconciliation and status checks](/docs/guides/reconciliation) describes the reconciliation workflow.
The sandbox adds a `Hubtel-Signature` header to its callbacks so you can test signature handling. Don't rely on it in production.
# Start a direct debit pre-approval (/docs/api/v1/direct-debit/initiate-preapproval)
Asks a customer to approve future debits from their wallet by USSD. The response is pending (`2000`); the final result is POSTed to `callbackUrl` after the customer responds on the Virtual Phone or the request expires. Use the same test numbers as Receive Money. After approval you can charge them with Receive Money using a direct-debit channel.
`POST https://preapproval.hubtel.com/api/v2/merchant/{accountNumber}/preapproval/initiate`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"clientReferenceId": "3jL2KlUy3vt21debitC",
"customerMsisdn": "233200000000",
"channel": "vodafone-gh-direct-debit",
"callbackUrl": "https://webhook.site/b503d1a9-e726-f315254a6ede"
}
```
## Response 200: Business result in ResponseCode: `2000`, `4000`. See the response code table.
```json
{
"message": "Request received! Pending preapproval",
"responseCode": "2000",
"data": {
"hubtelPreApprovalId": "5f20092321d54eefb974dbfea6de5c34",
"clientReferenceId": "3jL2KlUy3vt21debitC",
"verificationType": "USSD",
"otpPrefix": null,
"preapprovalStatus": "PENDING"
}
}
```
Full schema: /openapi/v1/direct-debit.json
# Confirm a pre-approval with an OTP (/docs/api/v1/direct-debit/verify-preapproval-otp)
Completes a pre-approval started with the OTP flow, using the code the customer received. On success the customer's wallet can be debited without further prompts.
`POST https://preapproval.hubtel.com/api/v2/merchant/{accountNumber}/preapproval/verifyotp`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"customerMsisdn": "233200000000",
"hubtelPreApprovalId": "5f20092321d54eefb974dbfea6de5c34",
"clientReferenceId": "3jL2KlUy3vt21debitC",
"otpCode": "HNRM-8852"
}
```
## Response 200: Success.
```json
{
"message": "OTP Verified! Pending preapproval",
"responseCode": "2000",
"data": {
"hubtelPreApprovalId": "5f20092321d54eefb974dbfea6de5c34",
"preapprovalStatus": "PENDING"
}
}
```
Full schema: /openapi/v1/direct-debit.json
# Get a pre-approval's status (/docs/api/v1/direct-debit/get-preapproval-status)
Returns whether a customer's direct debit pre-approval is pending, approved, failed or expired. Use it when a preapproval callback hasn't arrived, before retrying with a new reference.
`GET https://preapproval.hubtel.com/api/v2/merchant/{accountNumber}/preapproval/{clientReference}/status`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `clientReference` | path | Yes | |
## Response 200: Success.
```json
{
"message": "Success",
"code": "2000",
"data": {
"customerMsisdn": "233546335113",
"verificationType": "USSD",
"preapprovalStatus": "APPROVED",
"hubtelPreapprovalId": "5f20092321d54eefb974dbfea6de5c34",
"clientReferenceId": "3jL2KlUy3vt21debitC",
"createdAt": "2023-08-11T18:18:55.6439374Z"
}
}
```
Full schema: /openapi/v1/direct-debit.json
# Cancel a pre-approval (/docs/api/v1/direct-debit/cancel-preapproval)
Stops future debits for a customer's wallet. Do this when a loan is repaid or a subscription ends, so the customer isn't charged again.
`GET https://preapproval.hubtel.com/api/v2/merchant/{accountNumber}/preapproval/{msisdn}/cancel`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `msisdn` | path | Yes | |
## Response 200: Success.
```json
{
"message": "Successfully cancelled preapproval for customer 233548359582 and business gershon",
"responseCode": "2000",
"data": true
}
```
Full schema: /openapi/v1/direct-debit.json
# Reactivate a pre-approval (/docs/api/v1/direct-debit/reactivate-preapproval)
Restores a cancelled or expired pre-approval, asking the customer to confirm again. Use it when a customer resumes a subscription or takes a new loan.
`POST https://preapproval.hubtel.com/api/v2/merchant/{accountNumber}/preapproval/reactivate`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"callbackUrl": "https://webhook.site/b503d1af9-e726-f315254a6ede",
"customerMsisdn": "233200000000"
}
```
## Response 200: Success.
```json
{
"message": "Request received! Pending preapproval",
"responseCode": "2000",
"data": {
"hubtelPreApprovalId": "5f20092321d54eefb974dbfea6de5c34",
"clientReferenceId": "3jL2KlUy3vt21debitC",
"verificationType": "OTP",
"otpPrefix": "GNCC",
"preapprovalStatus": "PENDING"
}
}
```
Full schema: /openapi/v1/direct-debit.json
# Charge a mobile money wallet (/docs/api/v1/receive-money/receive-mobile-money)
Sends a payment prompt to the customer's phone. The response is `0001` (pending) while the customer decides. The final result is POSTed to `PrimaryCallbackUrl`, after the customer responds or the request expires. If no callback arrives within 5 minutes, call **Check a collection's status**. Prevent unsolicited prompts by charging only registered customers whose number cannot change at payment time, or verify unregistered numbers with an OTP first.
`POST https://rmp.hubtel.com/merchantaccount/merchants/{accountNumber}/receive/mobilemoney`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"CustomerName": "Joe Doe",
"CustomerMsisdn": "233200000000",
"CustomerEmail": "username@example.com",
"Channel": "vodafone-gh",
"Amount": 0.8,
"PrimaryCallbackUrl": "https://webhook.site/b503d1a9-e726-f315254a6ede",
"Description": "Union Dues",
"ClientReference": "3jL2KlUy3vt21"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4070`, `4101`, `4103`. See the response code table.
```json
{
"Message": "Transaction pending. Expect callback request for final state",
"ResponseCode": "0001",
"Data": {
"TransactionId": "09f84e20a283942e807128e8c21d08d6",
"Description": "Union Dues",
"ClientReference": "3jL2KlUy3vt21",
"Amount": 0.8,
"Charges": 0.05,
"AmountAfterCharges": 0.8,
"AmountCharged": 0.85,
"DeliveryFee": 0
}
}
```
Full schema: /openapi/v1/receive-money.json
# Send an invoice (/docs/api/v1/invoicing/create-invoice)
Creates an itemised invoice with optional discounts, fees and taxes and sends it by SMS and email with a payment link. Hubtel sends a callback when the invoice is paid.
`POST https://invoicing.hubtel.com/api/v2.0/invoice/{accountNumber}/simple`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"invoiceNumber": "12345",
"dueDate": "2026-06-02T23:59:59Z",
"createdBy": "John",
"customerName": "John",
"customerPhoneNumber": "233555654321",
"customerEmail": "username@domain.com",
"note": "Test simple invoice",
"items": [
{
"description": "Item",
"quantity": 1,
"unitPrice": 1
}
],
"discounts": [
{
"name": "Discount",
"value": 1,
"isFlat": false
}
],
"fees": [
{
"name": "Fee",
"value": 2,
"isFlat": true
}
],
"appliedTaxes": [
{
"name": "Tax",
"value": 1,
"isFlat": false
}
],
"callbackUrl": "https://webhook.site/4636d303-1234-440f-9920-68e34f43ebf9"
}
```
## Response 200: Success.
```json
{
"message": "Invoice has been created.",
"code": 201,
"data": {
"invoiceId": "pY3HfCTXZb",
"paymentUrl": "https://approval.biz/pY3HfCTXZb"
}
}
```
Full schema: /openapi/v1/invoicing.json
# Send a repeating invoice (/docs/api/v1/invoicing/create-repeat-invoice)
Creates an invoice that is re-issued on a schedule, optionally debited automatically. Use it for rent, fees or memberships billed the same way each period.
`POST https://invoicing.hubtel.com/api/v2.0/invoice/{accountNumber}/repeat`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"invoiceNumber": "12345",
"dueDate": "2026-06-02T23:59:59Z",
"createdBy": "John",
"customerName": "John",
"customerPhoneNumber": "233555654321",
"customerEmail": "username@domain.com",
"note": "Test repeat invoice",
"items": [
{
"description": "Item",
"quantity": 1,
"unitPrice": 1
}
],
"frequency": "Daily",
"shouldBeAutoDebited": false,
"discounts": [
{
"name": "Discount",
"value": 1,
"isFlat": false
}
],
"fees": [
{
"name": "Fee",
"value": 2,
"isFlat": true
}
],
"appliedTaxes": [
{
"name": "Tax",
"value": 1,
"isFlat": false
}
],
"callbackUrl": "https://webhook.site/4636d303-1234-440f-9920-68e34f43ebf9"
}
```
## Response 200: Success.
```json
{
"message": "Invoice has been created.",
"code": 201,
"data": {
"invoiceId": "pY3HfCTXZb",
"paymentUrl": "https://approval.biz/pY3HfCTXZb"
}
}
```
Full schema: /openapi/v1/invoicing.json
# Get an invoice's status (/docs/api/v1/invoicing/get-invoice-status)
Returns whether an invoice is paid or unpaid and the payment details. Use it to reconcile if the invoice callback didn't arrive.
`GET https://invoicing.hubtel.com/api/v2.0/invoice/{accountNumber}/{invoiceId}/status-check`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `invoiceId` | path | Yes | |
## Response 200: Success.
```json
{
"message": "Success",
"code": 200,
"data": {
"status": "Fully Paid",
"payments": [
{
"id": "f41ce50e-a966-4bf6-87b6-869065736f01",
"amountPaid": 1,
"amountDue": 1,
"paymentMethod": "mobilemoney",
"status": "Paid",
"paymentDate": "2026-06-01T13:28:49.456255",
"orderId": "6cf9a542-7fff-459f-afcf-a4b42207e7d2",
"receiptNumber": "748f4a9f0d664369899a74c820d95c21"
}
]
}
}
```
Full schema: /openapi/v1/invoicing.json
# Create a checkout (/docs/api/v1/online-checkout/initiate-checkout)
Creates a hosted checkout and returns a `checkoutUrl` to redirect your customer to, plus a `checkoutDirectUrl` for embedding. The customer chooses mobile money, card or Hubtel wallet on Hubtel's page. The final result arrives at `callbackUrl`; never fulfil an order from the `returnUrl` redirect alone.
`POST https://payproxyapi.hubtel.com/items/initiate`
## Request example
```json
{
"totalAmount": 100,
"description": "Book Shop Checkout",
"callbackUrl": "https://webhook.site/8b4bbd0a-5f98-4b3d-abbe-b9b49767f7d5",
"returnUrl": "http://hubtel.com/online",
"merchantAccountNumber": "11684",
"cancellationUrl": "http://hubtel.com/online",
"clientReference": "inv0012"
}
```
## Response 200: Business result in ResponseCode: `0000`, `4000`, `4101`. See the response code table.
```json
{
"responseCode": "0000",
"status": "Success",
"data": {
"checkoutUrl": "https://pay.hubtel.com/7569a11e8b784f21baa9443b3fce31ed",
"checkoutId": "7569a11e8b784f21baa9443b3fce31ed",
"clientReference": "inv0012",
"message": "",
"checkoutDirectUrl": "https://pay.hubtel.com/7569a11e8b784f21baa9443b3fce31ed/direct"
}
}
```
Full schema: /openapi/v1/online-checkout.json
# Create a recurring invoice (/docs/api/v1/recurring-invoice/create-recurring-invoice)
Starts a recurring mobile-money invoice. The response is pending (`0001`) with a `requestId` and `otpPrefix`; the OTP lands on the Virtual Phone. After **Verify a recurring invoice** and the customer approves the prompt, the initial debit result is POSTed to `callbackUrl`. Use the same test numbers as Receive Money.
`POST https://rip.hubtel.com/api/proxy/{accountNumber}/create-invoice`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"orderDate": "2022-01-28T08:57:00",
"invoiceEndDate": "2022-01-31T08:57:00",
"description": "My recurring service",
"startTime": "14:00",
"paymentInterval": "DAILY",
"customerMobileNumber": "233240000000",
"paymentOption": "MobileMoney",
"channel": "mtn_gh_rec",
"customerName": "Joe Doe",
"recurringAmount": 0.1,
"totalAmount": 0.1,
"initialAmount": 0.1,
"currency": "GHS",
"callbackUrl": "https://webhook.site/b503d1a9-e726-f315254a6ede"
}
```
## Response 200: Business result in ResponseCode: `0001`, `4000`. See the response code table.
```json
{
"responseCode": "0001",
"message": "Your request has been processed successfully.",
"data": {
"recurringInvoiceId": "0f84e20a2839482e807128e8c21d08d6",
"requestId": "a6487bc44eae44849fd80326a0dd802a",
"otpPrefix": "OQDM"
}
}
```
Full schema: /openapi/v1/recurring-invoice.json
# Verify a recurring invoice (/docs/api/v1/recurring-invoice/verify-recurring-invoice)
Completes setup with the OTP from create (`otpPrefix-0000` in the sandbox). Hubtel then prompts the customer; the initial debit callback arrives at the `callbackUrl` from create after they respond or the request expires.
`POST https://rip.hubtel.com/api/proxy/verify-invoice`
## Request example
```json
{
"recurringInvoiceId": "0f84e20a2839482e807128e8c21d08d6",
"requestId": "a6487bc44eae44849fd80326a0dd802a",
"otpCode": "OQDM-9514"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`. See the response code table.
```json
{
"responseCode": "0001",
"message": "Your request has been processed successfully. You will receive a callback on the final status shortly.",
"data": {
"recurringInvoiceId": "0f84e20a2839482e807128e8c21d08d6"
}
}
```
Full schema: /openapi/v1/recurring-invoice.json
# Cancel a recurring invoice (/docs/api/v1/recurring-invoice/cancel-recurring-invoice)
Stops a recurring invoice so no further instalments are collected. A cancellation callback (`0005`) is POSTed to the invoice's `callbackUrl`. Instalments already collected are not refunded; use Refunds for that.
`DELETE https://rip.hubtel.com/api/proxy/{accountNumber}/cancel-invoice/{id}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `id` | path | Yes | |
## Response 200: Business result in ResponseCode: `0000`, `0005`, `4000`. See the response code table.
```json
{
"responseCode": "0000",
"message": "Your request has been processed successfully"
}
```
Full schema: /openapi/v1/recurring-invoice.json
# Top up MTN airtime (/docs/api/v1/commission-services/mtn-airtime-top-up)
Tops up MTN airtime from your disbursement (prepaid) balance. The response is pending (`0001`); the final result is POSTed to `CallbackUrl`. Destination test numbers follow Send Money payout scenarios (e.g. `233240000101` succeeds). Maximum amount is 100 cedis.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/fdd76c884e614b1c8f669a3207b09a98`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233246912184",
"Amount": 0.5,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestEVD01011"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": "TestEVD01011",
"Amount": 0.85,
"TransactionId": "a50e003d8d8741d49a3a0dc677a7576b",
"Meta": {
"Commission": "0.05"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Top up Telecel airtime (/docs/api/v1/commission-services/telecel-airtime-top-up)
Tops up Telecel airtime from your disbursement (prepaid) balance. The response is pending (`0001`); the final result is POSTed to `CallbackUrl`. Destination test numbers follow Send Money payout scenarios (e.g. `233240000101` succeeds). Maximum amount is 100 cedis.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/f4be83ad74c742e185224fdae1304800`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233206439599",
"Amount": 0.5,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestEVD01021"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": "TestEVD01021",
"Amount": 0.85,
"TransactionId": "0305e0d79b2048e5b57647d4acaff939",
"Meta": {
"Commission": "0.0280"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Top up AirtelTigo airtime (/docs/api/v1/commission-services/airtel-tigo-airtime-top-up)
Tops up AirtelTigo airtime from your disbursement (prepaid) balance. The response is pending (`0001`); the final result is POSTed to `CallbackUrl`. Destination test numbers follow Send Money payout scenarios (e.g. `233240000101` succeeds). Maximum amount is 100 cedis.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/dae2142eb5a14c298eace60240c09e4b`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233574126849",
"Amount": 0.5,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestEVD01027"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Data": {
"ClientReference": "TestEVD01027",
"Amount": 0.85,
"TransactionId": "a1579b60845444babfe13945660a679d",
"Meta": {
"Commission": "0.35"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# List MTN data bundles (/docs/api/v1/commission-services/list-mtn-data-bundles)
Returns the available MTN data bundles for a phone number, supplied in the destination field. Use the returned bundle values when submitting a payment.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/b230733cd56b4a0fad820e39f66bc27c`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The destination number which will be receiving the data bundle value. This parameter is to be placed in the URL. Not in the request body. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "Successful",
"Data": [
{
"Display": "17.79MB",
"Value": "data_bundle_1",
"Amount": 0.5
},
{
"Display": "Kokrokoo 400MB, 5am to 8am",
"Value": "kokrokoo_bundle_1",
"Amount": 1.24
},
{
"Display": "35.57MB",
"Value": "data_bundle_2",
"Amount": 1
},
{
"Display": "349.24MB",
"Value": "data_bundle_3",
"Amount": 3
},
{
"Display": "718.91MB",
"Value": "data_bundle_4",
"Amount": 10
},
{
"Display": "1.19GB",
"Value": "flexi_data_bundle",
"Amount": 20
},
{
"Display": "2.38GB",
"Value": "flexi_data_bundle",
"Amount": 40
},
{
"Display": "3.58GB",
"Value": "flexi_data_bundle",
"Amount": 60
},
{
"Display": "4.77GB",
"Value": "flexi_data_bundle",
"Amount": 80
},
{
"Display": "7.87GB",
"Value": "flexi_data_bundle",
"Amount": 100
},
{
"Display": "9.44GB",
"Value": "flexi_data_bundle",
"Amount": 120
},
{
"Display": "11.80GB",
"Value": "flexi_data_bundle",
"Amount": 150
},
{
"Display": "26.50GB",
"Value": "flexi_data_bundle",
"Amount": 200
},
{
"Display": "33.13GB",
"Value": "flexi_data_bundle",
"Amount": 250
},
{
"Display": "39.62GB",
"Value": "flexi_data_bundle",
"Amount": 299
},
{
"Display": "92.88GB",
"Value": "flexi_data_bundle",
"Amount": 350
},
{
"Display": "Video 135.69MB",
"Value": "video_bundle_1",
"Amount": 1
},
{
"Display": "Video 678.43MB",
"Value": "video_bundle_2",
"Amount": 5
},
{
"Display": "Video 1.33GB",
"Value": "video_bundle_3",
"Amount": 10
},
{
"Display": "Social Media 70.87MB",
"Value": "social_media_bundle_1",
"Amount": 1
},
{
"Display": "Social Media 354.36MB",
"Value": "social_media_bundle_2",
"Amount": 5
},
{
"Display": "Social Media 708.72MB",
"Value": "social_media_bundle_3",
"Amount": 10
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Buy MTN data bundle (/docs/api/v1/commission-services/buy-mtn-data-bundle)
Pays for MTN data bundles from your prepaid balance; look up a phone number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/b230733cd56b4a0fad820e39f66bc27c`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233246912184",
"Amount": 0.5,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestDATA01013",
"Extradata": {
"bundle": "data_bundle_1"
}
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state.",
"Data": {
"ClientReference": "TestDATA01013",
"Amount": 0.5,
"TransactionId": "5b40e2e40fd4441d80b69b352f3103c7",
"Meta": {
"Commission": "0.0198"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# List Telecel data bundles (/docs/api/v1/commission-services/list-telecel-data-bundles)
Returns the available Telecel data bundles for a phone number, supplied in the destination field. Use the returned bundle values when submitting a payment.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/fa27127ba039455da04a2ac8a1613e00`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The destination number which will be receiving the data bundle value. This parameter is to be placed in the URL. Not in the request body. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "Successful",
"Data": [
{
"Display": " Dual Recharge",
"Value": " 5.7 GB",
"Amount": 50
},
{
"Display": "Chat Monthly",
"Value": "2 GB",
"Amount": 20
},
{
"Display": "Starter Monthly",
"Value": "560 MB",
"Amount": 10
},
{
"Display": " Streamer Weekly",
"Value": "460 MB",
"Amount": 5
},
{
"Display": "Browser Daily",
"Value": "61 MB",
"Amount": 1
},
{
"Display": " Starter Daily",
"Value": "25 MB",
"Amount": 0.5
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Buy Telecel data bundle (/docs/api/v1/commission-services/buy-telecel-data-bundle)
Pays for Telecel data bundles from your prepaid balance; look up a phone number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/fa27127ba039455da04a2ac8a1613e00`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233206439419",
"Amount": 0.5,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestDATA01025",
"Extradata": {
"bundle": "25 MB"
}
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": "TestDATA01025",
"Amount": 1,
"TransactionId": " 558625e7f8c94feb82ddf50cb33bc557",
"Meta": {
"Commission": "0.0140"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# List Telecel broadband (/docs/api/v1/commission-services/list-telecel-broadband-bundles)
Returns the available Telecel broadband for a phone number, supplied in the destination field. Use the returned bundle values when submitting a payment.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/b9a1aa246ba748f9ba01ca4cdbb3d1d3`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The landline number on the broadband account. E.g.: "0302450262" |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "",
"Data": [
{
"Display": "name",
"Value": "BOATENG PHILIP NANA BEDIAKO",
"Amount": 0
},
{
"Display": "amountDue",
"Value": "0.00",
"Amount": 0
},
{
"Display": "account",
"Value": "0302450262",
"Amount": 0
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Buy Telecel broadband (/docs/api/v1/commission-services/buy-telecel-broadband-bundle)
Pays for Telecel broadband from your prepaid balance; look up a phone number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/b9a1aa246ba748f9ba01ca4cdbb3d1d3`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "0302450262",
"Amount": 1,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "567680374084840678",
"Extradata": {
"bundle": "P0444101"
}
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state.",
"Data": {
"ClientReference": "567680374084840678",
"Amount": 1,
"TransactionId": "f12b0054fe884769910e187cac833ba1",
"Meta": {
"Commission": "0.0000"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# List AirtelTigo data bundles (/docs/api/v1/commission-services/list-airtel-tigo-data-bundles)
Returns the available AirtelTigo data bundles for a phone number, supplied in the destination field. Use the returned bundle values when submitting a payment.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/06abd92da459428496967612463575ca`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The destination number which will be receiving the data bundle value. This parameter is to be placed in the URL. Not in the request body. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "Select bundle",
"Data": [
{
"Display": "80MB Bundle (GHS 1)",
"Value": "DATA1",
"Amount": 1
},
{
"Display": "200MB Bundle (GHS 2",
"Value": "DATA2",
"Amount": 2
},
{
"Display": "650MB Bundle (GHS 5)",
"Value": "DATA5",
"Amount": 5
},
{
"Display": "2GB Bundle (GHS 10)",
"Value": "DATA10",
"Amount": 10
},
{
"Display": "5GB Bundle (GHS 20)",
"Value": "DATA20",
"Amount": 20
},
{
"Display": "11GB Bundle (GHS 50)",
"Value": "DATA50",
"Amount": 50
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Buy AirtelTigo data bundle (/docs/api/v1/commission-services/buy-airtel-tigo-data-bundle)
Pays for AirtelTigo data bundles from your prepaid balance; look up a phone number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/06abd92da459428496967612463575ca`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233273833933",
"Amount": 50,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestDATA01090",
"Extradata": {
"bundle": "DATA50"
}
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": "TestDATA01090",
"Amount": 50,
"TransactionId": " 6bf810b8f7d5424a973165b36cc1817e",
"Meta": {
"Commission": "0.0560"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Look up a DStv account (/docs/api/v1/commission-services/look-up-dstv-account)
Confirms a smartcard or customer number exists for DStv and returns the account holder's name and details. Show the returned name so the customer can confirm the account before paying.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/297a96656b5846ad8b00d5d41b256ea7`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The DStv account number. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "",
"Data": [
{
"Display": "name",
"Value": "John Barnes",
"Amount": 0
},
{
"Display": "amountDue",
"Value": "0.00",
"Amount": 0
},
{
"Display": "account",
"Value": "7029864396",
"Amount": 0
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Pay DStv (/docs/api/v1/commission-services/pay-dstv-bill)
Pays for DStv from your prepaid balance; look up a smartcard or customer number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/297a96656b5846ad8b00d5d41b256ea7`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "7029864396",
"Amount": 50,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestTV0101"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": "TestTV0101",
"Amount": 50,
"TransactionId": "9c6d65a2a7834759b44919a1621b80fd",
"Meta": {
"Commission": "0.3500"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Look up a GOtv account (/docs/api/v1/commission-services/look-up-gotv-account)
Confirms a smartcard or customer number exists for GOtv and returns the account holder's name and details. Show the returned name so the customer can confirm the account before paying.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/e6ceac7f3880435cb30b048e9617eb41`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The GOtv account number. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "",
"Data": [
{
"Display": "name",
"Value": "Senya Duku",
"Amount": 0
},
{
"Display": "amountDue",
"Value": "-201.00",
"Amount": 0
},
{
"Display": "account",
"Value": "7032371505",
"Amount": 0
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Pay GOtv (/docs/api/v1/commission-services/pay-gotv-bill)
Pays for GOtv from your prepaid balance; look up a smartcard or customer number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/e6ceac7f3880435cb30b048e9617eb41`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "7032371505",
"Amount": 50,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestTV0106"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": "TestTV0106",
"Amount": 50,
"TransactionId": "9c6d65a2a7834759b44919a1621b80fd",
"Meta": {
"Commission": "0.3500"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Look up a StarTimes account (/docs/api/v1/commission-services/look-up-startimes-account)
Confirms a smartcard or customer number exists for StarTimes and returns the account holder's name and details. Show the returned name so the customer can confirm the account before paying.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/6598652d34ea4112949c93c079c501ce`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The StarTimes TV account number. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "Successful",
"Data": [
{
"Display": "Name",
"Value": "Joe Nti",
"Amount": 0
},
{
"Display": "Account Number",
"Value": "02190617357",
"Amount": 0
},
{
"Display": "Bouquet",
"Value": "DTH_Super ",
"Amount": 0
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Pay StarTimes (/docs/api/v1/commission-services/pay-startimes-bill)
Pays for StarTimes from your prepaid balance; look up a smartcard or customer number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/6598652d34ea4112949c93c079c501ce`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "02190617357",
"Amount": 50,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestTV0108"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": "TestTV0108",
"Amount": 50,
"TransactionId": "0bf810b8f7d5424a973165b36cc1817e",
"Meta": {
"Commission": "0.3500"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Look up a ECG prepaid meter (/docs/api/v1/commission-services/look-up-ecg-meter)
Confirms a meter number exists for ECG prepaid and returns the account holder's name and details. Show the returned name so the customer can confirm the account before paying.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/e6d6bac062b5499cb1ece1ac3d742a84`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The mobile number linked to a particular ECG meter whose details need to be checked. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "Successful",
"Data": [
{
"Display": " THOMAS ANANE (G131099826)",
"Value": " G131099826",
"Amount": -1.1432
},
{
"Display": " ADEMAU LYDIA (24911947992)",
"Value": " 24911947992",
"Amount": 0
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Pay ECG prepaid (/docs/api/v1/commission-services/top-up-ecg-meter)
Pays for ECG prepaid from your prepaid balance; look up a meter number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/e6d6bac062b5499cb1ece1ac3d742a84`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233541312238",
"Amount": 1,
"CallbackUrl": "https://webhook.site/fcad8efa-624b-44c8-a129-b1c01921191d",
"ClientReference": "TestDATA2022052105",
"Extradata": {
"bundle": "P09137104"
}
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state",
"Data": {
"ClientReference": " TestDATA2022052105",
"Amount": 1,
"TransactionId": " 6bf810b8f7d5424a973165b36cc1817e",
"Meta": {
"Commission": "0.0171"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Look up a Ghana Water meter (/docs/api/v1/commission-services/look-up-ghana-water-meter)
Confirms a meter number exists for Ghana Water and returns the account holder's name and details. Show the returned name so the customer can confirm the account before paying.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/6c1e8a82d2e84feeb8bfd6be2790d71d`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `destination` | query | Yes | The meter number to be queried. |
| `mobile` | query | Yes | The customer's phone number. |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Successful",
"Label": "Successful",
"Data": [
{
"Display": "name",
"Value": "AMAKYE FREMPONG",
"Amount": 0
},
{
"Display": "amountDue",
"Value": "371.89",
"Amount": 371.89
},
{
"Display": "sessionId",
"Value": "3792660ccf0e687b64cdb3f776fd6e368ca4260d",
"Amount": 0
}
]
}
```
Full schema: /openapi/v1/commission-services.json
# Pay Ghana Water (/docs/api/v1/commission-services/pay-ghana-water-bill)
Pays for Ghana Water from your prepaid balance; look up a meter number first with the matching query. The response is pending and the final result arrives at your callback URL. Use a unique ClientReference to identify the transaction. Check its status before retrying an uncertain payment. You earn commission on each successful sale.
`POST https://cs.hubtel.com/commissionservices/{accountNumber}/6c1e8a82d2e84feeb8bfd6be2790d71d`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"Destination": "233548359582",
"Amount": 1,
"Extradata": {
"bundle": "080706070056",
"Email": "username@example.com",
"SessionId": "e7a113dd2f8b08b85a149d3db40854de2f13410b"
},
"CallbackUrl": "https://webhook.site/b630fc60-8041-470c-b13e-ee69ef15b2c2",
"ClientReference": "275438fce23f4983b9583abdf0ded9c7e"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Message": "Transaction pending. Expect callback request for final state.",
"Data": {
"ClientReference": "509e21d2b1104036a64ca44b30613f1ftestt",
"Amount": 1,
"TransactionId": "7304f27f559a4680a912ce7ec19e6d2a",
"Meta": {
"Commission": "0.0070"
}
}
}
```
Full schema: /openapi/v1/commission-services.json
# Check a credit score (/docs/api/v1/lending/check-credit-score)
Returns a consumer's credit score and a basic debt summary from the credit bureau. Requires a lending agreement and the customer's consent; operated by mycreditscore.com.gh.
`POST https://score-api.mycreditscore.com.gh/api/v1/score-check`
## Request example
```json
{
"ghanaCard": "GHA-000000000-0",
"identifierName": "John Doe",
"identifierNationality": "Ghanaian",
"identifierDob": "1999-06-15T00:00:00Z",
"identifierMobileNumber": "2330000000",
"currencyOfCredit": "GHS",
"creditAmount": 100,
"purposeOfCheck": "Loan Application",
"typeOfCreditFacility": "Personal Loan",
"lenderReferenceId": "LOAN-REF-12345",
"voterId": "VO678232",
"passportNumber": "PAS67894",
"driverLicenseNumber": "234286382",
"ssnitNumber": "E10089883497",
"nhisNumber": "N49834984",
"tin": "T19892323"
}
```
## Response 200: Success.
```json
{
"message": "Your score check request was successful",
"code": 200,
"data": {
"isCreditScoreActivated": "true",
"creditScoreIfActive": 711,
"name": "John Doe",
"minScore": 300,
"maxScore": 850,
"scoreBand": "Very Good",
"scoreBandInterpretation": "Shows lenders that you are a good investment with a strong credit history and qualify for very favorable interest rates and loan terms. Lenders will consider you a reliable borrower."
},
"subCode": "0",
"errors": null,
"responseCode": null
}
```
Full schema: /openapi/v1/lending.json
# Get a consumer identity report (/docs/api/v1/lending/get-consumer-identity-report)
Returns the identity details the credit bureau holds for a consumer, to support identity verification. Requires the customer's consent; operated by mycreditscore.com.gh.
`POST https://profile-api.mycreditscore.com.gh/api/v1/consumer-identity-report`
## Request example
```json
{
"nationalIds": [
{
"identityType": "passport",
"identityNumber": "0000000"
},
{
"identityType": "driverlicense",
"identityNumber": "0000000"
},
{
"identityType": "ghanacard",
"identityNumber": "GHA-000000000-2"
}
],
"names": [
{
"firstName": "John",
"lastName": "Doe",
"middleName": ""
}
],
"numberAndEmail": [
{
"mobileNumber": "233000000000",
"email": "John.Doe@example.com"
}
],
"dateOfBirth": "2007-11-21",
"gender": "male",
"reasonForRequest": "KYC",
"requestVerification": true,
"ghanaCardNumber": "GHA-000000000-2",
"identitySource": "General Report",
"reportType": "CreditReport",
"requestedBy": "John Doe",
"requestedTime": "2025-11-28T14:01:22.2373367Z"
}
```
## Response 200: Success.
```json
{
"message": "Your request for consumer identity report was successful",
"code": 200,
"data": {
"primaryIdentities": [
{
"identifier": "First Name",
"dataValue": "John Doe",
"dataProvider": "Prudential Bank Limited",
"dataSource": "Prudential Bank Limited",
"discoveryDate": "2025-11-01",
"status": "Active"
}
],
"associatedIdentities": [
{
"identifier": "Forename",
"dataValue": "John Doe",
"dataProvider": "NIA",
"dataSource": "NIA",
"discoveryDate": "2019 December 14",
"status": "Active"
}
]
},
"subCode": "0",
"errors": null,
"responseCode": null
}
```
Full schema: /openapi/v1/lending.json
# Get a consumer credit profile (/docs/api/v1/lending/get-consumer-profile)
Returns a detailed credit profile: accounts, balances and payment behaviour. Requires customer consent; operated by mycreditscore.com.gh.
`POST https://basic-credit-report-api.mycreditscore.com.gh/api/v1/consumer-profile-detail`
## Request example
```json
{
"ghanaCard": "GHA-000000000-0",
"identifierName": "",
"identifierNationality": "",
"identifierDob": "1999-06-15T00:00:00Z",
"identifierMobileNumber": "",
"currencyOfCredit": "",
"creditAmount": 1,
"purposeOfCheck": "",
"typeOfCreditFacility": "",
"lenderReferenceId": "",
"voterId": "",
"passportNumber": "",
"driverLicenseNumber": "",
"ssnitNumber": "",
"nhisNumber": "",
"tin": ""
}
```
## Response 200: Success.
```json
{
"message": "Your request for profile detail was successful",
"code": 200,
"data": {
"records": [
{
"demographicData": {
"ghanaCard": "GHA-000000000-0",
"fullName": "John Doe",
"dateOfBirth": "1999-11-17",
"gender": "Male",
"address": "North, Eastern",
"phoneNumbers": [
"233000000000"
],
"email": "john.doe@gmail.com"
},
"employmentHistory": [
{
"employmentType": "Self Employed",
"employerName": null,
"employerAddress1": null,
"employerAddress2": null,
"employerAddress3": null,
"employerAddress4": null,
"employerAddressPostalCode": null,
"dateOfEmployment": null,
"occupation": "Senior Software Engineer",
"employeePayrollNumber": null,
"incomeCurrency": "GHS",
"income": "1000",
"workTelephone": null
}
],
"borrowerAddressHistory": [],
"nationalId": "GHA-0000000000-0",
"tin": [],
"nhis": [],
"ssnit": [
"E242489898902"
],
"driverLicense": [],
"passport": [],
"voterId": [
"0000000000"
]
}
]
},
"subCode": "0",
"errors": null,
"responseCode": null
}
```
Full schema: /openapi/v1/lending.json
# Get a compact credit report (/docs/api/v1/lending/get-credit-profile-summary)
Returns a summary of a consumer's credit profile. Requires consent; operated by mycreditscore.com.gh.
`POST https://basic-credit-report-api.mycreditscore.com.gh/api/v1/credit-profile-summary`
## Request example
```json
{
"ghanaCard": "GHA-000000000-2",
"identifierName": "",
"identifierNationality": "",
"identifierDob": "1997-06-04T00:00:00Z",
"identifierMobileNumber": "",
"currencyOfCredit": "",
"creditAmount": 1,
"purposeOfCheck": "",
"typeOfCreditFacility": "",
"lenderReferenceId": "",
"voterId": "",
"passportNumber": "",
"driverLicenseNumber": "",
"ssnitNumber": "",
"nhisNumber": "",
"tin": ""
}
```
## Response 200: Success.
```json
{
"message": "Your request for credit profile summary was successful",
"code": 200,
"data": {
"records": [
{
"creditProfileSummary": {
"totalAccounts": {
"OTHERS": 0,
"GHS": 240,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalActiveAccounts": {
"OTHERS": 0,
"GHS": 3,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalClosedAccounts": {
"OTHERS": 0,
"GHS": 237,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalMonthlyInstallment": {
"OTHERS": 0,
"GHS": 740,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalOutstandingDebt": {
"OTHERS": 0,
"GHS": 243,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalAccountsInArrears": {
"OTHERS": 0,
"GHS": 0,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalArrearAmount": {
"OTHERS": 0,
"GHS": 0,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalAccountsInGoodStanding": {
"OTHERS": 0,
"GHS": 240,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalJudgementDebts": {
"OTHERS": 0,
"GHS": 0,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalJudgementAmount": {
"OTHERS": 0,
"GHS": 0,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"lastJudgementDate": {
"OTHERS": null,
"GHS": null,
"USD": null,
"GBP": null,
"EUR": null
},
"totalDishonouredCheques": {
"OTHERS": 0,
"GHS": 0,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"totalDishonouredChequeAmount": {
"OTHERS": 0,
"GHS": 0,
"USD": 0,
"GBP": 0,
"EUR": 0
},
"lastBouncedChequeDate": {
"OTHERS": null,
"GHS": null,
"USD": null,
"GBP": null,
"EUR": null
}
},
"nationalId": "GHA-000000000-2",
"tin": [],
"nhis": [],
"ssnit": [
"E10876767220019"
],
"driverLicense": [],
"passport": [],
"voterId": [
"880000003358"
]
}
]
},
"subCode": "0",
"errors": null,
"responseCode": null
}
```
Full schema: /openapi/v1/lending.json
# Get repayment history (/docs/api/v1/lending/get-repayment-history)
Returns a consumer's history of repaying credit, month by month. Requires customer consent; operated by mycreditscore.com.gh.
`POST https://score-debt-api.mycreditscore.com.gh/api/v1/repayment-history`
## Request example
```json
{
"ghanaCard": "GHA-000000000-2",
"identifierName": "",
"identifierNationality": "",
"identifierDob": "1997-06-04T00:00:00Z",
"identifierMobileNumber": "",
"currencyOfCredit": "",
"creditAmount": 1,
"purposeOfCheck": "",
"typeOfCreditFacility": "",
"lenderReferenceId": "",
"voterId": "",
"passportNumber": "",
"driverLicenseNumber": "",
"ssnitNumber": "",
"nhisNumber": "",
"tin": ""
}
```
## Response 200: Success.
```json
{
"message": "Your request for repayment history was successful",
"code": 200,
"data": {
"records": [
{
"repaymentHistory": [
{
"lenderName": "Micro Money Lending Limited",
"accountNumber": "0000000",
"purposeOfFacility": "P",
"facilityType": "119",
"reportedDate": "20250930",
"lenderLogoUrl": "http://logo.png",
"numberOfTimesOverdue": {
"days1To30": 0,
"days31To60": 0,
"days61To90": 0,
"days91To120": 0,
"days121To150": 0,
"days151To180": 0,
"days180Plus": 0
},
"repaymentHistory": [
{
"date": "2025-09-01T00:00:00Z",
"status": "OK",
"amountOverdue": 0
}
]
},
{
"lenderName": "Micro Money Lending Limited",
"accountNumber": "0000000",
"purposeOfFacility": "P",
"facilityType": "119",
"reportedDate": "20251110",
"lenderLogoUrl": "http://logo.png",
"numberOfTimesOverdue": {
"days1To30": 0,
"days31To60": 0,
"days61To90": 0,
"days91To120": 0,
"days121To150": 0,
"days151To180": 0,
"days180Plus": 0
},
"repaymentHistory": [
{
"date": "2025-10-01T00:00:00Z",
"status": "ND",
"amountOverdue": null
},
{
"date": "2025-11-01T00:00:00Z",
"status": "OK",
"amountOverdue": 0
}
]
}
],
"nationalId": "GHA-000000000-6",
"tin": [],
"nhis": [],
"ssnit": [],
"driverLicense": [],
"passport": [],
"voterId": []
}
]
},
"subCode": "0",
"errors": null,
"responseCode": null
}
```
Full schema: /openapi/v1/lending.json
# Send an SMS with a GET request (/docs/api/v1/sms/send-sms-quick)
Sends one SMS with credentials and content in the query string. Prefer **Send an SMS** (POST): query strings may be recorded in server logs and expose your client secret.
`GET https://sms.hubtel.com/v1/messages/send`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `clientsecret` | query | Yes | The client secret used to authenticate SMS requests. See [API keys and authentication](/docs/get-started/keys). |
| `clientid` | query | Yes | The client ID used to authenticate SMS requests. See [API keys and authentication](/docs/get-started/keys). |
| `from` | query | Yes | Sender ID or Name recipients will see. Maximum characters for this value is 11. |
| `to` | query | Yes | Mobile number of recipient. |
| `content` | query | Yes | Content of the simple message |
## Response 200: Business result in ResponseCode: `0`, `1`, `2`. See the response code table.
```json
{
"rate": 0.0309,
"messageId": "9c5f3edc-529e-4182-959b-aeb17b9ddad4",
"status": 0,
"networkId": "62001",
"clientReference": null,
"statusDescription": "request submitted successfully"
}
```
Full schema: /openapi/v1/sms.json
# Send an SMS (/docs/api/v1/sms/send-sms)
Sends one SMS from an approved sender ID. The response includes a `messageId`; delivery is reported to your callback and via **Get a message**. Sender IDs are approved per business; in test mode any sender ID works.
`POST https://sms.hubtel.com/v1/messages/send`
## Request example
```json
{
"From": "AbrantieLai",
"To": "233546335113",
"Content": "This is a test. Kindly ignore."
}
```
## Response 200: Business result in ResponseCode: `0`, `1`, `2`. See the response code table.
```json
{
"rate": 0.0246,
"messageId": "fab43849-6c5b-4334-a88b-d06520b1ace8",
"status": 0,
"networkId": "62002",
"clientReference": null,
"statusDescription": "request submitted successfully"
}
```
Full schema: /openapi/v1/sms.json
# Send the same SMS to many recipients (/docs/api/v1/sms/send-sms-batch)
Sends one message to a list of recipients and returns a `batchId` plus a `messageId` per recipient.
`POST https://sms.hubtel.com/v1/messages/batch/simple/send`
## Request example
```json
{
"From": "AbrantieLai",
"Recipients": [
"233546335113",
"233501431586"
],
"Content": "Welcome to the first ever bulk SMS via API in Ghana"
}
```
## Response 200: Success.
```json
{
"batchId": "165949ee-431b-4bf8-9eca-108058a8bc32",
"status": 0,
"data": [
{
"recipient": "233546335113",
"content": "Welcome to the first ever bulk SMS via API in Ghana",
"messageId": "e80133f9-e822-457c-98fb-d217bc4a1f83"
},
{
"recipient": "233501431586",
"content": "Welcome to the first ever bulk SMS via API in Ghana",
"messageId": "ebc7948a-7c81-4396-9104-9c99fc921069"
}
]
}
```
Full schema: /openapi/v1/sms.json
# Send a different SMS to each recipient (/docs/api/v1/sms/send-sms-personalized)
Sends a different message to each recipient in one request, for example with each customer's name or balance. Returns a `batchId` and a `messageId` per recipient for delivery tracking.
`POST https://sms.hubtel.com/v1/messages/batch/personalized/send`
## Request example
```json
{
"From": "AbrantieCo",
"personalizedRecipients": [
{
"To": "233501431586",
"Content": "Hi Pheezy, thank you for all you do for this business"
},
{
"To": "233501431586",
"Content": "Hi Joe, thank you for all you do for this business"
}
]
}
```
## Response 200: Success.
```json
{
"batchId": "18ee6a2a-29ac-41c6-b70f-de809b040584",
"status": 0,
"data": [
{
"recipient": "233501431586",
"content": "Hi Pheezy, thank you for all you do for this business",
"messageId": "350fd34d-dce1-4694-a4c9-d9b97d1f4593"
},
{
"recipient": "233546335113",
"content": "Hi Joe, thank you for all you do for this business",
"messageId": "f58e7f2a-203a-4079-a518-7f6647099b5e"
}
]
}
```
Full schema: /openapi/v1/sms.json
# Get a message (/docs/api/v1/sms/get-message)
Returns a message's delivery status: `delivered`, `undelivered`, `rejected` or `expired`.
`GET https://sms.hubtel.com/v1/messages/{messageId}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `messageId` | path | Yes | |
## Response 200: Success.
```json
{
"rate": 0.0309,
"batchId": null,
"messageId": "eadbfcd0-94d1-438f-ad32-0013f34042c2",
"content": "The Job is the JOB",
"status": "Delivered",
"updateTime": "2023-05-30T16:43:15",
"time": "2023-05-30T16:43:13.7208383Z",
"to": "233546335113",
"from": "AbrantieCo"
}
```
Full schema: /openapi/v1/sms.json
# Get a batch (/docs/api/v1/sms/get-message-batch)
Returns the delivery status of every message in a batch. Use callback delivery updates to reduce repeated status requests.
`GET https://sms.hubtel.com/v1/messages/batch/{messageId}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `messageId` | path | Yes | |
## Response 200: Success.
```json
{
"batchId": "eadbfcd0-94d1-438f-ad32-0013f34042c2",
"data": [
{
"rate": 0.0309,
"messageId": "f58e7f2a-203a-4079-a518-7f6647099b5e",
"content": "Hi Joe, thank you for all you do for this business",
"status": "Delivered",
"updateTime": "2023-03-21T12:54:43",
"time": "2023-03-21T12:50:27.893495Z",
"to": "233546335113",
"from": "AbrantieCo"
},
{
"rate": 0.0309,
"messageId": "350fd34d-dce1-4694-a4c9-d9b97d1f4593",
"content": "Hi Pheezy, thank you for all you do for this business",
"status": "Delivered",
"updateTime": "2023-03-21T12:50:34",
"time": "2023-03-21T12:50:27.893495Z",
"to": "233501431586",
"from": "AbrantieCo"
}
]
}
```
Full schema: /openapi/v1/sms.json
# Get your collection balance (/docs/api/v1/balance-transfers/get-collection-balance)
Returns the available balance of your collection (POS sales) account, which holds customer payments before settlement or transfer to your disbursement account.
`GET https://trnf.hubtel.com/api/inter-transfers/{accountNumber}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Response 200: Success.
```json
{
"responseCode": "0000",
"message": "Success",
"data": {
"amount": 123.5
}
}
```
Full schema: /openapi/v1/balance-transfers.json
# Move money between your accounts (/docs/api/v1/balance-transfers/transfer-balance)
Transfers funds from your collection account to your disbursement account so you can pay out. The result arrives at your callback URL. If the callback does not arrive, use **Get a transfer's status**.
`POST https://trnf.hubtel.com/api/inter-transfers/{accountNumber}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"Description": "Hubtel Transfer Test",
"Amount": 0.8,
"ClientReference": "bd0io3202ef49",
"DestinationAccountNumber": "11691",
"PrimaryCallbackUrl": "https://webhook.site/b513d1a9-e7826-a6ede"
}
```
## Response 200: Success.
```json
{
"responseCode": "0001",
"message": "Pending",
"data": {
"clientReference": "bd0i03202ef49",
"description": "Your request has been accepted. We'll notify you when the transaction is completed.",
"amount": 0.8,
"charges": 0,
"meta": null,
"recipientName": "gershon"
}
}
```
Full schema: /openapi/v1/balance-transfers.json
# Get your disbursement balance (/docs/api/v1/balance-transfers/get-disbursement-balance)
Returns the available balance of your disbursement (prepaid) account, which funds payouts.
`GET https://trnf.hubtel.com/api/inter-transfers/prepaid/{accountNumber}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Response 200: Success.
```json
{
"responseCode": "0000",
"message": "Success",
"data": {
"amount": 11.5
}
}
```
Full schema: /openapi/v1/balance-transfers.json
# Get a transfer's status (/docs/api/v1/balance-transfers/get-transfer-status)
Returns the status of a balance transfer by `clientReference`. Use it when a transfer callback hasn't arrived, before retrying with a new reference.
`GET https://trnf.hubtel.com/api/inter-transfers/status/{accountNumber}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `clientReference` | query | Yes | The client reference of the transaction specified in the request payload. |
## Response 200: Success.
```json
{
"message": "success",
"code": "200",
"data": {
"id": "bfe03a54f40e4f91ae8d1977f2250d39",
"createdAt": "2024-07-03T16:48:49.1073714+00:00",
"updatedAt": null,
"transferDescription": "InterFineractTransfer",
"transferAmount": 1,
"clientReference": "76576343905406557",
"callbackUrl": "https://webhook.site/3ae16425-b322-4e8e-ab52-c97bcd3c9ec1",
"fromAccountType": "receivemoney",
"fromAccountId": "11684",
"toAccountType": "sendmoney",
"toAccountId": "11691",
"fromBusinessId": "gershon",
"toBusinessId": "gershon",
"status": "success",
"failureReason": null
}
}
```
Full schema: /openapi/v1/balance-transfers.json
# Pay out to a mobile money wallet (/docs/api/v1/send-money/send-mobile-money)
Sends money from your disbursement account to a mobile money wallet. The response is pending; the final result is POSTed to `PrimaryCallbackUrl`. Your disbursement balance must cover the amount plus fees. If no callback arrives within 5 minutes, call **Check a payout's status**.
`POST https://smp.hubtel.com/api/merchants/{accountNumber}/send/mobilemoney`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
## Request example
```json
{
"RecipientName": "Joe Doe",
"RecipientMsisdn": "233200000000",
"CustomerEmail": "username@example.com",
"Channel": "vodafone-gh",
"Amount": 10,
"PrimaryCallbackURL": "https://webhook.site/b503d1a9-e726-f315254a6ede",
"Description": "Union Dues",
"ClientReference": "25335r45pch53544044"
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`, `4101`, `4103`. See the response code table.
```json
{
"ResponseCode": "0001",
"Data": {
"AmountDebited": 0,
"TransactionId": "8a545e5c7357714b80b65f76",
"Description": "Your request has been accepted. We will notify you when the transaction is completed.",
"ClientReference": "25335r45pch53544044",
"ExternalTransactionId": "",
"Amount": 10,
"Charges": 0,
"Meta": null,
"RecipientName": null
}
}
```
Full schema: /openapi/v1/send-money.json
# Check a payout's status (/docs/api/v1/send-money/get-payout-status)
Returns the current status of a mobile money or bank payout by `clientReference`. Use it when no final callback has arrived within 5 minutes.
`GET https://smrsc.hubtel.com/api/merchants/{accountNumber}/transactions/status`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `clientReference` | query | Yes | The clientReference of the transaction specified in the request payload. |
## Response 200: Business result in ResponseCode: `0000`, `4000`. See the response code table.
```json
{
"ResponseCode": "success",
"Data": {
"TransactionId": "09f84e20a283942e807128e8c21d0303",
"networkTransactionId": "142116938399",
"Amount": 0.8,
"Fees": 0.01,
"ClientReference": "3jL2KlUy3vt21",
"Channel": "vodafone-gh",
"CustomerNumber": "233200000000",
"transactionStatus": "success",
"CreatedAt": "2021-08-23 11:31:06"
}
}
```
Full schema: /openapi/v1/send-money.json
# Pay out to a bank account (/docs/api/v1/send-to-bank/send-to-bank)
Sends money from your disbursement account to a Ghanaian bank account identified by `bankCode` in the path. Verify the account name first with **Look up a bank account name**. The final result is POSTed to `PrimaryCallbackUrl`.
`POST https://smp.hubtel.com/api/merchants/{accountNumber}/send/bank/gh/{bankCode}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **disbursement account number** (prepaid), which funds payouts and purchases. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the disbursement account in Workbench. |
| `bankCode` | path | Yes | The recipient bank's GhIPSS code, for example `300304` for GCB Bank or `300312` for Ecobank. See the [full list of bank codes](/docs/guides/payouts#bank-codes). |
## Request example
```json
{
"Amount": 10,
"BankName": "",
"BankBranch": "",
"BankBranchCode": "",
"BankAccountNumber": "4XXXXXXXXX",
"BankAccountName": "",
"ClientReference": "sendToBank101",
"PrimaryCallbackUrl": "https://webhook.site/b503d1a9-e726-f315254a6ede",
"Description": "Test Deposit",
"RecipientPhoneNumber": ""
}
```
## Response 200: Business result in ResponseCode: `0001`, `2001`, `4000`, `4075`. See the response code table.
```json
{
"ResponseCode": "0001",
"Data": {
"AmountDebited": 0,
"TransactionId": "367121386447",
"Description": "Your request has been accepted. We will notify you when the transaction is completed.",
"ClientReference": "sendToBank101",
"ExternalTransactionId": "",
"Amount": 10,
"Charges": 0,
"Meta": null,
"RecipientName": null
}
}
```
Full schema: /openapi/v1/send-to-bank.json
# Report service fulfilment (/docs/api/v1/programmable-services/report-service-fulfilment)
Tells Hubtel whether your programmable service delivered what the customer paid for in a USSD session. Report whether fulfilment succeeded or failed so the payment can be settled or reversed.
`POST https://gs-callback.hubtel.com:9055/callback`
## Request example
```json
{
"SessionId": "3c796dac28174f739de4262d08409c51",
"OrderId": "ac3307bcca7445618071e6b0e41b50b5",
"ServiceStatus": "success",
"MetaData": null
}
```
Full schema: /openapi/v1/programmable-services.json
# Refund a payment (/docs/api/v1/refunds/refund-transaction)
Refunds a completed mobile money payment in full, within 45 days. The refund is processed asynchronously and the result is POSTed to `callbackUrl`.
`POST https://refund-api.hubtel.com/refund/{accountNumber}/order/{transactionId}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `transactionId` | path | Yes | |
## Request example
```json
{
"callbackUrl": "https://webhook.site/b503d1a9-e726-f315254a6ede"
}
```
## Response 200: Business result in ResponseCode: `0001`, `4000`. See the response code table.
```json
{
"message": "Transaction pending. Expect callback request for final state.",
"responseCode": "0001",
"data": {
"orderId": "b230733cd56b4a0fad820e39f66bc27c"
}
}
```
Full schema: /openapi/v1/refunds.json
# Check a collection's status (/docs/api/v1/transaction-status/get-transaction-status)
Returns the current status (`Paid`, `Unpaid` or `Refunded`) of a collection made through Checkout or Direct Receive Money. Use it when you have not received a final callback within 5 minutes, or to reconcile before fulfilling. Look up by `clientReference`, `hubtelTransactionId` or `networkTransactionId`.
`GET https://api-txnstatus.hubtel.com/transactions/{accountNumber}/status`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `clientReference` | query | Yes | The client reference of the transaction specified in the request payload. |
## Response 200: Business result in ResponseCode: `0000`, `4000`. See the response code table.
```json
{
"message": "Successful",
"responseCode": "0000",
"data": {
"date": "2024-04-25T21:45:48.4740964Z",
"status": "Paid",
"transactionId": "7fd01221faeb41469daec7b3561bddc5",
"externalTransactionId": "0000006824852622",
"paymentMethod": "mobilemoney",
"clientReference": "inv0012",
"currencyCode": null,
"amount": 0.1,
"charges": 0.02,
"amountAfterCharges": 0.08,
"isFulfilled": null
}
}
```
Full schema: /openapi/v1/transaction-status.json
# Look up a phone number's registered name (/docs/api/v1/verification/look-up-msisdn-name)
Returns the name a Ghanaian phone number is registered to, through the commission services host. Use the returned name to confirm the recipient before submitting a top-up.
`GET https://cs.hubtel.com/commissionservices/{accountNumber}/3e0841e70afc42fb97d13d19abd36384`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `destination` | query | Yes | The customer's phone number. Accepted formats: 0XXXXXXXXX / 233XXXXXXXXX E.g.: "0249111411" / "233249111411" |
## Response 200: Success.
```json
{
"ResponseCode": "0000",
"Message": "Customer Details",
"Label": "Customer Details",
"Data": [
{
"Display": "name",
"Value": "JOHN DOE",
"Amount": 0
}
]
}
```
Full schema: /openapi/v1/verification.json
# Look up a wallet's registered name (/docs/api/v1/verification/verify-mobile-money-wallet)
Returns whether a number is a registered mobile money wallet and the name it is registered to. Use it to confirm a recipient before a payout, or to reduce payment prompts to wrong numbers.
`GET https://rnv.hubtel.com/v2/merchantaccount/merchants/{accountNumber}/mobilemoney/verify`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `channel` | query | Yes | The mobile money channel provider. Available channels are: mtn-gh vodafone-gh tigo-gh |
| `customerMsisdn` | query | Yes | The customer’s mobile money number. Accepted formats: 0XXXXXXXXX / 233XXXXXXXXX E.g.: "0249111411" / "233249111411" |
## Response 200: Business result in ResponseCode: `0000`, `4000`. See the response code table.
```json
{
"message": "Success",
"responseCode": "0000",
"data": {
"isRegistered": true,
"name": "JOHN DOE",
"status": "active",
"profile": "Subscriber"
}
}
```
Full schema: /openapi/v1/verification.json
# Validate a Ghana Card (/docs/api/v1/verification/verify-ghana-card)
Checks a Ghana Card number with the National Identification Authority and returns the holder's details when it matches. Use it to onboard customers for regulated products such as loans.
`POST https://rnv.hubtel.com/v2/merchantaccount/merchants/{accountNumber}/ghanacard/verify`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"ghanaCardNumber": "GHA-000000000-0",
"surname": "Doe",
"firstnames": "John",
"gender": "male",
"dateOfBirth": "dd/mm/yyyy"
}
```
## Response 200: Success.
```json
{
"message": "Success",
"responseCode": "0000",
"data": {
"isValid": true,
"score": "100%"
}
}
```
Full schema: /openapi/v1/verification.json
# Validate a Voter ID (/docs/api/v1/verification/verify-voter-id)
Checks a Voter ID card number and returns the holder's details when it matches. Use it when your verification process requires Voter ID details.
`POST https://rnv.hubtel.com/v2/merchantaccount/merchants/{accountNumber}/voteridcard/verify`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
## Request example
```json
{
"voterIdCardNumber": "0000000000",
"surname": "Doe",
"othernames": "John",
"sex": "male",
"dateOfBirth": "yyyy/mm/dd"
}
```
## Response 200: Success.
```json
{
"message": "Success",
"responseCode": "0000",
"data": {
"isValid": true,
"score": "100%"
}
}
```
Full schema: /openapi/v1/verification.json
# Verify an ID with customer consent (/docs/api/v1/verification/verify-id-with-consent)
Verifies a Ghana Card or Voter ID through the mobile network (MTN) with the customer's consent by USSD. The customer approves sharing their details on their phone before the result is returned.
`GET https://rnv.hubtel.com/v2/merchantaccount/merchants/{accountNumber}/idcard/verify`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `idtype` | query | Yes | |
| `idnumber` | query | Yes | The customer's MTN number. Accepted formats: 233XXXXXXXXX and 0XXXXXXXXX |
| `network` | query | Yes | |
| `consentType` | query | No | The preferred consent type. Options include: 1. sms 2. ussd |
## Response 200: Success.
```json
{
"message": "Success",
"responseCode": "0000",
"data": {
"name": "JOHN DONATUS MILLS",
"dateOfBirth": "1984 June 23",
"gender": "MALE",
"nationalId": "GHA-000000000-0"
}
}
```
Full schema: /openapi/v1/verification.json
# Look up a bank account name (/docs/api/v1/verification/verify-bank-account)
Returns the account holder's name for a bank code and account number. Compare it with the name your customer gave you before paying out.
`GET https://rnv.hubtel.com/v2/merchantaccount/merchants/{accountNumber}/bank/verify/{bankCode}/{accountNumber2}`
## Parameters
| Name | In | Required | Description |
|---|---|---|---|
| `accountNumber` | path | Yes | Your **collection account number** (POS sales), where customer payments land. Find it in your Hubtel merchant account under [Programmable keys → Account ID](/dashboard/account-ids). In the sandbox, use the collection account in Workbench. |
| `bankCode` | path | Yes | The recipient bank's GhIPSS code, for example `300304` for GCB Bank or `300312` for Ecobank. See the [full list of bank codes](/docs/guides/payouts#bank-codes). |
| `accountNumber2` | path | Yes | |
## Response 200: Business result in ResponseCode: `0000`, `4000`. See the response code table.
```json
{
"message": "Success",
"responseCode": "0000",
"data": {
"name": "JOHN DOE"
}
}
```
Full schema: /openapi/v1/verification.json