Skip to content

MCP tools

《夜如何》MCP server 目前暴露 10 个 tool,按玩家 flow 顺序列出。所有 tool 元数据由 scripts/export_tools_md.tssrc/mcp/tools/*.tsregisterXxx 直接抽出,跟 server 的 tools/list 响应严格同源。

机器可读版:/tools.json(含完整 JSON Schema)。

start_run

Start a new run

New Shuran run: identifier and any carried relic.

Input:

字段类型必填说明
carried_relic_iduuid | null

open_night

Open a new night in daytime phase

New night in daytime phase for white-day actions before entering speaking.

Input:

字段类型必填说明
run_iduuid

start_night

Enter speaking phase

Locked oil cap and speaking-phase state for tonight (transitions daytime → speaking).

Input:

字段类型必填说明
run_iduuid
night_iduuid

daytime_action

Daytime action

Daytime move record (打听 / 播种 / 交换 / 布置) with resulting reward, if any.

Input:

字段类型必填说明
run_iduuid
night_iduuid
action_typeenum: 打听 | 播种 | 交换 | 布置
targetstring (0..200)
payloadobject

speak_to_king

Speak to the King

One narrative turn: King's reply, oil accounting, forced-dawn signal.

Input:

字段类型必填说明
run_iduuid
night_iduuid
textstring (1..4000)narrative text from Shuran for this turn

bring_relic

Bring a relic to the King tonight

Presentation event of a relic before the King tonight.

Input:

字段类型必填说明
run_iduuid
night_iduuid
relic_iduuid

use_continue_lamp

Use one continue-lamp charge

Continue-lamp charge consumption: new oil cap and remaining lamps.

Input:

字段类型必填说明
run_iduuid
night_iduuid

end_night

Reach dawn

Dawn verdict for tonight: survival, concepts, cheats, relic mutations.

Input:

字段类型必填说明
run_iduuid
night_iduuid

list_relics

List relics owned by this player

Relics alive under this account, each with name / origin / current meaning.

Input: none

get_state

Snapshot of current run and night

Snapshot of the run and current night; welcome and tools flow when run_id omitted.

Input:

字段类型必填说明
run_iduuid
night_iduuid

响应体里每个 tool 都带 next_step 中文引导字段(list_relics 除外——那是纯 array)。玩家侧 AI 遵循 next_step 即可跑完整 flow。

早期开发阶段 —— 一切规则、工具、Skill 均可能变。