pub struct Account {
pub email: String,
pub maildrop_email: String,
/* private fields */
}Fields§
§email: String§maildrop_email: StringImplementations§
Source§impl Account
impl Account
Sourcepub async fn login(email: &str, password: &str) -> Result<Self, Error>
pub async fn login(email: &str, password: &str) -> Result<Self, Error>
Log in to Things Cloud API with the provided credentials.
§Errors
Returns Error::AccountHasIssues if the account has outstanding issues.
Returns Error::UnknownAccountStatus if the account has an unknown status.
Returns Error::InvalidCredentials if the provided credentials are invalid.
Returns Error::Reqwest if an error occurred while communicating with the Things Cloud API.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Account
impl !RefUnwindSafe for Account
impl Send for Account
impl Sync for Account
impl Unpin for Account
impl !UnwindSafe for Account
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