pub struct HttpFactoryConfig {
pub base_url: String,
pub headers: HashMap<String, String>,
}Expand description
Configuration for an HTTP request factory (type = “http”).
Fields§
§base_url: StringBase URL for all requests. May contain $VAR_NAME.
headers: HashMap<String, String>Default headers merged into every request. May contain $VAR_NAME.
Implementations§
Source§impl HttpFactoryConfig
impl HttpFactoryConfig
Sourcepub fn build_request(&self, input: &HttpFactoryToolInput) -> HttpRequestInput
pub fn build_request(&self, input: &HttpFactoryToolInput) -> HttpRequestInput
Build an HttpRequestInput from factory defaults + per-call input.
If url is set, use it as-is (external API call — base_url is NOT prepended).
If path is set, prepend base_url (platform API call).
Factory default headers are merged, but per-call headers win on conflict.
Trait Implementations§
Source§impl Clone for HttpFactoryConfig
impl Clone for HttpFactoryConfig
Source§fn clone(&self) -> HttpFactoryConfig
fn clone(&self) -> HttpFactoryConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HttpFactoryConfig
impl Debug for HttpFactoryConfig
Source§impl<'de> Deserialize<'de> for HttpFactoryConfig
impl<'de> Deserialize<'de> for HttpFactoryConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for HttpFactoryConfig
impl JsonSchema for HttpFactoryConfig
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for HttpFactoryConfig
impl RefUnwindSafe for HttpFactoryConfig
impl Send for HttpFactoryConfig
impl Sync for HttpFactoryConfig
impl Unpin for HttpFactoryConfig
impl UnsafeUnpin for HttpFactoryConfig
impl UnwindSafe for HttpFactoryConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more