class GeneralPIIType
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.Bedrock.Alpha.GeneralPIIType |
![]() | github.com/aws/aws-cdk-go/awsbedrockalpha/v2#GeneralPIIType |
![]() | software.amazon.awscdk.services.bedrock.alpha.GeneralPIIType |
![]() | aws_cdk.aws_bedrock_alpha.GeneralPIIType |
![]() | @aws-cdk/aws-bedrock-alpha ยป GeneralPIIType |
Extends
PIIType
Types of PII that are general, and not domain-specific.
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 ADDRESS | General | A physical address, such as "100 Main Street, Anytown, USA" or "Suite #12, Building 123". |
static AGE | General | An individual's age, including the quantity and unit of time. |
static DRIVER_ID | General | The number assigned to a driver's license, which is an official document permitting an individual to operate one or more motorized vehicles on a public road. |
static EMAIL | General | An email address, such as marymajor@email.com. |
static LICENSE_PLATE | General | A license plate for a vehicle is issued by the state or country where the vehicle is registered. |
static NAME | General | An individual's name. |
static PASSWORD | General | An alphanumeric string that is used as a password, such as "very20special#pass". |
static PHONE | General | A phone number. |
static USERNAME | General | A user name that identifies an account, such as a login name, screen name, nick name, or handle. |
static VEHICLE_IDENTIFICATION_NUMBER | General | A Vehicle Identification Number (VIN) uniquely identifies a vehicle. |
value
Type:
string
The string value of the PII type.
static ADDRESS
Type:
General
A physical address, such as "100 Main Street, Anytown, USA" or "Suite #12, Building 123".
An address can include information such as the street, building, location, city, state, country, county, zip code, precinct, and neighborhood.
static AGE
Type:
General
An individual's age, including the quantity and unit of time.
static DRIVER_ID
Type:
General
The number assigned to a driver's license, which is an official document permitting an individual to operate one or more motorized vehicles on a public road.
A driver's license number consists of alphanumeric characters.
static EMAIL
Type:
General
An email address, such as marymajor@email.com.
static LICENSE_PLATE
Type:
General
A license plate for a vehicle is issued by the state or country where the vehicle is registered.
The format for passenger vehicles is typically five to eight digits, consisting of upper-case letters and numbers. The format varies depending on the location of the issuing state or country.
static NAME
Type:
General
An individual's name.
This entity type does not include titles, such as Dr., Mr., Mrs., or Miss.
static PASSWORD
Type:
General
An alphanumeric string that is used as a password, such as "very20special#pass".
static PHONE
Type:
General
A phone number.
This entity type also includes fax and pager numbers.
static USERNAME
Type:
General
A user name that identifies an account, such as a login name, screen name, nick name, or handle.
static VEHICLE_IDENTIFICATION_NUMBER
Type:
General
A Vehicle Identification Number (VIN) uniquely identifies a vehicle.
VIN content and format are defined in the ISO 3779 specification. Each country has specific codes and formats for VINs.
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.