Expand description
rightkit-http: the shared blocking HTTP client for Right Suite apps.
Client: timeouts, bounded bodies, retry/backoff honoringRetry-After, retry-safety rules for non-idempotent methods, streaming responses.Multipart:multipart/form-databodies with exact framing.netpolicy: the outbound address policy (SSRF guard) every request passes: resolve once, classify every address, connect only to checked addresses, on every redirect hop.CancelToken: cooperative cancellation for calls and streams.sse: WHATWG-compliant Server-Sent Events decoding.untrusted(feature, off by default): tamper-evident wrapping of external text for model input.secret: redactedSecret, theSecretStoreinterface and the in-memoryMemorySecretStore(no production implementation ships in this crate).ApprovedOrigins,check_redirect_targetandRedirectRefusal: the redirect origin allowlist (Request::approved_redirect_origins), its typed error (HttpError::RedirectRefused) and a string-level guard for other transports.async_client(featureasync): [AsyncClient], the same policy layer on reqwest/tokio, with a body [BodyStream] and an async [SseStream].testing(feature): in-process mock server that records exact requests.
Re-exports§
pub use cancel::is_cancelled_io;pub use cancel::CancelToken;pub use client::form_encode;pub use client::percent_decode;pub use client::percent_decode_component;pub use client::percent_encode;pub use client::percent_encode_component;pub use client::AttemptDelivery;pub use client::AttemptEvent;pub use client::AttemptOutcome;pub use client::Client;pub use client::ClientConfig;pub use client::Method;pub use client::ProxyDiagnostic;pub use client::ProxyMode;pub use client::ProxyModeUsed;pub use client::Request;pub use client::Response;pub use client::ResponseHead;pub use client::RetryEvent;pub use client::StreamResponse;pub use client::TrustRoots;pub use error::ErrorClass;pub use error::HttpError;pub use error::Phase;pub use multipart::Multipart;pub use multipart::MultipartRelated;pub use netpolicy::check_redirect_target;pub use netpolicy::parse_host_ip;pub use netpolicy::parse_legacy_ipv4;pub use netpolicy::validate_public_https_url;pub use netpolicy::AddressClass;pub use netpolicy::AddressPolicy;pub use netpolicy::ApprovedOrigins;pub use netpolicy::CredentialScope;pub use netpolicy::HostIpKind;pub use netpolicy::IpNet;pub use netpolicy::ParsedHostIp;pub use netpolicy::RedirectRefusal;pub use netpolicy::ResolveError;pub use netpolicy::UrlPolicyError;pub use quota::defer_in;pub use quota::remaining_in;pub use quota::QuotaSchedule;pub use quota::QuotaStore;pub use retry::parse_rate_limit_reset;pub use retry::parse_rate_limit_reset_at;pub use retry::parse_retry_after;pub use retry::parse_retry_after_at;pub use retry::RetryPolicy;pub use secret::MemorySecretStore;pub use secret::Secret;pub use secret::SecretError;pub use secret::SecretStore;pub use sse::EofPolicy;pub use sse::SseDecoder;pub use sse::SseEvent;pub use sse::SseReader;
Modules§
- cancel
- Cooperative cancellation shared by buffered calls and streams.
- client
- error
- multipart
multipart/form-datarequest bodies with exact, testable framing.- netpolicy
- Outbound address policy: address classification and the SSRF guard behind every
crate::Clientand [crate::AsyncClient] request. - quota
- Durable per-provider quota scheduling.
- retry
- secret
- Secret handling shared by the net crates: the redacted
Secret, theSecretStoreinterface andMemorySecretStore, an in-memory implementation for tests and ephemeral sessions. This crate holds no production (Keychain / Credential Manager) implementation, andrightkit-credentialsdoes not implementSecretStore(it has its ownStoreandSecrettypes and does not depend on this crate). An app that wants OS-backed storage behind this trait implements it itself. - sse
- Server-Sent Events decoder (WHATWG EventSource framing): LF, CR and CRLF line
endings, multi-line
data, comments,id,retry, BOM, bounded line size.