# `ClaudeAgentSDK.AssistantError`
[🔗](https://github.com/nshkrdotcom/claude_agent_sdk/blob/v0.17.2/lib/claude_agent_sdk/assistant_error.ex#L1)

Enumerates assistant-level error codes surfaced by the Claude CLI.

Mirrors the Python SDK enum to keep client handling consistent.

# `t`

```elixir
@type t() ::
  :authentication_failed
  | :billing_error
  | :rate_limit
  | :invalid_request
  | :server_error
  | :unknown
```

# `cast`

```elixir
@spec cast(String.t() | atom() | nil) :: t() | nil
```

Casts a string/atom error value into the assistant error enum.

Returns `nil` when no error is present, and `:unknown` when the value
is present but not recognized.

# `values`

```elixir
@spec values() :: [t()]
```

Returns the list of supported assistant error codes.

---

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