@delopay/sdk 0.130.0 → 0.132.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/{chunk-HMYRBVUT.js → chunk-I2YGFOLA.js} +36 -4
- package/dist/chunk-I2YGFOLA.js.map +1 -0
- package/dist/index.cjs +35 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +120 -4
- package/dist/index.d.ts +120 -4
- package/dist/index.js +1 -1
- package/dist/internal.cjs +49 -3
- package/dist/internal.cjs.map +1 -1
- package/dist/internal.d.cts +66 -2
- package/dist/internal.d.ts +66 -2
- package/dist/internal.js +15 -1
- package/dist/internal.js.map +1 -1
- package/package.json +17 -18
- package/dist/chunk-HMYRBVUT.js.map +0 -1
package/dist/internal.cjs
CHANGED
|
@@ -887,6 +887,23 @@ var Connectors = class {
|
|
|
887
887
|
{ body: params }
|
|
888
888
|
);
|
|
889
889
|
}
|
|
890
|
+
/**
|
|
891
|
+
* Register checkout/shop domains as Airwallex Apple Pay domains, so Apple Pay
|
|
892
|
+
* renders on those pages.
|
|
893
|
+
* `POST /account/{merchantId}/connectors/{connectorId}/airwallex/apple-pay-domains`
|
|
894
|
+
*
|
|
895
|
+
* Airwallex connectors only. One call registers against a single credential
|
|
896
|
+
* set (`environment`, default `'live'`) — call twice to cover live and
|
|
897
|
+
* sandbox. Idempotent: a host already on the account comes back
|
|
898
|
+
* `already_registered` without a write.
|
|
899
|
+
*/
|
|
900
|
+
async registerAirwallexApplePayDomains(merchantId, connectorId, params) {
|
|
901
|
+
return this.request(
|
|
902
|
+
"POST",
|
|
903
|
+
`/account/${encodeURIComponent(merchantId)}/connectors/${encodeURIComponent(connectorId)}/airwallex/apple-pay-domains`,
|
|
904
|
+
{ body: params }
|
|
905
|
+
);
|
|
906
|
+
}
|
|
890
907
|
/** Get registered webhooks for a connector. `GET /account/{merchantId}/connectors/webhooks/{connectorId}` */
|
|
891
908
|
async getWebhook(merchantId, connectorId) {
|
|
892
909
|
return this.request(
|
|
@@ -7303,6 +7320,14 @@ var PANE_VISIBILITIES = ["always", "embedded_only", "external_only"];
|
|
|
7303
7320
|
function parseVisibility(raw) {
|
|
7304
7321
|
return PANE_VISIBILITIES.find((value) => value === raw) ?? "always";
|
|
7305
7322
|
}
|
|
7323
|
+
var PANE_NATIVE_ELEMENTS = [
|
|
7324
|
+
"everywhere",
|
|
7325
|
+
"embedded_only",
|
|
7326
|
+
"external_only"
|
|
7327
|
+
];
|
|
7328
|
+
function parseNativeElement(raw) {
|
|
7329
|
+
return PANE_NATIVE_ELEMENTS.find((value) => value === raw) ?? "everywhere";
|
|
7330
|
+
}
|
|
7306
7331
|
function paneViewVisibility(view) {
|
|
7307
7332
|
const declared = PANE_VISIBILITIES.find((value) => value === view.visibility);
|
|
7308
7333
|
if (declared) return declared;
|
|
@@ -7534,7 +7559,8 @@ function defaultPane(method, catalog = STRIPE_FALLBACK_PANE_CATALOG) {
|
|
|
7534
7559
|
iconSvg: "",
|
|
7535
7560
|
displayOrder: 0,
|
|
7536
7561
|
visibility: "always",
|
|
7537
|
-
openIn: "tab"
|
|
7562
|
+
openIn: "tab",
|
|
7563
|
+
nativeElement: "everywhere"
|
|
7538
7564
|
};
|
|
7539
7565
|
}
|
|
7540
7566
|
function clonePane(pane) {
|
|
@@ -7580,7 +7606,8 @@ function decodePanes(raw) {
|
|
|
7580
7606
|
// Anything unrecognised degrades to `always` rather than dropping the row.
|
|
7581
7607
|
visibility: parseVisibility(entry["visibility"]),
|
|
7582
7608
|
// Same tolerance: an unknown value degrades to the default `tab`.
|
|
7583
|
-
openIn: entry["open_in"] === "popup" ? "popup" : "tab"
|
|
7609
|
+
openIn: entry["open_in"] === "popup" ? "popup" : "tab",
|
|
7610
|
+
nativeElement: parseNativeElement(entry["native_element"])
|
|
7584
7611
|
});
|
|
7585
7612
|
const indexByMethod = /* @__PURE__ */ new Map();
|
|
7586
7613
|
const out = [];
|
|
@@ -7632,7 +7659,12 @@ function encodePanes(panes) {
|
|
|
7632
7659
|
// never went through `decodePanes`. A decoded pane always holds a valid
|
|
7633
7660
|
// value, so this is a no-op on the round-trip path.
|
|
7634
7661
|
visibility: parseVisibility(pane.visibility),
|
|
7635
|
-
open_in: pane.openIn === "popup" ? "popup" : "tab"
|
|
7662
|
+
open_in: pane.openIn === "popup" ? "popup" : "tab",
|
|
7663
|
+
// Omitted at the default: `everywhere` is what the router decodes an
|
|
7664
|
+
// absent key to, so leaving it out changes nothing — and keeps a blob
|
|
7665
|
+
// stored before the field existed byte-identical on re-encode, which
|
|
7666
|
+
// is what the wire-compatibility test pins.
|
|
7667
|
+
...parseNativeElement(pane.nativeElement) === "everywhere" ? {} : { native_element: parseNativeElement(pane.nativeElement) }
|
|
7636
7668
|
};
|
|
7637
7669
|
});
|
|
7638
7670
|
}
|
|
@@ -8021,6 +8053,20 @@ var AdminPortal = class {
|
|
|
8021
8053
|
`/admin-portal/transactions/${encodeURIComponent(paymentId)}/client-context`
|
|
8022
8054
|
);
|
|
8023
8055
|
}
|
|
8056
|
+
/**
|
|
8057
|
+
* What the rail charged for one attempt of a transaction of ANY merchant,
|
|
8058
|
+
* off the attempt's settlement line (be#843). `line_recorded: false` means
|
|
8059
|
+
* no line exists for the attempt; an absent amount is "no figure", never
|
|
8060
|
+
* zero.
|
|
8061
|
+
*
|
|
8062
|
+
* `GET /admin-portal/transactions/{paymentId}/attempts/{attemptId}/processor-cost`
|
|
8063
|
+
*/
|
|
8064
|
+
async getTransactionAttemptProcessorCost(paymentId, attemptId) {
|
|
8065
|
+
return this.request(
|
|
8066
|
+
"GET",
|
|
8067
|
+
`/admin-portal/transactions/${encodeURIComponent(paymentId)}/attempts/${encodeURIComponent(attemptId)}/processor-cost`
|
|
8068
|
+
);
|
|
8069
|
+
}
|
|
8024
8070
|
/**
|
|
8025
8071
|
* The global payment auto-close policy.
|
|
8026
8072
|
* `GET /admin-portal/auto-close-config`
|