@delopay/sdk 0.263.0 → 0.265.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.
@@ -4653,6 +4653,85 @@ var Users = class {
4653
4653
  async updateMemberExpiry(params) {
4654
4654
  return this.request("POST", "/user/employees/update-expiry", { body: params });
4655
4655
  }
4656
+ /**
4657
+ * Create a reusable team invitation link. `POST /user/employees/invitation-links`
4658
+ *
4659
+ * Each person who joins through it gets `role_id` on the target, up to
4660
+ * `max_uses` people, until `expires_at`, and only from the networks and
4661
+ * countries `restrictions` allow. Creating it grants nothing and sends
4662
+ * nothing. You may grant only what you could invite with; a shop-level
4663
+ * caller only for its own shop. The secret to share comes back once, in
4664
+ * `token`. A refusal is a `UR_72` error whose `data` is an `InvitationLinkRefusal`.
4665
+ */
4666
+ async createInvitationLink(params) {
4667
+ return this.request("POST", "/user/employees/invitation-links", { body: params });
4668
+ }
4669
+ /**
4670
+ * Your merchant's team invitation links, newest first, with their usage and
4671
+ * status. A shop-level caller sees its own shop's.
4672
+ * `GET /user/employees/invitation-links`
4673
+ */
4674
+ async listInvitationLinks() {
4675
+ return this.request("GET", "/user/employees/invitation-links");
4676
+ }
4677
+ /**
4678
+ * Change a link's name, limit, expiry, access expiry or restrictions.
4679
+ * `PUT /user/employees/invitation-links/{link_id}`
4680
+ *
4681
+ * Send the whole policy and the `modified_at` you read as `version`. Saving
4682
+ * also reconfirms the link under your authority.
4683
+ */
4684
+ async updateInvitationLink(linkId, params) {
4685
+ return this.request("PUT", `/user/employees/invitation-links/${encodeURIComponent(linkId)}`, {
4686
+ body: params
4687
+ });
4688
+ }
4689
+ /**
4690
+ * Revoke a link: nobody joins through it from now on, and who already
4691
+ * joined keeps their access. Revoking a revoked link answers it unchanged.
4692
+ * `POST /user/employees/invitation-links/{link_id}/revoke`
4693
+ */
4694
+ async revokeInvitationLink(linkId) {
4695
+ return this.request(
4696
+ "POST",
4697
+ `/user/employees/invitation-links/${encodeURIComponent(linkId)}/revoke`
4698
+ );
4699
+ }
4700
+ /**
4701
+ * What a shared link offers, before joining. No authentication; grants
4702
+ * nothing. `POST /user/invitation-link/preview`
4703
+ */
4704
+ async previewInvitationLink(token) {
4705
+ return this.request("POST", "/user/invitation-link/preview", { body: { token } });
4706
+ }
4707
+ /**
4708
+ * Join through a shared link from a signed-in session.
4709
+ * `POST /user/invitation-link/join`
4710
+ *
4711
+ * Needs a verified email address. Joining twice answers `already_member`
4712
+ * and uses no second place.
4713
+ */
4714
+ async joinInvitationLink(token) {
4715
+ return this.request("POST", "/user/invitation-link/join", { body: { token } });
4716
+ }
4717
+ /**
4718
+ * Join through a shared link during sign-in, for someone who holds no access
4719
+ * yet: call it with the `accept_invite` single-purpose token set on the
4720
+ * client. Answers the token for the next sign-in step.
4721
+ * `POST /user/invitation-link/join/pre-auth`
4722
+ */
4723
+ async joinInvitationLinkPreAuth(token) {
4724
+ return this.request("POST", "/user/invitation-link/join/pre-auth", { body: { token } });
4725
+ }
4726
+ /**
4727
+ * Make an account through a shared link, for someone who has none. No
4728
+ * authentication. The account holds no access: its owner verifies the
4729
+ * address from the email this sends, signs in and joins.
4730
+ * `POST /user/invitation-link/register`
4731
+ */
4732
+ async registerThroughInvitationLink(params) {
4733
+ return this.request("POST", "/user/invitation-link/register", { body: params });
4734
+ }
4656
4735
  /**
4657
4736
  * One member of your merchant, with the person fields the member list
4658
4737
  * omits. `GET /user/employees/{user_id}/details`
@@ -6848,6 +6927,27 @@ var CheckoutMethods = class {
6848
6927
  body
6849
6928
  });
6850
6929
  }
6930
+ /**
6931
+ * For a buyer in `country` paying `amount` `currency`: which placeable
6932
+ * items they are offered and every reason they are not, asked the way the
6933
+ * hosted checkout asks; and how each smart block of the layout evaluates
6934
+ * for them (`smart_blocks`). `test_mode` asks the Test environment.
6935
+ * `GET /checkout-methods/{profile_id}/availability`
6936
+ */
6937
+ async availability(merchantId, profileId, params) {
6938
+ const { test_mode, ...order } = params;
6939
+ const query = { merchant_id: merchantId, ...order };
6940
+ if (test_mode) {
6941
+ return this.request(
6942
+ "GET",
6943
+ `/checkout-methods/${encodeURIComponent(profileId)}/test/availability`,
6944
+ { query }
6945
+ );
6946
+ }
6947
+ return this.request("GET", `/checkout-methods/${encodeURIComponent(profileId)}/availability`, {
6948
+ query
6949
+ });
6950
+ }
6851
6951
  /**
6852
6952
  * What DeloPay confirms beneath each item the shop can place: the card
6853
6953
  * networks the card form's accounts accept, and the methods or coins a
@@ -13579,4 +13679,4 @@ export {
13579
13679
  decodeNativePanes,
13580
13680
  encodeNativePanes
13581
13681
  };
13582
- //# sourceMappingURL=chunk-YZCDGNZL.js.map
13682
+ //# sourceMappingURL=chunk-SW4N2WY4.js.map