heartleo/zlib

A command-line tool for Z-Library. Search, download, send to Kindle, and integrate with AI agents.

What it solves

zlib is a command-line interface (CLI) for Z-Library, allowing users to search for and download books without using a web browser. It simplifies the process of managing downloads, handling mirror domains, and delivering books directly to Kindle devices.

How it works

The tool interacts with Z-Library via either standard HTML forms or an unofficial mobile app API (EAPI). It includes a "doctor" command to probe available mirror domains to find those that are healthy or can bypass anti-bot protections (like DiamWall). It manages user sessions and configuration via environment variables and local config files.

Who it’s for

Users who prefer a terminal-based workflow for accessing Z-Library, developers who want to automate book downloads via scripts, and Kindle users who want a direct delivery pipeline from the CLI.

Highlights

  • Interactive Search: Browse and download books using arrow keys and pagination.
  • Kindle Integration: Send books directly to Kindle addresses via SMTP.
  • Anti-Bot Handling: Automatically solves JS proof-of-work challenges on supported domains.
  • AI Plugin Support: Includes plugins for Claude Code and Codex to allow AI agents to search and download books.
  • Customizable UI: Supports multiple terminal themes (e.g., Nord, Dracula, Gruvbox).
  • Proxy Support: Built-in support for proxies to navigate restricted networks.

Related

  • Project
  • Project
  • Project
  • Project