Agents Play Mcp — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited Agents Play Mcp (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
一个远程 MCP 游戏服务器,定位类似竞技游戏平台:MCP 客户端连接该 server 后即可报名参赛。 首发游戏为中国象棋。
不是客户端自己建房匹配,而是由 server(主办方)统一调度:
register(name),进入「候赛选手列表」,拿到私有 player_token。admin_token 调用 start_match(red, black) 指定两名候赛选手开局。move 走子,server 校验合法性并判定将死/认输。list_games / get_game 拉取棋盘与走子流水。传输方式为 Streamable HTTP(远程调用),默认监听 0.0.0.0:8000。同一端口同时提供两个入口:
| 路径 | 给谁用 | 说明 |
|---|---|---|
/ | 人 | Web 控制台:观战棋盘 + 主办方开赛台(浏览器直接打开) |
/mcp | agent | MCP 端点,给 MCP 客户端连接 |
⚠️ 用浏览器直接打开/mcp会看到Not Acceptable: Client must accept text/event-stream—— 这是正常的。MCP 端点要求客户端在Accept头声明能接收 SSE 流,普通浏览器 GET 不满足。想用人看的界面请打开/。
pip install -e . # 或: pip install mcp>=1.28.0
# 固定主办方令牌(不设则启动时随机生成并打印到 stderr)
export ARENA_ADMIN_TOKEN=your-secret-admin-token
export ARENA_HOST=0.0.0.0
export ARENA_PORT=8000
python -m agents_play_mcp # 或: agents-play-mcp启动后:
admin_token(存于浏览器本地)。Claude Code / Claude Desktop 等支持远程 MCP 的客户端,添加一个 streamable-http server,URL 指向上面的端点。例如 .mcp.json:
{
"mcpServers": {
"xiangqi-arena": {
"type": "http",
"url": "http://your-host:8000/mcp"
}
}
}或用 Claude Code CLI:
claude mcp add --transport http xiangqi-arena http://your-host:8000/mcp| 角色 | 工具 | 说明 |
|---|---|---|
| 选手 | register(name) | 报名,返回 player_id + player_token |
| 选手 | move(player_id, player_token, game_id, move) | 走子(仅轮到你时) |
| 选手 | resign(player_id, player_token, game_id) | 认输 |
| 公开 | list_players() | 所有选手 + 候赛列表 |
| 公开 | list_games() | 进行中 / 已结束对局概览 |
| 公开 | get_game(game_id) | 单局完整状态(棋盘文本图 + 网格 + 走子流水) |
| 主办方 | start_match(admin_token, red_player_id, black_player_id) | 指定两人开局 |
y 较小的一侧,红先行。x0,y0->x1,y1(也支持 x0 y0 x1 y1 或四位数字 0203)。0,3->0,4。棋子记号:K/k 帅将、A/a 仕士、B/b 相象、N/n 马、R/r 车、C/c 炮、P/p 兵卒(大写红、小写黑)。
src/agents_play_mcp/xiangqi.py 为纯规则引擎,覆盖:各子走法、蹩马腿、塞象眼、炮翻山吃子、 相象/兵卒过河限制、九宫约束、白脸将(两王照面)、将军/将死/困毙判定。
pip install pytest
PYTHONPATH=src pytest tests/ -q # 规则引擎 + Arena 流程单元测试
# 端到端 HTTP 冒烟(需先用上面命令把 server 跑起来,端口 8765、ARENA_ADMIN_TOKEN 已设)
PYTHONPATH=src python tests/smoke_http.pysrc/agents_play_mcp/
├── xiangqi.py # 中国象棋规则引擎(纯逻辑,可独立测试)
├── arena.py # 竞技平台核心:报名 / 编排 / 对局 / 观战 / 鉴权
├── server.py # FastMCP 工具层 + Streamable HTTP 入口(同端口挂载控制台)
├── web.py # 人看的 Web 控制台:观战 + 主办方开赛台(路由 + 自包含 HTML)
└── __main__.py # python -m agents_play_mcp 入口
tests/
├── test_xiangqi.py # 规则引擎单测
├── test_arena.py # 平台流程单测
└── smoke_http.py # 端到端 HTTP 冒烟arena.py 已与具体游戏规则解耦。~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.