@delopay/sdk 0.300.0 → 0.302.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/dist/internal.cjs CHANGED
@@ -16161,6 +16161,40 @@ var AdminPortal = class {
16161
16161
  query: params
16162
16162
  });
16163
16163
  }
16164
+ /**
16165
+ * The operators' own analytics exclusions, oldest first, with the payments
16166
+ * each one matched in the lookback window. They change the admin's
16167
+ * analytics only; a merchant's own rules never change the admin's figures.
16168
+ * `GET /admin-portal/analytics/exclusions`
16169
+ */
16170
+ async listAnalyticsExclusions() {
16171
+ return this.request("GET", "/admin-portal/analytics/exclusions");
16172
+ }
16173
+ /**
16174
+ * Write a new operator rule. Omitting `merchant_id` applies it to every
16175
+ * merchant; omitting `surfaces` means **all five**, not none.
16176
+ * `POST /admin-portal/analytics/exclusions`
16177
+ */
16178
+ async createAnalyticsExclusion(rule) {
16179
+ return this.request("POST", "/admin-portal/analytics/exclusions", { body: rule });
16180
+ }
16181
+ /**
16182
+ * Replace an operator rule **completely** — send the whole rule, including
16183
+ * an explicit `null` for every optional field you mean to clear.
16184
+ * `PUT /admin-portal/analytics/exclusions/{id}`
16185
+ */
16186
+ async updateAnalyticsExclusion(id, rule) {
16187
+ return this.request("PUT", `/admin-portal/analytics/exclusions/${encodeURIComponent(id)}`, {
16188
+ body: rule
16189
+ });
16190
+ }
16191
+ /**
16192
+ * Delete an operator rule. Returns the rule as it was.
16193
+ * `DELETE /admin-portal/analytics/exclusions/{id}`
16194
+ */
16195
+ async deleteAnalyticsExclusion(id) {
16196
+ return this.request("DELETE", `/admin-portal/analytics/exclusions/${encodeURIComponent(id)}`);
16197
+ }
16164
16198
  /**
16165
16199
  * Device analytics over the canonical client-context observation per
16166
16200
  * payment, rooted at all merchants and drillable via `merchant_id` /
@@ -16773,6 +16807,35 @@ var AdminPortal = class {
16773
16807
  query: { revision: options.revision }
16774
16808
  });
16775
16809
  }
16810
+ /**
16811
+ * What recalculating the shop risk history over `range` would do, without
16812
+ * queuing it: its days, the first day whose counters are rebuilt, the model
16813
+ * it would score with now, and the run of the same range already recorded.
16814
+ * Refused exactly where `startRiskBackfill()` would be.
16815
+ *
16816
+ * `POST /admin-portal/risk-engine/backfill/preview`
16817
+ */
16818
+ async previewRiskBackfill(range) {
16819
+ return this.request("POST", "/admin-portal/risk-engine/backfill/preview", { body: range });
16820
+ }
16821
+ /**
16822
+ * Queue a recalculation of `range`. Days that already have a risk score keep
16823
+ * it, and recalculated days never alert. While the same range is queued or
16824
+ * running, nothing new is started and `enqueued` is `false`.
16825
+ *
16826
+ * `POST /admin-portal/risk-engine/backfill`
16827
+ */
16828
+ async startRiskBackfill(range) {
16829
+ return this.request("POST", "/admin-portal/risk-engine/backfill", { body: range });
16830
+ }
16831
+ /**
16832
+ * One recalculation by the `job_id` a preview or start returned.
16833
+ *
16834
+ * `GET /admin-portal/risk-engine/backfill/{job_id}`
16835
+ */
16836
+ async getRiskBackfill(jobId) {
16837
+ return this.request("GET", `/admin-portal/risk-engine/backfill/${encodeURIComponent(jobId)}`);
16838
+ }
16776
16839
  };
16777
16840
  function transactionListQuery(params) {
16778
16841
  if (!params) return void 0;