Skip to main content

CLI Reference

BookLife provides CLI subcommands for setup and standalone operations.

Commands

serve

Start the MCP server (default command).

booklife serve --config booklife.kdl
booklife --config booklife.kdl # same thing
FlagDescription
--config PATHPath to KDL configuration file

libby-connect

Connect a Libby/OverDrive account using a clone code.

booklife libby-connect <8-digit-code> [--skip-tls-verify]

Steps:

  1. Open Libby app → Settings → Copy To Another Device → Sonos Speakers
  2. Note the 8-digit code displayed
  3. Run the command within ~40 seconds
FlagDescription
--skip-tls-verifySkip TLS certificate verification (for OverDrive cert issues)

Identity is saved to:

  • Linux: ~/.config/booklife/libby-identity.json
  • macOS: ~/Library/Application Support/booklife/libby-identity.json

sync

Sync returned Libby books to Hardcover as "read".

booklife sync --config booklife.kdl [--dry-run] [--limit N]
FlagDescription
--config PATHPath to KDL configuration file
--dry-runPreview sync without making changes
--limit NLimit number of entries to sync

Output includes:

  • Book matching results (ISBN and title+author matching)
  • Hardcover IDs for successfully matched books
  • Error details for failed matches

import-timeline

Import a Libby timeline JSON export to local history.

booklife import-timeline <json-file> --config booklife.kdl

version

Show version information.

booklife version