UserPoolIdentityProviderOidcProps Struct
Properties to initialize UserPoolIdentityProviderOidc.
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_cognito as cognito } from 'aws-cdk-lib';
declare const providerAttribute: cognito.ProviderAttribute;
declare const userPool: cognito.UserPool;
const userPoolIdentityProviderOidcProps: cognito.UserPoolIdentityProviderOidcProps = {
clientId: 'clientId',
clientSecret: 'clientSecret',
issuerUrl: 'issuerUrl',
userPool: userPool,
// the properties below are optional
attributeMapping: {
address: providerAttribute,
birthdate: providerAttribute,
custom: {
customKey: providerAttribute,
},
email: providerAttribute,
emailVerified: providerAttribute,
familyName: providerAttribute,
fullname: providerAttribute,
gender: providerAttribute,
givenName: providerAttribute,
lastUpdateTime: providerAttribute,
locale: providerAttribute,
middleName: providerAttribute,
nickname: providerAttribute,
phoneNumber: providerAttribute,
preferredUsername: providerAttribute,
profilePage: providerAttribute,
profilePicture: providerAttribute,
timezone: providerAttribute,
website: providerAttribute,
},
attributeRequestMethod: cognito.OidcAttributeRequestMethod.GET,
endpoints: {
authorization: 'authorization',
jwksUri: 'jwksUri',
token: 'token',
userInfo: 'userInfo',
},
identifiers: ['identifiers'],
name: 'name',
scopes: ['scopes'],
};
Properties
attributeMappingAttributeMappingattribute_mappingAttributeMappingattributeMappingAttributeMappingAttributeMappingAttributeMappingAttributeMappingAttributeMapping#Mapping attributes from the identity provider to standard and custom attributes of the user pool.
Default: no attribute mapping
attributeRequestMethodOidcAttributeRequestMethodattribute_request_methodOidcAttributeRequestMethodattributeRequestMethodOidcAttributeRequestMethodAttributeRequestMethodOidcAttributeRequestMethodAttributeRequestMethodOidcAttributeRequestMethod= OidcAttributeRequestMethod.GET#The method to use to request attributes.
The client id.
The client secret.
endpointsOidcEndpointsendpointsOidcEndpointsendpointsOidcEndpointsEndpointsOidcEndpointsEndpointsOidcEndpoints#OpenID connect endpoints.
Default: auto discovered with issuer URL
identifiersstring[]identifierstyping.List[str]identifiersList<String>Identifiersstring[]Identifiers*[]*string#Identifiers.
Default: no identifiers used
Identifiers can be used to redirect users to the correct IdP in multitenant apps.
Issuer URL.
The name of the provider.
Default: the unique ID of the construct
The OAuth 2.0 scopes that you will request from OpenID Connect. Scopes are groups of OpenID Connect user attributes to exchange with your app.