Skip to content
geoffwhittington edited this page Feb 3, 2015 · 4 revisions

Rooms: Retrieve all rooms

GET /rooms

Retrieve the list of all rooms as a JSON list of rooms

For example:

[{ "id": "54b881cc1d0e11af0e0180f9", "slug": "lobby", "name": "Lobby", "description": "Come and chat here first", "lastActive": "2015-01-31T03:12:03.581Z", "created": "2015-01-16T03:13:16.588Z", "owner": "54b78f39ab48031b077e1f80" }]

Rooms: Create

POST /rooms

Create a new room.

For example, POSTing the following

{ "slug": "room1", "name": "Room 1", "description": "My Room #1" }

will return a 201 Created and the room details:

{ id: "54d039092fbe9a8104ad9390" slug: "room1" name: "Room 1" description: "My Room #1" lastActive: "2015-02-03T02:57:13.097Z" created: "2015-02-03T02:57:13.097Z" owner: "54c55225bbdccfca06cdd490" }

Rooms: Retrieve a room

GET /rooms/:room

Retrieve information about a room given its identifier :room

For example:

GET /rooms/54d039092fbe9a8104ad9390

returns

{ id: "54d039092fbe9a8104ad9390" slug: "room1" name: "Room 1" description: "My Room #1" lastActive: "2015-02-03T02:57:13.097Z" created: "2015-02-03T02:57:13.097Z" owner: "54c55225bbdccfca06cdd490" }