@teamnovu/kit-shopware-composables 0.0.3 → 0.0.4

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.
Files changed (149) hide show
  1. package/api-types/storeApiSchema.localhost.http +1 -1
  2. package/dist/helpers/checkout/index.d.ts +5 -0
  3. package/dist/helpers/checkout/useAddresses.d.ts +210 -0
  4. package/dist/helpers/checkout/useOrderDetails.d.ts +186 -0
  5. package/dist/helpers/checkout/useOrderPayment.d.ts +73 -0
  6. package/dist/helpers/checkout/usePaymentMethods.d.ts +155 -0
  7. package/dist/helpers/checkout/useShippingMethods.d.ts +173 -0
  8. package/dist/helpers/general/index.d.ts +2 -0
  9. package/dist/{usePagination.d.ts → helpers/general/usePagination.d.ts} +1 -1
  10. package/dist/{general → helpers/general}/useSeoUrl.d.ts +1 -1
  11. package/dist/helpers/index.d.ts +4 -0
  12. package/dist/helpers/product/index.d.ts +2 -0
  13. package/dist/helpers/product/useProductPrice.d.ts +61 -0
  14. package/dist/{products → helpers/product}/useProductVariantForOptions.d.ts +1 -1
  15. package/dist/helpers/user/index.d.ts +2 -0
  16. package/dist/helpers/user/useIsLoggedIn.d.ts +2 -0
  17. package/dist/helpers/user/useUser.d.ts +167 -0
  18. package/dist/index.d.ts +3 -221
  19. package/dist/index.mjs +851 -222
  20. package/dist/inject.d.ts +2 -2
  21. package/dist/keys.d.ts +32 -0
  22. package/dist/query/address/index.d.ts +3 -0
  23. package/dist/query/address/useCreateCustomerAddressMutation.d.ts +166 -0
  24. package/dist/query/address/useDeleteCustomerAddressMutation.d.ts +5 -0
  25. package/dist/query/address/useListAddressQuery.d.ts +48 -0
  26. package/dist/query/cart/index.d.ts +4 -0
  27. package/dist/query/cart/useAddLineItemMutation.d.ts +131 -0
  28. package/dist/query/cart/useReadCartQuery.d.ts +108 -0
  29. package/dist/query/cart/useRemoveLineItemMutation.d.ts +136 -0
  30. package/dist/query/cart/useUpdateLineItemMutation.d.ts +131 -0
  31. package/dist/query/checkout/index.d.ts +2 -0
  32. package/dist/query/checkout/useCheckout.d.ts +1 -0
  33. package/dist/query/checkout/useCreateOrderMutation.d.ts +281 -0
  34. package/dist/query/context/index.d.ts +2 -0
  35. package/dist/query/context/useReadContextQuery.d.ts +153 -0
  36. package/dist/query/context/useUpdateContextMutation.d.ts +60 -0
  37. package/dist/query/customer/index.d.ts +6 -0
  38. package/dist/query/customer/useChangeEmailMutation.d.ts +15 -0
  39. package/dist/query/customer/useChangeProfileMutation.d.ts +15 -0
  40. package/dist/query/customer/useLoginCustomerMutation.d.ts +30 -0
  41. package/dist/query/customer/useLogoutCustomerMutation.d.ts +15 -0
  42. package/dist/query/customer/useReadCustomerQuery.d.ts +220 -0
  43. package/dist/query/customer/useRegisterCustomerMutation.d.ts +266 -0
  44. package/dist/query/index.d.ts +10 -0
  45. package/dist/query/order/index.d.ts +1 -0
  46. package/dist/query/order/useReadOrderQuery.d.ts +44 -0
  47. package/dist/query/payment/index.d.ts +3 -0
  48. package/dist/query/payment/useHandlePaymentMutation.d.ts +15 -0
  49. package/dist/query/payment/useOrderSetPaymentMutation.d.ts +15 -0
  50. package/dist/query/payment/useReadPaymentMethodQuery.d.ts +31 -0
  51. package/dist/query/products/index.d.ts +3 -0
  52. package/dist/query/products/useReadCategoryListQuery.d.ts +48 -0
  53. package/dist/query/products/useReadCompactProductListingQuery.d.ts +35 -0
  54. package/dist/query/products/useReadCustomProductDetailQuery.d.ts +67 -0
  55. package/dist/query/shipping/index.d.ts +1 -0
  56. package/dist/query/shipping/useReadShippingMethodQuery.d.ts +55 -0
  57. package/dist/query/types/index.d.ts +2 -0
  58. package/dist/query/types/operations.d.ts +5 -0
  59. package/dist/query/types/query.d.ts +17 -0
  60. package/dist/util/index.d.ts +3 -0
  61. package/dist/util/unrefOptions.d.ts +4 -0
  62. package/dist/util/useOptimistic.d.ts +12 -0
  63. package/docs/index.md +457 -0
  64. package/docs/info.json +3 -0
  65. package/package.json +5 -1
  66. package/src/helpers/checkout/index.ts +5 -0
  67. package/src/helpers/checkout/useAddresses.ts +57 -0
  68. package/src/helpers/checkout/useOrderDetails.ts +94 -0
  69. package/src/helpers/checkout/useOrderPayment.ts +28 -0
  70. package/src/helpers/checkout/usePaymentMethods.ts +35 -0
  71. package/src/helpers/checkout/useShippingMethods.ts +35 -0
  72. package/src/helpers/general/index.ts +2 -0
  73. package/src/helpers/index.ts +4 -0
  74. package/src/helpers/product/index.ts +2 -0
  75. package/src/{products → helpers/product}/useProductPrice.ts +1 -43
  76. package/src/helpers/user/index.ts +2 -0
  77. package/src/helpers/user/useIsLoggedIn.ts +10 -0
  78. package/src/helpers/user/useUser.ts +53 -0
  79. package/src/index.ts +4 -29
  80. package/src/inject.ts +3 -3
  81. package/src/keys.ts +57 -0
  82. package/src/query/address/index.ts +3 -0
  83. package/src/query/address/useCreateCustomerAddressMutation.ts +32 -0
  84. package/src/query/address/useDeleteCustomerAddressMutation.ts +32 -0
  85. package/src/query/address/useListAddressQuery.ts +29 -0
  86. package/src/query/cart/index.ts +4 -0
  87. package/src/query/cart/useAddLineItemMutation.ts +45 -0
  88. package/src/query/cart/useReadCartQuery.ts +28 -0
  89. package/src/query/cart/useRemoveLineItemMutation.ts +32 -0
  90. package/src/query/cart/useUpdateLineItemMutation.ts +45 -0
  91. package/src/query/checkout/index.ts +2 -0
  92. package/src/query/checkout/useCheckout.ts +2 -0
  93. package/src/query/checkout/useCreateOrderMutation.ts +35 -0
  94. package/src/query/context/index.ts +2 -0
  95. package/src/query/context/useReadContextQuery.ts +19 -0
  96. package/src/query/context/useUpdateContextMutation.ts +36 -0
  97. package/src/query/customer/index.ts +6 -0
  98. package/src/query/customer/useChangeEmailMutation.ts +32 -0
  99. package/src/query/customer/useChangeProfileMutation.ts +32 -0
  100. package/src/query/customer/useLoginCustomerMutation.ts +42 -0
  101. package/src/query/customer/useLogoutCustomerMutation.ts +32 -0
  102. package/src/query/customer/useReadCustomerQuery.ts +27 -0
  103. package/src/query/customer/useRegisterCustomerMutation.ts +32 -0
  104. package/src/query/index.ts +10 -0
  105. package/src/query/order/index.ts +1 -0
  106. package/src/query/order/useReadOrderQuery.ts +33 -0
  107. package/src/query/payment/index.ts +3 -0
  108. package/src/query/payment/useHandlePaymentMutation.ts +27 -0
  109. package/src/query/payment/useOrderSetPaymentMutation.ts +32 -0
  110. package/src/query/payment/useReadPaymentMethodQuery.ts +30 -0
  111. package/src/query/products/index.ts +3 -0
  112. package/src/query/products/useReadCategoryListQuery.ts +28 -0
  113. package/src/query/products/useReadCompactProductListingQuery.ts +41 -0
  114. package/src/query/products/useReadCustomProductDetailQuery.ts +41 -0
  115. package/src/query/shipping/index.ts +1 -0
  116. package/src/query/shipping/useReadShippingMethodQuery.ts +29 -0
  117. package/src/query/types/index.ts +2 -0
  118. package/src/query/types/operations.ts +6 -0
  119. package/src/query/types/query.ts +39 -0
  120. package/src/util/index.ts +3 -0
  121. package/src/util/unrefOptions.ts +19 -0
  122. package/src/util/useOptimistic.ts +49 -0
  123. package/tsconfig.json +5 -2
  124. package/dist/cart/useCartAddItemMutation.d.ts +0 -12
  125. package/dist/cart/useCartQueryOptions.d.ts +0 -9
  126. package/dist/cart/useCartRemoveItemMutation.d.ts +0 -7
  127. package/dist/cart/useCartUpdateItemMutation.d.ts +0 -12
  128. package/dist/context/useContextOptions.d.ts +0 -9
  129. package/dist/context/useContextUpdate.d.ts +0 -4
  130. package/dist/products/useCategoryQueryOptions.d.ts +0 -17
  131. package/dist/products/useProductListingQueryOptions.d.ts +0 -19
  132. package/dist/products/useProductListingQueryOptions.test.d.ts +0 -1
  133. package/dist/products/useProductPrice.d.ts +0 -49
  134. package/dist/products/useProductQueryOptions.d.ts +0 -19
  135. package/dist/types/query.d.ts +0 -7
  136. package/src/cart/useCartAddItemMutation.ts +0 -48
  137. package/src/cart/useCartQueryOptions.ts +0 -19
  138. package/src/cart/useCartRemoveItemMutation.ts +0 -32
  139. package/src/cart/useCartUpdateItemMutation.ts +0 -48
  140. package/src/context/useContextOptions.ts +0 -16
  141. package/src/context/useContextUpdate.ts +0 -16
  142. package/src/products/useCategoryQueryOptions.ts +0 -25
  143. package/src/products/useProductListingQueryOptions.test.ts +0 -24
  144. package/src/products/useProductListingQueryOptions.ts +0 -29
  145. package/src/products/useProductQueryOptions.ts +0 -29
  146. package/src/types/query.ts +0 -18
  147. /package/src/{usePagination.ts → helpers/general/usePagination.ts} +0 -0
  148. /package/src/{general → helpers/general}/useSeoUrl.ts +0 -0
  149. /package/src/{products → helpers/product}/useProductVariantForOptions.ts +0 -0
@@ -0,0 +1,131 @@
1
+ import { UseMutationOptions, UseMutationReturnType, MutationObserverIdleResult, MutationObserverLoadingResult, MutationObserverErrorResult, MutationObserverSuccessResult } from '@tanstack/vue-query';
2
+ import { OperationBody, OperationResponse } from '../types/query';
3
+ import { components } from '../../../api-types/storeApiTypes';
4
+ declare const updateCartItemOperation = "updateLineItem patch /checkout/cart/line-item";
5
+ type LineItem = OperationBody<typeof updateCartItemOperation>['items'][number];
6
+ type LineItemPayload = Partial<Omit<LineItem, 'id' | 'quantity' | 'type'>> & Required<Pick<LineItem, 'id' | 'quantity' | 'type'>>;
7
+ type Body = Omit<OperationBody<typeof updateCartItemOperation>, 'items'> & {
8
+ items: LineItemPayload[];
9
+ };
10
+ export declare function useUpdateLineItemMutation(mutationOptions?: UseMutationOptions<OperationResponse<typeof updateCartItemOperation>, unknown, Body>): UseMutationReturnType<{
11
+ affiliateCode?: string | null;
12
+ apiAlias: "cart";
13
+ campaignCode?: string | null;
14
+ customerComment?: string | null;
15
+ deliveries?: components["schemas"]["CartDelivery"][];
16
+ errors?: components["schemas"]["CartError"][] | {
17
+ [key: string]: {
18
+ code: number;
19
+ key: string;
20
+ level: number;
21
+ message: string;
22
+ messageKey: string;
23
+ };
24
+ };
25
+ lineItems?: components["schemas"]["LineItem"][];
26
+ modified?: boolean;
27
+ name?: string;
28
+ price: components["schemas"]["CalculatedPrice"];
29
+ token?: string;
30
+ transactions?: {
31
+ amount?: components["schemas"]["CalculatedPrice"];
32
+ paymentMethodId?: string;
33
+ }[];
34
+ }, unknown, Body, unknown, Omit< MutationObserverIdleResult<{
35
+ affiliateCode?: string | null;
36
+ apiAlias: "cart";
37
+ campaignCode?: string | null;
38
+ customerComment?: string | null;
39
+ deliveries?: components["schemas"]["CartDelivery"][];
40
+ errors?: components["schemas"]["CartError"][] | {
41
+ [key: string]: {
42
+ code: number;
43
+ key: string;
44
+ level: number;
45
+ message: string;
46
+ messageKey: string;
47
+ };
48
+ };
49
+ lineItems?: components["schemas"]["LineItem"][];
50
+ modified?: boolean;
51
+ name?: string;
52
+ price: components["schemas"]["CalculatedPrice"];
53
+ token?: string;
54
+ transactions?: {
55
+ amount?: components["schemas"]["CalculatedPrice"];
56
+ paymentMethodId?: string;
57
+ }[];
58
+ }, unknown, Body, unknown>, "mutate" | "reset"> | Omit< MutationObserverLoadingResult<{
59
+ affiliateCode?: string | null;
60
+ apiAlias: "cart";
61
+ campaignCode?: string | null;
62
+ customerComment?: string | null;
63
+ deliveries?: components["schemas"]["CartDelivery"][];
64
+ errors?: components["schemas"]["CartError"][] | {
65
+ [key: string]: {
66
+ code: number;
67
+ key: string;
68
+ level: number;
69
+ message: string;
70
+ messageKey: string;
71
+ };
72
+ };
73
+ lineItems?: components["schemas"]["LineItem"][];
74
+ modified?: boolean;
75
+ name?: string;
76
+ price: components["schemas"]["CalculatedPrice"];
77
+ token?: string;
78
+ transactions?: {
79
+ amount?: components["schemas"]["CalculatedPrice"];
80
+ paymentMethodId?: string;
81
+ }[];
82
+ }, unknown, Body, unknown>, "mutate" | "reset"> | Omit< MutationObserverErrorResult<{
83
+ affiliateCode?: string | null;
84
+ apiAlias: "cart";
85
+ campaignCode?: string | null;
86
+ customerComment?: string | null;
87
+ deliveries?: components["schemas"]["CartDelivery"][];
88
+ errors?: components["schemas"]["CartError"][] | {
89
+ [key: string]: {
90
+ code: number;
91
+ key: string;
92
+ level: number;
93
+ message: string;
94
+ messageKey: string;
95
+ };
96
+ };
97
+ lineItems?: components["schemas"]["LineItem"][];
98
+ modified?: boolean;
99
+ name?: string;
100
+ price: components["schemas"]["CalculatedPrice"];
101
+ token?: string;
102
+ transactions?: {
103
+ amount?: components["schemas"]["CalculatedPrice"];
104
+ paymentMethodId?: string;
105
+ }[];
106
+ }, unknown, Body, unknown>, "mutate" | "reset"> | Omit< MutationObserverSuccessResult<{
107
+ affiliateCode?: string | null;
108
+ apiAlias: "cart";
109
+ campaignCode?: string | null;
110
+ customerComment?: string | null;
111
+ deliveries?: components["schemas"]["CartDelivery"][];
112
+ errors?: components["schemas"]["CartError"][] | {
113
+ [key: string]: {
114
+ code: number;
115
+ key: string;
116
+ level: number;
117
+ message: string;
118
+ messageKey: string;
119
+ };
120
+ };
121
+ lineItems?: components["schemas"]["LineItem"][];
122
+ modified?: boolean;
123
+ name?: string;
124
+ price: components["schemas"]["CalculatedPrice"];
125
+ token?: string;
126
+ transactions?: {
127
+ amount?: components["schemas"]["CalculatedPrice"];
128
+ paymentMethodId?: string;
129
+ }[];
130
+ }, unknown, Body, unknown>, "mutate" | "reset">>;
131
+ export {};
@@ -0,0 +1,2 @@
1
+ export * from './useCheckout';
2
+ export * from './useCreateOrderMutation';
@@ -0,0 +1 @@
1
+ export declare const useCheckout: () => void;
@@ -0,0 +1,281 @@
1
+ import { UseMutationOptions, UseMutationReturnType, MutationObserverIdleResult, MutationObserverLoadingResult, MutationObserverErrorResult, MutationObserverSuccessResult } from '@tanstack/vue-query';
2
+ import { OperationOptions, OperationResponse } from '../types/query';
3
+ import { components, GenericRecord } from '../../../api-types/storeApiTypes';
4
+ declare const createOrderOperation = "createOrder post /checkout/order";
5
+ export declare function useCreateOrderMutation(mutationOptions?: UseMutationOptions<OperationResponse<typeof createOrderOperation>, unknown, OperationOptions<typeof createOrderOperation>>): UseMutationReturnType<{
6
+ addresses?: components["schemas"]["OrderAddress"][];
7
+ affiliateCode?: string;
8
+ readonly amountNet?: number;
9
+ readonly amountTotal?: number;
10
+ billingAddress?: components["schemas"]["OrderAddress"];
11
+ billingAddressId: string;
12
+ billingAddressVersionId?: string;
13
+ campaignCode?: string;
14
+ readonly createdAt?: string;
15
+ createdById?: string;
16
+ currency?: components["schemas"]["Currency"];
17
+ currencyFactor: number;
18
+ currencyId: string;
19
+ customerComment?: string;
20
+ customFields?: GenericRecord;
21
+ deepLinkCode?: string;
22
+ deliveries?: components["schemas"]["OrderDelivery"][];
23
+ documents: components["schemas"]["Document"][];
24
+ id: string;
25
+ language?: components["schemas"]["Language"];
26
+ languageId: string;
27
+ lineItems?: components["schemas"]["OrderLineItem"][];
28
+ orderCustomer?: components["schemas"]["OrderCustomer"];
29
+ readonly orderDate: string;
30
+ orderDateTime: string;
31
+ orderNumber?: string;
32
+ readonly positionPrice?: number;
33
+ price: components["schemas"]["CalculatedPrice"];
34
+ salesChannelId: string;
35
+ shippingCosts?: {
36
+ calculatedTaxes?: GenericRecord;
37
+ listPrice?: {
38
+ discount?: number;
39
+ percentage?: number;
40
+ price?: number;
41
+ };
42
+ quantity: number;
43
+ referencePrice?: GenericRecord;
44
+ regulationPrice?: {
45
+ price?: number;
46
+ };
47
+ taxRules?: GenericRecord;
48
+ totalPrice: number;
49
+ unitPrice: number;
50
+ };
51
+ readonly shippingTotal?: number;
52
+ source?: string;
53
+ stateMachineState: components["schemas"]["StateMachineState"];
54
+ tags?: components["schemas"]["Tag"][];
55
+ readonly taxStatus?: string;
56
+ transactions?: components["schemas"]["OrderTransaction"][];
57
+ readonly updatedAt?: string;
58
+ updatedById?: string;
59
+ versionId?: string;
60
+ }, unknown, OperationOptions<"createOrder post /checkout/order">, unknown, Omit< MutationObserverIdleResult<{
61
+ addresses?: components["schemas"]["OrderAddress"][];
62
+ affiliateCode?: string;
63
+ readonly amountNet?: number;
64
+ readonly amountTotal?: number;
65
+ billingAddress?: components["schemas"]["OrderAddress"];
66
+ billingAddressId: string;
67
+ billingAddressVersionId?: string;
68
+ campaignCode?: string;
69
+ readonly createdAt?: string;
70
+ createdById?: string;
71
+ currency?: components["schemas"]["Currency"];
72
+ currencyFactor: number;
73
+ currencyId: string;
74
+ customerComment?: string;
75
+ customFields?: GenericRecord;
76
+ deepLinkCode?: string;
77
+ deliveries?: components["schemas"]["OrderDelivery"][];
78
+ documents: components["schemas"]["Document"][];
79
+ id: string;
80
+ language?: components["schemas"]["Language"];
81
+ languageId: string;
82
+ lineItems?: components["schemas"]["OrderLineItem"][];
83
+ orderCustomer?: components["schemas"]["OrderCustomer"];
84
+ readonly orderDate: string;
85
+ orderDateTime: string;
86
+ orderNumber?: string;
87
+ readonly positionPrice?: number;
88
+ price: components["schemas"]["CalculatedPrice"];
89
+ salesChannelId: string;
90
+ shippingCosts?: {
91
+ calculatedTaxes?: GenericRecord;
92
+ listPrice?: {
93
+ discount?: number;
94
+ percentage?: number;
95
+ price?: number;
96
+ };
97
+ quantity: number;
98
+ referencePrice?: GenericRecord;
99
+ regulationPrice?: {
100
+ price?: number;
101
+ };
102
+ taxRules?: GenericRecord;
103
+ totalPrice: number;
104
+ unitPrice: number;
105
+ };
106
+ readonly shippingTotal?: number;
107
+ source?: string;
108
+ stateMachineState: components["schemas"]["StateMachineState"];
109
+ tags?: components["schemas"]["Tag"][];
110
+ readonly taxStatus?: string;
111
+ transactions?: components["schemas"]["OrderTransaction"][];
112
+ readonly updatedAt?: string;
113
+ updatedById?: string;
114
+ versionId?: string;
115
+ }, unknown, OperationOptions<"createOrder post /checkout/order">, unknown>, "mutate" | "reset"> | Omit< MutationObserverLoadingResult<{
116
+ addresses?: components["schemas"]["OrderAddress"][];
117
+ affiliateCode?: string;
118
+ readonly amountNet?: number;
119
+ readonly amountTotal?: number;
120
+ billingAddress?: components["schemas"]["OrderAddress"];
121
+ billingAddressId: string;
122
+ billingAddressVersionId?: string;
123
+ campaignCode?: string;
124
+ readonly createdAt?: string;
125
+ createdById?: string;
126
+ currency?: components["schemas"]["Currency"];
127
+ currencyFactor: number;
128
+ currencyId: string;
129
+ customerComment?: string;
130
+ customFields?: GenericRecord;
131
+ deepLinkCode?: string;
132
+ deliveries?: components["schemas"]["OrderDelivery"][];
133
+ documents: components["schemas"]["Document"][];
134
+ id: string;
135
+ language?: components["schemas"]["Language"];
136
+ languageId: string;
137
+ lineItems?: components["schemas"]["OrderLineItem"][];
138
+ orderCustomer?: components["schemas"]["OrderCustomer"];
139
+ readonly orderDate: string;
140
+ orderDateTime: string;
141
+ orderNumber?: string;
142
+ readonly positionPrice?: number;
143
+ price: components["schemas"]["CalculatedPrice"];
144
+ salesChannelId: string;
145
+ shippingCosts?: {
146
+ calculatedTaxes?: GenericRecord;
147
+ listPrice?: {
148
+ discount?: number;
149
+ percentage?: number;
150
+ price?: number;
151
+ };
152
+ quantity: number;
153
+ referencePrice?: GenericRecord;
154
+ regulationPrice?: {
155
+ price?: number;
156
+ };
157
+ taxRules?: GenericRecord;
158
+ totalPrice: number;
159
+ unitPrice: number;
160
+ };
161
+ readonly shippingTotal?: number;
162
+ source?: string;
163
+ stateMachineState: components["schemas"]["StateMachineState"];
164
+ tags?: components["schemas"]["Tag"][];
165
+ readonly taxStatus?: string;
166
+ transactions?: components["schemas"]["OrderTransaction"][];
167
+ readonly updatedAt?: string;
168
+ updatedById?: string;
169
+ versionId?: string;
170
+ }, unknown, OperationOptions<"createOrder post /checkout/order">, unknown>, "mutate" | "reset"> | Omit< MutationObserverErrorResult<{
171
+ addresses?: components["schemas"]["OrderAddress"][];
172
+ affiliateCode?: string;
173
+ readonly amountNet?: number;
174
+ readonly amountTotal?: number;
175
+ billingAddress?: components["schemas"]["OrderAddress"];
176
+ billingAddressId: string;
177
+ billingAddressVersionId?: string;
178
+ campaignCode?: string;
179
+ readonly createdAt?: string;
180
+ createdById?: string;
181
+ currency?: components["schemas"]["Currency"];
182
+ currencyFactor: number;
183
+ currencyId: string;
184
+ customerComment?: string;
185
+ customFields?: GenericRecord;
186
+ deepLinkCode?: string;
187
+ deliveries?: components["schemas"]["OrderDelivery"][];
188
+ documents: components["schemas"]["Document"][];
189
+ id: string;
190
+ language?: components["schemas"]["Language"];
191
+ languageId: string;
192
+ lineItems?: components["schemas"]["OrderLineItem"][];
193
+ orderCustomer?: components["schemas"]["OrderCustomer"];
194
+ readonly orderDate: string;
195
+ orderDateTime: string;
196
+ orderNumber?: string;
197
+ readonly positionPrice?: number;
198
+ price: components["schemas"]["CalculatedPrice"];
199
+ salesChannelId: string;
200
+ shippingCosts?: {
201
+ calculatedTaxes?: GenericRecord;
202
+ listPrice?: {
203
+ discount?: number;
204
+ percentage?: number;
205
+ price?: number;
206
+ };
207
+ quantity: number;
208
+ referencePrice?: GenericRecord;
209
+ regulationPrice?: {
210
+ price?: number;
211
+ };
212
+ taxRules?: GenericRecord;
213
+ totalPrice: number;
214
+ unitPrice: number;
215
+ };
216
+ readonly shippingTotal?: number;
217
+ source?: string;
218
+ stateMachineState: components["schemas"]["StateMachineState"];
219
+ tags?: components["schemas"]["Tag"][];
220
+ readonly taxStatus?: string;
221
+ transactions?: components["schemas"]["OrderTransaction"][];
222
+ readonly updatedAt?: string;
223
+ updatedById?: string;
224
+ versionId?: string;
225
+ }, unknown, OperationOptions<"createOrder post /checkout/order">, unknown>, "mutate" | "reset"> | Omit< MutationObserverSuccessResult<{
226
+ addresses?: components["schemas"]["OrderAddress"][];
227
+ affiliateCode?: string;
228
+ readonly amountNet?: number;
229
+ readonly amountTotal?: number;
230
+ billingAddress?: components["schemas"]["OrderAddress"];
231
+ billingAddressId: string;
232
+ billingAddressVersionId?: string;
233
+ campaignCode?: string;
234
+ readonly createdAt?: string;
235
+ createdById?: string;
236
+ currency?: components["schemas"]["Currency"];
237
+ currencyFactor: number;
238
+ currencyId: string;
239
+ customerComment?: string;
240
+ customFields?: GenericRecord;
241
+ deepLinkCode?: string;
242
+ deliveries?: components["schemas"]["OrderDelivery"][];
243
+ documents: components["schemas"]["Document"][];
244
+ id: string;
245
+ language?: components["schemas"]["Language"];
246
+ languageId: string;
247
+ lineItems?: components["schemas"]["OrderLineItem"][];
248
+ orderCustomer?: components["schemas"]["OrderCustomer"];
249
+ readonly orderDate: string;
250
+ orderDateTime: string;
251
+ orderNumber?: string;
252
+ readonly positionPrice?: number;
253
+ price: components["schemas"]["CalculatedPrice"];
254
+ salesChannelId: string;
255
+ shippingCosts?: {
256
+ calculatedTaxes?: GenericRecord;
257
+ listPrice?: {
258
+ discount?: number;
259
+ percentage?: number;
260
+ price?: number;
261
+ };
262
+ quantity: number;
263
+ referencePrice?: GenericRecord;
264
+ regulationPrice?: {
265
+ price?: number;
266
+ };
267
+ taxRules?: GenericRecord;
268
+ totalPrice: number;
269
+ unitPrice: number;
270
+ };
271
+ readonly shippingTotal?: number;
272
+ source?: string;
273
+ stateMachineState: components["schemas"]["StateMachineState"];
274
+ tags?: components["schemas"]["Tag"][];
275
+ readonly taxStatus?: string;
276
+ transactions?: components["schemas"]["OrderTransaction"][];
277
+ readonly updatedAt?: string;
278
+ updatedById?: string;
279
+ versionId?: string;
280
+ }, unknown, OperationOptions<"createOrder post /checkout/order">, unknown>, "mutate" | "reset">>;
281
+ export {};
@@ -0,0 +1,2 @@
1
+ export * from './useReadContextQuery';
2
+ export * from './useUpdateContextMutation';
@@ -0,0 +1,153 @@
1
+ import { UndefinedInitialQueryOptions, UseQueryReturnType } from '@tanstack/vue-query';
2
+ import { components } from '../../../api-types/storeApiTypes';
3
+ export declare function useReadContext(): UndefinedInitialQueryOptions<{
4
+ apiAlias: "sales_channel_context";
5
+ context?: {
6
+ currencyFactor?: number;
7
+ currencyId?: string;
8
+ currencyPrecision?: number;
9
+ languageIdChain?: string[];
10
+ scope?: string;
11
+ source?: string;
12
+ taxState?: string;
13
+ useCache?: boolean;
14
+ versionId?: string;
15
+ };
16
+ currency?: components["schemas"]["Currency"];
17
+ currentCustomerGroup?: {
18
+ displayGross?: boolean;
19
+ name?: string;
20
+ };
21
+ customer?: components["schemas"]["Customer"];
22
+ fallbackCustomerGroup?: {
23
+ displayGross?: boolean;
24
+ name?: string;
25
+ };
26
+ paymentMethod?: components["schemas"]["PaymentMethod"];
27
+ salesChannel: components["schemas"]["SalesChannel"];
28
+ shippingLocation?: {
29
+ address?: components["schemas"]["CustomerAddress"];
30
+ apiAlias?: "cart_delivery_shipping_location";
31
+ country?: components["schemas"]["Country"];
32
+ };
33
+ shippingMethod?: components["schemas"]["ShippingMethod"];
34
+ taxRules?: {
35
+ name?: string;
36
+ taxRate?: number;
37
+ }[];
38
+ token?: string;
39
+ }, Error, {
40
+ apiAlias: "sales_channel_context";
41
+ context?: {
42
+ currencyFactor?: number;
43
+ currencyId?: string;
44
+ currencyPrecision?: number;
45
+ languageIdChain?: string[];
46
+ scope?: string;
47
+ source?: string;
48
+ taxState?: string;
49
+ useCache?: boolean;
50
+ versionId?: string;
51
+ };
52
+ currency?: components["schemas"]["Currency"];
53
+ currentCustomerGroup?: {
54
+ displayGross?: boolean;
55
+ name?: string;
56
+ };
57
+ customer?: components["schemas"]["Customer"];
58
+ fallbackCustomerGroup?: {
59
+ displayGross?: boolean;
60
+ name?: string;
61
+ };
62
+ paymentMethod?: components["schemas"]["PaymentMethod"];
63
+ salesChannel: components["schemas"]["SalesChannel"];
64
+ shippingLocation?: {
65
+ address?: components["schemas"]["CustomerAddress"];
66
+ apiAlias?: "cart_delivery_shipping_location";
67
+ country?: components["schemas"]["Country"];
68
+ };
69
+ shippingMethod?: components["schemas"]["ShippingMethod"];
70
+ taxRules?: {
71
+ name?: string;
72
+ taxRate?: number;
73
+ }[];
74
+ token?: string;
75
+ }, readonly ["context"]> & {
76
+ queryKey: readonly ["context"] & {
77
+ [dataTagSymbol]: {
78
+ apiAlias: "sales_channel_context";
79
+ context?: {
80
+ currencyFactor?: number;
81
+ currencyId?: string;
82
+ currencyPrecision?: number;
83
+ languageIdChain?: string[];
84
+ scope?: string;
85
+ source?: string;
86
+ taxState?: string;
87
+ useCache?: boolean;
88
+ versionId?: string;
89
+ };
90
+ currency?: components["schemas"]["Currency"];
91
+ currentCustomerGroup?: {
92
+ displayGross?: boolean;
93
+ name?: string;
94
+ };
95
+ customer?: components["schemas"]["Customer"];
96
+ fallbackCustomerGroup?: {
97
+ displayGross?: boolean;
98
+ name?: string;
99
+ };
100
+ paymentMethod?: components["schemas"]["PaymentMethod"];
101
+ salesChannel: components["schemas"]["SalesChannel"];
102
+ shippingLocation?: {
103
+ address?: components["schemas"]["CustomerAddress"];
104
+ apiAlias?: "cart_delivery_shipping_location";
105
+ country?: components["schemas"]["Country"];
106
+ };
107
+ shippingMethod?: components["schemas"]["ShippingMethod"];
108
+ taxRules?: {
109
+ name?: string;
110
+ taxRate?: number;
111
+ }[];
112
+ token?: string;
113
+ };
114
+ [dataTagErrorSymbol]: Error;
115
+ };
116
+ };
117
+ export declare function useReadContextQuery(): UseQueryReturnType<{
118
+ apiAlias: "sales_channel_context";
119
+ context?: {
120
+ currencyFactor?: number;
121
+ currencyId?: string;
122
+ currencyPrecision?: number;
123
+ languageIdChain?: string[];
124
+ scope?: string;
125
+ source?: string;
126
+ taxState?: string;
127
+ useCache?: boolean;
128
+ versionId?: string;
129
+ };
130
+ currency?: components["schemas"]["Currency"];
131
+ currentCustomerGroup?: {
132
+ displayGross?: boolean;
133
+ name?: string;
134
+ };
135
+ customer?: components["schemas"]["Customer"];
136
+ fallbackCustomerGroup?: {
137
+ displayGross?: boolean;
138
+ name?: string;
139
+ };
140
+ paymentMethod?: components["schemas"]["PaymentMethod"];
141
+ salesChannel: components["schemas"]["SalesChannel"];
142
+ shippingLocation?: {
143
+ address?: components["schemas"]["CustomerAddress"];
144
+ apiAlias?: "cart_delivery_shipping_location";
145
+ country?: components["schemas"]["Country"];
146
+ };
147
+ shippingMethod?: components["schemas"]["ShippingMethod"];
148
+ taxRules?: {
149
+ name?: string;
150
+ taxRate?: number;
151
+ }[];
152
+ token?: string;
153
+ }, Error>;
@@ -0,0 +1,60 @@
1
+ import { UseMutationOptions, UseMutationReturnType, MutationObserverIdleResult, MutationObserverLoadingResult, MutationObserverErrorResult, MutationObserverSuccessResult } from '@tanstack/vue-query';
2
+ import { OperationBody, OperationResponse } from '../types/query';
3
+ declare const updateContextOperation = "updateContext patch /context";
4
+ export declare function useUpdateContextMutation(mutationOptions?: UseMutationOptions<OperationResponse<typeof updateContextOperation>, unknown, OperationBody<typeof updateContextOperation>>): UseMutationReturnType<{
5
+ redirectUrl?: string;
6
+ }, unknown, {
7
+ billingAddressId?: string;
8
+ countryId?: string;
9
+ countryStateId?: string;
10
+ currencyId?: string;
11
+ languageId?: string;
12
+ paymentMethodId?: string;
13
+ shippingAddressId?: string;
14
+ shippingMethodId?: string;
15
+ }, unknown, Omit< MutationObserverIdleResult<{
16
+ redirectUrl?: string;
17
+ }, unknown, {
18
+ billingAddressId?: string;
19
+ countryId?: string;
20
+ countryStateId?: string;
21
+ currencyId?: string;
22
+ languageId?: string;
23
+ paymentMethodId?: string;
24
+ shippingAddressId?: string;
25
+ shippingMethodId?: string;
26
+ }, unknown>, "mutate" | "reset"> | Omit< MutationObserverLoadingResult<{
27
+ redirectUrl?: string;
28
+ }, unknown, {
29
+ billingAddressId?: string;
30
+ countryId?: string;
31
+ countryStateId?: string;
32
+ currencyId?: string;
33
+ languageId?: string;
34
+ paymentMethodId?: string;
35
+ shippingAddressId?: string;
36
+ shippingMethodId?: string;
37
+ }, unknown>, "mutate" | "reset"> | Omit< MutationObserverErrorResult<{
38
+ redirectUrl?: string;
39
+ }, unknown, {
40
+ billingAddressId?: string;
41
+ countryId?: string;
42
+ countryStateId?: string;
43
+ currencyId?: string;
44
+ languageId?: string;
45
+ paymentMethodId?: string;
46
+ shippingAddressId?: string;
47
+ shippingMethodId?: string;
48
+ }, unknown>, "mutate" | "reset"> | Omit< MutationObserverSuccessResult<{
49
+ redirectUrl?: string;
50
+ }, unknown, {
51
+ billingAddressId?: string;
52
+ countryId?: string;
53
+ countryStateId?: string;
54
+ currencyId?: string;
55
+ languageId?: string;
56
+ paymentMethodId?: string;
57
+ shippingAddressId?: string;
58
+ shippingMethodId?: string;
59
+ }, unknown>, "mutate" | "reset">>;
60
+ export {};
@@ -0,0 +1,6 @@
1
+ export * from './useChangeEmailMutation';
2
+ export * from './useChangeProfileMutation';
3
+ export * from './useLoginCustomerMutation';
4
+ export * from './useLogoutCustomerMutation';
5
+ export * from './useReadCustomerQuery';
6
+ export * from './useRegisterCustomerMutation';
@@ -0,0 +1,15 @@
1
+ import { UseMutationOptions, UseMutationReturnType, MutationObserverIdleResult, MutationObserverLoadingResult, MutationObserverErrorResult, MutationObserverSuccessResult } from '@tanstack/vue-query';
2
+ import { OperationOptions, OperationResponse } from '../types/query';
3
+ declare const changeEmailOperation = "changeEmail post /account/change-email";
4
+ export declare function useChangeEmailMutation(mutationOptions?: UseMutationOptions<OperationResponse<typeof changeEmailOperation>, unknown, OperationOptions<typeof changeEmailOperation>>): UseMutationReturnType<{
5
+ success?: boolean;
6
+ }, unknown, OperationOptions<"changeEmail post /account/change-email">, unknown, Omit< MutationObserverIdleResult<{
7
+ success?: boolean;
8
+ }, unknown, OperationOptions<"changeEmail post /account/change-email">, unknown>, "mutate" | "reset"> | Omit< MutationObserverLoadingResult<{
9
+ success?: boolean;
10
+ }, unknown, OperationOptions<"changeEmail post /account/change-email">, unknown>, "mutate" | "reset"> | Omit< MutationObserverErrorResult<{
11
+ success?: boolean;
12
+ }, unknown, OperationOptions<"changeEmail post /account/change-email">, unknown>, "mutate" | "reset"> | Omit< MutationObserverSuccessResult<{
13
+ success?: boolean;
14
+ }, unknown, OperationOptions<"changeEmail post /account/change-email">, unknown>, "mutate" | "reset">>;
15
+ export {};
@@ -0,0 +1,15 @@
1
+ import { UseMutationOptions, UseMutationReturnType, MutationObserverIdleResult, MutationObserverLoadingResult, MutationObserverErrorResult, MutationObserverSuccessResult } from '@tanstack/vue-query';
2
+ import { OperationOptions, OperationResponse } from '../types/query';
3
+ declare const changeProfileOperation = "changeProfile post /account/change-profile";
4
+ export declare function useChangeProfileMutation(mutationOptions?: UseMutationOptions<OperationResponse<typeof changeProfileOperation>, unknown, OperationOptions<typeof changeProfileOperation>>): UseMutationReturnType<{
5
+ success?: boolean;
6
+ }, unknown, OperationOptions<"changeProfile post /account/change-profile">, unknown, Omit< MutationObserverIdleResult<{
7
+ success?: boolean;
8
+ }, unknown, OperationOptions<"changeProfile post /account/change-profile">, unknown>, "mutate" | "reset"> | Omit< MutationObserverLoadingResult<{
9
+ success?: boolean;
10
+ }, unknown, OperationOptions<"changeProfile post /account/change-profile">, unknown>, "mutate" | "reset"> | Omit< MutationObserverErrorResult<{
11
+ success?: boolean;
12
+ }, unknown, OperationOptions<"changeProfile post /account/change-profile">, unknown>, "mutate" | "reset"> | Omit< MutationObserverSuccessResult<{
13
+ success?: boolean;
14
+ }, unknown, OperationOptions<"changeProfile post /account/change-profile">, unknown>, "mutate" | "reset">>;
15
+ export {};