List AI DLP Presets
Endpoint
GET /apiops/settings/ai-dlp-presets/
Authentication
Requires a Personal API Access Token with admin privileges.
Header
Authorization: Bearer YOUR_TOKEN
Request
Headers
| Header | Value | Required |
|---|---|---|
| Authorization | Bearer {token} | Yes |
Path Parameters
None.
Query Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| projectId | string | No | admin | Scope project id. Omit for the admin/global scope, where built-in and admin-owned presets live. |
Response
Success Response (200 OK)
{
"status": "SUCCESS",
"resultList": [
{
"id": "665f2a1c9b3e4a0012ab5501",
"projectId": "admin",
"name": "BUILTIN_DLP_AWS_ACCESS_KEY",
"ruleValue": "\\bAKIA[0-9A-Z]{16}\\b",
"action": "BLOCK",
"category": "aws",
"description": "AWS access key id (AKIA...)",
"enabled": true,
"builtIn": true
},
{
"id": "665f2a1c9b3e4a0012ab5507",
"projectId": "admin",
"name": "BUILTIN_DLP_JWT",
"ruleValue": "\\beyJ[A-Za-z0-9_-]+\\.[A-Za-z0-9_-]+\\.[A-Za-z0-9_-]+\\b",
"action": "MASK",
"category": "jwt",
"description": "JSON Web Token (eyJ...header.payload.signature)",
"enabled": true,
"builtIn": true
},
{
"id": "665f2a1c9b3e4a0012ab99aa",
"projectId": "admin",
"name": "internal-api-token",
"ruleValue": "ITK-[0-9]{10}",
"action": "MASK",
"category": "internal",
"description": "Internal service API token",
"enabled": true,
"builtIn": false
}
],
"resultCount": 3
}
Response Fields
| Field | Type | Description |
|---|---|---|
| status | string | Response status: SUCCESS or FAILURE |
| resultList | array | List of DLP preset objects |
| resultCount | integer | Total number of presets returned |
DLP Preset Object Fields
| Field | Type | Description |
|---|---|---|
| id | string | Server-assigned identifier (read-only) |
| projectId | string | Scope the preset belongs to (admin for global) |
| name | string | Unique preset name (e.g. BUILTIN_DLP_AWS_ACCESS_KEY for seeded rows, free-form for custom) |
| ruleValue | string | Java regex pattern used to detect the secret/credential |
| action | string | Action applied on match: BLOCK, FLAG, or MASK. DLP is the only preset family where all three are valid — MASK redacts the matched region instead of blocking or just logging |
| category | string | Optional category label (e.g. aws, openai, github, pem, slack, google, jwt, generic) |
| description | string | Optional description for UI display |
| enabled | boolean | Whether the preset is active |
| builtIn | boolean | true for Mongock-seeded rows (read-only), false for user-created |
EnumStatus
SUCCESS- Operation successfulFAILURE- Operation failed
Error Response (400 Bad Request)
Returned when the caller is authenticated but lacks the ADMIN role.
{
"status": "FAILURE",
"resultMessage": "Unauthorized! Only users with ADMIN role can manage AI presets!"
}
Error Response (401 Unauthorized)
{
"status": "FAILURE",
"resultMessage": "Token is not valid!"
}
cURL Example
Default (admin/global scope)
curl -X GET \
"https://demo.apinizer.com/apiops/settings/ai-dlp-presets/" \
-H "Authorization: Bearer YOUR_TOKEN"
Scoped to a project
curl -X GET \
"https://demo.apinizer.com/apiops/settings/ai-dlp-presets/?projectId=MyProject" \
-H "Authorization: Bearer YOUR_TOKEN"
Notes and Warnings
- Admin Only:
- Only sysAdmin users (or users with the
ADMINrole) can list AI DLP presets - A project-scoped
AI_DEVELOPMENTtoken is not sufficient
- Only sysAdmin users (or users with the
- Built-in Presets:
- Rows with
builtIn: truecome from the seeded secret/credential catalog (8 patterns: AWS access key, OpenAI key, GitHub token, PEM private key, Slack token and Google API key — allBLOCK; JWT and a genericpassword/secret/api_keyassignment — bothMASK) and are read-only
- Rows with
- Scope:
- The default scope is admin/global; pass
projectIdto list presets for a specific project
- The default scope is admin/global; pass
- No Secret Fields:
ruleValueis a detection regex pattern, not a credential itself — DLP presets carry no secret (@SecretData) fields, so no values are masked
Related Documentation
- Get AI DLP Preset - Get a single preset by name
- Create AI DLP Preset - Create or update a preset
- AI DLP Presets API - Resource overview