PostUnit
This request returns a list of all packages.
Request URL
POST https://api.theownly.io/v1/units
Headers
| Name | Value | Required? |
|---|---|---|
| Accept | application/json | Yes |
| Authorization | Bearer{APItoken} | Yes |
Parameters
No Parameters
Example Request
curl -X 'POST' \
'https://api.theownly.io/v1/units' \
-H 'accept: application/json' \
-H 'Authorization: Bearer {APItoken}' \
-d '{
"externalId": "string",
"name": "string",
"availability": "available",
"status": "unpublished",
"floor": 0,
"price": 0,
"floorLocation": "string",
"view": "string",
"tourUrl": "string",
"uTourUrl": "string",
"building": {
"name": "string",
"description": "string",
"id": "j7AVBMAK"
},
"buildingModel": {
"name": "string",
"size": 0,
"bedrooms": 0,
"bathrooms": 0,
"longDescription": "string",
"project": {
"longDescription": "string",
"city": "Calgary",
"name": "Sandgate",
"buildingType": "string",
"state": "Alberta",
"subRegion": "string",
"websiteUrl": "string",
"address": "string",
"id": "aTMoi8hp",
"description": "string"
},
"id": "aTMoi8hp"
},
"imageUrl": "https://example.com/my-image.jpg"
}'
Example Response
201 Unit created
{
"id": "ijY4hgQht",
"externalId": "string",
"name": "string",
"availability": "available",
"status": "unpublished",
"floor": 0,
"price": 0,
"floorLocation": "string",
"view": "string",
"tourUrl": "string",
"uTourUrl": "string",
"buildingModel": {
"id": "j156XwnJ",
"name": "string",
"size": 0,
"bedrooms": 0,
"bathrooms": 0,
"longDescription": "string",
"project": {
"id": "uH7F5HkJ",
"name": "Sandgate",
"subRegion": "string",
"description": "string",
"longDescription": "string",
"address": "string",
"buildingType": "string",
"websiteUrl": "string",
"city": {
"id": "Eynvv3nd",
"name": "Calgary",
"state": "Alberta"
}
}
},
"imageUrl": "string",
"reservationUrl": "string"
}