Farm.js Docs

dev.farmjs由 farmjs.dev 发布官方发布者v0.1.28更新于 Oct 26, 2026

Search and read the Farm.js docs: pages, sections, code examples and config options.

已验证Streamable HTTP可网页运行知识与记忆开发者工具

概览

AI 生成的概览

Farm.js 官方文档的远程 MCP 端点,让助手搜索、浏览并阅读文档页面、章节、代码示例和配置选项。

可以做什么
  • 按关键词搜索文档,可按框架、版本、包和标签筛选,并可先列出可用筛选面
  • 列出文档页面与章节,或获取导航树,无需拉取页面正文
  • 读取单个页面、指定标题,或一次读取最多 20 个页面并受 token 预算限制
  • 获取围栏代码示例和结构化的 docs.config.ts 选项元数据
  • 为查询构建章节级上下文,附带来源网址与统计元数据
  • 通过轮询元数据跟踪文档变更,再补取新增或修改的章节
适用场景
适合在编写或调试 Farm.js 代码时让助手获取准确、最新的 Farm.js 文档,或需要跟随文档变更并遵循页面级智能体任务契约的场景。
运行要求
需要访问 mcp.farmjs.dev 的远程 streamable HTTP 端点;未声明任何软件包、环境变量、请求头或身份验证。需要能访问该端点的网络。
安装前请注意
反馈工具会把机器可读的载荷发送到文档站点,并按站点配置的模式校验;请勿在反馈中包含密钥或私密信息。其余工具为只读。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Farm.js Docs,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Web executable,通过 Streamable HTTP。 远程服务在工作区中配置后即可从网页运行时运行。

交给智能体安装

把这段提示词粘贴到 Claude Code、Codex、Cursor 等智能体,或 SourceWeft 对话中。智能体会读取该服务器的安装指南,先向你展示发布者、端点和登录方式,经你同意后再把它添加到你的客户端。密钥不会写进任何命令。

阅读 https://sourceweft.com/mcp/dev.farmjs%2Fdocs/install.md,并按其中说明把这个 MCP 服务器接入我的客户端。修改任何配置之前,先告诉我它的发布者、端点和登录方式,等我确认。不要把 API 密钥写进命令或我会提交的文件;问我密钥应从哪里获取。

查看智能体所依据的安装指南

其他 MCP 客户端

把它添加到你客户端的 mcpServers 配置中。

{
  "mcpServers": {
    "farm-js-docs": {
      "type": "http",
      "url": "https://mcp.farmjs.dev/mcp"
    }
  }
}

README

Farm.js Docs (farmjs-docs)

Official documentation site for Farm.js, built with Farm.js.

Run locally

From the repo root:

bash
pnpm installpnpm run --filter farmjs-docs dev

Or from this directory (after pnpm install from root):

bash
pnpm dev

Open http://localhost:3000.

Agent waitlist database

The /agents form posts to /api/waitlist. WaitlistEntry in prisma/schema.prisma stores the normalized email (unique), signup description, and creation/update timestamps. Repeat submissions update that record instead of creating duplicates.

Set a server-only WAITLIST_DATABASE_URL in docs/.env.local for a dedicated Postgres database. Never prefix it with VITE_ or commit the credential. When omitted, the route continues to use DATABASE_URL; telemetry always keeps using DATABASE_URL.

From docs, prepare a new dedicated database once:

bash
pnpm db:waitlist

This requires WAITLIST_DATABASE_URL explicitly and only creates the WaitlistEntry table when it is absent. It never resets a database or modifies telemetry tables. Keep prisma/waitlist.sql aligned with the Prisma model for future schema changes; the bootstrap does not upgrade an existing table.

For production, set WAITLIST_DATABASE_URL on the Vercel project serving farmjs.dev, scoped to Production, then deploy the updated app. Do not replace the existing telemetry DATABASE_URL or give PR previews access to the production waitlist. Apply the bootstrap against that same database before the deployment accepts signups; schema changes are not run automatically during builds.

Farm development loads .env.local. To run a locally built Node output from the repo root:

bash
node --env-file=docs/.env.local docs/.farm/.output/server/index.mjs

Build

From the repo root:

bash
pnpm run --filter farmjs-docs build

The production Vercel artifact is written to .vercel/output.

Runtime-only core build

The documentation-site build opts into @farm.js/core's runtime-only package build:

bash
pnpm --filter @farm.js/core build:runtime

This builds the same ESM, CJS, and source-map artifacts as the default core build, but skips TypeScript declaration generation because the deployed website does not consume .d.ts files. The optimization applies to the complete farmjs.dev application, including the landing page and documentation routes.

The regular package and release build remains the default and continues to generate declarations:

bash
pnpm --filter @farm.js/core build

Use build:runtime only for application deployments that need executable runtime artifacts. Do not use it for package publishing, release validation, or any workflow that consumes generated types.

Structure

  • Landing (/) – Hero, features, and CTAs
  • Docs (/docs) – Documentation index
  • Getting Started (/docs/getting-started) – Installation and first steps
  • Routing (/docs/routing) – File-based routing
  • Layouts (/docs/layouts) – Root and nested layouts

来源:docs/README.md,提交 be34e74

工具

16

get_code_examples

Get docs code examples

Return fenced code examples from the docs with parsed metadata such as title, framework, packageManager, and runnable.

输入参数pathlimitquerylocalelanguagerunnableframeworkpackageManager

get_config_schema

Get docs config schema

Return structured docs.config.ts option metadata, optionally filtered by option path or query.

输入参数queryoption

get_context

Get budgeted docs context

Build deterministic, section-level documentation context for a query within a conservative UTF-8 byte ceiling derived from the requested token budget, with source URLs and accounting metadata.

输入参数tagsquery必填localepackageversionframeworktokenBudget

get_navigation

Get docs navigation

Return the documentation navigation tree for the current docs site.

输入参数locale

hydrate_content_changes

Hydrate docs content changes

Fetch only added and changed agent-facing sections after list_content_changes. Returns deletion tombstones and digest-bound continuation cursors under a conservative token budget.

输入参数since必填cursorlocaletokenBudget

list_content_changes

List docs content changes

Synchronize body-free document metadata. Save indexGeneration and pass it as since on the next poll. A reset response means the named snapshot is no longer available.

输入参数sincelocale

list_docs

List docs by section

List documentation pages grouped by section, optionally narrowed to one section.

输入参数cursorlocalesection

list_page_sections

List sections in a docs page

Discover a page's canonical headings, anchors, hierarchy, line ranges, size estimates, and budget-aware fetch URLs without returning the page body.

输入参数path必填cursorlocalebyteBudgettokenBudget

list_pages

List docs pages

List the known documentation pages with titles, slugs, and URLs.

输入参数cursorlocale

list_search_facets

List documentation search facets

List valid framework, version, package, and tag filters with matching page counts before calling search_docs. Use facet, limit, and cursor to continue a large facet without document bodies.

输入参数tagsfacetlimitcursorlocalepackageversionaudienceframework

list_tasks

List documented tasks

List pages with actionable agent contracts, optionally filtered by text or applicability.

输入参数querycursorlocalepackageversionframework

read_page

Read a docs page

Read a documentation page by slug or URL path, optionally selecting one heading and limiting returned characters.

输入参数path必填localesectionmaxChars

read_pages

Read several docs pages

Read up to 20 documentation pages in one round trip. Results preserve request order and share a conservative UTF-8 token budget.

输入参数paths必填localetokenBudgetmaxCharsPerPage

read_task

Read a documented task

Read the full structured agent contract for a page by slug or URL path.

输入参数path必填localesectionmaxChars

search_docs

Search documentation

Search the docs by keyword with optional framework, version, package, and tag filters. Returns structured ambiguity and metadata warnings.

输入参数tagslimitquery必填cursorlocaleexplainpackageversionaudienceframework

submit_feedback

Submit documentation feedback

Submit machine-readable documentation feedback. The payload is validated against the site's configured agent feedback schema before delivery.

输入参数contextpayload必填

版本历史

1
  1. v0.1.28最新Oct 20, 2026

评分

已满足适用检查项的 100%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通必需25 分
  • 已声明认证方式必需10 分
  • 已列出工具必需15 分
  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分