import { IFetcher, Network, AccountInfo, UTxO, IFetcherOptions, TransactionInfo, Asset, AssetMetadata, BlockInfo, Protocol, IListener, ISubmitter, IEvaluator, Action, GovernanceProposalInfo } from '@meshsdk/common'; /** * The BeginProvider class provides methods to query Begin ID. * * To use this provider, simply create a new instance of the BeginProvider class and call the desired method. * * ```typescript * import { BeginProvider } from "@meshsdk/core"; * * const beginProvider = new BeginProvider(); * ``` */ declare class BeginProvider { private readonly apikey; private readonly chainNumber; private readonly domainUrl; /** * Creates a new instance of the BeginProvider. * @param apikey The API key for querying Begin ID. */ constructor(apikey?: string); /** * Given a Begin ID, resolves the address and other information. * @param name name of Begin ID, e.g. `mesh` * @param url optional URL to override the default: https://resolveidaddress-ylo5dtxzdq-uc.a.run.app * @returns * - name: string * - domain: string * - image: string * - address: string */ resolveAddress(name: string, url?: string): Promise<{ name: string; domain: string; image: string; address: string; }>; /** * Given an address, resolves the Begin ID and other information. * @param address address to resolve * @param url optional URL to override the default: https://resolveIdReserveAddress-ylo5dtxzdq-uc.a.run.app * @returns * - name: string * - domain: string * - image: string * - address: string */ resolveAdressReverse(address: string, url?: string): Promise<{ name: string; domain: string; image: string; address: string; }>; } type AssetAddress = { address: string; quantity: string; }; /** * OfflineFetcher implements the IFetcher interface to provide offline access to blockchain data. * This class allows working with pre-loaded blockchain data without requiring network connectivity. * It's useful for testing, development, and scenarios where offline operation is needed. * * The class maintains internal storage for various blockchain data types: * - Account information * - UTXOs (Unspent Transaction Outputs) * - Asset addresses and metadata * - Block information * - Protocol parameters * - Transaction information * * Example usage: * ```typescript * import { OfflineFetcher } from '@meshsdk/core'; * * // Create a new instance * const fetcher = new OfflineFetcher(); * //or const fetcher = new OfflineFetcher("mainnet"); * * // Add some blockchain data * fetcher.addAccount(address, accountInfo); * fetcher.addUTxOs(utxos); * fetcher.addSerializedTransaction("txHash"); * * // Use the fetcher with MeshWallet * const wallet = new MeshWallet({ * networkId: 0, * fetcher: fetcher, * key: { * type: 'address', * address: walletAddress * } * }); * ``` */ declare class OfflineFetcher implements IFetcher { private network?; private accounts; private utxos; private assetAddresses; private assetMetadata; private blocks; private collections; private protocolParameters; private transactions; constructor(network?: Network | undefined); private paginate; /** * Fetches account information for a given address. * @param address - Address to fetch info for * @returns Promise resolving to account information * @throws Error if account not found */ fetchAccountInfo(address: string): Promise; /** * Fetches UTXOs for a given address, optionally filtered by asset. * @param address - Address to fetch UTXOs for * @param asset - Optional asset ID to filter UTXOs * @returns Promise resolving to array of UTXOs */ fetchAddressUTxOs(address: string, asset?: string): Promise; /** * WIP - NOT IMPLEMENTED * @param address * @param options */ fetchAddressTxs(address: string, options?: IFetcherOptions): Promise; /** * Fetches addresses holding a specific asset. * @param asset - Asset identifier * @returns Promise resolving to array of asset addresses and quantities */ fetchAssetAddresses(asset: string): Promise; /** * Fetches all assets associated with an address. * @param address - Address to fetch assets for * @returns Promise resolving to array of assets held by the address */ fetchAddressAssets(address: string): Promise; /** * Fetches metadata for a specific asset. * @param asset - Asset identifier * @returns Promise resolving to asset metadata * @throws Error if asset metadata not found */ fetchAssetMetadata(asset: string): Promise; /** * Fetches information about a specific block. * @param hash - Block hash * @returns Promise resolving to block information * @throws Error if block not found */ fetchBlockInfo(hash: string): Promise; /** * Fetches assets in a collection (by policy ID) with pagination. * @param policyId - Policy ID of the collection * @param cursor - Optional pagination cursor * @returns Promise resolving to paginated assets and next cursor * @throws Error if collection not found or invalid cursor */ fetchCollectionAssets(policyId: string, cursor?: number | string): Promise<{ assets: Asset[]; next?: string | number; }>; /** * Fetches metadata for a handle. * @param handle - Handle to fetch metadata for * @returns Promise resolving to handle metadata * @throws Error if handle not found or invalid */ fetchHandle(handle: string): Promise; /** * Fetches address associated with a handle. * @param handle - Handle to fetch address for * @returns Promise resolving to address * @throws Error if no address found for handle */ fetchHandleAddress(handle: string): Promise; /** * Fetches protocol parameters for a specific epoch. * @param epoch - Epoch number * @returns Promise resolving to protocol parameters * @throws Error if parameters not found for epoch */ fetchProtocolParameters(epoch?: number): Promise; fetchCostModels(epoch?: number): Promise; /** * Fetches information about a specific transaction. * @param hash - Transaction hash * @returns Promise resolving to transaction information * @throws Error if transaction not found */ fetchTxInfo(hash: string): Promise; /** * Fetches all UTXOs associated with a specific transaction hash. * @param hash - Transaction hash to fetch UTXOs for * @returns Promise resolving to array of UTXOs associated with the transaction * @throws Error if no UTXOs found for the transaction hash */ fetchUTxOs(hash: string): Promise; fetchGovernanceProposal(txHash: string, certIndex: number): Promise; /** * HTTP GET method required by IFetcher interface but not implemented in OfflineFetcher. * @param url - URL to fetch from * @throws Error always, as this fetcher operates offline */ get(url: string): Promise; /** * Serializes fetcher data to JSON string. * @returns JSON string containing all fetcher data */ toJSON(): string; /** * Creates an OfflineFetcher instance from JSON data. * @param json - JSON string containing fetcher data * @returns New OfflineFetcher instance */ static fromJSON(json: string): OfflineFetcher; private static isValidHex; private static isValidAddress; private static isValidBase58; private static isValidBech32; private static isValidBech32Address; private static isValidBech32Pool; private static isValidBech32VrfVk; private static isIntegerString; private static isValidAssetOrLovelace; /** * Adds account information to the fetcher. * @param address - Account address * @param accountInfo - Account information * @throws Error if address or account info invalid */ addAccount(address: string, accountInfo: AccountInfo): void; /** * Adds UTXOs to the fetcher. * @param utxos - Array of UTXOs * @throws Error if UTXOs invalid */ addUTxOs(utxos: UTxO[]): void; /** * Adds asset address information to the fetcher. * @param asset - Asset identifier * @param addresses - Array of asset addresses * @throws Error if asset or addresses invalid */ addAssetAddresses(asset: string, addresses: AssetAddress[]): void; /** * Adds asset metadata to the fetcher. * @param asset - Asset identifier * @param metadata - Asset metadata * @throws Error if asset or metadata invalid */ addAssetMetadata(asset: string, metadata: AssetMetadata): void; /** * Adds collection assets to the fetcher. * @param assets - Array of assets * @throws Error if assets invalid */ addCollectionAssets(assets: Asset[]): void; /** * Adds protocol parameters to the fetcher. * @param parameters - Protocol parameters * @throws Error if parameters invalid */ addProtocolParameters(parameters: Protocol): void; /** * Adds transaction information to the fetcher. * @param txInfo - Transaction information * @throws Error if transaction info invalid */ addTransaction(txInfo: TransactionInfo): void; /** * Adds block information to the fetcher. * @param blockInfo - Block information * @throws Error if block info invalid */ addBlock(blockInfo: BlockInfo): void; /** * Adds a serialized transaction to the fetcher, it's generates pseudo block in addition to transaction. * Removes spent UTxOs from the fetcher and adds new UTxOs from the transaction. * @param txHex - Hexadecimal string of the transaction * @throws Error if transaction hex invalid */ addSerializedTransaction(txHex: string): void; private slotToEpochSlot; private mapOutputToUTxO; private mapValueToAsset; } type BlockfrostCachingOptions = { enableCaching?: boolean; offlineFetcher?: OfflineFetcher; }; type BlockfrostSupportedNetworks = "mainnet" | "preview" | "preprod"; /** * Blockfrost provides restful APIs which allows your app to access information stored on the blockchain. * * Usage: * ``` * import { BlockfrostProvider } from "@meshsdk/core"; * * const provider = new BlockfrostProvider(''); * * // With caching enabled * const providerWithCache = new BlockfrostProvider('', 0, { enableCaching: true }); * ``` */ declare class BlockfrostProvider implements IFetcher, IListener, ISubmitter, IEvaluator { private readonly _axiosInstance; private readonly _network; private submitTxToBytes; private _offlineFetcher?; private _enableCaching; /** * If you are using a privately hosted Blockfrost instance, you can set the URL in the parameter. * @param baseUrl The base URL of the instance. * @param cachingOptions Optional caching configuration */ constructor(baseUrl: string, cachingOptions?: BlockfrostCachingOptions); /** * If you are using [Blockfrost](https://blockfrost.io/) hosted instance, you can set the project ID in the parameter. * @param projectId The project ID of the instance. * @param version The version of the API. Default is 0. * @param cachingOptions Optional caching configuration */ constructor(projectId: string, version?: number, cachingOptions?: BlockfrostCachingOptions); /** * Evaluates the resources required to execute the transaction * @param cbor - The transaction CBOR hex string to evaluate * @param additionalUtxos - Optional array of additional UTxOs to include in the evaluation context for resolving transaction inputs * @param additionalTxs - Optional array of transaction CBOR hex strings to provide additional UTxOs from their outputs */ evaluateTx(cbor: string, additionalUtxos?: UTxO[], additionalTxs?: string[]): Promise[]>; /** * Obtain information about a specific stake account. * @param address - Wallet address to fetch account information */ fetchAccountInfo(address: string): Promise; /** * Fetches the assets for a given address. * @param address - The address to fetch assets for * @returns A map of asset unit to quantity */ fetchAddressAssets(address: string): Promise<{ [key: string]: string; }>; /** * Transactions for an address. The `TransactionInfo` would only return the `hash`, `inputs`, and `outputs`. * @param address - The address to fetch transactions for * @returns - partial TransactionInfo */ fetchAddressTxs(address: string, option?: IFetcherOptions): Promise; /** * Deprecated, use fetchAddressTxs instead * @param address * @returns - partial TransactionInfo */ fetchAddressTransactions(address: string): Promise; /** * UTXOs of the address. * @param address - The address to fetch UTXO * @param asset - UTXOs of a given asset​ * @returns - Array of UTxOs */ fetchAddressUTxOs(address: string, asset?: string): Promise; /** * Fetches the asset addresses for a given asset. * @param asset - The asset to fetch addresses for */ fetchAssetAddresses(asset: string): Promise<{ address: string; quantity: string; }[]>; /** * Fetches the metadata for a given asset. * @param asset - The asset to fetch metadata for * @returns The metadata for the asset */ fetchAssetMetadata(asset: string): Promise; /** * Fetches the metadata for a given asset. * @param asset - The asset to fetch metadata for * @returns The metadata for the asset */ fetchLatestBlock(): Promise; /** * Fetches the block information for a given block hash. * @param hash The block hash to fetch from * @returns The block information */ fetchBlockInfo(hash: string): Promise; /** * Fetches the list of assets for a given policy ID. * @param policyId The policy ID to fetch assets for * @param cursor The cursor for pagination * @returns The list of assets and the next cursor */ fetchCollectionAssets(policyId: string, cursor?: number): Promise<{ assets: Asset[]; next: string | number | null; }>; fetchHandle(handle: string): Promise; fetchHandleAddress(handle: string): Promise; fetchCostModels(epoch?: number): Promise; /** * Fetch the latest protocol parameters. * @param epoch Optional - The epoch to fetch protocol parameters for * @returns - Protocol parameters */ fetchProtocolParameters(epoch?: number): Promise; /** * Fetches the transaction information for a given transaction hash. * @param hash The transaction hash to fetch * @returns The transaction information */ fetchTxInfo(hash: string): Promise; /** * Get UTxOs for a given hash. * @param hash The transaction hash * @param index Optional - The output index for filtering post fetching * @returns - Array of UTxOs */ fetchUTxOs(hash: string, index?: number): Promise; /** * Fetches the governance proposal information. * @param txHash The transaction hash of the proposal * @param certIndex The certificate index of the proposal * @returns The governance proposal information */ fetchGovernanceProposal(txHash: string, certIndex: number): Promise; /** * A generic method to fetch data from a URL. * @param url - The URL to fetch data from * @returns - The data fetched from the URL */ get(url: string): Promise; /** * A generic method to post data to a URL. * @param url - The URL to fetch data from * @param body - Payload * @param headers - Specify headers, default: { "Content-Type": "application/json" } * @returns - Data */ post(url: string, body: any, headers?: { "Content-Type": string; }): Promise; /** * Allow you to listen to a transaction confirmation. Upon confirmation, the callback will be called. * @param txHash - The transaction hash to listen for confirmation * @param callback - The callback function to call when the transaction is confirmed * @param limit - The number of blocks to wait for confirmation */ onTxConfirmed(txHash: string, callback: () => void, limit?: number): void; setSubmitTxToBytes(value: boolean): void; /** * Submit a serialized transaction to the network. * @param tx - The serialized transaction in hex to submit * @returns The transaction hash of the submitted transaction */ submitTx(tx: string): Promise; private resolveScriptRef; private toUTxO; private fetchPlutusScriptCBOR; private fetchNativeScriptJSON; /** * Enable or disable caching functionality. * @param enable - Whether to enable caching * @param offlineFetcher - Optional custom OfflineFetcher instance to use */ setCaching(enable: boolean, offlineFetcher?: OfflineFetcher): void; /** * Get the current OfflineFetcher instance if caching is enabled. * @returns The OfflineFetcher instance or undefined if caching is disabled */ getOfflineFetcher(): OfflineFetcher | undefined; /** * Check if caching is currently enabled. * @returns True if caching is enabled, false otherwise */ isCachingEnabled(): boolean; /** * Export the cached data as JSON string. * @returns JSON string of cached data or null if caching is disabled */ exportCache(): string | null; /** * Import cached data from JSON string. * @param jsonData - JSON string containing cached data * @param enableCaching - Whether to enable caching if not already enabled */ importCache(jsonData: string, enableCaching?: boolean): void; /** * Clear all cached data. */ clearCache(): void; } /** * Iagon Insight is a Cardano mainnet API: https://insight.iagon.com * * Usage: * ``` * import { IagonInsightProvider } from "@meshsdk/provider"; * * const provider = new IagonInsightProvider(""); * ``` */ declare class IagonInsightProvider implements IFetcher, IListener, ISubmitter, IEvaluator { private readonly _axiosInstance; private readonly _scripts; /** * @param apiKey Your Iagon Insight API key, from the dashboard * @param baseUrl Defaults to https://mainnet.insight.iagon.com. The key only goes out over https. */ constructor(apiKey: string, baseUrl?: string); fetchAccountInfo(address: string): Promise; /** * UTxOs of an address, optionally only those holding an asset. A failed * request throws instead of answering with an empty list. */ fetchAddressUTxOs(address: string, asset?: string): Promise; fetchAddressTxs(address: string, options?: IFetcherOptions): Promise; fetchAssetAddresses(asset: string): Promise<{ address: string; quantity: string; }[]>; fetchAssetMetadata(asset: string): Promise; fetchBlockInfo(hash: string): Promise; fetchCollectionAssets(policyId: string, cursor?: number | string): Promise<{ assets: Asset[]; next: number | null; }>; fetchProtocolParameters(epoch?: number): Promise; fetchCostModels(epoch?: number): Promise; fetchTxInfo(hash: string): Promise; fetchUTxOs(hash: string, index?: number): Promise; fetchGovernanceProposal(txHash: string, certIndex: number): Promise; /** * A generic GET. A path without a leading slash is the Blockfrost compatible * surface, `/v1/...` and `/koios/v1/...` work too. */ get(url: string): Promise; /** * Submit a serialized transaction. Never sent twice: a submit that timed out * may well have reached the node. */ submitTx(tx: string): Promise; /** * Evaluates the scripts of a transaction on the Iagon Insight API, one at a * time per account. A 429 or 503 with a short Retry-After is asked again, * at most twice. */ evaluateTx(tx: string, additionalUtxos?: UTxO[], additionalTxs?: string[]): Promise[]>; onTxConfirmed(txHash: string, callback: () => void, limit?: number): void; private bf; private toUTxO; private scriptRef; private loadScript; private pages; private request; } type KoiosSupportedNetworks = "api" | "preview" | "preprod" | "guild"; declare class KoiosProvider implements IFetcher, IListener, ISubmitter, IEvaluator { private readonly _axiosInstance; private readonly _network; constructor(baseUrl: string); constructor(network: KoiosSupportedNetworks, token: string, version?: number); /** * Obtain information about a specific stake account. * @param address - Wallet address to fetch account information */ fetchAccountInfo(address: string): Promise; /** * Fetches the assets for a given address. * @param address - The address to fetch assets for * @returns A map of asset unit to quantity */ fetchAddressAssets(address: string): Promise<{ [key: string]: string; }>; /** * Unimplemented - open for contribution, see blockfrost.ts for reference * @param address */ fetchAddressTxs(address: string, option?: IFetcherOptions): Promise; /** * UTXOs of the address. * @param address - The address to fetch UTXO * @param asset - UTXOs of a given asset​ * @returns - Array of UTxOs */ fetchAddressUTxOs(address: string, asset?: string): Promise; /** * Fetches the asset addresses for a given asset. * @param asset - The asset to fetch addresses for */ fetchAssetAddresses(asset: string): Promise<{ address: string; quantity: string; }[]>; /** * Fetches the metadata for a given asset. * @param asset - The asset to fetch metadata for * @returns The metadata for the asset */ fetchAssetMetadata(asset: string): Promise; /** * Fetches the block information for a given block hash. * @param hash The block hash to fetch from * @returns The block information */ fetchBlockInfo(hash: string): Promise; /** * Fetches the list of assets for a given policy ID. * @param policyId The policy ID to fetch assets for * @param cursor The cursor for pagination * @returns The list of assets and the next cursor */ fetchCollectionAssets(policyId: string): Promise<{ assets: Asset[]; }>; fetchHandle(handle: string): Promise; fetchHandleAddress(handle: string): Promise; /** * Fetch the latest protocol parameters. * @param epoch * @returns - Protocol parameters */ fetchProtocolParameters(epoch?: number): Promise; fetchCostModels(epoch?: number): Promise; /** * Fetches the transaction information for a given transaction hash. * @param hash The transaction hash to fetch * @returns The transaction information */ fetchTxInfo(hash: string): Promise; /** * Get UTxOs for a given hash. * @param hash The transaction hash * @param index Optional - The output index for filtering post fetching * @returns - Array of UTxOs */ fetchUTxOs(hash: string, index?: number): Promise; fetchGovernanceProposal(txHash: string, certIndex: number): Promise; /** * A generic method to fetch data from a URL. * @param url - The URL to fetch data from * @returns - The data fetched from the URL */ get(url: string): Promise; /** * A generic method to post data to a URL. * @param url - The URL to fetch data from * @param body - Payload * @param headers - Specify headers, default: { "Content-Type": "application/json" } * @returns - Data */ post(url: string, body: any, headers?: { "Content-Type": string; }): Promise; /** * Allow you to listen to a transaction confirmation. Upon confirmation, the callback will be called. * @param txHash - The transaction hash to listen for confirmation * @param callback - The callback function to call when the transaction is confirmed * @param limit - The number of blocks to wait for confirmation */ onTxConfirmed(txHash: string, callback: () => void, limit?: number): void; /** * Deprecated, use fetchAddressTxs instead * @param address * @returns - partial TransactionInfo */ fetchAddressTransactions(address: string): Promise; /** * Submit a serialized transaction to the network. * @param tx - The serialized transaction in hex to submit * @returns The transaction hash of the submitted transaction */ submitTx(tx: string): Promise; private toUTxO; private resolveScriptRef; /** * Evaluates the resources required to execute the transaction * @param cbor - The transaction CBOR hex string to evaluate * @param additionalUtxos - Optional array of additional UTxOs to include in the evaluation context for resolving transaction inputs * @param additionalTxs - Optional array of transaction CBOR hex strings to provide additional UTxOs from their outputs */ evaluateTx(cbor: string, additionalUtxos?: UTxO[], additionalTxs?: string[]): Promise[]>; } type MaestroSupportedNetworks = "Mainnet" | "Preprod" | "Preview"; interface MaestroConfig { network: MaestroSupportedNetworks; apiKey: string; turboSubmit?: boolean; } /** * @deprecated Maestro is no longer supported and will be removed in a later version. */ declare class MaestroProvider implements IFetcher, ISubmitter, IEvaluator, IListener { /** * @deprecated Maestro is no longer supported. Constructor params are kept for compatibility and will be removed in a later version. */ constructor(_config: MaestroConfig); /** * @deprecated Maestro is no longer supported. */ evaluateTx(_cbor: string, _additionalUtxos?: UTxO[], _additionalTxs?: string[]): Promise[]>; /** * @deprecated Maestro is no longer supported. */ fetchAccountInfo(_address: string): Promise; /** * @deprecated Maestro is no longer supported. */ fetchAddressAssets(_address: string): Promise<{ [key: string]: string; }>; /** * @deprecated Maestro is no longer supported. */ fetchAddressUTxOs(_address: string, _asset?: string): Promise; /** * @deprecated Maestro is no longer supported. */ fetchAddressTxs(_address: string, _option?: IFetcherOptions): Promise; /** * @deprecated Maestro is no longer supported. */ fetchAssetAddresses(_asset: string): Promise<{ address: string; quantity: string; }[]>; /** * @deprecated Maestro is no longer supported. */ fetchAssetMetadata(_asset: string): Promise; /** * @deprecated Maestro is no longer supported. */ fetchBlockInfo(_hash: string): Promise; /** * @deprecated Maestro is no longer supported. */ fetchCollectionAssets(_policyId: string, _cursor?: string): Promise<{ assets: Asset[]; next: string | number | null; }>; /** * @deprecated Maestro is no longer supported. */ fetchHandle(_handle: string): Promise; /** * @deprecated Maestro is no longer supported. */ fetchHandleAddress(_handle: string): Promise; /** * @deprecated Maestro is no longer supported. */ fetchProtocolParameters(_epoch?: number): Promise; /** * @deprecated Maestro is no longer supported. */ fetchCostModels(_epoch?: number): Promise; /** * @deprecated Maestro is no longer supported. */ fetchTxInfo(_hash: string): Promise; /** * @deprecated Maestro is no longer supported. */ fetchUTxOs(_hash: string, _index?: number): Promise; /** * @deprecated Maestro is no longer supported. */ fetchGovernanceProposal(_txHash: string, _certIndex: number): Promise; /** * @deprecated Maestro is no longer supported. */ get(_url: string): Promise; /** * @deprecated Maestro is no longer supported. */ post(_url: string, _body: any): Promise; /** * @deprecated Maestro is no longer supported. */ onTxConfirmed(_txHash: string, _callback: () => void, _limit?: number): void; /** * @deprecated Maestro is no longer supported. */ setSubmitTxToBytes(_value: boolean): void; /** * @deprecated Maestro is no longer supported. */ submitTx(_tx: string): Promise; } /** Script details from `GET /scripts/{scriptHash}`. */ type NexusScript = { hash: string; /** e.g. "plutusV1" | "plutusV2" | "plutusV3" | "timelock" (native). */ type: string; /** Raw script bytes in hex; some sources return it under `cbor`. */ bytes?: string; cbor?: string; value?: unknown; }; /** * The network ids Nexus publishes in its OpenAPI schema — the `enum` on the * `network` query parameter — and what {@link NexusProvider} puts on the wire. */ type NexusNetworkId = "CARDANO_MAINNET" | "CARDANO_PREPROD" | "CARDANO_PREVIEW"; /** * Networks accepted by {@link NexusProvider}, in any of the three spellings a * caller is likely to be holding, all normalised to a {@link NexusNetworkId}: * * - `CARDANO_PREVIEW` — the OpenAPI schema enum, shown in the Swagger UI. * - `cardano-preview` — the kebab id used in Nexus's docs prose and dashboard * (auto-generated API key names look like `cardano-preview`). * - `preview` — the bare name from `@meshsdk/common`'s `Network`, so a network * already threaded through a Mesh app can be passed straight in. * * Matching is case-insensitive. The bare Mesh name is a convenience of this * provider only: Nexus itself rejects it. */ type NexusSupportedNetworks = NexusNetworkId | "cardano-mainnet" | "cardano-preprod" | "cardano-preview" | "mainnet" | "preprod" | "preview"; /** * Nexus is Gero's Cardano data API (https://nexus.gerowallet.io). It exposes * a Blockfrost/Koios-style REST surface for querying chain data and submitting * transactions. * * Usage: * ``` * import { NexusProvider } from "@meshsdk/provider"; * * // hosted instance, API key is network-scoped * const provider = new NexusProvider(''); * * // hosted instance, network named explicitly (must match the key's network). * // The schema id, the dashboard's kebab id, and Mesh's bare name all work. * const provider = new NexusProvider('', 'CARDANO_PREPROD'); * const provider = new NexusProvider('', 'cardano-preprod'); * const provider = new NexusProvider('', 'preprod'); * * // self-hosted instance (include the `/api` path segment) * const provider = new NexusProvider('https://my-nexus.example.com/api', undefined, 'CARDANO_PREVIEW'); * ``` * * When a network is named it goes on every request as `?network=`. Leave it * unset against the hosted instance to let the API key's own network decide — * naming a network that disagrees with the key is a 400. */ declare class NexusProvider implements IFetcher, IListener, ISubmitter, IEvaluator { private readonly _axiosInstance; private readonly _network; /** * If you are using a privately hosted Nexus instance, pass its base URL * (including the `/api` path). Optionally pass an API key and the network the * instance serves. * @param baseUrl The base URL of the instance, e.g. `https://host/api`. * @param apiKey Optional API key sent as the `X-Api-Key` header. * @param network Optional network the instance serves, sent as `?network=`. * Omit it and the server decides: from the API key if one is set, otherwise * preprod. Handle resolution treats an omitted network as `mainnet`. */ constructor(baseUrl: string, apiKey?: string, network?: NexusSupportedNetworks); /** * If you are using the hosted Nexus instance, pass your API key. The key is * network-scoped, so the network is derived from the key server-side and * naming one here is optional. * @param apiKey Your Nexus API key. * @param network Optional network, sent as `?network=` and used for handle * resolution. Must match the API key's own network or the request is a 400. * Handle resolution treats an omitted network as `mainnet`. */ constructor(apiKey: string, network?: NexusSupportedNetworks); /** * Evaluates the resources required to execute the transaction. * Requires the Nexus instance to have an evaluation backend configured * (Ogmios); otherwise the endpoint responds 503. * @param cbor - The transaction in CBOR hex to evaluate * @param additionalUtxos - Additional UTxOs referenced by the transaction but not yet on-chain * @param additionalTxs - Additional (chained) transactions whose outputs the tx spends */ evaluateTx(cbor: string, additionalUtxos?: UTxO[], additionalTxs?: string[]): Promise[]>; /** * Obtain information about a specific stake account. * @param address - Wallet address (or stake address) to fetch account information */ fetchAccountInfo(address: string): Promise; /** * Fetches the assets for a given address. * @param address - The address to fetch assets for * @returns A map of asset unit to quantity */ fetchAddressAssets(address: string): Promise<{ [key: string]: string; }>; /** * Transactions for an address. * @param address * @param option - Fetcher options (pagination) * @returns - partial TransactionInfo */ fetchAddressTxs(address: string, option?: IFetcherOptions): Promise; /** * UTXOs of the address. * @param address - The address to fetch UTXOs for * @param asset - UTXOs of a given asset (policyId + assetName hex) * @returns - Array of UTxOs */ fetchAddressUTxOs(address: string, asset?: string): Promise; /** * Fetches the asset addresses (holders) for a given asset. * @param asset - The asset to fetch addresses for */ fetchAssetAddresses(asset: string): Promise<{ address: string; quantity: string; }[]>; /** * Fetches the metadata for a given asset. * @param asset - The asset to fetch metadata for * @returns The metadata for the asset */ fetchAssetMetadata(asset: string): Promise; /** * Fetches the latest block. * @returns The latest block information */ fetchLatestBlock(): Promise; fetchBlockInfo(hash: string): Promise; fetchCollectionAssets(policyId: string, cursor?: number): Promise<{ assets: Asset[]; next: string | number | null; }>; fetchHandle(handle: string): Promise; fetchHandleAddress(handle: string): Promise; fetchCostModels(epoch?: number): Promise; fetchProtocolParameters(epoch?: number): Promise; fetchTxInfo(hash: string): Promise; fetchUTxOs(hash: string, index?: number): Promise; fetchGovernanceProposal(txHash: string, certIndex: number): Promise; /** * A generic method to fetch data from a URL. * @param url - The URL to fetch data from * @returns - The data fetched from the URL */ get(url: string): Promise; /** * A generic method to post data to a URL. * @param url - The URL to post data to * @param body - Payload * @param headers - Specify headers, default: { "Content-Type": "application/json" } * @returns - Data */ post(url: string, body: any, headers?: { "Content-Type": string; }): Promise; /** * Allow you to listen to a transaction confirmation. Upon confirmation, the callback will be called. * @param txHash - The transaction hash to listen for confirmation * @param callback - The callback function to call when the transaction is confirmed * @param limit - The number of attempts to make before giving up */ onTxConfirmed(txHash: string, callback: () => void, limit?: number): void; /** * Submit a serialized transaction to the network. * @param tx - The serialized transaction in hex to submit * @returns The transaction hash of the submitted transaction */ submitTx(tx: string): Promise; private toBlockInfo; private toUTxO; private txUtxoToUTxO; /** * Fetches a script by its hash. * @param scriptHash - The hash of the script to fetch * @returns The script (type + bytes), or undefined if not found */ fetchScriptByHash(scriptHash: string): Promise; private resolveScriptRef; private resolveScriptRefByHash; private static readonly SCRIPT_REF_LANGUAGE_TAGS; private unwrapScriptRef; private scriptRefFromParts; } declare class OgmiosProvider implements IEvaluator, ISubmitter { private readonly _baseUrl; constructor(baseUrl: string); constructor(network: Network); /** * Evaluates the resources required to execute the transaction * @param cbor - The transaction CBOR hex string to evaluate * @param additionalUtxos - Optional array of additional UTxOs to include in the evaluation context for resolving transaction inputs * @param additionalTxs - Optional array of transaction CBOR hex strings to provide additional UTxOs from their outputs */ evaluateTx(cbor: string, additionalUtxos?: UTxO[], additionalTxs?: string[]): Promise[]>; onNextTx(callback: (tx: unknown) => void): Promise<() => void>; /** * Submit a serialized transaction to the network. * @param tx - The serialized transaction in hex to submit * @returns The transaction hash of the submitted transaction */ submitTx(tx: string): Promise; fetchProtocolParameters(): Promise; private open; private send; } /** * A UTxO RPC Provider for [MeshJS](https://meshjs.dev/) Transaction Builder Library. * * Example usage of how to use the UTxO RPC provider with Mesh to build and submit a transaction. * ``` * // Step #1 * // Import Mesh SDK and UTxO RPC provider * import { Transaction, MeshWallet, U5CProvider } from "@meshsdk/core"; * * async function main() { * // Step #2 * // Create a new U5C provider * const provider = new U5CProvider({ * url: "http://localhost:50051", * headers: { * "dmtr-api-key": "", * }, * }); * * // Step #3 * // Create a new wallet from a mnemonic * const wallet = new MeshWallet({ * networkId: 0, // 0: testnet, 1: mainnet * fetcher: provider, * submitter: provider, * key: { * type: "mnemonic", * words: [ * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * "solution", * ], * }, * }); * * // Optional: Print the wallet address * console.log(wallet.getChangeAddress()); * * // Optional: Print the wallet utxos * console.log(await provider.fetchAddressUTxOs(wallet.getChangeAddress())); * * // Step #4 * // Create an example transaction that sends 5 ADA to an address * const tx = new Transaction({ * initiator: wallet, * verbose: false, * }).sendLovelace( * "addr_test1vpvx0sacufuypa2k4sngk7q40zc5c4npl337uusdh64kv0c7e4cxr", * "5000000" * ); * const unsignedTx = await tx.build(); * * // Step #5 * // Sign the transaction * const signedTx = await wallet.signTx(unsignedTx); * * // Step #6 * // Submit the transaction to the blockchain network * const txId = await provider.submitTx(signedTx); * * // Optional: Print the transaction ID * console.log("Transaction ID", txId); * } * * main().catch(console.error); * ``` */ declare class U5CProvider implements IFetcher, ISubmitter, IEvaluator, IListener { private queryClient; private submitClient; /** * Constructor initializes the query and submit clients with provided URL and optional headers. * @param url - The base URL for interacting with Cardano nodes. * @param headers - Optional HTTP headers for API requests. */ constructor({ url, headers, }: { url: string; headers?: Record; }); /** * Allow you to listen to a transaction confirmation. Upon confirmation, the callback will be called. * @param txHash - The transaction hash to listen for confirmation * @param callback - The callback function to call when the transaction is confirmed * @param limit - The number of blocks to wait for confirmation */ onTxConfirmed(txHash: string, callback: () => void, limit?: number): void; /** * Evaluates the resources required to execute the transaction * @param tx - The transaction to evaluate */ evaluateTx(tx: string, additionalUtxos?: UTxO[], additionalTxs?: string[]): Promise[]>; /** * Submit a serialized transaction to the network. * @param tx - The serialized transaction in hex to submit * @returns The transaction hash of the submitted transaction */ submitTx(tx: string): Promise; /** * Obtain information about a specific stake account. * @param address - Wallet address to fetch account information */ fetchAccountInfo(address: string): Promise; fetchAddressAssets(address: string): Promise<{ [key: string]: string; }>; /** * Fetches the UTxOs for a given address. * @param address - The address to fetch UTxOs for * @param asset - The asset to filter UTxOs by (optional) * @returns UTxOs for the given address */ fetchAddressUTxOs(address: string, asset?: string): Promise; /** * Unimplemented - open for contribution * * Transactions for an address. The `TransactionInfo` would only return the `hash`, `inputs`, and `outputs`. * @param address - The address to fetch transactions for * @returns - partial TransactionInfo */ fetchAddressTxs(address: string, option?: IFetcherOptions): Promise; /** * Unimplemented - open for contribution * * Fetches the asset addresses for a given asset. * @param asset - The asset to fetch addresses for */ fetchAssetAddresses(asset: string): Promise<{ address: string; quantity: string; }[]>; /** * Unimplemented - open for contribution * * Fetches the metadata for a given asset. * @param asset - The asset to fetch metadata for */ fetchAssetMetadata(asset: string): Promise; /** * Unimplemented - open for contribution * * Fetches the block information for a given block hash. * @param hash - The block hash to fetch block information for */ fetchBlockInfo(hash: string): Promise; /** * Unimplemented - open for contribution * * Fetches the collection assets for a given policy ID. * @param policyId - The policy ID to fetch collection assets for * @param cursor - The cursor to fetch the next set of assets (optional) */ fetchCollectionAssets(policyId: string, cursor?: number | string): Promise<{ assets: Asset[]; next?: string | number | null; }>; /** * Unimplemented - open for contribution * * Fetches the information (AssetMetadata) for a given handle. * @param handle - The handle to fetch information for */ fetchHandle(handle: string): Promise; /** * Unimplemented - open for contribution * * Resolve the handle's address from the handle. * @param handle - The handle to resolve */ fetchHandleAddress(handle: string): Promise; /** * Unimplemented - open for contribution * * Fetches protocol parameters */ fetchProtocolParameters(epoch?: number): Promise; fetchCostModels(epoch?: number): Promise; /** * Unimplemented - open for contribution * * Fetches transaction info for a given hash. * @param hash - The transaction hash */ fetchTxInfo(hash: string): Promise; /** * Not complete - open for contribution * * Fetches output UTxOs of a given transaction hash. * @param hash - The transaction hash */ fetchUTxOs(hash: string, index?: number): Promise; /** * Unimplemented - open for contribution * * Fetches the governance proposal information. * @param txHash The transaction hash of the proposal * @param certIndex The certificate index of the proposal * @returns The governance proposal information */ fetchGovernanceProposal(txHash: string, certIndex: number): Promise; /** * Unimplemented - open for contribution * * @param url */ get(url: string): Promise; /** * Waits for transaction confirmation within a given timeout. * @param txId - The transaction hash. * @param timeout - Optional timeout in milliseconds. * @returns True if the transaction is confirmed within the timeout, otherwise false. */ awaitTransactionConfirmation(txId: string, timeout?: number): Promise; /** * Helper function to convert an RPC UTxO object to a Mesh UTxO object. * @param rpcTxoRef - The transaction output reference from RPC. * @param rpcTxOutput - The transaction output details from RPC. * @returns A formatted UTxO object. */ private _rpcUtxoToMeshUtxo; /** * Converts RPC protocol parameters to a Mesh Protocol object. * @param rpcPParams - The protocol parameters from the RPC. * @returns A Protocol object. */ private _rpcPParamsToProtocol; } /** * Yaci DevKit is a development tool designed for rapid and efficient Cardano blockchain development. It allows developers to create and destroy custom Cardano devnets in seconds, providing fast feedback loops and simplifying the iteration process. * * Get started: * ```typescript * import { YaciProvider } from "@meshsdk/core"; * const provider = new YaciProvider('', ''); * ``` */ declare class YaciProvider implements IFetcher, IListener, ISubmitter, IEvaluator { private readonly _axiosInstance; private readonly _adminAxiosInstance; /** * Set the URL of the instance. * @param baseUrl The base URL of the instance. */ constructor(baseUrl?: string, adminUrl?: string); /** * Obtain information about a specific stake account. * @param address - Wallet address to fetch account information */ fetchAccountInfo(address: string): Promise; private resolveScriptRef; private toUTxO; /** * Fetches the assets for a given address. * @param address - The address to fetch assets for * @returns A map of asset unit to quantity */ fetchAddressAssets(address: string): Promise<{ [key: string]: string; }>; /** * UTXOs of the address. * @param address - The address to fetch UTXO * @param asset - UTXOs of a given asset​ * @returns - Array of UTxOs */ fetchAddressUTxOs(address: string, asset?: string): Promise; /** * Unimplemented - open for contribution * * Transactions for an address. The `TransactionInfo` would only return the `hash`, `inputs`, and `outputs`. * @param address - The address to fetch transactions for * @returns - partial TransactionInfo */ fetchAddressTxs(address: string, option?: IFetcherOptions): Promise; /** * Fetches the asset addresses for a given asset. * @param asset - The asset to fetch addresses for */ fetchAssetAddresses(asset: string): Promise<{ address: string; quantity: string; }[]>; /** * Fetches the metadata for a given asset. * @param asset - The asset to fetch metadata for * @returns The metadata for the asset */ fetchAssetMetadata(asset: string): Promise; /** * Fetches the block information for a given block hash. * @param hash The block hash to fetch from * @returns The block information */ fetchBlockInfo(hash: string): Promise; /** * Fetches the list of assets for a given policy ID. * @param policyId The policy ID to fetch assets for * @param cursor The cursor for pagination * @returns The list of assets and the next cursor */ fetchCollectionAssets(policyId: string, cursor?: number): Promise<{ assets: Asset[]; next: string | number | null; }>; fetchHandle(handle: string): Promise; fetchHandleAddress(handle: string): Promise; /** * Fetch the latest protocol parameters. * @param epoch Optional - The epoch to fetch protocol parameters for * @returns - Protocol parameters */ fetchProtocolParameters(epoch?: number): Promise; fetchCostModels(epoch?: number): Promise; /** * Fetches the transaction information for a given transaction hash. * @param hash The transaction hash to fetch * @returns The transaction information */ fetchTxInfo(hash: string): Promise; /** * Get UTxOs for a given hash. * @param hash The transaction hash * @param index Optional - The output index for filtering post fetching * @returns - Array of UTxOs */ fetchUTxOs(hash: string, index?: number): Promise; /** * Unimplemented - open for contribution * * Fetches the governance proposal information. * @param txHash The transaction hash of the proposal * @param certIndex The certificate index of the proposal * @returns The governance proposal information */ fetchGovernanceProposal(txHash: string, certIndex: number): Promise; get(url: string): Promise; /** * Allow you to listen to a transaction confirmation. Upon confirmation, the callback will be called. * @param txHash - The transaction hash to listen for confirmation * @param callback - The callback function to call when the transaction is confirmed * @param limit - The number of blocks to wait for confirmation */ onTxConfirmed(txHash: string, callback: () => void, limit?: number): void; /** * Submit a serialized transaction to the network. * @param tx - The serialized transaction in hex to submit * @returns The transaction hash of the submitted transaction */ submitTx(txHex: string): Promise; /** * Evaluates the resources required to execute the transaction * @param tx - The transaction to evaluate */ evaluateTx(txHex: string, additionalUtxos?: UTxO[], additionalTxs?: string[]): Promise[]>; getDevnetInfo(): Promise; getGenesisByEra(era: string): Promise; /** * Topup address with ADA * @param address - Address to topup * @param amount - Amount to topup */ addressTopup(address: string, amount: string): Promise; private fetchPlutusScriptCBOR; private fetchNativeScriptJSON; } declare class KupoProvider implements IFetcher { baseUrl: string; private readonly _axiosInstance; constructor(baseUrl: string); fetchAccountInfo(address: string): Promise; fetchAddressUTxOs(address: string, asset?: string): Promise; fetchAddressTxs(address: string, options?: IFetcherOptions): Promise; fetchAssetAddresses(asset: string): Promise<{ address: string; quantity: string; }[]>; fetchAssetMetadata(asset: string): Promise; fetchBlockInfo(hash: string): Promise; fetchCollectionAssets(policyId: string, cursor?: number | string): Promise<{ assets: Asset[]; next?: string | number | null; }>; fetchProtocolParameters(epoch: number): Promise; fetchCostModels(epoch?: number): Promise; fetchTxInfo(hash: string): Promise; fetchUTxOs(hash: string, index?: number): Promise; fetchGovernanceProposal(txHash: string, certIndex: number): Promise; get(pattern: string): Promise; private kupoValueToMeshValue; } type BitcoinChainStats = { funded_txo_count: number; funded_txo_sum: number; spent_txo_count: number; spent_txo_sum: number; tx_count: number; }; type BitcoinMempoolStats = { funded_txo_count: number; funded_txo_sum: number; spent_txo_count: number; spent_txo_sum: number; tx_count: number; }; type BitcoinAddressInfo = { address: string; chain_stats: BitcoinChainStats; mempool_stats: BitcoinMempoolStats; }; type BitcoinScriptInfo = { scripthash: string; chain_stats: BitcoinChainStats; mempool_stats: BitcoinMempoolStats; }; type BitcoinTxStatus = { confirmed: boolean; block_height: number; block_hash: string; block_time: number; }; type BitcoinUTxO = { txid: string; vout: number; value: number; status: { confirmed: boolean; block_height: number; block_hash: string; block_time: number; }; }; type BitcoinTxInfo = { txid: string; version: number; locktime: number; vin: { txid: string; vout: number; prevout: { scriptpubkey: string; scriptpubkey_asm: string; scriptpubkey_type: string; scriptpubkey_address: string; value: number; }; scriptsig: string; scriptsig_asm: string; witness: string[]; is_coinbase: boolean; sequence: number; }[]; vout: { scriptpubkey: string; scriptpubkey_asm: string; scriptpubkey_type: string; scriptpubkey_address: string; value: number; }[]; size: number; weight: number; fee: number; status: BitcoinTxStatus; }; /** * Read-only chain data queries for Bitcoin addresses and scripts. * Mirrors `IBitcoinFetcher` from `@meshsdk/wallet` — structurally compatible. */ interface IBitcoinFetcher { fetchAddressInfo(address: string): Promise; fetchAddressUTxOs(address: string): Promise; fetchUTxO(txid: string, vout?: number): Promise; fetchAddressTxs(address: string, lastSeenTxid?: string): Promise; fetchTxInfo(txid: string): Promise; fetchFeeEstimates(blocks: number): Promise; fetchScriptInfo?(hash: string): Promise; fetchScriptUTxOs?(hash: string): Promise; fetchScriptTxs?(hash: string, lastSeenTxid?: string): Promise; } interface IBitcoinSubmitter { submitTx(tx: string): Promise; } interface IBitcoinProvider extends IBitcoinFetcher, IBitcoinSubmitter { } type BlockstreamNetwork = "mainnet" | "testnet"; type EsploraHeaders = Record; type EsploraClientOptions = { name: string; baseUrl: string; getHeaders?: () => Promise; onUnauthorized?: () => void; }; /** * Shared Esplora HTTP client. Not part of the public package surface. * Public providers implement `IBitcoinProvider`; this base only supplies the HTTP methods. */ declare class EsploraBitcoinClient { private readonly name; private readonly baseUrl; private readonly getHeaders; private readonly onUnauthorized?; constructor({ name, baseUrl, getHeaders, onUnauthorized, }: EsploraClientOptions); private request; protected get(path: string): Promise; fetchAddressInfo(address: string): Promise; fetchAddressUTxOs(address: string): Promise; fetchUTxO(txid: string, vout?: number): Promise; fetchAddressTxs(address: string, lastSeenTxid?: string): Promise; fetchTxInfo(txid: string): Promise; fetchFeeEstimates(blocks: number): Promise; fetchScriptInfo(hash: string): Promise; fetchScriptUTxOs(hash: string): Promise; fetchScriptTxs(hash: string, lastSeenTxid?: string): Promise; submitTx(txHex: string): Promise; } /** * Bitcoin provider backed by the public Blockstream Esplora API. * No API key required. * * @example * ```ts * import { BlockstreamBitcoinProvider } from "@meshsdk/provider"; * import { BitcoinHeadlessWallet } from "@meshsdk/wallet"; * * const provider = new BlockstreamBitcoinProvider("testnet"); * const wallet = await BitcoinHeadlessWallet.fromMnemonic({ * network: "Testnet4", * mnemonic: [...], * provider, * }); * ``` */ declare class BlockstreamBitcoinProvider extends EsploraBitcoinClient implements IBitcoinProvider { constructor(network: BlockstreamNetwork); } interface BlockstreamEnterpriseBitcoinConfig { /** `client_id` from a Blockstream Explorer API key. */ clientId: string; /** `client_secret` from a Blockstream Explorer API key. */ clientSecret: string; network: BlockstreamNetwork; } /** * Bitcoin provider for [Blockstream Explorer Enterprise](https://help.blockstream.com/blockstream-explorer-api/use-explorer-api/make-a-rest-api-request-with-your-api-keys). * Requires an API key pair (`clientId` + `clientSecret`) and uses the same Esplora REST API as the public provider. * * @example * ```ts * import { BlockstreamEnterpriseBitcoinProvider } from "@meshsdk/provider"; * * const provider = new BlockstreamEnterpriseBitcoinProvider({ * clientId: "your-client-id", * clientSecret: "your-client-secret", * network: "mainnet", * }); * ``` */ declare class BlockstreamEnterpriseBitcoinProvider extends EsploraBitcoinClient implements IBitcoinProvider { private accessToken?; private tokenExpiresAt; private tokenRequest?; private readonly clientId; private readonly clientSecret; constructor({ clientId, clientSecret, network, }: BlockstreamEnterpriseBitcoinConfig); private invalidateToken; private authorizationHeaders; private getAccessToken; private fetchAccessToken; } type MaestroBitcoinNetwork = "mainnet" | "testnet"; interface MaestroBitcoinConfig { apiKey: string; network: MaestroBitcoinNetwork; } /** * @deprecated Maestro Bitcoin is no longer supported and will be removed in a later version. */ declare class MaestroBitcoinProvider implements IBitcoinProvider { /** * @deprecated Maestro Bitcoin is no longer supported. Constructor params are kept for compatibility and will be removed in a later version. */ constructor(_config: MaestroBitcoinConfig); /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchAddressInfo(_address: string): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchAddressUTxOs(_address: string): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchUTxO(_txid: string, _vout?: number): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchAddressTxs(_address: string, _lastSeenTxid?: string): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchTxInfo(_txid: string): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchFeeEstimates(_blocks: number): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchScriptInfo(_hash: string): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchScriptUTxOs(_hash: string): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ fetchScriptTxs(_hash: string, _lastSeenTxid?: string): Promise; /** * @deprecated Maestro Bitcoin is no longer supported. */ submitTx(_txHex: string): Promise; } export { BeginProvider, type BitcoinAddressInfo, type BitcoinChainStats, type BitcoinMempoolStats, type BitcoinScriptInfo, type BitcoinTxInfo, type BitcoinTxStatus, type BitcoinUTxO, type BlockfrostCachingOptions, BlockfrostProvider, type BlockfrostSupportedNetworks, BlockstreamBitcoinProvider, type BlockstreamEnterpriseBitcoinConfig, BlockstreamEnterpriseBitcoinProvider, type BlockstreamNetwork, type IBitcoinFetcher, type IBitcoinProvider, type IBitcoinSubmitter, IagonInsightProvider, KoiosProvider, type KoiosSupportedNetworks, KupoProvider, type MaestroBitcoinConfig, type MaestroBitcoinNetwork, MaestroBitcoinProvider, type MaestroConfig, MaestroProvider, type MaestroSupportedNetworks, type NexusNetworkId, NexusProvider, type NexusSupportedNetworks, OfflineFetcher, OgmiosProvider, U5CProvider, YaciProvider };