Skip to content

Commit

Permalink
fix: readme
Browse files Browse the repository at this point in the history
  • Loading branch information
badmintoncryer committed Mar 25, 2024
1 parent 7df97c6 commit 816d08c
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions packages/aws-cdk-lib/aws-cognito/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -604,19 +604,21 @@ Using SAML identity provider is possible to use SAML metadata file content or SA
const userpool = new cognito.UserPool(this, 'Pool');

// specify the metadata as a file content
new cognito.UserPoolIdentityProviderSaml(stack, 'userpoolIdpFile', {
userPool: pool,
metadata: UserPoolIdentityProviderSamlMetadata.file('my-file-contents'),
new cognito.UserPoolIdentityProviderSaml(this, 'userpoolIdpFile', {
userPool: userpool,
metadata: cognito.UserPoolIdentityProviderSamlMetadata.file('my-file-contents'),
// Whether to require encrypted SAML assertions from IdP
encryptedResponses: true,
// The signing algorithm for the SAML requests
requestSigningAlgorithm: cognito.SigningAlgorithm.RSA_SHA256,
// Enable IdP initiated SAML auth flow
idpInitiated: true,
});

// specify the metadata as a URL
new cognito.UserPoolIdentityProviderSaml(stack, 'userpoolidpUrl', {
userPool: pool,
metadata: UserPoolIdentityProviderSamlMetadata.url('https://my-metadata-url.com'),
new cognito.UserPoolIdentityProviderSaml(this, 'userpoolidpUrl', {
userPool: userpool,
metadata: cognito.UserPoolIdentityProviderSamlMetadata.url('https://my-metadata-url.com'),
});
```

Expand Down

0 comments on commit 816d08c

Please sign in to comment.