Skip to main content

IndexerClient

For the complete documentation index, see llms.txt

@midnight-ntwrk/testkit-js v4.0.4


Constructors​

Constructor​

new IndexerClient(indexerUrl, logger): IndexerClient

Creates an instance of IndexerClient.

Parameters​

indexerUrl​

string

The URL of the indexer service.

logger​

Logger

The logger instance for logging information.

Returns​

IndexerClient

Properties​

indexerUrl​

readonly indexerUrl: string

Methods​

health()​

health(): Promise<AxiosResponse<any, any, { }>>

Checks the health status of the indexer service. Makes a GET request to the status endpoint of the indexer service.

Returns​

Promise<AxiosResponse<any, any, { }>>

A promise that resolves to the response of the health check or logs an error if the request fails.