Listings: Rooms
Supported Roles
Role | Reads | Writes | Notes |
---|---|---|---|
IDX | Yes | No | |
Public | Yes | No | |
VOW | Yes | No | |
Portal | Yes | No | |
Private | Yes | Yes |
More information about roles may be found here.
Available Services
Rooms
/<API Version>/listings/<Listing.Id>/rooms
/<API Version>/listings/incomplete/<IncompleteListing.Id>/rooms
HTTP Method | Description | Conditional | Notes |
---|---|---|---|
GET | Returns rooms for a listing with human readable labels | No | |
POST | Creates a room record. Note that the actual attributes, not the labels, must be used. | No | |
PUT | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
DELETE | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
GET Request
Parameters:
- None
GET Response
{
"Success": true,
"Results": [{
"Id": "20110525151622697369000000",
"ResourceUri": "/v1/listings/20101014195350951959000000/rooms/20110525151622697369000000",
"Fields": [{
"Room Name": "Bedroom"
},
{
"Room Level": "1"
},
{
"No. of Rooms": "2"
},
{
"Area": "40"
},
{
"Length": null
},
{
"Width": null
},
{
"Room Remarks": "Lorem ipsum dolor sit amet"
}
]
}]
}
POST Request
Request body:
{
"D":{
"Fields": {
"RoomName": "Bedroom",
"RoomLevel": "1",
"NumberOfRooms": "2",
"Area": "40",
"Length": null,
"Width": null,
"RoomRemarks": "Lorem ipsum dolor sit amet"
}
}
}
POST Response
The standard success/fail response with additional error information is returned.
Unlabeled Rooms
/<API Version>/listings/<Listing.Id>/rooms/raw
/<API Version>/listings/incomplete/<IncompleteListing.Id>/rooms/raw
HTTP Method | Description | Conditional | Notes |
---|---|---|---|
GET | Returns rooms for a listing | No | |
POST | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
PUT | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
DELETE | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
GET Request
Parameters:
- None
GET Response
{
"Success": true,
"Results": [{
"Id": "20110525151622697369000000",
"ResourceUri": "/v1/listings/20101014195350951959000000/rooms/20110525151622697369000000",
"Fields": [
{
"RoomName": "Bedroom"
},
{
"RoomLevel": "1"
},
{
"NumberOfRooms": "2"
},
{
"Area": "40"
},
{
"Length": null
},
{
"Width": null
},
{
"RoomRemarks": "Lorem ipsum dolor sit amet"
}
]
}
Individual Room
/<API Version>/listings/<Listing.Id>/rooms/<Room.Id>
/<API Version>/listings/incomplete/<IncompleteListing.Id>/rooms/<Room.Id>
HTTP Method | Description | Conditional | Notes |
---|---|---|---|
GET | Returns a specified room record | No | |
POST | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
PUT | Updates a room record. As with creation, the actual attributes, not the labels, must be used. | No | |
DELETE | Deletes a room record | No |
GET Request
Parameters:
- None
GET Response
See the GET request section for for the Rooms serivice.
PUT Request
Request body:
{
"D":{
"Fields": {
"RoomName": "Bedroom",
"RoomLevel": "1",
"NumberOfRooms": "2",
"Area": "40",
"Length": null,
"Width": null,
"RoomRemarks": "Lorem ipsum dolor sit amet"
}
}
}
PUT Response
The standard success/fail response with additional error information is returned.
DELETE Request
Parameters:
- None
DELETE Response
The standard success/fail response is returned.
Individual Unlabeled Room
/<API Version>/listings/<Listing.Id>/rooms/raw/<Room.Id>
/<API Version>/listings/incomplete/<IncompleteListing.Id>/rooms/raw/<Room.Id>
HTTP Method | Description | Conditional | Notes |
---|---|---|---|
GET | Returns a specified room record | No | |
POST | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
PUT | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
DELETE | Returns HTTP 405 (Method Not Allowed) | No | Not implemented |
GET Request
Parameters:
- None
GET Response
See the GET request section for for the Unlabeled Rooms serivice.
Listings: Rooms Description
Attribute | Data Type | Writeable | Required | Description |
---|---|---|---|---|
Id |
Character | No | No | The unique id for the room record. |
ResourceUri |
Character | No | No | The URI to the particular room record. |
Fields |
Array of JSON Objects | Yes | Yes | A list of key/value pairs for the rooms data. Available fields are listed in the Rooms Meta service. |
Expansions
None.