Find file
Fetching contributors…
Cannot retrieve contributors at this time
16 lines (14 sloc) 528 Bytes
GET /api/rooms/<roomname> -> [json] serve up page data (heartbeat api call)
:user => <username>,
:room => <room-name>,
:votes => {
<username> => <vote>
GET /api/rooms -> [json] list of room names
POST /api/rooms/<roomname> body is json vote info
{ :vote => <vote-value> }
POST /api/rooms/<roomname>/reset empty body; reset the votes
POST /api/rooms/<roomname>/login?redirect_to=<url>
GET /rooms/<roomname> serve up main room page; bounce to / if the username cookie is not set
GET / view of all the rooms
GET /login