pub struct AccessTokenDto {Show 17 fields
pub id: Uuid,
pub tenant_id: String,
pub article_id: String,
pub creator_id: String,
pub reader_wallet: String,
pub transaction_id: Option<Uuid>,
pub access_method: AccessMethodDto,
pub issued_at: DateTime<Utc>,
pub expires_at: DateTime<Utc>,
pub is_valid: bool,
pub is_expired: bool,
pub is_revoked: bool,
pub revoked_at: Option<DateTime<Utc>>,
pub revocation_reason: Option<String>,
pub remaining_days: i64,
pub access_count: u32,
pub last_accessed_at: Option<DateTime<Utc>>,
}Expand description
DTO for an access token in responses
Fields§
§id: Uuid§tenant_id: String§article_id: String§creator_id: String§reader_wallet: String§transaction_id: Option<Uuid>§access_method: AccessMethodDto§issued_at: DateTime<Utc>§expires_at: DateTime<Utc>§is_valid: bool§is_expired: bool§is_revoked: bool§revoked_at: Option<DateTime<Utc>>§revocation_reason: Option<String>§remaining_days: i64§access_count: u32§last_accessed_at: Option<DateTime<Utc>>Trait Implementations§
Source§impl Clone for AccessTokenDto
impl Clone for AccessTokenDto
Source§fn clone(&self) -> AccessTokenDto
fn clone(&self) -> AccessTokenDto
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AccessTokenDto
impl Debug for AccessTokenDto
Source§impl From<&AccessToken> for AccessTokenDto
impl From<&AccessToken> for AccessTokenDto
Source§fn from(token: &AccessToken) -> Self
fn from(token: &AccessToken) -> Self
Converts to this type from the input type.
Source§impl From<AccessToken> for AccessTokenDto
impl From<AccessToken> for AccessTokenDto
Source§fn from(token: AccessToken) -> Self
fn from(token: AccessToken) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for AccessTokenDto
impl RefUnwindSafe for AccessTokenDto
impl Send for AccessTokenDto
impl Sync for AccessTokenDto
impl Unpin for AccessTokenDto
impl UnsafeUnpin for AccessTokenDto
impl UnwindSafe for AccessTokenDto
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