# `ExMCP.ACP.Adapters.ZCode.Mapper`
[🔗](https://github.com/azmaveth/ex_mcp/blob/v1.4.0/lib/ex_mcp/acp/adapters/zcode/mapper.ex#L1)

Pure ZCode event to ACP message mapping.

Translates ZCode `session/event` typed notifications, server-initiated
requests, and response messages into ACP `session/update` notifications
and JSON-RPC responses.

# `reduce_message`

```elixir
@spec reduce_message(map(), map()) :: {[map()], [iodata()], map()}
```

Reduces a decoded ZCode message (response, server request, or notification)
into ACP messages, port writes, and new adapter state.

# `replay_snapshot_history`

```elixir
@spec replay_snapshot_history(String.t(), map()) :: [map()]
```

Replays snapshot messages as ACP session/update chunks.

# `session_result`

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

Builds the ACP session setup result from a ZCode snapshot.

---

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