Crate starknet_providers

Crate starknet_providers 

Source
Expand description

Clients for interacting with Starknet nodes and sequencers.

This crate provides the Provider trait for abstraction over means of accessing the Starknet network. The most commonly used implementation is JsonRpcClient with HttpTransport.

Re-exports§

pub use sequencer::GatewayClientError as SequencerGatewayProviderError;
pub use sequencer::SequencerGatewayProvider;
pub use jsonrpc::JsonRpcClient;

Modules§

jsonrpc
Module containing types related to JSON-RPC clients and servers.
sequencer
Module containing types related to the (now deprecated) sequencer gateway client.

Structs§

Url
A parsed URL record.

Enums§

AnyProvider
A convenient Box-able type that implements the Provider trait. This can be useful when you want to accept any built-in provider implementation from the library in your appliation, since the Provider trait itself cannot be Box-ed due to the use of associated type.
ProviderError
Errors using any Provider implementation. This type is deliberately not made generic such that:
ProviderRequestData
Typed request data for Provider requests.
ProviderResponseData
Typed response data for Provider responses.
StreamUpdateData
Typed data for stream updates.

Traits§

Provider
A generic interface for any type allowing communication with a Starknet network.
ProviderImplError
Trait for implementation-specific error type. These errors are irrelevant in most cases, assuming that users typically care more about the specifics of RPC errors instead of the underlying transport. Therefore, it makes little sense to bloat ProviderError with a generic parameter just for these errors. Instead, they’re erased to this trait object.