a1-yandex-kit-setup
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseA1 Yandex KIT Setup
A1 Yandex KIT 设置
Communication
沟通规范
Before producing any user-facing message, read and apply
completely.
../a1-yandex-kit/references/merchant-communication.mdMake setup a concierge flow for typed requests and voice transcriptions alike.
Start from the branch that invoked it:
- For the short orientation request , ask one question:
Связь с магазиномЧто сделать: подключить магазин или переподключить его с новым токеном? - A concrete request to connect or reconnect authorizes updating the selected client's user-level MCP configuration after the required inputs are collected and the candidate token passes validation. Reinstalling the connection and changing the token are both reconnection requests.
A project-local skill installation does not limit the configuration to that
project.
Use for configuration and the direct read-only smoke test.
Resolve every relative path from this skill directory, not from the user's
project.
scripts/setup.mjs在生成任何面向用户的消息之前,请完整阅读并应用中的内容。
../a1-yandex-kit/references/merchant-communication.md为打字请求和语音转录请求都设置管家式流程。从触发该流程的分支开始:
- 对于简短的导向性请求(连接商店),询问一个问题:
Связь с магазином您需要执行什么操作:连接商店还是使用新Token重新连接? - 明确的连接或重新连接请求,在收集完必要输入且候选Token通过验证后,授权更新所选客户端的用户级MCP配置。重新建立连接和更换Token均属于重新连接请求。
项目本地的Skill安装不会将配置限制在该项目内。
使用进行配置和直接只读冒烟测试。所有相对路径均从本Skill目录解析,而非用户项目目录。
scripts/setup.mjs1. Identify the client and prerequisite
1. 识别客户端与前置条件
Infer the current client from the host when it is clear. Otherwise ask one short
question:
В каком приложении вы сейчас хотите подключить Яндекс KIT?Normalize the answer to one of:
claude-codeclaude-desktopcursorcodexvscodekimikimi-desktophermesopenclawTreat Kimi Code and Kimi Desktop as different clients. Use only for the
Kimi Code CLI and for the Kimi Work desktop application. When
the user says only “Kimi” and the host does not disambiguate it, ask:
kimikimi-desktopВы используете приложение Kimi на компьютере или Kimi Code в терминале?For a tested client, run:
bash
node "<skill-directory>/scripts/setup.mjs" status --client <client> --jsonstatusnpxFor Claude Code, Cursor, VS Code and Kimi Code, also checks whether a
known project- or local-scope server named would override the
user-level entry. On an exact-name collision it selects the managed fallback
name . It ignores every differently named MCP server. A
previously configured canonical fallback stays selected on later runs.
statusyandex-kita1-yandex-kit-globalbash
node "<skill-directory>/scripts/setup.mjs" preflight --jsonRun later only when the ladder establishes a supported format and path.
This step is complete when Node.js 20+, and one client are identified.
statusnpx当主机信息明确时,从中推断当前客户端。否则询问一个简短问题:
您现在想要在哪个应用中连接Yandex KIT?将答案标准化为以下选项之一:
, , , , , , , , 。
claude-codeclaude-desktopcursorcodexvscodekimikimi-desktophermesopenclaw将Kimi Code和Kimi Desktop视为不同的客户端。仅用于Kimi Code CLI,用于Kimi Work桌面应用。当用户仅提及“Kimi”且主机未明确区分时,询问:
kimikimi-desktop您使用的是电脑上的Kimi应用还是终端中的Kimi Code?对于已测试的客户端,运行:
bash
node "<skill-directory>/scripts/setup.mjs" status --client <client> --jsonstatusnpx对于Claude Code、Cursor、VS Code和Kimi Code,命令还会检查是否存在名为的项目级或本地作用域服务器,该服务器可能会覆盖用户级条目。如果存在完全同名的冲突,将选择托管备用名称。忽略所有名称不同的MCP服务器。之前配置的标准备用名称在后续运行中会保持选中状态。
statusyandex-kita1-yandex-kit-globalbash
node "<skill-directory>/scripts/setup.mjs" preflight --json仅当兼容性阶梯确定了受支持的格式和路径后,才会再次运行命令。当Node.js 20+、和一个客户端均已识别完成时,本步骤结束。
statusnpx2. Validate the compatibility profile
2. 验证兼容性配置文件
Read for the
selected client. Check the installed client's version or MCP help when its CLI is
available, and check that the resolved user-level path and configuration shape
match the local installation.
references/client-profiles.mdUse the tested profile when those signals agree. On a mismatch, an unknown
client, or a client not listed above, read
completely and run
its compatibility ladder. This step is complete when the chosen adapter is
supported by local evidence or current official vendor documentation.
references/compatibility.md为所选客户端阅读。当客户端CLI可用时,检查已安装客户端的版本或MCP帮助信息,并确认解析后的用户级路径和配置结构与本地安装匹配。
references/client-profiles.md当这些信号一致时,使用已测试的配置文件。如果出现不匹配、未知客户端或上述未列出的客户端,请完整阅读并运行其兼容性阶梯。当所选适配器得到本地证据或当前官方供应商文档支持时,本步骤结束。
references/compatibility.md3. Obtain the token
3. 获取Token
Use the result without reading or displaying the stored token.
For a native CLI without a supported file adapter, use its documented
list/show command: treat an existing managed or
entry as without attempting to read its
token.
statusyandex-kita1-yandex-kit-globalconfigured: true- When is false, ask:
configuredДля настройки потребуется токен Яндекс KIT. Чтобы его получить, зайдите в кабинет Яндекс KIT: Настройки → API и скопируйте ключ. Вставьте его сюда — я привяжу его к приложению и не буду повторять в ответе. Токен останется в истории этого чата и будет сохранён в пользовательском конфиге приложения. - When is true, continue from the selected branch:
configured- For reconnection, including reinstallation or token replacement, ask:
Пришлите новый токен из **Настройки → API** — я обновлю подключение и не буду повторять его в ответе. Новый токен останется в истории этого чата и будет сохранён в пользовательском конфиге приложения. - For a first-connection request when a token is already configured, ask:
Токен Яндекс KIT уже сохранён в настройках. Хотите переподключить магазин с новым токеном?- For , finish with:
нетПринято! Оставляем действующий токен Яндекс KIT без изменений. Всё работает в прежнем режиме. - For , use the reconnection prompt above.
да
- For
- For reconnection, including reinstallation or token replacement, ask:
Accept the token in chat. Do not echo, summarize, quote, log or interpolate it
into a shell command. Pass a new token only through stdin to : write
the token followed by one newline. The first newline terminates the input, so
the helper starts immediately and never waits for the stdin pipe to close;
closing stdin after the newline is also safe.
setup.mjsBefore writing any new or replacement token, validate it with the direct
read-only MCP smoke test:
bash
node "<skill-directory>/scripts/setup.mjs" smoke-token --token-stdin --jsonsmoke-tokensmokemcp-yandex-kit@latestget_storecode: "NETWORK_UNAVAILABLE"If authentication fails (), ask for another token with the
replacement-token prompt and repeat this validation until it succeeds or the
user explicitly cancels. Do not impose a retry limit. Because configuration has not started,
cancellation leaves the current client settings unchanged. Treat other smoke
failures as their own diagnostics instead of asking for a different token.
code: "SMOKE_AUTH"This step is complete when one candidate token has passed . The
explicit branch for an existing first connection finishes the skill
without reaching this point.
get_storeнет使用命令的结果,无需读取或显示已存储的Token。对于没有受支持文件适配器的原生CLI,使用其文档中列出的查看命令:将已存在的托管或条目视为,无需尝试读取其Token。
statusyandex-kita1-yandex-kit-globalconfigured: true- 当为false时,询问:
configured配置需要Yandex KIT Token。获取方式:登录Yandex KIT后台 → 设置 → API,复制密钥。请在此处粘贴Token,我会将其绑定到应用中,且不会在回复中重复显示。Token将保留在此聊天记录中,并保存到应用的用户配置中。 - 当为true时,根据所选分支继续:
configured- 对于重新连接请求(包括重新建立连接或更换Token),询问:
请发送来自**设置 → API**的新Token,我会更新连接,且不会在回复中重复显示。新Token将保留在此聊天记录中,并保存到应用的用户配置中。 - 对于首次连接请求但Token已配置的情况,询问:
Yandex KIT Token已保存到设置中。是否要使用新Token重新连接商店?- 如果用户回复(否),结束流程并回复:
нет已确认!保留当前Yandex KIT Token不变,所有功能将正常运行。 - 如果用户回复(是),使用上述重新连接提示。
да
- 如果用户回复
- 对于重新连接请求(包括重新建立连接或更换Token),询问:
在聊天中接收Token。不要回显、总结、引用、记录或将其插入到shell命令中。仅通过标准输入(stdin)将新Token传递给:写入Token后换行。第一个换行符将终止输入,因此助手会立即启动,无需等待stdin管道关闭;换行后关闭stdin也是安全的。
setup.mjs在写入任何新Token或替换Token之前,通过直接只读MCP冒烟测试验证其有效性:
bash
node "<skill-directory>/scripts/setup.mjs" smoke-token --token-stdin --jsonsmoke-tokensmokemcp-yandex-kit@latestget_storecode: "NETWORK_UNAVAILABLE"如果验证失败(),使用替换Token提示请求新的Token,并重复此验证步骤直到成功或用户明确取消。不要设置重试次数限制。由于配置尚未开始,取消操作不会改变当前客户端设置。将其他冒烟测试失败视为独立诊断问题,而非请求不同Token。
code: "SMOKE_AUTH"当一个候选Token通过验证时,本步骤结束。对于已存在Token的首次连接请求,用户回复的分支会在到达此点前结束Skill流程。
get_storeнет4. Configure the user-level client
4. 配置用户级客户端
For a new or replacement token, run the helper in an interactive process and
write the token followed by a newline to its stdin; the newline completes the
input, so the helper does not wait for the pipe to close:
bash
node "<skill-directory>/scripts/setup.mjs" configure --client <client> --token-stdin --jsonFor a dynamically discovered native CLI, follow
and run
. The helper reads the token from stdin, substitutes it into
the documented child-process arguments, keeps it out of the agent-issued shell
command and shell history, and redacts it from output.
references/compatibility.mdnative-configureFor a dynamically discovered file adapter, also pass its verified capability
and path:
bash
node "<skill-directory>/scripts/setup.mjs" configure --client <label> --format <format> --config <absolute-path> --token-stdin --jsonIn either route, the canonical server is always:
text
npx -y mcp-yandex-kit@latestOnly add or update the selected managed entry. Preserve every differently named
MCP server and every unrelated client setting. Do not remove, rename, disable or
rewrite another server. When an exact project/local entry shadows
the user-level name, leave that entry unchanged and configure
instead.
yandex-kita1-yandex-kit-globalUse the concrete setup request selected at the start as the configuration
authorization and surface only the host application's unavoidable filesystem
approval. If an existing config cannot be parsed safely, leave it unchanged and
return to the compatibility ladder to try the client's documented native CLI.
Give the technical handoff only when the native route is also unavailable or
fails.
For a file adapter, this step is complete when the helper reports
, the token is present without being printed, unrelated
client settings remain intact, and a backup exists for every changed
pre-existing config. On POSIX systems, the changed config and its backup must
have mode . For a native CLI, this step is complete when the documented
add command exits successfully; the client owns its configuration mutation.
configured: true0600对于新Token或替换Token,在交互式进程中运行助手,并将Token写入其标准输入后换行;换行符会完成输入,因此助手无需等待管道关闭:
bash
node "<skill-directory>/scripts/setup.mjs" configure --client <client> --token-stdin --json对于动态发现的原生CLI,请遵循并运行命令。助手会从stdin读取Token,将其替换为文档化的子进程参数,确保Token不会出现在Agent发出的shell命令和shell历史中,并在输出中对其进行脱敏处理。
references/compatibility.mdnative-configure对于动态发现的文件适配器,还需传递其已验证的功能和路径:
bash
node "<skill-directory>/scripts/setup.mjs" configure --client <label> --format <format> --config <absolute-path> --token-stdin --json无论采用哪种方式,标准服务器始终为:
text
npx -y mcp-yandex-kit@latest仅添加或更新所选的托管条目。保留所有名称不同的MCP服务器和所有无关的客户端设置。不要删除、重命名、禁用或重写其他服务器。当存在完全同名的项目/本地条目覆盖用户级名称时,保留该条目不变,转而配置。
yandex-kita1-yandex-kit-global使用流程开始时选择的具体设置请求作为配置授权,仅显示主机应用不可避免的文件系统审批提示。如果现有配置无法安全解析,保留其不变并返回兼容性阶梯,尝试客户端的文档化原生CLI。仅当原生路由也不可用或失败时,才提供技术交接。
对于文件适配器,当助手报告、Token已存在且未被打印、无关客户端设置保持不变、每个已修改的现有配置都有备份时,本步骤结束。在POSIX系统上,修改后的配置及其备份必须具有权限。对于原生CLI,当文档化的添加命令成功退出时,本步骤结束;客户端负责其配置变更。
configured: true06005. Prove the connection
5. 验证连接
For a tested client, run the client check:
bash
node "<skill-directory>/scripts/setup.mjs" client-check --client <client> --jsonTreat as the expected client check for GUI clients without a
non-interactive MCP diagnostic. For a dynamic adapter, run the client-level
verification established from its official documentation.
structuralThe client check must verify the effective managed definition, not merely that
its name appears in a list. If a locally changed client path or precedence rule
still causes , configure the same validated token once under
by passing
to , and .
Leave the shadowing project entry and all other MCP servers unchanged.
SERVER_SHADOWEDa1-yandex-kit-global--server-name a1-yandex-kit-globalconfigureclient-checksmokeFor a file adapter, then run:
bash
node "<skill-directory>/scripts/setup.mjs" smoke --client <client> --jsonRepeat the verified and flags for a dynamic adapter.
For a native CLI without a supported file adapter, use the successful direct
smoke from step 3 and do not run the file-based command.
The smoke test must complete the MCP initialize handshake, list tools, find
, and call only . It must not call any write tool.
--format--configsmoke --clientget_storeget_storeIf the tested profile fails because its path, schema or client command changed,
restore only this run's change when reported , then
execute the dynamic compatibility branch. For a pre-existing config, use every
rollback value returned by that configure run:
configurechanged: truebash
node "<skill-directory>/scripts/setup.mjs" rollback --config <configPath> --backup <backupPath> --backup-hash <backupHash> --expected-hash <configHash> --jsonWhen this run created the config, use:
bash
node "<skill-directory>/scripts/setup.mjs" rollback --config <configPath> --created --expected-hash <configHash> --jsonIf the hash check refuses rollback, preserve the newer config and report its
path. If a post-write check reports authentication failure, roll back this run's
file change when one exists, then return to the unlimited token-validation loop
in step 3. If the config is malformed, do not repair it; try the documented
native CLI before using the technical handoff.
This step is complete only when the client check passes and the direct MCP
smoke test has passed during this run.
对于已测试的客户端,运行客户端检查:
bash
node "<skill-directory>/scripts/setup.mjs" client-check --client <client> --json对于没有非交互式MCP诊断功能的GUI客户端,将视为预期的客户端检查结果。对于动态适配器,运行从其官方文档确定的客户端级验证。
structural客户端检查必须验证有效的托管定义,而不仅仅是其名称出现在列表中。如果本地修改的客户端路径或优先级规则仍导致,通过向、和命令传递,在下配置相同的已验证Token。保留产生遮蔽的项目条目和所有其他MCP服务器不变。
SERVER_SHADOWEDconfigureclient-checksmoke--server-name a1-yandex-kit-globala1-yandex-kit-global对于文件适配器,然后运行:
bash
node "<skill-directory>/scripts/setup.mjs" smoke --client <client> --json对于动态适配器,重复使用已验证的和参数。对于没有受支持文件适配器的原生CLI,使用步骤3中成功的直接冒烟测试,无需运行基于文件的命令。冒烟测试必须完成MCP初始化握手、列出工具、找到并仅调用。不得调用任何写入工具。
--format--configsmoke --clientget_storeget_store如果已测试的配置文件因路径、架构或客户端命令变更而失败,当报告时,仅恢复本次运行的变更,然后执行动态兼容性分支。对于预先存在的配置,使用该configure运行返回的所有回滚值:
configurechanged: truebash
node "<skill-directory>/scripts/setup.mjs" rollback --config <configPath> --backup <backupPath> --backup-hash <backupHash> --expected-hash <configHash> --json如果本次运行创建了配置,使用:
bash
node "<skill-directory>/scripts/setup.mjs" rollback --config <configPath> --created --expected-hash <configHash> --json如果哈希检查拒绝回滚,保留较新的配置并报告其路径。如果写入后检查报告验证失败,当存在本次运行的文件变更时回滚该变更,然后返回步骤3中的无限Token验证循环。如果配置格式错误,不要修复它;在使用技术交接前尝试文档化的原生CLI。
仅当客户端检查通过且直接MCP冒烟测试在本次运行中通过时,本步骤结束。
6. Offer work without host stops
6. 提供无主机中断的工作模式
After the connection is proved, read
completely.
Use the same branch when the user reports repeated prompts during an
import, even if the store was connected earlier.
references/approval-policies.mdAllowInspect the current client's capability, state that the grant covers every
current and future Yandex KIT tool, and ask once whether to enable Работу без
остановок on this computer. After , apply the managed server wildcard.
The warning must name deletes, orders, promotions and store administration
before consent. Do not ask again for individual tools added later.
даThis step is complete when the helper reports , or
, and the user knows any remaining restart or UI action before
work starts.
automaticguidedunsupported连接验证通过后,请完整阅读。当用户报告在导入过程中反复出现“Allow”提示时,即使商店之前已连接,也使用相同分支处理。
references/approval-policies.md检查当前客户端的功能,说明授权涵盖所有当前和未来的Yandex KIT工具,并询问一次是否在该计算机上启用无中断工作模式。用户回复(是)后,应用托管服务器通配符。在用户同意前,必须警告该模式涉及删除、订单、促销和商店管理操作。后续添加新工具时无需再次询问。
да当助手报告、或,且用户了解工作开始前任何剩余的重启或UI操作时,本步骤结束。
automaticguidedunsupported7. Finish simply
7. 简洁收尾
Reload MCP automatically only when the validated client exposes a documented
non-interactive reload command. Otherwise give the single restart instruction
from ; do not force-close the application.
references/client-profiles.mdEnd with one short result, for example:
Готово — Яндекс KIT подключён к Cursor. Проверка прошла: вижу магазин «Название».Do not show configuration contents, token fragments, diagnostic dumps or
additional terminal commands. Setup is complete when the user sees the selected
client, a successful store check, and at most one necessary restart action.
仅当已验证的客户端提供文档化的非交互式重载命令时,才自动重新加载MCP。否则,提供中的单一重启指令;不要强制关闭应用。
references/client-profiles.md以简短结果结束流程,例如:
完成 — Yandex KIT已连接至Cursor。验证通过:已检测到商店«名称»。不要显示配置内容、Token片段、诊断转储或额外的终端命令。当用户看到所选客户端、成功的商店检查结果以及最多一个必要的重启操作时,设置流程完成。