AI-Game-Dev-CLI-Core
Shared TypeScript CLI core for the AI Game Dev engine CLIs (Unity / Unreal / Godot) and the
AI Game Developer App's Brutal integration, published to npm as @baizor/gamedev-cli-core via npm Trusted Publishing (OIDC, tokenless).
接入你的智能体
发布者自己的命令。不是 PlugMCP 端点。
用我们的密钥与日志托管一份副本。
npx -y @baizor/[email protected]Claude Code 没有针对本地命令的安装链接。复制下方命令并在终端中运行。
claude mcp add baizor-gamedev-cli-core -- npx -y @baizor/gamedev-cli-core@0.12.0在终端中运行。
{ "mcpServers": { "baizor-gamedev-cli-core": { "command": "npx", "args": [ "-y", "@baizor/[email protected]" ] } }}claude_desktop_config.json
远程 URL 还是本机命令? 两种安装方式的区别
来自发布者
Shared TypeScript CLI core for the AI Game Dev engine CLIs (Unity / Unreal / Godot) and the
AI Game Developer App's Brutal integration, published to npm as @baizor/gamedev-cli-core via npm Trusted Publishing (OIDC, tokenless).
Shared TypeScript CLI core for the AI Game Dev engine CLIs (Unity/Unreal/Godot) and the App's Brutal integration: project identity/pin, OAuth device login, machine credential store, and setup-mcp/install-plugin logic. Consumed as thin adapters by the engi
This package is the single source of truth for CLI logic; the engine CLIs are thin,
engine-specific adapters over it. The shared modules land here through the auth-fixes design
(tasks b2/b3):
Landed (b2 — correctness/security core):
derivePin/derivePort/deriveProjectPathHash (v1) and the
…V2 variants (separator-normalized, the B5 fix), gated byte-for-byte against the SAME golden
vectors as the C# LIB (test/golden-vectors/, vendored from MCP-Plugin-dotnet).MachineCredentialStore at ~/.ai-game-dev/credentials.json,
full MachineCredentials, DPAPI on Windows / 0600 on POSIX, atomic (crash-safe) writes.deviceLogin (RFC 8628, /oauth/device_authorization +
/oauth/token) with token rotation and a clean login required on family-revoke.Landed (b3 — shared modules + the engine-adapter contract):
EngineAdapter (+ unityAdapter / unrealAdapter / godotAdapter /
brutalAdapter),
the single typed seam that carries every per-engine difference: serverName, project markers,
stdioSupported + stdioArgs, the server install-dir layout, loginServerTarget, and the OAuth
clientId. No engine specifics live anywhere else in the package.EditorSession (Code-Exec §4.6): reuse a live editor or start one
headless/windowed with the AIGD_SESSION_* env, a .ai-game-dev/session.json lease (only leased
editors are ever closed; it records the server URL), a per-project heartbeated startup lock that
also serializes an optional beforeLaunch build, and waitForReady / mcpReadinessProbe.JsonAiAgentConfig / TomlAiAgentConfig, byte-for-byte parity with
the C# com.IvanMurzak.McpPlugin.AgentConfig, gated by test/golden-vectors/AgentConfig.GoldenVectors.json,
plus the engine-neutral agentRegistry.setupMcp (async) / resolveSetupMcpPlan: pins the routing URL by
default (/mcp/p/<pin-v2> http, project=<pin> stdio; B4), with a --no-pin escape hatch. A
Cloud http config carries Authorization: Bearer agd_pk_… — a non-expiring project key
bound to the pin — for every client (Codex via http_headers); an explicit --token wins,
oauth: true writes a URL-only config, regenerateKey: true mints a fresh key. stdio and
local-server configs are unchanged.getOrMintProjectKey / regenerateProjectKey / ProjectKeyStore: the
~/.ai-game-dev/project-keys.json cache (DPAPI on Windows / 0600 on POSIX, atomic, unknown
entries preserved) and the POST /api/mcp/project-keys + GET …/current client.resolveInstallTarget: resolves the project path
positional → --path → cwd (B1) then marker-probes it, failing with a message listing exactly
what was checked. Ancestor walk-up is out of scope (M5).runEnroll / redeemEnrollmentCode: writes the v2 pin (the B5 fix replaces the
Unity CLI's local \→/ workaround) and records the AS-root serverTarget, never a pinned
hub URL (b2 review MED-2).downloadServer with a fail-closed SHA256SUMS verify-before-execute gate
and a dependency-free in-process parseZip unzip.Landed (c1/c2 + DCR — desktop browser sign-in):
authCodeLogin (RFC 8252 native app, RFC 7636 PKCE
S256, state CSRF check, an ephemeral 127.0.0.1 loopback listener, RFC 8707 resource),
returning the same MachineCredentials shape as deviceLogin.discoverAuthorizationServer (RFC 8414
/.well-known/oauth-authorization-server, falling back to the hardcoded paths) and
resolveClientRegistration / registerClient (RFC 7591). /oauth/authorize resolves
client_id by an exact registry lookup whose only writer is POST /oauth/register — which mints
its OWN id — so a hardcoded client id is always rejected with invalid_client. The minted id is
persisted per authorization server in ~/.ai-game-dev/oauth-clients.json (ClientRegistrationStore,
same atomic owner-only write as the credential store) and reused on every later launch; only the
loopback port floats, so one registration serves every run. On invalid_client the flow
re-registers exactly once. The device grant deliberately keeps its static client id — the
server binds each refresh-token family to the id used at issue time, so moving it would
invalidate every existing CLI login.Landed (unified-machine-auth c3 — the shared refresher/provider + login plumbing):
MachineCredentialProvider — THE single entry point for credential access + refresh. The
three engine CLIs (W2: d2/e2/f2) and the desktop App (W3) obtain access tokens EXCLUSIVELY via
getAccessToken({family}) / refresh({family}); nothing else re-implements refresh. It is
family-aware over store schema v2 (agent / plugin / legacy planes), runs every refresh
under the cross-process MachineCredentialLock with a double-checked re-read (a peer's
rotation is adopted without a network call), presents the family's stored clientId
(component default ONLY for families.legacy), omits scope/resource on refresh
(P0-3), keeps the previous refresh token when the server does not rotate one, treats
invalid_grant after a post-failure re-read as family death (one structured telemetry event,
other families untouched, never loops), rate-limits to one attempt per family per skew
window, and surfaces busy locks / unreadable stores as typed non-sign-out errors.HttpTokenExchangeClient (the frozen a5 wire shape:
subject_token = fresh agent access token, exact URNs, scope=mcp:plugin,
audience only as the exact urn:agd:hub), deriving the plugin family from the agent family.commitAgentLogin (the F1/F2 two-lock-hold sequence:
agent family under hold 1 → exchange → plugin family + v1 mirror under hold 2; a failed
exchange leaves the committed agent family and a "partially authorized, retrying" state
resumable via derivePluginFamily), commitToolsOnlyLogin (the --tools-only / O10
plugin-only mint for CI — F10), the D6/F7 account-switch guard (evaluateAccountSwitch /
runAccountSwitchGuard; decline revokes the just-minted family and leaves the store
untouched; runEnroll routes through the same guard), signOutMachineWide (F6:
best-effort RFC 7009 revocation of every family, then the lock-guarded store delete), and
revokeTokenBestEffort (RFC 7009). Every commit re-verifies the world under its lock
hold before writing (commitFamilyUnderHold): a guard premise that changed during the
confirm dialog, a subject switched between the two holds, a store deleted by a concurrent
sign-out (never recreated), or a store turned unreadable (never overwritten) each abort with
a typed result — never a throw, never a mixed-account or resurrected
store.A small semver utility slice is also exposed. The package has zero runtime dependencies.
npm install # install dependencies
npm run build # tsc -> dist/ (ESM + .d.ts)
npm test # vitest run
npm run typecheck # tsc --noEmit
Releases are cut from the release.yml GitHub Actions workflow, which publishes to npm over OIDC
(no npm token, no --provenance flag — provenance is attached automatically). Run it from your
machine with the GitHub CLI:
gh workflow run release.yml -f version=X.Y.Z
The workflow enforces the Node >= 22.14.0 / npm >= 11.5.1 floors, sets the package version from the
version input, builds, and publishes.
The npm Trusted Publisher for @baizor/gamedev-cli-core is bound to this exact repo + workflow
(.github/workflows/release.yml). The publish step lives directly in that workflow file — it is
not factored into a reusable workflow, because reusable-workflow bindings are a known npm TP
limitation for workflow_dispatch.
MIT © Ivan Murzak
Shared TypeScript CLI core for the AI Game Dev engine CLIs (Unity/Unreal/Godot) and the App's Brutal integration: project identity/pin, OAuth device login, machine credential store, and setup-mcp/inst
{ "mcpServers": { "baizor-gamedev-cli-core": { "command": "npx", "args": [ "-y", "@baizor/[email protected]" ] } }}概览
Shared TypeScript CLI core for the AI Game Dev engine CLIs (Unity/Unreal/Godot) and the App's Brutal integration: project identity/pin, OAuth device login, machine credential store, and setup-mcp/install-plugin logic. Consumed as thin adapters by the engi
工具
暂无工具列表。远程服务器在首次健康检查后会获得工具列表。
常见问题
在本页复制适用于 Cursor、Claude Desktop、Claude Code 或 VS Code 的 stdio 配置。它使用发布者的安装方式,而不是 PlugMCP 代理。
CommitAbortReason此记录未列出必需的环境变量。
@baizor/gamedev Cli Core 通过 stdio 在本地运行。
上次检查时间:2026-11-16。 Shared TypeScript CLI core for the AI Game Dev engine CLIs (Unity/Unreal/Godot) and the App's Brutal integration: project identity/pin, OAuth device login, machine credential store, and setup-mcp/install-plugin logic. Consumed as thin adapters by the engi