pub struct ApiConfig {
pub address: Option<String>,
pub objectiveai_authorization: Option<String>,
pub openrouter_authorization: Option<String>,
pub github_authorization: Option<String>,
pub mcp_authorization: Option<IndexMap<String, String>>,
pub user_agent: Option<String>,
pub http_referer: Option<String>,
pub x_title: Option<String>,
pub commit_author_name: Option<String>,
pub commit_author_email: Option<String>,
pub mcp_timeout_ms: Option<u64>,
}Fields§
§address: Option<String>§user_agent: Option<String>§http_referer: Option<String>§x_title: Option<String>X-Title HTTP header — keeps the x_ prefix because that’s the
literal header name (every other field had its x_ dropped on
the flatten).
mcp_timeout_ms: Option<u64>MCP timeout override, in milliseconds. One value, fanned out to
the connect timeout, the per-call timeout, AND the backoff
max-elapsed-time of every MCP client this CLI drives (its
streaming conduit) and projected onto the spawned API’s MCP_*
env (which in turn drives the proxy it spawns). None ⇒ the
canonical default (60000ms). The other exponential-backoff knobs
(intervals / randomization / multiplier) keep their built-in
defaults.
Implementations§
Source§impl ApiConfig
impl ApiConfig
pub fn is_empty(&self) -> bool
pub fn is_none(this: &Option<Self>) -> bool
pub fn get_address(&self) -> Option<&str>
pub fn set_address(&mut self, value: impl Into<String>)
pub fn get_user_agent(&self) -> Option<&str>
pub fn set_user_agent(&mut self, value: impl Into<String>)
pub fn get_http_referer(&self) -> Option<&str>
pub fn set_http_referer(&mut self, value: impl Into<String>)
pub fn get_x_title(&self) -> Option<&str>
pub fn set_x_title(&mut self, value: impl Into<String>)
pub fn get_mcp_timeout_ms(&self) -> Option<u64>
pub fn set_mcp_timeout_ms(&mut self, value: u64)
pub fn jq(&self, filter: &str) -> Result<Vec<Value>, Error>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ApiConfig
impl<'de> Deserialize<'de> for ApiConfig
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 ApiConfig
impl JsonSchema for ApiConfig
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 ApiConfig
impl RefUnwindSafe for ApiConfig
impl Send for ApiConfig
impl Sync for ApiConfig
impl Unpin for ApiConfig
impl UnsafeUnpin for ApiConfig
impl UnwindSafe for ApiConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more