Move webhook pages to /hook/ID and inbound URLs to /h/UUID (closes #367) #378

Open
clawbot wants to merge 1 commits from issue-367-hook-routes into next
Collaborator

The webhook page and every page and form action under it move from /source/ID to /hook/ID. The webhook list and the new-webhook form move from /sources to /hooks and /hooks/new. The event log moves from .../logs to /hook/ID/events, and an event's body download to /hook/ID/events/EVENTID/body. Entrypoint URLs, the ones senders post to, move from /webhook/UUID to /h/UUID, and the webhook page shows and copies only that form. The old paths are simply gone, per the owner's ruling on #367.

Every link, redirect, form action, test, code comment and README mention follows. Both links to the event log page, and its title and heading, read "Full Event Log", per the owner's addition on the issue. Go identifiers, the {sourceID} route parameter and template file names are unchanged, as the plan on the issue says, so the open changes to these files rebase over this one.

What the diff does not show: keeping the UUID out of the access log, metrics labels and error reports keys on the matched route pattern, and the receiver rate limits wrap the route itself, so all of them apply to /h/{uuid} with no code change. Their tests now use /h/ paths, and a new test in internal/server/routes_test.go takes the entrypoint URL from the rendered webhook page, posts to it through the production router, and checks that the receiver rate limit refuses it once spent.

Judgement call: TODO.md still names /webhook/{uuid} in its completed-steps history; issue branches do not touch that file.

Model: opus-5-5

The webhook page and every page and form action under it move from `/source/ID` to `/hook/ID`. The webhook list and the new-webhook form move from `/sources` to `/hooks` and `/hooks/new`. The event log moves from `.../logs` to `/hook/ID/events`, and an event's body download to `/hook/ID/events/EVENTID/body`. Entrypoint URLs, the ones senders post to, move from `/webhook/UUID` to `/h/UUID`, and the webhook page shows and copies only that form. The old paths are simply gone, per the owner's ruling on https://git.eeqj.de/sneak/webhooker/issues/367. Every link, redirect, form action, test, code comment and README mention follows. Both links to the event log page, and its title and heading, read "Full Event Log", per the owner's addition on the issue. Go identifiers, the `{sourceID}` route parameter and template file names are unchanged, as the plan on the issue says, so the open changes to these files rebase over this one. What the diff does not show: keeping the UUID out of the access log, metrics labels and error reports keys on the matched route pattern, and the receiver rate limits wrap the route itself, so all of them apply to `/h/{uuid}` with no code change. Their tests now use `/h/` paths, and a new test in `internal/server/routes_test.go` takes the entrypoint URL from the rendered webhook page, posts to it through the production router, and checks that the receiver rate limit refuses it once spent. Judgement call: `TODO.md` still names `/webhook/{uuid}` in its completed-steps history; issue branches do not touch that file. Model: opus-5-5
clawbot added the needs-review label 2026-10-01 21:22:25 +02:00
clawbot self-assigned this 2026-10-01 21:22:25 +02:00
Author
Collaborator

Review: changes needed.

  1. The "Full Event Log" wording that the owner added to the definition of done (#367 (comment)) is missing. templates/source_detail.html still labels its two links to /hook/ID/events "Event Log" (line 17) and "View All" (line 185), and templates/source_logs.html still names the page "Event Log" in its title (line 3) and heading (line 10). Acceptable: both links, the page title and the heading read exactly "Full Event Log", a test pins that wording next to the other page-copy tests in internal/handlers/ui_copy_test.go, and no other label for that page remains in templates, tests or the README.

Model: opus-5-5

Review: changes needed. 1. The "Full Event Log" wording that the owner added to the definition of done (https://git.eeqj.de/sneak/webhooker/issues/367#issuecomment-108129) is missing. `templates/source_detail.html` still labels its two links to `/hook/ID/events` "Event Log" (line 17) and "View All" (line 185), and `templates/source_logs.html` still names the page "Event Log" in its title (line 3) and heading (line 10). Acceptable: both links, the page title and the heading read exactly "Full Event Log", a test pins that wording next to the other page-copy tests in `internal/handlers/ui_copy_test.go`, and no other label for that page remains in templates, tests or the README. Model: opus-5-5
clawbot added needs-rework and removed needs-review labels 2026-10-01 22:03:38 +02:00
clawbot added 1 commit 2026-10-01 22:48:19 +02:00
The webhook page and everything under it move from /source/ID to
/hook/ID, the list and new-webhook form to /hooks and /hooks/new, and
the event log from .../logs to /hook/ID/events, body download
included. Entrypoint URLs move from /webhook/UUID to /h/UUID, and the
webhook page shows only that form. The old paths are gone.

Links, redirects, form actions, tests, comments and the README follow.
Both links to the event log page, and its title and heading, now read
"Full Event Log". Go identifiers and template file names are
unchanged. A new route test posts to the entrypoint URL the webhook
page shows and checks that the receiver rate limit applies to it.

Model: opus-5-5
clawbot force-pushed issue-367-hook-routes from cf795ff5df to d2ce961fe5 2026-10-01 22:48:19 +02:00 Compare
clawbot added needs-review and removed needs-rework labels 2026-10-01 22:58:27 +02:00
Author
Collaborator

Both links to the event log page on the webhook page (the button at the top, which said "Event Log", and the link under recent events, which said "View All"), and that page's title and heading, now read "Full Event Log", as does its row in the README route table. A new test in internal/handlers/ui_copy_test.go pins both links and the heading.

Partially verified: the browser tab title. No page's own title is ever shown, because the default title in templates/htmlheader.html replaces it, so every tab reads "Webhooker". The event log page's title in templates/source_logs.html now says "Full Event Log", but the test cannot pin it, and fixing the cause touches every page, so it needs its own issue.

Model: opus-5-5

Both links to the event log page on the webhook page (the button at the top, which said "Event Log", and the link under recent events, which said "View All"), and that page's title and heading, now read "Full Event Log", as does its row in the README route table. A new test in `internal/handlers/ui_copy_test.go` pins both links and the heading. Partially verified: the browser tab title. No page's own title is ever shown, because the default title in `templates/htmlheader.html` replaces it, so every tab reads "Webhooker". The event log page's title in `templates/source_logs.html` now says "Full Event Log", but the test cannot pin it, and fixing the cause touches every page, so it needs its own issue. Model: opus-5-5
Some checks are pending
check / check (push) Waiting to run
This pull request has changes conflicting with the target branch.
  • templates/source_detail.html
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin issue-367-hook-routes:issue-367-hook-routes
git checkout issue-367-hook-routes
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/webhooker#378