原型 · 预览版:收录官方注册中心里的全部服务器,每 30 分钟同步一次。使用 Google 登录即可撰写评价。原型 · 每 30 分钟更新
PopNx MCP为使用 AI 的人准备的 MCP 服务器 · 用大白话讲清楚

PDF Writer (PDF Agent Stack)

作者:shuji-bonji版本 0.28.1i★ 0i在你的电脑上运行官方网站 ↗
注册名称io.github.shuji-bonji/pdf-writer-mcp

安装方法

What it does

Create and edit PDFs: text, Markdown, tables, metadata and pages, with Japanese font embedding.

  • Connects 在你的电脑上运行
  • Account or key No key needed
  • Category 文档、表格与办公

可搭配使用

教 AI 做这类工作的 Skill,可与本项一起使用

MinerU

Transforms complex documents like PDFs and Office docs into LLM-ready markdown/JSON for your Agentic workflows.

作者:opendatalab★ 83,9721 个 skill

Skill · 操作手册未注明许可证

watermarks-remover

A privacy-first app that strips AI watermarks from content you own.

作者:guillaumemeyer★ 27,7961 个 skill

Skill · 操作手册

obsidian-skills

Agent skills for Obsidian. Teach your agent to use Obsidian CLI and open formats including Markdown, Bases, JSON Canvas.

作者:kepano★ 53,183 (whole repo)5 个 skill

Skill · 操作手册

为什么排在这里

列表按使用分(满分 100)排序,由以下部分组成

热度28/80GitHub 星标或每周下载量:较大的计 60,较小的计 20
新鲜度12/1230 天内有发布或代码更新得满分
仍在响应0/8上次检查时云端端点有响应
使用分40/100

质量: 基础检查通过 3/3 项(仅展示,不用于排序) · 上升势头: 202 (只用于“上升中”标签)

安装

选择你使用的 AI 应用,然后复制设置。

用一句话让 AI 帮你安装

请帮我安装 PDF Writer (PDF Agent Stack)。按照 https://mcp.popnx.com/i/shuji-bonji-pdf-writer-mcp.md 操作,先把命令给我看,等我同意后再运行。

粘贴到能在你电脑上工作的 AI(如 Claude Code、Cursor)。它会读取我们的步骤,先给你看命令,等你同意。无需密钥,无需注册。 · 查看 AI 会读取的全文

通过 3/3 项检查 · 在你的电脑上运行 · ✓ 命令已检查 2026年11月20日

第一步:你用哪个 AI?

选择你用的应用,步骤会显示在下方。

可连接 Claude,但需要先准备

需要先在电脑上安装 Node.js(只需一次) · 仅限电脑上的 Claude 应用(Windows 或 Mac),网页和手机不可用

让 AI 帮你安装

把这段话复制到 Claude 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 Claude 安装 MCP server PDF Writer (PDF Agent Stack),按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "mcpServers": { "pdf-writer": { "command": "npx", "args": [ "-y", "@shuji-bonji/pdf-writer-mcp" ] } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) 不需要密钥。5) 按约定执行,然后确认 PDF Writer (PDF Agent Stack) 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 打开电脑版 Claude 应用的设置文件

    SettingsDeveloperEdit Config

  3. 粘贴这些设置并保存文件

    {
      "mcpServers": {
        "pdf-writer": {
          "command": "npx",
          "args": [
            "-y",
            "@shuji-bonji/pdf-writer-mcp"
          ]
        }
      }
    }
  4. 退出 Claude 再重新打开

  5. 试一试

    用 PDF Writer (PDF Agent Stack) 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 Claude 说正在使用 PDF Writer (PDF Agent Stack),或回答中出现 PDF Writer (PDF Agent Stack) 的工具名称,就表示连接成功

菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同

ChatGPT 暂时无法连接 PDF Writer (PDF Agent Stack)

PDF Writer (PDF Agent Stack) 需要安装在你的电脑上,而 ChatGPT 只能连接在网上运行的服务器

你可以改用这些方式

A · 使用能连接 PDF Writer (PDF Agent Stack) 的应用

  • 需要先在电脑上安装 Node.js(只需一次) · 仅限电脑上的 Claude 应用(Windows 或 Mac),网页和手机不可用
  • 需要先在电脑上安装 Node.js(只需一次)
  • 需要先在电脑上安装 Node.js(只需一次)
  • 需要先在电脑上安装 Node.js(只需一次)

B · 文档、表格与办公 类中能连接 ChatGPT 的其他服务器

从同类中使用较多的里挑选,仅限用地址即可连接、无需密钥的

可连接 Claude Code,但需要先准备

需要先在电脑上安装 Node.js(只需一次)

让 AI 帮你安装

把这段话复制到 Claude Code 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 Claude Code 安装 MCP server PDF Writer (PDF Agent Stack),按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):claude mcp add --scope user pdf-writer -- npx -y @shuji-bonji/pdf-writer-mcp 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) 不需要密钥。5) 按约定执行,然后确认 PDF Writer (PDF Agent Stack) 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 打开终端

    Mac:按 Command+空格,输入 Terminal · Windows:打开 PowerShell

  3. 粘贴这条命令并按 Enter

    claude mcp add --scope user pdf-writer -- npx -y @shuji-bonji/pdf-writer-mcp
  4. 在 Claude Code 中输入 /mcp

    应能看到 PDF Writer (PDF Agent Stack) 在列表中并显示已连接

  5. 试一试

    用 PDF Writer (PDF Agent Stack) 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 Claude Code 说正在使用 PDF Writer (PDF Agent Stack),或回答中出现 PDF Writer (PDF Agent Stack) 的工具名称,就表示连接成功

菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同

可连接 Cursor,但需要先准备

需要先在电脑上安装 Node.js(只需一次)

让 AI 帮你安装

把这段话复制到 Cursor 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 Cursor 安装 MCP server PDF Writer (PDF Agent Stack),按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "mcpServers": { "pdf-writer": { "command": "npx", "args": [ "-y", "@shuji-bonji/pdf-writer-mcp" ] } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) 不需要密钥。5) 按约定执行,然后确认 PDF Writer (PDF Agent Stack) 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 点击这个按钮打开 Cursor

    在 Cursor 中打开

    Cursor 会请你确认安装,点击 Install

  3. 在 Cursor 中以 Agent 模式打开 AI 聊天

  4. 试一试

    用 PDF Writer (PDF Agent Stack) 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 Cursor 说正在使用 PDF Writer (PDF Agent Stack),或回答中出现 PDF Writer (PDF Agent Stack) 的工具名称,就表示连接成功

菜单名称已于 2026年11月11日 对照 Cursor 帮助页面核实 · 你的界面可能因版本略有不同

可连接 VS Code,但需要先准备

需要先在电脑上安装 Node.js(只需一次)

让 AI 帮你安装

把这段话复制到 VS Code 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 VS Code 安装 MCP server PDF Writer (PDF Agent Stack),按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "servers": { "pdf-writer": { "type": "stdio", "command": "npx", "args": [ "-y", "@shuji-bonji/pdf-writer-mcp" ] } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) 不需要密钥。5) 按约定执行,然后确认 PDF Writer (PDF Agent Stack) 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 点击这个按钮打开 VS Code

    在 VS Code 中打开

    VS Code 会请你确认安装,点击 Install

  3. 在 VS Code 中以 Agent 模式打开 AI 聊天

  4. 试一试

    用 PDF Writer (PDF Agent Stack) 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 VS Code 说正在使用 PDF Writer (PDF Agent Stack),或回答中出现 PDF Writer (PDF Agent Stack) 的工具名称,就表示连接成功

菜单名称已于 2026年11月11日 对照 VS Code 帮助页面核实 · 你的界面可能因版本略有不同

其他支持 MCP 的应用(如 Windsurf、Zed、Gemini CLI)添加方式各不相同,请在应用列表中查看

查看所有支持 MCP 的应用 →

JSON 设置在下方“开发者专用”中

卡住了?问问正在用 PDF Writer (PDF Agent Stack) 的人💬 讨论 →
开发者专用:终端命令和 JSON 设置

安装在电脑上

Claude Code

claude mcp add --scope user pdf-writer -- npx -y @shuji-bonji/pdf-writer-mcp

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "pdf-writer": {
      "command": "npx",
      "args": [
        "-y",
        "@shuji-bonji/pdf-writer-mcp"
      ]
    }
  }
}

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "pdf-writer": {
      "command": "npx",
      "args": [
        "-y",
        "@shuji-bonji/pdf-writer-mcp"
      ]
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "pdf-writer": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@shuji-bonji/pdf-writer-mcp"
      ]
    }
  }
}

这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。

一览

每周下载量i
2,319/周
连接方式
在你的电脑上运行
最新版本i
0.28.1
发布到注册中心i
2026年11月10日
代码最后更新i
2026年11月10日
作者
shuji-bonji
软件包
npm: @shuji-bonji/pdf-writer-mcp
注册状态
活跃

哪些应用可以使用它

依据这个服务器的连接方式和各应用自己的文档,检查于 2026年11月10日。

在你的电脑上运行,适用于

ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast

全部应用及其优缺点 →

它能做什么

它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。

基础检查i

我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月20日

  • ✓ 通过

    作者与仓库一致

    注册名称已通过 GitHub 账户 shuji-bonji 验证,该账户拥有此仓库

  • ✓ 通过

    仍在维护

    代码最后更新于10天前

  • ✓ 通过

    有许可证

    使用 MIT

  • – 不适用

    端点有响应

    它在你的电脑上运行,没有互联网端点

  • – 不适用

    使用 OAuth 登录

    在你的电脑上运行,改用本地设置

  • … 尚未检查

    工具描述中没有隐藏指令

    它在你的电脑上运行;我们只能读取互联网端点的工具列表

已公开的漏洞(OSV.dev)

OSV.dev 中没有 @shuji-bonji/pdf-writer-mcp@0.28.1 的记录

只检查这个版本的包本身,不包括所有依赖 · 检查于 2026年11月15日

我们检查什么 → · JSON

作者:申请重新检查或报告信息错误
给作者:在 README 中加徽章

如果你是作者,可把这段代码贴到 README。徽章会链接回本页。

[![Featured on PopNx MCP](https://mcp.popnx.com/badge/shuji-bonji-pdf-writer-mcp.svg)](https://mcp.popnx.com/en/servers/shuji-bonji-pdf-writer-mcp)

讨论

提问、分享技巧或报告无法使用。按“有帮助”数量排序。

还没有帖子,欢迎第一个提问或分享。

此处内容由用户撰写,不代表 PopNx 团队。

登录后发帖

用户评价

还没有评价

登录后写评价

与“文档、表格与办公”中的其他服务器比较i

  • 星标数多于此分类中其他 4155 个服务器的 0%
  • 发布到注册中心的时间比此分类中其他 4155 个服务器的 76% 更新
  • 基础检查结果等于或优于此分类中其他 4155 个服务器的 99%

与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。

常见问题

PDF Writer (PDF Agent Stack) 安全吗?

它在 3 项适用的基础检查中通过了 3 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。

它需要哪些密钥或代码?

注册中心没有列出必需的密钥,不过有些服务器会在首次使用时要求你登录。

它在我的电脑上运行还是在云端?

它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。

它还在维护吗?

GitHub 仓库最后更新于10天前,最新版本(0.28.1)于10天前进入注册中心。

哪些应用可以使用它?

支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。

有什么可以替代它?

同一分类中有:Puter MCP, XcodeBuildMCP, Vexa, Atlassian Rovo MCP Server, Anki MCP Server

功能相近的其他选择

同一分类、其他作者、命令已通过检查。官方的排在前面,再按星标排序。

如何看卡片:↓ 每周下载量i★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i

Puter MCP

Puter MCP enables AI tools to interact with Puter: manage files, websites, workers, and more

作者:HeyPuter广泛使用★ 4.4万5个月前更新

在云端运行✓ 服务方 · puter.com

XcodeBuildMCP

XcodeBuildMCP provides tools for Xcode project management, simulator management, and app utilities.

作者:getsentry广泛使用↓ 13万/周 共用包的下载量★ 65944个月前更新

在你的电脑上运行✓ 服务方 · xcodebuildmcp.com

Vexa

Meeting bot and transcripts for Google Meet, Teams and Zoom. Live or after, speakers labelled.

作者:Vexa-ai广泛使用★ 29962个月前更新

在云端运行✓ 服务方 · vexa.ai

Anki MCP Server

MCP server for Anki flashcards: adaptive review, notes, media, and deck management via AnkiConnect.

作者:ankimcp正在增长↓ 1136/周★ 5682个月前更新

在你的电脑上运行✓ 服务方 · ankimcp.ai
与相似项目对比
本项
PDF Writer (PDF Agent Stack)
Puter MCPXcodeBuildMCPVexaAtlassian Rovo MCP ServerAnki MCP Server
运行位置需要安装在电脑上在云端运行,无需安装需要安装在电脑上在云端运行,无需安装在云端运行,无需安装需要安装在电脑上
需要密钥否否否是否否
可在 Claude 中按 + 添加否否否否是否
基础检查3/34/43/32/44/43/3
许可证MITAGPL-3.0MITApache-2.0Apache-2.0MIT
价格登记中未列出费用登记中未列出费用登记中未列出费用登记中未列出费用登记中未列出费用登记中未列出费用

作者的 README

打开 README

按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。

pdf-writer-mcp

日本語

MCP server that creates PDFs from text, Markdown, or tabular data and edits existing ones (metadata and page operations). Built on normativepdf — a clause-driven PDF library in which every behaviour is tied to an ISO 32000 clause — with CJK font embedding via harfbuzz subsetting.

Part of the PDF family alongside pdf-reader-mcp (structure analysis) and pdf-verify-mcp (authenticity verification). Where pdf-reader-mcp tells you *what is in* a PDF and pdf-verify-mcp tells you *whether it is genuine*, pdf-writer-mcp is the one that *writes it*.

Tools

[!IMPORTANT]

All file paths must be absolute (since v0.7.0). Relative paths and paths containing .. are rejected — a relative path would resolve against the MCP host's working directory, which is not the directory you think it is. This applies to inputPath, inputPaths, outputPath, outputDir, fontPath and attachmentPath. Input PDFs larger than 100 MB are also rejected.

Creation
ToolPurpose
create_text_pdfPlain text — honours \n, blank lines separate paragraphs, long lines wrap
create_markdown_pdfMarkdown — headings, paragraphs, bullet/ordered lists, code blocks, quotes, rules, tables
create_table_pdfRuled tables — automatic column widths, cell wrapping, headers repeated across page breaks

Shared options: outputPath, returnBase64, fontPath, fontSize, pageSize (A4/A3/A5/LETTER/LEGAL), margin, title, drawTitle, author, onMissingGlyph, tagged, lang, pdfVersion.

PDF 2.0 output (v0.16.0)

Pass pdfVersion: "2.0" to write an ISO 32000-2 file. The default stays "1.7", and its bytes are unchanged.

The version is not only a header. ISO 32000-2 attaches two obligations to it, and both are met:

  • trailer `/ID` becomes Required (Table 15). Both elements are equal on a first write (R-14.4-6), and the value stays deterministic under SOURCE_DATE_EPOCH.
  • the Info dictionary keeps only CreationDate and ModDate (§14.3.3); the title, author and producer move to the XMP metadata stream, where PDF 2.0 says document metadata belongs.
{ "text": "Body.", "title": "Report", "pdfVersion": "2.0" }

With tagged: true, a 2.0 file declares PDF/UA-2 (ISO 14289-2) instead of PDF/UA-1, which allows only PDF 1.0 to 1.7 (ISO 14289-1 §6.1). See PDF/UA-2 below. Up to v0.26.x the combination was refused.

Tagged PDF / PDF/UA (v0.5.0)

Pass tagged: true to produce an accessible, tagged PDF conforming to PDF/UA-1 (ISO 14289). Output is verified compliant by veraPDF (--flavour ua1, 106/106 rules).

{ "markdown": "# Title\n\nBody.", "title": "Report", "tagged": true, "lang": "en" }

Markdown maps onto the structure tree: headings → H1–H6, lists → L/LI/LBody, tables → Table/TR/TH/TD (headers get /Scope), quotes → BlockQuote, code → Code. Rules, borders and code backgrounds become artifacts. Under PDF/UA-1, heading levels are normalised so they start at H1 and never skip — a Markdown # → ### jump becomes H1 → H2 in the structure, while visual sizes stay as authored (PDF/UA-2 keeps the level as written; see below).

PDF/UA mandates a document title, so tagged: true requires title. The title is always written to the metadata (dc:title) and, by default, also drawn as the first H1. When the Markdown already starts with its own # … heading, pass drawTitle: false: the title then stays in the metadata only, and the first body heading becomes H1 (## → ### becomes H1 → H2). Output stays PDF/UA-1 compliant (veraPDF 106/106). lang (BCP 47) is inferred from the text when omitted and reported via warnings — pass it explicitly when you know it, since a wrong /Lang makes screen readers mispronounce the text.

[!NOTE]

Tagging is opt-in — default output is unchanged.

Machine validation (veraPDF) only sees whether things *exist*. It cannot judge whether reading order or alt text are *appropriate* — human review still matters.

PDF/UA-2 (v0.27.0)

Add pdfVersion: "2.0" to tagged: true and the file is written as PDF/UA-2 (ISO 14289-2:2024) on PDF 2.0. The default (1.7, PDF/UA-1) is unchanged.

{ "markdown": "# Title\n\nBody.", "title": "Report", "tagged": true, "pdfVersion": "2.0", "lang": "en" }

What differs from the PDF/UA-1 output, with the clause behind each:

PDF/UA-1 (1.7)PDF/UA-2 (2.0)
XMP declaration (§5)pdfuaid:part 1pdfuaid:part 2 and pdfuaid:rev 2024
Namespaces (§8.2.4, §8.2.5.2)none (the default PDF 1.7 namespace)Document and every type the PDF 2.0 namespace has get /NS → http://iso.org/pdf2/ssn; BlockQuote and Code, which it lacks, stay in the PDF 1.7 namespace
Drawn title (§8.2.5.13)first H1Title (not a heading)
Markdown headings (§8.2.5.12)normalised to start at H1 and never skipthe level as written (# → H1, ### → H3)
Nested listsinside the parent item's LBodydirectly in the parent L, right after the item (ISO 32000-2 §14.8.4.8.2)

Measured with veraPDF 1.30.0 (pdfua-2, 1,728 rules): the output of all three create tools, ensure_tagged on an untagged PDF 2.0 file, and ensure_pdfa(flavour: "pdfa-4") on a PDF/UA-2 file all pass, and the last one also passes PDF/A-4 (109/109).

Edits keep the declaration: when a tool rebuilds the XMP, pdfuaid:rev is carried with pdfuaid:part, and dc:title is kept when the Info dictionary has no Title (PDF 2.0 output does not put one there). add_bookmarks writes structure destinations on a PDF/UA-2 file, as §8.8 requires: a GoTo action whose SD names the structure element that starts on the target page, with D kept as the page destination for viewers that do not read SD. A page with no structure content keeps a page destination and is named in warnings.

Versions and declarations

An edit writes the PDF version of its input. Only an explicit conversion changes it: ensure_pdfa with flavour: "pdfa-4" / "pdfa-4f" (to PDF 2.0), and merge_pdfs with pdfVersion. Versions are never lowered.

  • Anything that would break a *shall* of the output's version, or of a standard the file declares, is refused with INVALID_ARGUMENT. The message names the input's version and declarations; next_actions gives a call that fits. Examples: merge_pdfs over PDF 2.0 and PDF 1.x inputs without pdfVersion, and ensure_pdfa(flavour: "pdfa-3b") on any PDF 2.0 input (PDF/A-3 needs a %PDF-1.n header).
  • A form that the output's version deprecates is written the way that version prescribes. On a PDF 2.0 input, set_metadata writes to XMP and adds no Info entries (ISO 32000-2 §14.3.3); on a PDF/UA-2 input it also moves the existing Info entries to XMP and removes them (ISO 14289-2 §6.2).
  • A mix the standard allows is written and reported. Structure elements that add_annotation and tag_form_fields add to a PDF/UA-2 file have no /NS, so they sit in the PDF 1.7 namespace (§8.2.4 allows it); warnings says so.

Every tool result carries output, read back from the written file:

{ "output": { "pdfVersion": "2.0", "declares": { "pdfua": 2, "pdfa": "4" } } }

declares.pdfua is pdfuaid:part; declares.pdfa joins pdfaid:part and pdfaid:conformance ("3b", "4", "4f"). A key is absent when nothing is declared. A declaration is only a claim — measure it with pdf-verify-mcp.

When a tool rewrites the XMP (set_metadata, ensure_pdfa), the values you did not pass are carried over as written: the other languages of dc:title, every name in dc:creator, and properties in namespaces this server does not know. Changing title replaces the x-default entry and names the other languages in warnings.

Editing — page operations
ToolPurpose
merge_pdfsConcatenate 2–50 PDFs in order; metadata inherited from the first file. Inputs that mix PDF 2.0 and PDF 1.x need pdfVersion: "2.0"
split_pdfOne output file per page range
extract_pagesExtract pages in the requested order (doubles as reordering)
delete_pagesRemove pages (deleting every page is rejected)
reorder_pagesReorder by an explicit permutation of all pages
rotate_pagesRotate clockwise (90/180/270), accumulating over existing rotation. Edits in place, so the warning below does not apply

[!WARNING]

The five tools other than `rotate_pages` rebuild the document from its pages.

- Carried over: attachments (/Names /EmbeddedFiles, /AF), /Lang, /ViewerPreferences, /OutputIntents

- Not carried over: the tagged structure tree, XMP, and anything tied to page numbers or page references (bookmarks, page labels, named destinations)

- Whatever is lost is reported in warnings — nothing disappears silently

Page specs use "1,3-5,8-" (1-based; -3 means up to page 3, 8- means page 8 to the end). Order is preserved and duplicates are removed.

Editing — adding to and repairing documents
ToolPurpose
set_metadataUpdate Info dictionary fields (title / author / subject / keywords / creator), preserving the rest. On documents carrying XMP, dc:title etc. are kept in sync (PDF/UA and PDF/A declarations preserved). tdmReservation (0 \1) and tdmPolicy write the W3C TDMRep rights statement to XMP (tdm:reservation / tdm:policy, namespace http://www.w3.org/ns/tdmrep/); a document without XMP gets one, and a PDF/A document also gets the schema described in pdfaExtension:schemas, so veraPDF does not fail ISO 19005-2 6.6.2.3 on it (v0.22.0)
add_bookmarksSet the outline (bookmarks); nestable via children, replaces any existing outline
add_annotationAdd a sticky note (text), highlight, or square annotation. On tagged PDFs the annotation is nested in an Annot element and stays PDF/UA conformant — pass alt to describe it. On PDF/UA-2, alt is also written as Contents (§8.9.4.2 requires them to match), and a different contents is refused
attach_fileEmbed a file (/Names /EmbeddedFiles + catalog /AF + /AFRelationship) — the PDF/A-3 shape
stamp_page_numbersStamp page numbers ({n} / {total}, six positions, pages, startAt). Becomes an artifact on tagged PDFs, so conformance holds
fill_formFill AcroForm fields. Japanese values via an embedded font; can flatten in the same pass
flatten_formFlatten a form into static content. Refuses tagged PDFs by default (breaks PDF/UA)
tag_form_fieldsRepair the form inside a tagged PDF for PDF/UA-1 (nest widgets in Form, set /Tabs S, add /TU alternate names; pass labels for human-readable names). On PDF/UA-2, widgets also get /Contents (§8.10.2.3). Idempotent
ensure_taggedPut an existing PDF into the PDF/UA-1 container → Scaffolding an untagged PDF
ensure_pdfaPut an existing PDF into the PDF/A-3b / PDF/A-4 / PDF/A-4f container (flavour) → The archival container
add_watermarkOverlay a diagonal watermark ("社外秘" / "DRAFT"). Behind the body content by default; artifact on tagged PDFs

Shared options: outputPath, returnBase64, allowBreakingSignatures.

[!IMPORTANT]

Editing signed PDFs: an ordinary sa

只显示了开头部分;其余内容请在仓库中阅读