ER

edricgsh/readwise-reader-mcp

API 开发

本页由 AI 翻译,技术细节请以原文为准。 查看原文

47 stars 8 forks 质量 66 趋势 0MIT

一款用于 Readwise Reader API 的模型上下文协议(MCP)服务器,使用 TypeScript 和官方 Claude SDK 构建。

概览

一款用于 Readwise Reader API 的模型上下文协议(MCP)服务器,使用 TypeScript 和官方 Claude SDK 构建。 - : 使用环境变量进行令牌存储 - : 保存、列出、更新和删除包含完整元数据的文档 - : 按标签列表和过滤 - : 按位置、类别、标签等过滤文档 - : 处理大型文档集合 - : 使用 r.jina.ai 自动转换为干净文本的HTML内容 - : 返回包括内容、元数据和时间戳在内的完整文档信息 有关 Readwise Reader API 端点、参数和示例的详细信息,请参阅官方 API 文档: 该MCP服务器实现了官方文档中描述的所有核心端点。 2. 从以下地址获取您的 Readwise 访问令牌:https://readwise.io/access_token 3. 将服务器添加到你的Claude桌面配置中。

概述(AI 翻译)

一款用于 Readwise Reader API 的模型上下文协议(MCP)服务器,使用 TypeScript 和官方 Claude SDK 构建。

特色

  • 安全认证:使用环境变量进行令牌存储
  • 文档管理:保存、列出、更新和删除包含完整元数据的文档
  • 标签管理:按标签列表和筛选
  • 丰富过滤:按位置、类别、标签等筛选文档
  • 分页支持:处理大型文档集合
  • LLM 友好内容:利用 r.jina.ai 自动转换为干净文本的 HTML 内容
  • 完整数据访问:返回包括内容、元数据和时间戳在内的完整文档信息

API 文档

有关 Readwise Reader API 端点、参数和示例的详细信息,请参阅官方 API 文档:

** 📖 Readwise Reader API 文档 **

该MCP服务器实现了官方文档中描述的所有核心端点。

安装

配置

使用Claude桌面

  1. 构建MCP服务器:

  2. 从以下地址获取您的 Readwise 访问令牌:https://readwise.io/access_token

  3. 将服务器添加到你的Claude桌面配置中。

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

Readwise Reader MCP Server

A Model Context Protocol (MCP) server for the Readwise Reader API, built with TypeScript and the official Claude SDK.

Features

  • Secure Authentication: Uses environment variables for token storage
  • Document Management: Save, list, update, and delete documents with complete metadata
  • Tag Management: List and filter by tags
  • Rich Filtering: Filter documents by location, category, tags, and more
  • Pagination Support: Handle large document collections
  • LLM-Friendly Content: HTML content automatically converted to clean text using r.jina.ai
  • Complete Data Access: Returns full document information including content, metadata, and timestamps

API Documentation

For detailed information about the Readwise Reader API endpoints, parameters, and examples, please refer to the official API documentation:

📖 Readwise Reader API Documentation

This MCP server implements all the core endpoints described in the official documentation.

Installation

npm install
npm run build

Configuration

With Claude Desktop

  1. Build the MCP server:

    npm install
    npm run build
    
  2. Get your Readwise access token from: https://readwise.io/access_token

  3. Add the server to your Claude Desktop configuration. Open your Claude Desktop settings and add this to your MCP servers configuration:

    macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%\Claude\claude_desktop_config.json

    {
      "mcpServers": {
        "readwise-reader": {
          "command": "node",
          "args": ["/path/to/your/reader_readwise_mcp/dist/index.js"],
          "env": {
            "READWISE_TOKEN": "your_readwise_access_token_here"
          }
        }
      }
    }
    

    Replace:

    • /path/to/your/reader_readwise_mcp with the actual path to this project directory
    • your_readwise_access_token_here with your actual Readwise access token
  4. Restart Claude Desktop

Available Tools

readwise_save_document

Save a document (URL or HTML content) to Readwise Reader.

Parameters:

  • url (required): URL of the document to save
  • html (optional): HTML content of the document
  • tags (optional): Array of tags to add
  • location (optional): Location to save (new, later, shortlist, archive, feed)
  • category (optional): Document category (article, book, tweet, pdf, email, youtube, podcast)

readwise_list_documents

List documents from Readwise Reader with optional filtering. Returns complete document information including metadata and LLM-friendly text content.

Parameters:

  • id (optional): Filter by specific document ID
  • updatedAfter (optional): Filter documents updated after this date (ISO 8601)
  • location (optional): Filter by document location
  • category (optional): Filter by document category
在 GitHub 查看完整 README

安装

This server does not publish a one-line install command.

Open the repository installation guide 新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "readwise-reader": { "command": "node", "args": ["/path/to/your/reader_readwise_mcp/dist/index.js"], "env": { "READWISE_TOKEN": "your_readwise_access_token_here" } } } }