@delopay/sdk 0.98.0 → 0.100.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/index.cjs CHANGED
@@ -3248,6 +3248,45 @@ var Users = class {
3248
3248
  async deleteRole(roleId) {
3249
3249
  return this.request("DELETE", `/user/role/${encodeURIComponent(roleId)}`);
3250
3250
  }
3251
+ /**
3252
+ * Read which individual connector accounts a role may see.
3253
+ *
3254
+ * `GET /user/role/{roleId}/connectors`
3255
+ *
3256
+ * **Check `restricted` before reading `connectors`.** An empty list is
3257
+ * ambiguous by itself, so the backend states which case it is: `false` means
3258
+ * the role holds no grant and sees whatever its entity and profile scope
3259
+ * already allowed. Rendering an empty `connectors` array as "this role sees
3260
+ * nothing" inverts the meaning.
3261
+ *
3262
+ * Requires the permission that *edits a role*, not a connector permission.
3263
+ */
3264
+ async getRoleConnectors(roleId) {
3265
+ return this.request("GET", `/user/role/${encodeURIComponent(roleId)}/connectors`);
3266
+ }
3267
+ /**
3268
+ * Replace the set of connector accounts a role may see.
3269
+ *
3270
+ * `PUT /user/role/{roleId}/connectors`
3271
+ *
3272
+ * The call **replaces** the whole set rather than adding to it, so send the
3273
+ * complete list every time. An empty `merchant_connector_ids` clears the
3274
+ * grant and returns the role to unrestricted.
3275
+ *
3276
+ * The backend refuses an id that is not a connector account of the caller's
3277
+ * own merchant, an `Organization`-scoped role (a connector account belongs to
3278
+ * exactly one merchant, so an org-spanning role cannot hold one coherently),
3279
+ * and any predefined role (one static entry shared by every tenant).
3280
+ *
3281
+ * Editing a grant invalidates the role cache and blacklists tokens minted
3282
+ * before the edit, so **users holding this role must sign in again**. Worth
3283
+ * saying in the UI before the save, not after.
3284
+ */
3285
+ async updateRoleConnectors(roleId, params) {
3286
+ return this.request("PUT", `/user/role/${encodeURIComponent(roleId)}/connectors`, {
3287
+ body: params
3288
+ });
3289
+ }
3251
3290
  };
3252
3291
 
3253
3292
  // src/resources/verification.ts
@@ -3400,6 +3439,33 @@ var Analytics = class {
3400
3439
  query: params
3401
3440
  });
3402
3441
  }
3442
+ /**
3443
+ * The recent payments behind one clicked geo target: a map country (in the
3444
+ * active claim mode), optionally narrowed to an IP-resolved city, or one
3445
+ * buyer-local heatmap cell (`dow` + `hour`, paid sessions only). Same
3446
+ * window/scope/filter and gating contract as `geo`; capped at 50 rows,
3447
+ * newest first, with the full match count alongside.
3448
+ * `GET /analytics/geo/transactions`
3449
+ */
3450
+ async geoTransactions(params) {
3451
+ return this.request("GET", "/analytics/geo/transactions", {
3452
+ query: params
3453
+ });
3454
+ }
3455
+ /**
3456
+ * The recent payments behind one clicked device target: exactly one of a
3457
+ * browser family, a platform family, an identified device-model label, or
3458
+ * a device class. Family/model targets are resolved server-side with the
3459
+ * same classifiers the cards use. Same window/scope/filter and gating
3460
+ * contract as `devices`; 50 rows per page (`offset` for the next page),
3461
+ * newest first, with the full match count alongside.
3462
+ * `GET /analytics/devices/transactions`
3463
+ */
3464
+ async deviceTransactions(params) {
3465
+ return this.request("GET", "/analytics/devices/transactions", {
3466
+ query: params
3467
+ });
3468
+ }
3403
3469
  /** Global search. `POST /analytics/search` */
3404
3470
  async search(params) {
3405
3471
  return this.request("POST", "/analytics/search", { body: params });