Skip to main content

Module transport

Module transport 

Source
Expand description

Foundry policy for the canonical MPP Alloy HTTP transport.

Re-exportsΒ§

use alloy_chains::Chain; πŸ”’
use alloy_json_rpc::RequestPacket; πŸ”’
use alloy_json_rpc::ResponsePacket; πŸ”’
use alloy_json_rpc::RpcError; πŸ”’
use alloy_transport::TransportError; πŸ”’
use alloy_transport::TransportFut; πŸ”’
use alloy_transport_mpp::MppHttpTransport; πŸ”’
use alloy_transport_mpp::MppWsConnect; πŸ”’
use mpp::MppError; πŸ”’
use mpp::PaymentErrorDetails; πŸ”’
use mpp::client::PaymentContext; πŸ”’
use mpp::client::PaymentProvider; πŸ”’
use mpp::client::TempoAccountsProvider; πŸ”’
use mpp::client::tempo::autoswap::AutoswapConfig; πŸ”’
use mpp::client::tempo::autoswap::DEFAULT_SLIPPAGE_BPS; πŸ”’
use mpp::client::tempo::session::store::SqliteChannelStore; πŸ”’
use mpp::client::tempo::session::store::SqliteChannelStoreOptions; πŸ”’
use mpp::protocol::core::PaymentChallenge; πŸ”’
use mpp::protocol::core::PaymentCredential; πŸ”’
use mpp::protocol::intents::ChargeRequest; πŸ”’
use mpp::protocol::intents::SessionRequest; πŸ”’
use std::collections::HashMap; πŸ”’
use std::env; πŸ”’
use std::env; πŸ”’
use std::fmt; πŸ”’
use std::io; πŸ”’
use std::io::IsTerminal; πŸ”’
use std::process::Command; πŸ”’
use std::process::Stdio; πŸ”’
use std::sync::Arc; πŸ”’
use std::sync::Mutex; πŸ”’
use std::sync::MutexGuard; πŸ”’
use std::sync::PoisonError; πŸ”’
use std::task; πŸ”’
use tempo_alloy::accounts::TempoAccountsError; πŸ”’
use tempo_alloy::accounts::TempoAccountsStore; πŸ”’
use tower::Service; πŸ”’
use url::Url; πŸ”’

StructsΒ§

FundingContext πŸ”’
LazyAccountsProvider
Lazily resolves a chain-bound MPP Charge provider from Tempo Accounts.
LazyMppHttpTransport
The MPP transport used by Foundry’s runtime transport builder.

ConstantsΒ§

DEFAULT_MPP_SESSION_DEPOSIT πŸ”’
Open a channel with 0.02 tokens when the server does not suggest a deposit.
MAX_CONCURRENT_MPP_HTTP_REQUESTS πŸ”’
Keep high-fanout fork database reads from overwhelming paid RPC endpoints.
MAX_MPP_SESSION_DEPOSIT πŸ”’
Never let a paid RPC reserve more than one six-decimal token automatically.

FunctionsΒ§

extract_challenge_chain_and_currency πŸ”’
Extract (chainId, currency) from a Tempo Charge or Session challenge.
has_access_key_for_challenge πŸ”’
insufficient_balance_details πŸ”’
interactive_fund_allowed πŸ”’
interactive_login_allowed πŸ”’
lazy_mpp_ws_connect πŸ”’
Build the canonical MPP WebSocket connector with Foundry’s lazy Accounts provider.
lock_map πŸ”’
redacted_url πŸ”’
run_interactive_tempo_fund πŸ”’
with_funding_help πŸ”’
with_transport_funding_help πŸ”’