import type { Address, Hex } from 'viem'; import type { AnyQuoteV2Entry, FeeQuotingCommand, FeeQuotingQuoteResponse } from './types.js'; import { NoQuoteAvailableReason } from './types.js'; export interface FeeQuotingClientOptions { baseUrl: string; apiKey: string; } export interface QuoteParams { origin: string; command: FeeQuotingCommand; router: Address; destination: number; /** Pre-computed salt (e.g. keccak256(sender, clientSalt) for QuotedCalls) */ salt: Hex; /** Required for warp commands (transferRemote, transferRemoteTo) */ recipient?: Hex; /** Target router for transferRemoteTo with CrossCollateralRoutingFee */ targetRouter?: Hex; } export declare class FeeQuotingClient { private readonly baseUrl; private readonly apiKey; constructor(options: FeeQuotingClientOptions); getQuote(params: QuoteParams): Promise; } /** Query params for `GET /v2/quote/warp`. Mirrors the server-side route schema. */ export interface FeeQuotingV2WarpParams { origin: string; /** EVM hex or Sealevel base58 — server validates per protocol. */ router: string; destination: number; /** bytes32 — already scope-mixed for transient mode. */ salt: Hex; recipient: Hex; targetRouter: Hex; /** EVM hex or Sealevel base58 — payer / submitter address. */ txSubmitter: string; } /** Query params for `GET /v2/quote/igp`. */ export interface FeeQuotingV2IgpParams { origin: string; router: string; destination: number; salt: Hex; txSubmitter: string; } /** * JS-level error mirroring the server-side 404 body * (`NoQuoteAvailableError` JSON shape from `types.ts`). Thrown by * `FeeQuotingV2Client` when the server returns 404 — callers can catch + * inspect `reason` / `detail` to decide whether to fall back to legacy * quoting or surface a clear "no quote available" UX. */ export declare class FeeQuotingNoQuoteAvailableError extends Error { readonly reason: NoQuoteAvailableReason; readonly detail: string; constructor(reason: NoQuoteAvailableReason, detail: string); } export declare class FeeQuotingV2Client { private readonly baseUrl; private readonly apiKey; constructor(options: FeeQuotingClientOptions); /** GET /v2/quote/warp. Throws `FeeQuotingNoQuoteAvailableError` on 404. */ getWarpQuote(params: FeeQuotingV2WarpParams): Promise; /** GET /v2/quote/igp. Throws `FeeQuotingNoQuoteAvailableError` on 404. */ getIgpQuote(params: FeeQuotingV2IgpParams): Promise; private fetchQuote; } //# sourceMappingURL=client.d.ts.map