Rpc
It allows for querying a Pezkuwi Client Node. WebSockets provider is recommended since HTTP provider only supports basic querying.
graph LR; A[Api] --> |WebSockets| B[WsProvider]; B --> |endpoint| C[ws://127.0.0.1:9944] Copy
graph LR; A[Api] --> |WebSockets| B[WsProvider]; B --> |endpoint| C[ws://127.0.0.1:9944]
import Rpc from '@pezkuwi/rpc-core';import { WsProvider } from '@pezkuwi/rpc-provider/ws';const provider = new WsProvider('ws://127.0.0.1:9944');const rpc = new Rpc(provider); Copy
import Rpc from '@pezkuwi/rpc-core';import { WsProvider } from '@pezkuwi/rpc-provider/ws';const provider = new WsProvider('ws://127.0.0.1:9944');const rpc = new Rpc(provider);
Default constructor for the core RPC handler
Type Registry
Optional
Readonly
Returns the connected status of a provider
Returns the underlying core stats, including those from teh provider
Manually connect from the attached provider
Manually disconnect from the attached provider
Sets a registry swap (typically from Api)
Sets a function to resolve block hash from block number
Name
Rpc
Description
It allows for querying a Pezkuwi Client Node. WebSockets provider is recommended since HTTP provider only supports basic querying.
Example