Methods
fetchContractAccountsBalance
- fetchContractAccountsBalance(contractAddress: {
contractAddress: string;
pagination?: PaginationOption;
}): Promise<ContractAccountsBalanceWithPagination>
-
Parameters
-
contractAddress: {
contractAddress: string;
pagination?: PaginationOption;
}
-
contractAddress: string
-
Optional
pagination?: PaginationOption
Returns Promise<ContractAccountsBalanceWithPagination>
fetchContractHistory
- fetchContractHistory(contractAddress: string): Promise<{
entriesList: ContractCodeHistoryEntry[];
pagination: AsObject;
}>
-
Returns Promise<{
entriesList: ContractCodeHistoryEntry[];
pagination: AsObject;
}>
fetchContractInfo
- fetchContractInfo(contractAddress: string): Promise<undefined | ContractInfo>
-
Returns Promise<undefined | ContractInfo>
fetchRawContractState
- fetchRawContractState(contractAddress: string, query?: string | Uint8Array): Promise<AsObject>
-
Parameters
-
contractAddress: string
-
Optional
query: string | Uint8Array
Returns Promise<AsObject>
fetchSmartContractState
- fetchSmartContractState(contractAddress: string, query?: string | Uint8Array): Promise<{
data: Record<string, any>;
}>
-
Parameters
-
contractAddress: string
-
Optional
query: string | Uint8Array
Returns Promise<{
data: Record<string, any>;
}>
The Wasm module manages contract state and info.
Example
To use Wasm methods, initialise a ChainGrpcWasmApi object to with a gRPC endpoint. An endpoint can be retrieved by using networkEndpoints.