Cache: Archive cache tree
metrecept_archive_cache_treeArchive a cache tree to make it read-only and hide it from active listings while preserving all entries for later restore; set archived=false to restore its prior status.
Instructions
Archive a cache tree: make it read-only and hide it from metrecept_list_cache_trees, keeping every entry so it can be restored later; archived=false restores it to the status it had before (active or frozen). Use it to retire a finished experiment's tree without losing it. Not for a temporary write lock: use metrecept_freeze_cache_tree. Not for freeing storage: use metrecept_delete_cache_tree. Archived trees still serve hits, but writes, eviction, reset and freeze return 409 tree_archived, and they cannot be a fork parent or promote target. List them with include_archived=true. Idempotent, not billed, audit-logged. Errors: 409 cannot_archive_main, 404 tree_missing. Requires a Metrecept API key (METRECEPT_API_KEY env on stdio, or Authorization: Bearer on remote HTTP); results are scoped to that key's tenant only.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tree_id | Yes | Id of the cache tree to archive or restore; any tree except "main". | |
| archived | No | true (default) archives the tree; false restores it to the status it had before archiving. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |