@delopay/sdk 0.304.0 → 0.305.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.
@@ -13222,6 +13222,11 @@ type ParentGroup = 'Operations' | 'Refunds'
13222
13222
  | 'AnalyticsDevices'
13223
13223
  /** Carved out of `Analytics`: the countries & cities surface. */
13224
13224
  | 'AnalyticsGeo'
13225
+ /**
13226
+ * Period Reports: calendar weeks and months for the shops the role covers
13227
+ * (todos#346). Read-only. An `Analytics` grant expands to it.
13228
+ */
13229
+ | 'AnalyticsReports'
13225
13230
  /** Carved out of `Workflows`. */
13226
13231
  | 'Routing'
13227
13232
  /**
@@ -13442,6 +13447,11 @@ interface ScopeDrillBase extends DrillListControls<ScopeDrillSortKey> {
13442
13447
  country?: string | null;
13443
13448
  country_source?: string | null;
13444
13449
  device_class?: string | null;
13450
+ /**
13451
+ * The zone the series' day buckets were local days of, so a `YYYY-MM-DD`
13452
+ * `target_bucket` spans that local day.
13453
+ */
13454
+ timezone?: string | null;
13445
13455
  /**
13446
13456
  * Which clicked metric this drill is for, so the list reproduces the number
13447
13457
  * that was clicked.
@@ -13572,6 +13582,15 @@ interface AnalyticsScopeRequest {
13572
13582
  * | `unknown` (rows whose render predates classification).
13573
13583
  */
13574
13584
  device_class?: string | null;
13585
+ /**
13586
+ * IANA time zone the day buckets are local calendar days of, e.g.
13587
+ * `Europe/Berlin`. Omit for UTC days. Only the `day` grain reads it: each
13588
+ * bucket is then one local calendar day, so days sum exactly into calendar
13589
+ * weeks and months, and `end_date`, `days` and the previous window count
13590
+ * local days. A zoned request always aggregates live. Older backends ignore
13591
+ * it and answer UTC days; check the response's `timezone`.
13592
+ */
13593
+ timezone?: string | null;
13575
13594
  }
13576
13595
  /**
13577
13596
  * One bucket of aggregated payment activity — a calendar day, or a single UTC
@@ -13684,6 +13703,11 @@ interface AnalyticsScopeResponse {
13684
13703
  * for daily buckets, where `end_date` + `days` describe the axis.
13685
13704
  */
13686
13705
  bucket_start?: string | null;
13706
+ /**
13707
+ * The IANA zone the day buckets are local days of, in its canonical
13708
+ * spelling; absent for UTC days and on backends that predate zoned days.
13709
+ */
13710
+ timezone?: string | null;
13687
13711
  series: AnalyticsDayBucket[];
13688
13712
  /**
13689
13713
  * Equal-length previous window (for period-over-period deltas + comparison).
@@ -26269,6 +26293,16 @@ declare class Analytics {
26269
26293
  * shop. `GET /analytics/scope`
26270
26294
  */
26271
26295
  scope(params?: AnalyticsScopeRequest): Promise<AnalyticsScopeResponse>;
26296
+ /**
26297
+ * Period Reports: the scoped daily series, pinned exactly like `scope`, but
26298
+ * gated on the Period Reports permission area instead of Payment
26299
+ * Performance. Pass `timezone` and each day bucket is a local calendar day,
26300
+ * which sums exactly into calendar weeks and months. Answers only the
26301
+ * `series`, `previous` and `children` blocks and ignores country and device
26302
+ * filters. Accepts a dashboard session or an API key, including a
26303
+ * `statistics_read` key. `GET /analytics/reports`
26304
+ */
26305
+ reports(params?: AnalyticsScopeRequest): Promise<AnalyticsScopeResponse>;
26272
26306
  /**
26273
26307
  * Shop comparison: one series per shop over one window, with whole-window
26274
26308
  * and previous-window totals, so shops can be drawn side by side. Pinned
@@ -13222,6 +13222,11 @@ type ParentGroup = 'Operations' | 'Refunds'
13222
13222
  | 'AnalyticsDevices'
13223
13223
  /** Carved out of `Analytics`: the countries & cities surface. */
13224
13224
  | 'AnalyticsGeo'
13225
+ /**
13226
+ * Period Reports: calendar weeks and months for the shops the role covers
13227
+ * (todos#346). Read-only. An `Analytics` grant expands to it.
13228
+ */
13229
+ | 'AnalyticsReports'
13225
13230
  /** Carved out of `Workflows`. */
13226
13231
  | 'Routing'
13227
13232
  /**
@@ -13442,6 +13447,11 @@ interface ScopeDrillBase extends DrillListControls<ScopeDrillSortKey> {
13442
13447
  country?: string | null;
13443
13448
  country_source?: string | null;
13444
13449
  device_class?: string | null;
13450
+ /**
13451
+ * The zone the series' day buckets were local days of, so a `YYYY-MM-DD`
13452
+ * `target_bucket` spans that local day.
13453
+ */
13454
+ timezone?: string | null;
13445
13455
  /**
13446
13456
  * Which clicked metric this drill is for, so the list reproduces the number
13447
13457
  * that was clicked.
@@ -13572,6 +13582,15 @@ interface AnalyticsScopeRequest {
13572
13582
  * | `unknown` (rows whose render predates classification).
13573
13583
  */
13574
13584
  device_class?: string | null;
13585
+ /**
13586
+ * IANA time zone the day buckets are local calendar days of, e.g.
13587
+ * `Europe/Berlin`. Omit for UTC days. Only the `day` grain reads it: each
13588
+ * bucket is then one local calendar day, so days sum exactly into calendar
13589
+ * weeks and months, and `end_date`, `days` and the previous window count
13590
+ * local days. A zoned request always aggregates live. Older backends ignore
13591
+ * it and answer UTC days; check the response's `timezone`.
13592
+ */
13593
+ timezone?: string | null;
13575
13594
  }
13576
13595
  /**
13577
13596
  * One bucket of aggregated payment activity — a calendar day, or a single UTC
@@ -13684,6 +13703,11 @@ interface AnalyticsScopeResponse {
13684
13703
  * for daily buckets, where `end_date` + `days` describe the axis.
13685
13704
  */
13686
13705
  bucket_start?: string | null;
13706
+ /**
13707
+ * The IANA zone the day buckets are local days of, in its canonical
13708
+ * spelling; absent for UTC days and on backends that predate zoned days.
13709
+ */
13710
+ timezone?: string | null;
13687
13711
  series: AnalyticsDayBucket[];
13688
13712
  /**
13689
13713
  * Equal-length previous window (for period-over-period deltas + comparison).
@@ -26269,6 +26293,16 @@ declare class Analytics {
26269
26293
  * shop. `GET /analytics/scope`
26270
26294
  */
26271
26295
  scope(params?: AnalyticsScopeRequest): Promise<AnalyticsScopeResponse>;
26296
+ /**
26297
+ * Period Reports: the scoped daily series, pinned exactly like `scope`, but
26298
+ * gated on the Period Reports permission area instead of Payment
26299
+ * Performance. Pass `timezone` and each day bucket is a local calendar day,
26300
+ * which sums exactly into calendar weeks and months. Answers only the
26301
+ * `series`, `previous` and `children` blocks and ignores country and device
26302
+ * filters. Accepts a dashboard session or an API key, including a
26303
+ * `statistics_read` key. `GET /analytics/reports`
26304
+ */
26305
+ reports(params?: AnalyticsScopeRequest): Promise<AnalyticsScopeResponse>;
26272
26306
  /**
26273
26307
  * Shop comparison: one series per shop over one window, with whole-window
26274
26308
  * and previous-window totals, so shops can be drawn side by side. Pinned
package/dist/index.cjs CHANGED
@@ -5979,6 +5979,20 @@ var Analytics = class {
5979
5979
  query: params
5980
5980
  });
5981
5981
  }
5982
+ /**
5983
+ * Period Reports: the scoped daily series, pinned exactly like `scope`, but
5984
+ * gated on the Period Reports permission area instead of Payment
5985
+ * Performance. Pass `timezone` and each day bucket is a local calendar day,
5986
+ * which sums exactly into calendar weeks and months. Answers only the
5987
+ * `series`, `previous` and `children` blocks and ignores country and device
5988
+ * filters. Accepts a dashboard session or an API key, including a
5989
+ * `statistics_read` key. `GET /analytics/reports`
5990
+ */
5991
+ async reports(params) {
5992
+ return this.request("GET", "/analytics/reports", {
5993
+ query: params
5994
+ });
5995
+ }
5982
5996
  /**
5983
5997
  * Shop comparison: one series per shop over one window, with whole-window
5984
5998
  * and previous-window totals, so shops can be drawn side by side. Pinned