class USASpecificPIIType
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.Bedrock.Alpha.USASpecificPIIType |
![]() | github.com/aws/aws-cdk-go/awsbedrockalpha/v2#USASpecificPIIType |
![]() | software.amazon.awscdk.services.bedrock.alpha.USASpecificPIIType |
![]() | aws_cdk.aws_bedrock_alpha.USASpecificPIIType |
![]() | @aws-cdk/aws-bedrock-alpha ยป USASpecificPIIType |
Extends
PIIType
Types of PII specific to the USA.
Example
const guardrail = new bedrock.Guardrail(this, 'bedrockGuardrails', {
guardrailName: 'my-BedrockGuardrails',
});
// Add PII filter for addresses with input/output actions
guardrail.addPIIFilter({
type: bedrock.GeneralPIIType.ADDRESS,
action: bedrock.GuardrailAction.BLOCK,
// below props are optional
inputAction: bedrock.GuardrailAction.BLOCK,
inputEnabled: true,
outputAction: bedrock.GuardrailAction.ANONYMIZE,
outputEnabled: true,
});
// Add PII filter for credit card numbers with input/output actions
guardrail.addPIIFilter({
type: bedrock.FinancePIIType.CREDIT_DEBIT_CARD_NUMBER,
action: bedrock.GuardrailAction.BLOCK,
// below props are optional
inputAction: bedrock.GuardrailAction.BLOCK,
inputEnabled: true,
outputAction: bedrock.GuardrailAction.ANONYMIZE,
outputEnabled: true,
});
// Add PII filter for email addresses
guardrail.addPIIFilter({
type: bedrock.GeneralPIIType.EMAIL,
action: bedrock.GuardrailAction.ANONYMIZE,
});
// Add PII filter for US Social Security Numbers
guardrail.addPIIFilter({
type: bedrock.USASpecificPIIType.US_SOCIAL_SECURITY_NUMBER,
action: bedrock.GuardrailAction.BLOCK,
});
// Add PII filter for IP addresses
guardrail.addPIIFilter({
type: bedrock.InformationTechnologyPIIType.IP_ADDRESS,
action: bedrock.GuardrailAction.ANONYMIZE,
});
Properties
Name | Type | Description |
---|---|---|
value | string | The string value of the PII type. |
static US_BANK_ACCOUNT_NUMBER | USASpecific | A US bank account number, which is typically 10 to 12 digits long. |
static US_BANK_ROUTING_NUMBER | USASpecific | A US bank account routing number. |
static US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER | USASpecific | A US Individual Taxpayer Identification Number (ITIN) is a nine-digit number that starts with a "9" and contain a "7" or "8" as the fourth digit. |
static US_PASSPORT_NUMBER | USASpecific | A US passport number. |
static US_SOCIAL_SECURITY_NUMBER | USASpecific | A US Social Security Number (SSN) is a nine-digit number that is issued to US citizens, permanent residents, and temporary working residents. |
value
Type:
string
The string value of the PII type.
static US_BANK_ACCOUNT_NUMBER
Type:
USASpecific
A US bank account number, which is typically 10 to 12 digits long.
static US_BANK_ROUTING_NUMBER
Type:
USASpecific
A US bank account routing number.
These are typically nine digits long.
static US_INDIVIDUAL_TAX_IDENTIFICATION_NUMBER
Type:
USASpecific
A US Individual Taxpayer Identification Number (ITIN) is a nine-digit number that starts with a "9" and contain a "7" or "8" as the fourth digit.
static US_PASSPORT_NUMBER
Type:
USASpecific
A US passport number.
Passport numbers range from six to nine alphanumeric characters.
static US_SOCIAL_SECURITY_NUMBER
Type:
USASpecific
A US Social Security Number (SSN) is a nine-digit number that is issued to US citizens, permanent residents, and temporary working residents.
Methods
Name | Description |
---|---|
to | Returns the string representation of the PII type. |
toString()
public toString(): string
Returns
string
Returns the string representation of the PII type.