pub struct Auth {
pub api_key: Option<String>,
pub headers: IndexMap<String, Option<String>>,
pub source: Option<String>,
pub base_url: Option<String>,
pub error: Option<String>,
pub env: Option<ProviderEnv>,
}Expand description
Credentials for one request.
Fields§
§api_key: Option<String>The API key, if the provider takes one.
headers: IndexMap<String, Option<String>>Headers that carry or accompany the credential. None removes a header.
source: Option<String>Where the credential came from, for messages.
base_url: Option<String>Replaces the model’s base URL, for accounts with their own endpoint.
error: Option<String>Why credentials could not be resolved. A request with it fails.
env: Option<ProviderEnv>Provider settings from the credential, such as a Cloudflare account id, that the request reads ahead of the process environment.
Implementations§
Trait Implementations§
impl StructuralPartialEq for Auth
Auto Trait Implementations§
impl Forget for Auth
impl Freeze for Auth
impl RefUnwindSafe for Auth
impl Send for Auth
impl Sync for Auth
impl Unpin for Auth
impl UnsafeUnpin for Auth
impl UnwindSafe for Auth
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