# `GenAI.Provider.Anthropic.EncoderProtocol`

Encoders use their module's EncoderProtocol to prep messages and tool definitions
To make future extensibility for third parties straight forward. If a new message
type, or tool type is added one simply needs to implement a EncoderProtocol for it
and most cases you can simply cast it to generic known type and then invoke the protocol
again.

# `t`

```elixir
@type t() :: term()
```

All the types that implement this protocol.

# `encode`

---

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