> ## Documentation Index
> Fetch the complete documentation index at: https://docs.the40thieves.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# update_frontmatter

> Mutate a note's frontmatter (set/remove/merge/replace).

Mutate a note's frontmatter (set/remove/merge/replace). `replace` discards all existing metadata and requires confirmation, except on a note whose frontmatter is not valid YAML (nothing parsed to discard): that is the repair route, and it needs no approval. `replace` takes `properties` (an object) or `frontmatter_yaml` (raw YAML for the whole block, no --- lines; validated before anything is written and refused with the parse error if invalid). set/remove/merge on a note whose frontmatter is not valid YAML are refused. Optional prev\_hash gives compare-and-swap. Set nested=true to address a dotted key path for set/remove (intermediate objects are created as needed). response\_format=concise acknowledges with \{vault, path, content\_hash} only (no frontmatter echo).

| | |
| - | - |
| **Domain** | metadata |
| **Scopes** | `write:notes` |
| **Access** | write |
| **Tags** | `writes`, `destructive`, `hitl`, `domain:metadata` |
| **Profile** | core, full |

## Annotations

| Annotation | Value |
| - | - |
| Read-only | no |
| Destructive | yes |
| Idempotent | no |
| Accepts an idempotency key | no |

`Idempotent` is the advisory MCP `idempotentHint`. `Destructive` is also `yes` for a tool that
asks for confirmation only on some calls.

## Confirmation (human in the loop)

The handler asks for confirmation only when a call crosses a boundary (for example an overwrite, a folder-boundary crossing or a bulk-cost floor); other calls need none.

* The confirmation binds to the vault paths the call names, which are also checked against the folder ACL.

## Input

| Parameter | Type | Required | Default | Description |
| - | - | - | - | - |
| `vault` | `string` | | — | Vault id. May be omitted when only one vault is available. length 1–64; pattern `^[a-z0-9_-]+$` |
| `path` | `string` | yes | — | length 1–1024 |
| `operation` | `enum` | yes | — | One of: `"set"`, `"remove"`, `"merge"`, `"replace"` |
| `key` | `string` | | — | length ≥ 1 |
| `value` | `any` | | — | — |
| `properties` | `Record<string, any>` | | — | — |
| `frontmatter_yaml` | `string` | | — | length ≤ 200000 |
| `prev_hash` | `string` | | — | — |
| `create_if_missing` | `boolean` | | `false` | — |
| `nested` | `boolean` | | `false` | — |
| `elicit_token` | `string` | | — | pattern `^[a-f0-9]{32}$` |
| `response_format` | `enum` | | — | concise returns only the high-signal fields; detailed (the shipped default) returns the full payload. Errors and safety warnings are never trimmed. When omitted, the server's tools.defaults.responseFormat applies. One of: `"concise"`, `"detailed"` |
| `verbosity` | `enum` | | — | Legacy alias for response\_format: terse = concise, full = detailed. One of: `"full"`, `"terse"` |

## Output

| Field | Type | Always present | Description |
| - | - | - | - |
| `vault` | `string` | yes | — |
| `path` | `string` | yes | — |
| `operation` | `enum` | | One of: `"set"`, `"remove"`, `"merge"`, `"replace"` |
| `created` | `boolean` | | — |
| `frontmatter` | `object \| null` | | — |
| `content_hash` | `string` | yes | — |
| `prev_hash` | `string \| null` | | — |
| `conventions` | `object` | | — |
| `conventions.warnings` | `object[]` | | — |
| `conventions.warnings_omitted` | `integer` | | range ≥ -9007199254740991 |
| `conventions.file_warnings` | `object[]` | | — |
| `conventions.file_warnings_omitted` | `integer` | | range ≥ -9007199254740991 |

## Related tools

Other tools in the `metadata` domain: [`add_tag`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/add_tag/), [`bulk_set_property`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/bulk_set_property/), [`find_notes_by_property`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/find_notes_by_property/), [`find_notes_by_tag`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/find_notes_by_tag/), [`get_conventions`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/get_conventions/), [`get_note_tags`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/get_note_tags/), [`list_properties`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/list_properties/), [`list_tags`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/list_tags/), [`read_frontmatter`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/read_frontmatter/), [`read_metadata_fields`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/read_metadata_fields/), [`read_property`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/read_property/), [`remove_tag`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/remove_tag/), [`suggest_tags`](https://docs.the40thieves.dev/reliquary-tc/tools/reference/suggest_tags/).

Back to the [tool catalog](https://docs.the40thieves.dev/reliquary-tc/tools/tool-catalog.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.