Skip to main content

Properties API

Endpoints for managing property projects.

Property Object​

{
"id": "prop_123abc",
"name": "Sunset Villas",
"type": "villa",
"status": "under_construction",
"location": {
"address": "Jl. Pantai Batu Mejan",
"area": "Canggu",
"city": "Badung",
"country": "Indonesia",
"coordinates": {
"lat": -8.6478,
"lng": 115.1385
}
},
"description": "Luxury villa development...",
"media": {
"cover": "https://cdn.propertybase.ai/...",
"gallery": ["https://cdn.propertybase.ai/..."],
"floor_plans": ["https://cdn.propertybase.ai/..."],
"virtual_tour": "https://my.matterport.com/..."
},
"pricing": {
"currency": "USD",
"min_price": 750000,
"max_price": 1500000
},
"features": ["pool", "garden", "parking"],
"units_count": 12,
"units_available": 8,
"completion_date": "2025-06-30",
"created_at": "2024-01-15T10:30:00Z",
"updated_at": "2024-01-20T14:00:00Z"
}

List Properties​

GET /v1/properties

Query Parameters​

ParameterTypeDescription
statusstringFilter by status
typestringFilter by property type
min_pricenumberMinimum price
max_pricenumberMaximum price
locationstringFilter by area/city
sortstringSort field
orderstringSort order (asc/desc)
pagenumberPage number
per_pagenumberResults per page

Example Request​

curl -X GET "https://api.propertybase.ai/v1/properties?status=completed&type=villa&per_page=10" \
-H "Authorization: Bearer YOUR_API_KEY"

Example Response​

{
"success": true,
"data": [
{
"id": "prop_123abc",
"name": "Sunset Villas",
"type": "villa",
"status": "completed",
"pricing": {
"currency": "USD",
"min_price": 750000,
"max_price": 1500000
},
"units_available": 8
}
],
"meta": {
"page": 1,
"per_page": 10,
"total": 25,
"total_pages": 3
}
}

Get Property​

GET /v1/properties/:id

Example Request​

curl -X GET "https://api.propertybase.ai/v1/properties/prop_123abc" \
-H "Authorization: Bearer YOUR_API_KEY"

Example Response​

{
"success": true,
"data": {
"id": "prop_123abc",
"name": "Sunset Villas",
"type": "villa",
"status": "completed",
"location": {
"address": "Jl. Pantai Batu Mejan",
"area": "Canggu",
"city": "Badung",
"country": "Indonesia"
},
"description": "Luxury villa development featuring 12 exclusive residences...",
"pricing": {
"currency": "USD",
"min_price": 750000,
"max_price": 1500000
},
"units_count": 12,
"units_available": 8
}
}

Create Property​

POST /v1/properties

Request Body​

FieldTypeRequiredDescription
namestringYesProperty name
typestringYesProperty type
statusstringNoStatus (default: planning)
locationobjectYesLocation details
descriptionstringNoProperty description
pricingobjectNoPricing configuration
featuresarrayNoFeature tags
completion_datestringNoExpected completion

Example Request​

curl -X POST "https://api.propertybase.ai/v1/properties" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Ocean View Apartments",
"type": "apartment",
"status": "under_construction",
"location": {
"address": "123 Beach Road",
"area": "Seminyak",
"city": "Badung",
"country": "Indonesia"
},
"description": "Modern beachfront apartments...",
"pricing": {
"currency": "USD",
"min_price": 200000,
"max_price": 500000
},
"features": ["beach_access", "pool", "gym"],
"completion_date": "2025-12-31"
}'

Example Response​

{
"success": true,
"data": {
"id": "prop_456def",
"name": "Ocean View Apartments",
"type": "apartment",
"status": "under_construction",
"created_at": "2024-01-25T09:00:00Z"
}
}

Update Property​

PUT /v1/properties/:id

Example Request​

curl -X PUT "https://api.propertybase.ai/v1/properties/prop_123abc" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"status": "completed",
"completion_date": "2024-12-15"
}'

Example Response​

{
"success": true,
"data": {
"id": "prop_123abc",
"name": "Sunset Villas",
"status": "completed",
"completion_date": "2024-12-15",
"updated_at": "2024-01-25T10:00:00Z"
}
}

Delete Property​

DELETE /v1/properties/:id
warning

Deleting a property also deletes all associated units. This action cannot be undone.

Example Request​

curl -X DELETE "https://api.propertybase.ai/v1/properties/prop_123abc" \
-H "Authorization: Bearer YOUR_API_KEY"

Example Response​

{
"success": true,
"data": {
"id": "prop_123abc",
"deleted": true
}
}

Get Property Units​

GET /v1/properties/:id/units

Returns all units belonging to a property.

Example Request​

curl -X GET "https://api.propertybase.ai/v1/properties/prop_123abc/units" \
-H "Authorization: Bearer YOUR_API_KEY"

Property Types​

ValueDescription
villaStandalone villa
apartmentApartment unit
townhouseTownhouse
penthousePenthouse
commercialCommercial space
landLand plot
mixed_useMixed-use development

Property Status​

ValueDescription
planningIn planning phase
under_constructionCurrently being built
completedConstruction complete
sold_outAll units sold
archivedNo longer active