State Combinations
State combinations cases.
Understanding the various possible combination of Payment Transactions that are in the attempted
state with the Payment-Attempts states is crucial. Let's simplify them:
For the payment transactions that allow multiple attempts, we encounter two combinations:
When a Payment Transaction is in the
attempted
state, and the Payment-Attempt state iscanceled
orfailed
, the payment transaction state remainsattempted
. That means the transaction is open for another attempt until it either expires (i.e.,expired
state) or successfully reaches thepaid
state. In simple terms:attempted
state for payment transaction ➕canceled
orfailed
state for payment attempt ➡attempted
state for payment transaction, until it changed toexpired
orpaid
, and the payment transaction can be attempted againAlternatively, when a Payment Transaction is in the
attempted
state and the Payment-Attempt succeeds (i.e.,success
state), the payment transaction progresses into thepaid
orauthorized
state. In simple terms:attempted
state for payment transaction ➕success
state for payment attempt ➡paid
orauthorized
state for payment transaction.
For the payment transactions that do not allow multiple attempts:
Such transactions do not have an
attempted
state. Instead, they can either be in afailed
orauthorized
state.
The following image sums it all up clearly:
