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

# Error Handling in Europe

> Learn about error handling in Europe.

<h2 id="_types_of_error_handling">
  Types of error handling
</h2>

Marqeta offers several functionalities to aid you in the event of system failure. These cover a range of products, such as Just-in-Time (JIT) Funding gateway and webhook processing failure. We provide the means to stand in on your behalf or the option to resend webhooks that you have not processed.

<h2 id="_commando_mode">
  Commando Mode
</h2>

Commando Mode is a fallback measure that ensures Gateway JIT-funded cards continue to function in the event that your system fails. If your system cannot respond to the JIT Funding request, the Marqeta platform makes a decision in your place, based on defined business rules. Commando Mode details are outlined below.

* **Manual Commando Mode** – Manually activated by the API or the Marqeta Dashboard.

  * Approves all transactions on your behalf for the specified time duration.

  * Used for a period of known downtime.

  * Follows `standin_approved_by` = `COMMANDO_MANUAL`.

* **Automated Commando Mode** – Automatically enabled or disabled on a per-transaction basis.

  * Follows `real_time_standin_criteria.enabled` = `true`.

    * `include_connection_errors` – Unable to establish connection to your endpoint.

    * `include_response_timeouts` – Gateway response slower than 3000ms.

    * `include_application_errors` – An application error (any non-connection, non-timeout error).

    * `standin_approved_by` = `COMMANDO_AUTO`.

For more information, see [Commando Mode](/core-api/commando-mode/).

```json JSON lines wrap theme={null}
{
  "transactions": [
    {
      "type": "authorization",
      "state": "DECLINED",
      "response": {
        "code": "0000",
        "memo": "Approved or completed successfully"
      },
      "network": "VISA",
      "subnetwork": "VISANET",
      "standin_approved_by": "COMMANDO_AUTO",
      "standin_by": "COMMANDO_AUTO"
    }
  ]
}
```

<h2 id="_webhook_replay">
  Webhook replay
</h2>

In the event you fail to accept a webhook, Marqeta continues to resend the event until a `200` response is achieved. Marqeta retries for up to 12 days after the event time. After 12 days, Marqeta ceases to resend the event, and it is dropped from the queue. However, you can still replay the event through the API with key information from the event. Webhook replay details are outlined below.

* A messaging failure is defined as any HTTP response code other than `200`.

* In the case of a messaging failure, the Marqeta platform:

  * Attempts to resend a notification message 10 times.

  * Exponentially increases the interval between retries by powers of 4, following a retry interval of: 4 seconds, 16 seconds, 64 seconds, and so on, up to an interval just over 12 days.

* In the event of a failure, you can replay events by sending a `POST` request to the `/v3/webhooks/{token}/{event_type}/{event_token}` endpoint.

  * `{token}` – The token of your webhook configuration endpoint.

  * `{event_type}` – The [event type](/core-api/event-types/).

  * `{event_token}` – The token of the event itself. This can be a transaction token or card transition token.

<h3 id="_idempotency">
  Idempotency
</h3>

Your webhook endpoint might occasionally receive the same notification more than once.

To support idempotency:

* Each transaction is identified by a unique transaction token.

* Each webhook is identified by a unique event token.

For more information, see [Webhooks](/core-api/webhooks/#post_webhooks_token_eventtype_eventtoken).

<h2 id="_error_handling_responsibilities">
  Error handling responsibilities
</h2>

If you have a card program in Europe, there are several responsibilities that you and Marqeta maintain. These responsibilities include:

| Responsibility                                                                                   | Powered By | Managed By |
| ------------------------------------------------------------------------------------------------ | ---------- | ---------- |
| Ingest Marqeta events and respond accordingly, and accept Marqeta’s retry events                 | You        | You        |
| Store and reprocess failed webhook events for up to 12 days during customer platform downtime    | Marqeta    | Marqeta    |
| Configure and manage Commando Mode, if applicable                                                | You        | Marqeta    |
| Approve transactions on your behalf in the event that your endpoint is not functioning correctly | Marqeta    | Marqeta    |
| Receive and store balance information sent via JIT Funding or the API for later use              | Marqeta    | Marqeta    |


## Related topics

- [Creating a Dispute](/docs/developer-guides/disputes-create.md)
- [Marqeta in Europe Overview](/docs/developer-guides/marqeta-in-europe-landing-page.md)
- [Errors](/docs/core-api/errors.md)
- [Tokenization in Europe](/docs/developer-guides/mq-eu-tokenization.md)
- [2022 Release Notes](/docs/developer-guides/release-notes-2022.md)
