---
title: "Apply transcript customization operations"
method: PATCH
path: "/customizations"
tags: ["customizations"]
---

# Apply transcript customization operations

`PATCH /customizations`

## Request

- Base URL: `https://api.aquavoice.com/v1`
- URL: `https://api.aquavoice.com/v1/customizations`
- Auth: HTTP bearer

Applies all operations atomically against the latest state. Each
operation says what to want, not what to change, so no read is needed
first. Send `expected_revision` to refuse a write over a newer change
(`409 transcript_customizations_conflict`). Send `dry_run: true` to
get the would-be state and `results` without saving.

## Request body

- CustomizationsUpdate
  - `expected_revision` integer: Optional. When present, the write fails with 409 unless this is the current revision.
  - `dry_run` boolean: Validate and compute the response without saving.
  - `operations` CustomizationOperation[], required
    - union
      - object
        - `type` 'dictionary_add', required
        - `word` string, required
      - object
        - `type` 'dictionary_remove', required
        - `word` string, required
      - object: The dictionary becomes exactly these words.
        - `type` 'dictionary_replace', required
        - `words` string[], required
      - object
        - `type` 'replacement_set', required
        - `from` string, required
        - `to` string, required
      - object
        - `type` 'replacement_remove', required
        - `from` string, required
      - object: The replacements become exactly these; the last entry for a `from` wins.
        - `type` 'replacements_replace', required
        - `replacements` Replacement[], required
          - `from` string, required
          - `to` string, required
      - object
        - `type` 'custom_instructions_set', required
        - `text` string, required
      - object
        - `type` 'custom_instructions_append', required
        - `text` string, required

## Response `200`

Updated customization state, with one result per operation.

- CustomizationsUpdated
  - `object` 'customizations', required
  - `revision` integer, required
  - `updated_at` string, date-time, nullable, required
  - `dictionary` string[], required
  - `replacements` Replacement[], required
    - `from` string, required
    - `to` string, required
  - `custom_instructions` string, required
  - `warning` string: Only in an update result. Present when the dictionary is longer than speech recognition reads.
  - `results` CustomizationResult[], required: One entry per operation, in request order.
    - union: What one operation changed, against the state before it. Empty lists mean no change.
      - object
        - `added` string[], required
        - `removed` string[], required
      - object
        - `added` Replacement[], required: Includes a changed `to` for an existing `from`.
          - `from` string, required
          - `to` string, required
        - `removed` Replacement[], required
          - `from` string, required
          - `to` string, required
      - object
        - `changed` boolean, required

## Other responses

- `default`: Product API error.

---

[API](https://skmtc.dev/aquavoice/apis/aqua-api.md) - [All operations](https://skmtc.dev/aquavoice/apis/aqua-api/llms.txt) - [OpenAPI document](https://skmtc.dev/aquavoice/apis/aqua-api/revisions/f0139c07aded?raw)
