curl --request PATCH \
--url https://app.planpoint.io/api/units/{id} \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"_id": "<string>",
"floor": "<string>",
"name": "<string>",
"bedrooms": "<string>",
"squareFeet": 123,
"isFeatured": false,
"price": 123,
"unitPriceTBD": false,
"type": "<string>",
"specificType": "<string>",
"availability": "<string>",
"path": "<string>",
"lotPath": "<string>",
"unitImageUrl": "<string>",
"onHoldExpiresAt": "2023-11-07T05:31:56Z",
"layoutUrl": "<string>",
"layoutGallery": [
"<string>"
],
"downloadableAsset": "<string>",
"brochurePDF": "<string>",
"additionalInfo": [
{
"label": "<string>",
"value": "<string>"
}
],
"embedCode": "<string>",
"customButtonUrl": "",
"payableAmount": 123,
"customButtonSnippet": "",
"images": [
"<string>"
],
"clonedImages": [
"<string>"
],
"customFinishes": {
"type": {
"name": "<string>",
"options": {
"kitchen": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"bathroom": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"general": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
}
}
},
"default": {}
},
"finishes": [
"<string>"
],
"clonedFinishes": [
"<string>"
],
"parking": 123,
"bathrooms": 123,
"orientation": "<string>",
"inclusions": "<string>",
"deliveryDate": "<string>",
"description": "<string>",
"unitmodels": [
"<string>"
],
"lon": -93.75940812944683,
"lat": 43.75940812944682,
"perimeter": "<string>",
"svgLotId": "<string>"
}
'import requests
url = "https://app.planpoint.io/api/units/{id}"
payload = {
"_id": "<string>",
"floor": "<string>",
"name": "<string>",
"bedrooms": "<string>",
"squareFeet": 123,
"isFeatured": False,
"price": 123,
"unitPriceTBD": False,
"type": "<string>",
"specificType": "<string>",
"availability": "<string>",
"path": "<string>",
"lotPath": "<string>",
"unitImageUrl": "<string>",
"onHoldExpiresAt": "2023-11-07T05:31:56Z",
"layoutUrl": "<string>",
"layoutGallery": ["<string>"],
"downloadableAsset": "<string>",
"brochurePDF": "<string>",
"additionalInfo": [
{
"label": "<string>",
"value": "<string>"
}
],
"embedCode": "<string>",
"customButtonUrl": "",
"payableAmount": 123,
"customButtonSnippet": "",
"images": ["<string>"],
"clonedImages": ["<string>"],
"customFinishes": {
"type": {
"name": "<string>",
"options": {
"kitchen": { "tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
] },
"bathroom": { "tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
] },
"general": { "tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
] }
}
},
"default": {}
},
"finishes": ["<string>"],
"clonedFinishes": ["<string>"],
"parking": 123,
"bathrooms": 123,
"orientation": "<string>",
"inclusions": "<string>",
"deliveryDate": "<string>",
"description": "<string>",
"unitmodels": ["<string>"],
"lon": -93.75940812944683,
"lat": 43.75940812944682,
"perimeter": "<string>",
"svgLotId": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
_id: '<string>',
floor: '<string>',
name: '<string>',
bedrooms: '<string>',
squareFeet: 123,
isFeatured: false,
price: 123,
unitPriceTBD: false,
type: '<string>',
specificType: '<string>',
availability: '<string>',
path: '<string>',
lotPath: '<string>',
unitImageUrl: '<string>',
onHoldExpiresAt: '2023-11-07T05:31:56Z',
layoutUrl: '<string>',
layoutGallery: ['<string>'],
downloadableAsset: '<string>',
brochurePDF: '<string>',
additionalInfo: [{label: '<string>', value: '<string>'}],
embedCode: '<string>',
customButtonUrl: '',
payableAmount: 123,
customButtonSnippet: '',
images: ['<string>'],
clonedImages: ['<string>'],
customFinishes: {
type: {
name: '<string>',
options: {
kitchen: {tabs: [{label: '<string>', cover: '<string>', thumbnail: '<string>'}]},
bathroom: {tabs: [{label: '<string>', cover: '<string>', thumbnail: '<string>'}]},
general: {tabs: [{label: '<string>', cover: '<string>', thumbnail: '<string>'}]}
}
},
default: {}
},
finishes: ['<string>'],
clonedFinishes: ['<string>'],
parking: 123,
bathrooms: 123,
orientation: '<string>',
inclusions: '<string>',
deliveryDate: '<string>',
description: '<string>',
unitmodels: ['<string>'],
lon: -93.75940812944683,
lat: 43.75940812944682,
perimeter: '<string>',
svgLotId: '<string>'
})
};
fetch('https://app.planpoint.io/api/units/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.planpoint.io/api/units/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'_id' => '<string>',
'floor' => '<string>',
'name' => '<string>',
'bedrooms' => '<string>',
'squareFeet' => 123,
'isFeatured' => false,
'price' => 123,
'unitPriceTBD' => false,
'type' => '<string>',
'specificType' => '<string>',
'availability' => '<string>',
'path' => '<string>',
'lotPath' => '<string>',
'unitImageUrl' => '<string>',
'onHoldExpiresAt' => '2023-11-07T05:31:56Z',
'layoutUrl' => '<string>',
'layoutGallery' => [
'<string>'
],
'downloadableAsset' => '<string>',
'brochurePDF' => '<string>',
'additionalInfo' => [
[
'label' => '<string>',
'value' => '<string>'
]
],
'embedCode' => '<string>',
'customButtonUrl' => '',
'payableAmount' => 123,
'customButtonSnippet' => '',
'images' => [
'<string>'
],
'clonedImages' => [
'<string>'
],
'customFinishes' => [
'type' => [
'name' => '<string>',
'options' => [
'kitchen' => [
'tabs' => [
[
'label' => '<string>',
'cover' => '<string>',
'thumbnail' => '<string>'
]
]
],
'bathroom' => [
'tabs' => [
[
'label' => '<string>',
'cover' => '<string>',
'thumbnail' => '<string>'
]
]
],
'general' => [
'tabs' => [
[
'label' => '<string>',
'cover' => '<string>',
'thumbnail' => '<string>'
]
]
]
]
],
'default' => [
]
],
'finishes' => [
'<string>'
],
'clonedFinishes' => [
'<string>'
],
'parking' => 123,
'bathrooms' => 123,
'orientation' => '<string>',
'inclusions' => '<string>',
'deliveryDate' => '<string>',
'description' => '<string>',
'unitmodels' => [
'<string>'
],
'lon' => -93.75940812944683,
'lat' => 43.75940812944682,
'perimeter' => '<string>',
'svgLotId' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.planpoint.io/api/units/{id}"
payload := strings.NewReader("{\n \"_id\": \"<string>\",\n \"floor\": \"<string>\",\n \"name\": \"<string>\",\n \"bedrooms\": \"<string>\",\n \"squareFeet\": 123,\n \"isFeatured\": false,\n \"price\": 123,\n \"unitPriceTBD\": false,\n \"type\": \"<string>\",\n \"specificType\": \"<string>\",\n \"availability\": \"<string>\",\n \"path\": \"<string>\",\n \"lotPath\": \"<string>\",\n \"unitImageUrl\": \"<string>\",\n \"onHoldExpiresAt\": \"2023-11-07T05:31:56Z\",\n \"layoutUrl\": \"<string>\",\n \"layoutGallery\": [\n \"<string>\"\n ],\n \"downloadableAsset\": \"<string>\",\n \"brochurePDF\": \"<string>\",\n \"additionalInfo\": [\n {\n \"label\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"embedCode\": \"<string>\",\n \"customButtonUrl\": \"\",\n \"payableAmount\": 123,\n \"customButtonSnippet\": \"\",\n \"images\": [\n \"<string>\"\n ],\n \"clonedImages\": [\n \"<string>\"\n ],\n \"customFinishes\": {\n \"type\": {\n \"name\": \"<string>\",\n \"options\": {\n \"kitchen\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"bathroom\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"general\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n }\n }\n },\n \"default\": {}\n },\n \"finishes\": [\n \"<string>\"\n ],\n \"clonedFinishes\": [\n \"<string>\"\n ],\n \"parking\": 123,\n \"bathrooms\": 123,\n \"orientation\": \"<string>\",\n \"inclusions\": \"<string>\",\n \"deliveryDate\": \"<string>\",\n \"description\": \"<string>\",\n \"unitmodels\": [\n \"<string>\"\n ],\n \"lon\": -93.75940812944683,\n \"lat\": 43.75940812944682,\n \"perimeter\": \"<string>\",\n \"svgLotId\": \"<string>\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://app.planpoint.io/api/units/{id}")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"_id\": \"<string>\",\n \"floor\": \"<string>\",\n \"name\": \"<string>\",\n \"bedrooms\": \"<string>\",\n \"squareFeet\": 123,\n \"isFeatured\": false,\n \"price\": 123,\n \"unitPriceTBD\": false,\n \"type\": \"<string>\",\n \"specificType\": \"<string>\",\n \"availability\": \"<string>\",\n \"path\": \"<string>\",\n \"lotPath\": \"<string>\",\n \"unitImageUrl\": \"<string>\",\n \"onHoldExpiresAt\": \"2023-11-07T05:31:56Z\",\n \"layoutUrl\": \"<string>\",\n \"layoutGallery\": [\n \"<string>\"\n ],\n \"downloadableAsset\": \"<string>\",\n \"brochurePDF\": \"<string>\",\n \"additionalInfo\": [\n {\n \"label\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"embedCode\": \"<string>\",\n \"customButtonUrl\": \"\",\n \"payableAmount\": 123,\n \"customButtonSnippet\": \"\",\n \"images\": [\n \"<string>\"\n ],\n \"clonedImages\": [\n \"<string>\"\n ],\n \"customFinishes\": {\n \"type\": {\n \"name\": \"<string>\",\n \"options\": {\n \"kitchen\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"bathroom\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"general\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n }\n }\n },\n \"default\": {}\n },\n \"finishes\": [\n \"<string>\"\n ],\n \"clonedFinishes\": [\n \"<string>\"\n ],\n \"parking\": 123,\n \"bathrooms\": 123,\n \"orientation\": \"<string>\",\n \"inclusions\": \"<string>\",\n \"deliveryDate\": \"<string>\",\n \"description\": \"<string>\",\n \"unitmodels\": [\n \"<string>\"\n ],\n \"lon\": -93.75940812944683,\n \"lat\": 43.75940812944682,\n \"perimeter\": \"<string>\",\n \"svgLotId\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.planpoint.io/api/units/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"_id\": \"<string>\",\n \"floor\": \"<string>\",\n \"name\": \"<string>\",\n \"bedrooms\": \"<string>\",\n \"squareFeet\": 123,\n \"isFeatured\": false,\n \"price\": 123,\n \"unitPriceTBD\": false,\n \"type\": \"<string>\",\n \"specificType\": \"<string>\",\n \"availability\": \"<string>\",\n \"path\": \"<string>\",\n \"lotPath\": \"<string>\",\n \"unitImageUrl\": \"<string>\",\n \"onHoldExpiresAt\": \"2023-11-07T05:31:56Z\",\n \"layoutUrl\": \"<string>\",\n \"layoutGallery\": [\n \"<string>\"\n ],\n \"downloadableAsset\": \"<string>\",\n \"brochurePDF\": \"<string>\",\n \"additionalInfo\": [\n {\n \"label\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"embedCode\": \"<string>\",\n \"customButtonUrl\": \"\",\n \"payableAmount\": 123,\n \"customButtonSnippet\": \"\",\n \"images\": [\n \"<string>\"\n ],\n \"clonedImages\": [\n \"<string>\"\n ],\n \"customFinishes\": {\n \"type\": {\n \"name\": \"<string>\",\n \"options\": {\n \"kitchen\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"bathroom\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"general\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n }\n }\n },\n \"default\": {}\n },\n \"finishes\": [\n \"<string>\"\n ],\n \"clonedFinishes\": [\n \"<string>\"\n ],\n \"parking\": 123,\n \"bathrooms\": 123,\n \"orientation\": \"<string>\",\n \"inclusions\": \"<string>\",\n \"deliveryDate\": \"<string>\",\n \"description\": \"<string>\",\n \"unitmodels\": [\n \"<string>\"\n ],\n \"lon\": -93.75940812944683,\n \"lat\": 43.75940812944682,\n \"perimeter\": \"<string>\",\n \"svgLotId\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"_id": "<string>",
"floor": "<string>",
"name": "<string>",
"bedrooms": "<string>",
"squareFeet": 123,
"isFeatured": false,
"price": 123,
"unitPriceTBD": false,
"type": "<string>",
"specificType": "<string>",
"availability": "<string>",
"path": "<string>",
"lotPath": "<string>",
"unitImageUrl": "<string>",
"onHoldExpiresAt": "2023-11-07T05:31:56Z",
"layoutUrl": "<string>",
"layoutGallery": [
"<string>"
],
"downloadableAsset": "<string>",
"brochurePDF": "<string>",
"additionalInfo": [
{
"label": "<string>",
"value": "<string>"
}
],
"embedCode": "<string>",
"customButtonUrl": "",
"payableAmount": 123,
"customButtonSnippet": "",
"images": [
"<string>"
],
"clonedImages": [
"<string>"
],
"customFinishes": {
"type": {
"name": "<string>",
"options": {
"kitchen": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"bathroom": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"general": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
}
}
},
"default": {}
},
"finishes": [
"<string>"
],
"clonedFinishes": [
"<string>"
],
"parking": 123,
"bathrooms": 123,
"orientation": "<string>",
"inclusions": "<string>",
"deliveryDate": "<string>",
"description": "<string>",
"unitmodels": [
"<string>"
],
"lon": -93.75940812944683,
"lat": 43.75940812944682,
"perimeter": "<string>",
"svgLotId": "<string>"
}Update Unit
Update an existing unit by Id
curl --request PATCH \
--url https://app.planpoint.io/api/units/{id} \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"_id": "<string>",
"floor": "<string>",
"name": "<string>",
"bedrooms": "<string>",
"squareFeet": 123,
"isFeatured": false,
"price": 123,
"unitPriceTBD": false,
"type": "<string>",
"specificType": "<string>",
"availability": "<string>",
"path": "<string>",
"lotPath": "<string>",
"unitImageUrl": "<string>",
"onHoldExpiresAt": "2023-11-07T05:31:56Z",
"layoutUrl": "<string>",
"layoutGallery": [
"<string>"
],
"downloadableAsset": "<string>",
"brochurePDF": "<string>",
"additionalInfo": [
{
"label": "<string>",
"value": "<string>"
}
],
"embedCode": "<string>",
"customButtonUrl": "",
"payableAmount": 123,
"customButtonSnippet": "",
"images": [
"<string>"
],
"clonedImages": [
"<string>"
],
"customFinishes": {
"type": {
"name": "<string>",
"options": {
"kitchen": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"bathroom": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"general": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
}
}
},
"default": {}
},
"finishes": [
"<string>"
],
"clonedFinishes": [
"<string>"
],
"parking": 123,
"bathrooms": 123,
"orientation": "<string>",
"inclusions": "<string>",
"deliveryDate": "<string>",
"description": "<string>",
"unitmodels": [
"<string>"
],
"lon": -93.75940812944683,
"lat": 43.75940812944682,
"perimeter": "<string>",
"svgLotId": "<string>"
}
'import requests
url = "https://app.planpoint.io/api/units/{id}"
payload = {
"_id": "<string>",
"floor": "<string>",
"name": "<string>",
"bedrooms": "<string>",
"squareFeet": 123,
"isFeatured": False,
"price": 123,
"unitPriceTBD": False,
"type": "<string>",
"specificType": "<string>",
"availability": "<string>",
"path": "<string>",
"lotPath": "<string>",
"unitImageUrl": "<string>",
"onHoldExpiresAt": "2023-11-07T05:31:56Z",
"layoutUrl": "<string>",
"layoutGallery": ["<string>"],
"downloadableAsset": "<string>",
"brochurePDF": "<string>",
"additionalInfo": [
{
"label": "<string>",
"value": "<string>"
}
],
"embedCode": "<string>",
"customButtonUrl": "",
"payableAmount": 123,
"customButtonSnippet": "",
"images": ["<string>"],
"clonedImages": ["<string>"],
"customFinishes": {
"type": {
"name": "<string>",
"options": {
"kitchen": { "tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
] },
"bathroom": { "tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
] },
"general": { "tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
] }
}
},
"default": {}
},
"finishes": ["<string>"],
"clonedFinishes": ["<string>"],
"parking": 123,
"bathrooms": 123,
"orientation": "<string>",
"inclusions": "<string>",
"deliveryDate": "<string>",
"description": "<string>",
"unitmodels": ["<string>"],
"lon": -93.75940812944683,
"lat": 43.75940812944682,
"perimeter": "<string>",
"svgLotId": "<string>"
}
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
_id: '<string>',
floor: '<string>',
name: '<string>',
bedrooms: '<string>',
squareFeet: 123,
isFeatured: false,
price: 123,
unitPriceTBD: false,
type: '<string>',
specificType: '<string>',
availability: '<string>',
path: '<string>',
lotPath: '<string>',
unitImageUrl: '<string>',
onHoldExpiresAt: '2023-11-07T05:31:56Z',
layoutUrl: '<string>',
layoutGallery: ['<string>'],
downloadableAsset: '<string>',
brochurePDF: '<string>',
additionalInfo: [{label: '<string>', value: '<string>'}],
embedCode: '<string>',
customButtonUrl: '',
payableAmount: 123,
customButtonSnippet: '',
images: ['<string>'],
clonedImages: ['<string>'],
customFinishes: {
type: {
name: '<string>',
options: {
kitchen: {tabs: [{label: '<string>', cover: '<string>', thumbnail: '<string>'}]},
bathroom: {tabs: [{label: '<string>', cover: '<string>', thumbnail: '<string>'}]},
general: {tabs: [{label: '<string>', cover: '<string>', thumbnail: '<string>'}]}
}
},
default: {}
},
finishes: ['<string>'],
clonedFinishes: ['<string>'],
parking: 123,
bathrooms: 123,
orientation: '<string>',
inclusions: '<string>',
deliveryDate: '<string>',
description: '<string>',
unitmodels: ['<string>'],
lon: -93.75940812944683,
lat: 43.75940812944682,
perimeter: '<string>',
svgLotId: '<string>'
})
};
fetch('https://app.planpoint.io/api/units/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.planpoint.io/api/units/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'_id' => '<string>',
'floor' => '<string>',
'name' => '<string>',
'bedrooms' => '<string>',
'squareFeet' => 123,
'isFeatured' => false,
'price' => 123,
'unitPriceTBD' => false,
'type' => '<string>',
'specificType' => '<string>',
'availability' => '<string>',
'path' => '<string>',
'lotPath' => '<string>',
'unitImageUrl' => '<string>',
'onHoldExpiresAt' => '2023-11-07T05:31:56Z',
'layoutUrl' => '<string>',
'layoutGallery' => [
'<string>'
],
'downloadableAsset' => '<string>',
'brochurePDF' => '<string>',
'additionalInfo' => [
[
'label' => '<string>',
'value' => '<string>'
]
],
'embedCode' => '<string>',
'customButtonUrl' => '',
'payableAmount' => 123,
'customButtonSnippet' => '',
'images' => [
'<string>'
],
'clonedImages' => [
'<string>'
],
'customFinishes' => [
'type' => [
'name' => '<string>',
'options' => [
'kitchen' => [
'tabs' => [
[
'label' => '<string>',
'cover' => '<string>',
'thumbnail' => '<string>'
]
]
],
'bathroom' => [
'tabs' => [
[
'label' => '<string>',
'cover' => '<string>',
'thumbnail' => '<string>'
]
]
],
'general' => [
'tabs' => [
[
'label' => '<string>',
'cover' => '<string>',
'thumbnail' => '<string>'
]
]
]
]
],
'default' => [
]
],
'finishes' => [
'<string>'
],
'clonedFinishes' => [
'<string>'
],
'parking' => 123,
'bathrooms' => 123,
'orientation' => '<string>',
'inclusions' => '<string>',
'deliveryDate' => '<string>',
'description' => '<string>',
'unitmodels' => [
'<string>'
],
'lon' => -93.75940812944683,
'lat' => 43.75940812944682,
'perimeter' => '<string>',
'svgLotId' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.planpoint.io/api/units/{id}"
payload := strings.NewReader("{\n \"_id\": \"<string>\",\n \"floor\": \"<string>\",\n \"name\": \"<string>\",\n \"bedrooms\": \"<string>\",\n \"squareFeet\": 123,\n \"isFeatured\": false,\n \"price\": 123,\n \"unitPriceTBD\": false,\n \"type\": \"<string>\",\n \"specificType\": \"<string>\",\n \"availability\": \"<string>\",\n \"path\": \"<string>\",\n \"lotPath\": \"<string>\",\n \"unitImageUrl\": \"<string>\",\n \"onHoldExpiresAt\": \"2023-11-07T05:31:56Z\",\n \"layoutUrl\": \"<string>\",\n \"layoutGallery\": [\n \"<string>\"\n ],\n \"downloadableAsset\": \"<string>\",\n \"brochurePDF\": \"<string>\",\n \"additionalInfo\": [\n {\n \"label\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"embedCode\": \"<string>\",\n \"customButtonUrl\": \"\",\n \"payableAmount\": 123,\n \"customButtonSnippet\": \"\",\n \"images\": [\n \"<string>\"\n ],\n \"clonedImages\": [\n \"<string>\"\n ],\n \"customFinishes\": {\n \"type\": {\n \"name\": \"<string>\",\n \"options\": {\n \"kitchen\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"bathroom\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"general\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n }\n }\n },\n \"default\": {}\n },\n \"finishes\": [\n \"<string>\"\n ],\n \"clonedFinishes\": [\n \"<string>\"\n ],\n \"parking\": 123,\n \"bathrooms\": 123,\n \"orientation\": \"<string>\",\n \"inclusions\": \"<string>\",\n \"deliveryDate\": \"<string>\",\n \"description\": \"<string>\",\n \"unitmodels\": [\n \"<string>\"\n ],\n \"lon\": -93.75940812944683,\n \"lat\": 43.75940812944682,\n \"perimeter\": \"<string>\",\n \"svgLotId\": \"<string>\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://app.planpoint.io/api/units/{id}")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"_id\": \"<string>\",\n \"floor\": \"<string>\",\n \"name\": \"<string>\",\n \"bedrooms\": \"<string>\",\n \"squareFeet\": 123,\n \"isFeatured\": false,\n \"price\": 123,\n \"unitPriceTBD\": false,\n \"type\": \"<string>\",\n \"specificType\": \"<string>\",\n \"availability\": \"<string>\",\n \"path\": \"<string>\",\n \"lotPath\": \"<string>\",\n \"unitImageUrl\": \"<string>\",\n \"onHoldExpiresAt\": \"2023-11-07T05:31:56Z\",\n \"layoutUrl\": \"<string>\",\n \"layoutGallery\": [\n \"<string>\"\n ],\n \"downloadableAsset\": \"<string>\",\n \"brochurePDF\": \"<string>\",\n \"additionalInfo\": [\n {\n \"label\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"embedCode\": \"<string>\",\n \"customButtonUrl\": \"\",\n \"payableAmount\": 123,\n \"customButtonSnippet\": \"\",\n \"images\": [\n \"<string>\"\n ],\n \"clonedImages\": [\n \"<string>\"\n ],\n \"customFinishes\": {\n \"type\": {\n \"name\": \"<string>\",\n \"options\": {\n \"kitchen\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"bathroom\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"general\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n }\n }\n },\n \"default\": {}\n },\n \"finishes\": [\n \"<string>\"\n ],\n \"clonedFinishes\": [\n \"<string>\"\n ],\n \"parking\": 123,\n \"bathrooms\": 123,\n \"orientation\": \"<string>\",\n \"inclusions\": \"<string>\",\n \"deliveryDate\": \"<string>\",\n \"description\": \"<string>\",\n \"unitmodels\": [\n \"<string>\"\n ],\n \"lon\": -93.75940812944683,\n \"lat\": 43.75940812944682,\n \"perimeter\": \"<string>\",\n \"svgLotId\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.planpoint.io/api/units/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"_id\": \"<string>\",\n \"floor\": \"<string>\",\n \"name\": \"<string>\",\n \"bedrooms\": \"<string>\",\n \"squareFeet\": 123,\n \"isFeatured\": false,\n \"price\": 123,\n \"unitPriceTBD\": false,\n \"type\": \"<string>\",\n \"specificType\": \"<string>\",\n \"availability\": \"<string>\",\n \"path\": \"<string>\",\n \"lotPath\": \"<string>\",\n \"unitImageUrl\": \"<string>\",\n \"onHoldExpiresAt\": \"2023-11-07T05:31:56Z\",\n \"layoutUrl\": \"<string>\",\n \"layoutGallery\": [\n \"<string>\"\n ],\n \"downloadableAsset\": \"<string>\",\n \"brochurePDF\": \"<string>\",\n \"additionalInfo\": [\n {\n \"label\": \"<string>\",\n \"value\": \"<string>\"\n }\n ],\n \"embedCode\": \"<string>\",\n \"customButtonUrl\": \"\",\n \"payableAmount\": 123,\n \"customButtonSnippet\": \"\",\n \"images\": [\n \"<string>\"\n ],\n \"clonedImages\": [\n \"<string>\"\n ],\n \"customFinishes\": {\n \"type\": {\n \"name\": \"<string>\",\n \"options\": {\n \"kitchen\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"bathroom\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n },\n \"general\": {\n \"tabs\": [\n {\n \"label\": \"<string>\",\n \"cover\": \"<string>\",\n \"thumbnail\": \"<string>\"\n }\n ]\n }\n }\n },\n \"default\": {}\n },\n \"finishes\": [\n \"<string>\"\n ],\n \"clonedFinishes\": [\n \"<string>\"\n ],\n \"parking\": 123,\n \"bathrooms\": 123,\n \"orientation\": \"<string>\",\n \"inclusions\": \"<string>\",\n \"deliveryDate\": \"<string>\",\n \"description\": \"<string>\",\n \"unitmodels\": [\n \"<string>\"\n ],\n \"lon\": -93.75940812944683,\n \"lat\": 43.75940812944682,\n \"perimeter\": \"<string>\",\n \"svgLotId\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"_id": "<string>",
"floor": "<string>",
"name": "<string>",
"bedrooms": "<string>",
"squareFeet": 123,
"isFeatured": false,
"price": 123,
"unitPriceTBD": false,
"type": "<string>",
"specificType": "<string>",
"availability": "<string>",
"path": "<string>",
"lotPath": "<string>",
"unitImageUrl": "<string>",
"onHoldExpiresAt": "2023-11-07T05:31:56Z",
"layoutUrl": "<string>",
"layoutGallery": [
"<string>"
],
"downloadableAsset": "<string>",
"brochurePDF": "<string>",
"additionalInfo": [
{
"label": "<string>",
"value": "<string>"
}
],
"embedCode": "<string>",
"customButtonUrl": "",
"payableAmount": 123,
"customButtonSnippet": "",
"images": [
"<string>"
],
"clonedImages": [
"<string>"
],
"customFinishes": {
"type": {
"name": "<string>",
"options": {
"kitchen": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"bathroom": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
},
"general": {
"tabs": [
{
"label": "<string>",
"cover": "<string>",
"thumbnail": "<string>"
}
]
}
}
},
"default": {}
},
"finishes": [
"<string>"
],
"clonedFinishes": [
"<string>"
],
"parking": 123,
"bathrooms": 123,
"orientation": "<string>",
"inclusions": "<string>",
"deliveryDate": "<string>",
"description": "<string>",
"unitmodels": [
"<string>"
],
"lon": -93.75940812944683,
"lat": 43.75940812944682,
"perimeter": "<string>",
"svgLotId": "<string>"
}Authorizations
Path Parameters
Unit ID
"objectId"
Body
Update an existing unit
Unique identifier for the unit
Reference to the associated floor
Name of the unit
Number of bedrooms in the unit
Square footage of the unit
Indicates if the unit is featured
Price of the unit
Indicates if the unit price is to be determined
Type of the unit
Specific type, e.g., 'Amenities', 'Parkings'. Defaults to 'unit' if not specified
Availability status of the unit
Path for unit details
Path for the lot associated with the unit
URL of the unit's image
Expiration date for the unit's hold status
URL of the unit layout
Gallery of layout images
URL of a downloadable asset
URL of the brochure in PDF format
List of additional information
Show child attributes
Show child attributes
Embed code for the unit
Custom URL for the unit's button
Payable amount for the unit
Custom snippet for the unit's button
List of image URLs
List of cloned image URLs
Show child attributes
Show child attributes
List of finishes
List of cloned finishes
Number of parking spaces
Number of bathrooms
Orientation of the unit
Inclusions for the unit
Expected delivery date
Description of the unit
References to associated unit models
Longitude of the unit location.
-93.75940812944683
Latitude of the unit location.
43.75940812944682
Perimeter of the unit
SVG ID for the lot
Response
Successful operation
Unique identifier for the unit
Reference to the associated floor
Name of the unit
Number of bedrooms in the unit
Square footage of the unit
Indicates if the unit is featured
Price of the unit
Indicates if the unit price is to be determined
Type of the unit
Specific type, e.g., 'Amenities', 'Parkings'. Defaults to 'unit' if not specified
Availability status of the unit
Path for unit details
Path for the lot associated with the unit
URL of the unit's image
Expiration date for the unit's hold status
URL of the unit layout
Gallery of layout images
URL of a downloadable asset
URL of the brochure in PDF format
List of additional information
Show child attributes
Show child attributes
Embed code for the unit
Custom URL for the unit's button
Payable amount for the unit
Custom snippet for the unit's button
List of image URLs
List of cloned image URLs
Show child attributes
Show child attributes
List of finishes
List of cloned finishes
Number of parking spaces
Number of bathrooms
Orientation of the unit
Inclusions for the unit
Expected delivery date
Description of the unit
References to associated unit models
Longitude of the unit location.
-93.75940812944683
Latitude of the unit location.
43.75940812944682
Perimeter of the unit
SVG ID for the lot