Expand description
Re-exports§
pub use http::Accepted;pub use http::ApiError;pub use http::ExchangeResponse;pub use http::Http;pub use http::Method;pub use http::Request;pub use http::Response;pub use http::Spent;pub use http::Status;pub use http::Transport;pub use http::TransportError;pub use http::exchange;pub use http::info;pub use http::info_request;pub use http::user_request;pub use network::L1_CHAIN_ID;pub use network::MAINNET_HYPE;pub use network::MAINNET_USDC;pub use network::Network;pub use network::TESTNET_HYPE;pub use network::TESTNET_USDC;pub use network::Token;pub use network::USDC_INDEX;pub use network::UnknownNetwork;
Modules§
- evm
- HyperEVM and the Arbitrum side of the bridge: typed JSON-RPC, ABI, RLP, EIP-1559
transactions, HyperCore’s read precompiles and CoreWriter actions. Sans-IO;
quantities are exact integers (
U256) and amounts convert tocrate::utils::Dec. Chain ids come fromcrate::client::Network. - http
- HTTP to
/infoand/exchange: theHttpwire, theTransportevery read and action goes through, what/exchangeanswers, the signed body it takes, and the rate limit. - native
- HTTP and websocket for native programs:
Nativesends requests through reqwest on rustls,clockis the system clock, and aFeedkeeps the websocket open over tokio-tungstenite. Hand the first two to acrate::Client: - network
- Mainnet and testnet. Everything that differs between them is a method on
Network; an action signed for one is never valid on the other, so the network is never assumed. - web
- HTTP and websocket for the browser and Workers:
Websends requests through the globalfetch,clockisDate.now(), and aFeedkeeps the websocket open over the globalWebSocket. Hand the first two to acrate::Client:
Structs§
- Client
- Reads for any module (
markets::perps::meta(&client)) and, with aSigner, actions.Sis()for a client that only reads.
Enums§
- Send
Error - Why an action was not taken. An action whose answer never came
(
TransportError::Unreachable) may have landed, so it is never resent.
Type Aliases§
- Clock
- Unix milliseconds. Injected: std has no clock in the browser or Workers, and a test pins the time.