Without flusher.Flush() after WriteHeader, the HTTP response headers
were buffered and never sent to the client, causing SSE clients to hang
indefinitely waiting for the initial response.
- Add flusher.Flush() after WriteHeader in HandleSSE
- Add TestSSEStreamReceivesEventOnCapture integration test:
starts test server, subscribes to SSE, captures a request, and
verifies the event arrives within 2s
Co-Authored-By: Paperclip <noreply@paperclip.ing>
- Add POST /e/{endpoint}/requests/{id}/replay endpoint
- Replay re-sends captured method, path, headers, query, body to target URL
- Response includes target status code, headers, body (truncated 64KB)
- SSRF guard: denies replay to private/loopback by default
- Opt-in env var HATCH_ALLOW_PRIVATE_REPLAY=true for local dev
- Server-rendered inspect page at GET /e/{endpoint} with replay button UI
- SSE live stream for new requests (EventSource)
- Mock configuration at PUT /e/{endpoint}/mock
- Store: GetRequest, GetMock, SetMock methods added
- Chi router migration from stdlib ServeMux
- 26 passing tests including replay unit tests and E2E capture-to-replay
Co-Authored-By: Paperclip <noreply@paperclip.ing>