Skip to content

Sales

Set up your service for selling airtime and data through Moolre.

The Sales endpoints let you sell airtime and mobile data bundles on MTN, Telecel, and AT, paid from your Moolre wallet. Add top-ups to your app, reseller platform, or customer service tools.

Before you begin: Before using the Airtime or Data Sales APIs, you must create a Sell on Our Platform Service in the Moolre App. Open the Moolre App.

Sales workflow

Set up your sales service once, then treat Sales Status as the source of truth for whether each sale was delivered.

  1. Set up sales serviceCreate a Sell on Our Platform Service and link the wallet you will sell from.
  2. Pick a bundleData only: look up the bundle ID and price for the network.
  3. Send the saleSell airtime or the chosen data bundle from your wallet.
  4. Confirm outcomeCheck the final status before retrying or reporting delivery.

Sales APIs

Each card opens the request contract, examples, and Try It panel for that endpoint.

Handle pending sales

ASL11 means a sale is in progress, not that the airtime or data has been delivered. ASL06 is an uncertain outcome: the sale may still have gone through. Treat both as unfinished until Sales Status returns a final result.

Check the sale with Sales Status before retrying. Look it up with idtype 1 and the original externalref (or extid), using the same paying wallet accountnumber. Never generate a new external reference to resubmit a pending or uncertain sale.

Try It requests in Live mode make a real purchase from the selected wallet. Other replies from the sales server are returned unchanged; do not assume delivery for any code not documented on the endpoint page.

Sell motor insurance

Insurance agents can also sell motor insurance through the Sales APIs: new motor policies, paid from the agent wallet in GHS. Renewals are not available at the moment.

Insurance is sold from a wallet that Moolre has registered as an insurance sales agent. Register it in the Moolre App (create a Sell on Our Platform service, choose the Insurance product and link your GHS wallet) or contact Moolre Support; the accountnumber you send must be your own GHS wallet.

List the covers, find the vehicle (from its VIN, or by make and model), quote the cover for the start date and seats, then sell the policy with the quoted premium and a unique externalref. Confirm the result with Sales Status. The motor insurance guide walks through the whole flow with code.

The wallet is charged the full premium. If the premium is not the current price the sale is refused with IS10 and nothing is charged: quote again. Renewals (type 2) are not available at the moment: they are refused with IS18 and nothing is charged.

You earn a 10% commission on an issued policy. It is paid to the same wallet as a separate credit after the policy is issued; if it cannot be paid straight away it stays pending and is paid later.

A policy can take up to a minute to confirm. IS21 and ASL11 mean it is still being confirmed, not that it failed. After a timeout, ASL06 or IS30 the sale may still have gone through. Never resend with a new externalref: check Sales Status with idtype 1 and the original externalref. Only txstatus 2 means the policy was not issued and the charge was refunded, so a new purchase is safe.

Choose a data bundle

Data sales need a bundle ID instead of an amount. Call Bundles for the recipient's network, then pass the returned bundle value unchanged to the Data API with the matching network as channel. The bundle price determines what the wallet is charged, so do not send amount.

Bundles response keys map to sale channels: mtn → MTN, telecel → TELECEL, at → AT. Legacy numeric values are also accepted (1 = MTN, 6 = Telecel, 7 = AT); send them in network for Bundles and in channel for sales. An empty network array means no bundles are currently listed for that network.

Sale outcomes

Sales Status returns data.txstatus with one of these values. See Sales Status for the lookup request and application codes.

Sales transaction status meanings
txstatusOutcomeMeaning
0PendingThe sale is not yet final. Check its status again before deciding what to do next.
1SentThe airtime or data sale was sent.
2Failed and refundedrefundid identifies the refund transaction.
3Not foundNo sale was found for this lookup in the selected wallet. Check the wallet, identifier type, and identifier.