# ZaunError

Defined in: [zaun/js/index.d.ts:43](https://github.com/zaunchat/zaun-client/blob/main/zaun/js/index.d.ts#L43)

## Extends

- `Error`

## Constructors

### Constructor

> **new ZaunError**(`message?`): `ZaunError`

Defined in: ../../../node\_modules/typescript/lib/lib.es5.d.ts:1082

#### Parameters

##### message?

`string`

#### Returns

`ZaunError`

#### Inherited from

`Error.constructor`

### Constructor

> **new ZaunError**(`message?`, `options?`): `ZaunError`

Defined in: ../../../node\_modules/typescript/lib/lib.es5.d.ts:1082

#### Parameters

##### message?

`string`

##### options?

`ErrorOptions`

#### Returns

`ZaunError`

#### Inherited from

`Error.constructor`

## Properties

### body?

> `optional` **body?**: `unknown`

Defined in: [zaun/js/index.d.ts:49](https://github.com/zaunchat/zaun-client/blob/main/zaun/js/index.d.ts#L49)

***

### code

> **code**: `string`

Defined in: [zaun/js/index.d.ts:46](https://github.com/zaunchat/zaun-client/blob/main/zaun/js/index.d.ts#L46)

Lowercase for a local failure (`timeout`, `closed`, `bad_link`, `unsupported`, …), or
the host's own code (`FORBIDDEN`, `RATE_LIMITED`, …).

***

### command?

> `optional` **command?**: `string`

Defined in: [zaun/js/index.d.ts:48](https://github.com/zaunchat/zaun-client/blob/main/zaun/js/index.d.ts#L48)

The command the host refused.
