keyring-agent-core 0.2.44 → 0.2.46

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -866,10 +866,21 @@ interface X402PaymentRequiredProps {
866
866
  };
867
867
  /** Human-readable fields for the card (display only). */
868
868
  display: {
869
- /** Amount in smallest unit, e.g. "10000". */
869
+ /**
870
+ * Amount ALREADY formatted by the token's on-chain `decimals()`, e.g.
871
+ * "0.01" — render this as-is, never re-scale it. Falls back to the raw
872
+ * smallest-unit string when the token could not be read on-chain (then
873
+ * `decimals` is null).
874
+ */
870
875
  amount: string;
871
- /** Asset symbol, e.g. "USDC". */
876
+ /** Asset symbol read on-chain via `symbol()`, e.g. "USDC". */
872
877
  asset: string;
878
+ /** Amount in smallest unit, exactly as the 402 demanded it, e.g. "10000". */
879
+ amountRaw: string;
880
+ /** The token's on-chain `decimals()`, or null when it could not be read. */
881
+ decimals: number | null;
882
+ /** Payment token contract address. */
883
+ assetAddress: string;
873
884
  /** CAIP-2 network id, e.g. "eip155:84532". */
874
885
  network: string;
875
886
  /** Network name, e.g. "Base Sepolia". */
@@ -1906,10 +1917,11 @@ declare class AgentCore {
1906
1917
  private persistHistory;
1907
1918
  /**
1908
1919
  * Validate the license key against the hash baked into this bundle at build
1909
- * time (`__AGENT_LICENSE_HASH__`, set by tsup). We compare hashes, never the
1910
- * raw key, so the bundle never contains the key itself. When no key was baked
1911
- * in (local dev build with no SECRET_KEY) the hash is empty and the gate is a
1912
- * no-op. Cached after the first pass so we only hash once.
1920
+ * time (`__AGENT_LICENSE_HASH__`, set by tsup from `SECRET_KEY_HASH`). The
1921
+ * app passes the raw key; we hash it here and compare hash-to-hash, so
1922
+ * neither the bundle nor the repo ever holds the key itself. When no hash was
1923
+ * baked in (local dev build with no `SECRET_KEY_HASH`) the gate is a no-op.
1924
+ * Cached after the first pass so we only hash once.
1913
1925
  *
1914
1926
  * The gate exists to protect the Keyring-hosted Gemini proxy. A caller that
1915
1927
  * brings their own Gemini API key (`llm.apiKey`) talks to Google directly and
@@ -7528,8 +7540,8 @@ interface X402RetryContext {
7528
7540
  headers?: Record<string, string>;
7529
7541
  }
7530
7542
  /**
7531
- * Resolve a 402 challenge into the header(s) to retry with (e.g.
7532
- * `{ 'PAYMENT-SIGNATURE': '…' }`), or `null` to give up (caller sees the 402).
7543
+ * Resolve a 402 challenge into the header(s) to retry with — `PAYMENT-SIGNATURE`
7544
+ * for x402 v2, `X-PAYMENT` for v1 — or `null` to give up (caller sees the 402).
7533
7545
  */
7534
7546
  type X402RetryHandler = (response: ApiResponse, ctx: X402RetryContext) => Promise<Record<string, string> | null>;
7535
7547
  type RequestOptions = Omit<AxiosRequestConfig, 'url' | 'method' | 'data' | 'baseURL'>;
@@ -7550,17 +7562,36 @@ declare const apiClient: ApiClient;
7550
7562
  /**
7551
7563
  * Generic x402 (HTTP 402 "pay-per-call") client for the agent core.
7552
7564
  *
7553
- * The core makes the outbound HTTP call. When a resource answers `402` with a
7554
- * `PAYMENT-REQUIRED` header, the core does NOT hold a private key, so it builds
7555
- * the payment authorization + the EIP-712 typed data and hands the typed data to
7556
- * the FE to SIGN. The FE returns just the signature; the core then re-issues the
7557
- * request with the `PAYMENT-SIGNATURE` header and returns the unlocked result.
7558
- *
7559
- * Supports the x402 v2 "exact" EVM scheme (EIP-3009 `TransferWithAuthorization`),
7560
- * which covers USDC-style assets. No crypto library is needed here — signing
7561
- * happens on the FE; the core only does JSON + base64 + a random nonce.
7565
+ * The core makes the outbound HTTP call. When a resource answers `402`, the core
7566
+ * does NOT hold a private key, so it builds the payment authorization + the
7567
+ * EIP-712 typed data and hands the typed data to the FE to SIGN. The FE returns
7568
+ * just the signature; the core then re-issues the request with the payment
7569
+ * header and returns the unlocked result.
7570
+ *
7571
+ * Supports BOTH protocol versions of the "exact" EVM scheme (EIP-3009
7572
+ * `TransferWithAuthorization`), which covers USDC-style assets. The cryptography
7573
+ * is identical across versions — only the transport and field names differ:
7574
+ *
7575
+ * | | v1 | v2 |
7576
+ * |---|---|---|
7577
+ * | challenge | 402 + JSON **body** | 402 + `PAYMENT-REQUIRED` header (base64) |
7578
+ * | retry header | `X-PAYMENT` | `PAYMENT-SIGNATURE` |
7579
+ * | price field | `maxAmountRequired` | `amount` |
7580
+ * | network | `"base-sepolia"` | CAIP-2 `"eip155:84532"` |
7581
+ * | payload | flat `{scheme, network, payload}` | `{accepted, resource, payload}` |
7582
+ * | receipt | `X-PAYMENT-RESPONSE` | `PAYMENT-RESPONSE` |
7583
+ *
7584
+ * The version is DETECTED from the 402 (never assumed), normalized into one
7585
+ * internal shape, and re-encoded in the detected version's wire format on retry.
7586
+ * No crypto library is needed here — signing happens on the FE; the core only
7587
+ * does JSON + base64 + a random nonce.
7588
+ *
7589
+ * @see specs/x402-specification-v1.md + specs/transports-v1/http.md
7590
+ * @see specs/x402-specification-v2.md + specs/transports-v2/http.md
7562
7591
  */
7563
7592
  type HttpMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE';
7593
+ /** Protocol version of a challenge. Detected from the 402, never assumed. */
7594
+ type X402Version = 1 | 2;
7564
7595
  /** A request the core wants to make (and replay after payment). */
7565
7596
  interface X402RequestSpec {
7566
7597
  url: string;
@@ -7572,10 +7603,19 @@ interface X402RequestSpec {
7572
7603
  /** Extra request headers (the payment header is added on retry). */
7573
7604
  headers?: Record<string, string>;
7574
7605
  }
7575
- /** Selected payment requirement from the 402 challenge (accepts[0]). */
7606
+ /**
7607
+ * A payment requirement from the 402 challenge, NORMALIZED across versions.
7608
+ *
7609
+ * `network` and `amount` are always kept VERBATIM as the server sent them, so
7610
+ * the retry echoes back exactly what the facilitator expects to match (v1
7611
+ * facilitators compare `network` string-equal against `"base-sepolia"`). The
7612
+ * derived, version-independent values live in `chainId` / `amountRaw`.
7613
+ */
7576
7614
  interface X402Requirements {
7577
7615
  scheme: string;
7616
+ /** Verbatim from the server: v1 `"base-sepolia"`, v2 CAIP-2 `"eip155:84532"`. */
7578
7617
  network: string;
7618
+ /** Smallest unit, e.g. "10000" = 0.01 USDC (6 dp). v1 sends it as `maxAmountRequired`. */
7579
7619
  amount: string;
7580
7620
  asset: string;
7581
7621
  payTo: string;
@@ -7585,6 +7625,11 @@ interface X402Requirements {
7585
7625
  version?: string;
7586
7626
  [k: string]: unknown;
7587
7627
  };
7628
+ /** v1-only fields, preserved so the retry can echo the requirement verbatim. */
7629
+ resource?: string;
7630
+ description?: string;
7631
+ mimeType?: string;
7632
+ outputSchema?: unknown;
7588
7633
  }
7589
7634
  /** EIP-712 typed data the FE must sign with the connected wallet. */
7590
7635
  interface X402TypedData {
@@ -7621,19 +7666,16 @@ interface X402Challenge {
7621
7666
  body?: unknown;
7622
7667
  headers?: Record<string, string>;
7623
7668
  };
7669
+ /** Protocol version detected from the 402 — decides the retry wire format. */
7670
+ x402Version: X402Version;
7624
7671
  requirements: X402Requirements;
7625
7672
  authorization: X402Authorization;
7626
7673
  typedData: X402TypedData;
7627
- /** The signed wire payload, missing only `payload.signature`. */
7628
- paymentDraft: {
7629
- x402Version: number;
7630
- payload: {
7631
- authorization: X402Authorization;
7632
- };
7633
- resource?: unknown;
7634
- accepted: X402Requirements;
7635
- extensions?: unknown;
7636
- };
7674
+ /** EVM chain id resolved from `requirements.network` (both version formats). */
7675
+ chainId: number;
7676
+ /** v2-only passthrough: the `resource` / `extensions` objects echoed on retry. */
7677
+ resource?: unknown;
7678
+ extensions?: unknown;
7637
7679
  /** The user's original question, so phase 2 can synthesize an answer. */
7638
7680
  userQuery?: string;
7639
7681
  }
@@ -7644,7 +7686,38 @@ type X402Outcome = {
7644
7686
  status: 'payment_required';
7645
7687
  challenge: X402Challenge;
7646
7688
  };
7647
- /** Build the challenge (authorization + typed data + replay payload) from a 402. */
7689
+ /** Settlement receipt the server returns after a successful paid request. */
7690
+ interface X402Receipt {
7691
+ success: boolean;
7692
+ errorReason?: string;
7693
+ transaction: string;
7694
+ network: string;
7695
+ payer: string;
7696
+ }
7697
+ /** The 402 challenge as it arrives on the wire, before normalization. */
7698
+ interface RawPaymentRequired {
7699
+ x402Version?: number;
7700
+ accepts?: Array<Record<string, unknown>>;
7701
+ resource?: unknown;
7702
+ extensions?: unknown;
7703
+ error?: string;
7704
+ }
7705
+ /**
7706
+ * Read the 402 challenge from EITHER transport and report which version it is.
7707
+ *
7708
+ * v2 puts a base64 `PaymentRequired` in the `PAYMENT-REQUIRED` header; v1 puts a
7709
+ * plain-JSON `PaymentRequirementsResponse` in the response BODY. The header is
7710
+ * checked first because it is unambiguous — a v2 server may also write a body,
7711
+ * but a v1 server never writes that header.
7712
+ *
7713
+ * Returns `null` when the response carries no x402 challenge at all (so a plain
7714
+ * 402 from a non-x402 API is passed through untouched rather than misread).
7715
+ */
7716
+ declare function readPaymentRequired(res: ApiResponse): {
7717
+ version: X402Version;
7718
+ payload: RawPaymentRequired;
7719
+ } | null;
7720
+ /** Build the challenge (authorization + typed data) from a 402, for either version. */
7648
7721
  declare function buildChallenge(res: ApiResponse, req: X402RequestSpec, payer: string, userQuery?: string): X402Challenge;
7649
7722
  /**
7650
7723
  * Make the request. Returns the data when free/already-paid, or a challenge to
@@ -7656,18 +7729,99 @@ declare function requestWithX402(client: ApiClient, req: X402RequestSpec, payer:
7656
7729
  * return the unlocked data. Throws with the facilitator's reason on failure.
7657
7730
  */
7658
7731
  declare function completeX402(client: ApiClient, challenge: X402Challenge, signature: string): Promise<unknown>;
7659
- /** Encode the signed payment as the `PAYMENT-SIGNATURE` retry header. */
7732
+ /**
7733
+ * Does this response carry an x402 challenge? True for either transport — the v2
7734
+ * `PAYMENT-REQUIRED` header or a v1 JSON body with an `accepts` array.
7735
+ *
7736
+ * Use this to tell "the resource wants payment" apart from an ordinary 402
7737
+ * (a quota error, a proxy's own 402) that must NOT open a payment prompt.
7738
+ */
7739
+ declare function isPaymentRequired(res: ApiResponse): boolean;
7740
+ /**
7741
+ * Why a paid retry was rejected, from whichever channel the server used: the
7742
+ * settlement receipt's `errorReason` (e.g. "insufficient_funds") or the
7743
+ * re-issued challenge's `error` (e.g. "invalid_exact_evm_insufficient_balance").
7744
+ * Covers both versions, since each carries these in a different place.
7745
+ *
7746
+ * Returns the bare reason, or `null` when the response explains nothing — see
7747
+ * {@link paymentFailureReason} for the caller-facing, prefixed message.
7748
+ */
7749
+ declare function readPaymentError(res: ApiResponse): string | null;
7750
+ /**
7751
+ * Encode the signed payment as the retry header for the challenge's version.
7752
+ *
7753
+ * v1 → `X-PAYMENT` with a FLAT payload (`{x402Version, scheme, network, payload}`).
7754
+ * v2 → `PAYMENT-SIGNATURE` with the nested payload (`{accepted, resource, payload}`).
7755
+ *
7756
+ * `scheme` / `network` / `accepted` are echoed exactly as the server sent them,
7757
+ * because facilitators match the retry against the original requirement.
7758
+ */
7660
7759
  declare function encodeSignedHeader(challenge: X402Challenge, signature: string): Record<string, string>;
7760
+ /**
7761
+ * Decode the settlement receipt the server returns on a successful paid call
7762
+ * (`PAYMENT-RESPONSE` in v2, `X-PAYMENT-RESPONSE` in v1). Returns `null` when
7763
+ * the server sent none — the receipt is informational, never required.
7764
+ */
7765
+ declare function readReceipt(res: ApiResponse): X402Receipt | null;
7661
7766
  /** Human-readable payment details for a confirmation UI, derived from a challenge. */
7662
- declare function displayFromChallenge(challenge: X402Challenge): {
7767
+ interface X402Display {
7768
+ /** Human amount, already scaled by the token's on-chain `decimals()` (e.g. "0.01"). */
7663
7769
  amount: string;
7770
+ /** The payment token's on-chain `symbol()`, falling back to the 402's domain name. */
7664
7771
  asset: string;
7772
+ /** Raw smallest-unit amount, exactly as the resource demanded it. */
7773
+ amountRaw: string;
7774
+ /** On-chain `decimals()`, or null when the token could not be read. */
7775
+ decimals: number | null;
7776
+ /** Payment token contract address. */
7777
+ assetAddress: string;
7778
+ /**
7779
+ * CANONICAL CAIP-2 network id (`"eip155:8453"`), normalized so a v1 and a v2
7780
+ * challenge for the same chain produce the same value. Falls back to the raw
7781
+ * identifier only when the chain could not be resolved.
7782
+ *
7783
+ * This is NOT what the server sent for v1 (which uses names like
7784
+ * `"base-sepolia"`) — see {@link networkRaw} for that. Display code should
7785
+ * prefer {@link networkLabel}, and chain logic {@link chainId}.
7786
+ */
7665
7787
  network: string;
7788
+ /**
7789
+ * The network id exactly as the server sent it — v1 `"base-sepolia"`, v2
7790
+ * `"eip155:84532"`. For debugging and echoing back only; never key on it,
7791
+ * since its format depends on the protocol version.
7792
+ */
7793
+ networkRaw: string;
7794
+ /**
7795
+ * Decimal EVM chain id, already resolved from EITHER protocol version's
7796
+ * network format (v2 CAIP-2 or a v1 legacy name).
7797
+ *
7798
+ * Hosts should key on THIS rather than parsing `network` themselves: the two
7799
+ * versions encode the chain differently, so a host-side parser would need to
7800
+ * know both formats and the v1 name table to avoid silently failing on one of
7801
+ * them. Typed nullable for forward compatibility with non-EVM schemes; for a
7802
+ * challenge from {@link buildChallenge} it is always set, since a network that
7803
+ * cannot be resolved is rejected before a challenge is produced.
7804
+ */
7805
+ chainId: number | null;
7666
7806
  networkLabel: string;
7667
7807
  payTo: string;
7668
7808
  description?: string;
7669
7809
  resourceUrl?: string;
7670
- };
7810
+ }
7811
+ /**
7812
+ * Build the confirmation-UI payload for a challenge.
7813
+ *
7814
+ * The 402 states its price in the token's SMALLEST unit and does not carry the
7815
+ * token's symbol (`extra.name` is the EIP-712 domain name — "USD Coin", not
7816
+ * "USDC" — and is absent on many tokens). So this reads `symbol()` + `decimals()`
7817
+ * for the payment token in ONE Multicall3 round-trip and formats the amount by
7818
+ * those decimals, rather than showing "10000" or assuming 6-dp USDC.
7819
+ *
7820
+ * Best-effort: if the chain is unknown to the RPC layer or the reads fail, the
7821
+ * amount stays the raw smallest-unit string and `decimals` is null, so a wrong
7822
+ * scale is never shown as if it were a real price.
7823
+ */
7824
+ declare function displayFromChallenge(challenge: X402Challenge): Promise<X402Display>;
7671
7825
  /**
7672
7826
  * Build a global {@link X402RetryHandler} for {@link setX402Handler}: on a 402 it
7673
7827
  * builds the challenge, asks the host signer to sign, and returns the
@@ -8079,4 +8233,4 @@ declare class AbortError extends Error {
8079
8233
  */
8080
8234
  declare function isAbortError(err: unknown): boolean;
8081
8235
 
8082
- export { AI_AGENT_TOOL_NAMES, AbortError, type AddLiquidityFormProps, type AddLiquiditySummary, type AffiliateFee, type AgentConfig, AgentCore, type AgentResponse, ApproveTokenTool, BaseNftAiTool, BaseSwapService, BaseTool, BaseWalletActionTool, type BuyTokenConfirmTxProps, type BuyTokenSide, BuyTokenTool, type ChainMeta, type ChainRef, type ChainSelector, ChatHistory, type ChatMessage, type ChatOptions, type ChatRole, type CheckApprovalParams, type CheckApprovalResult, type ConfirmAddLiquidityTxProps, type CortexResponse, DEFAULT_CHAIN, DEFAULT_PROVIDER, DEFAULT_RPC_BY_CHAIN, DebridgeAdapter, type DecodedCall, type DecodedEvent, type DecodedParam, type DefaultSubagentName, type DefiPosition, type DefiPositionDetails, type DefiPositionToken, type DefiProtocolSummary, EstimatePoolYieldTool, type EstimatePoolYieldToolConfig, type ExchangeProviderConfig, type ExecuteSwapParams, type ExecuteSwapResult, GeminiProvider, GeminiSearchAiTool, type GeminiSearchAiToolConfig, HEX_TO_PANTOGRAPH, type HolderChangePeriod, type HolderSupplyTier, type HttpMethod, type IngestKnowledgeBaseInput, type IngestKnowledgeBaseResult, type InputTokenInfo, type KBSearchResult, KnowledgeBase, type KnowledgeBaseEntry, type KnowledgeBaseProvider, type LLMProvider, type LLMProviderConfig, type LLMResponse, type LLMToolCall, ManageLiquidityRedirectTool, type MarketplaceLink, type MoralisApiResponse, MoralisService, type MoralisServiceConfig, NFC_AGENT_TOOL_NAMES, NFC_AMAZON_DEFAULT_DOMAIN, NFC_AMAZON_DOMAINS, type NFTCollectionItem, NFTContractInfoTool, type NFTContractMetadata, type NFTItem, type NFTLastSale, type NFTMetadata, NFTMetadataTool, NFT_AGENT_TOOL_NAMES, type NativeTokenInfo, NfcBuyTool, NfcInfoTool, type NftTransferLastSale, NoFormTool, type NoFormToolMessages, OpenAddLiquidityFormTool, type OpenAddLiquidityFormToolConfig, POOL_AGENT_TOOL_NAMES, PantographService, type PantographServiceConfig, type PaymentToken, PoolByAddressTool, type PoolByAddressToolConfig, PoolDetailTool, type PoolDetailToolConfig, type PoolDisplayInfo, PoolFallbackAiTool, type PoolFallbackAiToolConfig, type PoolOnchainInfo, PoolPriceRangesTool, type PoolPriceRangesToolConfig, PoolSearchTool, type PoolSearchToolConfig, PoolService, type PoolServiceConfig, type PresetInputs, PreviewAddLiquidityTool, type PreviewAddLiquidityToolConfig, type PriceBounds, type PriceRangePrefill, type ProviderName, type QuickRate, type RangePreset, type ReActPhase, type ReActStep, type ReActTrace, RelayAdapter, type ResolvedRange, Router, type RouterAssignment, type RouterDecision, SUPPORTED_CHAINS, SUPPORTED_CHAINS_LABEL, SWAP_PROVIDER_CONFIG, SendNativeTool, SendNftTool, SendTokenTool, type StorageProvider, Subagent, type SubagentCard, type SubagentOptions, type SubagentParams, type SubagentResult, type SubagentTask, type SubagentToggles, SubgraphAddPoolTool, type SubgraphAddPoolToolConfig, SubgraphCoinPoolPairsTool, type SubgraphCoinPoolPairsToolConfig, SubgraphPoolByAddressTool, type SubgraphPoolByAddressToolConfig, SubgraphPoolByPositionIdTool, type SubgraphPoolByPositionIdToolConfig, SubgraphPoolSearchTool, type SubgraphPoolSearchToolConfig, SubgraphPositionDetailTool, type SubgraphPositionDetailToolConfig, SubgraphTrendingPoolsTool, type SubgraphTrendingPoolsToolConfig, type SuggestedAction, Summarizer, type SupportedChainId, type SupportedChainName, type SwapQuoteParams, type SwapQuoteResult, type SwapServiceConfig, SwapServiceFactory, type SwapTokenConfirmTxProps, SwapTokenTool, type SwapTxData, Synthesizer, TOKEN_AGENT_TOOL_NAMES, TRANSFER_TOPIC, TRENDING_DEFAULT_BY_HEX_CHAIN, type TokenAnalyticsResponse, type TokenAnalyticsTimeframeBuckets, TokenAnalyticsTool, type TokenAnalyticsToolConfig, type TokenApproval, type TokenApprovalSpender, type TokenApprovalToken, type TokenBalance, type TokenDisplay, type TokenHoldersResponse, TokenHoldersTool, type TokenHoldersToolConfig, TokenInfoTool, type TokenInfoToolConfig, type TokenMetadata, type TokenScoreMetrics, type TokenScoreResponse, type TokenScoreSupply, type TokenScoreTimeframeBuckets, TokenScoreTool, type TokenScoreToolConfig, type Tool, type ToolDefinition, type ToolKind, type ToolParameter, ToolRegistry, type ToolResult, type TopGainerTimeFrames, type TopGainerToken, type TopGainersTimeFrame, TopGainersTool, type TopGainersToolConfig, TopPoolsTool, type TopPoolsToolConfig, type TrackStatus, type TrackTransactionParams, type TrackTransactionResult, type TransactionByHashResponse, TransactionByHashTool, type TransactionByHashToolConfig, type TransactionLog, type TransactionReceipt, type TransactionReceiptLog, type TrendingToken, type TrendingTokenTimeframeBuckets, TrendingTokensTool, type TrendingTokensToolConfig, type UIPayload, UNISWAP_CHAIN_SLUG, type UnsignedTx, type UpstashEmbedStrategy, type UpstashFusionAlgorithm, type UpstashKBUpsertEntry, UpstashKnowledgeBase, type UpstashKnowledgeBaseConfig, type UserContext, type VectorKBConfig, WALLET_ACTION_AGENT_TOOL_NAMES, WALLET_AGENT_TOOL_NAMES, type WalletActionProps, type WalletActionType, type WalletApprovalsResponse, WalletApprovalsTool, type WalletApprovalsToolConfig, type WalletDefiPositionSummary, WalletDefiPositionsTool, type WalletDefiPositionsToolConfig, type WalletDefiPositionsV1Response, type WalletDefiProtocolPositionsResponse, WalletDefiProtocolPositionsTool, type WalletDefiProtocolPositionsToolConfig, type WalletDefiProtocolPositionsV1Response, type WalletDefiSummaryResponse, WalletDefiSummaryTool, type WalletDefiSummaryToolConfig, type WalletDefiSummaryV1Response, type WalletHistoryCategory, type WalletHistoryContractInteraction, type WalletHistoryErc20Transfer, type WalletHistoryItem, type WalletHistoryNativeTransfer, type WalletHistoryNftTransfer, type WalletHistoryResponse, WalletHistoryTool, type WalletHistoryToolConfig, WalletNFTsTool, type WalletNFTsToolConfig, type WalletNftCardProps, type WalletNftListProps, type WalletNftTransferItem, type WalletNftTransfersResponse, WalletNftTransfersTool, type WalletNftTransfersToolConfig, type WalletPnlDaysWindow, type WalletPnlResponse, type WalletPnlSummaryResponse, WalletPnlSummaryTool, type WalletPnlSummaryToolConfig, type WalletPnlTokenItem, WalletPnlTool, type WalletPnlToolConfig, WalletTokenBalancesTool, type WalletTokenBalancesToolConfig, type WalletTokenTransferItem, type WalletTokenTransfersResponse, WalletTokenTransfersTool, type WalletTokenTransfersToolConfig, type WebsiteTrustExtraData, type WebsiteTrustInput, WebsiteTrustKeyringAgent, type WebsiteTrustKeyringAgentConfig, type WebsiteTrustResult, type X402Authorization, type X402Challenge, type X402Outcome, type X402PaymentRequiredProps, type X402RequestSpec, type X402Requirements, type X402SignRequest, type X402Signer, type X402TypedData, ZERO_ADDRESS, amazonDomainForLanguage, apiClient, buildChallenge, buildRangePresets, buildUniswapPoolUrl, clampTick, completeX402, configureSupportedChains, createAiAgent, createDefaultSubagents, createNfcAgent, createNftAgent, createPoolAgent, createTokenAgent, createWalletActionAgent, createWalletAgent, createX402SignatureProvider, displayFromChallenge, encodeSignedHeader, ethCallAt, ethCallByChain, fetchTopMarketplaces, getAffiliateFee, getChainMeta, getDefaultRpcUrl, getGatewayAddress, getGatewayChains, getNativeTokenInfo, getPositionManagerAddress, getProviderByChain, ingestKnowledgeBase, isAbortError, nfcAmazonSearchUrl, normaliseCountry, normalizePriceRangeToPool, priceToTick, registerMaybeNoForm, requestWithX402, resolveNfcShopLinks, resolveRpcUrl, roundTickToSpacing, rpcCall, setRpcOverrides, swapServiceFactory, tickToPrice, toPantographChain };
8236
+ export { AI_AGENT_TOOL_NAMES, AbortError, type AddLiquidityFormProps, type AddLiquiditySummary, type AffiliateFee, type AgentConfig, AgentCore, type AgentResponse, ApproveTokenTool, BaseNftAiTool, BaseSwapService, BaseTool, BaseWalletActionTool, type BuyTokenConfirmTxProps, type BuyTokenSide, BuyTokenTool, type ChainMeta, type ChainRef, type ChainSelector, ChatHistory, type ChatMessage, type ChatOptions, type ChatRole, type CheckApprovalParams, type CheckApprovalResult, type ConfirmAddLiquidityTxProps, type CortexResponse, DEFAULT_CHAIN, DEFAULT_PROVIDER, DEFAULT_RPC_BY_CHAIN, DebridgeAdapter, type DecodedCall, type DecodedEvent, type DecodedParam, type DefaultSubagentName, type DefiPosition, type DefiPositionDetails, type DefiPositionToken, type DefiProtocolSummary, EstimatePoolYieldTool, type EstimatePoolYieldToolConfig, type ExchangeProviderConfig, type ExecuteSwapParams, type ExecuteSwapResult, GeminiProvider, GeminiSearchAiTool, type GeminiSearchAiToolConfig, HEX_TO_PANTOGRAPH, type HolderChangePeriod, type HolderSupplyTier, type HttpMethod, type IngestKnowledgeBaseInput, type IngestKnowledgeBaseResult, type InputTokenInfo, type KBSearchResult, KnowledgeBase, type KnowledgeBaseEntry, type KnowledgeBaseProvider, type LLMProvider, type LLMProviderConfig, type LLMResponse, type LLMToolCall, ManageLiquidityRedirectTool, type MarketplaceLink, type MoralisApiResponse, MoralisService, type MoralisServiceConfig, NFC_AGENT_TOOL_NAMES, NFC_AMAZON_DEFAULT_DOMAIN, NFC_AMAZON_DOMAINS, type NFTCollectionItem, NFTContractInfoTool, type NFTContractMetadata, type NFTItem, type NFTLastSale, type NFTMetadata, NFTMetadataTool, NFT_AGENT_TOOL_NAMES, type NativeTokenInfo, NfcBuyTool, NfcInfoTool, type NftTransferLastSale, NoFormTool, type NoFormToolMessages, OpenAddLiquidityFormTool, type OpenAddLiquidityFormToolConfig, POOL_AGENT_TOOL_NAMES, PantographService, type PantographServiceConfig, type PaymentToken, PoolByAddressTool, type PoolByAddressToolConfig, PoolDetailTool, type PoolDetailToolConfig, type PoolDisplayInfo, PoolFallbackAiTool, type PoolFallbackAiToolConfig, type PoolOnchainInfo, PoolPriceRangesTool, type PoolPriceRangesToolConfig, PoolSearchTool, type PoolSearchToolConfig, PoolService, type PoolServiceConfig, type PresetInputs, PreviewAddLiquidityTool, type PreviewAddLiquidityToolConfig, type PriceBounds, type PriceRangePrefill, type ProviderName, type QuickRate, type RangePreset, type ReActPhase, type ReActStep, type ReActTrace, RelayAdapter, type ResolvedRange, Router, type RouterAssignment, type RouterDecision, SUPPORTED_CHAINS, SUPPORTED_CHAINS_LABEL, SWAP_PROVIDER_CONFIG, SendNativeTool, SendNftTool, SendTokenTool, type StorageProvider, Subagent, type SubagentCard, type SubagentOptions, type SubagentParams, type SubagentResult, type SubagentTask, type SubagentToggles, SubgraphAddPoolTool, type SubgraphAddPoolToolConfig, SubgraphCoinPoolPairsTool, type SubgraphCoinPoolPairsToolConfig, SubgraphPoolByAddressTool, type SubgraphPoolByAddressToolConfig, SubgraphPoolByPositionIdTool, type SubgraphPoolByPositionIdToolConfig, SubgraphPoolSearchTool, type SubgraphPoolSearchToolConfig, SubgraphPositionDetailTool, type SubgraphPositionDetailToolConfig, SubgraphTrendingPoolsTool, type SubgraphTrendingPoolsToolConfig, type SuggestedAction, Summarizer, type SupportedChainId, type SupportedChainName, type SwapQuoteParams, type SwapQuoteResult, type SwapServiceConfig, SwapServiceFactory, type SwapTokenConfirmTxProps, SwapTokenTool, type SwapTxData, Synthesizer, TOKEN_AGENT_TOOL_NAMES, TRANSFER_TOPIC, TRENDING_DEFAULT_BY_HEX_CHAIN, type TokenAnalyticsResponse, type TokenAnalyticsTimeframeBuckets, TokenAnalyticsTool, type TokenAnalyticsToolConfig, type TokenApproval, type TokenApprovalSpender, type TokenApprovalToken, type TokenBalance, type TokenDisplay, type TokenHoldersResponse, TokenHoldersTool, type TokenHoldersToolConfig, TokenInfoTool, type TokenInfoToolConfig, type TokenMetadata, type TokenScoreMetrics, type TokenScoreResponse, type TokenScoreSupply, type TokenScoreTimeframeBuckets, TokenScoreTool, type TokenScoreToolConfig, type Tool, type ToolDefinition, type ToolKind, type ToolParameter, ToolRegistry, type ToolResult, type TopGainerTimeFrames, type TopGainerToken, type TopGainersTimeFrame, TopGainersTool, type TopGainersToolConfig, TopPoolsTool, type TopPoolsToolConfig, type TrackStatus, type TrackTransactionParams, type TrackTransactionResult, type TransactionByHashResponse, TransactionByHashTool, type TransactionByHashToolConfig, type TransactionLog, type TransactionReceipt, type TransactionReceiptLog, type TrendingToken, type TrendingTokenTimeframeBuckets, TrendingTokensTool, type TrendingTokensToolConfig, type UIPayload, UNISWAP_CHAIN_SLUG, type UnsignedTx, type UpstashEmbedStrategy, type UpstashFusionAlgorithm, type UpstashKBUpsertEntry, UpstashKnowledgeBase, type UpstashKnowledgeBaseConfig, type UserContext, type VectorKBConfig, WALLET_ACTION_AGENT_TOOL_NAMES, WALLET_AGENT_TOOL_NAMES, type WalletActionProps, type WalletActionType, type WalletApprovalsResponse, WalletApprovalsTool, type WalletApprovalsToolConfig, type WalletDefiPositionSummary, WalletDefiPositionsTool, type WalletDefiPositionsToolConfig, type WalletDefiPositionsV1Response, type WalletDefiProtocolPositionsResponse, WalletDefiProtocolPositionsTool, type WalletDefiProtocolPositionsToolConfig, type WalletDefiProtocolPositionsV1Response, type WalletDefiSummaryResponse, WalletDefiSummaryTool, type WalletDefiSummaryToolConfig, type WalletDefiSummaryV1Response, type WalletHistoryCategory, type WalletHistoryContractInteraction, type WalletHistoryErc20Transfer, type WalletHistoryItem, type WalletHistoryNativeTransfer, type WalletHistoryNftTransfer, type WalletHistoryResponse, WalletHistoryTool, type WalletHistoryToolConfig, WalletNFTsTool, type WalletNFTsToolConfig, type WalletNftCardProps, type WalletNftListProps, type WalletNftTransferItem, type WalletNftTransfersResponse, WalletNftTransfersTool, type WalletNftTransfersToolConfig, type WalletPnlDaysWindow, type WalletPnlResponse, type WalletPnlSummaryResponse, WalletPnlSummaryTool, type WalletPnlSummaryToolConfig, type WalletPnlTokenItem, WalletPnlTool, type WalletPnlToolConfig, WalletTokenBalancesTool, type WalletTokenBalancesToolConfig, type WalletTokenTransferItem, type WalletTokenTransfersResponse, WalletTokenTransfersTool, type WalletTokenTransfersToolConfig, type WebsiteTrustExtraData, type WebsiteTrustInput, WebsiteTrustKeyringAgent, type WebsiteTrustKeyringAgentConfig, type WebsiteTrustResult, type X402Authorization, type X402Challenge, type X402Display, type X402Outcome, type X402PaymentRequiredProps, type X402Receipt, type X402RequestSpec, type X402Requirements, type X402SignRequest, type X402Signer, type X402TypedData, type X402Version, ZERO_ADDRESS, amazonDomainForLanguage, apiClient, buildChallenge, buildRangePresets, buildUniswapPoolUrl, clampTick, completeX402, configureSupportedChains, createAiAgent, createDefaultSubagents, createNfcAgent, createNftAgent, createPoolAgent, createTokenAgent, createWalletActionAgent, createWalletAgent, createX402SignatureProvider, displayFromChallenge, encodeSignedHeader, ethCallAt, ethCallByChain, fetchTopMarketplaces, getAffiliateFee, getChainMeta, getDefaultRpcUrl, getGatewayAddress, getGatewayChains, getNativeTokenInfo, getPositionManagerAddress, getProviderByChain, ingestKnowledgeBase, isAbortError, isPaymentRequired, nfcAmazonSearchUrl, normaliseCountry, normalizePriceRangeToPool, priceToTick, readPaymentError, readPaymentRequired, readReceipt, registerMaybeNoForm, requestWithX402, resolveNfcShopLinks, resolveRpcUrl, roundTickToSpacing, rpcCall, setRpcOverrides, swapServiceFactory, tickToPrice, toPantographChain };