pub struct User {
pub uuid: Uuid,
pub auth_provider: String,
pub external_id: String,
pub role: String,
pub email: String,
pub suspended: bool,
pub has_api_key: bool,
pub created_at: i64,
pub updated_at: i64,
}Expand description
A Dinio user account. A non-Admin can read only their own
(Users::get).
Fields§
§uuid: UuidUser id; what a zone Owner needs to add the user as a zone member.
auth_provider: StringIdentity provider that created the account (e.g. the IdP name, dev in
development).
external_id: StringThe user’s id at that provider.
role: StringAdmin or User (kept as a string for forward compatibility).
email: StringEmail address, unique on the platform.
suspended: boolA suspended user cannot sign in or use their key, and the zone keys of zones they
own stop working too. Only an Admin can change it, so a suspended user never sees
true here.
has_api_key: boolWhether the user has a personal API key. The key itself is shown only once, by
Users::create_api_key.
created_at: i64Unix seconds.
updated_at: i64Unix seconds.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for User
impl<'de> Deserialize<'de> for User
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 User
impl RefUnwindSafe for User
impl Send for User
impl Sync for User
impl Unpin for User
impl UnsafeUnpin for User
impl UnwindSafe for User
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