# `TypeSafeAPISDK.SystemOneResponse`
[🔗](https://github.com/nshkrdotcom/typesafe_api_sdk/blob/v0.1.0/lib/typesafe_api_sdk/system_one_response.ex#L1)

Typed System One response with grouped convenience accessors.

Responses produced by the HTTP client retain request metadata separately from
the decoded API payload. `request_id!/1` and `raw_http_response!/1` mirror the
Python SDK's metadata access without polluting the wire fields.

# `answer`

```elixir
@type answer() ::
  TypeSafeAPISDK.NoulAnswer.t()
  | TypeSafeAPISDK.ChoiceAnswer.t()
  | TypeSafeAPISDK.ScoreAnswer.t()
```

# `t`

```elixir
@type t() :: %TypeSafeAPISDK.SystemOneResponse{
  answers: %{required(String.t()) =&gt; answer()},
  elapsed_ms: number(),
  model: String.t(),
  raw: map() | nil,
  raw_http_response: Pristine.Response.t() | nil,
  request_id: String.t() | nil,
  retries: non_neg_integer(),
  unknown_answers: map(),
  usage: TypeSafeAPISDK.Usage.t()
}
```

# `choices`

```elixir
@spec choices(t()) :: %{required(String.t()) =&gt; TypeSafeAPISDK.ChoiceAnswer.t()}
```

# `decode`

```elixir
@spec decode(term()) :: {:ok, t()} | {:error, TypeSafeAPISDK.Error.t()}
```

# `fetch`

```elixir
@spec fetch(t(), String.t()) :: {:ok, answer()} | :error
```

Fetch an answer by its wire question ID.

# `fetch!`

```elixir
@spec fetch!(t(), String.t()) :: answer()
```

Fetch an answer or raise a KeyError listing the available IDs.

# `nouls`

```elixir
@spec nouls(t()) :: %{required(String.t()) =&gt; TypeSafeAPISDK.NoulAnswer.t()}
```

# `raw_http_response!`

```elixir
@spec raw_http_response!(t()) :: Pristine.Response.t()
```

# `request_id!`

```elixir
@spec request_id!(t()) :: String.t()
```

# `scores`

```elixir
@spec scores(t()) :: %{required(String.t()) =&gt; TypeSafeAPISDK.ScoreAnswer.t()}
```

---

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