pub struct CliGrantResponse {
pub code: String,
pub expires_in: i64,
}Expand description
Response body for POST /api/v1/auth/cli/request-grant.
Carries the human-typeable grant code that the user pastes into
the pathbase CLI, plus its lifetime. Display the code prominently
in the UI; do not store it in the URL or log files.
JSON schema
{
"description": "Response body for `POST /api/v1/auth/cli/request-grant`.\n\nCarries the human-typeable grant `code` that the user pastes into\nthe pathbase CLI, plus its lifetime. Display the code prominently\nin the UI; do not store it in the URL or log files.",
"type": "object",
"required": [
"code",
"expires_in"
],
"properties": {
"code": {
"description": "Short, visually unambiguous alphanumeric code. Single-use;\nconsumed by the next call to `/api/v1/auth/cli/redeem`.\nComparison is case-insensitive on redeem.",
"type": "string"
},
"expires_in": {
"description": "Lifetime of the grant in seconds, set by the server.",
"type": "integer",
"format": "int64"
}
}
}Fields§
§code: StringShort, visually unambiguous alphanumeric code. Single-use;
consumed by the next call to /api/v1/auth/cli/redeem.
Comparison is case-insensitive on redeem.
expires_in: i64Lifetime of the grant in seconds, set by the server.
Trait Implementations§
Source§impl Clone for CliGrantResponse
impl Clone for CliGrantResponse
Source§fn clone(&self) -> CliGrantResponse
fn clone(&self) -> CliGrantResponse
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 CliGrantResponse
impl Debug for CliGrantResponse
Source§impl<'de> Deserialize<'de> for CliGrantResponse
impl<'de> Deserialize<'de> for CliGrantResponse
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 CliGrantResponse
impl RefUnwindSafe for CliGrantResponse
impl Send for CliGrantResponse
impl Sync for CliGrantResponse
impl Unpin for CliGrantResponse
impl UnsafeUnpin for CliGrantResponse
impl UnwindSafe for CliGrantResponse
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