@01.software/sdk 0.51.0 → 0.65.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/CHANGELOG.md +313 -0
- package/README.md +228 -102
- package/dist/client.cjs +556 -60
- package/dist/client.cjs.map +1 -1
- package/dist/client.d.cts +6 -6
- package/dist/client.d.ts +6 -6
- package/dist/client.js +556 -60
- package/dist/client.js.map +1 -1
- package/dist/{collection-client-CWAeuzV4.d.cts → collection-client-B7rsTtVj.d.cts} +6 -6
- package/dist/{collection-client-hYvVfHIm.d.ts → collection-client-C2sMvfme.d.ts} +6 -6
- package/dist/{const-JD8obaKg.d.ts → const-CRxPTDGt.d.ts} +2 -2
- package/dist/{const-D8LixhAJ.d.cts → const-D6ZRQLxI.d.cts} +2 -2
- package/dist/{index-B0Hjh3Ey.d.ts → index-1auUEYrl.d.ts} +24 -7
- package/dist/{index-Bu0kCc6o.d.cts → index-Bbpf5t-l.d.cts} +24 -7
- package/dist/index.cjs +573 -260
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +19 -12
- package/dist/index.d.ts +19 -12
- package/dist/index.js +573 -260
- package/dist/index.js.map +1 -1
- package/dist/{payload-types-BOsckg8B.d.cts → payload-types-BnIET0xU.d.cts} +567 -438
- package/dist/{payload-types-BOsckg8B.d.ts → payload-types-BnIET0xU.d.ts} +567 -438
- package/dist/query.cjs +62 -3
- package/dist/query.cjs.map +1 -1
- package/dist/query.d.cts +5 -5
- package/dist/query.d.ts +5 -5
- package/dist/query.js +62 -3
- package/dist/query.js.map +1 -1
- package/dist/realtime.d.cts +2 -2
- package/dist/realtime.d.ts +2 -2
- package/dist/server.cjs +557 -20
- package/dist/server.cjs.map +1 -1
- package/dist/server.d.cts +14 -8
- package/dist/server.d.ts +14 -8
- package/dist/server.js +557 -20
- package/dist/server.js.map +1 -1
- package/dist/{types-5ZlcAFuU.d.ts → types-D1y4TgQm.d.ts} +2 -2
- package/dist/{types-Bj8j7VHU.d.ts → types-DnRC3nLG.d.ts} +464 -16
- package/dist/{types-B14sEt1z.d.cts → types-Dp1oYpD3.d.cts} +2 -2
- package/dist/{types-CM5qiR2k.d.cts → types-Dzn0LD2N.d.cts} +464 -16
- package/dist/ui/form.d.cts +1 -1
- package/dist/ui/form.d.ts +1 -1
- package/dist/ui/video.cjs +4 -2
- package/dist/ui/video.cjs.map +1 -1
- package/dist/ui/video.d.cts +4 -2
- package/dist/ui/video.d.ts +4 -2
- package/dist/ui/video.js +4 -2
- package/dist/ui/video.js.map +1 -1
- package/dist/webhook.cjs +13 -2
- package/dist/webhook.cjs.map +1 -1
- package/dist/webhook.d.cts +5 -5
- package/dist/webhook.d.ts +5 -5
- package/dist/webhook.js +13 -2
- package/dist/webhook.js.map +1 -1
- package/package.json +9 -28
- package/dist/analytics/react.cjs +0 -344
- package/dist/analytics/react.cjs.map +0 -1
- package/dist/analytics/react.d.cts +0 -24
- package/dist/analytics/react.d.ts +0 -24
- package/dist/analytics/react.js +0 -319
- package/dist/analytics/react.js.map +0 -1
- package/dist/analytics.cjs +0 -238
- package/dist/analytics.cjs.map +0 -1
- package/dist/analytics.d.cts +0 -39
- package/dist/analytics.d.ts +0 -39
- package/dist/analytics.js +0 -215
- package/dist/analytics.js.map +0 -1
package/dist/query.d.cts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import { QueryClient, UseQueryResult, UseSuspenseQueryResult, InfiniteData, UseInfiniteQueryResult, UseSuspenseInfiniteQueryResult } from '@tanstack/react-query';
|
|
3
|
-
import { i as ApiQueryOptions, P as PayloadFindResponse,
|
|
4
|
-
import './payload-types-
|
|
5
|
-
import { S as ServerCollection, P as PublicCollection } from './const-
|
|
6
|
-
import { C as CollectionClient } from './collection-client-
|
|
7
|
-
import { C as CollectionType } from './types-
|
|
3
|
+
import { i as ApiQueryOptions, P as PayloadFindResponse, cN as PublicReadQueryOptions, L as PayloadMutationResponse, cO as CustomerAuth, cP as CustomerProfile, cQ as CustomerAuthResponse, cR as CustomerLoginData, cS as CustomerRegisterResponse, cT as CustomerRegisterData, cU as CustomerRefreshResponse, cV as UpdateProfileData, cW as ProductListingPageParams, cX as ProductListingPageBaseParams, cY as ProductDetailParams, cZ as ProductDetailCatalogResult, c_ as ProductListingPageCatalogParams, c$ as ProductListingPageResult, d0 as ProductListingGroupsCatalogItem, d1 as ProductListingPageFullParams, d2 as ProductListingGroupsItem, al as RootClient, cp as RootServerClient } from './types-Dzn0LD2N.cjs';
|
|
4
|
+
import './payload-types-BnIET0xU.cjs';
|
|
5
|
+
import { S as ServerCollection, P as PublicCollection } from './const-D6ZRQLxI.cjs';
|
|
6
|
+
import { C as CollectionClient } from './collection-client-B7rsTtVj.cjs';
|
|
7
|
+
import { C as CollectionType } from './types-Dp1oYpD3.cjs';
|
|
8
8
|
import { SDKError } from './errors.cjs';
|
|
9
9
|
export { a as RealtimeConnection, R as RealtimeEvent, b as RealtimeListener } from './realtime-D7HtUpqt.cjs';
|
|
10
10
|
import './metadata.cjs';
|
package/dist/query.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
2
2
|
import { QueryClient, UseQueryResult, UseSuspenseQueryResult, InfiniteData, UseInfiniteQueryResult, UseSuspenseInfiniteQueryResult } from '@tanstack/react-query';
|
|
3
|
-
import { i as ApiQueryOptions, P as PayloadFindResponse,
|
|
4
|
-
import './payload-types-
|
|
5
|
-
import { S as ServerCollection, P as PublicCollection } from './const-
|
|
6
|
-
import { C as CollectionClient } from './collection-client-
|
|
7
|
-
import { C as CollectionType } from './types-
|
|
3
|
+
import { i as ApiQueryOptions, P as PayloadFindResponse, cN as PublicReadQueryOptions, L as PayloadMutationResponse, cO as CustomerAuth, cP as CustomerProfile, cQ as CustomerAuthResponse, cR as CustomerLoginData, cS as CustomerRegisterResponse, cT as CustomerRegisterData, cU as CustomerRefreshResponse, cV as UpdateProfileData, cW as ProductListingPageParams, cX as ProductListingPageBaseParams, cY as ProductDetailParams, cZ as ProductDetailCatalogResult, c_ as ProductListingPageCatalogParams, c$ as ProductListingPageResult, d0 as ProductListingGroupsCatalogItem, d1 as ProductListingPageFullParams, d2 as ProductListingGroupsItem, al as RootClient, cp as RootServerClient } from './types-DnRC3nLG.js';
|
|
4
|
+
import './payload-types-BnIET0xU.js';
|
|
5
|
+
import { S as ServerCollection, P as PublicCollection } from './const-CRxPTDGt.js';
|
|
6
|
+
import { C as CollectionClient } from './collection-client-C2sMvfme.js';
|
|
7
|
+
import { C as CollectionType } from './types-D1y4TgQm.js';
|
|
8
8
|
import { SDKError } from './errors.js';
|
|
9
9
|
export { a as RealtimeConnection, R as RealtimeEvent, b as RealtimeListener } from './realtime-D7HtUpqt.js';
|
|
10
10
|
import './metadata.js';
|
package/dist/query.js
CHANGED
|
@@ -703,10 +703,13 @@ var CustomerHooks = class {
|
|
|
703
703
|
useCustomerLogout(options) {
|
|
704
704
|
return useMutationOriginal2({
|
|
705
705
|
mutationFn: async () => {
|
|
706
|
-
|
|
706
|
+
try {
|
|
707
|
+
await this.ensureCustomerAuth().logoutAsync();
|
|
708
|
+
} finally {
|
|
709
|
+
this.queryClient.removeQueries({ queryKey: customerKeys.all });
|
|
710
|
+
}
|
|
707
711
|
},
|
|
708
712
|
onSuccess: () => {
|
|
709
|
-
this.queryClient.removeQueries({ queryKey: customerKeys.all });
|
|
710
713
|
options?.onSuccess?.();
|
|
711
714
|
},
|
|
712
715
|
onError: options?.onError,
|
|
@@ -861,6 +864,11 @@ var COMMERCE_ENDPOINT_OPERATIONS = {
|
|
|
861
864
|
detail: strictCommerceOperation("checkouts", "post", "/detail"),
|
|
862
865
|
query: strictCommerceOperation("checkouts", "post", "/query")
|
|
863
866
|
},
|
|
867
|
+
draftOrders: {
|
|
868
|
+
calculate: operation("draft-orders", "post", "/:id/calculate"),
|
|
869
|
+
complete: operation("draft-orders", "post", "/:id/complete"),
|
|
870
|
+
finalize: operation("draft-orders", "post", "/:id/finalize")
|
|
871
|
+
},
|
|
864
872
|
transactions: {
|
|
865
873
|
update: operation("transactions", "post", "/update")
|
|
866
874
|
},
|
|
@@ -960,8 +968,51 @@ var portOneStandardActionCapabilityOperations = /* @__PURE__ */ new Set([
|
|
|
960
968
|
]);
|
|
961
969
|
var MEMBERSHIP_ENDPOINT_OPERATIONS = {
|
|
962
970
|
subscribe: operation(null, "post", "/memberships/subscribe"),
|
|
971
|
+
billingCustody: operation(null, "post", "/memberships/billing-custody"),
|
|
963
972
|
cancel: operation(null, "post", "/memberships/:id/cancel"),
|
|
964
|
-
me: operation(null, "get", "/memberships/me")
|
|
973
|
+
me: operation(null, "get", "/memberships/me"),
|
|
974
|
+
chargeResult: operation(null, "post", "/memberships/:id/charge-result"),
|
|
975
|
+
refundResult: operation(null, "post", "/memberships/:id/refund-result"),
|
|
976
|
+
revoke: operation(null, "post", "/memberships/:id/revoke")
|
|
977
|
+
};
|
|
978
|
+
var EXTERNAL_EFFECT_CLAIM_ENDPOINT_OPERATIONS = {
|
|
979
|
+
claim: operation(null, "post", "/external-effect-claims/claim"),
|
|
980
|
+
get: operation(null, "post", "/external-effect-claims/get"),
|
|
981
|
+
arm: operation(null, "post", "/external-effect-claims/arm"),
|
|
982
|
+
release: operation(null, "post", "/external-effect-claims/release"),
|
|
983
|
+
report: operation(null, "post", "/external-effect-claims/report"),
|
|
984
|
+
recovery: operation(null, "post", "/external-effect-claims/recovery")
|
|
985
|
+
};
|
|
986
|
+
var INSTALLATION_CREDENTIAL_ENDPOINT_OPERATIONS = {
|
|
987
|
+
create: operation(null, "post", "/installation-credentials/create"),
|
|
988
|
+
get: operation(null, "post", "/installation-credentials/get"),
|
|
989
|
+
replace: operation(null, "post", "/installation-credentials/replace"),
|
|
990
|
+
dispose: operation(null, "post", "/installation-credentials/dispose")
|
|
991
|
+
};
|
|
992
|
+
var EXTERNAL_CUSTOMER_LINK_ENDPOINT_OPERATIONS = {
|
|
993
|
+
connect: operation("customers", "post", "/external-links/connect"),
|
|
994
|
+
get: operation("customers", "post", "/external-links/get"),
|
|
995
|
+
list: operation("customers", "post", "/external-links/list"),
|
|
996
|
+
unlink: operation("customers", "post", "/external-links/unlink"),
|
|
997
|
+
capturePreviousState: operation(
|
|
998
|
+
"customers",
|
|
999
|
+
"post",
|
|
1000
|
+
"/external-links/capture-previous-state"
|
|
1001
|
+
),
|
|
1002
|
+
clearPreviousState: operation(
|
|
1003
|
+
"customers",
|
|
1004
|
+
"post",
|
|
1005
|
+
"/external-links/clear-previous-state"
|
|
1006
|
+
)
|
|
1007
|
+
};
|
|
1008
|
+
var CUSTOMER_GROUP_ENDPOINT_OPERATIONS = {
|
|
1009
|
+
members: operation("customer-groups", "get", "/:id/members"),
|
|
1010
|
+
grant: operation("customer-groups", "post", "/:id/members/grant"),
|
|
1011
|
+
revoke: operation("customer-groups", "post", "/:id/members/revoke")
|
|
1012
|
+
};
|
|
1013
|
+
var CUSTOMER_AUTH_ENDPOINT_OPERATIONS = {
|
|
1014
|
+
revokeRefresh: operation("customers", "post", "/revoke-refresh"),
|
|
1015
|
+
withdraw: operation("customers", "post", "/withdraw")
|
|
965
1016
|
};
|
|
966
1017
|
var EMBEDDED_ADMIN_ENDPOINT_OPERATIONS = {
|
|
967
1018
|
show: operation("tenants", "get", "/embedded-admin-app"),
|
|
@@ -986,6 +1037,14 @@ var COMMUNITY_ENDPOINT_OPERATIONS = {
|
|
|
986
1037
|
detail: operation("posts", "get", "/detail")
|
|
987
1038
|
}
|
|
988
1039
|
};
|
|
1040
|
+
var GALLERY_ENDPOINT_OPERATIONS = {
|
|
1041
|
+
items: {
|
|
1042
|
+
storefront: operation("gallery-items", "get", "/storefront")
|
|
1043
|
+
}
|
|
1044
|
+
};
|
|
1045
|
+
var VIDEO_ENDPOINT_OPERATIONS = {
|
|
1046
|
+
playback: operation("videos", "post", "/:id/playback")
|
|
1047
|
+
};
|
|
989
1048
|
function resolveOperationTemplate(descriptor) {
|
|
990
1049
|
return descriptor.collection ? `/api/${descriptor.collection}${descriptor.path}` : `/api${descriptor.path}`;
|
|
991
1050
|
}
|