@cyanheads/mcp-ts-core 0.9.9 → 0.9.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CLAUDE.md +3 -2
- package/README.md +4 -4
- package/biome.json +1 -1
- package/changelog/0.9.x/0.9.10.md +37 -0
- package/changelog/0.9.x/0.9.11.md +38 -0
- package/changelog/template.md +8 -0
- package/dist/cli/init.js +16 -3
- package/dist/cli/init.js.map +1 -1
- package/dist/logs/combined.log +4 -0
- package/dist/logs/error.log +2 -0
- package/dist/logs/interactions.log +0 -0
- package/dist/mcp-server/transports/http/httpErrorHandler.d.ts.map +1 -1
- package/dist/mcp-server/transports/http/httpErrorHandler.js +27 -6
- package/dist/mcp-server/transports/http/httpErrorHandler.js.map +1 -1
- package/dist/mcp-server/transports/http/httpTransport.d.ts.map +1 -1
- package/dist/mcp-server/transports/http/httpTransport.js +29 -4
- package/dist/mcp-server/transports/http/httpTransport.js.map +1 -1
- package/package.json +9 -9
- package/skills/code-simplifier/SKILL.md +130 -0
- package/skills/design-mcp-server/SKILL.md +72 -2
- package/skills/git-wrapup/SKILL.md +2 -3
- package/skills/maintenance/SKILL.md +2 -1
- package/skills/orchestrations/SKILL.md +217 -0
- package/skills/orchestrations/workflows/field-test-fix.md +206 -0
- package/skills/orchestrations/workflows/fix-wrapup-release.md +175 -0
- package/skills/orchestrations/workflows/greenfield-build.md +143 -0
- package/skills/orchestrations/workflows/maintenance-release.md +171 -0
- package/skills/polish-docs-meta/SKILL.md +27 -6
- package/skills/release-and-publish/SKILL.md +5 -4
- package/skills/report-issue-framework/SKILL.md +4 -1
- package/templates/.claude-plugin/plugin.json +20 -0
- package/templates/.codex-plugin/mcp.json +9 -0
- package/templates/.codex-plugin/plugin.json +25 -0
- package/templates/AGENTS.md +11 -0
- package/templates/CLAUDE.md +12 -1
- package/templates/changelog/template.md +8 -0
- package/skills/multi-server-orchestration/SKILL.md +0 -137
- package/skills/multi-server-orchestration/references/greenfield-buildout.md +0 -246
- package/skills/multi-server-orchestration/references/maintenance-pass.md +0 -148
- package/skills/multi-server-orchestration/references/release-and-publish-pass.md +0 -184
- package/skills/multi-server-orchestration/references/wrapup-pass.md +0 -150
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: maintenance-release
|
|
3
|
+
description: >
|
|
4
|
+
Workflow: run the `maintenance` skill against one or more existing MCP server projects (dependency updates, framework adoption, skill sync), verify adoption gaps in a double-check pass, then wrap up and release via `git-wrapup` and `release-and-publish`. Read `../SKILL.md` first for the universal rules and sub-agent strategy.
|
|
5
|
+
metadata:
|
|
6
|
+
author: cyanheads
|
|
7
|
+
version: "1.0"
|
|
8
|
+
audience: internal
|
|
9
|
+
type: workflow
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
# Maintenance + Release Workflow
|
|
13
|
+
|
|
14
|
+
Use after reading `../SKILL.md`. Drives maintenance, adoption verification, wrap-up, and release across N existing MCP server projects.
|
|
15
|
+
|
|
16
|
+
## When applicable
|
|
17
|
+
|
|
18
|
+
- One or more existing servers built on `@cyanheads/mcp-ts-core` need updates from `bun outdated` landed and shipped
|
|
19
|
+
- N = 1 still benefits — fresh-context sub-agents per phase keep each focused and within context budget
|
|
20
|
+
- Each target should have a clean working tree before the workflow starts — uncommitted work blocks the `maintenance` skill's verification gate
|
|
21
|
+
|
|
22
|
+
## Tier 1 skills referenced
|
|
23
|
+
|
|
24
|
+
| Phase | Tier 1 skill(s) |
|
|
25
|
+
|:---|:---|
|
|
26
|
+
| Maintenance | `skills/maintenance/SKILL.md` |
|
|
27
|
+
| Double-check | `skills/polish-docs-meta/SKILL.md` (the cross-file consistency reference is the most commonly missed surface) |
|
|
28
|
+
| Wrap-up | `skills/git-wrapup/SKILL.md` |
|
|
29
|
+
| Release | `skills/release-and-publish/SKILL.md` |
|
|
30
|
+
|
|
31
|
+
## Pre-flight
|
|
32
|
+
|
|
33
|
+
Per target:
|
|
34
|
+
|
|
35
|
+
1. **Clean working tree** — `git status --short` must be empty. Halt if dirty; user fixes locally before re-invoking.
|
|
36
|
+
2. **Latest tag and version** — `git describe --tags --abbrev=0`, `grep '"version"' package.json`
|
|
37
|
+
3. **`list-skills` script presence** — `test -f scripts/list-skills.ts && grep -q '"list-skills"' package.json`. If missing, note it — the `maintenance` skill's Phase C will install it.
|
|
38
|
+
4. **`publish-mcp` script** — when `server.json` exists, check `grep -q '"publish-mcp"' package.json`. If missing, flag it — the maintenance sub-agent adds it.
|
|
39
|
+
5. **Publish destinations** — note which exist: `server.json` (MCP Registry), `manifest.json` (MCPB / GH Release), `Dockerfile` (GHCR). If `server.json` exists but `manifest.json` doesn't, flag — maintenance scaffolds it.
|
|
40
|
+
6. **`npm whoami`** — required if releasing publicly.
|
|
41
|
+
7. **Framework version delta** — `grep '"version"' node_modules/@cyanheads/mcp-ts-core/package.json` vs `npm view @cyanheads/mcp-ts-core version` to preview adoption scope.
|
|
42
|
+
|
|
43
|
+
## Phases
|
|
44
|
+
|
|
45
|
+
Each phase's Objective column is the goal state per target — the verifiable end state the phase must produce.
|
|
46
|
+
|
|
47
|
+
| # | Phase | Objective | Sub-agent mode |
|
|
48
|
+
|:--|:---|:---|:---|
|
|
49
|
+
| 1 | Maintenance | Per target: deps updated, framework adoption applied, project skills synced, `rebuild` + `devcheck` + `test` green, Step 8 numbered summary returned | parallel fanout |
|
|
50
|
+
| 2 | Double-check | Adoption gaps from Phase 1 fixed; `manifest.json`/`server.json` content validated; audience compliance verified; `rebuild` + `devcheck` + `test` green | parallel fanout |
|
|
51
|
+
| 3 | Roll-up | Per-target headlines + cross-target patterns surfaced to user; version-bump intent confirmed (patch/minor/major) | orchestrator (serial) |
|
|
52
|
+
| 4 | Wrap-up + release | Per target: version-bumped commit + annotated tag + push + publish per scope; tag annotation renders as structured markdown on GitHub Release | parallel fanout (Bash git only) |
|
|
53
|
+
|
|
54
|
+
Phase 4 combines wrap-up and release in one sub-agent because the work is sequential and shares context (version, changelog, tag annotation). The sub-agent reads both Tier 1 skills.
|
|
55
|
+
|
|
56
|
+
## Phase notes
|
|
57
|
+
|
|
58
|
+
### Phase 1: Maintenance
|
|
59
|
+
Each sub-agent runs `skills/maintenance/SKILL.md` Mode A — the full flow from `bun outdated` through verification.
|
|
60
|
+
|
|
61
|
+
**Prompt phrasing matters.** Generic "run the maintenance skill" prompts cause sub-agents to stop at changelog analysis without executing. Include explicit steps in the prompt body:
|
|
62
|
+
1. `bun outdated` — capture the list
|
|
63
|
+
2. `bun update --latest` — apply, capturing the `↑ package old → new` lines for Step 3
|
|
64
|
+
3. Invoke the `changelog` skill for each updated package (or read `node_modules/<pkg>/CHANGELOG.md` directly if the skill isn't synced yet)
|
|
65
|
+
4. If `@cyanheads/mcp-ts-core` updated, do the deeper framework review per the maintenance skill's Step 4
|
|
66
|
+
5. Run Step 5 skill/script sync — Phase A (package → project `skills/`), Phase B (project `skills/` → agent dirs), Phase C (package scripts + pristine references → project)
|
|
67
|
+
6. Adopt changes per Step 6 — framework changes are auto-adopt at every applicable site in this pass; third-party libs are cost/benefit
|
|
68
|
+
7. `bun run rebuild` → `bun run devcheck` → `bun run test`
|
|
69
|
+
8. Produce the Step 8 numbered summary
|
|
70
|
+
|
|
71
|
+
**Skill-version paradox.** If `node_modules/@cyanheads/mcp-ts-core/skills/maintenance/SKILL.md` version is newer than the synced project copy, feature-adoption rows added in the new version don't surface. Sub-agent prompt instructs: after Phase A sync completes, re-read the synced `maintenance` SKILL.md and continue from Step 5 with the new version.
|
|
72
|
+
|
|
73
|
+
**Skill audience compliance.** Only sync skills with `metadata.audience: external` into project `skills/`. Sub-agents miss this under context pressure — restate explicitly.
|
|
74
|
+
|
|
75
|
+
**Constraints to restate verbatim:**
|
|
76
|
+
- No commits, tags, pushes — leave working tree dirty for orchestrator review
|
|
77
|
+
- Read-only git allowed and expected — `git diff skills/` after Phase A surfaces adoption signal
|
|
78
|
+
- Halt and report verbatim if `bun run devcheck` can't be made green; `bun audit` failures from a transitive dep with no patch are note-not-halt
|
|
79
|
+
- Output the Step 8 numbered summary at the end — the orchestrator parses it
|
|
80
|
+
|
|
81
|
+
### Phase 2: Double-check
|
|
82
|
+
Independent maintenance sub-agents diverge on incidental choices and miss adoption sites under context pressure. The double-check pass catches gaps before wrap-up.
|
|
83
|
+
|
|
84
|
+
**Critical: these sub-agents audit AND fix, then re-verify.** Not analysis-only.
|
|
85
|
+
|
|
86
|
+
Audit categories (sub-agent prompt enumerates):
|
|
87
|
+
|
|
88
|
+
- **Adoption gaps** — features the updated skills say to do that weren't applied (error code semantic audit, missing scaffolding files like `manifest.json`/`.mcpbignore`, `publish-mcp` script)
|
|
89
|
+
- **Audience compliance** — only skills with `metadata.audience: external` belong in project `skills/`; agents sometimes sync `internal`-audience skills
|
|
90
|
+
- **Content accuracy** — `isRequired` flags in `server.json` match the upstream API's reality (does the API work without the key?); `manifest.json` `name` doesn't include the npm scope prefix; `user_config` entries have required `title` and `type` fields
|
|
91
|
+
- **Cross-target consistency** — if a feature shows up in 3 of 5 Phase 1 summaries, the other 2 likely missed it
|
|
92
|
+
- **Error code semantics** — `InvalidParams` only for malformed JSON-RPC params shape; `ValidationError` for domain validation; `NotFound` for missing entities
|
|
93
|
+
- **Description alignment** — `package.json`, `manifest.json`, `server.json` (≤100 char), README header, GH repo description should be consistent
|
|
94
|
+
- **README install badges** — Claude Desktop `.mcpb`, Cursor deeplink, VS Code deeplink — present when `manifest.json` exists
|
|
95
|
+
|
|
96
|
+
Exit gate: `bun run rebuild && bun run devcheck && bun run test` after fixes.
|
|
97
|
+
|
|
98
|
+
A lighter model (e.g. Sonnet-class) is appropriate here — verification + targeted fixes, not deep adoption work.
|
|
99
|
+
|
|
100
|
+
### Phase 3: Roll-up
|
|
101
|
+
The orchestrator collects Phase 1 + Phase 2 reports and produces:
|
|
102
|
+
1. **Per-target headlines** — short table: target → packages updated → mcp-ts-core delta → devcheck/test status → gaps fixed
|
|
103
|
+
2. **Cross-target patterns** — features adopted across multiple targets, breaking changes that hit a subset
|
|
104
|
+
3. **Open decisions** — per-target ambiguities; group by decision so the user can rule once across multiple targets when the choice is the same
|
|
105
|
+
4. **Outliers** — targets with unusually large diffs or where adoption couldn't complete cleanly
|
|
106
|
+
|
|
107
|
+
**Version bump intent.** Default is **patch** unless the change shape indicates otherwise:
|
|
108
|
+
|
|
109
|
+
| Bump | When |
|
|
110
|
+
|:---|:---|
|
|
111
|
+
| **patch** (default) | Dependency updates, framework adoption, doc polish, bug fixes — ~95% of maintenance runs |
|
|
112
|
+
| **minor** | New tools/resources/prompts added, new user-facing features, new env vars that change behavior |
|
|
113
|
+
| **major** | Breaking changes to the server's MCP surface (removed tools, renamed fields, changed semantics) |
|
|
114
|
+
|
|
115
|
+
If a target's diff suggests minor-or-above, **pause that target and surface to the user during roll-up** — unaffected targets proceed to Phase 4 at patch.
|
|
116
|
+
|
|
117
|
+
### Phase 4: Wrap-up + release
|
|
118
|
+
Each sub-agent reads BOTH `skills/git-wrapup/SKILL.md` AND `skills/release-and-publish/SKILL.md`. Runs wrap-up (version bump, changelog authoring, commit, annotated tag), then release (push, npm publish, MCP Registry, GH release, Docker).
|
|
119
|
+
|
|
120
|
+
**Framework changelog reading.** When `mcp-ts-core` was updated, the sub-agent must read the framework's changelog files for the version delta (e.g. `node_modules/@cyanheads/mcp-ts-core/changelog/0.9.x/0.9.2.md` through `0.9.6.md`) and distill user-facing changes relevant to this server into the changelog entry and tag annotation. "Picks up upstream fixes" is not acceptable — name what changed.
|
|
121
|
+
|
|
122
|
+
**Wrap-up scope.** Determined by repo visibility (`gh repo view --json visibility`):
|
|
123
|
+
|
|
124
|
+
| Status | Scope |
|
|
125
|
+
|:---|:---|
|
|
126
|
+
| Private / in-development | Version bump → changelog → commit → tag → mcpb bundle → push → `gh release create`. Skip `bun publish`, Docker, MCP Registry. |
|
|
127
|
+
| Public / launched | Full `release-and-publish`: push + `bun publish` + `publish-mcp` + bundle + GH release + Docker (if Dockerfile). |
|
|
128
|
+
|
|
129
|
+
**npm 2FA mode.** Parallel `bun publish` doesn't play nicely with interactive 2FA — OTP prompts from multiple sub-agents interleave. Either:
|
|
130
|
+
- Bypass token configured (granular access token with "Bypass 2FA for publish") → Phase 4 runs as parallel fanout
|
|
131
|
+
- No bypass → Phase 4 runs serially, orchestrator-driven, one target at a time
|
|
132
|
+
- No npm publish involved (private only) → non-issue
|
|
133
|
+
|
|
134
|
+
**Commit structure.** Version bump rides with the change that warrants it. For a maintenance pass with a single cohesive change shape (e.g. just dep updates, or just one framework adoption), that's **one commit** — subject can lead with the version (e.g. `feat: 0.5.2 — adopt new error factories, framework ^0.9.6`). For a maintenance pass containing multiple distinct concerns, split into per-concern commits with the version bump folded into the headline-change commit, not a separate ceremonial release commit.
|
|
135
|
+
|
|
136
|
+
**Tag annotations are for end users.** Internal dev cleanup (lockfile refreshes, linter fixes, build config) belongs in the commit body, not the tag annotation.
|
|
137
|
+
|
|
138
|
+
**Tag-moving protocol.** If post-version doc changes land after the version commit, move the tag to HEAD: delete remote release, delete remote + local tag, recreate tag at new HEAD with same annotation, re-push, recreate release with `.mcpb`. Authorized within the workflow — same-day forward move.
|
|
139
|
+
|
|
140
|
+
### Watchtower-style container refresh (if applicable)
|
|
141
|
+
For targets with hosted instances behind an auto-pull tool, trigger the refresh after GHCR images are verified reachable. This is operational, not part of the release-and-publish skill — handle in the orchestrator's post-Phase-4 step if the deployment infrastructure has it.
|
|
142
|
+
|
|
143
|
+
## Workflow-specific gotchas
|
|
144
|
+
|
|
145
|
+
| # | Gotcha | Mitigation |
|
|
146
|
+
|:--|:-------|:-----------|
|
|
147
|
+
| 1 | Generic "run the maintenance skill" prompts cause ~50% of sub-agents to halt at changelog analysis without executing | Include explicit execution steps in Phase 1 prompt body; respawn with directive if Step 8 summary missing |
|
|
148
|
+
| 2 | Skill-version paradox — feature rows added in newer maintenance skill don't surface in the synced older copy | Sub-agent prompt: after Phase A sync, re-read synced `maintenance` SKILL.md and continue from Step 5 |
|
|
149
|
+
| 3 | Per-target adoption divergence is expected — projects on different starting framework versions adopt different things | Don't try to normalize. Surface divergence as informational in Phase 3 roll-up. |
|
|
150
|
+
| 4 | The `changelog` skill may not exist in a target's skill directory yet | Sub-agent falls back to direct `node_modules/<pkg>/CHANGELOG.md` reading |
|
|
151
|
+
| 5 | Sub-agent runs write git commands despite instruction | Restate the no-write-git list + no-`stash` rule in prompt body; verify via `git log --oneline -1` per target after Phase 1 — should show no new commits |
|
|
152
|
+
| 6 | Sub-agent syncs `internal`-audience skills into project `skills/` | Restate "Only sync skills with `metadata.audience: external`" — sub-agents miss this under context pressure |
|
|
153
|
+
| 7 | `manifest.json` scaffolded with scoped name from `package.json` (e.g. `@scope/server-name`) — renders in mcpb install dialog | Phase 2 verifies `manifest.json` `name` doesn't contain `/` |
|
|
154
|
+
| 8 | `manifest.json` `user_config` entries missing required `title`/`type` — `mcpb pack` fails at release time | Phase 2 verifies required fields |
|
|
155
|
+
| 9 | `server.json` `isRequired` doesn't match upstream API reality | Phase 2 verifies against actual API behavior |
|
|
156
|
+
| 10 | Framework version arrow in tag/changelog says nothing useful ("picks up upstream fixes") | Phase 4 prompt requires reading mcp-ts-core changelog files and distilling relevant changes |
|
|
157
|
+
| 11 | Tag annotations render as flat comma-separated strings or balloon into full CHANGELOG copies | Phase 4 prompt: structured markdown with sections (Fixed, Dependencies, etc.), dep arrows (`pkg ^old → ^new`), test footer; length is earned |
|
|
158
|
+
| 12 | Post-version doc changes land after the tag — release points at stale content | Tag-moving protocol; authorized within the workflow as a same-day forward move |
|
|
159
|
+
| 13 | Background sub-agent bails early on context | Orchestrator checks for Step 8 summary; respawns continuation sub-agent if missing |
|
|
160
|
+
| 14 | Big monorepo or many adoptions cause context exhaustion in a sub-agent | Narrow the prompt: if a target has many breaking framework changes, split the work into "update deps + verify" and "adopt features" against that target |
|
|
161
|
+
|
|
162
|
+
## Checklist
|
|
163
|
+
|
|
164
|
+
- [ ] Pre-flight: target list confirmed, clean working trees, `list-skills`/`publish-mcp`/`manifest.json` presence noted, framework version delta noted, npm 2FA mode confirmed if releasing publicly
|
|
165
|
+
- [ ] Phase 1: maintenance sub-agents complete — Step 8 summary present per target, devcheck + test green
|
|
166
|
+
- [ ] Phase 1 integrity: `git log --oneline -1` per target confirms no new commits written by sub-agents
|
|
167
|
+
- [ ] Phase 2: double-check sub-agents complete — adoption gaps fixed, audience compliance verified, `manifest.json` and `server.json` validated; devcheck + test green after fixes
|
|
168
|
+
- [ ] Phase 3: roll-up surfaced to user; version bump intent confirmed (patch default; minor/major surfaces if applicable)
|
|
169
|
+
- [ ] Phase 4: wrap-up + release sub-agents complete — commit + annotated tag + push + publish per target, scope matches private/public status
|
|
170
|
+
- [ ] Post-Phase-4 verification: `git ls-remote --tags origin` shows new tag; `npm view <pkg>@<version>` resolves (public); GH release artifacts attached; Docker image exists (if Dockerfile)
|
|
171
|
+
- [ ] Tag/release quality review: tag subject omits version number, structured markdown, no marketing adjectives, dep arrows present, issue backlinks where applicable
|
|
@@ -4,7 +4,7 @@ description: >
|
|
|
4
4
|
Finalize documentation and project metadata for a ship-ready MCP server. Use after implementation is complete, tests pass, and devcheck is clean. Safe to run at any stage — each step checks current state and only acts on what still needs work.
|
|
5
5
|
metadata:
|
|
6
6
|
author: cyanheads
|
|
7
|
-
version: "2.
|
|
7
|
+
version: "2.3"
|
|
8
8
|
audience: external
|
|
9
9
|
type: workflow
|
|
10
10
|
---
|
|
@@ -165,7 +165,24 @@ Never hand-edit `CHANGELOG.md` when using this pattern — it's a build artifact
|
|
|
165
165
|
|
|
166
166
|
**Monolithic** — maintain `CHANGELOG.md` directly in [Keep a Changelog](https://keepachangelog.com/) format. To collapse from the template default: delete the `changelog/` directory, remove `changelog:build` and `changelog:check` from `package.json` scripts (and from `devcheck.config.json` if referenced), and drop `"changelog/"` from the `files` array. The `release` skill's directory-specific steps then don't apply — just edit `CHANGELOG.md` and bump version at release time.
|
|
167
167
|
|
|
168
|
-
### 10.
|
|
168
|
+
### 10. Plugin Metadata (Codex / Claude Code)
|
|
169
|
+
|
|
170
|
+
If `.codex-plugin/plugin.json` exists, verify it's populated and in sync with `package.json` and `server.json`:
|
|
171
|
+
|
|
172
|
+
- `name` matches `package.json` `name`
|
|
173
|
+
- `version` matches `package.json` `version`
|
|
174
|
+
- `description` matches `package.json` `description`
|
|
175
|
+
- `repository` matches `package.json` `repository.url`
|
|
176
|
+
- `license` matches `package.json` `license`
|
|
177
|
+
- `interface.displayName` = `package.json` `name`
|
|
178
|
+
- `interface.shortDescription` matches `package.json` `description`
|
|
179
|
+
- `interface.category` is set to a meaningful category
|
|
180
|
+
|
|
181
|
+
If `.codex-plugin/mcp.json` exists, verify the server name key matches `package.json` `name` and env vars include any required API keys from the server config schema.
|
|
182
|
+
|
|
183
|
+
If `.claude-plugin/plugin.json` exists, apply the same checks: `name`, `version`, `description`, `repository`, `license` from `package.json`. Verify the inline `mcpServers` entry key matches `package.json` `name` and env vars include any required API keys.
|
|
184
|
+
|
|
185
|
+
### 11. MCPB Bundling Artifacts
|
|
169
186
|
|
|
170
187
|
If the project ships as an `.mcpb` bundle for Claude Desktop (check for `manifest.json` at the project root), verify the full artifact set is present and consistent. If the project doesn't ship `.mcpb` bundles, skip this step.
|
|
171
188
|
|
|
@@ -185,6 +202,7 @@ If the project ships as an `.mcpb` bundle for Claude Desktop (check for `manifes
|
|
|
185
202
|
- Env var names in `manifest.json` (`mcp_config.env` + `user_config`) match `server.json` `environmentVariables` — `lint:packaging` enforces this, but verify the set is complete
|
|
186
203
|
- `manifest.json` `name` matches `package.json` name **without the npm scope prefix** (e.g. `bls-mcp-server`, not `@cyanheads/bls-mcp-server`); `description` matches `package.json`
|
|
187
204
|
- `manifest.json` `user_config` entries must include `title` and `type` fields — `mcpb pack` validates these
|
|
205
|
+
- For each `user_config` entry referenced as `${user_config.X}` in `mcp_config.env`: if it's not `required: true`, set `"default": ""`. MCPB hosts (Claude Desktop included) pass the literal placeholder string through to the process when an optional field is left blank without a default — strict consumer validators (`z.email()`, `z.url()`, `.regex()`) then crash at lazy config load, exiting silently after `initialize`. Server-side: pair every optional env-backed strict-validator field with a `z.preprocess` that strips `${...}` placeholders to `undefined`.
|
|
188
206
|
- `server.json` env var `isRequired` must match the upstream API's actual requirement — if the API works without the value (rate-limited, DEMO_KEY fallback, polite pool), mark `isRequired: false` and describe the tradeoff in the description
|
|
189
207
|
- Server description aligned across all surfaces: `package.json`, `manifest.json`, `server.json` (condensed, hard 100-char limit), README header `<p><b>`, and GitHub repo description (`gh repo edit --description`)
|
|
190
208
|
- `package.json` `keywords` include baseline terms: `mcp`, `mcp-server`, `model-context-protocol`, `typescript`, `bun`, `stdio`, `streamable-http`, plus data-domain terms. GitHub repo topics (`gh repo edit --add-topic`) should match.
|
|
@@ -196,11 +214,11 @@ If the project ships as an `.mcpb` bundle for Claude Desktop (check for `manifes
|
|
|
196
214
|
- See `references/readme.md` for badge format and config generation commands
|
|
197
215
|
- See the **Bundling** section of `templates/CLAUDE.md` for `base64` / `encodeURIComponent` generation
|
|
198
216
|
|
|
199
|
-
###
|
|
217
|
+
### 12. `LICENSE`
|
|
200
218
|
|
|
201
219
|
Confirm a license file exists. If not, ask the user which license to use (default: Apache-2.0, matching the scaffolded `package.json`). Create the file.
|
|
202
220
|
|
|
203
|
-
###
|
|
221
|
+
### 13. `Dockerfile`
|
|
204
222
|
|
|
205
223
|
If a `Dockerfile` exists, verify the OCI labels and runtime config match the actual server:
|
|
206
224
|
|
|
@@ -211,7 +229,7 @@ If a `Dockerfile` exists, verify the OCI labels and runtime config match the act
|
|
|
211
229
|
|
|
212
230
|
If no `Dockerfile` exists and the server is deployed via HTTP transport, consider scaffolding one — the template is available via `npx @cyanheads/mcp-ts-core init`.
|
|
213
231
|
|
|
214
|
-
###
|
|
232
|
+
### 14. `docs/tree.md`
|
|
215
233
|
|
|
216
234
|
Regenerate the directory structure:
|
|
217
235
|
|
|
@@ -221,7 +239,7 @@ bun run tree
|
|
|
221
239
|
|
|
222
240
|
Review the output for anything unexpected (leftover files, missing directories).
|
|
223
241
|
|
|
224
|
-
###
|
|
242
|
+
### 15. Final Verification
|
|
225
243
|
|
|
226
244
|
Run the full check suite one last time:
|
|
227
245
|
|
|
@@ -243,6 +261,9 @@ Both must pass clean.
|
|
|
243
261
|
- [ ] GitHub repo description matches `package.json` description; topics ↔ keywords in sync
|
|
244
262
|
- [ ] `bunfig.toml` present
|
|
245
263
|
- [ ] Changelog current — either monolithic `CHANGELOG.md` (hand-edited, Keep a Changelog) or directory-based (`changelog/<minor>.x/<version>.md` + rollup regenerated and in sync)
|
|
264
|
+
- [ ] `.codex-plugin/plugin.json` populated and in sync with `package.json` (if present)
|
|
265
|
+
- [ ] `.codex-plugin/mcp.json` server name and env vars current (if present)
|
|
266
|
+
- [ ] `.claude-plugin/plugin.json` populated and in sync with `package.json` (if present)
|
|
246
267
|
- [ ] MCPB artifacts consistent (if `manifest.json` present) — version synced, env vars match `server.json`, `bundle` + `lint:packaging` scripts exist, README install badges present
|
|
247
268
|
- [ ] `LICENSE` file present
|
|
248
269
|
- [ ] `Dockerfile` OCI labels and runtime config accurate (if present)
|
|
@@ -4,7 +4,7 @@ description: >
|
|
|
4
4
|
Ship a release end-to-end across every registry the project targets (npm, MCP Registry, GitHub Releases for `.mcpb` bundles, GHCR). Runs the final verification gate, pushes commits and tags, then publishes to each applicable destination. Assumes git wrapup (version bumps, changelog, commit, annotated tag) is already complete — this skill is the post-wrapup publish workflow. Retries transient network failures on publish steps; halts with a partial-state report when retries are exhausted or the failure is terminal.
|
|
5
5
|
metadata:
|
|
6
6
|
author: cyanheads
|
|
7
|
-
version: "2.
|
|
7
|
+
version: "2.7"
|
|
8
8
|
audience: external
|
|
9
9
|
type: workflow
|
|
10
10
|
---
|
|
@@ -131,11 +131,12 @@ Halt on any publisher error other than "cannot publish duplicate version".
|
|
|
131
131
|
|
|
132
132
|
Only if `manifest.json` exists at the repo root (otherwise skip).
|
|
133
133
|
|
|
134
|
-
Build the bundle, then create a Release on the existing annotated tag and attach the `.mcpb`. The Release sits on top of the tag from wrapup — `--verify-tag` enforces that the tag already exists on the remote and prevents `gh` from creating a lightweight tag that would shadow the annotated one. `--notes-from-tag` pulls release notes
|
|
134
|
+
Build the bundle, then create a Release on the existing annotated tag and attach the `.mcpb`. The Release sits on top of the tag from wrapup — `--verify-tag` enforces that the tag already exists on the remote and prevents `gh` from creating a lightweight tag that would shadow the annotated one. `--notes-from-tag` pulls the tag annotation body as release notes. `--title` sets the release title from the tag subject — `--notes-from-tag` alone does NOT set the title (it defaults to the bare tag name, e.g. "v0.1.8" with no theme). The tag subject already omits the version number per the git-wrapup skill, so prepending `v<VERSION>:` produces the correct display title.
|
|
135
135
|
|
|
136
136
|
```bash
|
|
137
137
|
bun run bundle # produces dist/<name>.mcpb (stable filename, no version)
|
|
138
|
-
|
|
138
|
+
SUBJECT=$(git tag -l --format='%(contents:subject)' v<VERSION>)
|
|
139
|
+
gh release create v<VERSION> --verify-tag --notes-from-tag --title "v<VERSION>: $SUBJECT" dist/*.mcpb
|
|
139
140
|
```
|
|
140
141
|
|
|
141
142
|
The stable filename matters: it lets the README "Install in Claude Desktop" badge point at `releases/latest/download/<name>.mcpb` and always resolve to the most recent release. The `bundle` script in the templates outputs `dist/{{PACKAGE_NAME}}.mcpb` for this reason.
|
|
@@ -205,7 +206,7 @@ If any check fails, halt and report which destination is unreachable. A successf
|
|
|
205
206
|
- [ ] Tags pushed to origin
|
|
206
207
|
- [ ] `bun publish --access public` succeeds
|
|
207
208
|
- [ ] `bun run publish-mcp` succeeds (if `server.json` present)
|
|
208
|
-
- [ ] `bun run bundle` + `gh release create --verify-tag --notes-from-tag` succeeds (if `manifest.json` present)
|
|
209
|
+
- [ ] `bun run bundle` + `gh release create --verify-tag --notes-from-tag --title` succeeds (if `manifest.json` present)
|
|
209
210
|
- [ ] Docker buildx multi-arch push succeeds (if `Dockerfile` present)
|
|
210
211
|
- [ ] All published artifacts verified reachable (npm, MCP Registry, GH Release asset, GHCR manifest)
|
|
211
212
|
- [ ] On re-invocation: idempotent-success signals recognized for already-published destinations
|
|
@@ -4,7 +4,7 @@ description: >
|
|
|
4
4
|
File a bug or feature request against @cyanheads/mcp-ts-core when you hit a framework issue. Use when a builder, utility, context method, or config behaves contrary to the documented API — not for server-specific application bugs.
|
|
5
5
|
metadata:
|
|
6
6
|
author: cyanheads
|
|
7
|
-
version: "1.
|
|
7
|
+
version: "1.7"
|
|
8
8
|
audience: external
|
|
9
9
|
type: workflow
|
|
10
10
|
---
|
|
@@ -33,6 +33,8 @@ For general `gh` CLI workflows outside issue filing (PRs, workflows, API access)
|
|
|
33
33
|
gh issue list -R cyanheads/mcp-ts-core --search "your error message or keyword"
|
|
34
34
|
```
|
|
35
35
|
|
|
36
|
+
5. **For documentation- or contract-shaped requests, audit all three doc layers first** — proposals to add reference docs, public-API conventions, attribute/event catalogs, or stability commitments often duplicate surface that already exists. Check `src/` for behavior, `docs/` for human-facing reference, and `skills/` for agent-facing reference. Skill files marked `audience: external` are the framework's public contract — treat them as authoritative when evaluating whether a documentation gap exists. Also verify the constants or types you'd reference aren't already exported from `@cyanheads/mcp-ts-core` or one of its subpaths.
|
|
37
|
+
|
|
36
38
|
## Writing Well-Structured Issues
|
|
37
39
|
|
|
38
40
|
Good issues are scannable, concrete, and self-contained — terse and fact-dense. Default to one or two sentences per bullet; if a bullet runs long, split it or cut it. These patterns apply to both bugs and features — the guidance targets any prose block (Description, Additional context, feature proposals).
|
|
@@ -286,6 +288,7 @@ gh issue list -R cyanheads/mcp-ts-core --author @me
|
|
|
286
288
|
- [ ] Confirmed bug is in `@cyanheads/mcp-ts-core`, not server code
|
|
287
289
|
- [ ] Running latest (or documented) framework version
|
|
288
290
|
- [ ] Searched existing issues — no duplicate found
|
|
291
|
+
- [ ] If documentation or contract enhancement: confirmed `src/`, `docs/`, `skills/`, and public exports don't already cover the surface
|
|
289
292
|
- [ ] All secrets, credentials, and tokens redacted
|
|
290
293
|
- [ ] Primary label assigned (`bug` / `enhancement` / `documentation`)
|
|
291
294
|
- [ ] If bug: version, runtime, repro code, actual vs expected behavior included
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "{{PACKAGE_NAME}}",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "",
|
|
5
|
+
"author": {
|
|
6
|
+
"name": ""
|
|
7
|
+
},
|
|
8
|
+
"homepage": "",
|
|
9
|
+
"repository": "",
|
|
10
|
+
"license": "Apache-2.0",
|
|
11
|
+
"mcpServers": {
|
|
12
|
+
"{{PACKAGE_NAME}}": {
|
|
13
|
+
"command": "npx",
|
|
14
|
+
"args": ["-y", "{{PACKAGE_NAME}}"],
|
|
15
|
+
"env": {
|
|
16
|
+
"MCP_TRANSPORT_TYPE": "stdio"
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "{{PACKAGE_NAME}}",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "",
|
|
5
|
+
"author": {
|
|
6
|
+
"name": "",
|
|
7
|
+
"email": "",
|
|
8
|
+
"url": ""
|
|
9
|
+
},
|
|
10
|
+
"homepage": "",
|
|
11
|
+
"repository": "",
|
|
12
|
+
"license": "Apache-2.0",
|
|
13
|
+
"keywords": ["mcp", "mcp-server", "model-context-protocol"],
|
|
14
|
+
"mcpServers": "./.codex-plugin/mcp.json",
|
|
15
|
+
"interface": {
|
|
16
|
+
"displayName": "{{PACKAGE_NAME}}",
|
|
17
|
+
"shortDescription": "",
|
|
18
|
+
"longDescription": "",
|
|
19
|
+
"developerName": "",
|
|
20
|
+
"category": "",
|
|
21
|
+
"capabilities": ["Read"],
|
|
22
|
+
"websiteURL": "",
|
|
23
|
+
"defaultPrompt": []
|
|
24
|
+
}
|
|
25
|
+
}
|
package/templates/AGENTS.md
CHANGED
|
@@ -264,9 +264,14 @@ Available skills:
|
|
|
264
264
|
| `add-service` | Scaffold a new service integration |
|
|
265
265
|
| `add-test` | Scaffold test file for a tool, resource, or service |
|
|
266
266
|
| `field-test` | Exercise tools/resources/prompts with real inputs, verify behavior, report issues |
|
|
267
|
+
| `tool-defs-analysis` | Read-only audit of MCP definition language across the surface — voice, leaks, defaults, recovery hints, output descriptions |
|
|
267
268
|
| `security-pass` | Audit server for MCP-flavored security gaps: output injection, scope blast radius, input sinks, tenant isolation |
|
|
269
|
+
| `code-simplifier` | Post-session cleanup against `git diff` — modernize syntax, consolidate duplication, align with the codebase |
|
|
268
270
|
| `devcheck` | Lint, format, typecheck, audit |
|
|
269
271
|
| `polish-docs-meta` | Finalize docs, README, metadata, and agent protocol for shipping |
|
|
272
|
+
| `git-wrapup` | Land working-tree changes as a versioned commit + annotated tag — version bump, changelog, verify, tag. Local only. |
|
|
273
|
+
| `release-and-publish` | Push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
|
|
274
|
+
| `migrate-mcp-ts-template` | One-time migration of an existing project to the current framework template |
|
|
270
275
|
| `maintenance` | Investigate changelogs, adopt upstream changes, sync skills to agent dirs |
|
|
271
276
|
| `report-issue-framework` | File a bug or feature request against `@cyanheads/mcp-ts-core` via `gh` CLI |
|
|
272
277
|
| `report-issue-local` | File a bug or feature request against this server's own repo via `gh` CLI |
|
|
@@ -275,6 +280,7 @@ Available skills:
|
|
|
275
280
|
| `api-config` | AppConfig, parseConfig, env vars |
|
|
276
281
|
| `api-context` | Context interface, logger, state, progress |
|
|
277
282
|
| `api-errors` | McpError, JsonRpcErrorCode, error patterns |
|
|
283
|
+
| `api-linter` | Definition linter rule catalog — invoked by `bun run lint:mcp` and `devcheck` |
|
|
278
284
|
| `api-services` | LLM, Speech, Graph services |
|
|
279
285
|
| `api-testing` | createMockContext, test patterns |
|
|
280
286
|
| `api-utils` | Formatting, parsing, security, pagination, scheduling, telemetry helpers |
|
|
@@ -369,6 +375,8 @@ security: false # optional — true flags security fi
|
|
|
369
375
|
|
|
370
376
|
`breaking: true` renders a `· ⚠️ Breaking` badge — use it when consumers must update code on upgrade (signature changes, removed APIs, config renames). `security: true` renders a `· 🛡️ Security` badge and pairs with a `## Security` body section. When both are set, badges render `· ⚠️ Breaking · 🛡️ Security`.
|
|
371
377
|
|
|
378
|
+
`agent-notes` is an optional free-form field for maintenance agents processing the release downstream. Content here won't appear in the rendered CHANGELOG — it's consumed by agents running the `maintenance` skill. Use it for adoption instructions that don't fit the human-facing sections: new files to create, fields to populate, one-time migration steps. Omit entirely when there's nothing to say.
|
|
379
|
+
|
|
372
380
|
**Section order** (Keep a Changelog): Added, Changed, Deprecated, Removed, Fixed, Security. Include only sections with entries — don't ship empty headers.
|
|
373
381
|
|
|
374
382
|
**Tag annotations** render as GitHub Release bodies via `--notes-from-tag`. They must be structured markdown — never a flat comma-separated string. Subject omits the version number (GitHub prepends it). See `changelog/template.md` for the full format reference.
|
|
@@ -401,4 +409,7 @@ import { getMyService } from '@/services/my-domain/my-service.js';
|
|
|
401
409
|
- [ ] If wrapping external API: tests include at least one sparse payload case with omitted upstream fields
|
|
402
410
|
- [ ] Registered in `createApp()` arrays (directly or via barrel exports)
|
|
403
411
|
- [ ] Tests use `createMockContext()` from `@cyanheads/mcp-ts-core/testing`
|
|
412
|
+
- [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = package name; `interface.shortDescription` from `package.json` description
|
|
413
|
+
- [ ] `.codex-plugin/mcp.json` updated — server name key matches `package.json` name; env vars added for any required API keys
|
|
414
|
+
- [ ] `.claude-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; inline `mcpServers` entry with server name key, env vars for any required API keys
|
|
404
415
|
- [ ] `npm run devcheck` passes
|
package/templates/CLAUDE.md
CHANGED
|
@@ -50,7 +50,7 @@ Tailor suggestions to what's actually missing or stale — don't recite the full
|
|
|
50
50
|
- **Use `ctx.state`** for tenant-scoped storage. Never access persistence directly.
|
|
51
51
|
- **Check `ctx.elicit` / `ctx.sample`** for presence before calling.
|
|
52
52
|
- **Secrets in env vars only** — never hardcoded.
|
|
53
|
-
- **Close the loop on issues.** When implementing work tracked by a GitHub issue, comment on the issue with what landed
|
|
53
|
+
- **Close the loop on issues.** When implementing work tracked by a GitHub issue, comment on the issue with what landed and close it. Do both — a comment without a close leaves stale issues open; a close without a comment leaves no record of what shipped. The comment is for future readers — state the concrete changes, not the conversation that produced them.
|
|
54
54
|
|
|
55
55
|
---
|
|
56
56
|
|
|
@@ -265,9 +265,14 @@ Available skills:
|
|
|
265
265
|
| `add-service` | Scaffold a new service integration |
|
|
266
266
|
| `add-test` | Scaffold test file for a tool, resource, or service |
|
|
267
267
|
| `field-test` | Exercise tools/resources/prompts with real inputs, verify behavior, report issues |
|
|
268
|
+
| `tool-defs-analysis` | Read-only audit of MCP definition language across the surface — voice, leaks, defaults, recovery hints, output descriptions |
|
|
268
269
|
| `security-pass` | Audit server for MCP-flavored security gaps: output injection, scope blast radius, input sinks, tenant isolation |
|
|
270
|
+
| `code-simplifier` | Post-session cleanup against `git diff` — modernize syntax, consolidate duplication, align with the codebase |
|
|
269
271
|
| `devcheck` | Lint, format, typecheck, audit |
|
|
270
272
|
| `polish-docs-meta` | Finalize docs, README, metadata, and agent protocol for shipping |
|
|
273
|
+
| `git-wrapup` | Land working-tree changes as a versioned commit + annotated tag — version bump, changelog, verify, tag. Local only. |
|
|
274
|
+
| `release-and-publish` | Push + npm + MCP Registry + GH Release + Docker. Picks up from `git-wrapup` |
|
|
275
|
+
| `migrate-mcp-ts-template` | One-time migration of an existing project to the current framework template |
|
|
271
276
|
| `maintenance` | Investigate changelogs, adopt upstream changes, sync skills to agent dirs |
|
|
272
277
|
| `report-issue-framework` | File a bug or feature request against `@cyanheads/mcp-ts-core` via `gh` CLI |
|
|
273
278
|
| `report-issue-local` | File a bug or feature request against this server's own repo via `gh` CLI |
|
|
@@ -276,6 +281,7 @@ Available skills:
|
|
|
276
281
|
| `api-config` | AppConfig, parseConfig, env vars |
|
|
277
282
|
| `api-context` | Context interface, logger, state, progress |
|
|
278
283
|
| `api-errors` | McpError, JsonRpcErrorCode, error patterns |
|
|
284
|
+
| `api-linter` | Definition linter rule catalog — invoked by `bun run lint:mcp` and `devcheck` |
|
|
279
285
|
| `api-services` | LLM, Speech, Graph services |
|
|
280
286
|
| `api-testing` | createMockContext, test patterns |
|
|
281
287
|
| `api-utils` | Formatting, parsing, security, pagination, scheduling, telemetry helpers |
|
|
@@ -370,6 +376,8 @@ security: false # optional — true flags security fi
|
|
|
370
376
|
|
|
371
377
|
`breaking: true` renders a `· ⚠️ Breaking` badge — use it when consumers must update code on upgrade (signature changes, removed APIs, config renames). `security: true` renders a `· 🛡️ Security` badge and pairs with a `## Security` body section. When both are set, badges render `· ⚠️ Breaking · 🛡️ Security`.
|
|
372
378
|
|
|
379
|
+
`agent-notes` is an optional free-form field for maintenance agents processing the release downstream. Content here won't appear in the rendered CHANGELOG — it's consumed by agents running the `maintenance` skill. Use it for adoption instructions that don't fit the human-facing sections: new files to create, fields to populate, one-time migration steps. Omit entirely when there's nothing to say.
|
|
380
|
+
|
|
373
381
|
**Section order** (Keep a Changelog): Added, Changed, Deprecated, Removed, Fixed, Security. Include only sections with entries — don't ship empty headers.
|
|
374
382
|
|
|
375
383
|
**Tag annotations** render as GitHub Release bodies via `--notes-from-tag`. They must be structured markdown — never a flat comma-separated string. Subject omits the version number (GitHub prepends it). See `changelog/template.md` for the full format reference.
|
|
@@ -402,4 +410,7 @@ import { getMyService } from '@/services/my-domain/my-service.js';
|
|
|
402
410
|
- [ ] If wrapping external API: tests include at least one sparse payload case with omitted upstream fields
|
|
403
411
|
- [ ] Registered in `createApp()` arrays (directly or via barrel exports)
|
|
404
412
|
- [ ] Tests use `createMockContext()` from `@cyanheads/mcp-ts-core/testing`
|
|
413
|
+
- [ ] `.codex-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; `interface.displayName` = package name; `interface.shortDescription` from `package.json` description
|
|
414
|
+
- [ ] `.codex-plugin/mcp.json` updated — server name key matches `package.json` name; env vars added for any required API keys
|
|
415
|
+
- [ ] `.claude-plugin/plugin.json` populated — `name`, `version`, `description`, `repository`, `license` from `package.json`; inline `mcpServers` entry with server name key, env vars for any required API keys
|
|
405
416
|
- [ ] `npm run devcheck` passes
|
|
@@ -19,6 +19,14 @@ breaking: false
|
|
|
19
19
|
# `## Security` section below. Flagged as `Security` in the rollup so
|
|
20
20
|
# users can triage upgrade urgency at a glance.
|
|
21
21
|
security: false
|
|
22
|
+
|
|
23
|
+
# Optional free-form notes for maintenance agents processing this release.
|
|
24
|
+
# Not rendered in CHANGELOG — consumed by agents running `maintenance` on
|
|
25
|
+
# downstream servers. Use for adoption instructions that don't fit the
|
|
26
|
+
# human-facing sections: new files to create, fields to populate, one-time
|
|
27
|
+
# migration steps. Omit the field entirely when there's nothing to say.
|
|
28
|
+
# agent-notes: |
|
|
29
|
+
# <instructions for downstream maintenance agents>
|
|
22
30
|
---
|
|
23
31
|
|
|
24
32
|
# <version> — YYYY-MM-DD
|