Webhook test fixtures from real captures

flurryport:capture-fixture-suiteintakev1first-partysha256:b97c025bfc2dRead-only friendly

Turn captured webhooks into byte-exact test fixtures: real provider bytes, re-signed with a test secret, guarded so any reformat fails the build.

Captured real provider events become your test suite's fixtures: not sanitized approximations, the actual bytes. Export a capture verbatim with a byte-count guard against the provider's declared Content-Length, re-sign the real bytes with a test secret through your real verification path, and re-forward the same capture to drive live regression scenarios without ever re-creating provider state. Shopify-first examples; the discipline works for any provider that posts webhooks.

The credential never enters the model context: it lives in the FlurryPORT secret store, deliveries are signed server-side, and every send returns a receipt your agent can quote.

What this is

Your webhook handler's test suite, seeded from reality. Every event that reaches a FlurryPORT endpoint is stored byte-for-byte as a capture: body, headers, declared Content-Length, signature included. This recipe turns those captures into test fixtures with a chain of custody: files whose bytes provably match what the provider sent, re-signed in tests with a test secret, and verified through your real authentication path.

Why real bytes

Hand-written mocks drift from reality the day they are written. Real payloads carry what no mock author thinks to include: the field that only appears on the update trailing a cancellation, the thin payload that cannot deserialize as its sibling events, the provider's own serializer quirks. A fixture built from captured bytes tests your handler against what production will actually send, because it is what production actually sent.

The fidelity guard

Each fixture records the Content-Length the provider declared on delivery, and a test asserts the fixture's byte count still matches. If anyone pretty-prints a fixture, the build fails. That is the point: a reformatted fixture is a fixture whose signature can never verify again, and the guard turns that silent invalidation into a red build.

The regression leg

A capture is also a durable regression asset. Change your code, then re-forward the same stored event to your local handler: no provider round-trip, no clicking through a store to create fresh test data, no waiting. One captured event can drive the happy path, a redelivery idempotency check, a wrong-signature rejection, and any state-dependent branch you can dress up locally. The first suite seeded this way went from zero tests to thirty in a day, every one anchored to a real captured event.

Your secret stays yours

FlurryPORT never needs your webhook secret. The provider's signature travels with the capture, and verification happens only in your code, with your copy of the secret. In tests, you re-sign the real bytes with a test secret, so the production secret never enters the repository and the fixtures stay shareable.

What to expect

The footprint is one capture endpoint: no replay targets, no transformations, no watches. Exported fixtures are yours forever; the re-forward leg needs the capture to still exist, and captures age out with your plan's retention window unless saved to a collection. Byte-exact work requires a session token minted without privacy redaction, because masked bytes cannot match a signature. The security model is documented on the endpoint security page.

Install with your agent

npx flurryport mcp

Point your agent at the FlurryPORT MCP server (npx flurryport mcp) and ask it for the flurryport:capture-fixture-suite recipe. Works from AI clients that can run a local process: desktop apps and terminal agents. Web-only chat clients cannot reach a local MCP server; open a desktop client instead.

Gotchas

Where this fits

Related recipes

flurryport:airtable-adddelivery

Let your AI add records to an Airtable table; the token stays server-side.

flurryport:azure-devops-managedelivery

Create and update Azure DevOps work items in one batched pipe: priority, state, tags, and sprint included.

flurryport:azure-devops-querydelivery

Query Azure DevOps work items with WIQL and read the matching ids back, without your AI ever holding the PAT.

flurryport:azure-devops-readdelivery

Read fields for a batch of Azure DevOps work items by id: title, state, tags, priority, iteration.

flurryport:azure-devops-workitemdelivery

Let your AI file Azure DevOps work items (bugs, tasks) the model never holds credentials for.

flurryport:discord-postdelivery

Let your AI post to Discord through a channel webhook the model never sees.