import type { components } from './generated'; import { type GauntletApiConfig } from './http'; type Schemas = components['schemas']; export type UserActivity = Schemas['UserActivity']; export type UserActivityResponse = Schemas['UserActivityResponse']; export type UserPosition = Schemas['UserPosition']; export type UserAllPositionsResponse = Schemas['UserAllPositionsResponse']; export type UserPositionLatestResponse = Schemas['UserPositionLatestResponse']; export type UserPositionsTimeseriesResponse = Schemas['UserPositionsTimeseriesResponse']; export type PositionTimeseriesPoint = Schemas['PositionTimeseriesPoint']; export type VaultDetail = Schemas['VaultDetail']; export type VaultDetailResponse = Schemas['VaultDetailResponse']; export type VaultTimeseriesResponse = Schemas['VaultTimeseriesResponse']; export type VaultTimeseriesPoint = Schemas['VaultTimeseriesPoint']; export type VaultMetrics = Schemas['VaultMetrics']; export type FeaturedVault = Schemas['FeaturedVault']; export type FeaturedVaultsResponse = Schemas['FeaturedVaultsResponse']; export type StrategyCard = Schemas['StrategyCard']; export type StrategyListResponse = Schemas['StrategyListResponse']; export type TvlResponse = Schemas['TvlResponse']; export type LatestPriceResponse = Schemas['LatestPriceResponse']; export type PriceTimeseriesResponse = Schemas['TimeseriesResponse']; export type TokenRef = Schemas['TokenRef']; export type PartialResponseError = Schemas['PartialResponseError']; export type AmountPair = Schemas['AmountPair']; export type TimeseriesMeta = Schemas['TimeseriesMeta']; export type HealthResponse = Schemas['HealthResponse']; export type ChainSyncStatus = Schemas['ChainSyncStatus']; export interface PageOptions { /** Opaque cursor from a previous response's `meta.next_cursor`. */ next?: string; limit?: number; order?: 'asc' | 'desc'; } export interface TimeWindowOptions extends PageOptions { /** ISO 8601 date (`2026-01-01`) or RFC 3339 timestamp. */ start?: string; end?: string; granularity?: 'hour' | 'day' | 'week' | 'month'; } export interface ActivityOptions extends PageOptions { /** CAIP-10 vault id (`"{chainId}:{address}"`). Omit for wallet-wide activity. */ vaultId?: string; /** * Wallet-wide feeds only: include activity in hidden (enabled but unlisted) * vaults alongside visible ones. Activity in disabled vaults is never * returned. Ignored when `vaultId` is set. */ includeHidden?: boolean; } export interface PositionsOptions extends PageOptions { /** * Include positions in hidden (enabled but unlisted) vaults alongside * visible ones. Positions in disabled vaults are never returned. */ includeHidden?: boolean; } export interface LatestPriceOptions { address: string; chainId: number; /** Optional ISO 8601 timestamp for a point-in-time price. */ at?: string; } export interface PriceTimeseriesOptions { address: string; chainId: number; start: string; end: string; granularity?: 'raw' | 'hour' | 'day' | 'week' | 'month'; limit?: number; } /** * Typed client for the Gaia REST API (api.gauntlet.xyz). * * All response types are generated from the service's OpenAPI spec * (`src/api/generated.ts`, regenerated via `yarn generate:api-types`) so they * cannot drift from the server models. Values are returned exactly as the API * emits them — human-unit decimal strings and CAIP-10 vault ids; use * `decimalToBigInt` / `sharesToBigInt` and `apiVaultIdFromVaultId` / * `vaultIdFromApiVaultId` to convert, or the higher-level `activityFlows` / * `positionHistory` helpers for pre-normalized values. * * Available on a configured client as `client.api`, or standalone: * ```ts * const api = new GauntletApi({ apiKey: process.env.GAUNTLET_API_KEY }); * const { data } = await api.vaults(); * ``` */ export declare class GauntletApi { private readonly config; constructor(config?: GauntletApiConfig); private get; /** GET /health — service liveness (version + uptime). */ health(): Promise; /** GET /health/chains — per-chain indexer sync freshness. */ chainSyncStatus(): Promise; /** GET /v1/vaults — all indexed vaults with live metrics (TVL, APY, unit price). */ vaults(options?: PageOptions): Promise<{ data: VaultDetail[]; meta: TimeseriesMeta; }>; /** GET /v1/vaults/featured — admin-curated featured vault cards. */ featuredVaults(): Promise; /** GET /v1/strategies — admin-curated strategy cards. */ strategies(): Promise; /** GET /v1/vaults/{vault_id} — one vault with live metrics. `vaultId` is CAIP-10. */ vault(vaultId: string): Promise; /** GET /v1/vaults/{vault_id}/definition — raw indexed vault definition. */ vaultDefinition(vaultId: string): Promise; /** GET /v1/vaults/{vault_id}/timeseries — TVL / unit-price / APY history. */ vaultTimeseries(vaultId: string, options?: TimeWindowOptions): Promise; /** GET /v1/users/{wallet}/positions — all of a wallet's indexed positions with PnL. */ positions(walletAddress: string, options?: PositionsOptions): Promise; /** GET /v1/users/{wallet}/positions/{vault_id} — one position with PnL breakdown. */ position(walletAddress: string, vaultId: string): Promise; /** GET /v1/users/{wallet}/positions/{vault_id}/timeseries — value / cost-basis / PnL / ROI history. */ positionTimeseries(walletAddress: string, vaultId: string, options?: TimeWindowOptions): Promise; /** GET /v1/users/{wallet}/activity — one page of the wallet's immutable event log. */ activity(walletAddress: string, options?: ActivityOptions): Promise; /** * Iterates the wallet's full activity log, following `meta.next_cursor` * across pages so callers never handle cursors. */ activityRows(walletAddress: string, options?: Omit): AsyncGenerator; /** GET /v1/tvl — aggregate Gauntlet TVL, optionally with per-source breakdown. */ tvl(options?: { includeBreakdown?: boolean; }): Promise; /** GET /v1/prices — latest USD price for a token. */ latestPrice(options: LatestPriceOptions): Promise; /** GET /v1/prices/timeseries — USD price history for a token. */ priceTimeseries(options: PriceTimeseriesOptions): Promise; } export {}; //# sourceMappingURL=client.d.ts.map