Airwallex logo

Transaction lifecycle (Beta)

The three-level Issuing model - lifecycles, card transactions, and transaction events - plus billing amounts, status, fund direction, and how card transaction state changes.

Copy for LLMView as Markdown

The Issuing transaction APIs use three levels of categories to represent card payment activity: lifecycles, card transactions, and transaction events. Understanding this model is important when you reconcile transactions, handle inquiries and disputes, or build reporting and operations workflows, as it helps you choose the right API and interpret statuses and fund movements correctly.

Three-level transaction model

Airwallex structures transaction data in three layers, from the broadest (network-level grouping) to the most granular (individual events):

LevelDescriptionWhen to use it
LifecycleA container of all related transaction events and one or more card transactions, based on network-provided information.When you need a network-level view of a payment story and want to build your own UI or grouping (for example, using lifecycle_id with transaction events).
Card transactionA container of related transaction events with Airwallex's interpretation of a single card transaction. It has a guaranteed terminal status.When terminal statuses matter and you prefer not to implement your own grouping logic.
Transaction eventA single network message or Airwallex fund movement. The most granular unit; fund movement per event is immutable.When you need per-event detail (for example, failure reason, type, subtype such as partial authorization).
  • Lifecycles have no status; matching is best-effort and depends on the network and acquirers. A lifecycle can include matched refunds and does not have a guaranteed terminal state.
  • Card transactions always reach a terminal state (CLEARED, REVERSED, EXPIRED, DECLINED, or VERIFIED). When an authorization is fully cleared, expired, or reversed, no further events are added to that card transaction. Refunds always form a new card transaction but can be linked via lifecycle_id.
  • Transaction events have no status; each event has a lifecycle_id and card_transaction_id so you can trace it to its containers.

Lifecycle

A lifecycle groups related card transactions and transaction events. It begins with a network message represented as a transaction event.

Typical first messages include:

  • Authorization request (most common) - when a merchant requests approval to use the card.
  • Financial transactions - standalone financial messages such as ATM withdrawals or forced captures.
  • Refunds - unmatched refunds start a new lifecycle; matched refunds attach to an existing lifecycle.

With a lifecycle_id, you can retrieve the related card transaction IDs and transaction event IDs. Matching is done on a best-effort basis and depends on the network and acquirers providing the identifiers Airwallex needs.

Billing amounts aggregation

The billing_amounts object in the API holds aggregated totals that are updated as transaction events arrive. It appears at two levels: lifecycle (rolled up across everything on that lifecycle) and card transaction (amounts for a single card transaction).

At the lifecycle level: billing_amounts aggregates amounts across all card transactions and transaction events that belong to that lifecycle. One lifecycle can span multiple card transactions (for example, a purchase and a later refund). The lifecycle-level aggregation gives you a single view of total authorized, debited, credited, declined, expired, pending, and reversed amounts for the whole payment story, so you can reconcile or display net position without summing individual card transactions yourself.

At the card transaction level: billing_amounts aggregates amounts only for that single card transaction. It is an up-to-date snapshot of the totals for every transaction event in that card transaction (authorizations, clearings, reversals). Use it to derive the card transaction status and to understand how much is reserved, debited, or credited for that transaction alone.

The following fields appear in billing_amounts (at either level, with the same meaning):

FieldMeaning
total_authorizedTotal amount authorized.
total_creditedTotal amount credited to the account (for example, refunds).
total_debitedTotal amount debited from the account (for example, cleared transaction).
total_declinedTotal amount declined.
total_expiredTotal amount expired after authorization.
total_pendingTotal authorization amount still pending.
total_reversedTotal amount reversed by reversal request.

Card transaction

A card transaction groups related transaction events and represents Airwallex's interpretation of one card transaction. It usually starts with a network message as well.

Typical first messages include:

  • Authorization request (most common) - when a merchant requests approval to use the card.
  • Financial transactions - when there is no matching outstanding authorization, or the matching authorization has been fully cleared or reversed; a new card transaction is created.
  • Refunds - every refund (both matched and unmatched) is a new card transaction.

Later messages that attach to the same card transaction include:

  • Incremental authorization - increase to the authorized amount.
  • Single or multiple financial transaction advices - single or multi-capture clearing.
  • Reversal request - cancellation of a previously approved authorization (release of the reserve).

Each card transaction has exactly one lifecycle_id. Multiple card transactions can share the same lifecycle_id, indicating they are related (for example, original purchase and refund).

Billing amounts aggregation applies to both lifecycles and card transactions. The following subsections focus on card transaction behavior: status, fund direction, and how status changes are determined using fund direction and billing totals.

Card transaction statuses

Only card transactions have a status. Possible statuses and whether they are terminal are:

StatusDescriptionTerminal
AUTHORIZEDThe authorization has been approved.No
VERIFIEDThe $0 authorization has been verified.Yes
CLEAREDClearing is complete; funds have moved from the customer's wallet.Yes
REVERSEDA previously approved authorization was reversed; funds are released.Yes
EXPIREDThe authorization expired (for example, no clearing in time); reserved funds are released.Yes
DECLINEDThe authorization was declined by Airwallex or the scheme.Yes

Fund direction

Each card transaction includes a fund direction that describes the intended movement of funds relative to the wallet.

Fund directionMeaning
DEBITFunds are intended to be debited from the wallet. The wallet is only debited when the transaction is authorized and cleared.
CREDITFunds are intended to be credited to the wallet. The wallet is only credited when the transaction is authorized and cleared.
NO_MOVEMENTNo fund movement is intended.

How state changes are determined

Card transaction state changes are determined by fund direction. Billing amounts aggregation totals (total_pending, total_debited, total_credited, total_expired, total_reversed) show when a transition occurs. The statuses CLEARED, EXPIRED, REVERSED, DECLINED, and VERIFIED are terminal (no further transitions).

When fund direction is DEBIT

This section is for card transactions whose fund direction is DEBIT (funds intended to move out of the wallet). It lists which status values can appear and how status and billing amounts change when authorization, clearing, expiry, reversal, or decline events occur.

Allowed statuses

AUTHORIZED, CLEARED, EXPIRED, REVERSED, DECLINED.

Transition rules

State transitionTriggerAmount change
AUTHORIZEDThe authorization request is approved.total_pending is greater than zero (funds are reserved).
AUTHORIZEDCLEAREDA clearing request is received and processed, debiting the authorized amount.total_pending reaches zero and total_debited increases (reserve is replaced by a debit).
AUTHORIZEDEXPIREDThe authorization time limit passes without a clearing request (merchant did not complete the transaction).total_pending reaches zero and total_expired increases (reserve released without clearing).
AUTHORIZEDREVERSEDA reversal request is received and processed, releasing the authorization reserve.total_pending reaches zero and total_reversed increases (reserve released by reversal).
DECLINEDThe authorization request is declined by Airwallex or the scheme.No funds are reserved or moved; total_declined can increase.

When fund direction is CREDIT

This section is for card transactions whose fund direction is CREDIT (funds intended to move into the wallet). It lists which status values can appear and how status and billing amounts change for credit authorizations, clearing, reversals, or declines.

Allowed statuses

AUTHORIZED, DECLINED, CLEARED, REVERSED.

Transition rules

State transitionTriggerAmount change
AUTHORIZEDThe authorization request is approved for a credit (for example, refund).Funds can be credited when clearing completes.
AUTHORIZEDCLEAREDA refund or credit clearing is processed.total_credited is greater than zero.
AUTHORIZEDREVERSEDA reversal request is processed against the credit authorization or a cleared credit.total_reversed and related credit totals update to reflect the reversal of funds.
DECLINEDThe authorization request is declined by Airwallex or the scheme.No funds are reserved or moved; total_declined can increase.

When fund direction is NO_MOVEMENT

This section is for card transactions whose fund direction is NO_MOVEMENT (no intended wallet movement). It lists which status values can appear and how status and billing amounts change for declines or verification-only flows.

Allowed statuses

DECLINED, VERIFIED.

Transition rules

State transitionTriggerAmount change
DECLINEDThe authorization request is declined by Airwallex or the scheme.No funds are reserved or moved; total_declined can increase.
VERIFIEDA verification request is processed (for example, $0 authorization to validate the card).No fund movement; billing amounts remain unchanged.

Transaction events and scenarios

Each transaction event has a type and optional subtype. Together with card transaction status and transaction_category, they describe the full payment story.

For reference tables (event types, fund movement mapping, transaction_category values) and step-by-step example flows (dual message, partial clearing, refunds, reversal clearing), see:

Real lifecycles can be more complex, with multiple authorizations, partial clearings, and reversals on the same lifecycle_id.

See also

Was this page helpful?