feat(server): add delete_hook DELETE-tier tool #17

Merged
David merged 1 commit from feat/delete-hook-tool-fjmcp-16 into main 2026-06-14 23:16:29 +02:00
Owner

Problem

The webhook tool family (FJMCP-12) shipped create_hook, edit_hook, get_hook, list_hooks, and test_hook, but delete_hook was never added. It was nonetheless advertised as a DELETE-tier tool in README.md:161 and in the get_info instructions (src/server.rs:4243), so an agent reading either surface and calling delete_hook got a method-not-found error. This was the only gap in the fj-core operation surface (153 of 154 functions wired) and left epic FJMCP-9 acceptance criterion 3 unmet.

Change

Add the delete_hook #[tool], mirroring the existing delete_deploy_key DELETE-tier tool:

  • DELETE-tier gated via self.require(Tier::Delete)?.
  • Reuses the existing HookIdParams (owner, repo, id); no new params struct.
  • Calls fj_core::repo::delete_hook and returns { deleted: true, id }.

README.md and get_info already describe exactly this tool and return shape, so no documentation change is needed; this PR makes those claims true.

Verification

just check (fmt, clippy, build, Docker builder compile) and just test (41 passed) both green.

#FJMCP-16

## Problem The webhook tool family (FJMCP-12) shipped `create_hook`, `edit_hook`, `get_hook`, `list_hooks`, and `test_hook`, but `delete_hook` was never added. It was nonetheless advertised as a DELETE-tier tool in `README.md:161` and in the `get_info` instructions (`src/server.rs:4243`), so an agent reading either surface and calling `delete_hook` got a method-not-found error. This was the only gap in the fj-core operation surface (153 of 154 functions wired) and left epic FJMCP-9 acceptance criterion 3 unmet. ## Change Add the `delete_hook` `#[tool]`, mirroring the existing `delete_deploy_key` DELETE-tier tool: - DELETE-tier gated via `self.require(Tier::Delete)?`. - Reuses the existing `HookIdParams` (`owner`, `repo`, `id`); no new params struct. - Calls `fj_core::repo::delete_hook` and returns `{ deleted: true, id }`. `README.md` and `get_info` already describe exactly this tool and return shape, so no documentation change is needed; this PR makes those claims true. ## Verification `just check` (fmt, clippy, build, Docker builder compile) and `just test` (41 passed) both green. #FJMCP-16
feat(server): add delete_hook DELETE-tier tool
All checks were successful
Check / fmt + clippy + build + tests (pull_request) Successful in 39s
Create release / Create release from merged PR (pull_request) Has been skipped
f707d62636
The webhook tool family shipped create_hook, edit_hook, get_hook, list_hooks, and test_hook but never the delete_hook tool, even though fj-core exposes repo::delete_hook and both README.md and the get_info instructions already advertise delete_hook as a DELETE-tier tool. Calling it returned method-not-found. This was the sole gap in the otherwise complete fj-core operation surface (153/154), so it also closed epic FJMCP-9 acceptance criterion 3.

Mirror the existing delete_deploy_key tool: DELETE-tier gated via require(Tier::Delete), reuse HookIdParams, call fj_core::repo::delete_hook, return { deleted: true, id }. README and get_info already describe this shape, so no doc change is needed.

#FJMCP-16
David merged commit 9758f3ee81 into main 2026-06-14 23:16:29 +02:00
David deleted branch feat/delete-hook-tool-fjmcp-16 2026-06-14 23:16:29 +02:00
Commenting is not possible because the repository is archived.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
pandoras-box/forgejo-mcp!17
No description provided.