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

# Corrective retry

> How deliberate stamp corrections work — proof, preview, apply, and hard blocks.

Corrective retry changes course on purpose. Use it when automatic recovery is not enough and evidence proves a real correction is required.

Ordinary document [failures](/stamping/failures) still need corrected evidence first. Corrective retry only continues when policy and proof allow it.

## How it works

```text theme={null}
Immutable CargoWise capture (original accounting evidence)
        │
        └── Corrective retry
              preview a plan → apply only that plan
              either resume the exact attempt, or remap source once
              never silent
```

Lambda treats the original CargoWise capture as immutable accounting evidence. Before anything mutates, it asks:

1. Is this document already successful, cancelled, in flight, or waiting on a parent?
2. Does policy allow a stamp retry for the active classification?
3. Can we **resume** the exact stored attempt, or must we **reprocess** from the original capture?
4. For failed documents: is there proof the fiscal projection changed, or that an approved prerequisite was corrected?

If any answer fails, retry blocks.

## Resume vs reprocess

Lambda chooses the strategy from evidence. People do not pick it.

|                    | Resume attempt                   | Reprocess source                                 |
| ------------------ | -------------------------------- | ------------------------------------------------ |
| Body               | Exact stored request             | Remapped from original capture                   |
| When               | Known or uncertain provider work | Create never produced an invoice                 |
| What it never does | Remap into a different body      | Open a new attempt when create may already exist |

If Facturapi already created the invoice, Lambda retrieves and finalizes that invoice. It does not create again.

If the create outcome is unknown, Lambda resumes the exact request. Remapping uncertainty into a new attempt is blocked.

## Preview, then apply

1. **Preview** recomputes what would happen and returns a plan fingerprint.
2. **Apply** recomputes under lock and only proceeds if that exact plan still matches.
3. A private reason is stored on the ops run. It is not copied into customer notifications.

Stale previews fail closed.

## Hard blocks

Corrective retry never:

* Edits the original CargoWise capture
* Retries successful or cancelled documents as an everyday action
* Stacks a second stamp lane on in-flight or parent-waiting work
* Opens a new attempt when the provider may already have created the invoice
* Retries an unchanged rejected request without proven correction
* Uses delivery retry to issue another CFDI

**Retry CargoWise delivery** only re-sends XML/PDF (or a cancellation receipt). The CFDI may already be issued.

Documents observed as **Stamped externally** have no Lambda stamp retry here. They are recorded evidence, not Lambda-owned CFDIs to remake.

## What you do in the workspace

| Situation                                  | Start here                                                           |
| ------------------------------------------ | -------------------------------------------------------------------- |
| Button says **Retry stamp**                | Use it once; watch the timeline                                      |
| Button says **Retry CargoWise delivery**   | Re-send files only; do not expect a new stamp                        |
| Note says wait for parent or review fields | Fix evidence; do not invent a second stamp                           |
| System error / support issue               | Leave for Jaantonio unless a safe retry is offered                   |
| Source changed after review                | Accept or reject with evidence — post-stamp drift is not auto-healed |

Support-owned corrective retry follows the same preview → apply gates when the workspace correctly blocks day-to-day action (for example after a proven mapper fix). Replacement of an already-issued Lambda-owned CFDI is a separate, explicit support operation — not the same as resume or reprocess above.

## Related

* [Recovery](/stamping/retry/overview) — automatic vs corrective
* [Failures](/stamping/failures) · [System errors](/stamping/system-errors)
* [Rules](/stamping/rules)
