TransactionStatusResult

interface TransactionStatusResult : Parcelable

The result of a com.adyen.ipp.api.InPersonPayments.getTransactionStatus call.

data always contains a NEXO TransactionStatusResponse JSON string, regardless of whether the call succeeded or failed. success indicates the outcome and determines how data should be interpreted.

Success semantics:

  • success == true: the terminal record was found and the NEXO response contains a valid RepeatedMessageResponse with the original payment or reversal body.

  • success == false: the lookup failed. Possible causes include:

    • A transaction is currently in progress (NEXO error condition: UnavailableService).

    • No matching record was found for the given ServiceID (NEXO error condition: NotFound).

    • The stored record is unreadable due to encryption or serialization failure (UnexpectedData).

    • An internal storage error occurred (ResourceNotAvailable). In all failure cases data still contains a well-formed NEXO error response with a Response.Result of Failure and a populated ErrorCondition.

Thread safety: Instances are immutable after creation and may be read from any thread.

Example usage:

val result: TransactionStatusResult = InPersonPayments.getTransactionStatus(request).getOrThrow()
if (result.success) {
val nexoJson = result.data // full NEXO TransactionStatusResponse JSON
} else {
val errorJson = result.data // NEXO error response with ErrorCondition
}

Properties

Link copied to clipboard
abstract val data: String

NEXO TransactionStatusResponse JSON string.

Link copied to clipboard
abstract val success: Boolean

true if the transaction record was found and successfully encoded; false if the lookup failed for any reason. Always check this field before interpreting data.