Skip to main content

tapis_authenticator/models/
token_response_access_token.rs

1/*
2 * Authenticator
3 *
4 * REST API and web server providing authentication for a Tapis v3 instance.
5 *
6 * The version of the OpenAPI document: 1
7 * Contact: cicsupport@tacc.utexas.edu
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// TokenResponseAccessToken : A Tapis access token object.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct TokenResponseAccessToken {
17    /// The actual access token as a JWT
18    #[serde(rename = "access_token", skip_serializing_if = "Option::is_none")]
19    pub access_token: Option<String>,
20    /// The actual access token as a JWT
21    #[serde(rename = "id_token", skip_serializing_if = "Option::is_none")]
22    pub id_token: Option<String>,
23    /// The time, as a string in UTC, when the token expires.
24    #[serde(rename = "expires_at", skip_serializing_if = "Option::is_none")]
25    pub expires_at: Option<String>,
26    /// The amount of time, in seconds, when the token will expire.
27    #[serde(rename = "expires_in", skip_serializing_if = "Option::is_none")]
28    pub expires_in: Option<i32>,
29    /// Unique identifier for the token
30    #[serde(rename = "jti", skip_serializing_if = "Option::is_none")]
31    pub jti: Option<String>,
32}
33
34impl TokenResponseAccessToken {
35    /// A Tapis access token object.
36    pub fn new() -> TokenResponseAccessToken {
37        TokenResponseAccessToken {
38            access_token: None,
39            id_token: None,
40            expires_at: None,
41            expires_in: None,
42            jti: None,
43        }
44    }
45}