@deliverart/sdk-js-stats 2.14.14 → 2.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -25,6 +25,7 @@ The package now exposes five daily stats families:
25
25
  It also exposes a frontend-ready customer analytics endpoint:
26
26
 
27
27
  - `CustomerStatsOverviewResponse`
28
+ - `DeliveryZoneStatsResponse`
28
29
 
29
30
  Each family includes:
30
31
 
@@ -58,6 +59,10 @@ All daily buckets use the point of sale local day, exposed as `YYYY-MM-DD`.
58
59
  - `GetDeliveryDailyStatsDetails`
59
60
  - `GetDeliveryDailyStatsFromPointOfSale`
60
61
 
62
+ ### Delivery zone analytics
63
+
64
+ - `GetDeliveryZoneStatsFromPointOfSale`
65
+
61
66
  ### Order daily stats
62
67
 
63
68
  - `GetOrderDailyStats`
@@ -198,6 +203,22 @@ const overview = await sdk.call(
198
203
  )
199
204
  ```
200
205
 
206
+ ### Fetch delivery zone analytics for one point of sale
207
+
208
+ ```typescript
209
+ import { GetDeliveryZoneStatsFromPointOfSale } from '@deliverart/sdk-js-stats'
210
+
211
+ const analytics = await sdk.call(
212
+ new GetDeliveryZoneStatsFromPointOfSale('pos-123', {
213
+ query: {
214
+ 'day[after]': '2026-04-01',
215
+ distanceBand: 'between_2km_4km',
216
+ 'order[lateRate]': 'desc',
217
+ },
218
+ }),
219
+ )
220
+ ```
221
+
201
222
  ## License
202
223
 
203
224
  See the main SDK repository for license information.