ce-storefront 0.5.0 → 0.5.2

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 (144) hide show
  1. package/README.md +12 -11
  2. package/docs/sdks/carts/README.md +480 -5
  3. package/docs/sdks/customers/README.md +4 -0
  4. package/esm/funcs/cartsApplyCoupon.d.ts +16 -0
  5. package/esm/funcs/cartsApplyCoupon.d.ts.map +1 -0
  6. package/esm/funcs/{checkoutApplyCoupon.js → cartsApplyCoupon.js} +12 -6
  7. package/esm/funcs/cartsApplyCoupon.js.map +1 -0
  8. package/esm/funcs/{checkoutCreateCheckoutAddress.d.ts → cartsCreateCartAddress.d.ts} +2 -2
  9. package/esm/funcs/cartsCreateCartAddress.d.ts.map +1 -0
  10. package/esm/funcs/{checkoutCreateCheckoutAddress.js → cartsCreateCartAddress.js} +16 -12
  11. package/esm/funcs/cartsCreateCartAddress.js.map +1 -0
  12. package/esm/funcs/cartsDeleteCart.js +2 -2
  13. package/esm/funcs/cartsDeleteCart.js.map +1 -1
  14. package/esm/funcs/cartsGetCart.d.ts +1 -1
  15. package/esm/funcs/cartsGetCart.js +3 -3
  16. package/esm/funcs/cartsGetCart.js.map +1 -1
  17. package/esm/funcs/cartsGetUserCart.d.ts +16 -0
  18. package/esm/funcs/cartsGetUserCart.d.ts.map +1 -0
  19. package/esm/funcs/cartsGetUserCart.js +85 -0
  20. package/esm/funcs/cartsGetUserCart.js.map +1 -0
  21. package/esm/funcs/{checkoutRemoveCoupon.d.ts → cartsRemoveCoupon.d.ts} +2 -2
  22. package/esm/funcs/cartsRemoveCoupon.d.ts.map +1 -0
  23. package/esm/funcs/{checkoutRemoveCoupon.js → cartsRemoveCoupon.js} +12 -7
  24. package/esm/funcs/{checkoutRemoveCoupon.js.map → cartsRemoveCoupon.js.map} +1 -1
  25. package/esm/funcs/{checkoutApplyCoupon.d.ts → cartsRemoveUserCart.d.ts} +4 -4
  26. package/esm/funcs/{checkoutApplyCoupon.d.ts.map → cartsRemoveUserCart.d.ts.map} +1 -1
  27. package/esm/funcs/cartsRemoveUserCart.js +85 -0
  28. package/esm/funcs/cartsRemoveUserCart.js.map +1 -0
  29. package/esm/lib/config.d.ts +3 -3
  30. package/esm/lib/config.js +3 -3
  31. package/esm/models/components/cart.d.ts +4 -4
  32. package/esm/models/components/cart.d.ts.map +1 -1
  33. package/esm/models/components/cart.js +4 -4
  34. package/esm/models/components/cart.js.map +1 -1
  35. package/esm/models/components/cartitem.d.ts +0 -5
  36. package/esm/models/components/cartitem.d.ts.map +1 -1
  37. package/esm/models/components/cartitem.js +0 -2
  38. package/esm/models/components/cartitem.js.map +1 -1
  39. package/esm/models/components/customeraddress.d.ts +7 -4
  40. package/esm/models/components/customeraddress.d.ts.map +1 -1
  41. package/esm/models/components/customeraddress.js +4 -4
  42. package/esm/models/components/customeraddress.js.map +1 -1
  43. package/esm/models/components/customeraddressinput.d.ts +7 -2
  44. package/esm/models/components/customeraddressinput.d.ts.map +1 -1
  45. package/esm/models/components/customeraddressinput.js +4 -2
  46. package/esm/models/components/customeraddressinput.js.map +1 -1
  47. package/esm/models/operations/applycoupon.d.ts +30 -2
  48. package/esm/models/operations/applycoupon.d.ts.map +1 -1
  49. package/esm/models/operations/applycoupon.js +35 -4
  50. package/esm/models/operations/applycoupon.js.map +1 -1
  51. package/esm/models/operations/createaddress.d.ts +7 -2
  52. package/esm/models/operations/createaddress.d.ts.map +1 -1
  53. package/esm/models/operations/createaddress.js +4 -2
  54. package/esm/models/operations/createaddress.js.map +1 -1
  55. package/esm/models/operations/createcartaddress.d.ts +183 -0
  56. package/esm/models/operations/createcartaddress.d.ts.map +1 -0
  57. package/esm/models/operations/createcartaddress.js +214 -0
  58. package/esm/models/operations/createcartaddress.js.map +1 -0
  59. package/esm/models/operations/deletecart.d.ts +3 -3
  60. package/esm/models/operations/deletecart.d.ts.map +1 -1
  61. package/esm/models/operations/deletecart.js +2 -11
  62. package/esm/models/operations/deletecart.js.map +1 -1
  63. package/esm/models/operations/deleteusercart.d.ts +63 -0
  64. package/esm/models/operations/deleteusercart.d.ts.map +1 -0
  65. package/esm/models/operations/deleteusercart.js +77 -0
  66. package/esm/models/operations/deleteusercart.js.map +1 -0
  67. package/esm/models/operations/getaddressdetail.d.ts +7 -4
  68. package/esm/models/operations/getaddressdetail.d.ts.map +1 -1
  69. package/esm/models/operations/getaddressdetail.js +4 -4
  70. package/esm/models/operations/getaddressdetail.js.map +1 -1
  71. package/esm/models/operations/getcart.d.ts +3 -3
  72. package/esm/models/operations/getcart.d.ts.map +1 -1
  73. package/esm/models/operations/getcart.js +2 -11
  74. package/esm/models/operations/getcart.js.map +1 -1
  75. package/esm/models/operations/getusercart.d.ts +94 -0
  76. package/esm/models/operations/getusercart.d.ts.map +1 -0
  77. package/esm/models/operations/getusercart.js +105 -0
  78. package/esm/models/operations/getusercart.js.map +1 -0
  79. package/esm/models/operations/index.d.ts +3 -1
  80. package/esm/models/operations/index.d.ts.map +1 -1
  81. package/esm/models/operations/index.js +3 -1
  82. package/esm/models/operations/index.js.map +1 -1
  83. package/esm/models/operations/listaddresses.d.ts +7 -4
  84. package/esm/models/operations/listaddresses.d.ts.map +1 -1
  85. package/esm/models/operations/listaddresses.js +4 -4
  86. package/esm/models/operations/listaddresses.js.map +1 -1
  87. package/esm/models/operations/removecoupon.d.ts +18 -17
  88. package/esm/models/operations/removecoupon.d.ts.map +1 -1
  89. package/esm/models/operations/removecoupon.js +15 -28
  90. package/esm/models/operations/removecoupon.js.map +1 -1
  91. package/esm/models/operations/updateaddressdetail.d.ts +7 -2
  92. package/esm/models/operations/updateaddressdetail.d.ts.map +1 -1
  93. package/esm/models/operations/updateaddressdetail.js +4 -2
  94. package/esm/models/operations/updateaddressdetail.js.map +1 -1
  95. package/esm/sdk/carts.d.ts +36 -1
  96. package/esm/sdk/carts.d.ts.map +1 -1
  97. package/esm/sdk/carts.js +51 -1
  98. package/esm/sdk/carts.js.map +1 -1
  99. package/esm/sdk/sdk.d.ts +0 -3
  100. package/esm/sdk/sdk.d.ts.map +1 -1
  101. package/esm/sdk/sdk.js +0 -4
  102. package/esm/sdk/sdk.js.map +1 -1
  103. package/jsr.json +1 -1
  104. package/package.json +1 -1
  105. package/src/funcs/{checkoutApplyCoupon.ts → cartsApplyCoupon.ts} +13 -6
  106. package/src/funcs/{checkoutCreateCheckoutAddress.ts → cartsCreateCartAddress.ts} +19 -15
  107. package/src/funcs/cartsDeleteCart.ts +2 -2
  108. package/src/funcs/cartsGetCart.ts +3 -3
  109. package/src/funcs/cartsGetUserCart.ts +149 -0
  110. package/src/funcs/{checkoutRemoveCoupon.ts → cartsRemoveCoupon.ts} +13 -7
  111. package/src/funcs/cartsRemoveUserCart.ts +149 -0
  112. package/src/lib/config.ts +3 -3
  113. package/src/models/components/cart.ts +9 -9
  114. package/src/models/components/cartitem.ts +0 -7
  115. package/src/models/components/customeraddress.ts +11 -8
  116. package/src/models/components/customeraddressinput.ts +11 -4
  117. package/src/models/operations/applycoupon.ts +73 -6
  118. package/src/models/operations/createaddress.ts +11 -4
  119. package/src/models/operations/{createcheckoutaddress.ts → createcartaddress.ts} +152 -85
  120. package/src/models/operations/deletecart.ts +5 -14
  121. package/src/models/operations/deleteusercart.ts +154 -0
  122. package/src/models/operations/getaddressdetail.ts +11 -8
  123. package/src/models/operations/getcart.ts +5 -14
  124. package/src/models/operations/getusercart.ts +220 -0
  125. package/src/models/operations/index.ts +3 -1
  126. package/src/models/operations/listaddresses.ts +11 -8
  127. package/src/models/operations/removecoupon.ts +28 -40
  128. package/src/models/operations/updateaddressdetail.ts +11 -4
  129. package/src/sdk/carts.ts +91 -1
  130. package/src/sdk/sdk.ts +0 -6
  131. package/docs/sdks/checkout/README.md +0 -310
  132. package/esm/funcs/checkoutApplyCoupon.js.map +0 -1
  133. package/esm/funcs/checkoutCreateCheckoutAddress.d.ts.map +0 -1
  134. package/esm/funcs/checkoutCreateCheckoutAddress.js.map +0 -1
  135. package/esm/funcs/checkoutRemoveCoupon.d.ts.map +0 -1
  136. package/esm/models/operations/createcheckoutaddress.d.ts +0 -154
  137. package/esm/models/operations/createcheckoutaddress.d.ts.map +0 -1
  138. package/esm/models/operations/createcheckoutaddress.js +0 -181
  139. package/esm/models/operations/createcheckoutaddress.js.map +0 -1
  140. package/esm/sdk/checkout.d.ts +0 -26
  141. package/esm/sdk/checkout.d.ts.map +0 -1
  142. package/esm/sdk/checkout.js +0 -38
  143. package/esm/sdk/checkout.js.map +0 -1
  144. package/src/sdk/checkout.ts +0 -63
@@ -0,0 +1,183 @@
1
+ import * as z from "zod";
2
+ import { Result as SafeParseResult } from "../../types/fp.js";
3
+ import * as components from "../components/index.js";
4
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
5
+ export declare const CreateCartAddressServerList: readonly ["https://staging.api.commercengine.io/api/v1/{store_id}/storefront", "https://prod.api.commercengine.io/api/v1/{store_id}/storefront"];
6
+ /**
7
+ * For guest checkout where address is not saved
8
+ */
9
+ export type GuestUser = {
10
+ billingAddress: components.CustomerAddressInput | null;
11
+ shippingAddress: components.CustomerAddressInput | null;
12
+ };
13
+ /**
14
+ * For registered users where address is previously added
15
+ */
16
+ export type RegisteredUser = {
17
+ billingAddressId: string;
18
+ shippingAddressId: string;
19
+ };
20
+ /**
21
+ * Update billing and shipping address during checkout
22
+ */
23
+ export type CreateCartAddressRequestBody = RegisteredUser | GuestUser;
24
+ export type CreateCartAddressRequest = {
25
+ /**
26
+ * Cart ID
27
+ */
28
+ id: string;
29
+ /**
30
+ * Update billing and shipping address during checkout
31
+ */
32
+ requestBody: RegisteredUser | GuestUser;
33
+ };
34
+ export type CreateCartAddressContent = {
35
+ /**
36
+ * This cart model is structured to capture a wide range of details, facilitating accurate representation and management of user shopping carts in an e-commerce platform.
37
+ */
38
+ cart: components.Cart;
39
+ };
40
+ /**
41
+ * OK
42
+ */
43
+ export type CreateCartAddressResponseBody = {
44
+ message: string;
45
+ success: boolean;
46
+ content: CreateCartAddressContent;
47
+ };
48
+ /** @internal */
49
+ export declare const GuestUser$inboundSchema: z.ZodType<GuestUser, z.ZodTypeDef, unknown>;
50
+ /** @internal */
51
+ export type GuestUser$Outbound = {
52
+ billing_address: components.CustomerAddressInput$Outbound | null;
53
+ shipping_address: components.CustomerAddressInput$Outbound | null;
54
+ };
55
+ /** @internal */
56
+ export declare const GuestUser$outboundSchema: z.ZodType<GuestUser$Outbound, z.ZodTypeDef, GuestUser>;
57
+ /**
58
+ * @internal
59
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
60
+ */
61
+ export declare namespace GuestUser$ {
62
+ /** @deprecated use `GuestUser$inboundSchema` instead. */
63
+ const inboundSchema: z.ZodType<GuestUser, z.ZodTypeDef, unknown>;
64
+ /** @deprecated use `GuestUser$outboundSchema` instead. */
65
+ const outboundSchema: z.ZodType<GuestUser$Outbound, z.ZodTypeDef, GuestUser>;
66
+ /** @deprecated use `GuestUser$Outbound` instead. */
67
+ type Outbound = GuestUser$Outbound;
68
+ }
69
+ export declare function guestUserToJSON(guestUser: GuestUser): string;
70
+ export declare function guestUserFromJSON(jsonString: string): SafeParseResult<GuestUser, SDKValidationError>;
71
+ /** @internal */
72
+ export declare const RegisteredUser$inboundSchema: z.ZodType<RegisteredUser, z.ZodTypeDef, unknown>;
73
+ /** @internal */
74
+ export type RegisteredUser$Outbound = {
75
+ billing_address_id: string;
76
+ shipping_address_id: string;
77
+ };
78
+ /** @internal */
79
+ export declare const RegisteredUser$outboundSchema: z.ZodType<RegisteredUser$Outbound, z.ZodTypeDef, RegisteredUser>;
80
+ /**
81
+ * @internal
82
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
83
+ */
84
+ export declare namespace RegisteredUser$ {
85
+ /** @deprecated use `RegisteredUser$inboundSchema` instead. */
86
+ const inboundSchema: z.ZodType<RegisteredUser, z.ZodTypeDef, unknown>;
87
+ /** @deprecated use `RegisteredUser$outboundSchema` instead. */
88
+ const outboundSchema: z.ZodType<RegisteredUser$Outbound, z.ZodTypeDef, RegisteredUser>;
89
+ /** @deprecated use `RegisteredUser$Outbound` instead. */
90
+ type Outbound = RegisteredUser$Outbound;
91
+ }
92
+ export declare function registeredUserToJSON(registeredUser: RegisteredUser): string;
93
+ export declare function registeredUserFromJSON(jsonString: string): SafeParseResult<RegisteredUser, SDKValidationError>;
94
+ /** @internal */
95
+ export declare const CreateCartAddressRequestBody$inboundSchema: z.ZodType<CreateCartAddressRequestBody, z.ZodTypeDef, unknown>;
96
+ /** @internal */
97
+ export type CreateCartAddressRequestBody$Outbound = RegisteredUser$Outbound | GuestUser$Outbound;
98
+ /** @internal */
99
+ export declare const CreateCartAddressRequestBody$outboundSchema: z.ZodType<CreateCartAddressRequestBody$Outbound, z.ZodTypeDef, CreateCartAddressRequestBody>;
100
+ /**
101
+ * @internal
102
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
103
+ */
104
+ export declare namespace CreateCartAddressRequestBody$ {
105
+ /** @deprecated use `CreateCartAddressRequestBody$inboundSchema` instead. */
106
+ const inboundSchema: z.ZodType<CreateCartAddressRequestBody, z.ZodTypeDef, unknown>;
107
+ /** @deprecated use `CreateCartAddressRequestBody$outboundSchema` instead. */
108
+ const outboundSchema: z.ZodType<CreateCartAddressRequestBody$Outbound, z.ZodTypeDef, CreateCartAddressRequestBody>;
109
+ /** @deprecated use `CreateCartAddressRequestBody$Outbound` instead. */
110
+ type Outbound = CreateCartAddressRequestBody$Outbound;
111
+ }
112
+ export declare function createCartAddressRequestBodyToJSON(createCartAddressRequestBody: CreateCartAddressRequestBody): string;
113
+ export declare function createCartAddressRequestBodyFromJSON(jsonString: string): SafeParseResult<CreateCartAddressRequestBody, SDKValidationError>;
114
+ /** @internal */
115
+ export declare const CreateCartAddressRequest$inboundSchema: z.ZodType<CreateCartAddressRequest, z.ZodTypeDef, unknown>;
116
+ /** @internal */
117
+ export type CreateCartAddressRequest$Outbound = {
118
+ id: string;
119
+ RequestBody: RegisteredUser$Outbound | GuestUser$Outbound;
120
+ };
121
+ /** @internal */
122
+ export declare const CreateCartAddressRequest$outboundSchema: z.ZodType<CreateCartAddressRequest$Outbound, z.ZodTypeDef, CreateCartAddressRequest>;
123
+ /**
124
+ * @internal
125
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
126
+ */
127
+ export declare namespace CreateCartAddressRequest$ {
128
+ /** @deprecated use `CreateCartAddressRequest$inboundSchema` instead. */
129
+ const inboundSchema: z.ZodType<CreateCartAddressRequest, z.ZodTypeDef, unknown>;
130
+ /** @deprecated use `CreateCartAddressRequest$outboundSchema` instead. */
131
+ const outboundSchema: z.ZodType<CreateCartAddressRequest$Outbound, z.ZodTypeDef, CreateCartAddressRequest>;
132
+ /** @deprecated use `CreateCartAddressRequest$Outbound` instead. */
133
+ type Outbound = CreateCartAddressRequest$Outbound;
134
+ }
135
+ export declare function createCartAddressRequestToJSON(createCartAddressRequest: CreateCartAddressRequest): string;
136
+ export declare function createCartAddressRequestFromJSON(jsonString: string): SafeParseResult<CreateCartAddressRequest, SDKValidationError>;
137
+ /** @internal */
138
+ export declare const CreateCartAddressContent$inboundSchema: z.ZodType<CreateCartAddressContent, z.ZodTypeDef, unknown>;
139
+ /** @internal */
140
+ export type CreateCartAddressContent$Outbound = {
141
+ cart: components.Cart$Outbound;
142
+ };
143
+ /** @internal */
144
+ export declare const CreateCartAddressContent$outboundSchema: z.ZodType<CreateCartAddressContent$Outbound, z.ZodTypeDef, CreateCartAddressContent>;
145
+ /**
146
+ * @internal
147
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
148
+ */
149
+ export declare namespace CreateCartAddressContent$ {
150
+ /** @deprecated use `CreateCartAddressContent$inboundSchema` instead. */
151
+ const inboundSchema: z.ZodType<CreateCartAddressContent, z.ZodTypeDef, unknown>;
152
+ /** @deprecated use `CreateCartAddressContent$outboundSchema` instead. */
153
+ const outboundSchema: z.ZodType<CreateCartAddressContent$Outbound, z.ZodTypeDef, CreateCartAddressContent>;
154
+ /** @deprecated use `CreateCartAddressContent$Outbound` instead. */
155
+ type Outbound = CreateCartAddressContent$Outbound;
156
+ }
157
+ export declare function createCartAddressContentToJSON(createCartAddressContent: CreateCartAddressContent): string;
158
+ export declare function createCartAddressContentFromJSON(jsonString: string): SafeParseResult<CreateCartAddressContent, SDKValidationError>;
159
+ /** @internal */
160
+ export declare const CreateCartAddressResponseBody$inboundSchema: z.ZodType<CreateCartAddressResponseBody, z.ZodTypeDef, unknown>;
161
+ /** @internal */
162
+ export type CreateCartAddressResponseBody$Outbound = {
163
+ message: string;
164
+ success: boolean;
165
+ content: CreateCartAddressContent$Outbound;
166
+ };
167
+ /** @internal */
168
+ export declare const CreateCartAddressResponseBody$outboundSchema: z.ZodType<CreateCartAddressResponseBody$Outbound, z.ZodTypeDef, CreateCartAddressResponseBody>;
169
+ /**
170
+ * @internal
171
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
172
+ */
173
+ export declare namespace CreateCartAddressResponseBody$ {
174
+ /** @deprecated use `CreateCartAddressResponseBody$inboundSchema` instead. */
175
+ const inboundSchema: z.ZodType<CreateCartAddressResponseBody, z.ZodTypeDef, unknown>;
176
+ /** @deprecated use `CreateCartAddressResponseBody$outboundSchema` instead. */
177
+ const outboundSchema: z.ZodType<CreateCartAddressResponseBody$Outbound, z.ZodTypeDef, CreateCartAddressResponseBody>;
178
+ /** @deprecated use `CreateCartAddressResponseBody$Outbound` instead. */
179
+ type Outbound = CreateCartAddressResponseBody$Outbound;
180
+ }
181
+ export declare function createCartAddressResponseBodyToJSON(createCartAddressResponseBody: CreateCartAddressResponseBody): string;
182
+ export declare function createCartAddressResponseBodyFromJSON(jsonString: string): SafeParseResult<CreateCartAddressResponseBody, SDKValidationError>;
183
+ //# sourceMappingURL=createcartaddress.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createcartaddress.d.ts","sourceRoot":"","sources":["../../../src/models/operations/createcartaddress.ts"],"names":[],"mappings":"A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AAE,OAAO,CAAC;IACjB,OAAO,EAAE,iCAAiC,CAAC;CAC5C,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,4CAA4C,EAAE,CAAC,CAAC,OAAO,CAClE,sCAAsC,EACtC,CAAC,CAAC,UAAU,EACZ,6BAA6B,CAK7B,CAAC;AAEH;;;GAGG;AACH,yBAAiB,8BAA8B,CAAC;IAC9C,6EAA6E;IACtE,MAAM,aAAa,iEAA8C,CAAC;IACzE,8EAA8E;IACvE,MAAM,cAAc,gGAA+C,CAAC;IAC3E,wEAAwE;IACxE,KAAY,QAAQ,GAAG,sCAAsC,CAAC;CAC/D;AAED,wBAAgB,mCAAmC,CACjD,6BAA6B,EAAE,6BAA6B,GAC3D,MAAM,CAMR;AAED,wBAAgB,qCAAqC,CACnD,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,6BAA6B,EAAE,kBAAkB,CAAC,CAMpE"}
@@ -0,0 +1,214 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+ import * as z from "zod";
5
+ import { remap as remap$ } from "../../lib/primitives.js";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import * as components from "../components/index.js";
8
+ export const CreateCartAddressServerList = [
9
+ /**
10
+ * Staging Server
11
+ */
12
+ "https://staging.api.commercengine.io/api/v1/{store_id}/storefront",
13
+ /**
14
+ * Prod Server
15
+ */
16
+ "https://prod.api.commercengine.io/api/v1/{store_id}/storefront",
17
+ ];
18
+ /** @internal */
19
+ export const GuestUser$inboundSchema = z.object({
20
+ billing_address: z.nullable(components.CustomerAddressInput$inboundSchema),
21
+ shipping_address: z.nullable(components.CustomerAddressInput$inboundSchema),
22
+ }).transform((v) => {
23
+ return remap$(v, {
24
+ "billing_address": "billingAddress",
25
+ "shipping_address": "shippingAddress",
26
+ });
27
+ });
28
+ /** @internal */
29
+ export const GuestUser$outboundSchema = z.object({
30
+ billingAddress: z.nullable(components.CustomerAddressInput$outboundSchema),
31
+ shippingAddress: z.nullable(components.CustomerAddressInput$outboundSchema),
32
+ }).transform((v) => {
33
+ return remap$(v, {
34
+ billingAddress: "billing_address",
35
+ shippingAddress: "shipping_address",
36
+ });
37
+ });
38
+ /**
39
+ * @internal
40
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
41
+ */
42
+ export var GuestUser$;
43
+ (function (GuestUser$) {
44
+ /** @deprecated use `GuestUser$inboundSchema` instead. */
45
+ GuestUser$.inboundSchema = GuestUser$inboundSchema;
46
+ /** @deprecated use `GuestUser$outboundSchema` instead. */
47
+ GuestUser$.outboundSchema = GuestUser$outboundSchema;
48
+ })(GuestUser$ || (GuestUser$ = {}));
49
+ export function guestUserToJSON(guestUser) {
50
+ return JSON.stringify(GuestUser$outboundSchema.parse(guestUser));
51
+ }
52
+ export function guestUserFromJSON(jsonString) {
53
+ return safeParse(jsonString, (x) => GuestUser$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'GuestUser' from JSON`);
54
+ }
55
+ /** @internal */
56
+ export const RegisteredUser$inboundSchema = z.object({
57
+ billing_address_id: z.string(),
58
+ shipping_address_id: z.string(),
59
+ }).transform((v) => {
60
+ return remap$(v, {
61
+ "billing_address_id": "billingAddressId",
62
+ "shipping_address_id": "shippingAddressId",
63
+ });
64
+ });
65
+ /** @internal */
66
+ export const RegisteredUser$outboundSchema = z.object({
67
+ billingAddressId: z.string(),
68
+ shippingAddressId: z.string(),
69
+ }).transform((v) => {
70
+ return remap$(v, {
71
+ billingAddressId: "billing_address_id",
72
+ shippingAddressId: "shipping_address_id",
73
+ });
74
+ });
75
+ /**
76
+ * @internal
77
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
78
+ */
79
+ export var RegisteredUser$;
80
+ (function (RegisteredUser$) {
81
+ /** @deprecated use `RegisteredUser$inboundSchema` instead. */
82
+ RegisteredUser$.inboundSchema = RegisteredUser$inboundSchema;
83
+ /** @deprecated use `RegisteredUser$outboundSchema` instead. */
84
+ RegisteredUser$.outboundSchema = RegisteredUser$outboundSchema;
85
+ })(RegisteredUser$ || (RegisteredUser$ = {}));
86
+ export function registeredUserToJSON(registeredUser) {
87
+ return JSON.stringify(RegisteredUser$outboundSchema.parse(registeredUser));
88
+ }
89
+ export function registeredUserFromJSON(jsonString) {
90
+ return safeParse(jsonString, (x) => RegisteredUser$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'RegisteredUser' from JSON`);
91
+ }
92
+ /** @internal */
93
+ export const CreateCartAddressRequestBody$inboundSchema = z.union([
94
+ z.lazy(() => RegisteredUser$inboundSchema),
95
+ z.lazy(() => GuestUser$inboundSchema),
96
+ ]);
97
+ /** @internal */
98
+ export const CreateCartAddressRequestBody$outboundSchema = z.union([
99
+ z.lazy(() => RegisteredUser$outboundSchema),
100
+ z.lazy(() => GuestUser$outboundSchema),
101
+ ]);
102
+ /**
103
+ * @internal
104
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
105
+ */
106
+ export var CreateCartAddressRequestBody$;
107
+ (function (CreateCartAddressRequestBody$) {
108
+ /** @deprecated use `CreateCartAddressRequestBody$inboundSchema` instead. */
109
+ CreateCartAddressRequestBody$.inboundSchema = CreateCartAddressRequestBody$inboundSchema;
110
+ /** @deprecated use `CreateCartAddressRequestBody$outboundSchema` instead. */
111
+ CreateCartAddressRequestBody$.outboundSchema = CreateCartAddressRequestBody$outboundSchema;
112
+ })(CreateCartAddressRequestBody$ || (CreateCartAddressRequestBody$ = {}));
113
+ export function createCartAddressRequestBodyToJSON(createCartAddressRequestBody) {
114
+ return JSON.stringify(CreateCartAddressRequestBody$outboundSchema.parse(createCartAddressRequestBody));
115
+ }
116
+ export function createCartAddressRequestBodyFromJSON(jsonString) {
117
+ return safeParse(jsonString, (x) => CreateCartAddressRequestBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateCartAddressRequestBody' from JSON`);
118
+ }
119
+ /** @internal */
120
+ export const CreateCartAddressRequest$inboundSchema = z.object({
121
+ id: z.string(),
122
+ RequestBody: z.union([
123
+ z.lazy(() => RegisteredUser$inboundSchema),
124
+ z.lazy(() => GuestUser$inboundSchema),
125
+ ]),
126
+ }).transform((v) => {
127
+ return remap$(v, {
128
+ "RequestBody": "requestBody",
129
+ });
130
+ });
131
+ /** @internal */
132
+ export const CreateCartAddressRequest$outboundSchema = z.object({
133
+ id: z.string(),
134
+ requestBody: z.union([
135
+ z.lazy(() => RegisteredUser$outboundSchema),
136
+ z.lazy(() => GuestUser$outboundSchema),
137
+ ]),
138
+ }).transform((v) => {
139
+ return remap$(v, {
140
+ requestBody: "RequestBody",
141
+ });
142
+ });
143
+ /**
144
+ * @internal
145
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
146
+ */
147
+ export var CreateCartAddressRequest$;
148
+ (function (CreateCartAddressRequest$) {
149
+ /** @deprecated use `CreateCartAddressRequest$inboundSchema` instead. */
150
+ CreateCartAddressRequest$.inboundSchema = CreateCartAddressRequest$inboundSchema;
151
+ /** @deprecated use `CreateCartAddressRequest$outboundSchema` instead. */
152
+ CreateCartAddressRequest$.outboundSchema = CreateCartAddressRequest$outboundSchema;
153
+ })(CreateCartAddressRequest$ || (CreateCartAddressRequest$ = {}));
154
+ export function createCartAddressRequestToJSON(createCartAddressRequest) {
155
+ return JSON.stringify(CreateCartAddressRequest$outboundSchema.parse(createCartAddressRequest));
156
+ }
157
+ export function createCartAddressRequestFromJSON(jsonString) {
158
+ return safeParse(jsonString, (x) => CreateCartAddressRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateCartAddressRequest' from JSON`);
159
+ }
160
+ /** @internal */
161
+ export const CreateCartAddressContent$inboundSchema = z.object({
162
+ cart: components.Cart$inboundSchema,
163
+ });
164
+ /** @internal */
165
+ export const CreateCartAddressContent$outboundSchema = z.object({
166
+ cart: components.Cart$outboundSchema,
167
+ });
168
+ /**
169
+ * @internal
170
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
171
+ */
172
+ export var CreateCartAddressContent$;
173
+ (function (CreateCartAddressContent$) {
174
+ /** @deprecated use `CreateCartAddressContent$inboundSchema` instead. */
175
+ CreateCartAddressContent$.inboundSchema = CreateCartAddressContent$inboundSchema;
176
+ /** @deprecated use `CreateCartAddressContent$outboundSchema` instead. */
177
+ CreateCartAddressContent$.outboundSchema = CreateCartAddressContent$outboundSchema;
178
+ })(CreateCartAddressContent$ || (CreateCartAddressContent$ = {}));
179
+ export function createCartAddressContentToJSON(createCartAddressContent) {
180
+ return JSON.stringify(CreateCartAddressContent$outboundSchema.parse(createCartAddressContent));
181
+ }
182
+ export function createCartAddressContentFromJSON(jsonString) {
183
+ return safeParse(jsonString, (x) => CreateCartAddressContent$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateCartAddressContent' from JSON`);
184
+ }
185
+ /** @internal */
186
+ export const CreateCartAddressResponseBody$inboundSchema = z.object({
187
+ message: z.string(),
188
+ success: z.boolean(),
189
+ content: z.lazy(() => CreateCartAddressContent$inboundSchema),
190
+ });
191
+ /** @internal */
192
+ export const CreateCartAddressResponseBody$outboundSchema = z.object({
193
+ message: z.string(),
194
+ success: z.boolean(),
195
+ content: z.lazy(() => CreateCartAddressContent$outboundSchema),
196
+ });
197
+ /**
198
+ * @internal
199
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
200
+ */
201
+ export var CreateCartAddressResponseBody$;
202
+ (function (CreateCartAddressResponseBody$) {
203
+ /** @deprecated use `CreateCartAddressResponseBody$inboundSchema` instead. */
204
+ CreateCartAddressResponseBody$.inboundSchema = CreateCartAddressResponseBody$inboundSchema;
205
+ /** @deprecated use `CreateCartAddressResponseBody$outboundSchema` instead. */
206
+ CreateCartAddressResponseBody$.outboundSchema = CreateCartAddressResponseBody$outboundSchema;
207
+ })(CreateCartAddressResponseBody$ || (CreateCartAddressResponseBody$ = {}));
208
+ export function createCartAddressResponseBodyToJSON(createCartAddressResponseBody) {
209
+ return JSON.stringify(CreateCartAddressResponseBody$outboundSchema.parse(createCartAddressResponseBody));
210
+ }
211
+ export function createCartAddressResponseBodyFromJSON(jsonString) {
212
+ return safeParse(jsonString, (x) => CreateCartAddressResponseBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'CreateCartAddressResponseBody' from JSON`);
213
+ }
214
+ //# sourceMappingURL=createcartaddress.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createcartaddress.js","sourceRoot":"","sources":["../../../src/models/operations/createcartaddress.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAE,KAAK,IAAI,MAAM,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAEjD,OAAO,KAAK,UAAU,MAAM,wBAAwB,CAAC;AAGrD,MAAM,CAAC,MAAM,2BAA2B,GAAG;IACzC;;OAEG;IACH,mEAAmE;IACnE;;OAEG;IACH,gEAAgE;CACxD,CAAC;AAkDX,gBAAgB;AAChB,MAAM,CAAC,MAAM,uBAAuB,GAIhC,CAAC,CAAC,MAAM,CAAC;IACX,eAAe,EAAE,CAAC,CAAC,QAAQ,CAAC,UAAU,CAAC,kCAAkC,CAAC;IAC1E,gBAAgB,EAAE,CAAC,CAAC,QAAQ,CAAC,UAAU,CAAC,kCAAkC,CAAC;CAC5E,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,MAAM,CAAC,CAAC,EAAE;QACf,iBAAiB,EAAE,gBAAgB;QACnC,kBAAkB,EAAE,iBAAiB;KACtC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAQH,gBAAgB;AAChB,MAAM,CAAC,MAAM,wBAAwB,GAIjC,CAAC,CAAC,MAAM,CAAC;IACX,cAAc,EAAE,CAAC,CAAC,QAAQ,CAAC,UAAU,CAAC,mCAAmC,CAAC;IAC1E,eAAe,EAAE,CAAC,CAAC,Q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AAS,CACnB,4CAA4C,CAAC,KAAK,CAChD,6BAA6B,CAC9B,CACF,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,qCAAqC,CACnD,UAAkB;IAElB,OAAO,SAAS,CACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,2CAA2C,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EACvE,2DAA2D,CAC5D,CAAC;AACJ,CAAC"}
@@ -4,9 +4,9 @@ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
4
  export declare const DeleteCartServerList: readonly ["https://staging.api.commercengine.io/api/v1/{store_id}/storefront", "https://prod.api.commercengine.io/api/v1/{store_id}/storefront"];
5
5
  export type DeleteCartRequest = {
6
6
  /**
7
- * user id
7
+ * Cart ID
8
8
  */
9
- userId: string;
9
+ id: string;
10
10
  };
11
11
  /**
12
12
  * OK
@@ -19,7 +19,7 @@ export type DeleteCartResponseBody = {
19
19
  export declare const DeleteCartRequest$inboundSchema: z.ZodType<DeleteCartRequest, z.ZodTypeDef, unknown>;
20
20
  /** @internal */
21
21
  export type DeleteCartRequest$Outbound = {
22
- user_id: string;
22
+ id: string;
23
23
  };
24
24
  /** @internal */
25
25
  export declare const DeleteCartRequest$outboundSchema: z.ZodType<DeleteCartRequest$Outbound, z.ZodTypeDef, DeleteCartRequest>;
@@ -1 +1 @@
1
- {"version":3,"file":"deletecart.d.ts","sourceRoot":"","sources":["../../../src/models/operations/deletecart.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAGzB,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE,eAAO,MAAM,oBAAoB,kJASvB,CAAC;AAEX,MAAM,MAAM,iBAAiB,GAAG;IAC9B;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF;;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GG;AACH,yBAAiB,kBAAkB,CAAC;IAClC,iEAAiE;IAC1D,MAAM,aAAa,qDAAkC,CAAC;IAC7D,kEAAkE;IAC3D,MAAM,cAAc,wEAAmC,CAAC;IAC/D,4DAA4D;IAC5D,KAAY,QAAQ,GAAG,0BAA0B,CAAC;CACnD;AAED,wBAAgB,uBAAuB,CACrC,iBAAiB,EAAE,iBAAiB,GACnC,MAAM,CAIR;AAED,wBAAgB,yBAAyB,CACvC,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,iBAAiB,EAAE,kBAAkB,CAAC,CAMxD;AAED,gBAAgB;AAChB,eAAO,MAAM,oCAAoC,EAAE,CAAC,CAAC,OAAO,CAC1D,sBAAsB,EACtB,CAAC,CAAC,UAAU,EACZ,OAAO,CAIP,CAAC;AAEH,gBAAgB;AAChB,MAAM,MAAM,+BAA+B,GAAG;IAC5C,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,qCAAqC,EAAE,CAAC,CAAC,OAAO,CAC3D,+BAA+B,EAC/B,CAAC,CAAC,UAAU,EACZ,sBAAsB,CAItB,CAAC;AAEH;;;GAGG;AACH,yBAAiB,uBAAuB,CAAC;IACvC,sEAAsE;IAC/D,MAAM,aAAa,0DAAuC,CAAC;IAClE,uEAAuE;IAChE,MAAM,cAAc,kFAAwC,CAAC;IACpE,iEAAiE;IACjE,KAAY,QAAQ,GAAG,+BAA+B,CAAC;CACxD;AAED,wBAAgB,4BAA4B,CAC1C,sBAAsB,EAAE,sBAAsB,GAC7C,MAAM,CAIR;AAED,wBAAgB,8BAA8B,CAC5C,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,sBAAsB,EAAE,kBAAkB,CAAC,CAM7D"}
@@ -2,7 +2,6 @@
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
4
  import * as z from "zod";
5
- import { remap as remap$ } from "../../lib/primitives.js";
6
5
  import { safeParse } from "../../lib/schemas.js";
7
6
  export const DeleteCartServerList = [
8
7
  /**
@@ -16,19 +15,11 @@ export const DeleteCartServerList = [
16
15
  ];
17
16
  /** @internal */
18
17
  export const DeleteCartRequest$inboundSchema = z.object({
19
- user_id: z.string(),
20
- }).transform((v) => {
21
- return remap$(v, {
22
- "user_id": "userId",
23
- });
18
+ id: z.string(),
24
19
  });
25
20
  /** @internal */
26
21
  export const DeleteCartRequest$outboundSchema = z.object({
27
- userId: z.string(),
28
- }).transform((v) => {
29
- return remap$(v, {
30
- userId: "user_id",
31
- });
22
+ id: z.string(),
32
23
  });
33
24
  /**
34
25
  * @internal
@@ -1 +1 @@
1
- {"version":3,"file":"deletecart.js","sourceRoot":"","sources":["../../../src/models/operations/deletecart.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAAE,KAAK,IAAI,MAAM,EAAE,MAAM,yBAAyB,CAAC;AAC1D,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AAIjD,MAAM,CAAC,MAAM,oBAAoB,GAAG;IAClC;;OAEG;IACH,mEAAmE;IACnE;;OAEG;IACH,gEAAgE;CACxD,CAAC;AAiBX,gBAAgB;AAChB,MAAM,CAAC,MAAM,+BAA+B,GAIxC,CAAC,CAAC,MAAM,CAAC;IACX,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;CACpB,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,MAAM,CAAC,CAAC,EAAE;QACf,SAAS,EAAE,QAAQ;KACpB,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAOH,gBAAgB;AAChB,MAAM,CAAC,MAAM,gCAAgC,GAIzC,CAAC,CAAC,MAAM,CAAC;IACX,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE;CACnB,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,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,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EAChE,oDAAoD,CACrD,CAAC;AACJ,CAAC"}
@@ -0,0 +1,63 @@
1
+ import * as z from "zod";
2
+ import { Result as SafeParseResult } from "../../types/fp.js";
3
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
4
+ export declare const DeleteUserCartServerList: readonly ["https://staging.api.commercengine.io/api/v1/{store_id}/storefront", "https://prod.api.commercengine.io/api/v1/{store_id}/storefront"];
5
+ export type DeleteUserCartRequest = {
6
+ /**
7
+ * User ID
8
+ */
9
+ userId: string;
10
+ };
11
+ /**
12
+ * OK
13
+ */
14
+ export type DeleteUserCartResponseBody = {
15
+ message: string;
16
+ success?: boolean | undefined;
17
+ };
18
+ /** @internal */
19
+ export declare const DeleteUserCartRequest$inboundSchema: z.ZodType<DeleteUserCartRequest, z.ZodTypeDef, unknown>;
20
+ /** @internal */
21
+ export type DeleteUserCartRequest$Outbound = {
22
+ user_id: string;
23
+ };
24
+ /** @internal */
25
+ export declare const DeleteUserCartRequest$outboundSchema: z.ZodType<DeleteUserCartRequest$Outbound, z.ZodTypeDef, DeleteUserCartRequest>;
26
+ /**
27
+ * @internal
28
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
29
+ */
30
+ export declare namespace DeleteUserCartRequest$ {
31
+ /** @deprecated use `DeleteUserCartRequest$inboundSchema` instead. */
32
+ const inboundSchema: z.ZodType<DeleteUserCartRequest, z.ZodTypeDef, unknown>;
33
+ /** @deprecated use `DeleteUserCartRequest$outboundSchema` instead. */
34
+ const outboundSchema: z.ZodType<DeleteUserCartRequest$Outbound, z.ZodTypeDef, DeleteUserCartRequest>;
35
+ /** @deprecated use `DeleteUserCartRequest$Outbound` instead. */
36
+ type Outbound = DeleteUserCartRequest$Outbound;
37
+ }
38
+ export declare function deleteUserCartRequestToJSON(deleteUserCartRequest: DeleteUserCartRequest): string;
39
+ export declare function deleteUserCartRequestFromJSON(jsonString: string): SafeParseResult<DeleteUserCartRequest, SDKValidationError>;
40
+ /** @internal */
41
+ export declare const DeleteUserCartResponseBody$inboundSchema: z.ZodType<DeleteUserCartResponseBody, z.ZodTypeDef, unknown>;
42
+ /** @internal */
43
+ export type DeleteUserCartResponseBody$Outbound = {
44
+ message: string;
45
+ success: boolean;
46
+ };
47
+ /** @internal */
48
+ export declare const DeleteUserCartResponseBody$outboundSchema: z.ZodType<DeleteUserCartResponseBody$Outbound, z.ZodTypeDef, DeleteUserCartResponseBody>;
49
+ /**
50
+ * @internal
51
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
52
+ */
53
+ export declare namespace DeleteUserCartResponseBody$ {
54
+ /** @deprecated use `DeleteUserCartResponseBody$inboundSchema` instead. */
55
+ const inboundSchema: z.ZodType<DeleteUserCartResponseBody, z.ZodTypeDef, unknown>;
56
+ /** @deprecated use `DeleteUserCartResponseBody$outboundSchema` instead. */
57
+ const outboundSchema: z.ZodType<DeleteUserCartResponseBody$Outbound, z.ZodTypeDef, DeleteUserCartResponseBody>;
58
+ /** @deprecated use `DeleteUserCartResponseBody$Outbound` instead. */
59
+ type Outbound = DeleteUserCartResponseBody$Outbound;
60
+ }
61
+ export declare function deleteUserCartResponseBodyToJSON(deleteUserCartResponseBody: DeleteUserCartResponseBody): string;
62
+ export declare function deleteUserCartResponseBodyFromJSON(jsonString: string): SafeParseResult<DeleteUserCartResponseBody, SDKValidationError>;
63
+ //# sourceMappingURL=deleteusercart.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"deleteusercart.d.ts","sourceRoot":"","sources":["../../../src/models/operations/deleteusercart.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAGzB,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE,eAAO,MAAM,wBAAwB,kJAS3B,CAAC;AAEX,MAAM,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CAAC,OAAO,CAC/D,mCAAmC,EACnC,CAAC,CAAC,UAAU,EACZ,0BAA0B,CAI1B,CAAC;AAEH;;;GAGG;AACH,yBAAiB,2BAA2B,CAAC;IAC3C,0EAA0E;IACnE,MAAM,aAAa,8DAA2C,CAAC;IACtE,2EAA2E;IACpE,MAAM,cAAc,0FAA4C,CAAC;IACxE,qEAAqE;IACrE,KAAY,QAAQ,GAAG,mCAAmC,CAAC;CAC5D;AAED,wBAAgB,gCAAgC,CAC9C,0BAA0B,EAAE,0BAA0B,GACrD,MAAM,CAIR;AAED,wBAAgB,kCAAkC,CAChD,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,0BAA0B,EAAE,kBAAkB,CAAC,CAMjE"}
@@ -0,0 +1,77 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+ import * as z from "zod";
5
+ import { remap as remap$ } from "../../lib/primitives.js";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ export const DeleteUserCartServerList = [
8
+ /**
9
+ * Staging Server
10
+ */
11
+ "https://staging.api.commercengine.io/api/v1/{store_id}/storefront",
12
+ /**
13
+ * Prod Server
14
+ */
15
+ "https://prod.api.commercengine.io/api/v1/{store_id}/storefront",
16
+ ];
17
+ /** @internal */
18
+ export const DeleteUserCartRequest$inboundSchema = z.object({
19
+ user_id: z.string(),
20
+ }).transform((v) => {
21
+ return remap$(v, {
22
+ "user_id": "userId",
23
+ });
24
+ });
25
+ /** @internal */
26
+ export const DeleteUserCartRequest$outboundSchema = z.object({
27
+ userId: z.string(),
28
+ }).transform((v) => {
29
+ return remap$(v, {
30
+ userId: "user_id",
31
+ });
32
+ });
33
+ /**
34
+ * @internal
35
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
36
+ */
37
+ export var DeleteUserCartRequest$;
38
+ (function (DeleteUserCartRequest$) {
39
+ /** @deprecated use `DeleteUserCartRequest$inboundSchema` instead. */
40
+ DeleteUserCartRequest$.inboundSchema = DeleteUserCartRequest$inboundSchema;
41
+ /** @deprecated use `DeleteUserCartRequest$outboundSchema` instead. */
42
+ DeleteUserCartRequest$.outboundSchema = DeleteUserCartRequest$outboundSchema;
43
+ })(DeleteUserCartRequest$ || (DeleteUserCartRequest$ = {}));
44
+ export function deleteUserCartRequestToJSON(deleteUserCartRequest) {
45
+ return JSON.stringify(DeleteUserCartRequest$outboundSchema.parse(deleteUserCartRequest));
46
+ }
47
+ export function deleteUserCartRequestFromJSON(jsonString) {
48
+ return safeParse(jsonString, (x) => DeleteUserCartRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'DeleteUserCartRequest' from JSON`);
49
+ }
50
+ /** @internal */
51
+ export const DeleteUserCartResponseBody$inboundSchema = z.object({
52
+ message: z.string(),
53
+ success: z.boolean().default(true),
54
+ });
55
+ /** @internal */
56
+ export const DeleteUserCartResponseBody$outboundSchema = z.object({
57
+ message: z.string(),
58
+ success: z.boolean().default(true),
59
+ });
60
+ /**
61
+ * @internal
62
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
63
+ */
64
+ export var DeleteUserCartResponseBody$;
65
+ (function (DeleteUserCartResponseBody$) {
66
+ /** @deprecated use `DeleteUserCartResponseBody$inboundSchema` instead. */
67
+ DeleteUserCartResponseBody$.inboundSchema = DeleteUserCartResponseBody$inboundSchema;
68
+ /** @deprecated use `DeleteUserCartResponseBody$outboundSchema` instead. */
69
+ DeleteUserCartResponseBody$.outboundSchema = DeleteUserCartResponseBody$outboundSchema;
70
+ })(DeleteUserCartResponseBody$ || (DeleteUserCartResponseBody$ = {}));
71
+ export function deleteUserCartResponseBodyToJSON(deleteUserCartResponseBody) {
72
+ return JSON.stringify(DeleteUserCartResponseBody$outboundSchema.parse(deleteUserCartResponseBody));
73
+ }
74
+ export function deleteUserCartResponseBodyFromJSON(jsonString) {
75
+ return safeParse(jsonString, (x) => DeleteUserCartResponseBody$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'DeleteUserCartResponseBody' from JSON`);
76
+ }
77
+ //# sourceMappingURL=deleteusercart.js.map