@yubing744/rooch-sdk
Version:
25 lines (24 loc) • 3.21 kB
TypeScript
import { RequestManager, Client } from "@open-rpc/client-js";
import { InscriptionFilterView, IndexerStateID, usize, InscriptionStatePageView, UTXOFilterView, UTXOStatePageView, ExecuteTransactionResponseView, FunctionCallView, AnnotatedFunctionResultView, RoochAccountAddress, RoochStructTag, BalanceInfoView, PageView_for_BalanceInfoView_and_String, u64, EventOptions, EventPageView, AccessPath, StateOptions, StateView, primitive_types_H256, TransactionWithInfoView, TransactionWithInfoPageView, StatePageView, EventFilterView, IndexerEventID, PageView_for_IndexerEventView_and_IndexerEventID, GlobalStateFilterView, GlobalStateView, TableStateFilterView, TableStateView, TransactionFilterView, StateSyncFilterView, PageView_for_IndexerTableChangeSetView_and_IndexerStateID } from "./types";
export declare class JsonRpcClient extends Client {
constructor(requestManager: RequestManager);
getRpcApiVersion(): Promise<string | undefined>;
btc_queryInscriptions(filter: InscriptionFilterView, cursor: IndexerStateID, limit: usize, descending_order: boolean): Promise<InscriptionStatePageView>;
btc_queryUTXOs(filter: UTXOFilterView, cursor: IndexerStateID, limit: usize, descending_order: boolean): Promise<UTXOStatePageView>;
rooch_executeRawTransaction(tx_bcs_hex: Uint8Array): Promise<ExecuteTransactionResponseView>;
rooch_executeViewFunction(function_call: FunctionCallView): Promise<AnnotatedFunctionResultView>;
rooch_getBalance(account_addr: RoochAccountAddress, coin_type: RoochStructTag): Promise<BalanceInfoView>;
rooch_getBalances(account_addr: RoochAccountAddress, cursor: string, limit: usize): Promise<PageView_for_BalanceInfoView_and_String>;
rooch_getChainID(): Promise<u64>;
rooch_getEventsByEventHandle(event_handle_type: RoochStructTag, cursor: u64, limit: u64, event_options: EventOptions): Promise<EventPageView>;
rooch_getStates(access_path: AccessPath, state_option: StateOptions): Promise<StateView | null[]>;
rooch_getTransactionsByHash(tx_hashes: primitive_types_H256[]): Promise<TransactionWithInfoView | null[]>;
rooch_getTransactionsByOrder(cursor: u64, limit: u64): Promise<TransactionWithInfoPageView>;
rooch_listStates(access_path: AccessPath, cursor: string, limit: usize, state_option: StateOptions): Promise<StatePageView>;
rooch_queryEvents(filter: EventFilterView, cursor: IndexerEventID, limit: usize, descending_order: boolean): Promise<PageView_for_IndexerEventView_and_IndexerEventID>;
rooch_queryGlobalStates(filter: GlobalStateFilterView, cursor: IndexerStateID, limit: usize, descending_order: boolean): Promise<GlobalStateView>;
rooch_queryTableStates(filter: TableStateFilterView, cursor: IndexerStateID, limit: usize, descending_order: boolean): Promise<TableStateView>;
rooch_queryTransactions(filter: TransactionFilterView, cursor: u64, limit: usize, descending_order: boolean): Promise<TransactionWithInfoPageView>;
rooch_sendRawTransaction(tx_bcs_hex: Uint8Array): Promise<primitive_types_H256>;
rooch_syncStates(filter: StateSyncFilterView, cursor: IndexerStateID, limit: usize, descending_order: boolean): Promise<PageView_for_IndexerTableChangeSetView_and_IndexerStateID>;
}