interface TokenValidityUnitsProperty
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.Cognito.CfnUserPoolClient.TokenValidityUnitsProperty |
Java | software.amazon.awscdk.services.cognito.CfnUserPoolClient.TokenValidityUnitsProperty |
Python | aws_cdk.aws_cognito.CfnUserPoolClient.TokenValidityUnitsProperty |
TypeScript | @aws-cdk/aws-cognito » CfnUserPoolClient » TokenValidityUnitsProperty |
The time units you use when you set the duration of ID, access, and refresh tokens.
The default unit for RefreshToken is days, and the default for ID and access tokens is hours.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as cognito from '@aws-cdk/aws-cognito';
const tokenValidityUnitsProperty: cognito.CfnUserPoolClient.TokenValidityUnitsProperty = {
accessToken: 'accessToken',
idToken: 'idToken',
refreshToken: 'refreshToken',
};
Properties
| Name | Type | Description |
|---|---|---|
| access | string | A time unit of seconds , minutes , hours , or days for the value that you set in the AccessTokenValidity parameter. |
| id | string | A time unit of seconds , minutes , hours , or days for the value that you set in the IdTokenValidity parameter. |
| refresh | string | A time unit of seconds , minutes , hours , or days for the value that you set in the RefreshTokenValidity parameter. |
accessToken?
Type:
string
(optional)
A time unit of seconds , minutes , hours , or days 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.
idToken?
Type:
string
(optional)
A time unit of seconds , minutes , hours , or days 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.
refreshToken?
Type:
string
(optional)
A time unit of seconds , minutes , hours , or days 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.

.NET
Java
Python
TypeScript