# `Spectre.GAM.Domain.Projection`
[🔗](https://github.com/elchemista/spectre/blob/0.4.0/lib/spectre/gam/domain/projection.ex#L1)

Domain-facing driver and query API for disposable governed state.

A projection is rebuilt from the canonical ledger and can always be thrown
away. Structural snapshot verification belongs here; transition semantics
live in `Spectre.GAM.GovernedAct.Fold`, while derived reads live in
`Spectre.GAM.GovernedAct.View`. None of these modules is an authority store.

# `dispatch_cancellation`

```elixir
@type dispatch_cancellation() :: Spectre.GAM.GovernedAct.State.dispatch_cancellation()
```

# `meter_recontainment`

```elixir
@type meter_recontainment() :: Spectre.GAM.GovernedAct.State.meter_recontainment()
```

# `meter_reservation`

```elixir
@type meter_reservation() :: Spectre.GAM.GovernedAct.State.meter_reservation()
```

# `reservation_status`

```elixir
@type reservation_status() :: Spectre.GAM.GovernedAct.State.reservation_status()
```

# `t`

```elixir
@type t() :: Spectre.GAM.GovernedAct.State.t()
```

# `apply_payloads`

```elixir
@spec apply_payloads(t(), [map()], non_neg_integer()) :: {:ok, t()} | {:error, term()}
```

Applies one timestamped payload batch to disposable governed state.

# `authority_view`

```elixir
@spec authority_view(t()) :: Spectre.GAM.Kernel.Authority.Facts.t()
```

Returns the immutable authority facts consumed by the pure kernel.

# `candidate_decision`

```elixir
@spec candidate_decision(t(), String.t()) ::
  {:ok, Spectre.GAM.Decision.t()} | :not_found | {:error, term()}
```

Looks up the durable Decision selected by a Candidate identity key.

# `decision_act`

```elixir
@spec decision_act(t(), Spectre.GAM.Decision.t()) ::
  {:ok, Spectre.GAM.Act.t() | nil} | {:error, term()}
```

Looks up the Act paired with a durable Decision.

# `definition`

```elixir
@spec definition(t(), String.t()) ::
  {:ok, Spectre.GAM.Definition.t()} | {:error, term()}
```

Looks up one immutable governed Definition by exact reference.

# `duty`

```elixir
@spec duty(t(), {:cause_key, term()} | {:ref, String.t()}) ::
  {:ok, Spectre.GAM.Duty.t()} | :not_found | {:error, :invalid_duty_lookup}
```

Looks up a Duty by stable cause key or durable reference.

# `evidence_set`

```elixir
@spec evidence_set(t(), [String.t()]) :: {:ok, [term()]} | {:error, term()}
```

Resolves an exact Evidence set from disposable state.

# `meter_accounts`

```elixir
@spec meter_accounts(t(), String.t()) :: {:ok, map()} | {:error, term()}
```

Returns physical Meter accounts for a logical Mandate revision.

# `new`

```elixir
@spec new(String.t(), map()) :: t()
```

Creates empty disposable state for a Domain.

# `replay`

```elixir
@spec replay(Spectre.GAM.Ledger.snapshot(), map()) :: {:ok, t()} | {:error, term()}
```

Verifies a ledger snapshot and folds its canonical governed history.

# `scope_context`

```elixir
@spec scope_context(t(), Spectre.GAM.SubmissionContext.t()) ::
  {:ok, Spectre.GAM.Scope.Opening.t()} | {:error, term()}
```

Checks an authenticated context against its durable Scope opening.

---

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