MCP: update_project and update_changelog
FeatureShipped· 3 days ago
Imported from GitHub pull request El-SaMa/hollahoop#123 by @El-SaMa.
Summary
- New write-scope MCP tools
update_project(name, tagline, description, accent_color, is_public; slug or id) andupdate_changelog(title, body_md, tag, publish; entry id or slug). - REST twins:
PATCH /api/v1/projects/:projectSlugandPATCH /api/v1/projects/:projectSlug/changelog/:entryId. - OpenAPI, api-docs page, MCP doc seed table and server instructions updated.
Behaviour (mirrors the dashboard actions)
update_project: same patch asupdateProjectAction, restricted to the API key's org, then layout revalidation. The dashboard applies no plan limit or audit entry to this patch, so none added.update_changelog: same rules asupdateChangelogAction. The public-safety check (publicPublishError, same aspublish_changelog) runs whenever the resulting entry is published; a blocked draft stays a draft with the guard's message. Publishing a draft setspublished_at, clears any schedule and queues email notifications.publish=falsemoves a published entry back to draft (supported by the dashboard) and keeps the original timestamp. The slug never changes. Unknown entry returnsnot_found.
Note: the server actions use cookie-auth Supabase, so they can't be called from API-key context; the tools reuse the shared helpers and the same rules instead. Webhook/SMS/voter-email fan-out that the dashboard does on publish is not included (publish_changelog doesn't do it either).
The repo's default branch is master (there is no main), so this targets master.
Tests
typecheck, lint (0 errors) and full vitest suite (260 files, 2017 tests) pass. Added tests: visibility flip, cross-org refusal, publish-guard block stays draft, unpublish, unknown entry, REST PATCH routes, registry and OpenAPI.
Generated by Claude Code
<!-- hh:closed-by:https://github.com/El-SaMa/hollahoop/pull/123 -->Closed by MCP: update_project and update_changelog