Representing a Primer Validation Error. External input to our components will always undergo data validation to ensure accuracy and reliability.

12345
data class PrimerValidationError(  val errorId: String,  val description: String,  val diagnosticsId: String)
kotlin
copy

Properties

errorId
StringRequired
A unique error identifier.
description
StringRequired
A error description.
diagnosticsId
StringRequired
A unique diagnostics id for the given error.

Exposed Error IDs

Payment Component Errors

Klarna Component

Error IDDescription
session-not-createdSession needs to be created before payment category can be collected.
invalid-payment-categoryPayment category is invalid.
payment-already-finalizedThis payment was configured to finalize automatically.

Banks Component

Error IDDescription
banks-not-loadedBanks need to be loaded before bank id can be collected.
invalid-bank-idBank id doesn't belong to any of the supported banks.

Nol Pay Components

Error IDDescription
invalid-otp-codeOTP code is not valid.
invalid-phone-numberFailed to parse phone number.
invalid-card-numberCard number cannot be blank.