Commit 1f4829bb3fe for woocommerce
commit 1f4829bb3fe3a7b21d9333500231578a115b3b9b
Author: louwie17 <lourensschep@gmail.com>
Date: Wed Jun 17 10:10:46 2026 +0200
Fix total_refunds JSON example in v3 sales report docs (#65758)
The sales report example showed `total_refunds` as a quoted string
("10.00"), but the top-level `total_refunds` is a raw PHP float never
passed through wc_format_decimal, so the API returns it as a JSON number.
Restore it to an unquoted number to match the actual response and the
schema, which types it as `integer`.
Bug introduced in PR #65467.
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
diff --git a/docs/apis/rest-api/v3/reports.mdx b/docs/apis/rest-api/v3/reports.mdx
index 7723af344e0..025d95c0f8c 100644
--- a/docs/apis/rest-api/v3/reports.mdx
+++ b/docs/apis/rest-api/v3/reports.mdx
@@ -309,7 +309,7 @@ woocommerce.get("reports/sales", query).parsed_response
"total_items": 6,
"total_tax": "0.00",
"total_shipping": "10.00",
- "total_refunds": "10.00",
+ "total_refunds": 10,
"total_discount": "0.00",
"totals_grouped_by": "day",
"totals": {