pub enum AuthType {
Token(String),
UsernamePassword(String, String),
}Expand description
Enum representing the type of authentication to use.
§Examples
use http_request_zabbix::AuthType;
let auth_type = AuthType::UsernamePassword("Admin".to_string(), "zabbix".to_string());use http_request_zabbix::AuthType;
let auth_type = AuthType::Token("817dc89d0ae1d347fbcacdd6c00f322d0ec0651a8df60115304216dc768205db".to_string());Variants§
Token(String)
Token authentication. Use it if you have a token from Zabbix. More info: https://www.zabbix.com/documentation/current/en/manual/web_interface/frontend_sections/users/api_tokens
UsernamePassword(String, String)
Username and password authentication. Use it if you have a username and password for Zabbix.
Auto Trait Implementations§
impl Freeze for AuthType
impl RefUnwindSafe for AuthType
impl Send for AuthType
impl Sync for AuthType
impl Unpin for AuthType
impl UnsafeUnpin for AuthType
impl UnwindSafe for AuthType
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