# ClientOptions

> **ClientOptions** = `object` & \{ `identity`: `Identity` \| `"anonymous"`; `auth?`: `never`; \} \| \{ `auth`: () => [`AuthLike`](https://ic-reactor.b3pay.net/v4/libs/interfaces/authlike/); `identity?`: `never`; \}

Defined in: [core/src/client.ts:135](https://github.com/B3Pay/ic-reactor/blob/6b3b9f58b7868082175216ca6e3688d278d17c1f/packages/core/src/client.ts#L135)

Options for [createClient](https://ic-reactor.b3pay.net/v4/libs/functions/createclient/): a network, and exactly one of `identity`
and `auth`, so that who calls is always written down.

## Type Declaration

### network

> `readonly` **network**: [`Network`](https://ic-reactor.b3pay.net/v4/libs/type-aliases/network/)

Where the canisters are. See [Network](https://ic-reactor.b3pay.net/v4/libs/type-aliases/network/).

### allowEnvConfig?

> `readonly` `optional` **allowEnvConfig?**: `boolean`

Whether the `ic_env` cookie (root key and canister ids) is believed. See
the `network` option; absent trusts it only when both the page and the
replica are local.

### fetch?

> `readonly` `optional` **fetch?**: *typeof* `globalThis.fetch`

The `fetch` every agent of this client sends with. Defaults to the global
one. Tests pass a fake replica's `fetch` here; nothing global is touched.

### maxDepth?

> `readonly` `optional` **maxDepth?**: `number`

How deep a decoded reply may nest. Defaults to 256. Raise it for replies
that nest deeper, such as an ICRC-3 block log's values.