Public declaration syntax from forge-rs/harness-runtime/src/planes/http.rs Original source SHA-256: bc8f1f50d78d444a8ed950487b585a3a2f747a3f6f97b7fb0029c3e6325b378a Function bodies and constant values are omitted. This is not the complete implementation. Source line 21 #[derive(Debug, Error)] pub enum HttpClientError { /// The base URL is not a valid absolute http(s) URL. #[error("invalid plane base URL {url:?}: {reason}")] InvalidBaseUrl { /// The offending URL. url: String, /// Why it is invalid. reason: String, }, /// The underlying HTTP client could not be built. #[error("http client build failed: {0}")] BuildFailed(String), } Source line 44 #[derive(Debug, Clone)] pub struct HttpPlaneClient { } Source line 57 pub fn new( plane: PlaneKind, base_url: impl Into, timeout: Duration, ) -> Result; Source line 92 pub fn with_default_header(mut self, name: &str, value: impl Into) -> Self; Source line 99 pub fn plane(&self) -> PlaneKind; Source line 104 pub fn base_url(&self) -> &str; Source line 109 pub fn timeout(&self) -> Duration; Source line 114 pub fn url(&self, path: &str) -> String; Source line 120 pub async fn post_json( &self, path: &str, body: &B, trace: &TraceContext, ) -> Result where B: Serialize + Sync, T: DeserializeOwned,; Source line 147 pub async fn get_json(&self, path: &str, trace: &TraceContext) -> Result where T: DeserializeOwned,;