Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The reason is simple: REST forbids a server being aware of client state. So practically, this means sessions are off limits; cookies for managing sessions are meaningless in such a world.

To send an event to a client, though, means the server must have some sort of awareness of the client. Otherwise, it wouldn't know to send the client a message in the first place.

So, can you have events in conjunction with REST? Sure. Just realize once you do that, your application isn't 100% RESTful. It's RESTful and... RESTless I guess :)




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: