@01.software/sdk 0.25.0 → 0.27.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/README.md +28 -3
- package/dist/analytics/react.cjs +249 -0
- package/dist/analytics/react.cjs.map +1 -0
- package/dist/analytics/react.d.cts +8 -0
- package/dist/analytics/react.d.ts +8 -0
- package/dist/analytics/react.js +228 -0
- package/dist/analytics/react.js.map +1 -0
- package/dist/{const-C8UhtzLn.d.cts → const-C0GlmeJ_.d.cts} +6 -6
- package/dist/{const-Bs-QcTj0.d.ts → const-D-xucnw4.d.ts} +6 -6
- package/dist/{image-TT8lTsk5.d.cts → image-BDz2-AaO.d.cts} +1 -1
- package/dist/{image-TT8lTsk5.d.ts → image-BDz2-AaO.d.ts} +1 -1
- package/dist/index.cjs +32 -7
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -9
- package/dist/index.d.ts +9 -9
- package/dist/index.js +32 -7
- package/dist/index.js.map +1 -1
- package/dist/{payload-types-BaK4zCQ8.d.cts → payload-types-BPvUmPAq.d.cts} +803 -709
- package/dist/{payload-types-BaK4zCQ8.d.ts → payload-types-BPvUmPAq.d.ts} +803 -709
- package/dist/realtime.d.cts +2 -2
- package/dist/realtime.d.ts +2 -2
- package/dist/{server-DLdbWJVv.d.cts → server-BINWywT8.d.cts} +1 -1
- package/dist/{server-DLdbWJVv.d.ts → server-BINWywT8.d.ts} +1 -1
- package/dist/{server-CkGfBnSx.d.cts → server-_zvihptw.d.ts} +27 -4
- package/dist/{server-DQYWLnkt.d.ts → server-n3xK4Nks.d.cts} +27 -4
- package/dist/server.cjs +25 -4
- package/dist/server.cjs.map +1 -1
- package/dist/server.d.cts +4 -4
- package/dist/server.d.ts +4 -4
- package/dist/server.js +25 -4
- package/dist/server.js.map +1 -1
- package/dist/{types-DjaaBExv.d.ts → types-BLdthWiW.d.ts} +1 -1
- package/dist/{types-BH-YBrFs.d.cts → types-DzWNu9pw.d.cts} +1 -1
- package/dist/ui/canvas/server.d.cts +1 -1
- package/dist/ui/canvas/server.d.ts +1 -1
- package/dist/ui/canvas.d.cts +3 -3
- package/dist/ui/canvas.d.ts +3 -3
- package/dist/ui/form.d.cts +1 -1
- package/dist/ui/form.d.ts +1 -1
- package/dist/ui/image.d.cts +1 -1
- package/dist/ui/image.d.ts +1 -1
- package/dist/ui/rich-text.cjs +138 -0
- package/dist/ui/rich-text.cjs.map +1 -1
- package/dist/ui/rich-text.d.cts +23 -1
- package/dist/ui/rich-text.d.ts +23 -1
- package/dist/ui/rich-text.js +138 -0
- package/dist/ui/rich-text.js.map +1 -1
- package/dist/ui/video.d.cts +2 -2
- package/dist/ui/video.d.ts +2 -2
- package/dist/{video-DbLL8yuc.d.cts → video-WR_TFO9a.d.cts} +1 -1
- package/dist/{video-DbLL8yuc.d.ts → video-WR_TFO9a.d.ts} +1 -1
- package/dist/webhook.d.cts +3 -3
- package/dist/webhook.d.ts +3 -3
- package/package.json +41 -24
package/dist/index.d.cts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { d as Cart, e as CartItem, O as Order, f as Product } from './payload-types-
|
|
2
|
-
export { A as Article, g as ArticleAuthor, h as ArticleCategory, i as ArticleTag, D as Document, I as Image, P as Post, j as PostCategory, k as ProductVariant, T as Tenant, V as Video } from './payload-types-
|
|
3
|
-
import { C as CustomerAuth, a as CustomerAuthOptions, S as StockCheckParams, b as StockCheckResponse, L as ListingGroupsParams, P as ProductListingGroupsResponse, A as AddItemParams, U as UpdateItemParams, R as RemoveItemParams, c as ApplyDiscountParams, d as RemoveDiscountParams, e as ClearCartParams, f as CheckoutParams, g as PayloadFindResponse, V as ValidateDiscountParams, h as ValidateDiscountResult, i as CalculateShippingParams, j as CalculateShippingResult, k as ApiQueryOptions, l as ProductListingGroupsQueryOptions, m as
|
|
4
|
-
export {
|
|
1
|
+
import { d as Cart, e as CartItem, O as Order, f as Product } from './payload-types-BPvUmPAq.cjs';
|
|
2
|
+
export { A as Article, g as ArticleAuthor, h as ArticleCategory, i as ArticleTag, D as Document, I as Image, P as Post, j as PostCategory, k as ProductVariant, T as Tenant, V as Video } from './payload-types-BPvUmPAq.cjs';
|
|
3
|
+
import { C as CustomerAuth, a as CustomerAuthOptions, S as StockCheckParams, b as StockCheckResponse, L as ListingGroupsParams, P as ProductListingGroupsResponse, A as AddItemParams, U as UpdateItemParams, R as RemoveItemParams, c as ApplyDiscountParams, d as RemoveDiscountParams, e as ClearCartParams, f as CheckoutParams, g as PayloadFindResponse, V as ValidateDiscountParams, h as ValidateDiscountResult, i as CalculateShippingParams, j as CalculateShippingResult, k as ApiQueryOptions, l as ProductListingGroupsQueryOptions, m as CommunityClient, n as ReadOnlyQueryHooks, o as ReadOnlyCollectionClient, p as ClientState, q as ClientConfig } from './server-n3xK4Nks.cjs';
|
|
4
|
+
export { r as ApiError, s as AuthError, B as BanCustomerParams, t as BaseApi, u as BulkImportFulfillmentsParams, v as BulkImportFulfillmentsResponse, w as CartApi, x as CartApiOptions, y as ClientMetadata, z as ClientServerConfig, D as CollectionClient, E as CollectionDetailQueryParams, F as CollectionHooks, G as CollectionInfiniteQueryParams, H as CollectionQueryBuilder, I as CollectionQueryParams, J as CommunityBan, K as CommunityClientOptions, M as CommunityPost, N as ConfigError, O as ConfirmPaymentParams, Q as ConfirmPaymentResponse, T as ConflictError, W as CreateFulfillmentParams, X as CreateOrderParams, Y as CreateReturnParams, Z as CustomerAuthResponse, _ as CustomerHooks, $ as CustomerLoginData, a0 as CustomerProfile, a1 as CustomerRefreshResponse, a2 as CustomerRegisterData, a3 as CustomerRegisterResponse, a4 as CustomerSnapshot, a5 as DebugConfig, a6 as DeepPartial, a7 as DiscountApi, a8 as DiscountApiOptions, a9 as ExtractArrayType, aa as GenerateMetadataOptions, ab as GoneError, ac as InfiniteQueryOptions, ad as ModerationApi, ae as ModerationApiOptions, af as NetworkError, ag as NotFoundError, ah as OrderApi, ai as OrderApiOptions, aj as PaginationMeta, ak as PayloadMutationResponse, al as PermissionError, am as ProductApi, an as ProductApiOptions, ao as ProductListingGroup, ap as ProductListingGroupSummary, aq as ProductListingGroupsItem, ar as ProductListingProductShape, as as ProductListingProjection, at as ProductOptionMatrix, au as ProductOptionMatrixOption, av as ProductOptionMatrixValue, aw as ProductOptionMatrixVariant, ax as ProductOptionShape, ay as ProductOptionValueShape, az as ProductVariantShape, aA as QueryHooks, aB as QueryOptions, aC as RateLimitError, aD as ReadOnlyQueryBuilder, aE as RequestOptions, aF as RetryConfig, aG as ReturnItem, aH as ReturnReason, aI as ReturnWithRefundParams, aJ as SDKError, aK as ServerApiOptions, aL as ServerClient, aL as ServerClientType, aM as ServerCollectionClient, aN as ServerCollectionQueryBuilder, aO as ServerCommerceClient, aP as ServerCommerceClientOptions, aQ as ServiceUnavailableError, aR as ShippingApi, aS as ShippingApiOptions, aT as StockCheckResult, aU as SuspenseInfiniteQueryOptions, aV as SuspenseQueryOptions, aW as TimeoutError, aX as UnbanCustomerParams, aY as UpdateFulfillmentParams, aZ as UpdateOrderParams, a_ as UpdateProfileData, a$ as UpdateReturnParams, b0 as UpdateTransactionParams, b1 as UsageLimitError, b2 as ValidationError, b3 as buildProductListingGroupsByOption, b4 as buildProductListingProjection, b5 as buildProductOptionMatrix, b6 as createAuthError, b7 as createConflictError, b8 as createNotFoundError, b9 as createPermissionError, ba as createRateLimitError, bb as createServerClient, bc as getAvailableOptionValues, bd as getSelectedValueByOptionId, be as isApiError, bf as isAuthError, bg as isConfigError, bh as isConflictError, bi as isGoneError, bj as isNetworkError, bk as isNotFoundError, bl as isPermissionError, bm as isRateLimitError, bn as isSDKError, bo as isServiceUnavailableError, bp as isTimeoutError, bq as isUsageLimitError, br as isValidationError, bs as normalizeSelectedValueIds, bt as resolveApiUrl, bu as resolveVariantForSelection } from './server-n3xK4Nks.cjs';
|
|
5
5
|
import { QueryClient } from '@tanstack/react-query';
|
|
6
|
-
export { C as CollectionType } from './types-
|
|
7
|
-
import { P as PublicCollection } from './const-
|
|
8
|
-
export {
|
|
6
|
+
export { C as CollectionType } from './types-DzWNu9pw.cjs';
|
|
7
|
+
import { P as PublicCollection } from './const-C0GlmeJ_.cjs';
|
|
8
|
+
export { C as COLLECTIONS, a as Collection, I as INTERNAL_COLLECTIONS, b as InternalCollection, S as SERVER_COLLECTIONS, c as SERVER_ONLY_COLLECTIONS, d as ServerCollection, e as ServerOnlyCollection } from './const-C0GlmeJ_.cjs';
|
|
9
9
|
export { a as RealtimeConnection, R as RealtimeEvent, b as RealtimeListener } from './realtime-D7HtUpqt.cjs';
|
|
10
10
|
export { CUSTOMER_PASSWORD_RESET_OPERATION, CustomerAuthWebhookEvent, CustomerAuthWebhookHandlers, CustomerPasswordResetWebhookData, CustomerPasswordResetWebhookEvent, WebhookEvent, WebhookHandler, WebhookOperation, WebhookOptions, createCustomerAuthWebhookHandler, createTypedWebhookHandler, handleWebhook, isCustomerPasswordResetWebhookEvent, isValidWebhookEvent } from './webhook.cjs';
|
|
11
|
-
export {
|
|
12
|
-
export {
|
|
11
|
+
export { a as IMAGE_SIZES, I as ImageData, b as ImagePalette, c as ImagePlaceholderOptions, g as getImageLqip, d as getImagePalette, e as getImagePlaceholderStyle, f as getImageSrcSet, h as getImageUrl } from './image-BDz2-AaO.cjs';
|
|
12
|
+
export { V as VideoGifOptions, a as VideoThumbnailOptions, g as getVideoGif, b as getVideoMp4Url, c as getVideoStoryboard, d as getVideoStreamUrl, e as getVideoThumbnail } from './video-WR_TFO9a.cjs';
|
|
13
13
|
export { Analytics, AnalyticsConfig, createAnalytics } from './analytics.cjs';
|
|
14
14
|
import 'payload';
|
|
15
15
|
import 'next';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { d as Cart, e as CartItem, O as Order, f as Product } from './payload-types-
|
|
2
|
-
export { A as Article, g as ArticleAuthor, h as ArticleCategory, i as ArticleTag, D as Document, I as Image, P as Post, j as PostCategory, k as ProductVariant, T as Tenant, V as Video } from './payload-types-
|
|
3
|
-
import { C as CustomerAuth, a as CustomerAuthOptions, S as StockCheckParams, b as StockCheckResponse, L as ListingGroupsParams, P as ProductListingGroupsResponse, A as AddItemParams, U as UpdateItemParams, R as RemoveItemParams, c as ApplyDiscountParams, d as RemoveDiscountParams, e as ClearCartParams, f as CheckoutParams, g as PayloadFindResponse, V as ValidateDiscountParams, h as ValidateDiscountResult, i as CalculateShippingParams, j as CalculateShippingResult, k as ApiQueryOptions, l as ProductListingGroupsQueryOptions, m as
|
|
4
|
-
export {
|
|
1
|
+
import { d as Cart, e as CartItem, O as Order, f as Product } from './payload-types-BPvUmPAq.js';
|
|
2
|
+
export { A as Article, g as ArticleAuthor, h as ArticleCategory, i as ArticleTag, D as Document, I as Image, P as Post, j as PostCategory, k as ProductVariant, T as Tenant, V as Video } from './payload-types-BPvUmPAq.js';
|
|
3
|
+
import { C as CustomerAuth, a as CustomerAuthOptions, S as StockCheckParams, b as StockCheckResponse, L as ListingGroupsParams, P as ProductListingGroupsResponse, A as AddItemParams, U as UpdateItemParams, R as RemoveItemParams, c as ApplyDiscountParams, d as RemoveDiscountParams, e as ClearCartParams, f as CheckoutParams, g as PayloadFindResponse, V as ValidateDiscountParams, h as ValidateDiscountResult, i as CalculateShippingParams, j as CalculateShippingResult, k as ApiQueryOptions, l as ProductListingGroupsQueryOptions, m as CommunityClient, n as ReadOnlyQueryHooks, o as ReadOnlyCollectionClient, p as ClientState, q as ClientConfig } from './server-_zvihptw.js';
|
|
4
|
+
export { r as ApiError, s as AuthError, B as BanCustomerParams, t as BaseApi, u as BulkImportFulfillmentsParams, v as BulkImportFulfillmentsResponse, w as CartApi, x as CartApiOptions, y as ClientMetadata, z as ClientServerConfig, D as CollectionClient, E as CollectionDetailQueryParams, F as CollectionHooks, G as CollectionInfiniteQueryParams, H as CollectionQueryBuilder, I as CollectionQueryParams, J as CommunityBan, K as CommunityClientOptions, M as CommunityPost, N as ConfigError, O as ConfirmPaymentParams, Q as ConfirmPaymentResponse, T as ConflictError, W as CreateFulfillmentParams, X as CreateOrderParams, Y as CreateReturnParams, Z as CustomerAuthResponse, _ as CustomerHooks, $ as CustomerLoginData, a0 as CustomerProfile, a1 as CustomerRefreshResponse, a2 as CustomerRegisterData, a3 as CustomerRegisterResponse, a4 as CustomerSnapshot, a5 as DebugConfig, a6 as DeepPartial, a7 as DiscountApi, a8 as DiscountApiOptions, a9 as ExtractArrayType, aa as GenerateMetadataOptions, ab as GoneError, ac as InfiniteQueryOptions, ad as ModerationApi, ae as ModerationApiOptions, af as NetworkError, ag as NotFoundError, ah as OrderApi, ai as OrderApiOptions, aj as PaginationMeta, ak as PayloadMutationResponse, al as PermissionError, am as ProductApi, an as ProductApiOptions, ao as ProductListingGroup, ap as ProductListingGroupSummary, aq as ProductListingGroupsItem, ar as ProductListingProductShape, as as ProductListingProjection, at as ProductOptionMatrix, au as ProductOptionMatrixOption, av as ProductOptionMatrixValue, aw as ProductOptionMatrixVariant, ax as ProductOptionShape, ay as ProductOptionValueShape, az as ProductVariantShape, aA as QueryHooks, aB as QueryOptions, aC as RateLimitError, aD as ReadOnlyQueryBuilder, aE as RequestOptions, aF as RetryConfig, aG as ReturnItem, aH as ReturnReason, aI as ReturnWithRefundParams, aJ as SDKError, aK as ServerApiOptions, aL as ServerClient, aL as ServerClientType, aM as ServerCollectionClient, aN as ServerCollectionQueryBuilder, aO as ServerCommerceClient, aP as ServerCommerceClientOptions, aQ as ServiceUnavailableError, aR as ShippingApi, aS as ShippingApiOptions, aT as StockCheckResult, aU as SuspenseInfiniteQueryOptions, aV as SuspenseQueryOptions, aW as TimeoutError, aX as UnbanCustomerParams, aY as UpdateFulfillmentParams, aZ as UpdateOrderParams, a_ as UpdateProfileData, a$ as UpdateReturnParams, b0 as UpdateTransactionParams, b1 as UsageLimitError, b2 as ValidationError, b3 as buildProductListingGroupsByOption, b4 as buildProductListingProjection, b5 as buildProductOptionMatrix, b6 as createAuthError, b7 as createConflictError, b8 as createNotFoundError, b9 as createPermissionError, ba as createRateLimitError, bb as createServerClient, bc as getAvailableOptionValues, bd as getSelectedValueByOptionId, be as isApiError, bf as isAuthError, bg as isConfigError, bh as isConflictError, bi as isGoneError, bj as isNetworkError, bk as isNotFoundError, bl as isPermissionError, bm as isRateLimitError, bn as isSDKError, bo as isServiceUnavailableError, bp as isTimeoutError, bq as isUsageLimitError, br as isValidationError, bs as normalizeSelectedValueIds, bt as resolveApiUrl, bu as resolveVariantForSelection } from './server-_zvihptw.js';
|
|
5
5
|
import { QueryClient } from '@tanstack/react-query';
|
|
6
|
-
export { C as CollectionType } from './types-
|
|
7
|
-
import { P as PublicCollection } from './const-
|
|
8
|
-
export {
|
|
6
|
+
export { C as CollectionType } from './types-BLdthWiW.js';
|
|
7
|
+
import { P as PublicCollection } from './const-D-xucnw4.js';
|
|
8
|
+
export { C as COLLECTIONS, a as Collection, I as INTERNAL_COLLECTIONS, b as InternalCollection, S as SERVER_COLLECTIONS, c as SERVER_ONLY_COLLECTIONS, d as ServerCollection, e as ServerOnlyCollection } from './const-D-xucnw4.js';
|
|
9
9
|
export { a as RealtimeConnection, R as RealtimeEvent, b as RealtimeListener } from './realtime-D7HtUpqt.js';
|
|
10
10
|
export { CUSTOMER_PASSWORD_RESET_OPERATION, CustomerAuthWebhookEvent, CustomerAuthWebhookHandlers, CustomerPasswordResetWebhookData, CustomerPasswordResetWebhookEvent, WebhookEvent, WebhookHandler, WebhookOperation, WebhookOptions, createCustomerAuthWebhookHandler, createTypedWebhookHandler, handleWebhook, isCustomerPasswordResetWebhookEvent, isValidWebhookEvent } from './webhook.js';
|
|
11
|
-
export {
|
|
12
|
-
export {
|
|
11
|
+
export { a as IMAGE_SIZES, I as ImageData, b as ImagePalette, c as ImagePlaceholderOptions, g as getImageLqip, d as getImagePalette, e as getImagePlaceholderStyle, f as getImageSrcSet, h as getImageUrl } from './image-BDz2-AaO.js';
|
|
12
|
+
export { V as VideoGifOptions, a as VideoThumbnailOptions, g as getVideoGif, b as getVideoMp4Url, c as getVideoStoryboard, d as getVideoStreamUrl, e as getVideoThumbnail } from './video-WR_TFO9a.js';
|
|
13
13
|
export { Analytics, AnalyticsConfig, createAnalytics } from './analytics.js';
|
|
14
14
|
import 'payload';
|
|
15
15
|
import 'next';
|
package/dist/index.js
CHANGED
|
@@ -455,14 +455,23 @@ function debugLog(debug, type, message, data) {
|
|
|
455
455
|
}
|
|
456
456
|
}
|
|
457
457
|
function getErrorSuggestion(status) {
|
|
458
|
-
if (status === 400)
|
|
458
|
+
if (status === 400)
|
|
459
|
+
return "The request data failed validation. Check field values and types.";
|
|
459
460
|
if (status === 401) return "Please check your authentication credentials.";
|
|
460
|
-
if (status === 403)
|
|
461
|
+
if (status === 403)
|
|
462
|
+
return "Access denied. Check your credentials or permissions.";
|
|
461
463
|
if (status === 404) return "The requested resource was not found.";
|
|
462
464
|
if (status === 422) return "The request data failed validation.";
|
|
463
465
|
if (status >= 500) return "A server error occurred. Please try again later.";
|
|
464
466
|
return void 0;
|
|
465
467
|
}
|
|
468
|
+
function isUsageLimitExceededResponse(response) {
|
|
469
|
+
if (response.status !== 429) return false;
|
|
470
|
+
const limit = parseInt(response.headers.get("X-Usage-Limit") || "", 10);
|
|
471
|
+
const current = parseInt(response.headers.get("X-Usage-Current") || "", 10);
|
|
472
|
+
if (!Number.isFinite(limit) || !Number.isFinite(current)) return false;
|
|
473
|
+
return response.headers.get("X-Usage-Exceeded") === "true" || current > limit;
|
|
474
|
+
}
|
|
466
475
|
async function parseErrorBody(response) {
|
|
467
476
|
const fallback = {
|
|
468
477
|
errorMessage: `HTTP ${response.status}: ${response.statusText}`,
|
|
@@ -662,7 +671,7 @@ async function httpFetch(url, options) {
|
|
|
662
671
|
headers: Object.fromEntries(response.headers.entries())
|
|
663
672
|
});
|
|
664
673
|
if (!response.ok) {
|
|
665
|
-
if (response
|
|
674
|
+
if (isUsageLimitExceededResponse(response)) {
|
|
666
675
|
const limit = parseInt(
|
|
667
676
|
response.headers.get("X-Usage-Limit") || "0",
|
|
668
677
|
10
|
|
@@ -679,7 +688,11 @@ async function httpFetch(url, options) {
|
|
|
679
688
|
createUsageLimitError(
|
|
680
689
|
`Monthly API usage limit exceeded (${current.toLocaleString()}/${limit.toLocaleString()})`,
|
|
681
690
|
{ limit, current, remaining },
|
|
682
|
-
{
|
|
691
|
+
{
|
|
692
|
+
url,
|
|
693
|
+
method: requestInit.method || "GET",
|
|
694
|
+
attempt: attempt + 1
|
|
695
|
+
},
|
|
683
696
|
"Monthly API call limit exceeded. Please upgrade your plan.",
|
|
684
697
|
"Upgrade your tenant plan to increase the monthly API call limit."
|
|
685
698
|
),
|
|
@@ -1124,6 +1137,7 @@ var INTERNAL_COLLECTIONS = [
|
|
|
1124
1137
|
"email-logs",
|
|
1125
1138
|
"api-usage",
|
|
1126
1139
|
"tenant-analytics-daily",
|
|
1140
|
+
"tenant-web-analytics-config",
|
|
1127
1141
|
"analytics-event-schemas",
|
|
1128
1142
|
"subscriptions",
|
|
1129
1143
|
"billing-history",
|
|
@@ -1131,6 +1145,7 @@ var INTERNAL_COLLECTIONS = [
|
|
|
1131
1145
|
"api-keys",
|
|
1132
1146
|
"personal-access-tokens",
|
|
1133
1147
|
"tenant-entitlements",
|
|
1148
|
+
"tenant-purge-jobs",
|
|
1134
1149
|
"direct-upload-sessions",
|
|
1135
1150
|
"webhook-events",
|
|
1136
1151
|
"webhook-deliveries",
|
|
@@ -1209,8 +1224,6 @@ var COLLECTIONS = [
|
|
|
1209
1224
|
"reaction-types",
|
|
1210
1225
|
"bookmarks",
|
|
1211
1226
|
"post-categories",
|
|
1212
|
-
"reports",
|
|
1213
|
-
"community-bans",
|
|
1214
1227
|
// Events
|
|
1215
1228
|
"event-calendars",
|
|
1216
1229
|
"events",
|
|
@@ -1218,7 +1231,11 @@ var COLLECTIONS = [
|
|
|
1218
1231
|
"event-occurrences",
|
|
1219
1232
|
"event-tags"
|
|
1220
1233
|
];
|
|
1221
|
-
var SERVER_ONLY_COLLECTIONS = [
|
|
1234
|
+
var SERVER_ONLY_COLLECTIONS = [
|
|
1235
|
+
"customer-groups",
|
|
1236
|
+
"reports",
|
|
1237
|
+
"community-bans"
|
|
1238
|
+
];
|
|
1222
1239
|
var SERVER_COLLECTIONS = [
|
|
1223
1240
|
...COLLECTIONS,
|
|
1224
1241
|
...SERVER_ONLY_COLLECTIONS
|
|
@@ -1913,6 +1930,13 @@ var OrderApi = class extends BaseApi {
|
|
|
1913
1930
|
updateTransaction(params) {
|
|
1914
1931
|
return this.request("/api/transactions/update", params);
|
|
1915
1932
|
}
|
|
1933
|
+
confirmPayment(params) {
|
|
1934
|
+
return this.request(
|
|
1935
|
+
"/api/orders/confirm-payment",
|
|
1936
|
+
params,
|
|
1937
|
+
params.providerEventId ? { headers: { "X-Idempotency-Key": params.providerEventId } } : void 0
|
|
1938
|
+
);
|
|
1939
|
+
}
|
|
1916
1940
|
checkout(params) {
|
|
1917
1941
|
return this.request("/api/orders/checkout", params);
|
|
1918
1942
|
}
|
|
@@ -1978,6 +2002,7 @@ var ServerCommerceClient = class {
|
|
|
1978
2002
|
create: orderApi.createOrder.bind(orderApi),
|
|
1979
2003
|
update: orderApi.updateOrder.bind(orderApi),
|
|
1980
2004
|
updateTransaction: orderApi.updateTransaction.bind(orderApi),
|
|
2005
|
+
confirmPayment: orderApi.confirmPayment.bind(orderApi),
|
|
1981
2006
|
createFulfillment: orderApi.createFulfillment.bind(orderApi),
|
|
1982
2007
|
updateFulfillment: orderApi.updateFulfillment.bind(orderApi),
|
|
1983
2008
|
bulkImportFulfillments: orderApi.bulkImportFulfillments.bind(orderApi),
|