public static final class UserPoolClientProps.Builder
extends java.lang.Object
UserPoolClientProps
Constructor and Description |
---|
Builder() |
public UserPoolClientProps.Builder userPool(IUserPool userPool)
UserPoolClientProps.getUserPool()
userPool
- The UserPool resource this client will have access to. This parameter is required.this
public UserPoolClientProps.Builder accessTokenValidity(Duration accessTokenValidity)
UserPoolClientOptions.getAccessTokenValidity()
accessTokenValidity
- Validity of the access token.
Values between 5 minutes and 1 day are valid. The duration can not be longer than the refresh token validity.this
public UserPoolClientProps.Builder authFlows(AuthFlow authFlows)
UserPoolClientOptions.getAuthFlows()
authFlows
- The set of OAuth authentication flows to enable on the client.this
public UserPoolClientProps.Builder disableOAuth(java.lang.Boolean disableOAuth)
UserPoolClientOptions.getDisableOAuth()
disableOAuth
- Turns off all OAuth interactions for this client.this
public UserPoolClientProps.Builder enableTokenRevocation(java.lang.Boolean enableTokenRevocation)
UserPoolClientOptions.getEnableTokenRevocation()
enableTokenRevocation
- Enable token revocation for this client.this
public UserPoolClientProps.Builder generateSecret(java.lang.Boolean generateSecret)
UserPoolClientOptions.getGenerateSecret()
generateSecret
- Whether to generate a client secret.this
public UserPoolClientProps.Builder idTokenValidity(Duration idTokenValidity)
UserPoolClientOptions.getIdTokenValidity()
idTokenValidity
- Validity of the ID token.
Values between 5 minutes and 1 day are valid. The duration can not be longer than the refresh token validity.this
public UserPoolClientProps.Builder oAuth(OAuthSettings oAuth)
UserPoolClientOptions.getOAuth()
oAuth
- OAuth settings for this client to interact with the app.
An error is thrown when this is specified and disableOAuth
is set.this
public UserPoolClientProps.Builder preventUserExistenceErrors(java.lang.Boolean preventUserExistenceErrors)
UserPoolClientOptions.getPreventUserExistenceErrors()
preventUserExistenceErrors
- Whether Cognito returns a UserNotFoundException exception when the user does not exist in the user pool (false), or whether it returns another type of error that doesn't reveal the user's absence.this
public UserPoolClientProps.Builder readAttributes(ClientAttributes readAttributes)
UserPoolClientOptions.getReadAttributes()
readAttributes
- The set of attributes this client will be able to read.this
public UserPoolClientProps.Builder refreshTokenValidity(Duration refreshTokenValidity)
UserPoolClientOptions.getRefreshTokenValidity()
refreshTokenValidity
- Validity of the refresh token.
Values between 60 minutes and 10 years are valid.this
public UserPoolClientProps.Builder supportedIdentityProviders(java.util.List<? extends UserPoolClientIdentityProvider> supportedIdentityProviders)
UserPoolClientOptions.getSupportedIdentityProviders()
supportedIdentityProviders
- The list of identity providers that users should be able to use to sign in using this client.this
public UserPoolClientProps.Builder userPoolClientName(java.lang.String userPoolClientName)
UserPoolClientOptions.getUserPoolClientName()
userPoolClientName
- Name of the application client.this
public UserPoolClientProps.Builder writeAttributes(ClientAttributes writeAttributes)
UserPoolClientOptions.getWriteAttributes()
writeAttributes
- The set of attributes this client will be able to write.this
public UserPoolClientProps build()
UserPoolClientProps
java.lang.NullPointerException
- if any required attribute was not provided