Constructors

Properties

hyperionProvider?: FetchProvider
provider: APIProvider
v1: {
    chain: ChainAPI;
    history: HistoryAPI;
} = ...

Type declaration

v2: {
    history: HistoryAPIv2;
    state: StateAPIv2;
    stats: StatsAPIv2;
} = ...

Type declaration

  • history: HistoryAPIv2
  • state: StateAPIv2
  • stats: StatsAPIv2
__className: string = 'APIClient'

Methods

  • Type Parameters

    Parameters

    • args: {
          headers?: Record<string, string>;
          method?: APIMethods;
          params?: unknown;
          path: string;
          responseType: T;
      }
      • Optional headers?: Record<string, string>
      • Optional method?: APIMethods
      • Optional params?: unknown
      • path: string
      • responseType: T

    Returns Promise<InstanceType<T>>

  • Type Parameters

    • T extends keyof BuiltinTypes

    Parameters

    • args: {
          headers?: Record<string, string>;
          method?: APIMethods;
          params?: unknown;
          path: string;
          responseType: T;
      }
      • Optional headers?: Record<string, string>
      • Optional method?: APIMethods
      • Optional params?: unknown
      • path: string
      • responseType: T

    Returns Promise<BuiltinTypes[T]>

  • Type Parameters

    • T = unknown

    Parameters

    • args: {
          headers?: Record<string, string>;
          method?: APIMethods;
          params?: unknown;
          path: string;
      }
      • Optional headers?: Record<string, string>
      • Optional method?: APIMethods
      • Optional params?: unknown
      • path: string

    Returns Promise<T>