Expand description
Registry API client for shipper.
This crate provides API clients for interacting with crate registries like crates.io, supporting version existence checks, sparse-index visibility polling, ownership verification, and readiness backoff loops.
§Modules
context— the primaryRegistryClientthat isRegistry-aware. Accepts a fullshipper_types::Registry(name, api_base, index_base) and exposes the complete registry surface used by the shipper library: API existence checks, sparse-index visibility, owner queries,is_version_visible_with_backoffwith exponential-backoff evidence, etc.http— a lightweight HTTP clienthttp::HttpRegistryClientthat takes a bare base-URL string. Intended for callers that do not need the fullRegistrycontext (e.g. the parallel engine helper crate).
§Example
use shipper_registry::RegistryClient;
use shipper_types::Registry;
let registry = Registry::crates_io();
let client = RegistryClient::new(registry).expect("client");
let visible = client.version_exists("serde", "1.0.0").unwrap_or(false);Re-exports§
pub use context::Owner;pub use context::OwnersResponse;pub use context::RegistryClient;pub use http::HttpRegistryClient;pub use http::CrateInfo;pub use http::OwnersApiUser;
Modules§
Constants§
- CRATES_
IO_ API - Default API endpoint for crates.io
- DEFAULT_
TIMEOUT_ SECS - Default timeout for API requests (used by
HttpRegistryClient). - USER_
AGENT - Default user agent for API requests.
Functions§
- is_
crate_ visible - Check if a crate exists on the registry via its API.
- is_
version_ visible - Check if a crate version is visible on the registry via its API.
- sparse_
index_ path - Compute the sparse-index path for a crate name.