# IndexerQueryError

> For the complete documentation index, see [llms.txt](https://docs.midnight.network/llms.txt)

[**Midnight.js API Reference v4.1.0**](https://docs.midnight.network/api-reference/midnight-js.md)

***

[Midnight.js API Reference](https://docs.midnight.network/api-reference/midnight-js/packages.md) / [@midnight-ntwrk/midnight-js-indexer-public-data-provider](https://docs.midnight.network/api-reference/midnight-js/@midnight-ntwrk/midnight-js-indexer-public-data-provider.md) / IndexerQueryError

# Class: IndexerQueryError

An error raised when an Apollo query or fetch fails at the transport layer (network failure, malformed response, Apollo client error), distinct from the case where the server returns a well-formed response containing `GraphQLFormattedError` entries, which is reported via [IndexerFormattedError](https://docs.midnight.network/api-reference/midnight-js/@midnight-ntwrk/midnight-js-indexer-public-data-provider/classes/IndexerFormattedError.md).

Preserves the original Apollo error via `Error.cause` so consumers can inspect network details and the original stack.

## Extends[​](#extends "Direct link to Extends")

* [`IndexerError`](https://docs.midnight.network/api-reference/midnight-js/@midnight-ntwrk/midnight-js-indexer-public-data-provider/classes/IndexerError.md)

## Constructors[​](#constructors "Direct link to Constructors")

### Constructor[​](#constructor "Direct link to Constructor")

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

#### Parameters[​](#parameters "Direct link to Parameters")

##### message[​](#message "Direct link to message")

`string`

##### options?[​](#options "Direct link to options?")

`ErrorOptions`

#### Returns[​](#returns "Direct link to Returns")

`IndexerQueryError`

#### Overrides[​](#overrides "Direct link to Overrides")

[`IndexerError`](https://docs.midnight.network/api-reference/midnight-js/@midnight-ntwrk/midnight-js-indexer-public-data-provider/classes/IndexerError.md).[`constructor`](https://docs.midnight.network/api-reference/midnight-js/@midnight-ntwrk/midnight-js-indexer-public-data-provider/classes/IndexerError.md#constructor)
