import type { AnyCell, MapCell, SheetProxy } from "@okcontract/cells";
import type { CacheQuery, ContractQueryType, OKWidgetStep, OKWidgetStepType, SmartContract } from "@okcontract/coredata";
import { type Address, type ChainType, type LocalRPCSubscriber, type Network } from "@okcontract/multichain";
import type { LocalSubscriber } from "@scv/cache";
import type { AnyAddress } from "./types";
export declare const contractQuery: (step: OKWidgetStep<OKWidgetStepType>) => ContractQueryType;
export declare const is_contract_addr: (addr: string, ch: ChainType) => Promise<boolean>;
/**
 * contract_address returns the address on a given contract.
 * @param con
 * @returns
 * @todo check current chain matches?
 */
export declare const contractAddress: (proxy: SheetProxy, con: AnyCell<SmartContract>, ch: AnyCell<ChainType>) => MapCell<Address<Network>, true>;
/**
 * call any smart contract method.
 * @param ch chain
 * @param con contract, or token or address
 * @param meth method (as string)
 * @param params
 * @todo move out from erc20
 */
export declare const callMethod: <Args extends AnyCell<unknown>[]>(rpc: LocalRPCSubscriber, local: LocalSubscriber<CacheQuery>, chain: AnyCell<ChainType>, q: AnyCell<AnyAddress>, meth: AnyCell<string>, args: AnyCell<Args>) => Promise<MapCell<unknown, false>>;
