@delopay/sdk 0.107.0 → 0.108.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
@@ -554,6 +554,11 @@ var Connectors = class {
554
554
  * This is the retrieve path alone. `create` and `update` echo back what the
555
555
  * caller sent, and `clone` returns the *copied* secrets — see that method.
556
556
  *
557
+ * Because the value is gone, `has_live_webhook_secret` and
558
+ * `has_sandbox_webhook_secret` are what tell a stored webhook signing secret
559
+ * from an unconfigured one. Render those; never infer configuration from the
560
+ * `null` block.
561
+ *
557
562
  * `GET /account/{accountId}/connectors/{connectorId}`
558
563
  */
559
564
  async retrieve(accountId, connectorId) {
@@ -624,6 +629,21 @@ var Connectors = class {
624
629
  `/account/${encodeURIComponent(accountId)}/connectors/${encodeURIComponent(connectorId)}/epayouts/catalog/sync`
625
630
  );
626
631
  }
632
+ /**
633
+ * Update a connector account.
634
+ *
635
+ * `connector_webhook_details` **merges** into the stored block key by key
636
+ * (be#992): an absent key keeps its stored secret, an explicit value is
637
+ * written, and an explicit empty string clears that secret. Send only the
638
+ * keys the operator typed — padding the other environment's keys with `''`
639
+ * clears a live signing secret and inbound webhooks stop verifying.
640
+ *
641
+ * The other credential-bearing fields — `connector_wallets_details`,
642
+ * `pm_auth_config`, `additional_merchant_data` — are still whole-value
643
+ * replacements: omit them unless you are writing a complete new value.
644
+ *
645
+ * `POST /account/{accountId}/connectors/{connectorId}`
646
+ */
627
647
  async update(accountId, connectorId, params) {
628
648
  return this.request(
629
649
  "POST",
@@ -2919,6 +2939,32 @@ var Shops = class {
2919
2939
  { body: params, ...options }
2920
2940
  );
2921
2941
  }
2942
+ /**
2943
+ * Read only the checkout appearance of a shop, so the role that may restyle a
2944
+ * checkout can load the checkout it may restyle.
2945
+ *
2946
+ * Gated on `ProfileCheckoutBrandingRead` — the read twin of the
2947
+ * `ProfileCheckoutBrandingEdit` guard on `updateCheckoutBranding` above.
2948
+ * Prefer this over `shops.retrieve` for the branding editor: `retrieve`
2949
+ * returns the whole profile, including the webhook signing key and the
2950
+ * card-vault configuration, and needs the shop-read permission for exactly
2951
+ * that reason.
2952
+ *
2953
+ * `GET /shops/{merchantId}/{shopId}/checkout-branding`
2954
+ *
2955
+ * @param merchantId - The merchant account ID.
2956
+ * @param shopId - The shop (business profile) ID whose branding to read.
2957
+ * @returns The shop's id, name and stored `payment_link_config`. That config
2958
+ * is `null` when the shop has never been styled — the untouched default, not
2959
+ * an error, and distinct from a stored-but-empty style.
2960
+ */
2961
+ async retrieveCheckoutBranding(merchantId, shopId, options) {
2962
+ return this.request(
2963
+ "GET",
2964
+ `/shops/${encodeURIComponent(merchantId)}/${encodeURIComponent(shopId)}/checkout-branding`,
2965
+ options
2966
+ );
2967
+ }
2922
2968
  };
2923
2969
 
2924
2970
  // src/resources/stripeConnect.ts