arky-sdk 0.5.24 → 0.5.25
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 +3 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -4
- package/dist/index.d.ts +3 -4
- package/dist/index.js +3 -12
- package/dist/index.js.map +1 -1
- package/dist/types.cjs.map +1 -1
- package/dist/types.d.cts +4 -23
- package/dist/types.d.ts +4 -23
- package/dist/types.js.map +1 -1
- package/dist/utils.cjs +2 -3
- package/dist/utils.cjs.map +1 -1
- package/dist/utils.js +2 -3
- package/dist/utils.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -405,14 +405,6 @@ var createBusinessApi = (apiConfig) => {
|
|
|
405
405
|
{ provider: params.provider },
|
|
406
406
|
options
|
|
407
407
|
);
|
|
408
|
-
},
|
|
409
|
-
async setupChannelWebhook(params, options) {
|
|
410
|
-
const businessId = params.businessId || apiConfig.businessId;
|
|
411
|
-
return apiConfig.httpClient.post(
|
|
412
|
-
`/v1/businesses/${businessId}/channels/${params.integrationId}/webhook`,
|
|
413
|
-
{ webhookBaseUrl: params.webhookBaseUrl },
|
|
414
|
-
options
|
|
415
|
-
);
|
|
416
408
|
}
|
|
417
409
|
};
|
|
418
410
|
};
|
|
@@ -1686,13 +1678,12 @@ function getFirstAvailableFCId(variant, quantity = 1) {
|
|
|
1686
1678
|
|
|
1687
1679
|
// src/utils/integrations.ts
|
|
1688
1680
|
function getPaymentConfig(configs) {
|
|
1689
|
-
|
|
1690
|
-
const i = configs.integrations?.find((i2) => i2.id === configs.paymentId);
|
|
1681
|
+
const i = configs.integrations?.find((i2) => i2.provider?.type === "stripe" && i2.provider.activeForCardPayments);
|
|
1691
1682
|
if (!i || i.provider?.type !== "stripe") return null;
|
|
1692
1683
|
return { publishableKey: i.provider.publishableKey, currency: i.provider.currency };
|
|
1693
1684
|
}
|
|
1694
1685
|
function getAnalyticsConfigs(configs) {
|
|
1695
|
-
return (configs.
|
|
1686
|
+
return (configs.integrations || []).filter((i) => i.provider?.type === "google_analytics4" && i.provider.activeForTracking).map((i) => {
|
|
1696
1687
|
if (i.provider.type === "google_analytics4") {
|
|
1697
1688
|
return { measurementId: i.provider.measurementId };
|
|
1698
1689
|
}
|
|
@@ -1701,7 +1692,7 @@ function getAnalyticsConfigs(configs) {
|
|
|
1701
1692
|
}
|
|
1702
1693
|
|
|
1703
1694
|
// src/index.ts
|
|
1704
|
-
var SDK_VERSION = "0.5.
|
|
1695
|
+
var SDK_VERSION = "0.5.25";
|
|
1705
1696
|
var SUPPORTED_FRAMEWORKS = [
|
|
1706
1697
|
"astro",
|
|
1707
1698
|
"react",
|