# `Nous.Workflow.Checkpoint`
[🔗](https://github.com/nyo16/nous/blob/v0.21.1/lib/nous/workflow/checkpoint.ex#L1)

Checkpoint for suspending and resuming workflow execution.

When a workflow is paused (via hook, atomics signal, or human checkpoint),
a checkpoint captures the full execution state so the workflow can be
resumed later.

## Fields

| Field | Description |
|-------|-------------|
| `workflow_id` | Graph ID |
| `run_id` | Unique run identifier |
| `node_id` | Node where execution paused |
| `state` | Full workflow state at pause point |
| `status` | `:suspended` or `:completed` or `:failed` |
| `reason` | Why the workflow was paused |
| `created_at` | When checkpoint was created |

# `t`

```elixir
@type t() :: %Nous.Workflow.Checkpoint{
  created_at: DateTime.t(),
  node_id: String.t() | nil,
  reason: term(),
  run_id: String.t(),
  state: Nous.Workflow.State.t(),
  status: :suspended | :completed | :failed,
  workflow_id: String.t()
}
```

# `new`

```elixir
@spec new(map()) :: t()
```

Create a new checkpoint from execution context.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
