g3-toolkit API Reference
    Preparing search index...

    Interface RestAdapterConfig

    interface RestAdapterConfig {
        headers?: Record<string, string>;
        mapResponse: (json: unknown) => RestResponseMapping;
        method?: "GET" | "POST";
        middleware?: Middleware[];
        timeoutMs?: number;
        url: string;
    }
    Index

    Properties

    headers?: Record<string, string>

    Static headers (auth headers should use middleware).

    mapResponse: (json: unknown) => RestResponseMapping

    Transform the JSON response into node/edge arrays.

    method?: "GET" | "POST"

    HTTP method (default: POST).

    middleware?: Middleware[]

    Middleware chain (auth, retry, logging).

    timeoutMs?: number

    Request timeout in milliseconds. Defaults to DEFAULT_TIMEOUT_MS (30 s); pass 0 to disable it.

    url: string

    Base URL for the API endpoint.