pub struct KeyAuth {
pub hide_credentials: Option<bool>,
pub query: Option<String>,
pub header: Option<String>,
}Expand description
The key-auth Plugin is used to add an authentication key (API key) to a Route or a Service. This works well with a Consumer. Consumers of the API can then add their key to the query string or the header to authenticate their requests. Documentation
Fields§
§hide_credentials: Option<bool>§query: Option<String>§header: Option<String>Trait Implementations§
Source§impl<'de> Deserialize<'de> for KeyAuth
impl<'de> Deserialize<'de> for KeyAuth
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 From<KeyAuth> for KeyAuthBuilder
impl From<KeyAuth> for KeyAuthBuilder
impl Plugin for KeyAuth
impl StructuralPartialEq for KeyAuth
Auto Trait Implementations§
impl Freeze for KeyAuth
impl RefUnwindSafe for KeyAuth
impl Send for KeyAuth
impl Sync for KeyAuth
impl Unpin for KeyAuth
impl UnwindSafe for KeyAuth
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