pub struct ATProtocolSession {
pub did: String,
pub handle: String,
pub access_token: String,
pub token_type: String,
pub scopes: Vec<String>,
pub pds_endpoint: String,
pub dpop_key: Option<String>,
pub dpop_jwk: Option<WrappedJsonWebKey>,
pub expires_at: i64,
}Expand description
Represents an authenticated AT Protocol session.
This structure contains all the information needed to make authenticated requests to AT Protocol services after a successful OAuth flow.
Fields§
§did: StringThe Decentralized Identifier (DID) of the authenticated user.
handle: StringThe handle (username) of the authenticated user.
access_token: StringThe OAuth access token for making authenticated requests.
token_type: StringThe type of token (typically “Bearer”).
scopes: Vec<String>The list of OAuth scopes granted to this session.
pds_endpoint: StringThe Personal Data Server (PDS) endpoint URL for this user.
dpop_key: Option<String>The DPoP (Demonstration of Proof-of-Possession) key in string serialized format.
dpop_jwk: Option<WrappedJsonWebKey>The DPoP (Demonstration of Proof-of-Possession) key in JWK format.
expires_at: i64Unix timestamp indicating when this session expires.
Trait Implementations§
Source§impl Clone for ATProtocolSession
impl Clone for ATProtocolSession
Source§fn clone(&self) -> ATProtocolSession
fn clone(&self) -> ATProtocolSession
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<'de> Deserialize<'de> for ATProtocolSession
impl<'de> Deserialize<'de> for ATProtocolSession
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 ATProtocolSession
impl RefUnwindSafe for ATProtocolSession
impl Send for ATProtocolSession
impl Sync for ATProtocolSession
impl Unpin for ATProtocolSession
impl UnwindSafe for ATProtocolSession
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