curl -N -H 'Accept: text/event-stream' http://localhost:3000/events

Category: Web App Development

curl -N -H 'Accept: text/event-stream' http://localhost:3000/events

Stream server-sent events from an endpoint

Connects to an SSE endpoint and prints each event as it arrives. Server-sent events are a one-way push channel over plain HTTP, unlike WebSockets which are two-way. The -N flag disables buffering so events show up immediately. Press Ctrl+C to disconnect.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.