Do these 3 things before closing this tab:
1Scan for outdated or missing drivers - takes under a minute2Repair Windows errors before they cause bigger problems3Fix the driver behind crashes, sound loss and screen glitchesAn idempotency key can help your application avoid treating a repeated request as a new payment instruction. It cannot tell you whether M-Pesa completed a request when its result is still pending or a callback never arrived. In M-Pesa integrations, de-duplicating requests and reconciling transaction outcomes are separate jobs.
That distinction matters because Safaricom describes its APIs as asynchronous: results can arrive through callback or result URLs, and a separate Transaction Status request can be used when a callback is missing. The design lesson is not that idempotency is unhelpful; it is that it answers a different question.
As an Amazon Associate I earn from qualifying purchases.
What idempotency does—and what it cannot tell you
An idempotency key is an identifier your application uses to recognize repeated submissions as the same intended operation. Safaricom gives a concrete example for B2C: the merchant-generated OriginatorConversationID must be unique for each request to avoid double disbursement, and can be used to query status before another disbursement. See Safaricom’s B2C documentation.
Recommended Free Tools
That identifier helps protect the request boundary. It does not, by itself, prove the provider-side outcome. If your application submits a request and records the identifier, but the response is delayed or the callback is absent, you may still not know whether the transaction completed. Safaricom documents asynchronous results and a separate status-query mechanism; a submission acknowledgement should not be treated as the final transaction result.
#1 Best Overall
- Use the, easy-to-use, and customizable POS to get started.
- Accept contactless payments, chip cards, Apple Pay, and Google Pay from anywhere, with improved connectivity, extended battery life, and enhanced security. Pay one low rate for every tap or dip.
- No long-term commitments or contracts, no monthly fees- and with offline payments, keep taking payments for up to 24 hours.
- Safely and securely accepts payments anywhere. Plus, get data security, 24/7 fraud prevention, and payment-dispute management at no extra cost.
- Use the, easy-to-use, and customizable POS to get started.
Keep these questions separate:
- Did we already accept this instruction? Use your own request record and unique merchant identifier to avoid creating a second operation for a retry.
- What happened to the provider transaction? Use the callback/result and, when needed, a provider-side status or transaction-record check.
Why callbacks leave an unresolved state
Safaricom says API responses are delivered to callback or result URLs. Its Getting Started documentation warns that if the server is unavailable, a 503 may be logged and results discarded. That makes callback handling an operational dependency: an absent callback is not evidence that a payment failed, just as a request acknowledgement is not evidence that it succeeded.
The documentation does not establish exactly-once callback delivery, automatic callback retries, a delivery window, or event ordering. Do not build a reconciliation policy around any of those assumptions. Instead, treat the callback as one channel for learning the outcome, and keep a way to investigate transactions whose outcome remains unknown.
Rank #2
- Get your money as soon as the next business day.
- Get set up quickly with no long-term commitments. Download the Square Point of Sale app for free, create an account, and start taking payments anywhere.
- Run your business all in one place with the free Square Point of Sale app. Track your sales, manage inventory, accept tips, send receipts digitally, and more.
- Works with Apple devices with a Lightning connector.
Which M-Pesa mechanism answers which question?
| Mechanism | What it helps answer | What it does not settle |
|---|---|---|
| Merchant request identifier or idempotency key | Whether your application has already accepted the same intended operation. Safaricom specifically links a unique B2C OriginatorConversationID to avoiding duplicate disbursement. |
It does not independently establish the final provider-side outcome if an asynchronous result is missing. |
| Callback or result URL | Delivers an asynchronous outcome to your application. | A callback receiver can be unavailable; Safaricom warns an unavailable server may result in a logged 503 and discarded results. The documentation does not establish delivery guarantees or ordering. |
| Transaction Status | Provides a secondary reconciliation mechanism when a callback is absent. Safaricom says a query can use an M-Pesa receipt number or an Originator Conversation ID. | The query is itself asynchronous and requires one of those identifiers. See the Transaction Status documentation. |
| C2B Pull Transaction API or M-PESA Organization portal | Offers additional ways to address failed C2B notifications and review account-side transaction information. | The reviewed documentation does not establish every retrieval limit or window. Check current production guidance for your integration. See Safaricom’s C2B documentation. |
How to design the reconciliation path
The following is engineering guidance for an asynchronous payment flow, not a Safaricom-mandated database, queue, or retry policy.
The Tool Desk
Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →- Record the instruction before sending it. Store your internal payment reference, the merchant-generated request identifier, the intended operation, and a state showing that the outcome is not yet confirmed. Enforce uniqueness for the request identifier so a client retry cannot silently create a second instruction.
- Keep submission separate from settlement. Record the API submission response as an acknowledgement or submission event, not as proof of final success. Leave the payment unresolved until an outcome is obtained.
- Receive and persist callback events safely. Save each received event before acknowledging it to your own processing flow. Make the handler safe to run more than once so repeat processing does not repeat side effects such as fulfilling an order. These are resilience practices, not guarantees about Safaricom callback delivery.
- Retain lookup identifiers. Keep the M-Pesa receipt number when one is available, as well as the merchant request identifier or Originator Conversation ID. Transaction Status lookup uses a receipt number or Originator Conversation ID, according to Safaricom’s documentation.
- Make uncertainty visible. Model a state such as unresolved or pending confirmation separately from completed and failed. “No callback yet” should not be automatically converted into either success or failure.
- Reconcile aged unresolved records. Use the documented Transaction Status mechanism to investigate missing or delayed callbacks. For C2B notification failures, Safaricom also points to the Pull Transaction API or the M-PESA Organization portal. Track which records were checked and what provider-side outcome was returned.
- Alert on operational backlogs. Monitor callback receipt and processing delays, and surface unresolved transactions for review. This is an application-level recommendation; Safaricom’s documentation does not prescribe a particular monitoring system.
What changes for C2B and B2C
C2B: payment notifications and retrieval options
Safaricom’s C2B documentation describes confirmation URLs for successful payment notifications. For failed notifications, it identifies the Pull Transaction API or checking the M-PESA Organization portal as ways to address the gap. This gives C2B integrations options beyond waiting for the original notification, but the documentation cited here does not specify every operational limit or retrieval window. Use current production documentation for those details.
Rank #3
- Pay one transparent rate per swipe for Visa, Mastercard, Discover and American Express.
- Works in conjunction with most downloadable Square point-of-sale apps on your device. Customers can pay, tip and sign directly on your device. Track payments in cash, gift cards and more. Also lets you send receipts via e-mail or text message, makes it easy to apply discounts, keeps a data and sales history log and more.
- Accepts magstripe credit card payments, including those from Visa, Mastercard, Discover and American Express (fees apply).
- App sends deposits to your bank account within 1 to 2 business days, or enjoy instant deposits (fees apply).
B2C: guard against a second disbursement
For B2C, Safaricom says the merchant-generated OriginatorConversationID should be unique for every request to avoid double disbursement. It can also be used to query status before another disbursement. That makes the identifier especially important when an outcome is uncertain: do not treat a timeout or missing callback as permission to issue a fresh disbursement under a new identifier without first checking status.
Test the gaps, not just the happy path
Safaricom’s developer portal describes sandbox testing with predetermined scenarios, API-performance reporting, transaction details, and a review process before a service goes live. Use the sandbox to validate your own duplicate-request handling, callback processing, and unresolved-payment workflow, but do not assume its scenarios reproduce every production fault. The portal’s API catalog and the M-Pesa Business INFO Portal’s developer information describe the testing and reporting context.
Rank #4
- 【2-in-1 CAC & NFC Smart Card Reader】2-in-1 contact and contactless card reader equipped with integrated USB-A & USB-C dual-head cable. Supports CAC, PIV, military ID, chip credit/debit cards and NFC ID badges. Only one reading mode can be activated at a time to guarantee stable data reading. No extra adapter required for different device ports.
- 【Full Certification & Broad Card Support】 Certified FCC, CE, VCCI, CCID and Microsoft WHQL. Contact interface follows ISO7816 Class A/B/C with T0/T1 protocol; NFC module supports ISO14443 A/B and MIFARE. Compatible with SLE, AT88SC memory smart cards, meeting PC/SC 2.0 and EMV standards for high-security military and government authentication.
- 【Plug & Play Multi-OS Reader】No driver needed for immediate use. Works on Windows, mac OS, Linux and Android devices. Standard CCID hardware compatible with common card management tools. Please be aware that third-party decoding software and official card middleware are not included in the package.
- 【Durable & Travel-Friendly Construction】Comes with 95cm reinforced strain-relief cable, LED light and buzzer prompt. Compact lightweight body supports USB 2.0 480Mbps high-speed transmission. Perfect for daily office, business trips and field identity verification for military and government users.
- 【Application & Reliable After-Sales Service】Great for tax declaration, pension inquiry, vehicle registration and access control. ❗Not compatible with health insurance cards. Package: 1×Smart Card Reader, 1×User Manual. 24-month warranty and lifetime technical support; free return for quality defects.
- Submit the same intended request twice and confirm your application does not create a second operation.
- Exercise callback handling when your listener is unavailable or cannot process an event, then verify that the payment remains visible for reconciliation.
- Check that a transaction can be looked up using the identifiers your application actually retains.
- Confirm that an unresolved record is not automatically treated as paid, failed, or safe to retry.
Sandbox scenarios are useful validation, not proof that every production failure mode has been covered. Keep production monitoring and reconciliation as part of the payment design.
Quick Recap
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




