Deactivate and Activate a Property
How to deactivate and activate a property in Guesty.
Deactivating a Property
Before deactivating a property, it is important to ensure the following:
- Current and future stays are accounted for, so there is no disruption in the guest experience. Related automation will cease to function once the property is deactivated.
 - The property has been disconnected from all its channel integrations.
 
Available Endpoints
| Method | Endpoint | 
|---|---|
| PUT | /listings/{id} | 
Key Parameters
Path Parameters
| Path Parameter | Type | Description | Required | 
|---|---|---|---|
id | 
      string | The property's Guesty ID. E.g., 66054019764cbb000f37c450 | 
      yes | 
Query Parameters
| Query Parameter | Type | Description | Required | 
|---|---|---|---|
updateSubUnits | 
      boolean | Set to true for the request to affect the sub-unitsof a multi-unit.E.g., updateSubUnits=true | 
      
To deactivate a property, send the following request in its entirety. Neglecting any of the body parameters may prevent the intended outcome.
curl --globoff --request PUT 'https://open-api.guesty.com/v1/listings/{{_id}}?updateSubUnits=true' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer <accessToken>' \
--data '{
    "active": false,
    "pms": {
        "active": false,
        "automation": {
            "hooks": {
                "active": false
            },
            "answeringMachine": {
                "active": false
            },
            "calendarSmartRules": {
                "active": false
            },
            "autoReviews": {
                "active": false
            },
            "autoList": {
                "active": false
            },
            "autoPricing": {
                "active": false
            },
            "homeAutomation": {
                "buzzer": {
                    "active": false
                }
            }
        },
        "cleaningStatus": {
            "active": false
        }
    },
    "receptionistsService": {
        "active": false
    },
    "postBookingService": {
      "monitorReservations": false,
      "manualWork": false,
      "findServiceProvider": false,
      "handleEmergencies": false,
      "reservationTask": false
   } 
}'const myHeaders = new Headers();
myHeaders.append("Content-Type", "application/json");
myHeaders.append("Authorization", "Bearer {accessToken}");
const raw = JSON.stringify({
  "active": false,
  "pms": {
    "active": false,
    "automation": {
      "hooks": {
        "active": false
      },
      "answeringMachine": {
        "active": false
      },
      "calendarSmartRules": {
        "active": false
      },
      "autoReviews": {
        "active": false
      },
      "autoList": {
        "active": false
      },
      "autoPricing": {
        "active": false
      },
      "homeAutomation": {
        "buzzer": {
          "active": false
        }
      }
    },
    "cleaningStatus": {
      "active": false
    }
  },
  "receptionistsService": {
    "active": false
  },
  "postBookingService": {
    "monitorReservations": false,
    "manualWork": false,
    "findServiceProvider": false,
    "handleEmergencies": false,
    "reservationTask": false
  }
});
const requestOptions = {
  method: "PUT",
  headers: myHeaders,
  body: raw,
  redirect: "manual"
};
fetch("https://open-api.guesty.com/v1/listings/{_id}?updateSubUnits=true", requestOptions)
  .then((response) => response.text())
  .then((result) => console.log(result))
  .catch((error) => console.error(error));var https = require('follow-redirects').https;
var fs = require('fs');
var options = {
  'method': 'PUT',
  'hostname': 'open-api.guesty.com',
  'path': '/v1/listings/{_id}?updateSubUnits=true',
  'headers': {
    'Content-Type': 'application/json',
    'Authorization': 'Bearer {accessToken}'
  },
  'maxRedirects': 20
};
var req = https.request(options, function (res) {
  var chunks = [];
  res.on("data", function (chunk) {
    chunks.push(chunk);
  });
  res.on("end", function (chunk) {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
  res.on("error", function (error) {
    console.error(error);
  });
});
var postData = JSON.stringify({
  "active": false,
  "pms": {
    "active": false,
    "automation": {
      "hooks": {
        "active": false
      },
      "answeringMachine": {
        "active": false
      },
      "calendarSmartRules": {
        "active": false
      },
      "autoReviews": {
        "active": false
      },
      "autoList": {
        "active": false
      },
      "autoPricing": {
        "active": false
      },
      "homeAutomation": {
        "buzzer": {
          "active": false
        }
      }
    },
    "cleaningStatus": {
      "active": false
    }
  },
  "receptionistsService": {
    "active": false
  },
  "postBookingService": {
    "monitorReservations": false,
    "manualWork": false,
    "findServiceProvider": false,
    "handleEmergencies": false,
    "reservationTask": false
  }
});
req.write(postData);
req.end();<?php
$curl = curl_init();
curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://open-api.guesty.com/v1/listings/{_id}?updateSubUnits=true',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => false,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'PUT',
  CURLOPT_POSTFIELDS =>'{
    "active": false,
    "pms": {
        "active": false,
        "automation": {
            "hooks": {
                "active": false
            },
            "answeringMachine": {
                "active": false
            },
            "calendarSmartRules": {
                "active": false
            },
            "autoReviews": {
                "active": false
            },
            "autoList": {
                "active": false
            },
            "autoPricing": {
                "active": false
            },
            "homeAutomation": {
                "buzzer": {
                    "active": false
                }
            }
        },
        "cleaningStatus": {
            "active": false
        }
    },
    "receptionistsService": {
        "active": false
    },
    "postBookingService": {
      "monitorReservations": false,
      "manualWork": false,
      "findServiceProvider": false,
      "handleEmergencies": false,
      "reservationTask": false
   } 
}',
  CURLOPT_HTTPHEADER => array(
    'Content-Type: application/json',
    'Authorization: Bearer {accessToken}'
  ),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
import http.client
import json
conn = http.client.HTTPSConnection("open-api.guesty.com")
payload = json.dumps({
  "active": False,
  "pms": {
    "active": False,
    "automation": {
      "hooks": {
        "active": False
      },
      "answeringMachine": {
        "active": False
      },
      "calendarSmartRules": {
        "active": False
      },
      "autoReviews": {
        "active": False
      },
      "autoList": {
        "active": False
      },
      "autoPricing": {
        "active": False
      },
      "homeAutomation": {
        "buzzer": {
          "active": False
        }
      }
    },
    "cleaningStatus": {
      "active": False
    }
  },
  "receptionistsService": {
    "active": False
  },
  "postBookingService": {
    "monitorReservations": False,
    "manualWork": False,
    "findServiceProvider": False,
    "handleEmergencies": False,
    "reservationTask": False
  }
})
headers = {
  'Content-Type': 'application/json',
  'Authorization': 'Bearer {accessToken}'
}
conn.request("PUT", "/v1/listings/{_id}?updateSubUnits=true", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))Activating a Property
BillingOnce a property is activated it becomes billable in accordance with your service agreement with Guesty. For any billing-related issues contact your account manager or our Customer Experience team.
To activate a property, send the following request.
curl --globoff --request PUT 'https://open-api.guesty.com/v1/listings/{_id}?updateSubUnits=true' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer {token}' \
--data '{
    "active": true,
    "pms": {
        "active": true
    }
}'const myHeaders = new Headers();
myHeaders.append("Content-Type", "application/json");
myHeaders.append("Authorization", "Bearer {token}");
const raw = JSON.stringify({
  "active": true,
  "pms": {
    "active": true
  }
});
const requestOptions = {
  method: "PUT",
  headers: myHeaders,
  body: raw,
  redirect: "manual"
};
fetch("https://open-api.guesty.com/v1/listings/{_id}?updateSubUnits=true", requestOptions)
  .then((response) => response.text())
  .then((result) => console.log(result))
  .catch((error) => console.error(error));var https = require('follow-redirects').https;
var fs = require('fs');
var options = {
  'method': 'PUT',
  'hostname': 'open-api.guesty.com',
  'path': '/v1/listings/{_id}?updateSubUnits=true',
  'headers': {
    'Content-Type': 'application/json',
    'Authorization': 'Bearer {token}'
  },
  'maxRedirects': 20
};
var req = https.request(options, function (res) {
  var chunks = [];
  res.on("data", function (chunk) {
    chunks.push(chunk);
  });
  res.on("end", function (chunk) {
    var body = Buffer.concat(chunks);
    console.log(body.toString());
  });
  res.on("error", function (error) {
    console.error(error);
  });
});
var postData = JSON.stringify({
  "active": true,
  "pms": {
    "active": true
  }
});
req.write(postData);
req.end();<?php
$curl = curl_init();
curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://open-api.guesty.com/v1/listings/{_id}?updateSubUnits=true',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => false,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'PUT',
  CURLOPT_POSTFIELDS =>'{
    "active": true,
    "pms": {
        "active": true
    }
}',
  CURLOPT_HTTPHEADER => array(
    'Content-Type: application/json',
    'Authorization: Bearer {token}'
  ),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
import http.client
import json
conn = http.client.HTTPSConnection("open-api.guesty.com")
payload = json.dumps({
  "active": True,
  "pms": {
    "active": True
  }
})
headers = {
  'Content-Type': 'application/json',
  'Authorization': 'Bearer {token}'
}
conn.request("PUT", "/v1/listings/{_id}?updateSubUnits=true", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))Updated about 2 months ago
What’s Next