Update Rate Sets
Update existing Rate Sets of units in the inventory available to the API User
Overview
This endpoint allows the Agent to make updates to existing Rate Sets associated with specific units. It enables adjustments to rates, intervals (weekly, daily, or monthly), Minimum or Maximum Length of Stay, and more as needed.
It is recommended to first use the Retrieve Rate Set function, then use the details from the Retrieve Rate Set Response to populate details for the Update Rate Set Request.
Endpoints Available
| Method | Endpoint | Description |
|---|---|---|
| PUT | v2024.07.31/ratesets/{rateset_id} | Modify existing rate sets. |
Path Parameters
| Path Parameter | Required / Optional | Description |
|---|---|---|
{rateset_id} | Required | The unique identifier for the rate set. |
Body Parameters
| Parameter | Required / Optional | Description | Data Type |
|---|---|---|---|
"rate_set_id" | Required | The unique identifier for the rate set. | int |
"management_company_user_id" | Required | The unique identifier for the supplier associated with the rate set. | int |
"set_name" | Required | The unique rate set name as configured by the supplier. | string |
"weekly_daily_monthly" | Required | Is the rate set Weekly, Daily, or Monthly? | int |
"includes_tax" | Required | Does the rate include taxes? | boolean |
"days_in_month" | Required | How many days in a month when using a Monthly Rate Set? | int |
"based_on_arrival_date_band_only" | Required | Quote rates based on arrival date band only (else pro-rate based on split of bands). | boolean |
"currency" | Required | The currency for the rate set. | string |
"minimum_nightly_rate" | Required | The minimum nightly rate for the rate set. | int |
"imported" | Required | Date-time of when the rate set was imported. | date-time |
"last_modified_by_staff_user_id" | Required | The unique identifier of the staff user who last modified the rate set. | int |
"last_modified_by_user_id" | Required | The unique identifier of the user who last modified the rate set. | int |
"ip_address" | Required | IP address of the user or system that last modified the rate set. | string |
"imported_from_calendar_sync_master" | Required | A flag indicating if the rate set was imported from the calendar sync master (true) or not (false). | boolean |
"is_flat_rate_model" | Required | A flag indicating if the rate set follows a flat rate model (true) or not (false). | boolean |
"rate_bands" | Required | An array of objects representing the rate set rate bands. | arroy[objects] |
weekly_daily_monthlyThis parameter determines the interval type to be used within the Rate Set. The values to be used are:
0: Weekly
1: Daily
2: Monthly
"rate_Bands" Object Body Parameters
"rate_Bands" Object Body Parameters| Parameter | Required / Optional | Description | Data Type |
|---|---|---|---|
"rate_band_id" | Required | The unique identifier for the rate set rate band. | int |
"property_id" | Required | The unique identifier for the unit in the inventory associated with the rate band. | int |
"date_from" | Required | The start date for the rate band. | date-time |
"date_to" | Required | The end date for the rate band. | date-time |
"us_rate" | Required | number | |
"rate_set_id" | Required | The unique identifier for the rate set. | int |
"minimum_nights_stay" | Required | The minimum nights a guest can stay during this period. | int |
"arrival_days" | Required | The arrival day restrictions - This value uses bitwise representation (See below). | int |
"floor_rate" | Required | The wholesale or discounted rate configured by the supplier. | number |
"minimum_nightly_rate" | Required | The minimum nightly rate for the rate set. | int |
"daily_rate" | Required | The price charged to guests for each day of their stay at the rental property. | int |
"monthly_rate" | Required | The price charged to guests for a month-long stay at the rental property, if applicable. | int |
"departure_days" | Required | The departure day Restrictions - This value uses bitwise representation (See below). | int |
"season_name" | Required | The name given to the unique rate band in the rate set. (e.g. High Season, Low Season). | string |
"imported" | Required | The timestamp representing when the rate set was imported. | date-time |
"maximum_nights_stay" | Required | The maximum nights a guest can stay during this period. | int |
"last_modified_by_staff_user_id" | Required | The unique identifier of the staff user who last modified the rate set. | int |
"last_modified_by_user_id" | Required | The unique identifier of the user who last modified the rate set. | int |
"last_modified_by_ip_address" | Required | The IP address of the user or system that last modified the rate set. | string |
"ip_address" | Required | The IP address of the user or system that last modified the rate set. | string |
Arrival/Departure Day Restrictions - Bitwise RepresentationArrival and departure day restrictions refer to specific rules or limitations set by property owners or managers regarding the days on which guests are allowed to arrive or depart from the property. To efficiently represent and enforce these restrictions, a bitwise representation is utilized, where each day of the week is assigned a corresponding bit value.
Bitwise representation allows for the encoding of multiple restrictions into a single integer value.
In this specific representation, Monday serves as the starting point, and each day of the week is assigned a unique bit position as follows:
Day Bit Position Byte Monday 0 1 Tuesday 1 2 Wednesday 2 4 Thursday 3 8 Friday 4 16 Saturday 5 32 Sunday 6 64 To determine the arrival/departure day restrictions for a property, the relevant bit positions are set to 1 to indicate the allowed days and 0 to indicate the restricted days.
Examples:
- If a property allows arrival and departure on Monday, Wednesday, and Sunday, the bitwise representation would be 1 + 4 + 64 = 69
- If a property allows arrival and departures on Tuesday, Wednesday, and Sunday, the bitwise representation would be 2 + 4 + 64 = 70
- For a property that restricts arrivals and departures on Monday, Friday, and Saturday, the bitwise representation would be 2 + 4 + 8 + 64 = 78
- If a property allows check-ins and check-outs on all days, the bitwise representation would be
1 + 2 + 4 + 8 + 16 + 32 + 64 = 127
Response Definitions
| Parameter | Description | Data Type |
|---|---|---|
"rate_set_id" | The unique identifier for the rate set. | int |
"management_company_user_id" | The unique identifier for the supplier associated with the rate set. | int |
"set_name" | The unique rate set name as configured by the supplier. | string |
"weekly_daily_monthly" | Is the rate set Weekly, Daily, or Monthly? | int |
"includes_tax" | Does the rate include taxes? | boolean |
"days_in_month" | How many days in a month when using a Monthly Rate Set? | int |
"based_on_arrival_date_band_only" | Quote rates based on arrival date band only (else pro-rate based on split of bands). | boolean |
"currency" | The currency for the rate set. | string |
"minimum_nightly_rate" | The minimum nightly rate for the rate set. | int |
"imported" | Date-time of when the rate set was imported. | date-time |
"last_modified_by_staff_user_id" | The unique identifier of the staff user who last modified the rate set. | int |
"last_modified_by_user_id" | The unique identifier of the user who last modified the rate set. | int |
"ip_address" | IP address of the user or system that last modified the rate set. | string |
"imported_from_calendar_sync_master" | A flag indicating if the rate set was imported from the calendar sync master (true) or not (false). | boolean |
"is_flat_rate_model" | A flag indicating if the rate set follows a flat rate model (true) or not (false). | boolean |
"rate_bands" | An array of objects representing the rate set rate bands. | arroy[objects] |
weekly_daily_monthlyThis parameter determines the interval type to be used within the Rate Set. The values to be used are:
0: Weekly
1: Daily
2: Monthly
"rate_Bands" Object
"rate_Bands" Object| Parameter | Description | Data Type |
|---|---|---|
"rate_band_id" | The unique identifier for the rate set rate band. | int |
"property_id" | The unique identifier for the unit in the inventory associated with the rate band. | int |
"date_from" | The start date for the rate band. | date-time |
"date_to" | The end date for the rate band. | date-time |
"us_rate" | number | |
"rate_set_id" | The unique identifier for the rate set. | int |
"minimum_nights_stay" | The minimum nights a guest can stay during this period. | int |
"arrival_days" | The arrival day restrictions - This value uses bitwise representation (See below). | int |
"floor_rate" | The wholesale or discounted rate configured by the supplier. | number |
"minimum_nightly_rate" | The minimum nightly rate for the rate set. | int |
"daily_rate" | The price charged to guests for each day of their stay at the rental property. | int |
"monthly_rate" | The price charged to guests for a month-long stay at the rental property, if applicable. | int |
"departure_days" | The departure day Restrictions - This value uses bitwise representation (See below). | int |
"season_name" | The name given to the unique rate band in the rate set. (e.g. High Season, Low Season). | string |
"imported" | The timestamp representing when the rate set was imported. | date-time |
"maximum_nights_stay" | The maximum nights a guest can stay during this period. | int |
"last_modified_by_staff_user_id" | The unique identifier of the staff user who last modified the rate set. | int |
"last_modified_by_user_id" | The unique identifier of the user who last modified the rate set. | int |
"last_modified_by_ip_address" | The IP address of the user or system that last modified the rate set. | string |
"ip_address" | The IP address of the user or system that last modified the rate set. | string |
Sample Request
curl --location --request PUT 'https://api.ciiruspartners.com/v2024.07.31/rates/ratesets/72024' \
--header 'Authorization: Basic {APIUsername:APIPassword}' \
--data '{
"rate_set_id": 72024,
"mc_user_id": 42330,
"set_name": "Test Property 1",
"weekly_daily_monthly": 1,
"includes_tax": false,
"days_in_month": 30,
"based_on_arrival_date_band_only": false,
"currency": "USD",
"minimum_nightly_rate": 0,
"imported": "2023-09-15T00:00:00",
"rate_bands": [
{
"rate_band_id": 1395092385,
"property_id": 219264,
"date_from": "2023-09-15T00:00:00",
"date_to": "2023-11-21T00:00:00",
"us_rate": 0,
"rate_set_id": 72024,
"minimum_nights_stay": 3,
"arrival_days": 127,
"floor_rate": 1,
"minimum_nightly_rate": 0,
"daily_rate": 1.5,
"monthly_rate": 0,
"departure_days": 127,
"season_name": "Test1",
"imported": "2023-09-15T00:00:00",
"maximum_nights_stay": 0,
"last_modified_by_staff_user_id": 0,
"last_modified_by_user_id": 77520,
"last_modified_by_ip_address": "9.8.8.7",
"ip_address": "9.8.8.7"
},
...
],
"last_modified_by_staff_user_id": 0,
"last_modified_by_user_id": 77520,
"ip_address": "9.8.8.7",
"imported_from_calendar_sync_master": false,
"is_flat_rate_model": false
}'Sample Response
{
"id": 72024,
"set_name": "Test Property 1",
"weekly_daily_monthly": 1,
"use_default_floor_rate": false,
"includes_tax": false,
"days_in_month": 30,
"based_on_arrival_date_band_only": false,
"currency": "USD",
"minimum_nightly_rate": 0,
"rate_bands": [
{
"id": 1585490830,
"unit_id": 0,
"date_from": "2023-09-15T00:00:00",
"date_to": "2023-11-21T00:00:00",
"us_rate": 0,
"rate_set_id": 72024,
"missing_band": 0,
"minimum_nights_stay": 3,
"arrival_days": 127,
"floor_rate": 1,
"daily_rate": 1.5,
"monthly_rate": 0,
"departure_days": 127,
"season_name": "Test1",
"imported": "2023-09-15T00:00:00",
"maximum_nights_stay": 0
},
...
],
"mc_user_id": 42330
}Updated 3 months ago
