Real-time APIs
medium 27 minHTTP lets the client ask and the server answer.
Where it shows up
The same pattern appears across everyday software.
Team chat
Slack and Discord give apps a WebSocket. Discord's gateway has heartbeats and a resume step with the last sequence number.
Generated text
Language model APIs stream the answer as server-sent events, so people read while the rest is written.
Editing together
Design and document editors send small changes both ways over a WebSocket and resend what was not acknowledged.
Build logs
The page shows each line as it is produced. One way and text: a good fit for SSE.
Delivery tracking
The courier's phone posts its position every few seconds. Watching customers get it pushed, at most once a second.
Queue consumers
Amazon SQS lets a receive call wait up to 20 seconds: long polling between servers, to avoid empty answers.