Carrier billing payment retries should follow the provider's documented recovery rules. After a timeout, preserve the original purchase identity and establish what happened before starting another charge. Repeat a charge request only when the provider documents how it prevents duplicate effects for that operation.
This guide addresses recovery after an uncertain charge request in an mVAS purchase or renewal workflow. It proposes implementation and review criteria, rather than claiming that every carrier or aggregator supports the same recovery features.
1. Separate a payment timeout from a declined charge
Consider a digital subscription purchase. Your backend sends a charge request, the connection closes, and the checkout receives no usable result. The provider might have rejected the request, might still be processing it, or might have completed it before the response disappeared.
Microsoft's Retry pattern documentation explicitly describes the risk of an operation succeeding while its response fails to reach the caller. Repeating a non-idempotent operation can then repeat its effects. Applied to carrier billing, this means the absence of a response is insufficient evidence for another charge.
Give the application an explicit unresolved state. Keep it separate from a confirmed decline and from a provider-reported pending state, whose meaning comes from that provider's API. A local timer expiring should record a communication problem without inventing a final payment outcome.
Product owners should approve the customer wording for this state. A useful message explains that the purchase status is being checked and offers a way to revisit it. Avoid saying the payment failed or promising that no charge occurred when neither statement has been verified.
2. Confirm the provider's duplicate-prevention contract
Idempotency means repeated identical requests have the same intended effect as one request. MDN's idempotency reference explains that POST requests are not guaranteed to be idempotent. The HTTP method alone therefore cannot establish that replaying a charge is safe.
Before enabling automatic charge retries, ask the integration team to document the provider's answers to these questions:
- Which charge operations support duplicate prevention?
- Which field identifies a repeated operation, and what is its scope?
- How long does the provider retain that identity?
- Must every payment parameter remain identical during replay?
- What response indicates that the original operation is still processing?
- Which lookup or escalation route resolves an uncertain result?
Do not assume that adding an Idempotency-Key header creates protection. MDN's header documentation labels the feature experimental and non-standard, and explains that supporting servers must document requirements such as key format and expiry. Follow the actual provider contract, including any differently named request identifier.
Distinguish the business purchase from individual transport attempts. As a proposed design, keep one purchase record linked to its attempts and provider references. A fresh network attempt should not silently become a fresh purchase. Conversely, a genuinely new purchase must not inherit an old operation's duplicate-prevention identity.
3. Choose the next action from evidence
Use the following table during connector reviews. These are proposed decision rules. Map each row to the selected provider's documented statuses and capabilities before implementation.
| Evidence available | Recovery action | Condition for another charge request |
|---|---|---|
| Connection timed out and no final outcome is known | Preserve the unresolved purchase and use documented status recovery | Only a documented safe replay or a resolved original outcome permits it |
| Provider reports that processing continues | Wait for supported notification or status lookup | Do not treat elapsed checkout time as permission |
| Provider confirms successful payment | Record success and apply the content-access policy | Do not retry that purchase's charge |
| Provider confirms a terminal rejection | Show the applicable failure and recovery options | A new attempt must follow provider rules and the user's intended purchase |
| Duplicate-prevention identity has expired while outcome remains unknown | Escalate through the provider's resolution process | Do not assume the old identity still prevents another charge |
The distinction between a status lookup and a charge replay matters. A lookup asks what happened; a replay may perform an operation. Record which action each recovery worker is allowed to take.
Keep access decisions separate from retry decisions. The catalogue's guide to when pending carrier payments should unlock digital content covers that related question. Here, the immediate task is to resolve the original charge without accidentally initiating another purchase.
4. Give recovery one owner and a stopping point
Assign one component responsibility for deciding whether to replay a charge. Review browser behaviour, backend jobs and connector libraries so that several layers do not independently repeat the same operation. Support tools should use that same decision path.
For permitted retries, define a finite attempt budget and delays that respect the provider's requirements. Record the next eligible attempt time so that a restarted worker does not immediately exhaust the remaining budget. Treat permanent rejection separately from temporary communication trouble.
For a sustained outage, consider a circuit breaker around the affected connector. Microsoft's Circuit Breaker pattern describes temporarily blocking calls after failures reach a threshold, then allowing limited requests to test recovery. It does not determine whether an earlier payment succeeded.
Scope outage controls to the integration boundary your system can reliably identify. An unavailable route should not automatically stop unrelated routes. Equally, switching an unresolved purchase to another provider can create a separate charge attempt without resolving the original one. Treat such routing changes as explicit decisions requiring evidence, rather than a generic fallback.
5. Test uncertainty and concurrent recovery
A successful sandbox purchase proves little about timeout handling. Build tests around the point where the external action and the local record can disagree. Use provider-supported simulations where available, with controlled application tests for local failures.
Test a lost response after simulated provider success, a worker restart after sending a request, and a late success notification while a recovery worker is checking status. Also test two workers selecting the same unresolved purchase and a customer reopening checkout during recovery.
For each scenario, inspect the purchase record and every outbound charge attempt. Confirm that your local controls prevent competing workers from independently authorizing recovery. If the provider supports idempotent replay, verify the documented behaviour without generalizing that result to other connectors.
Make payment-state updates and local fulfilment repeatable too. A repeated success message should not grant the same subscription period twice. An older unresolved observation should not overwrite confirmed success. Define conflicting-evidence handling explicitly and preserve enough history for investigation.
Acceptance criteria should describe observable behaviour: the purchase identity survives a restart, repeat delivery does not repeat fulfilment, and unresolved records reach a named support queue. These criteria are more useful than a blanket claim that the integration is duplicate-proof.
6. Use a release checklist and avoid misleading shortcuts
Before enabling carrier billing payment retries, complete this practical checklist:
- Attach the provider's replay, status lookup and identity-expiry documentation to the connector review.
- Persist purchase identity and outbound-attempt details before sending a charge.
- Separate unresolved, processing, successful and rejected outcomes.
- Make concurrent recovery workers coordinate through durable application state.
- Set retry limits and escalation ownership for each connector.
- Verify customer messages when the payment outcome remains unknown.
- Test late notifications, worker crashes and expired duplicate-prevention identities.
- Give support a transaction timeline with the evidence behind each decision.
Common mistakes include generating a new purchase reference on every timeout, enabling automatic retries for every server error, and treating a missing lookup result as proof that no payment exists. The last assumption is safe only if the provider explicitly documents that meaning for the lookup and timing involved.
Another mistake is providing an unrestricted support-side recharge button. Support should see why a payment remains unresolved and which documented action is available. For traceability, use the principles in carrier billing support logs that protect subscriber details.
Start with one connector. Produce a short recovery specification containing its state mapping, permitted replay conditions, stopping rules and test evidence. Have the product owner approve the customer journey and the integration owner verify the provider mapping. Expand the policy only after those decisions are concrete for the next connector.
India
UAE
KSA
USA
UK
Canada
Oman
Kuwait
Australia
Thailand