
MTA:SA Documentation MCP Server
io.github.Luminaire1337由 GitHub 账号 Luminaire1337 发布v1.0.3更新于 Oct 24, 2026
MCP server for MTA:SA documentation with intelligent search and caching
概览
本地 MCP 服务器,为助手提供 Multi Theft Auto: San Andreas 函数与事件文档的结构化检索与缓存访问。
- 可以做什么
- 按关键词搜索函数与事件,并支持关键词智能扩展
- 用语义匹配找出适合某项任务的函数或事件
- 获取单个或多个函数的完整文档及代码示例
- 按分类列出函数,并提示已弃用的 API
- 查看或清空本地 SQLite 文档缓存,并获取文档工作流建议
- 适用场景
- 适合在编写或调试 MTA:SA Lua 脚本时使用,让助手直接查询权威的函数与事件文档,而不必手动抓取 wiki。
- 运行要求
- 以 stdio 方式在本机运行;需要 Node.js 24+(Bun 1.3+ 可选)。通过 npm 包 mtasa-docs-mcp 安装,通常用 npx 启动。未声明需要账号、API 密钥或环境变量。抓取文档填充缓存需要网络访问。
安装
在 SourceWeft 中
- 打开 控制台中的 MTA:SA Documentation MCP Server,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
MTA:SA Documentation MCP Server
An MCP (Model Context Protocol) server that gives AI assistants reliable, structured access to Multi Theft Auto: San Andreas documentation.
It combines fast keyword search, semantic matching, and SQLite-backed caching so agents can discover the right APIs and fetch authoritative docs without manual wiki scraping.
Highlights
- 11 MCP tools for discovery, docs retrieval, cache operations, and workflow guidance
- Event-first discovery (
search_events,find_events_for_task) - Semantic task matching with SQLite vector search
- Smart keyword expansion (for example,
database->db*APIs) - Built-in deprecation detection and warnings
- Local SQLite cache with configurable lifetime
- CI verification gates, smoke tests, and release automation
Installation
Requirements:
- Node.js 24+
- Bun 1.3+ (optional runtime)
- pnpm 10+ (for local development)
Launcher note:
- You can launch/install via
npx,pnpx,bunx, or yarn dlx-style flows. - Runtime support is cross-runtime: Node.js (via
node:sqlite) and Bun (viabun:sqlite).
From npm (recommended)
or:
Quick install
[Add mtasa-docs MCP server to Cursor]
From source
If your environment skips optional native dependencies, run:
MCP Client Setup
Cursor (manual)
Global: ~/.cursor/mcp.json
Project: .cursor/mcp.json
VS Code (manual)
Workspace: .vscode/mcp.json
User: Command Palette -> MCP: Open User Configuration
Or add it from terminal:
Claude Code (CLI)
OpenCode (manual)
Global config file: ~/.config/opencode/opencode.json
Antigravity (manual)
Config file: ~/.gemini/antigravity/mcp_config.json
Generic MCP clients (manual)
If mtasa-docs-mcp is already published, replace the command with:
Available Tools
search_functionssearch_eventsfind_functions_for_taskfind_events_for_taskget_function_docsget_multiple_function_docsget_function_exampleslist_functions_by_categoryget_cache_statsrecommend_doc_workflowclear_cache
Development
Useful checks:
pnpm check:versions- keeppackage.jsonand MCP server version alignedpnpm check:changelog- ensureCHANGELOG.mdhas current release headingpnpm check:tool-names- prevent legacy tool naming regressionspnpm test:runtime- run integration runtime tests for Node and Bun smoke pathspnpm smoke:cross-runtime- run smoke checks against both Node and Bun runtimes
Scripts are located in scripts/ (build, smoke, release guards).
Release Flow
Release automation is handled by .github/workflows/release.yml.
- Bump version in
package.jsonandsrc/index.ts. - Move release notes from
Unreleasedinto a versioned section inCHANGELOG.mdusing## [x.y.z] - YYYY-MM-DD. - Create and push a release tag:
git tag v<version> && git push origin v<version>.
Branching policy:
- Before
v1.0.0: direct pushes tomasterare allowed. - Starting at
v1.0.0: use PR-based development for all changes tomaster.
On release tag pushes (v*.*.*), the release workflow:
- checks whether the version already exists on npm
- runs
pnpm verify:full - publishes to npm with provenance using trusted publishing (OIDC)
- publishes
server.jsonto the MCP Registry using GitHub OIDC - creates/updates the GitHub Release from
CHANGELOG.md - verifies installability of the published package and runs smoke tests
Maintainer setup for npm trusted publishing
In npm package settings, configure a trusted publisher for this repository and workflow:
- Repository:
Luminaire1337/mtasa-docs-mcp - Workflow file:
.github/workflows/release.yml - Environment (if used): match your GitHub Actions configuration
Maintainer setup for MCP Registry publishing
- Ensure
server.jsonexists at repository root and uses this package name:mtasa-docs-mcp - Configure MCP Registry ownership for
io.github.Luminaire1337/mtasa-docs-mcp - Release workflow uses
mcp-publisher login github-oidcand publishes only when the npm publish gate passes
CI Workflows
.github/workflows/ci.yml- verification on push/PR tomaster(Ubuntu + macOS) and optional live wiki integration tests on labeled PRs.github/workflows/release.yml- automated publish and GitHub release on release tags (v*.*.*)
Project Docs
AGENTS.md- architecture and contributor guidanceFEATURES.md- roadmap and ideasCHANGELOG.md- release historySECURITY.md- vulnerability disclosure policy
License
GNU General Public License v3.0. See LICENSE.
来源:README.md,提交 2360dcf
工具
0版本历史
1- v1.0.3最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分