2 Commits
Author SHA1 Message Date
Monica KhouryandCharis Lam 2d5768d3c1 feat(studio): wire Platform Webhooks UI to real backend API (#51352)
## What
Wires the existing (mocked) Platform Webhooks UI to the real Management
API backend, per FE-3749.

- New `data/platform-webhooks/` query/mutation hooks, calling the real
`/v2/organizations/{slug}/webhooks/...` and
`/v2/projects/{ref}/webhooks/...` endpoints
- Updated `PlatformWebhooks.types.ts` to match the real API contract
(field names, shapes)
- Added a signing secret field to the create-endpoint form (API requires
a user-provided secret, not server-generated like the mock assumed)
- Removed the event-type column from the deliveries table (the real
list-deliveries endpoint doesn't return event type, only the
single-delivery endpoint does)
- Removed `PlatformWebhooks.mock.ts` / `.store.ts` and their tests

## Why
UI was built ~80% against mock data months ago; this closes the gap to a
real, working feature.

## Known open items (not blocking, tracked separately)
- `name` field has no backend storage yet — client-only for now, open
question with Ali/Paweł
- Deliveries table only fetches the backend's default single page — real
server-side pagination not yet wired (see FE-3750)

## Follow-up PR (stacked)
Tests for the new `data/platform-webhooks/` hooks (MSW-based), per the
ticket's own scope split.

## Testing
Manually tested end-to-end against local backend: created/edited/deleted
an endpoint, verified the real signature using webhook.site,
independently recomputed the HMAC and confirmed it matches the
`webhook-signature` header.

Linear: FE-3749

---------

Co-authored-by: Charis Lam <26616127+charislam@users.noreply.github.com>
2026-10-09 22:41:09 +03:00
Danny White 611ad867be chore(studio): webhook name (#43796)
## What kind of change does this PR introduce?

Chore

## What is the current behavior?

Endpoints have no (public) unique identifier, making it hard to
distinguish in UI.

## What is the new behavior?

Endpoints now have a name field. This is optional but strongly
encouraged:
- No _(Optional)_ on label
- Autogenerated name

Removing an endpoint name makes corresponding UI fall back the URL.

| Before | After |
| --- | --- |
| <img width="1234" height="629" alt="Settings Oldie 2 Toolshed
Supabase-CF557DE5-FA03-40E7-938E-2CC87F27C9A5"
src="https://github.com/user-attachments/assets/4b55fcb7-f8bc-4b85-a374-9ee62e452cb0"
/> | <img width="1234" height="629" alt="Settings Oldie 2 Toolshed
Supabase-74BBF142-DEC0-4626-B614-B05EBB2AC0EF"
src="https://github.com/user-attachments/assets/7ff40a91-c71a-4e20-85f8-0837d62202aa"
/> |
| <img width="1234" height="629" alt="Settings Oldie 2 Toolshed
Supabase-32A4B56C-61F5-4C1C-81DD-C455835E075F"
src="https://github.com/user-attachments/assets/f732ca50-2c60-4fbc-99c7-53afb5c34682"
/> | <img width="1234" height="629" alt="Settings Oldie 2 Toolshed
Supabase-29987973-9616-4409-9DF1-B9581112D4C3"
src="https://github.com/user-attachments/assets/0cf1db9a-fe84-4140-a2fc-bf10cf295c3b"
/> |
2026-03-18 03:08:56 +00:00