/** * Coin Railz Client v1.0.3 * Lightweight x402 micropayment SDK for AI agents and bots * * Features: * - Zero-config start: Works without API key for free-tier services * - Auto demo key: Fetches trial credits on first 402 response * - Telemetry: Anonymous usage tracking to improve SDK experience * - Smart retries: Auto-retries with demo key on payment required */ import type { CoinRailzConfig, ServiceResponse, GasPriceResponse, TokenMetadataResponse, TokenPriceResponse, TradeSignalResponse, WhaleAlertResponse, SentimentResponse, DexLiquidityResponse, ArbitrageScannerResponse, PredictionMarketResponse, AgentWalletResponse, ContractScanResponse, PortfolioOptimizationResponse, ServiceCatalog } from './types.js'; export declare const SDK_VERSION = "1.2.0"; export declare class CoinRailzClient { private apiKey; private readonly baseUrl; private readonly timeoutMs; private readonly disableTelemetry; constructor(config?: CoinRailzConfig); private sendTelemetry; private fetchDemoKey; private request; /** * Set or update the API key */ setApiKey(apiKey: string): void; /** * Check if client has an API key configured */ hasApiKey(): boolean; /** * Get the current install ID (for debugging) */ getInstallId(): string; /** * Call any x402 service by name */ call(service: string, payload?: unknown): Promise>; /** * Get the full service catalog */ getCatalog(): Promise>; /** * Ping endpoint - verify API connectivity */ ping(): Promise>; /** * Get real-time gas prices across chains (FREE) */ gasPriceOracle(params?: { chain?: string; }): Promise>; /** * Get token metadata (FREE) */ tokenMetadata(params: { chain: string; address: string; }): Promise>; /** * Get token price in USD */ tokenPrice(params: { chain: string; address: string; }): Promise>; /** * Get AI-powered trade signals */ tradeSignals(params: { token: string; chain?: string; }): Promise>; /** * Get whale movement alerts */ whaleAlerts(params?: { chain?: string; minValueUsd?: number; }): Promise>; /** * Get social sentiment analysis */ sentimentAnalysis(params: { token: string; }): Promise>; /** * Get DEX liquidity analysis */ dexLiquidity(params: { chain: string; token: string; }): Promise>; /** * Scan for cross-chain arbitrage opportunities */ arbitrageScanner(params?: { minSpreadPercent?: number; }): Promise>; /** * Scan smart contract for vulnerabilities */ contractScan(params: { chain: string; address: string; }): Promise>; /** * Get portfolio optimization recommendations */ portfolioOptimization(params: { holdings: Array<{ token: string; amount: number; }>; riskTolerance?: 'low' | 'medium' | 'high'; }): Promise>; /** * Get trending tokens */ trendingTokens(params?: { chain?: string; limit?: number; }): Promise>; /** * Get token correlation matrix */ correlationMatrix(params: { tokens: string[]; }): Promise>; /** * Get prediction market odds */ predictionMarketOdds(params: { marketSlug?: string; query?: string; }): Promise>; /** * Get Polymarket events */ polymarketEvents(params?: { category?: string; }): Promise>; /** * Prediction market spread — cross-platform arbitrage between Polymarket and Kalshi * $0.25 per request */ predictionMarketSpread(params?: { market?: string; }): Promise>; /** * Robinhood Chain token price — live price + pool data * $0.60 per request (day-1 exclusivity premium) */ robinhoodTokenPrice(params: { token: string; }): Promise>; /** * Robinhood Chain DEX pools — top liquidity pools for trading/routing * $1.25 per request */ robinhoodDexPools(params?: { limit?: number; }): Promise>; /** * Robinhood Chain stats — block, gas, total DEX volume, active pools * $0.75 per request */ robinhoodChainStats(): Promise>; /** * RH stock price — live Chainlink price feed for RH stock tokens (AAPL, NVDA, SPY, etc) * $0.05 per request */ rhStockPrice(params: { symbol: string; }): Promise>; /** * RH USDC bridge — bridge USDC (Base) to USDG (Robinhood Chain) via Across Protocol * $0.75 per request */ rhBridgeUsdc(params: { amount: number; recipient?: string; }): Promise>; /** * B20 token info — ERC-20 metadata + compliance mode/freeze state * $0.05 per request */ b20TokenInfo(params: { address: string; chain?: string; }): Promise>; /** * B20 transfer check — simulate transfer against live freeze/blocklist/allowlist * $0.10 per request */ b20TransferCheck(params: { token: string; from: string; to: string; amount: string; }): Promise>; /** * B20 compliance scan — multi-issuer compliance scan for a wallet address * $0.25 per request */ b20ComplianceScan(params: { address: string; }): Promise>; /** * RWA NAV oracle — synthetic market-based NAV estimate + EIP-712 attestation * $0.50 per request */ rwaNavOracle(params: { asset: string; }): Promise>; /** * Tokenized yield compare — live yield comparison: Ondo/Backed/Superstate/Mountain/OpenEden * $0.25 per request */ tokenizedYieldCompare(params?: { minApy?: number; }): Promise>; /** * Create an agent wallet (standard method) */ createAgentWallet(params?: { label?: string; metadata?: Record; }): Promise>; /** * Build a transaction */ transactionBuilder(params: { chain: string; from: string; to: string; value?: string; data?: string; }): Promise>; /** * Get batch quote for multiple swaps */ batchQuote(params: { swaps: Array<{ tokenIn: string; tokenOut: string; amount: string; }>; }): Promise>; /** * Cross-chain bridge routing */ chainBridge(params: { fromChain: string; toChain: string; token: string; amount: string; }): Promise>; /** * Get wallet risk analysis */ walletRisk(params: { address: string; chain?: string; }): Promise>; /** * Get risk metrics */ riskMetrics(params: { token: string; }): Promise>; /** * Credit risk score */ creditRiskScore(params: { address: string; chain?: string; }): Promise>; /** * Fraud detection analysis */ fraudDetection(params: { address: string; chain?: string; }): Promise>; /** * Compliance check for address */ complianceCheck(params: { address: string; chain?: string; }): Promise>; /** * Compliance consultation */ complianceConsultation(params: { query: string; }): Promise>; /** * Property valuation analysis */ propertyValuation(params: { address?: string; propertyId?: string; }): Promise>; /** * Lease analysis */ leaseAnalysis(params: { propertyId: string; }): Promise>; /** * Construction progress monitoring */ constructionProgress(params: { projectId: string; }): Promise>; /** * Token sentiment analysis (alternative endpoint) */ tokenSentiment(params: { tokenSymbol: string; }): Promise>; /** * Trading signal (alternative endpoint) */ tradingSignal(params: { token: string; chain?: string; }): Promise>; /** * Portfolio tracker */ portfolioTracker(params: { address: string; chains?: string[]; }): Promise>; /** * Token approval manager */ approvalManager(params: { tokenAddress: string; spenderAddress: string; ownerAddress: string; chain: string; amount?: string; }): Promise>; /** * Multi-chain balance lookup */ multiChainBalance(params: { address: string; chains?: string[]; }): Promise>; /** * Smart contract security audit */ smartContractAudit(params: { address: string; chain: string; }): Promise>; /** * Stock market sentiment analysis * AI-powered stock sentiment with news, technicals, and institutional activity * $0.40 per request */ stockSentiment(params: { symbol: string; }): Promise>; /** * Forex sentiment analysis * AI-powered forex sentiment with central bank policy and economic indicators * $0.40 per request */ forexSentiment(params: { pair: string; }): Promise>; /** * Polymarket odds lookup */ polymarketOdds(params: { marketId?: string; slug?: string; }): Promise>; /** * Polymarket search */ polymarketSearch(params: { query: string; category?: string; }): Promise>; /** * Create instant agent wallet */ instantAgentWallet(params?: { label?: string; }): Promise>; /** * Verified agent identity (ERC-8004) */ verifiedAgentIdentity(params: { agentAddress: string; }): Promise>; } export default CoinRailzClient; //# sourceMappingURL=client.d.ts.map