ShelfBridge

ShelfBridge

Docker app from rpurandare's Repository

Overview

Sync your audiobook reading progress from Audiobookshelf to Hardcover automatically.

ShelfBridge

Sync your audiobook reading progress from Audiobookshelf to Hardcover automatically.

πŸš€ Quick Start

Docker (Recommended)

Option 1: Environment Variables (Basic Setup)

# Download docker-compose.yml
curl -O https://raw.githubusercontent.com/rohit-purandare/ShelfBridge/main/docker-compose.yml

# Edit docker-compose.yml and uncomment/set your environment variables:
# SHELFBRIDGE_USER_0_ID: "your_username"
# SHELFBRIDGE_USER_0_ABS_URL: "https://your-audiobookshelf-server.com"
# SHELFBRIDGE_USER_0_ABS_TOKEN: "your_abs_token"
# SHELFBRIDGE_USER_0_HARDCOVER_TOKEN: "your_hardcover_token"

# Start the container
docker-compose up -d

Option 2: YAML Configuration (Basic + Advanced Features)

# Download and start
curl -O https://raw.githubusercontent.com/rohit-purandare/ShelfBridge/main/docker-compose.yml
docker-compose up -d

# Configure your settings
cp config/config.yaml.example config/config.yaml
# Edit config/config.yaml with your credentials and advanced settings
# Restart the container:
docker-compose restart

Node.js

ShelfBridge supports Node.js 22 and 24. Node.js 24 LTS is recommended.

# Clone and install
git clone https://github.com/rohit-purandare/ShelfBridge.git
cd ShelfBridge && npm install

# Configure and start
cp config/config.yaml.example config/config.yaml
# Edit config/config.yaml with your tokens
node src/main.js start

βš™οΈ Configuration Options

ShelfBridge supports two configuration methods to fit different deployment needs:

πŸ”§ Environment Variables (Basic Configuration)

Perfect for Docker deployments, container environments, and simple setups.

βœ… Supports:

  • User credentials (tokens, URLs)
  • Core sync settings (workers, scheduling, thresholds)
  • Rate limiting and performance tuning
  • Safety settings (dry-run, progress protection)

Example:

SHELFBRIDGE_USER_0_ID=alice
SHELFBRIDGE_USER_0_ABS_URL=https://abs.example.com
SHELFBRIDGE_USER_0_ABS_TOKEN=your_abs_token
SHELFBRIDGE_USER_0_HARDCOVER_TOKEN=your_hardcover_token
SHELFBRIDGE_MIN_PROGRESS_THRESHOLD=5.0
SHELFBRIDGE_AUTO_ADD_BOOKS=true

πŸ“„ YAML Configuration (Basic + Advanced Features)

Required for advanced features and complex multi-user setups.

βœ… Everything from Environment Variables, plus:

  • Library filtering - Include/exclude specific libraries
  • Title/Author matching - Intelligent fuzzy matching for books without ASIN/ISBN
  • Reread detection - Advanced progress regression protection
  • Multi-user advanced setups - Different settings per user
  • Complex family configurations - User-specific library preferences

Example:

global:
  min_progress_threshold: 5.0
  auto_add_books: true
  libraries:
    exclude: ['Podcasts', 'Samples'] # ← Not possible with env vars

users:
  - id: alice
    abs_url: https://abs.example.com
    abs_token: your_abs_token
    hardcover_token: your_hardcover_token
    libraries:
      include: ['Audiobooks', 'Fiction'] # ← Advanced per-user filtering

🎯 Which Should You Use?

Use Case Recommendation Why
Basic Docker setup Environment Variables Simple, container-friendly
Single user, no filtering Environment Variables Fastest to configure
Homelab/NAS deployment Environment Variables Easy container management
Need library filtering YAML Configuration Arrays not supported in env vars
Multi-user with different libraries YAML Configuration Complex per-user settings
Family setup YAML Configuration Advanced user management

πŸ’‘ Hybrid Approach: You can use both! Set basic credentials via environment variables and advanced features via YAML.

πŸ“– Documentation

πŸš€ Getting Started

βš™οΈ Configuration

πŸ”§ Usage & Commands

πŸ”„ Recent Changes

v1.16.0: Added comprehensive title/author matching as a third fallback option! When books lack ASIN/ISBN identifiers, ShelfBridge now intelligently matches using Hardcover's search API with a sophisticated scoring algorithm. Features configurable confidence thresholds and supports matching across different formats (audiobook ↔ ebook).

v1.15.0: Added environment variable configuration support! Perfect for Docker deployments and homelab setups. Configure basic settings without YAML files. Environment variables provide ~85% feature parity with YAML configuration. Advanced features like library filtering still require YAML.

v1.14.0: Added multi-library filtering support! Now you can include/exclude specific Audiobookshelf libraries by name or ID. Configure globally or per-user to sync only the libraries you want. Enhanced debug command shows available libraries for easy configuration.

v1.13.0: Enhanced CLI interface and workflow improvements. Improved sync output display and user experience with better progress indicators and performance metrics.

v1.12.4: Comprehensive CLI interface, multi-user support, and advanced configuration options. Use node src/main.js <command> for direct access, or node src/main.js interactive for menu-driven mode.

πŸ“ Note: The CHANGELOG.md file is now automatically updated on every release! Check the complete changelog for detailed version history.

πŸ“‹ Features

  • βœ… Flexible configuration - Environment variables for simple setups, YAML for advanced features
  • βœ… Automatic sync - Scheduled synchronization between services
  • βœ… Multi-user support - Sync multiple users from one server
  • βœ… Library filtering - Sync specific libraries or exclude unwanted ones
  • βœ… Progress protection - Prevent accidental progress regression
  • βœ… Smart matching - Advanced 3-tier matching: ASIN β†’ ISBN β†’ Title/Author with intelligent fuzzy matching
  • βœ… Docker support - Easy deployment with containers
  • βœ… Comprehensive logging - Detailed sync reports and error tracking

🀝 Contributing

See Contributing Guide for development setup and guidelines.

πŸ“„ License

MIT License - see LICENSE file for details.

Install ShelfBridge on Unraid in a few clicks.

Find ShelfBridge in Community Apps on your Unraid server, review the template, and click Install. Unraid handles the Docker app or plugin setup from the published template.

Open the Apps tab on your Unraid server Search Community Apps for ShelfBridge Review the template variables and paths Click Install

Requirements

Audiobookshelf server with API access and Hardcover account with API token

Related apps

Explore more like this

Explore all

Details

Repository
ghcr.io/rohit-purandare/shelfbridge:latest
Last Updated2026-07-17
First Seen2025-08-19

Runtime arguments

Network
bridge
Shell
sh
Privileged
false
Extra Params
--restart=no

Template configuration

ConfigPathrw

Container config directory

Target
/app/config
Default
/mnt/user/appdata/shelfbridge/config
Value
/mnt/user/appdata/shelfbridge/config
DataPathrw

Container data directory

Target
/app/data
Default
/mnt/user/appdata/shelfbridge/data
Value
/mnt/user/appdata/shelfbridge/data
LogsPathrw

Container logs directory

Target
/app/logs
Default
/mnt/user/appdata/shelfbridge/logs
Value
/mnt/user/appdata/shelfbridge/logs
User IDVariable

Your username/identifier (any name you choose)

Target
SHELFBRIDGE_USER_0_ID
Audiobookshelf URLVariable

URL of your Audiobookshelf server (include https://)

Target
SHELFBRIDGE_USER_0_ABS_URL
Audiobookshelf TokenVariable

API token from your Audiobookshelf server

Target
SHELFBRIDGE_USER_0_ABS_TOKEN
Hardcover TokenVariable

API token from Hardcover (hardcover.app/account/api)

Target
SHELFBRIDGE_USER_0_HARDCOVER_TOKEN