Skip to main content
Two shapes: the customer is present and pays a link, or they’re not and you charge under a COLLECT contract they approved once. No card or method parameters in either — Atoa settles with the method on file.
  • expiresIn (milliseconds) shortens the link’s window; an unpaid link reads back EXPIRED.
  • Cancel an unpaid link with payment.cancel(paymentRequestId)CANCELLED, reason MERCHANT_CANCELLED.
Sandbox: open the link, choose the Atoa Test Bank, and pick the outcome — COMPLETED, FAILED, or PENDING. Cancelling on the bank page gives CUSTOMER_CANCELLED.

Off-session — under a COLLECT contract [#off-session]

The customer approves the contract (and links a payment method) once at its authorizationUrl. After that you charge under the contract while they’re away — pass the contractId, never a payment method.
Atoa enforces the limits on every charge. Check headroom before charging instead of probing with a failure:

SCA on a charge

An off-session charge doesn’t settle on its own. It returns an approval action — nextAction (TS) / next_action (Python) — and the customer approves on Atoa’s page with a one-time code or a passkey. Your app never sees the credential.
To keep the approver in your own web UI, embed the approval with the Approvals SDK instead of sharing the URL — pass nextAction.clientSecret to confirmApproval. Declined reads back FAILED with failureReason: APPROVAL_DECLINED; lapsed, APPROVAL_EXPIRED — returned on the Payment, not thrown. In sandbox, open the approvalUrl and force whichever decision you want to test.

Refunds

Refund a COMPLETED collect, in full or in part. A refund moves INITIATED → COMPLETED (or FAILED).
A pending refund can be cancelled with cancelRefund(refundId). Sandbox: set reason to "FAILURE TEST" to force a FAILED refund and exercise that branch.