UserPoolIdentityProviderSamlMetadata Class
Metadata for a SAML user pool identity provider.
Example
ts
const userpool = new cognito.UserPool(this, 'Pool');
// specify the metadata as a file content
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(this, 'userpoolidpUrl', {
userPool: userpool,
metadata: cognito.UserPoolIdentityProviderSamlMetadata.url('https://my-metadata-url.com'),
});
Properties
metadataContentstringmetadata_contentstrmetadataContentStringMetadataContentstringMetadataContent*stringrequired#A URL hosting SAML metadata, or the content of a file containing SAML metadata.
metadataTypeUserPoolIdentityProviderSamlMetadataTypemetadata_typeUserPoolIdentityProviderSamlMetadataTypemetadataTypeUserPoolIdentityProviderSamlMetadataTypeMetadataTypeUserPoolIdentityProviderSamlMetadataTypeMetadataTypeUserPoolIdentityProviderSamlMetadataTyperequired#The type of metadata, either a URL or file content.
Methods
file(fileContent: string): UserPoolIdentityProviderSamlMetadata // chainable@staticmethod def file(file_content: str) -> UserPoolIdentityProviderSamlMetadatapublic static UserPoolIdentityProviderSamlMetadata file(String fileContent)public static UserPoolIdentityProviderSamlMetadata File(string fileContent)func File(FileContent *string) UserPoolIdentityProviderSamlMetadatastatic#Specify SAML metadata via the contents of a file.
url(url: string): UserPoolIdentityProviderSamlMetadata // chainable@staticmethod def url(url: str) -> UserPoolIdentityProviderSamlMetadatapublic static UserPoolIdentityProviderSamlMetadata url(String url)public static UserPoolIdentityProviderSamlMetadata Url(string url)func Url(Url *string) UserPoolIdentityProviderSamlMetadatastatic#Specify SAML metadata via a URL.