GatewayErrorCode enum

Stable wire identifiers for gateway-handoff failures.

These are NOT a subset of ReaderErrorCode - the gateway handoff is a distinct architectural layer with distinct failure modes that the POS may want to surface differently (e.g. "we asked the gateway and it said no" vs. "we never reached the gateway"). Renaming a value here is breaking.

Inheritance
Available extensions

Values

unknown → const GatewayErrorCode

Catch-all when no other code fits.

const GatewayErrorCode('unknown')
notConfigured → const GatewayErrorCode

The SDK is in GatewayMode.payloadOnly but something asked the SDK to perform a handoff. Indicates a configuration mismatch on the POS side.

const GatewayErrorCode('not_configured')
payloadInvalid → const GatewayErrorCode

The handoff request was malformed before it left the SDK (e.g. the encrypted payload bridge map was missing a safe-field). Indicates a bug in the transaction-runner; the POS should report this.

const GatewayErrorCode('payload_invalid')
transportError → const GatewayErrorCode

The gateway client threw an exception that does not map to any of the structured codes below.

const GatewayErrorCode('transport_error')
transportTimeout → const GatewayErrorCode

The transport call exceeded GatewayConfig.requestTimeout. Distinct from networkError so the POS can show "took too long" UI.

const GatewayErrorCode('transport_timeout')
backendError → const GatewayErrorCode

The backend responded with a non-2xx HTTP status that the GatewayClient classified as transient (5xx) or non-transient (4xx). The SDK does not retry 4xx on the cardholder's behalf.

const GatewayErrorCode('backend_error')
responseInvalid → const GatewayErrorCode

The backend returned a 2xx response whose body could not be parsed as a GatewayHandoffResponse. Distinct from backendError because the network call succeeded.

const GatewayErrorCode('response_invalid')
cancelled → const GatewayErrorCode

The SDK was torn down (disconnect / cancelTransaction) while the handoff was in flight. The terminal callback resolves to cancelled; this code is informational on the handoff event stream.

const GatewayErrorCode('cancelled')
internalError → const GatewayErrorCode

An unexpected error inside the SDK's gateway layer.

const GatewayErrorCode('internal_error')

Properties

hashCode → int
The hash code for this object.
no setterinherited
index → int
A numeric identifier for the enumerated value.
no setterinherited
name → String

Available on Enum, provided by the EnumName extension

The name of the enum value.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
wire → String
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

fromWire(String? value) → GatewayErrorCode

Constants

values → const List<GatewayErrorCode>
A constant List of the values in this enum, in order of their declaration.