Class AnalyticsAPI

Represents a class for handling operations related to making analytics queries from the subgraph.

Hierarchy

  • BaseAPI
    • AnalyticsAPI

Constructors

Properties

Methods

Constructors

Properties

premia: Premia

Methods

  • Retrieves daily data for a specific vault using its address.

    This function is cached, meaning that if it is called multiple times within a one minute period, it will only perform the operation once and then return the cached result for subsequent calls.

    Parameters

    • vaultAddress: string

      The address of the vault for which daily data should be retrieved.

    • Optional startTime: number = 0

      The timestamp (in seconds) from when the data should start being retrieved (default is 0).

    • Optional first: number = 1000

      The maximum number of data points to return (default is 1000).

    • Optional skip: number = 0

      The number of data points to skip from the start of the results (default is 0).

    Returns Promise<VaultDayData[]>

    A promise that resolves to an array of VaultDayData objects, containing daily information about the vault at the specified address.

Generated using TypeDoc