The rental's own price lists, rate periods, rates and price rules. Any key with the price right reads them. Only the organization's key, made with the Prices right, writes them. Every write takes preview=true, which answers the change and writes nothing. Every write goes into the rental's price history with the key's name.
The rental's price lists
The organization's key reads every list. A channel's key reads only the list its channel sells at.
path Parameters
slugThe rental's price lists › Responses
OK
The rental's rate periods
Rate periods belong to the rental, not to a price list. Every list prices the same periods.
path Parameters
slugThe rental's rate periods › Responses
OK
Add a rate period
A recurring rate period takes its days from the rate periods that hold them, and keeps their rates. It may trim them, never take one whole. A one-off (with year) wins for its days in that year.
path Parameters
slugquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
Add a rate period › Request Body
namefrom^\d{2}-\d{2}$ · requiredMonth and day, MM-DD.
to^\d{2}-\d{2}$ · requiredMonth and day, MM-DD.
yearminPaidDaysAdd a rate period › Responses
OK
previewidThe rate period added, changed or removed.
splitNameThe rate period cut in two, when a new one landed in its middle.
Every rate period after.
Rate periods that go, each with the count of rates that go too.
Price rules that named only rate periods that go. They go too.
Every rate a price list charges
One cell for each car type and rate period the list prices, with its steps. A cell of a derived list is own or taken from the parent. A channel's key reads only the list its channel sells at: another list answers 404.
path Parameters
slugidEvery rate a price list charges › Responses
OK
priceListIdWrite rates on a price list
Up to 500 cells in one write, all or none. Only the steps sent change, as on the Rates page: a step not sent keeps its price, and null takes a step out. A cell left out stays as it is.
path Parameters
slugidquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
Write rates on a price list › Responses
OK
previewpriceListIdRemove a rate period
Its rates go with it, and so does a price rule that named only it. A recurring rate period gives its days to a neighbour: name it in giveTo. Ask with preview=true first to see what goes.
path Parameters
slugidquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
giveToThe rate period before or after it, which takes its days.
The rate period before or after it, which takes its days.
Remove a rate period › Responses
OK
previewidThe rate period added, changed or removed.
splitNameThe rate period cut in two, when a new one landed in its middle.
Every rate period after.
Rate periods that go, each with the count of rates that go too.
Price rules that named only rate periods that go. They go too.
Change a rate period
New dates on a recurring rate period reshape the year. The days it gives up go to the neighbour on that side, and the days it takes come from whoever holds them. It keeps its rates.
path Parameters
slugidquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
Change a rate period › Request Body
namefrom^\d{2}-\d{2}$Month and day, MM-DD.
to^\d{2}-\d{2}$Month and day, MM-DD.
minPaidDaysChange a rate period › Responses
OK
previewidThe rate period added, changed or removed.
splitNameThe rate period cut in two, when a new one landed in its middle.
Every rate period after.
Rate periods that go, each with the count of rates that go too.
Price rules that named only rate periods that go. They go too.
The rental's price rules, first applied first
The organization's key reads every rule. A channel's key reads the rules that move its prices: a rule that names its channel, or a rule that names no channel, unless that rule names only other price lists. It never reads a rule that names only other channels.
path Parameters
slugThe rental's price rules, first applied first › Responses
OK
Add a price rule
For example +10% on two car types for two weeks: percentBp 1000, carTypeIds, dateFrom and dateTo. A new rule goes last, so it compounds on the rules before it, unless position says otherwise. Send an Idempotency-Key header: a retry with the same key and body answers the same rule and adds no second one. The same key with another body answers 409 idempotency_mismatch, and a copy while the first is still being made answers 409 in_progress. A preview takes no key.
path Parameters
slugquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
Headers
idempotency-keyAdd a price rule › Request Body
nameNull: a stored condition that does not read. The rule moves no price.
percentBpamountMinoramountPerappliesTocarTypeIdsratePeriodIdsdateFromdateTopriceListIdsexclusiveGroupactiveposition0 applies first. Left out: last.
Add a price rule › Responses
OK
Remove a price rule
Bookings already priced keep their lines. New quotes stop seeing the rule.
path Parameters
slugidquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
Remove a price rule › Responses
OK
Change a price rule
Only the fields given change. A condition given replaces the parts this API names, and keeps parts an import wrote. Setting percentBp clears amountMinor, and the other way round.
path Parameters
slugidquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
Change a price rule › Request Body
nameNull: a stored condition that does not read. The rule moves no price.
percentBpamountMinoramountPerappliesTocarTypeIdsratePeriodIdsdateFromdateTopriceListIdsexclusiveGroupactiveChange a price rule › Responses
OK
Put the price rules in a new order
Every rule of the rental, each once, first applied first. Rules compound in this order.
path Parameters
slugquery Parameters
previewtrue runs every check and answers what the write would change, and writes nothing.
true runs every check and answers what the write would change, and writes nothing.
Put the price rules in a new order › Responses
OK
previewids