pub struct NamedProviderConfig {
pub api_key: Option<String>,
pub azure: Option<ProviderConfigAzure>,
pub base_url: String,
pub bearer_token: Option<String>,
pub headers: Option<HashMap<String, String>>,
pub name: String,
pub type: Option<ProviderConfigType>,
pub wire_api: Option<ProviderConfigWireApi>,
}Expand description
A named BYOK provider connection (transport + credentials).
Experimental. This type is part of an experimental wire-protocol surface and may change or be removed in future SDK or CLI releases.
Fields§
§api_key: Option<String>API key. Optional for local providers like Ollama.
azure: Option<ProviderConfigAzure>Azure-specific provider options.
base_url: StringAPI endpoint URL.
bearer_token: Option<String>Bearer token for authentication. Sets the Authorization header directly. Takes precedence over apiKey when both are set.
headers: Option<HashMap<String, String>>Custom HTTP headers to include in all outbound requests to the provider.
name: StringStable identifier referenced by BYOK model definitions. Must not contain ‘/’.
type: Option<ProviderConfigType>Provider type. Defaults to “openai” for generic OpenAI-compatible APIs.
wire_api: Option<ProviderConfigWireApi>Wire API format (openai/azure only). Defaults to “completions”.
Trait Implementations§
Source§impl Clone for NamedProviderConfig
impl Clone for NamedProviderConfig
Source§fn clone(&self) -> NamedProviderConfig
fn clone(&self) -> NamedProviderConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 NamedProviderConfig
impl Debug for NamedProviderConfig
Source§impl Default for NamedProviderConfig
impl Default for NamedProviderConfig
Source§fn default() -> NamedProviderConfig
fn default() -> NamedProviderConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for NamedProviderConfig
impl<'de> Deserialize<'de> for NamedProviderConfig
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
Auto Trait Implementations§
impl Freeze for NamedProviderConfig
impl RefUnwindSafe for NamedProviderConfig
impl Send for NamedProviderConfig
impl Sync for NamedProviderConfig
impl Unpin for NamedProviderConfig
impl UnsafeUnpin for NamedProviderConfig
impl UnwindSafe for NamedProviderConfig
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