Skip to main content
Paymend specializes in recovery of payments that have already failed authorization. Whether a payment is one-time or recurring: when you receive a decline from your primary payment provider, simply re-route it to Paymend and we’ll take care of the rest. It is not always possible to recover a failed payment immediately. In these cases, merchants can safely leave the payment with Paymend, confident that it will be handled by a platform designed to maximize the chance of eventual approval.
Asynchronous processing is required. Every Paymend integration must handle PENDING payments, and we strongly recommend webhooks for tracking them. An integration that only handles immediate results limits the value of the platform. See the integration checklist.
Our recovery engine evaluates each failed payment using a rich set of signals and dynamically selects the optimal recovery strategy. In certain scenarios, this means intentionally waiting before attempting the payment again. A common example is an insufficient funds decline: retrying immediately is unlikely to succeed, so Paymend schedules a retry for when we expect the cardholder to have available balance again.

Merchant-initiated payments

Paymend only retries a payment later, or returns PENDING for it, when the payment is merchant-initiated: send source.initiatedBy: "MERCHANT" for rebills, subscription renewals and any other charge made without the cardholder present. A payment sent with source.initiatedBy: "CONSUMER" always gets a final result (AUTHORIZED, CAPTURED or FAILED) in the create response, because the cardholder is waiting for it. Paymend doesn’t schedule retries for these payments, and a timeout returns FAILED instead of PENDING.
source.initiatedBy is required on every payment.

Pending payments

When Paymend requires additional time to process a merchant-initiated payment, we respond to the payment creation request with a PENDING status. A PENDING status means:
  • The payment has been successfully created
  • No final authorization decision has been made yet
  • Paymend is actively managing recovery attempts: an attempt is either in flight or scheduled
PENDING doesn’t necessarily mean an attempt has already failed. Attempt timing depends on the payment, including any decline reasons, and usually ranges from a few hours to a few days. PENDING is always a temporary state. Without any further action from the merchant, the payment will eventually transition to one of the following final statuses:
  • AUTHORIZED
  • CAPTURED
  • FAILED
Paymend will never hold a payment in a non-terminal state indefinitely: we enforce a maximum recovery window of 30 days for all payments. If recovery is not successful within this window, the payment is marked as FAILED and no further attempts are made. Either way, we send the matching webhook. The 30-day window is fixed, and there is no per-payment deadline field. To stop recovery earlier, void the payment while it is PENDING. You can see the lifecycle for payments with Paymend here.

Best practices for PENDING payments

While a payment is in PENDING state with Paymend, merchants may continue to attempt recovery outside of Paymend. To avoid conflicts or double charges, please follow these rules:
  1. Do not retry the same payment via Paymend while it remains in PENDING state.
  2. If circumstances change such that no further authorization attempts should be made for a PENDING payment (for example, the order is canceled or the consumer is successfully charged elsewhere), the payment with Paymend must be voided to prevent a double charge.
If a retry attempt is in progress when you send the void, the void fails, and Paymend may already have recovered the payment. See Voids for what to do next, including when to refund.
Void a PENDING payment

Webhooks

Webhooks are the recommended way to learn the outcome of a PENDING payment (for example, when it moves from PENDING to AUTHORIZED). Polling the query endpoint is possible but not recommended: a payment can stay PENDING for up to 30 days, and the delay before you see a status change risks double charges. You can find more details on Paymend webhooks here. Payment status update via webhook

Previous failure details

The more information you can provide about previous attempts to process a payment, the more effectively Paymend can recover it. Paymend supports a PreviousFailure object that allows you to pass details about earlier attempts and their failure reasons. This information helps route the payment onto the most effective recovery path more quickly. For each earlier attempt:
  • Put the decline code in providerFailureCode exactly as your processor returned it (for example NMI 201, 202, 253). Don’t map it to your own codes.
  • Set provider to one of Paymend’s normalised provider names. Ask your Account Manager for the list.
For retries of declined recurring subscriptions for digital goods, send goodsType: "DIGITAL" as well as source.initiatedBy: "MERCHANT" (see Merchant-initiated payments).

Integration checklist

Every Paymend integration must:
  • Send source.initiatedBy on every payment: MERCHANT for rebills, subscription renewals and any other charge without the cardholder present, CONSUMER otherwise. Only MERCHANT payments are retried later (see Merchant-initiated payments)
  • Handle PENDING as a non-terminal state, and not retry the payment while it is PENDING
  • Void PENDING payments if no further authorization attempts should be made
  • Handle create timeouts without creating duplicate payments (see Timeouts and retries)
We also strongly recommend that you:
  • Receive and acknowledge webhooks, dropping duplicates by eventId, rather than polling for status changes
  • Provide PreviousFailure data where available