mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-03-01 21:49:40 +00:00
2.3 KiB
2.3 KiB
Metadata Management Tools
Overview
Audiobookshelf provides tools to manage and recover metadata when automatic matching fails or when users have manually edited metadata and wish to revert to the data contained within the source files.
Reset Metadata
The Reset Metadata action allows a user to discard all manual edits and server-side metadata files, forcing the scanner to re-evaluate the item from its original source.
Mechanism
When a "Reset" is triggered:
- Server Metadata Removal: The
metadata.jsonfile stored in the application's internal metadata directory (/metadata/items/<id>/metadata.json) is deleted. - Local Metadata Removal: If the system is configured to
storeMetadataWithItem, themetadata.jsonfile inside the book's folder is also deleted. - Database Reset: The
media.coverPathis set tonullin the database. - Re-Scan: A full scan is triggered using
LibraryItemScanner.scanLibraryItem(id). This scan prioritizes:- Embedded Audio Tags (ID3, MP4, etc.)
- OPF or NFO files in the folder.
- Filename and folder structure patterns.
Usage
- Single Item: Found in the Edit Modal under the Details tab, next to the "ReScan" button.
- Color: Represented by a red button (Warning) to indicate a destructive action.
Batch Reset Metadata
The batch version allows performing the reset operation on multiple selected items simultaneously.
Usage
- Select multiple items in the library listing.
- Open the context menu (three dots) in the selection bar at the top of the interface.
- Select Reset Metadata.
- A confirmation dialog will appear, confirming the number of items to be reset.
When to Use
- Incorrect Matches: If a book was matched to the wrong title and manual corrections are too cumbersome.
- File Updates: If the underlying audio files have been replaced with different versions (e.g., higher bitrate) and the user wants to ensure the database reflects the new file tags.
- Corrupted Metadata: If the
metadata.jsonhas become inconsistent with the actual files on disk.
Technical Details
- Permissions: Requires the
canUpdatepermission. - Events: Triggering a reset will eventually emit an
item_updatedsocket event once the subsequent scan completes.