1 Respuesta
- Más nuevo
- Más votos
- Más comentarios
0
In order to define the Cognito UserPool client, you can refer to the addClient function of the UserPool construct in CDK and then define the refreshTokenValidity duration to correctly synthesize the construct to the corresponding CloudFormation resource
const pool = new cognito.UserPool(this, 'Pool');
const provider = new cognito.UserPoolIdentityProviderAmazon(this, 'Amazon', {
userPool: pool,
clientId: 'amzn-client-id',
clientSecret: 'amzn-client-secret',
});
const client = pool.addClient('app-client', {
refreshTokenValidity: cdk.Duration.hours(12),
idTokenValidity: cdk.Duration.hours(2),
accessTokenValidity:cdk.Duration.hours(2),
supportedIdentityProviders: [
cognito.UserPoolClientIdentityProvider.AMAZON,
],
});
client.node.addDependency(provider);
respondido hace 5 horas
Contenido relevante
- OFICIAL DE AWSActualizada hace 3 años
- ¿Cómo puedo hacer una llamada al SDK de AWS desde un proyecto de CDK mediante la interfaz AWSdkCall?OFICIAL DE AWSActualizada hace un año
- OFICIAL DE AWSActualizada hace un año
- OFICIAL DE AWSActualizada hace un año
You might want to post this as a bug on the github repository, as that is the best place for it if this is really a bug. Link here: https://github.com/aws/aws-cdk