npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

mcp-douban-server

v1.0.0

Published

MCP Server for Douban books, movies, and groups interaction

Downloads

5

Readme

Douban MCP Server

This MCP server provides functionality to search and interact with Douban content including books, movies, and group discussions.

Features

  • Search Books: Search books by title keywords or ISBN
  • Search Movies: Search movies by title or keywords
  • Get Movie Reviews: Fetch reviews for a specific movie
  • Browse Content: Open book or movie pages in your default browser
  • Group Topics: List and filter topics from Douban groups
  • Topic Details: Get detailed content of specific group topics

Tools

The server provides the following tools that can be called through MCP:

1. Search Books

// Tool name: search-book
{
  q: "Python",             // Optional: Search by keyword
  isbn: "9787501524044"    // Optional: Search by ISBN
}

One of q or isbn must be provided.

2. Search Movies

// Tool name: search-movie
{
  q: "Inception"; // Required: Search by title or keyword
}

3. Get Movie Reviews

// Tool name: get-movie-reviews
{
  id: "1889243"; // Required: Douban movie ID
}

4. Browse Content

// Tool name: browse
{
  id: "1889243",           // Required: Douban item ID
  type: "movie"            // Optional: "book" (default) or "movie"
}

5. List Group Topics

// Tool name: list-group-topics
{
  id: "732764",            // Optional: Douban group ID (default: 732764)
  tags: ["python", "web"],  // Optional: Filter by tags
  from_date: "2024-01-01"  // Optional: Filter by date (from this date onward)
}

6. Get Group Topic Detail

// Tool name: get-group-topic-detail
{
  id: "123456789"; // Required: Douban group topic ID
}

Response Format

All tools return responses in the following format:

{
  content: [
    {
      type: "text",
      text: "Response content in markdown format",
    },
  ];
}

Getting Started

  1. Clone the repository
  2. Install dependencies: npm install
  3. Build the server: npm run build

Usage

To use the server, you can run it directly:

npm start

This will start the Douban MCP Server running on stdio.

Usage with Desktop App

To integrate this server with a desktop app, add the following to your app's server configuration:

{
  "mcpServers": {
    "douban-mcp": {
      "command": "node",
      "args": ["{ABSOLUTE PATH TO FILE HERE}/dist/index.js"],
      "env": {
        "COOKIE": "bid=;ck=;dbcl2=;frodotk_db=;" // get cookie value from Douban website
      }
    }
  }
}

Configuration

You can configure various options through environment variables:

# API Configuration
export COOKIE="bid=;ck=;dbcl2=;frodotk_db=;" # Your Douban cookie value for authenticated requests

Development

  • Run npm run dev to start the TypeScript compiler in watch mode
  • Run npm test to run tests

Douban API Integration

This server uses several Douban APIs:

  1. Book API - Searches for books by keyword or ISBN
  2. Movie API - Searches for movies and retrieves reviews
  3. Group API - Accesses group topics and details

Error Handling

All tools include comprehensive error handling that will provide clear error messages when issues occur, such as:

  • Invalid parameters
  • Not found errors
  • API request failures
  • Authentication issues

License

This project is licensed under the MIT License.