import { type PublicClient, type WalletClient } from 'viem'; import { GauntletApi } from './api/client'; import type { VaultManifest } from './evm/types'; /** * Controls how builder attribution is appended to transactions. * * - `PUBLIC` – attribution is sent as plain calldata (default). * - `ENCODED` – attribution is encoded using ERC-8021 with a builder code fetched from the API. * - `PRIVATE` – no attribution data is appended. */ export declare enum AttributionMode { PUBLIC = "public", ENCODED = "encoded", PRIVATE = "private" } export type ChainId = string | number; export interface GauntletClientConfig { /** Gaia API key, sent as `x-api-key` on `client.api` requests. Anonymous access is rate-limited. */ apiKey?: string; /** Override the Gaia API origin (e.g. a same-origin proxy route). Defaults to `https://api.gauntlet.xyz`. */ apiUrl?: string; /** Map of chainId → PublicClient, e.g. { [base.id]: createPublicClient(...) } */ evmClients?: Record; attributionMode?: AttributionMode; builderCode?: string; /** Viem WalletClient for signing transactions. */ wallet?: WalletClient; } /** * Main entry point for the Gauntlet SDK. * * Holds configuration (RPC clients, wallet, attribution mode) and exposes helpers * for reading the vault manifest. Pass an instance of this class to every SDK * function (e.g. `getDepositTx`, `getWithdrawTx`, `getVaults`). * * @example * ```ts * import { createPublicClient, createWalletClient, http } from 'viem'; * import { base } from 'viem/chains'; * import { GauntletClient, AttributionMode } from '@gauntlet-xyz/sdk'; * * const wallet = createWalletClient({ * account: privateKeyToAccount('0x...'), // or other account source * chain: base, * transport: http() * }) * * const client = new GauntletClient({ * evmClients: { [base.id]: createPublicClient({ chain: base, transport: http() }) }, * wallet, * attributionMode: AttributionMode.PUBLIC, * }); * ``` */ export declare class GauntletClient { readonly apiKey?: string; readonly builderCode?: string; readonly attributionMode: AttributionMode; readonly evmClients: Record; readonly wallet?: WalletClient; /** Typed client for the Gaia REST API (vaults, positions, activity, tvl, prices). */ readonly api: GauntletApi; private _manifest; constructor(config: GauntletClientConfig); get manifest(): Promise; setManifest(manifest: VaultManifest): void; getPublicClient(chainId?: ChainId): PublicClient; getSourceId(): Promise; } //# sourceMappingURL=client.d.ts.map