# `Chronicle.Auditing.CausationManager`
[🔗](https://github.com/Cratis/Chronicle.Elixir/blob/main/lib/chronicle/auditing/causation_manager.ex#L4)

Process-scoped causation chain manager.

Maintains a root causation entry and any additional entries added in the
current process.

# `add`

```elixir
@spec add(Chronicle.Auditing.CausationType.t() | String.t(), map()) ::
  Chronicle.Auditing.CausationEntry.t()
```

Adds a causation entry to the current process chain.

# `clear`

```elixir
@spec clear() :: :ok
```

Clears the current process causation root and chain.

# `define_root`

```elixir
@spec define_root(map()) :: Chronicle.Auditing.CausationEntry.t()
```

Defines the root causation entry for the calling process.

# `get_current_chain`

```elixir
@spec get_current_chain() :: [Chronicle.Auditing.CausationEntry.t()]
```

Gets the current causation chain for the calling process.

---

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