Skip to main content

CreateLibraryRequest

Create library request

allowedFormatsstring[]nullable

Allowed file formats (e.g., ["CBZ", "CBR", "EPUB"])

Example: ["CBZ","CBR","EPUB"]
autoMatchConditions

Auto-match conditions (JSON object with mode and rules) Controls when auto-matching runs for this library

bookConfig

Book strategy-specific configuration (JSON, mutable after creation)

bookStrategyBookStrategy (string)

Book naming strategy (mutable after creation) Options: filename, metadata_first, smart, series_name

Possible values: [filename, metadata_first, smart, series_name, custom]

defaultReadingDirectionstring | nullnullable

Default reading direction for books in this library (ltr, rtl, ttb or webtoon)

Example: ltr
descriptionstring | nullnullable

Optional description

Example: My comic book collection
excludedPatternsstring | nullnullable

Excluded path patterns (newline-separated, e.g., ".DS_Store\nThumbs.db")

Example: .DS_Store Thumbs.db
namestringrequired

Library name

Example: Comics
numberConfig

Number strategy-specific configuration (JSON, mutable after creation)

numberStrategyNumberStrategy (string)

Book number strategy (mutable after creation) Options: file_order, metadata, filename, smart

Possible values: [file_order, metadata, filename, smart]

pathstringrequired

Filesystem path to the library

Example: /media/comics
scanImmediatelyboolean

Scan immediately after creation (not stored in DB)

Example: true
scanningConfig object

Scanning configuration

cronSchedulestring | nullnullable

Cron expression for scheduled scans. Accepts standard 5-part Unix cron (e.g., "0 */6 * * *") or 6-part with seconds (e.g., "0 0 */6 * * *"). Stored as provided; normalization happens at scheduler level.

Example: 0 */6 * * *
cronTimezonestring | nullnullable

IANA timezone for the cron schedule (e.g., "America/Los_Angeles", "Europe/London"). Overrides the server-level scheduler.timezone config for this library. If not set, falls back to the server default (which itself defaults to UTC).

Example: America/Los_Angeles
enabledbooleanrequired

Whether scheduled scanning is enabled

Example: true
purgeDeletedOnScanboolean

Purge soft-deleted books after completing a scan

Example: false
scanModestringrequired

Default scan mode for scheduled scans ("normal" or "deep")

Example: normal
scanOnStartboolean

Scan library when the application starts

Example: false
seriesConfig

Strategy-specific configuration (JSON, immutable after creation)

seriesStrategySeriesStrategy (string)

Series detection strategy (immutable after creation) Options: series_volume, series_volume_chapter, flat, publisher_hierarchy, calibre, custom

Possible values: [series_volume, series_volume_chapter, flat, publisher_hierarchy, calibre, custom]

titlePreprocessingRules

Title preprocessing rules (JSON array of regex rules) Applied during scan to clean series titles before metadata search

CreateLibraryRequest
{
"allowedFormats": [
"CBZ",
"CBR",
"EPUB"
],
"bookStrategy": "filename",
"defaultReadingDirection": "ltr",
"description": "My comic book collection",
"excludedPatterns": ".DS_Store\nThumbs.db",
"name": "Comics",
"numberStrategy": "file_order",
"path": "/media/comics",
"scanImmediately": true,
"scanningConfig": {
"cronSchedule": "0 */6 * * *",
"cronTimezone": "America/Los_Angeles",
"enabled": true,
"purgeDeletedOnScan": false,
"scanMode": "normal",
"scanOnStart": false
},
"seriesStrategy": "series_volume"
}