> ## Documentation Index
> Fetch the complete documentation index at: https://primer.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# PrimerError

> Error class containing payment and SDK error details

<Warning>
  Primer Checkout Android SDK is currently in **beta** (v3.0.0-beta.4).
  The API is subject to change before the stable release.
</Warning>

Error class carried by [`PrimerCheckoutState.Failure`](/docs/sdk/android-checkout/v3.0.0-beta/api/primer-checkout-state). Contains error details and a diagnostics ID for Primer support.

## Definition

```kotlin theme={"dark"}
class PrimerError {
    val errorId: String
    val description: String
    val errorCode: String?
    val diagnosticsId: String
    val recoverySuggestion: String?
}
```

## Properties

| Property             | Type      | Description                                                                                               |
| -------------------- | --------- | --------------------------------------------------------------------------------------------------------- |
| `errorId`            | `String`  | Unique error identifier for programmatic handling                                                         |
| `description`        | `String`  | Human-readable error message (suitable for logging)                                                       |
| `errorCode`          | `String?` | Specific failure reason (e.g., `"card_declined"`, `"insufficient_funds"`). `null` for non-payment errors. |
| `diagnosticsId`      | `String`  | Unique diagnostics ID. Provide to Primer support when investigating issues.                               |
| `recoverySuggestion` | `String?` | Suggested recovery action. `null` when no recovery applies.                                               |
