Free fake Server-send Events for testing and prototyping.
Go to file
2022-03-04 11:33:29 +01:00
app/website The first commit 2022-03-04 11:33:29 +01:00
sse_fake The first commit 2022-03-04 11:33:29 +01:00
static The first commit 2022-03-04 11:33:29 +01:00
.gitignore The first commit 2022-03-04 11:33:29 +01:00
Caddyfile The first commit 2022-03-04 11:33:29 +01:00
django-launcher.sh The first commit 2022-03-04 11:33:29 +01:00
docker-compose.yml The first commit 2022-03-04 11:33:29 +01:00
Dockerfile The first commit 2022-03-04 11:33:29 +01:00
manage.py The first commit 2022-03-04 11:33:29 +01:00
README.md The first commit 2022-03-04 11:33:29 +01:00
requirements.txt The first commit 2022-03-04 11:33:29 +01:00

SSE Fake

Free fake Server-side Events for testing and prototyping.

Try it

Run this code in JavaScript or from any site:

const sse = new EventSource("https://sse-fake.andros.dev/events/");

sse.onmessage = function(event) {
  console.log(event.data);
}

Or from the terminal:

curl https://sse-fake.andros.dev/events/

Events

Between 1 to 5 seconds, you will randomly receive one of the following messages:

  • User connected
{
	"action": "User connected",
	"name": [random name]
}
  • User disconnected
{
	"action": "User disconnected",
	"name": [random name]
}
  • New message
{
	"action": "New message",
	"name": [random name],
	"text": [random text]
}

Made with ♥️, Django, Channels and Django EventStream.

Author: Andros Fenollosa