curl --request POST \
--url https://v2.api.uk.housr.com/create-property \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"title": "Spacious 4-bed near campus",
"description": "Modern kitchen, large garden.",
"address": "12 Oxford Road",
"city": "Manchester",
"images": [
"https://cdn.example.com/img/1.jpg",
"https://cdn.example.com/img/2.jpg"
],
"price_pw": 180,
"bedrooms": 4,
"bathrooms": 2,
"postcode": "M13 9PL",
"number_available": 1,
"lat": 53.467,
"lng": -2.233,
"deposit": 200
}
'
{
"propertyId": 12345,
"message": "Property successfully uploaded"
}{
"response": "Invalid JSON in request body"
}{
"response": "Missing or invalid authentication token"
}{
"response": "Validation failed",
"errors": {
"title": [
"Title cannot be empty"
],
"price_pw": [
"Price must be a positive number"
]
}
}Properties
Create a property
Creates a new property record
POST
/
create-property
curl --request POST \
--url https://v2.api.uk.housr.com/create-property \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"title": "Spacious 4-bed near campus",
"description": "Modern kitchen, large garden.",
"address": "12 Oxford Road",
"city": "Manchester",
"images": [
"https://cdn.example.com/img/1.jpg",
"https://cdn.example.com/img/2.jpg"
],
"price_pw": 180,
"bedrooms": 4,
"bathrooms": 2,
"postcode": "M13 9PL",
"number_available": 1,
"lat": 53.467,
"lng": -2.233,
"deposit": 200
}
'
{
"propertyId": 12345,
"message": "Property successfully uploaded"
}{
"response": "Invalid JSON in request body"
}{
"response": "Missing or invalid authentication token"
}{
"response": "Validation failed",
"errors": {
"title": [
"Title cannot be empty"
],
"price_pw": [
"Price must be a positive number"
]
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/jsonapplication/x-www-form-urlencoded
Array of image URLs, each their own comma-separated string
Weekly price as a string to preserve precision
Required range:
x >= 0Required range:
x >= 0Defaults to 0 if not supplied
⌘I

