---
title: "Updates an existing AI privacy preset"
method: PUT
path: "/apiops/settings/ai-privacy-presets/{presetName}/"
tags: ["AiTopicCategoryPreset", "AiPromptGuardPreset", "AiPromptTemplate", "AiPromptDecoratorPreset", "AiPrivacyPreset", "AiDlpPreset"]
---

# Updates an existing AI privacy preset

`PUT /apiops/settings/ai-privacy-presets/{presetName}/`

## Request

- Base URL: `http://167.86.118.166:32080`
- URL: `http://167.86.118.166:32080/apiops/settings/ai-privacy-presets/{presetName}/`
- Auth: none declared
- TypeScript: <https://skmtc.dev/apinizer/apis/apinizer-management-apis/docs/apiops/settings/ai-privacy-presets/:presetName/put.ts> (a function with typed inputs; its response is checked against the schema)

Updates a custom AI privacy preset. Built-in presets are read-only and reject this call.

## Path parameters

- `presetName` string, required

## Query parameters

- `projectId` string

## Request body

- AiPrivacyPresetDTO
  - `id` string
  - `projectId` string
  - `name` string
  - `elementName` string
  - `patternType` 'ELEMENT_NAME' | 'REGEX' | 'BUILTIN'
  - `regexPattern` string
  - `operation` 'MASK' | 'DELETE' | 'ENCRYPT' | 'HASH' | 'DETECT'
  - `maskMode` 'FIXED' | 'KEEP_FIRST' | 'KEEP_LAST' | 'MASK_FIRST' | 'PLACEHOLDER_SEQUENCE' | 'SYNTHETIC'
  - `maskPattern` string
  - `maskVisibleCharCount` integer
  - `enabled` boolean
  - `builtIn` boolean

## Response `200`

successful operation!

- ApiOpsResponseSuccess
  - `status` 'SUCCESS' | 'FAILURE'
  - `resultMessage` string
  - `resultList` string[]
  - `resultCount` integer
  - `deploymentResult` DeploymentResult
    - `envName` string
    - `podName` string
    - `podIp` string
    - `success` boolean
    - `detail` string
    - `responseTime` integer
    - `detailList` unknown[]
      - unknown
    - `firstFromApiResultList` unknown
  - `unresolvedReferences` string[]
  - `advisories` ApiOpsAdvisoryDTO[]
    - `level` string
    - `key` string
    - `params` object

## Other responses

- `401`: not authorized for this operation!
- `500`: internal error!

## Changes

- **2026-10-20** `d1a546deccf0`: 7 breaking
  - request property `maskMode` was restricted to a list of enum values
  - request property `operation` was restricted to a list of enum values
  - request property `patternType` was restricted to a list of enum values
  - the `maskMode` request property type changed from `object` to `string`
  - …3 more
  - …this revision’s changelog is incomplete
- **2026-08-11** `9ae232e55479`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/apinizer/apis/apinizer-management-apis/changes/apiops/settings/ai-privacy-presets/:presetName/put.md)

---

[API](https://skmtc.dev/apinizer/apis/apinizer-management-apis.md) - [All operations](https://skmtc.dev/apinizer/apis/apinizer-management-apis/llms.txt) - [OpenAPI document](https://skmtc.dev/apinizer/apis/apinizer-management-apis/revisions/e083046b24cd?raw)
