Class: AWSCDK::Cognito::CfnUserPoolClient::TokenValidityUnitsProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Cognito::CfnUserPoolClient::TokenValidityUnitsProperty
- Defined in:
- cognito/cfn_user_pool_client.rb
Overview
The units that validity times are represented in.
The default unit for refresh tokens is days, and the default for ID and access tokens are hours.
Instance Attribute Summary collapse
-
#access_token ⇒ String?
readonly
A time unit for the value that you set in the
AccessTokenValidityparameter. -
#id_token ⇒ String?
readonly
A time unit for the value that you set in the
IdTokenValidityparameter. -
#refresh_token ⇒ String?
readonly
A time unit for the value that you set in the
RefreshTokenValidityparameter.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(access_token: nil, id_token: nil, refresh_token: nil) ⇒ TokenValidityUnitsProperty
constructor
A new instance of TokenValidityUnitsProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(access_token: nil, id_token: nil, refresh_token: nil) ⇒ TokenValidityUnitsProperty
Returns a new instance of TokenValidityUnitsProperty.
933 934 935 936 937 938 939 940 |
# File 'cognito/cfn_user_pool_client.rb', line 933 def initialize(access_token: nil, id_token: nil, refresh_token: nil) @access_token = access_token Jsii::Type.check_type(@access_token, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "accessToken") unless @access_token.nil? @id_token = id_token Jsii::Type.check_type(@id_token, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "idToken") unless @id_token.nil? @refresh_token = refresh_token Jsii::Type.check_type(@refresh_token, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "refreshToken") unless @refresh_token.nil? end |
Instance Attribute Details
#access_token ⇒ String? (readonly)
A time unit for the value that you set in the AccessTokenValidity parameter.
The default AccessTokenValidity time unit is hours . AccessTokenValidity duration can range from five minutes to one day.
948 949 950 |
# File 'cognito/cfn_user_pool_client.rb', line 948 def access_token @access_token end |
#id_token ⇒ String? (readonly)
A time unit for the value that you set in the IdTokenValidity parameter.
The default IdTokenValidity time unit is hours . IdTokenValidity duration can range from five minutes to one day.
955 956 957 |
# File 'cognito/cfn_user_pool_client.rb', line 955 def id_token @id_token end |
#refresh_token ⇒ String? (readonly)
A time unit for the value that you set in the RefreshTokenValidity parameter.
The default RefreshTokenValidity time unit is days . RefreshTokenValidity duration can range from 60 minutes to 10 years.
962 963 964 |
# File 'cognito/cfn_user_pool_client.rb', line 962 def refresh_token @refresh_token end |
Class Method Details
.jsii_properties ⇒ Object
964 965 966 967 968 969 970 |
# File 'cognito/cfn_user_pool_client.rb', line 964 def self.jsii_properties { :access_token => "accessToken", :id_token => "idToken", :refresh_token => "refreshToken", } end |
Instance Method Details
#to_jsii ⇒ Object
972 973 974 975 976 977 978 979 980 |
# File 'cognito/cfn_user_pool_client.rb', line 972 def to_jsii result = {} result.merge!({ "accessToken" => @access_token, "idToken" => @id_token, "refreshToken" => @refresh_token, }) result.compact end |