Repository navigation
feat(api): typed response structs, batch 6 — webhooks, schedules, keys (#1196) - #1208
Merged
Merged
Conversation
#1196) API key issue and revoke, the schedule list/create/toggle/delete, and the webhook list/create/delete, deliveries and event catalog now return Serialize + ToSchema structs. Deleted is shared by every {deleted} body, so delete_salesforce_connection is typed too. 12 more operations publish a $ref success schema (52 -> 64). WebhookItem projects the secret-free WebhookWire to the four fields the list served, and deliveries serialize through WebhookDeliveryWire, which is field-identical to the entity. Value equality against the previous json! builds is pinned in response_shape_tests; envelopes.json is unchanged. Co-Authored-By: Claude Opus 5.5 <[email protected]>
athvin
marked this pull request as ready for review
November 24, 2026 16:24
Contributor
|
The marketing preview was removed because this PR is closed or merged. |
athvin
temporarily deployed
to
marketing-preview
November 24, 2026 16:34 — with
GitHub Actions
Inactive
This was referenced Nov 24, 2026
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #1196
Part of #864 (batch 6 of 10: webhooks+schedules+keys).
What
Batch 6 of #864 converts API key issue and revoke, schedules (list, create, toggle, delete), and webhooks (list, create, delete, deliveries, event catalog) to typed structs. The shared
Deletedalso typesdelete_salesforce_connection. 12 more operations now publish a$refsuccess schema (52 → 64 of 119).Why
OpenAPI is the customer integration contract (#857). Keys and webhooks are how an integrator authenticates and listens.
Proof
make check: 1,154 passed, 0 failed.er-server --testsagainst Postgres: 388 passed.tsc --noEmitis clean against the regeneratedschema.d.ts.envelopes.jsonis unchanged.Risk & rollback
Bodies are value-equal to the old ones; only key order changes. The webhook list still never includes the secret. Rollback:
git revert <merge-sha>.Post-merge ledger
Closed by: agent · session
Claude Code:d1e3b2dc-3174-4091-9c30-c08fc4820306onMac· 2026-11-24T16:46:59Zmainis green with this change on it: mergee51245be. The push runsrust45438713482 andfrontend45438714082, plusinfra,devcontainerandmarketing preview, all succeeded.imagesbuilt: run 45438713441, success.deployconverged: run 45439753778 succeeded withDEPLOY_SHA: e51245be…. Process proof, read 2026-11-25 after SSO was renewed: the live colour in dev (ci/web-api-blue) and prod (app/web-api-green) runser-api@sha256:e935e7e5…. ECR tags that digest8bd3c294(feat(api): self-service API keys — admin minting with a role ceiling, list, show-once UI (#866) #1216's merge), which contains this merge (e51245be) as an ancestor, and both pods logged"er-server listening","addr":"0.0.0.0:8000"at 08:11Z.driftandkindwere already red on schedule before feat(api): typed response structs, batch 3 — reviews+merges (#1193) #1202. The nightly golden-50k flake is scale golden (50k) fails deterministically on main since 03792063..ad38be23 (likely the DuckDB 2.0.1 bump) #1206.api-contractrules.Specific to this change
Context — plan, discoveries, measurements, files
Plan
KeyIssued,KeyRevoked,Deleted,ScheduleItem(From<&pg::ScheduleRow>),ScheduleCreated,ScheduleToggled,WebhookItem(From<&WebhookWire>, the four list fields),WebhookCreated,WebhookDeliveryList(WebhookDeliveryWire, field-identical to the entity),WebhookEventCatalog/WebhookEventItem.response_shape_tests. The catalog is compared againstwebhook::catalog_json().Discoveries
Measurements
Files
rust/crates/er-server/src/{lib.rs,openapi.rs},frontend/src/lib/api/{openapi.json,openapi.public.json,schema.d.ts}