Offline transactions
Because transaction processing runs on the Axium device itself, transactions taken while the device is offline are queued locally and uploaded once connectivity returns. The behaviour is configurable per-transaction via ParameterKeys.OfflineTransactionUploadMode.
Upload Modes
| Mode | Behaviour |
|---|---|
Automatic (default) | A background worker uploads queued offline transactions automatically as soon as the device regains network connectivity. |
Manual | Queued transactions are not uploaded until your application explicitly calls processOfflineRequest() with the transaction's UserReference. |
In Manual mode, your integration is responsible for deciding when offline transactions are processed — useful when you want to batch uploads, defer to a quieter window, or require an operator action before payment data leaves the device.
Environment-Bound Queue
Offline transactions can only be processed by an SDK configured against the same environment in which they were taken. A transaction queued against Staging credentials cannot be uploaded by an SDK currently configured for Live, and vice versa.
If your integration moves between environments (for example, during pilot testing or environment migration), be aware that any offline transactions queued while configured against the old environment will not upload until the SDK is reconfigured back to that environment.
Inspecting the environment of a transaction
To check which environment a queued transaction belongs to, call getTransactionInformation() and read ParameterKeys.Environment from the result.
val info = ChipDnaMobile.getInstance().getTransactionInformation(params)
val txEnvironment = info.getValue(ParameterKeys.Environment)Inspecting the currently configured environment
To check which environment the SDK is currently configured against, call getStatus() and read ParameterKeys.Environment from the result.
val status = ChipDnaMobile.getInstance().getStatus(null)
val configuredEnvironment = status.getValue(ParameterKeys.Environment)If a queued transaction's environment doesn't match the configured environment, either:
- Reconfigure the SDK to match the transaction's environment, then process the offline queue, or
- Leave the transaction queued until the SDK is next configured against the matching environment.
Method Reference
processOfflineRequest(parameters)— Triggers upload of a single queued offline transaction in Manual mode. PassParameterKeys.UserReferenceset to the queued transaction's reference. See the shared Configuration and Utility Methods reference for the full method signature.
