Skip to content
v2.278.0

IdentityPoolAuthenticationProviders Struct ​

External Authentication Providers for usage in Identity Pool.

Example ​

ts
declare const openIdConnectProvider: iam.OpenIdConnectProvider;
new IdentityPool(this, 'myidentitypool', {
  identityPoolName: 'myidentitypool',
  authenticationProviders: {
    google: {
      clientId: '12345678012.apps.googleusercontent.com',
    },
    openIdConnectProviders: [openIdConnectProvider],
    customProvider: 'my-custom-provider.example.com',
  },
});
python
from aws_cdk.aws_cognito_identitypool import IdentityPoolAuthenticationProviders, IdentityPoolGoogleLoginProvider
# open_id_connect_provider: iam.OpenIdConnectProvider

IdentityPool(self, "myidentitypool",
    identity_pool_name="myidentitypool",
    authentication_providers=IdentityPoolAuthenticationProviders(
        google=IdentityPoolGoogleLoginProvider(
            client_id="12345678012.apps.googleusercontent.com"
        ),
        open_id_connect_providers=[open_id_connect_provider],
        custom_provider="my-custom-provider.example.com"
    )
)
java
OpenIdConnectProvider openIdConnectProvider;

IdentityPool.Builder.create(this, "myidentitypool")
        .identityPoolName("myidentitypool")
        .authenticationProviders(IdentityPoolAuthenticationProviders.builder()
                .google(IdentityPoolGoogleLoginProvider.builder()
                        .clientId("12345678012.apps.googleusercontent.com")
                        .build())
                .openIdConnectProviders(List.of(openIdConnectProvider))
                .customProvider("my-custom-provider.example.com")
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
OpenIdConnectProvider openIdConnectProvider;

new IdentityPool(this, "myidentitypool", new IdentityPoolProps {
    IdentityPoolName = "myidentitypool",
    AuthenticationProviders = new IdentityPoolAuthenticationProviders {
        Google = new IdentityPoolGoogleLoginProvider {
            ClientId = "12345678012.apps.googleusercontent.com"
        },
        OpenIdConnectProviders = new [] { openIdConnectProvider },
        CustomProvider = "my-custom-provider.example.com"
    }
});
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
var openIdConnectProvider OpenIdConnectProvider

awscdk.NewIdentityPool(this, jsii.String("myidentitypool"), &IdentityPoolProps{
	IdentityPoolName: jsii.String("myidentitypool"),
	AuthenticationProviders: &IdentityPoolAuthenticationProviders{
		Google: &IdentityPoolGoogleLoginProvider{
			ClientId: jsii.String("12345678012.apps.googleusercontent.com"),
		},
		OpenIdConnectProviders: []IOIDCProviderRef{
			openIdConnectProvider,
		},
		CustomProvider: jsii.String("my-custom-provider.example.com"),
	},
})

Properties ​

The Amazon Authentication Provider associated with this Identity Pool.

Default: No Amazon Authentication Provider used without OpenIdConnect or a User Pool

The Apple Authentication Provider associated with this Identity Pool.

Default: No Apple Authentication Provider used without OpenIdConnect or a User Pool

customProvideroptionalstringcustom_provideroptionalstrcustomProvideroptionalStringCustomProvideroptionalstringCustomProvideroptional*string #
The developer provider name to associate with this Identity Pool.

Default: no custom provider

The Facebook Authentication Provider associated with this Identity Pool.

Default: No Facebook Authentication Provider used without OpenIdConnect or a User Pool

The Google Authentication Provider associated with this Identity Pool.

Default: No Google Authentication Provider used without OpenIdConnect or a User Pool

openIdConnectProvidersoptionalIOIDCProviderRef[]open_id_connect_providersoptionaltyping.List[IOIDCProviderRef]openIdConnectProvidersoptionalList<IOIDCProviderRef>OpenIdConnectProvidersoptionalIOIDCProviderRef[]OpenIdConnectProvidersoptional*[]IOIDCProviderRef #
The OpenIdConnect Provider associated with this Identity Pool.

Default: no OpenIdConnectProvider

samlProvidersoptionalISAMLProviderRef[]saml_providersoptionaltyping.List[ISAMLProviderRef]samlProvidersoptionalList<ISAMLProviderRef>SamlProvidersoptionalISAMLProviderRef[]SamlProvidersoptional*[]ISAMLProviderRef #
The Security Assertion Markup Language provider associated with this Identity Pool.

Default: no SamlProvider

The Twitter Authentication Provider associated with this Identity Pool.

Default: No Twitter Authentication Provider used without OpenIdConnect or a User Pool

userPoolsoptionalIUserPoolAuthenticationProvider[]user_poolsoptionaltyping.List[IUserPoolAuthenticationProvider]userPoolsoptionalList<IUserPoolAuthenticationProvider>UserPoolsoptionalIUserPoolAuthenticationProvider[]UserPoolsoptional*[]IUserPoolAuthenticationProvider #
The User Pool Authentication Providers associated with this Identity Pool.

Default: no User Pools associated