From c23a1bcf948ddfe146422f889aff3caf30255240 Mon Sep 17 00:00:00 2001 From: Hannah Date: Wed, 19 Aug 2026 13:55:54 +0100 Subject: [PATCH 1/3] update schema --- swagger/api-display.yml | 11 +++++++++-- swagger/api.yml | 11 +++++++++-- 2 files changed, 18 insertions(+), 4 deletions(-) diff --git a/swagger/api-display.yml b/swagger/api-display.yml index 80f7626..4f9c45f 100644 --- a/swagger/api-display.yml +++ b/swagger/api-display.yml @@ -609,9 +609,16 @@ definitions: daily rent each tenant will pay for the first payment period for a rolling tenancy. This is required if is_fixed_term is false. - The first payment period covers the rent from the start date to - the day before the first rolling monthly payment day. The first payment rent + The first payment period covers the rent from the start date to + the day before the first rolling monthly payment day. The first payment rent is calculated based on the number of days in the period multiplied by the per day rate. + price_per_person_per_week_4dp: + type: number + nullable: true + description: | + The weekly rent per person expressed to 4 decimal places of precision. + This mirrors price_per_person_per_week but with greater precision + to avoid rounding errors in downstream payment calculations. PriceOutbound: description: | When fetching property details this describes a Price attached diff --git a/swagger/api.yml b/swagger/api.yml index 1075cba..338905f 100644 --- a/swagger/api.yml +++ b/swagger/api.yml @@ -1393,9 +1393,16 @@ definitions: daily rent each tenant will pay for the first payment period for a rolling tenancy. This is required if is_fixed_term is false. - The first payment period covers the rent from the start date to - the day before the first rolling monthly payment day. The first payment rent + The first payment period covers the rent from the start date to + the day before the first rolling monthly payment day. The first payment rent is calculated based on the number of days in the period multiplied by the per day rate. + price_per_person_per_week_4dp: + type: number + nullable: true + description: | + The weekly rent per person expressed to 4 decimal places of precision. + This mirrors price_per_person_per_week but with greater precision + to avoid rounding errors in downstream payment calculations. PriceOutbound: description: | When fetching property details this describes a Price attached From d16dcd3de571154025754acfbab156cc66cffb68 Mon Sep 17 00:00:00 2001 From: Hannah Date: Wed, 19 Aug 2026 13:58:24 +0100 Subject: [PATCH 2/3] update to model --- src/Models/Price.php | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/src/Models/Price.php b/src/Models/Price.php index 8057135..b9904e2 100644 --- a/src/Models/Price.php +++ b/src/Models/Price.php @@ -68,6 +68,15 @@ class Price extends SwaggerModel */ protected $rolling_price_initial_period_per_person_per_day = 0.0; + /** + * The weekly rent per person expressed to 4 decimal places of precision. + * This mirrors price_per_person_per_week but with greater precision + * to avoid rounding errors in downstream payment calculations. + * + * @var ?float + */ + protected $price_per_person_per_week_4dp = 0.0; + /** * @return ?float @@ -177,4 +186,26 @@ public function setRollingPriceInitialPeriodPerPersonPerDay($rolling_price_initi return $this; } + + + /** + * @return ?float + */ + public function getPricePerPersonPerWeek4dp() + { + return $this->price_per_person_per_week_4dp; + } + + + /** + * @param ?float $price_per_person_per_week_4dp + * + * @return $this + */ + public function setPricePerPersonPerWeek4dp($price_per_person_per_week_4dp) + { + $this->price_per_person_per_week_4dp = $price_per_person_per_week_4dp; + + return $this; + } } From 754ba9c0713db5aca1bd5a937acb4b3b38f27544 Mon Sep 17 00:00:00 2001 From: Hannah Date: Sat, 29 Aug 2026 21:16:17 +0100 Subject: [PATCH 3/3] update channel.yml --- swagger/api-channel.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/swagger/api-channel.yml b/swagger/api-channel.yml index ce1c898..f45ddeb 100644 --- a/swagger/api-channel.yml +++ b/swagger/api-channel.yml @@ -719,6 +719,13 @@ definitions: The first payment period covers the rent from the start date to the day before the first rolling monthly payment day. The first payment rent is calculated based on the number of days in the period multiplied by the per day rate. + price_per_person_per_week_4dp: + type: number + nullable: true + description: | + The weekly rent per person expressed to 4 decimal places of precision. + This mirrors price_per_person_per_week but with greater precision + to avoid rounding errors in downstream payment calculations. PriceOutbound: description: | When fetching property details this describes a Price attached