import { type JsonRpcAccount, type PrivateKeyAccount, type PublicClient, type Transport, type WalletClient } from '../../index.js'; import type { Hex } from '../../types/misc.js'; import { suaveRigil, suaveToliman } from '../index.js'; type SuaveChain = typeof suaveToliman | typeof suaveRigil; export type SuaveWallet = WalletClient; export type SuaveProvider = PublicClient; /** Get a SUAVE-enabled viem wallet. * * @param params.transport - the transport to use for RPC requests. Defaults to public testnet. * @param params.jsonRpcAccount - the address to use for EIP-1193 requests (browser wallets). Required for `custom` transports. * @param params.privateKey - the private key to use for signing transactions. Required for *non*-`custom` transports. * @param params.customRpc - the RPC URL to use for SUAVE calls (nonce, gas estimates, etc) when using a `custom` transport. Defaults to transport URL. * * @example * import { http } from 'viem' * import { getSuaveWallet } from 'viem/chains/utils' * const wallet = getSuaveWallet({ * transport: http('http://localhost:8545'), * privateKey: '0xac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80', * }) * * @example * // using window.ethereum * import { custom } from 'viem' * import { getSuaveWallet } from 'viem/chains/utils' * async function main() { * const accounts = await window.ethereum.request({ method: 'eth_requestAccounts' }) * const account = accounts[0] * const wallet = getSuaveWallet({ * transport: custom(window.ethereum), * jsonRpcAccount: account, * // ensures reliable RPC requests (nonce, gas estimates, etc) as user switches RPCs in their wallet * customRpc: 'http://localhost:8545', * }) * } * main() */ export declare function getSuaveWallet(params: { transport?: TTransport; jsonRpcAccount?: Hex; privateKey?: Hex; customRpc?: string; chain?: SuaveChain; }): SuaveWallet; /** Creates a new SUAVE Public Client instance. * @example * import { http } from 'viem' * import { getSuaveProvider } from 'viem/chains/utils' * const client = getSuaveProvider(http('http://localhost:8545')) * @example * // using window.ethereum * import { custom } from 'viem' * import { getSuaveProvider } from 'viem/chains/utils' * const client = getSuaveProvider(custom(window.ethereum)) */ export declare function getSuaveProvider(transport?: TTransport, chain?: SuaveChain): SuaveProvider; export {}; //# sourceMappingURL=wallet.d.ts.map