70ddb6516f
- Add pezkuwi-subxt crates to vendor/pezkuwi-subxt - Add pezkuwi-zombienet-sdk crates to vendor/pezkuwi-zombienet-sdk - Convert git dependencies to path dependencies - Add vendor crates to workspace members - Remove test/example crates from vendor (not needed for SDK) - Fix feature propagation issues detected by zepter - Fix workspace inheritance for internal dependencies - All 606 crates now in workspace - All 6919 internal dependency links verified correct - No git dependencies remaining
18 lines
614 B
Markdown
18 lines
614 B
Markdown
# subxt-rpcs
|
|
|
|
This crate provides an interface for interacting with Bizinikiwi nodes via the available RPC methods.
|
|
|
|
```rust
|
|
use subxt_rpcs::{RpcClient, ChainHeadRpcMethods};
|
|
|
|
// Connect to a local node:
|
|
let client = RpcClient::from_url("ws://127.0.0.1:9944").await?;
|
|
// Use a set of methods, here the V2 "chainHead" ones:
|
|
let methods = ChainHeadRpcMethods::new(client);
|
|
|
|
// Call some RPC methods (in this case a subscription):
|
|
let mut follow_subscription = methods.chainhead_v1_follow(false).await.unwrap();
|
|
while let Some(follow_event) = follow_subscription.next().await {
|
|
// do something with events..
|
|
}
|
|
``` |