Create policies that apply to every customer you provision.
Default policies are set by you (the partner) and apply to all customers you provision. Customers can also create their own policies on top of your defaults. Your defaults always run first.
await client.defaults.createPolicy({
action: 'block',
rules: {
match: {
pattern: ['\\b\\d{3}-\\d{2}-\\d{4}\\b'],
},
},
priority: 5,
description: 'Block SSNs for all customers',
});// List all default policies
const policies = await client.defaults.listPolicies();
// Update a default policy
await client.defaults.updatePolicy(policyId, {
priority: 3,
});
// Delete a default policy
await client.defaults.deletePolicy(policyId);