Transaction Lifecycle & Statuses

Understand the discrete states that each payment order traverses from creation to final on-chain settlement, along with terminal event webhooks.

Transaction state transitions

Every customer transaction moves through a defined state machine:

StatusClassificationMeaning & State Description
CreatedIntermediateOrder created in database; checkout session active and awaiting customer payment.
PendingIntermediatePayment transfer has been detected on the blockchain; node watchers are awaiting required block confirmations.
SuccessTerminalPayment is fully confirmed on-chain. Merchant balance is credited; dispatches transaction.success webhook.
ExpiredTerminalThe 15-minute rate quote window lapsed without payment; dispatches transaction.expired webhook.
FailedTerminalBlockchain transaction execution failed or reverted on-chain.
CancelledTerminalOrder was explicitly cancelled prior to payment completion.
InvalidTerminal (Exception)Payment was received with mismatched parameters (e.g. underpayment or wrong token); triggers ops manual review.

Exception handling & ops manual review

When a customer accidentally underpays or transfers an unsupported token, the order is flagged as Invalid with manual_review: true. Hashpay operations engineers review the exception queue:

  • If the customer settles the remainder, the operator marks the order settled, dispatching a delayed transaction.success event with manual_review: true.
  • If the customer requests a return, the funds are refunded directly to the sender address on-chain.