import { ApiResponse, User, Token, Transaction, AIStrategy, AIOrder, NFT, NFTCollection, Contract, ContractReadParams, ContractWriteParams, ContractDeployParams, OfframpQuote, OfframpRequest, OfframpTransaction, BillProvider, BillPayment, StakingPool, StakingPosition, UserProfile, UserSettings, Notification, ReferralInfo, Referral, BridgeQuote, BridgeTransaction, GasEstimate, GasPrice, WalletImportRequest, PortfolioAnalytics, TradingCondition, LimitOrder, Webhook, CreateWebhookInput, UpdateWebhookInput, WebhookDelivery, AdminListOptions, PaginatedResult, AdminUser, AdminProject, SystemStats, SystemLog, RateLimitInfo, StrategyCategory, AINavSnapshot, AIMarketData, AITradeExecution, CreateAIOrderRequest, AIOrderStatus, AIRedemptionResult, AIPortfolioSummary, AITradeAllocation } from './types/index.js';

/**
 * ONE Engine Client - The unified API gateway for all ONE Ecosystem services
 *
 * All wallet operations, onramp, swap, trading go through ONE Engine.
 * Thirdweb/Onramper/etc are internal to ONE Engine and hidden from clients.
 */

interface EngineAuthResponse {
    user: User;
    accessToken: string;
    refreshToken?: string;
    expiresIn: number;
}
interface EngineWalletBalance {
    address: string;
    totalUsd: number;
    change24h: number;
    changePercent24h: number;
    tokens: Token[];
}
interface EngineTransactionRequest {
    to: string;
    amount: string;
    tokenSymbol: string;
    chainId: number;
    memo?: string;
}
interface EngineTransactionResponse {
    txId: string;
    status: 'queued' | 'pending' | 'confirmed' | 'failed';
    txHash?: string;
    explorerUrl?: string;
}
interface OnrampSessionRequest {
    walletAddress: string;
    fiatCurrency?: string;
    fiatAmount?: number;
    cryptoCurrency?: string;
    cryptoNetwork?: string;
    paymentMethod?: string;
    redirectUrl?: string;
}
interface OnrampSession {
    sessionId: string;
    widgetUrl: string;
    expiresAt: string;
}
interface OnrampQuote {
    provider: string;
    fiatCurrency: string;
    fiatAmount: number;
    cryptoCurrency: string;
    cryptoAmount: number;
    rate: number;
    fees: {
        network: number;
        provider: number;
        total: number;
    };
    paymentMethod: string;
    estimatedTime: string;
}
interface OnrampTransaction {
    id: string;
    sessionId: string;
    status: 'pending' | 'processing' | 'completed' | 'failed' | 'expired';
    fiatAmount: number;
    fiatCurrency: string;
    cryptoAmount?: number;
    cryptoCurrency: string;
    walletAddress: string;
    txHash?: string;
    createdAt: string;
    completedAt?: string;
}
interface SwapQuoteRequest {
    fromToken: string;
    fromAmount: string;
    fromChainId: number;
    toToken: string;
    toChainId: number;
    walletAddress: string;
    slippage?: number;
}
interface SwapQuote {
    quoteId: string;
    fromToken: string;
    fromAmount: string;
    fromChainId: number;
    toToken: string;
    toAmount: string;
    toChainId: number;
    rate: number;
    priceImpact: number;
    estimatedGas: string;
    estimatedTime: string;
    fees: {
        gas: number;
        protocol: number;
        total: number;
    };
    expiresAt: string;
}
interface SwapExecuteRequest {
    quoteId: string;
    walletAddress: string;
    signature?: string;
}
interface SwapResult {
    swapId: string;
    status: 'pending' | 'confirming' | 'completed' | 'failed';
    txHash?: string;
    fromAmount: string;
    toAmount?: string;
}
declare class OneEngineClient {
    private baseUrl;
    private clientId;
    private secretKey?;
    private accessToken?;
    constructor(options?: {
        baseUrl?: string;
        clientId?: string;
        secretKey?: string;
    });
    /**
     * Set access token for authenticated requests
     */
    setAccessToken(token: string): void;
    /**
     * Clear access token
     */
    clearAccessToken(): void;
    private getHeaders;
    private request;
    /**
     * Send OTP to email for authentication
     */
    sendEmailOtp(email: string): Promise<ApiResponse<{
        message: string;
    }>>;
    /**
     * Verify OTP and get access token
     */
    verifyEmailOtp(email: string, otp: string): Promise<ApiResponse<EngineAuthResponse>>;
    /**
     * Authenticate with wallet signature
     */
    authWithWallet(walletAddress: string, signature: string, message: string): Promise<ApiResponse<EngineAuthResponse>>;
    /**
     * Refresh access token
     */
    refreshToken(refreshToken: string): Promise<ApiResponse<EngineAuthResponse>>;
    /**
     * Get current user
     */
    getCurrentUser(): Promise<ApiResponse<User>>;
    /**
     * Sign out
     */
    signOut(): Promise<ApiResponse<{
        success: boolean;
    }>>;
    /**
     * Get wallet balance across all chains
     */
    getWalletBalance(walletAddress: string, chains?: number[]): Promise<ApiResponse<EngineWalletBalance>>;
    /**
     * Get portfolio summary
     */
    getPortfolioSummary(walletAddress: string): Promise<ApiResponse<{
        totalValue: number;
        change24h: number;
        tokens: Token[];
    }>>;
    /**
     * Get user's wallets
     */
    getUserWallets(chainId?: number): Promise<ApiResponse<{
        wallets: any[];
        total: number;
    }>>;
    /**
     * Create a new wallet
     */
    createWallet(chainId?: number, type?: 'smart' | 'eoa' | 'multisig'): Promise<ApiResponse<{
        wallet: any;
        smartAccountAddress: string;
        personalAddress: string;
    }>>;
    /**
     * Get wallet transactions (placeholder - needs endpoint)
     */
    getWalletTransactions(walletAddress: string, options?: {
        limit?: number;
        offset?: number;
        chainId?: number;
    }): Promise<ApiResponse<{
        transactions: Transaction[];
        total: number;
    }>>;
    /**
     * Send native token or ERC20
     */
    sendTransaction(request: EngineTransactionRequest): Promise<ApiResponse<EngineTransactionResponse>>;
    /**
     * Get transaction status
     */
    getTransactionStatus(txId: string): Promise<ApiResponse<EngineTransactionResponse>>;
    /**
     * Get onramp quote
     */
    getOnrampQuote(fiatCurrency: string, fiatAmount: number, cryptoCurrency: string, paymentMethod?: string): Promise<ApiResponse<OnrampQuote[]>>;
    /**
     * Create onramp session (returns widget URL)
     */
    createOnrampSession(request: OnrampSessionRequest): Promise<ApiResponse<OnrampSession>>;
    /**
     * Get onramp session status
     */
    getOnrampStatus(sessionId: string): Promise<ApiResponse<OnrampTransaction>>;
    /**
     * Get supported currencies (fiat + crypto)
     */
    getSupportedCurrencies(): Promise<ApiResponse<{
        fiatCurrencies: string[];
        cryptoCurrencies: string[];
    }>>;
    /**
     * Get supported fiat currencies
     */
    getSupportedFiatCurrencies(): Promise<ApiResponse<string[]>>;
    /**
     * Get supported payment methods
     */
    getSupportedPaymentMethods(country?: string): Promise<ApiResponse<string[]>>;
    /**
     * Get swap quote
     */
    getSwapQuote(request: SwapQuoteRequest): Promise<ApiResponse<SwapQuote>>;
    /**
     * Execute swap
     */
    executeSwap(request: SwapExecuteRequest): Promise<ApiResponse<SwapResult>>;
    /**
     * Get swap status
     */
    getSwapStatus(swapId: string): Promise<ApiResponse<SwapResult>>;
    /**
     * Get supported tokens for swap
     */
    getSupportedSwapTokens(chainId?: number): Promise<ApiResponse<{
        tokens: Token[];
    }>>;
    /**
     * Get supported chains for swap
     */
    getSupportedSwapChains(): Promise<ApiResponse<{
        chains: {
            id: number;
            name: string;
        }[];
    }>>;
    /**
     * Get available AI trading strategies
     */
    getStrategies(): Promise<ApiResponse<AIStrategy[]>>;
    /**
     * Get strategy details
     */
    getStrategy(strategyId: string): Promise<ApiResponse<AIStrategy>>;
    /**
     * Get user's positions
     */
    getPositions(): Promise<ApiResponse<any[]>>;
    /**
     * Create investment order
     */
    createOrder(strategyId: string, amount: number, currency: string): Promise<ApiResponse<AIOrder>>;
    /**
     * Get user's orders
     */
    getUserOrders(): Promise<ApiResponse<AIOrder[]>>;
    /**
     * Get user's portfolio stats from positions
     */
    getPortfolioStats(): Promise<ApiResponse<{
        totalInvested: number;
        totalValue: number;
        totalPnl: number;
        totalPnlPercent: number;
        activePositions: number;
    }>>;
    /**
     * Get token prices
     */
    getTokenPrices(symbols: string[]): Promise<ApiResponse<Record<string, {
        price: number;
        change24h: number;
        marketCap?: number;
    }>>>;
    /**
     * Get market data overview
     */
    getMarketData(): Promise<ApiResponse<{
        totalMarketCap: number;
        totalVolume24h: number;
        btcDominance: number;
        markets: any[];
    }>>;
    /**
     * Get user's NFTs
     */
    getUserNFTs(walletAddress: string, options?: {
        chainId?: number;
        limit?: number;
        offset?: number;
    }): Promise<ApiResponse<{
        nfts: NFT[];
        total: number;
    }>>;
    /**
     * Get NFT details
     */
    getNFTDetails(contractAddress: string, tokenId: string, chainId: number): Promise<ApiResponse<NFT>>;
    /**
     * Get NFT collection
     */
    getNFTCollection(contractAddress: string, chainId: number): Promise<ApiResponse<NFTCollection>>;
    /**
     * Transfer NFT
     */
    transferNFT(params: {
        contractAddress: string;
        tokenId: string;
        chainId: number;
        to: string;
        tokenType?: 'ERC721' | 'ERC1155';
        amount?: number;
    }): Promise<ApiResponse<{
        txHash: string;
        status: string;
    }>>;
    /**
     * Get user's contracts
     */
    getUserContracts(options?: {
        chainId?: number;
        limit?: number;
        offset?: number;
    }): Promise<ApiResponse<{
        contracts: Contract[];
        total: number;
    }>>;
    /**
     * Get contract details
     */
    getContractDetails(address: string, chainId: number): Promise<ApiResponse<Contract>>;
    /**
     * Read contract (call view function)
     */
    readContract(params: ContractReadParams): Promise<ApiResponse<any>>;
    /**
     * Write to contract (execute transaction)
     */
    writeContract(params: ContractWriteParams): Promise<ApiResponse<{
        txHash: string;
        status: string;
    }>>;
    /**
     * Deploy contract
     */
    deployContract(params: ContractDeployParams): Promise<ApiResponse<{
        address: string;
        txHash: string;
        contract: Contract;
    }>>;
    /**
     * Get offramp quote
     */
    getOfframpQuote(cryptoCurrency: string, cryptoAmount: number, fiatCurrency: string, payoutMethod?: string): Promise<ApiResponse<OfframpQuote[]>>;
    /**
     * Create offramp transaction
     */
    createOfframpTransaction(request: OfframpRequest): Promise<ApiResponse<OfframpTransaction>>;
    /**
     * Get offramp transaction status
     */
    getOfframpStatus(transactionId: string): Promise<ApiResponse<OfframpTransaction>>;
    /**
     * Get supported payout methods
     */
    getSupportedPayoutMethods(country?: string): Promise<ApiResponse<string[]>>;
    /**
     * Get bill providers
     */
    getBillProviders(country?: string, category?: string): Promise<ApiResponse<BillProvider[]>>;
    /**
     * Get bill details/validate account
     */
    validateBillAccount(providerId: string, accountNumber: string): Promise<ApiResponse<{
        valid: boolean;
        accountName?: string;
        minAmount?: number;
        maxAmount?: number;
        dueAmount?: number;
    }>>;
    /**
     * Pay bill
     */
    payBill(params: {
        providerId: string;
        accountNumber: string;
        amount: number;
        currency: string;
    }): Promise<ApiResponse<BillPayment>>;
    /**
     * Get bill payment history
     */
    getBillHistory(options?: {
        limit?: number;
        offset?: number;
    }): Promise<ApiResponse<{
        payments: BillPayment[];
        total: number;
    }>>;
    /**
     * Get staking pools
     */
    getStakingPools(chainId?: number): Promise<ApiResponse<StakingPool[]>>;
    /**
     * Get user's staking positions
     */
    getStakingPositions(): Promise<ApiResponse<StakingPosition[]>>;
    /**
     * Stake tokens
     */
    stake(params: {
        poolId: string;
        amount: number;
    }): Promise<ApiResponse<{
        positionId: string;
        txHash: string;
    }>>;
    /**
     * Unstake tokens
     */
    unstake(params: {
        positionId: string;
        amount?: number;
    }): Promise<ApiResponse<{
        txHash: string;
    }>>;
    /**
     * Claim staking rewards
     */
    claimStakingRewards(positionId: string): Promise<ApiResponse<{
        txHash: string;
        amount: number;
    }>>;
    /**
     * Get user profile
     */
    getUserProfile(): Promise<ApiResponse<UserProfile>>;
    /**
     * Update user profile
     */
    updateUserProfile(updates: Partial<UserProfile>): Promise<ApiResponse<UserProfile>>;
    /**
     * Get user settings
     */
    getUserSettings(): Promise<ApiResponse<UserSettings>>;
    /**
     * Update user settings
     */
    updateUserSettings(updates: Partial<UserSettings>): Promise<ApiResponse<UserSettings>>;
    /**
     * Get notifications
     */
    getNotifications(options?: {
        unreadOnly?: boolean;
        limit?: number;
        offset?: number;
    }): Promise<ApiResponse<{
        notifications: Notification[];
        unreadCount: number;
    }>>;
    /**
     * Mark notification as read
     */
    markNotificationRead(notificationId: string): Promise<ApiResponse<void>>;
    /**
     * Mark all notifications as read
     */
    markAllNotificationsRead(): Promise<ApiResponse<void>>;
    /**
     * Get referral info
     */
    getReferralInfo(): Promise<ApiResponse<ReferralInfo>>;
    /**
     * Get referred users
     */
    getReferrals(): Promise<ApiResponse<Referral[]>>;
    /**
     * Apply referral code
     */
    applyReferralCode(code: string): Promise<ApiResponse<{
        success: boolean;
        message: string;
    }>>;
    /**
     * Claim referral rewards
     */
    claimReferralRewards(): Promise<ApiResponse<{
        amount: number;
        txHash?: string;
    }>>;
    /**
     * Get KYC status
     */
    getKycStatus(): Promise<ApiResponse<{
        status: 'none' | 'pending' | 'verified' | 'rejected';
        level: number;
        limits: {
            daily: number;
            monthly: number;
        };
        rejectionReason?: string;
    }>>;
    /**
     * Start KYC verification
     */
    startKycVerification(level: number): Promise<ApiResponse<{
        verificationUrl: string;
        sessionId: string;
    }>>;
    /**
     * Submit KYC documents
     */
    submitKycDocuments(params: {
        documentType: 'passport' | 'id_card' | 'drivers_license';
        frontImage: string;
        backImage?: string;
        selfieImage: string;
    }): Promise<ApiResponse<{
        status: string;
        message: string;
    }>>;
    /**
     * Get bridge quote
     */
    getBridgeQuote(params: {
        fromChainId: number;
        toChainId: number;
        fromToken: string;
        toToken: string;
        amount: string;
        walletAddress: string;
    }): Promise<ApiResponse<BridgeQuote>>;
    /**
     * Execute bridge transaction
     */
    executeBridge(params: {
        quoteId: string;
        walletAddress: string;
    }): Promise<ApiResponse<BridgeTransaction>>;
    /**
     * Get bridge transaction status
     */
    getBridgeStatus(bridgeId: string): Promise<ApiResponse<BridgeTransaction>>;
    /**
     * Get supported bridge routes
     */
    getSupportedBridgeRoutes(): Promise<ApiResponse<{
        routes: {
            fromChainId: number;
            toChainId: number;
            tokens: string[];
        }[];
    }>>;
    /**
     * Get gas estimate for transaction
     */
    getGasEstimate(params: {
        chainId: number;
        to: string;
        data?: string;
        value?: string;
    }): Promise<ApiResponse<GasEstimate>>;
    /**
     * Get current gas prices for chain
     */
    getGasPrice(chainId: number): Promise<ApiResponse<GasPrice>>;
    /**
     * Import wallet from private key or mnemonic
     */
    importWallet(request: WalletImportRequest): Promise<ApiResponse<{
        wallet: any;
        address: string;
        smartAccountAddress?: string;
    }>>;
    /**
     * Export wallet (get encrypted private key)
     * Requires additional authentication
     */
    exportWallet(walletId: string, pin: string): Promise<ApiResponse<{
        encryptedPrivateKey: string;
        address: string;
    }>>;
    /**
     * Generate new mnemonic phrase
     */
    generateMnemonic(): Promise<ApiResponse<{
        mnemonic: string;
        address: string;
    }>>;
    /**
     * Validate mnemonic phrase
     */
    validateMnemonic(mnemonic: string): Promise<ApiResponse<{
        valid: boolean;
        address?: string;
    }>>;
    /**
     * Get portfolio analytics with historical data
     */
    getPortfolioAnalytics(walletAddress: string, period?: '24h' | '7d' | '30d' | '90d' | '1y' | 'all'): Promise<ApiResponse<PortfolioAnalytics>>;
    /**
     * Get transaction analytics
     */
    getTransactionAnalytics(walletAddress: string, period?: '24h' | '7d' | '30d' | '90d'): Promise<ApiResponse<{
        totalTransactions: number;
        totalVolume: number;
        avgTransactionValue: number;
        byType: Record<string, number>;
        byChain: Record<string, number>;
    }>>;
    /**
     * Create limit order
     */
    createLimitOrder(params: {
        tokenSymbol: string;
        type: 'buy' | 'sell';
        amount: number;
        limitPrice: number;
        chainId: number;
        expiresIn?: number;
        conditions?: TradingCondition[];
    }): Promise<ApiResponse<LimitOrder>>;
    /**
     * Get user's limit orders
     */
    getLimitOrders(status?: 'pending' | 'filled' | 'cancelled'): Promise<ApiResponse<LimitOrder[]>>;
    /**
     * Cancel limit order
     */
    cancelLimitOrder(orderId: string): Promise<ApiResponse<{
        success: boolean;
    }>>;
    /**
     * Set price alert
     */
    setPriceAlert(params: {
        tokenSymbol: string;
        targetPrice: number;
        condition: 'above' | 'below';
        notification: 'push' | 'email' | 'both';
    }): Promise<ApiResponse<{
        alertId: string;
    }>>;
    /**
     * Get price alerts
     */
    getPriceAlerts(): Promise<ApiResponse<{
        id: string;
        tokenSymbol: string;
        targetPrice: number;
        condition: 'above' | 'below';
        status: 'active' | 'triggered' | 'cancelled';
        createdAt: string;
        triggeredAt?: string;
    }[]>>;
    /**
     * Delete price alert
     */
    deletePriceAlert(alertId: string): Promise<ApiResponse<{
        success: boolean;
    }>>;
    /**
     * Get active sessions
     */
    getActiveSessions(): Promise<ApiResponse<{
        sessions: {
            id: string;
            deviceName: string;
            ipAddress: string;
            lastActive: string;
            current: boolean;
        }[];
    }>>;
    /**
     * Revoke session
     */
    revokeSession(sessionId: string): Promise<ApiResponse<{
        success: boolean;
    }>>;
    /**
     * Revoke all other sessions
     */
    revokeAllOtherSessions(): Promise<ApiResponse<{
        revokedCount: number;
    }>>;
    /**
     * List webhooks for the project
     */
    listWebhooks(options?: {
        isActive?: boolean;
    }): Promise<ApiResponse<{
        webhooks: Webhook[];
        total: number;
    }>>;
    /**
     * Get webhook by ID
     */
    getWebhook(webhookId: string): Promise<ApiResponse<{
        webhook: Webhook;
    }>>;
    /**
     * Create a webhook
     */
    createWebhook(input: CreateWebhookInput): Promise<ApiResponse<{
        webhook: Webhook;
    }>>;
    /**
     * Update a webhook
     */
    updateWebhook(webhookId: string, input: UpdateWebhookInput): Promise<ApiResponse<{
        webhook: Webhook;
    }>>;
    /**
     * Delete a webhook
     */
    deleteWebhook(webhookId: string): Promise<ApiResponse<{
        deleted: boolean;
    }>>;
    /**
     * Get webhook deliveries
     */
    getWebhookDeliveries(webhookId: string, options?: {
        status?: 'pending' | 'success' | 'failed';
        limit?: number;
        offset?: number;
    }): Promise<ApiResponse<{
        deliveries: WebhookDelivery[];
        total: number;
    }>>;
    /**
     * Test a webhook
     */
    testWebhook(webhookId: string): Promise<ApiResponse<{
        success: boolean;
        statusCode?: number;
        responseTime?: number;
        error?: string;
    }>>;
    /**
     * List all users (admin only)
     */
    adminListUsers(options?: AdminListOptions & {
        role?: 'user' | 'admin';
        kycStatus?: 'none' | 'pending' | 'verified' | 'rejected';
        isActive?: boolean;
    }): Promise<ApiResponse<PaginatedResult<AdminUser>>>;
    /**
     * Get user by ID (admin only)
     */
    adminGetUser(userId: string): Promise<ApiResponse<{
        user: AdminUser;
    }>>;
    /**
     * Update user (admin only)
     */
    adminUpdateUser(userId: string, data: {
        role?: 'user' | 'admin';
        isActive?: boolean;
        kycStatus?: 'none' | 'pending' | 'verified' | 'rejected';
    }): Promise<ApiResponse<{
        user: AdminUser;
    }>>;
    /**
     * List all projects (admin only)
     */
    adminListProjects(options?: AdminListOptions & {
        isActive?: boolean;
    }): Promise<ApiResponse<PaginatedResult<AdminProject>>>;
    /**
     * Get project by ID (admin only)
     */
    adminGetProject(projectId: string): Promise<ApiResponse<{
        project: AdminProject;
    }>>;
    /**
     * Update project (admin only)
     */
    adminUpdateProject(projectId: string, data: {
        name?: string;
        isActive?: boolean;
        settings?: Record<string, unknown>;
    }): Promise<ApiResponse<{
        project: AdminProject;
    }>>;
    /**
     * Regenerate project API key (admin only)
     */
    adminRegenerateApiKey(projectId: string): Promise<ApiResponse<{
        apiKey: string;
    }>>;
    /**
     * Get system statistics (admin only)
     */
    adminGetStats(days?: number): Promise<ApiResponse<SystemStats>>;
    /**
     * Get system logs (admin only)
     */
    adminGetLogs(options?: {
        level?: 'info' | 'warn' | 'error';
        service?: string;
        limit?: number;
        offset?: number;
        startDate?: string;
        endDate?: string;
    }): Promise<ApiResponse<{
        logs: SystemLog[];
        total: number;
    }>>;
    /**
     * Get rate limit status (admin only)
     */
    adminGetRateLimits(options?: {
        identifier?: string;
        limit?: number;
    }): Promise<ApiResponse<{
        limits: RateLimitInfo[];
    }>>;
    /**
     * Clear rate limits for an identifier (admin only)
     */
    adminClearRateLimits(identifier: string): Promise<ApiResponse<{
        success: boolean;
    }>>;
    /**
     * Get all AI agent configurations
     * This returns the full agent setup including tiers, cycles, and trading parameters
     */
    getAgentConfigs(options?: {
        includeInactive?: boolean;
        agentId?: string;
    }): Promise<ApiResponse<{
        agents?: Array<{
            id: string;
            name: string;
            name_zh: string;
            description: string;
            description_zh: string;
            category: string;
            risk_level: number;
            icon: string;
            color: string;
            tiers: Array<{
                tier: number;
                amount: number;
                label: string;
                label_zh: string;
            }>;
            supported_cycles: number[];
            default_cycle: number;
            supported_pairs: string[];
            supported_chains: string[];
            is_active: boolean;
            preview: {
                tier: {
                    tier: number;
                    amount: number;
                    label: string;
                };
                cycle: number;
                dailyLots: number;
                stabilityScore: number;
                roiRange: {
                    min: number;
                    max: number;
                    userMin: number;
                    userMax: number;
                };
                shareRate: number;
                profitEstimate: {
                    monthlyMin: number;
                    monthlyMax: number;
                    cycleMin: number;
                    cycleMax: number;
                };
            };
        }>;
        agent?: any;
        shareRates?: Record<number, number>;
    }>>;
    /**
     * Calculate subscription parameters for an agent
     */
    calculateAgentParams(params: {
        agentId: string;
        amount: number;
        cycleDays: number;
    }): Promise<ApiResponse<{
        dailyLots: number;
        effectiveCapital: number;
        stabilityScore: number;
        roiRange: {
            min: number;
            max: number;
            userMin: number;
            userMax: number;
        };
        shareRate: number;
        profitEstimate: {
            monthlyMin: number;
            monthlyMax: number;
            cycleMin: number;
            cycleMax: number;
        };
    }>>;
    /**
     * Get supported trading pairs from agents
     */
    getTradingPairs(): Promise<ApiResponse<{
        pairs: string[];
        byAgent: Record<string, string[]>;
    }>>;
    /**
     * Get all AI trading strategies
     */
    getAIStrategies(filters?: {
        category?: StrategyCategory;
        riskLevel?: number;
        minTvl?: number;
        isActive?: boolean;
    }): Promise<ApiResponse<{
        strategies: AIStrategy[];
    }>>;
    /**
     * Get AI strategy details
     */
    getAIStrategy(strategyId: string, include?: ('performance' | 'market' | 'trades')[]): Promise<ApiResponse<{
        strategy: AIStrategy;
        performance?: AINavSnapshot[];
        marketData?: AIMarketData[];
        trades?: AITradeExecution[];
    }>>;
    /**
     * Get strategy performance history
     */
    getAIStrategyPerformance(strategyId: string, days?: number): Promise<ApiResponse<{
        performance: AINavSnapshot[];
    }>>;
    /**
     * Get real-time market data for strategy pairs
     */
    getAIStrategyMarketData(strategyId: string): Promise<ApiResponse<{
        marketData: AIMarketData[];
    }>>;
    /**
     * Create AI trading order
     */
    createAIOrder(request: CreateAIOrderRequest): Promise<ApiResponse<{
        order: AIOrder;
    }>>;
    /**
     * Get user's AI orders
     */
    getAIOrders(filters?: {
        strategyId?: string;
        status?: AIOrderStatus;
    }): Promise<ApiResponse<{
        orders: AIOrder[];
    }>>;
    /**
     * Get AI order details
     */
    getAIOrder(orderId: string): Promise<ApiResponse<{
        order: AIOrder;
        strategy: AIStrategy;
    }>>;
    /**
     * Pause AI order
     */
    pauseAIOrder(orderId: string): Promise<ApiResponse<{
        order: AIOrder;
        message: string;
    }>>;
    /**
     * Resume AI order
     */
    resumeAIOrder(orderId: string): Promise<ApiResponse<{
        order: AIOrder;
        message: string;
    }>>;
    /**
     * Request redemption for AI order
     */
    redeemAIOrder(orderId: string): Promise<ApiResponse<{
        success: boolean;
        redemption: AIRedemptionResult;
        message: string;
    }>>;
    /**
     * Get AI portfolio summary
     */
    getAIPortfolio(include?: ('allocations' | 'orders')[]): Promise<ApiResponse<{
        portfolio: AIPortfolioSummary;
        allocations?: AITradeAllocation[];
        orders?: AIOrder[];
    }>>;
    /**
     * Get user's trade allocations
     */
    getAITradeAllocations(limit?: number): Promise<ApiResponse<{
        allocations: AITradeAllocation[];
    }>>;
    /**
     * Get trade history for a strategy
     */
    getAITradeHistory(strategyId: string, limit?: number): Promise<ApiResponse<{
        trades: AITradeExecution[];
    }>>;
    /**
     * Execute AI signals for a strategy (admin only)
     */
    executeAISignals(strategyId: string): Promise<ApiResponse<{
        executions: AITradeExecution[];
        count: number;
        message: string;
    }>>;
    /**
     * Get cryptocurrency prices (FREE - uses CoinGecko/Binance/CoinCap)
     */
    getCryptoPrices(symbols: string[]): Promise<ApiResponse<{
        prices: Array<{
            symbol: string;
            price: number;
            change24h: number;
            changePercent24h: number;
            high24h: number;
            low24h: number;
            volume24h: number;
            marketCap?: number;
            lastUpdated: string;
        }>;
    }>>;
    /**
     * Get single cryptocurrency price (FREE)
     */
    getCryptoPrice(symbol: string): Promise<ApiResponse<{
        price: {
            symbol: string;
            price: number;
            change24h: number;
            changePercent24h: number;
            high24h: number;
            low24h: number;
            volume24h: number;
            marketCap?: number;
            lastUpdated: string;
        };
    }>>;
    /**
     * Get OHLCV candles for charting (FREE - from Binance)
     */
    getCryptoCandles(symbol: string, interval?: '1m' | '5m' | '15m' | '1h' | '4h' | '1d', limit?: number): Promise<ApiResponse<{
        symbol: string;
        interval: string;
        candles: Array<{
            timestamp: number;
            open: number;
            high: number;
            low: number;
            close: number;
            volume: number;
        }>;
    }>>;
    /**
     * Get top cryptocurrencies by market cap (FREE)
     */
    getTopCryptos(limit?: number): Promise<ApiResponse<{
        prices: Array<{
            symbol: string;
            price: number;
            change24h: number;
            changePercent24h: number;
            high24h: number;
            low24h: number;
            volume24h: number;
            marketCap?: number;
            lastUpdated: string;
        }>;
    }>>;
    /**
     * Get crypto market overview (FREE)
     */
    getCryptoMarketOverview(): Promise<ApiResponse<{
        overview: {
            totalMarketCap: number;
            totalVolume24h: number;
            btcDominance: number;
            marketCapChange24h: number;
            activeCryptocurrencies: number;
        };
    }>>;
    /**
     * Get user's projects
     */
    getProjects(options?: {
        isActive?: boolean;
    }): Promise<ApiResponse<{
        projects: AdminProject[];
        total: number;
    }>>;
    /**
     * Create a new project for ecosystem partners
     */
    createProject(params: {
        name: string;
        slug: string;
        settings?: Record<string, unknown>;
    }): Promise<ApiResponse<{
        project: AdminProject;
    }>>;
    /**
     * Get project details
     */
    getProject(projectId: string): Promise<ApiResponse<{
        project: AdminProject;
    }>>;
    /**
     * Update project settings
     */
    updateProject(projectId: string, updates: {
        name?: string;
        isActive?: boolean;
        settings?: Record<string, unknown>;
    }): Promise<ApiResponse<{
        project: AdminProject;
    }>>;
    /**
     * Get project features status
     */
    getProjectFeatures(projectId: string): Promise<ApiResponse<{
        features: Record<string, {
            enabled: boolean;
            name: string;
            description: string;
            description_zh: string;
        }>;
        availableFeatures: string[];
    }>>;
    /**
     * Enable/disable features for a project
     */
    updateProjectFeatures(projectId: string, features: {
        wallet?: boolean;
        swap?: boolean;
        contracts?: boolean;
        fiat?: boolean;
        payments?: boolean;
        quant?: boolean;
        ai?: boolean;
        x402?: boolean;
    }): Promise<ApiResponse<{
        project: AdminProject;
        message: string;
    }>>;
    /**
     * Regenerate project API key
     */
    regenerateProjectApiKey(projectId: string): Promise<ApiResponse<{
        apiKey: string;
    }>>;
    /**
     * Delete project
     */
    deleteProject(projectId: string): Promise<ApiResponse<{
        deleted: boolean;
    }>>;
}
declare function createOneEngineClient(options?: {
    baseUrl?: string;
    clientId?: string;
    secretKey?: string;
}): OneEngineClient;

export { type EngineAuthResponse as E, OneEngineClient as O, type SwapQuoteRequest as S, type EngineWalletBalance as a, type EngineTransactionRequest as b, createOneEngineClient as c, type EngineTransactionResponse as d, type OnrampSessionRequest as e, type OnrampSession as f, type OnrampQuote as g, type OnrampTransaction as h, type SwapQuote as i, type SwapExecuteRequest as j, type SwapResult as k };
