ce-storefront 0.14.0 → 0.14.1

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 (171) hide show
  1. package/docs/sdks/catalog/README.md +7 -3
  2. package/esm/funcs/catalogGetProductDetail.js +1 -1
  3. package/esm/funcs/catalogGetProductDetail.js.map +1 -1
  4. package/esm/funcs/catalogGetVariantDetail.js +1 -1
  5. package/esm/funcs/catalogGetVariantDetail.js.map +1 -1
  6. package/esm/funcs/catalogListCrosssellProducts.js +1 -1
  7. package/esm/funcs/catalogListCrosssellProducts.js.map +1 -1
  8. package/esm/funcs/catalogListProductVariants.js +1 -1
  9. package/esm/funcs/catalogListProductVariants.js.map +1 -1
  10. package/esm/funcs/catalogListProducts.js +1 -1
  11. package/esm/funcs/catalogListProducts.js.map +1 -1
  12. package/esm/funcs/catalogListSimilarProducts.js +1 -1
  13. package/esm/funcs/catalogListSimilarProducts.js.map +1 -1
  14. package/esm/funcs/catalogListSkus.js +1 -1
  15. package/esm/funcs/catalogListSkus.js.map +1 -1
  16. package/esm/funcs/catalogListUpsellProducts.js +1 -1
  17. package/esm/funcs/catalogListUpsellProducts.js.map +1 -1
  18. package/esm/funcs/catalogSearchProducts.d.ts +1 -2
  19. package/esm/funcs/catalogSearchProducts.d.ts.map +1 -1
  20. package/esm/funcs/catalogSearchProducts.js +4 -4
  21. package/esm/funcs/catalogSearchProducts.js.map +1 -1
  22. package/esm/lib/config.d.ts +3 -3
  23. package/esm/lib/config.js +3 -3
  24. package/esm/lib/files.d.ts +5 -0
  25. package/esm/lib/files.d.ts.map +1 -1
  26. package/esm/lib/files.js +40 -0
  27. package/esm/lib/files.js.map +1 -1
  28. package/esm/lib/security.d.ts +2 -2
  29. package/esm/lib/security.d.ts.map +1 -1
  30. package/esm/models/components/coloroption.js +1 -1
  31. package/esm/models/components/coloroption.js.map +1 -1
  32. package/esm/models/components/customeraddress.js +1 -1
  33. package/esm/models/components/customeraddress.js.map +1 -1
  34. package/esm/models/components/customeraddressinput.js +1 -1
  35. package/esm/models/components/customeraddressinput.js.map +1 -1
  36. package/esm/models/components/discountbasedpromotion.js +1 -1
  37. package/esm/models/components/discountbasedpromotion.js.map +1 -1
  38. package/esm/models/components/fixedpricepromotion.js +1 -1
  39. package/esm/models/components/fixedpricepromotion.js.map +1 -1
  40. package/esm/models/components/freegoodspromotion.js +1 -1
  41. package/esm/models/components/freegoodspromotion.js.map +1 -1
  42. package/esm/models/components/generateotpwithemail.js +1 -1
  43. package/esm/models/components/generateotpwithemail.js.map +1 -1
  44. package/esm/models/components/juspaypaymentinfo.d.ts.map +1 -1
  45. package/esm/models/components/juspaypaymentinfo.js +3 -2
  46. package/esm/models/components/juspaypaymentinfo.js.map +1 -1
  47. package/esm/models/components/orderpayment.d.ts +2 -2
  48. package/esm/models/components/orderpayment.d.ts.map +1 -1
  49. package/esm/models/components/orderpayment.js +2 -2
  50. package/esm/models/components/orderpayment.js.map +1 -1
  51. package/esm/models/components/payupaymentinfo.js +3 -3
  52. package/esm/models/components/payupaymentinfo.js.map +1 -1
  53. package/esm/models/components/productpromotion.d.ts +20 -20
  54. package/esm/models/components/productpromotion.d.ts.map +1 -1
  55. package/esm/models/components/productpromotion.js +16 -16
  56. package/esm/models/components/productpromotion.js.map +1 -1
  57. package/esm/models/components/searchproduct.d.ts +0 -5
  58. package/esm/models/components/searchproduct.d.ts.map +1 -1
  59. package/esm/models/components/searchproduct.js +0 -11
  60. package/esm/models/components/searchproduct.js.map +1 -1
  61. package/esm/models/components/singleselectoption.js +1 -1
  62. package/esm/models/components/singleselectoption.js.map +1 -1
  63. package/esm/models/components/volumebasedpromotion.js +1 -1
  64. package/esm/models/components/volumebasedpromotion.js.map +1 -1
  65. package/esm/models/operations/createaddress.js +1 -1
  66. package/esm/models/operations/createaddress.js.map +1 -1
  67. package/esm/models/operations/createorder.d.ts +16 -16
  68. package/esm/models/operations/createorder.d.ts.map +1 -1
  69. package/esm/models/operations/createorder.js +12 -12
  70. package/esm/models/operations/createorder.js.map +1 -1
  71. package/esm/models/operations/generateotp.d.ts +2 -2
  72. package/esm/models/operations/generateotp.js +2 -2
  73. package/esm/models/operations/getaddressdetail.js +1 -1
  74. package/esm/models/operations/getaddressdetail.js.map +1 -1
  75. package/esm/models/operations/getproductdetail.d.ts +3 -3
  76. package/esm/models/operations/getproductdetail.d.ts.map +1 -1
  77. package/esm/models/operations/getproductdetail.js +4 -4
  78. package/esm/models/operations/getproductdetail.js.map +1 -1
  79. package/esm/models/operations/getvariantdetail.d.ts +3 -3
  80. package/esm/models/operations/getvariantdetail.d.ts.map +1 -1
  81. package/esm/models/operations/getvariantdetail.js +4 -4
  82. package/esm/models/operations/getvariantdetail.js.map +1 -1
  83. package/esm/models/operations/listaddresses.js +1 -1
  84. package/esm/models/operations/listaddresses.js.map +1 -1
  85. package/esm/models/operations/listcrosssellproducts.d.ts +3 -3
  86. package/esm/models/operations/listcrosssellproducts.d.ts.map +1 -1
  87. package/esm/models/operations/listcrosssellproducts.js +4 -4
  88. package/esm/models/operations/listcrosssellproducts.js.map +1 -1
  89. package/esm/models/operations/listproducts.d.ts +3 -3
  90. package/esm/models/operations/listproducts.d.ts.map +1 -1
  91. package/esm/models/operations/listproducts.js +4 -4
  92. package/esm/models/operations/listproducts.js.map +1 -1
  93. package/esm/models/operations/listproductvariants.d.ts +3 -3
  94. package/esm/models/operations/listproductvariants.d.ts.map +1 -1
  95. package/esm/models/operations/listproductvariants.js +4 -4
  96. package/esm/models/operations/listproductvariants.js.map +1 -1
  97. package/esm/models/operations/listsimilarproducts.d.ts +3 -3
  98. package/esm/models/operations/listsimilarproducts.d.ts.map +1 -1
  99. package/esm/models/operations/listsimilarproducts.js +4 -4
  100. package/esm/models/operations/listsimilarproducts.js.map +1 -1
  101. package/esm/models/operations/listskus.d.ts +3 -3
  102. package/esm/models/operations/listskus.d.ts.map +1 -1
  103. package/esm/models/operations/listskus.js +4 -4
  104. package/esm/models/operations/listskus.js.map +1 -1
  105. package/esm/models/operations/listupsellproducts.d.ts +3 -3
  106. package/esm/models/operations/listupsellproducts.d.ts.map +1 -1
  107. package/esm/models/operations/listupsellproducts.js +4 -4
  108. package/esm/models/operations/listupsellproducts.js.map +1 -1
  109. package/esm/models/operations/loginwithwhatsapp.js +1 -1
  110. package/esm/models/operations/loginwithwhatsapp.js.map +1 -1
  111. package/esm/models/operations/retryorderpayment.d.ts +16 -16
  112. package/esm/models/operations/retryorderpayment.d.ts.map +1 -1
  113. package/esm/models/operations/retryorderpayment.js +12 -12
  114. package/esm/models/operations/retryorderpayment.js.map +1 -1
  115. package/esm/models/operations/searchproducts.d.ts +30 -0
  116. package/esm/models/operations/searchproducts.d.ts.map +1 -1
  117. package/esm/models/operations/searchproducts.js +37 -0
  118. package/esm/models/operations/searchproducts.js.map +1 -1
  119. package/esm/models/operations/updateaddressdetail.js +1 -1
  120. package/esm/models/operations/updateaddressdetail.js.map +1 -1
  121. package/esm/sdk/catalog.d.ts +1 -2
  122. package/esm/sdk/catalog.d.ts.map +1 -1
  123. package/esm/sdk/catalog.js.map +1 -1
  124. package/esm/types/constdatetime.js +1 -1
  125. package/jsr.json +1 -1
  126. package/package.json +1 -1
  127. package/src/funcs/catalogGetProductDetail.ts +3 -3
  128. package/src/funcs/catalogGetVariantDetail.ts +3 -3
  129. package/src/funcs/catalogListCrosssellProducts.ts +3 -3
  130. package/src/funcs/catalogListProductVariants.ts +3 -3
  131. package/src/funcs/catalogListProducts.ts +3 -3
  132. package/src/funcs/catalogListSimilarProducts.ts +3 -3
  133. package/src/funcs/catalogListSkus.ts +3 -3
  134. package/src/funcs/catalogListUpsellProducts.ts +3 -3
  135. package/src/funcs/catalogSearchProducts.ts +10 -6
  136. package/src/lib/config.ts +3 -3
  137. package/src/lib/files.ts +42 -0
  138. package/src/lib/security.ts +2 -2
  139. package/src/models/components/coloroption.ts +1 -1
  140. package/src/models/components/customeraddress.ts +1 -1
  141. package/src/models/components/customeraddressinput.ts +1 -1
  142. package/src/models/components/discountbasedpromotion.ts +1 -1
  143. package/src/models/components/fixedpricepromotion.ts +1 -1
  144. package/src/models/components/freegoodspromotion.ts +1 -1
  145. package/src/models/components/generateotpwithemail.ts +1 -1
  146. package/src/models/components/juspaypaymentinfo.ts +3 -2
  147. package/src/models/components/orderpayment.ts +4 -4
  148. package/src/models/components/payupaymentinfo.ts +3 -3
  149. package/src/models/components/productpromotion.ts +48 -48
  150. package/src/models/components/searchproduct.ts +0 -16
  151. package/src/models/components/singleselectoption.ts +1 -1
  152. package/src/models/components/volumebasedpromotion.ts +1 -1
  153. package/src/models/operations/createaddress.ts +1 -1
  154. package/src/models/operations/createorder.ts +37 -35
  155. package/src/models/operations/generateotp.ts +6 -6
  156. package/src/models/operations/getaddressdetail.ts +1 -1
  157. package/src/models/operations/getproductdetail.ts +7 -7
  158. package/src/models/operations/getvariantdetail.ts +7 -7
  159. package/src/models/operations/listaddresses.ts +1 -1
  160. package/src/models/operations/listcrosssellproducts.ts +7 -7
  161. package/src/models/operations/listproducts.ts +7 -7
  162. package/src/models/operations/listproductvariants.ts +7 -7
  163. package/src/models/operations/listsimilarproducts.ts +7 -7
  164. package/src/models/operations/listskus.ts +7 -7
  165. package/src/models/operations/listupsellproducts.ts +7 -7
  166. package/src/models/operations/loginwithwhatsapp.ts +1 -1
  167. package/src/models/operations/retryorderpayment.ts +37 -35
  168. package/src/models/operations/searchproducts.ts +75 -0
  169. package/src/models/operations/updateaddressdetail.ts +1 -1
  170. package/src/sdk/catalog.ts +1 -2
  171. package/src/types/constdatetime.ts +1 -1
@@ -17,8 +17,8 @@ export const PaymentGateway = {
17
17
  export type PaymentGateway = ClosedEnum<typeof PaymentGateway>;
18
18
 
19
19
  export type PaymentGatewayParams =
20
- | (components.PayuPaymentGatewayParams & { paymentGateway: "PAYU" })
21
- | (components.JuspayPaymentGatewayParams & { paymentGateway: "JUSPAY" });
20
+ | (components.JuspayPaymentGatewayParams & { paymentGateway: "JUSPAY" })
21
+ | (components.PayuPaymentGatewayParams & { paymentGateway: "PAYU" });
22
22
 
23
23
  /**
24
24
  * Request body
@@ -27,18 +27,18 @@ export type CreateOrderRequestBody = {
27
27
  cartId: string;
28
28
  paymentGateway: PaymentGateway;
29
29
  paymentGatewayParams:
30
- | (components.PayuPaymentGatewayParams & { paymentGateway: "PAYU" })
31
- | (components.JuspayPaymentGatewayParams & { paymentGateway: "JUSPAY" });
30
+ | (components.JuspayPaymentGatewayParams & { paymentGateway: "JUSPAY" })
31
+ | (components.PayuPaymentGatewayParams & { paymentGateway: "PAYU" });
32
32
  };
33
33
 
34
34
  export type PaymentInfo =
35
- | components.JuspayPaymentInfo
36
- | components.PayuPaymentInfo;
35
+ | components.PayuPaymentInfo
36
+ | components.JuspayPaymentInfo;
37
37
 
38
38
  export type CreateOrderContent = {
39
39
  order: components.Order;
40
40
  paymentRequired: boolean;
41
- paymentInfo: components.JuspayPaymentInfo | components.PayuPaymentInfo;
41
+ paymentInfo: components.PayuPaymentInfo | components.JuspayPaymentInfo;
42
42
  };
43
43
 
44
44
  /**
@@ -77,13 +77,13 @@ export const PaymentGatewayParams$inboundSchema: z.ZodType<
77
77
  z.ZodTypeDef,
78
78
  unknown
79
79
  > = z.union([
80
- components.PayuPaymentGatewayParams$inboundSchema.and(
81
- z.object({ payment_gateway: z.literal("PAYU") }).transform((v) => ({
80
+ components.JuspayPaymentGatewayParams$inboundSchema.and(
81
+ z.object({ payment_gateway: z.literal("JUSPAY") }).transform((v) => ({
82
82
  paymentGateway: v.payment_gateway,
83
83
  })),
84
84
  ),
85
- components.JuspayPaymentGatewayParams$inboundSchema.and(
86
- z.object({ payment_gateway: z.literal("JUSPAY") }).transform((v) => ({
85
+ components.PayuPaymentGatewayParams$inboundSchema.and(
86
+ z.object({ payment_gateway: z.literal("PAYU") }).transform((v) => ({
87
87
  paymentGateway: v.payment_gateway,
88
88
  })),
89
89
  ),
@@ -91,9 +91,11 @@ export const PaymentGatewayParams$inboundSchema: z.ZodType<
91
91
 
92
92
  /** @internal */
93
93
  export type PaymentGatewayParams$Outbound =
94
- | (components.PayuPaymentGatewayParams$Outbound & { payment_gateway: "PAYU" })
95
94
  | (components.JuspayPaymentGatewayParams$Outbound & {
96
95
  payment_gateway: "JUSPAY";
96
+ })
97
+ | (components.PayuPaymentGatewayParams$Outbound & {
98
+ payment_gateway: "PAYU";
97
99
  });
98
100
 
99
101
  /** @internal */
@@ -102,13 +104,13 @@ export const PaymentGatewayParams$outboundSchema: z.ZodType<
102
104
  z.ZodTypeDef,
103
105
  PaymentGatewayParams
104
106
  > = z.union([
105
- components.PayuPaymentGatewayParams$outboundSchema.and(
106
- z.object({ paymentGateway: z.literal("PAYU") }).transform((v) => ({
107
+ components.JuspayPaymentGatewayParams$outboundSchema.and(
108
+ z.object({ paymentGateway: z.literal("JUSPAY") }).transform((v) => ({
107
109
  payment_gateway: v.paymentGateway,
108
110
  })),
109
111
  ),
110
- components.JuspayPaymentGatewayParams$outboundSchema.and(
111
- z.object({ paymentGateway: z.literal("JUSPAY") }).transform((v) => ({
112
+ components.PayuPaymentGatewayParams$outboundSchema.and(
113
+ z.object({ paymentGateway: z.literal("PAYU") }).transform((v) => ({
112
114
  payment_gateway: v.paymentGateway,
113
115
  })),
114
116
  ),
@@ -154,13 +156,13 @@ export const CreateOrderRequestBody$inboundSchema: z.ZodType<
154
156
  cart_id: z.string(),
155
157
  payment_gateway: PaymentGateway$inboundSchema,
156
158
  payment_gateway_params: z.union([
157
- components.PayuPaymentGatewayParams$inboundSchema.and(
158
- z.object({ payment_gateway: z.literal("PAYU") }).transform((v) => ({
159
+ components.JuspayPaymentGatewayParams$inboundSchema.and(
160
+ z.object({ payment_gateway: z.literal("JUSPAY") }).transform((v) => ({
159
161
  paymentGateway: v.payment_gateway,
160
162
  })),
161
163
  ),
162
- components.JuspayPaymentGatewayParams$inboundSchema.and(
163
- z.object({ payment_gateway: z.literal("JUSPAY") }).transform((v) => ({
164
+ components.PayuPaymentGatewayParams$inboundSchema.and(
165
+ z.object({ payment_gateway: z.literal("PAYU") }).transform((v) => ({
164
166
  paymentGateway: v.payment_gateway,
165
167
  })),
166
168
  ),
@@ -178,11 +180,11 @@ export type CreateOrderRequestBody$Outbound = {
178
180
  cart_id: string;
179
181
  payment_gateway: string;
180
182
  payment_gateway_params:
181
- | (components.PayuPaymentGatewayParams$Outbound & {
182
- payment_gateway: "PAYU";
183
- })
184
183
  | (components.JuspayPaymentGatewayParams$Outbound & {
185
184
  payment_gateway: "JUSPAY";
185
+ })
186
+ | (components.PayuPaymentGatewayParams$Outbound & {
187
+ payment_gateway: "PAYU";
186
188
  });
187
189
  };
188
190
 
@@ -195,13 +197,13 @@ export const CreateOrderRequestBody$outboundSchema: z.ZodType<
195
197
  cartId: z.string(),
196
198
  paymentGateway: PaymentGateway$outboundSchema,
197
199
  paymentGatewayParams: z.union([
198
- components.PayuPaymentGatewayParams$outboundSchema.and(
199
- z.object({ paymentGateway: z.literal("PAYU") }).transform((v) => ({
200
+ components.JuspayPaymentGatewayParams$outboundSchema.and(
201
+ z.object({ paymentGateway: z.literal("JUSPAY") }).transform((v) => ({
200
202
  payment_gateway: v.paymentGateway,
201
203
  })),
202
204
  ),
203
- components.JuspayPaymentGatewayParams$outboundSchema.and(
204
- z.object({ paymentGateway: z.literal("JUSPAY") }).transform((v) => ({
205
+ components.PayuPaymentGatewayParams$outboundSchema.and(
206
+ z.object({ paymentGateway: z.literal("PAYU") }).transform((v) => ({
205
207
  payment_gateway: v.paymentGateway,
206
208
  })),
207
209
  ),
@@ -251,14 +253,14 @@ export const PaymentInfo$inboundSchema: z.ZodType<
251
253
  z.ZodTypeDef,
252
254
  unknown
253
255
  > = z.union([
254
- components.JuspayPaymentInfo$inboundSchema,
255
256
  components.PayuPaymentInfo$inboundSchema,
257
+ components.JuspayPaymentInfo$inboundSchema,
256
258
  ]);
257
259
 
258
260
  /** @internal */
259
261
  export type PaymentInfo$Outbound =
260
- | components.JuspayPaymentInfo$Outbound
261
- | components.PayuPaymentInfo$Outbound;
262
+ | components.PayuPaymentInfo$Outbound
263
+ | components.JuspayPaymentInfo$Outbound;
262
264
 
263
265
  /** @internal */
264
266
  export const PaymentInfo$outboundSchema: z.ZodType<
@@ -266,8 +268,8 @@ export const PaymentInfo$outboundSchema: z.ZodType<
266
268
  z.ZodTypeDef,
267
269
  PaymentInfo
268
270
  > = z.union([
269
- components.JuspayPaymentInfo$outboundSchema,
270
271
  components.PayuPaymentInfo$outboundSchema,
272
+ components.JuspayPaymentInfo$outboundSchema,
271
273
  ]);
272
274
 
273
275
  /**
@@ -306,8 +308,8 @@ export const CreateOrderContent$inboundSchema: z.ZodType<
306
308
  order: components.Order$inboundSchema,
307
309
  payment_required: z.boolean(),
308
310
  payment_info: z.union([
309
- components.JuspayPaymentInfo$inboundSchema,
310
311
  components.PayuPaymentInfo$inboundSchema,
312
+ components.JuspayPaymentInfo$inboundSchema,
311
313
  ]),
312
314
  }).transform((v) => {
313
315
  return remap$(v, {
@@ -321,8 +323,8 @@ export type CreateOrderContent$Outbound = {
321
323
  order: components.Order$Outbound;
322
324
  payment_required: boolean;
323
325
  payment_info:
324
- | components.JuspayPaymentInfo$Outbound
325
- | components.PayuPaymentInfo$Outbound;
326
+ | components.PayuPaymentInfo$Outbound
327
+ | components.JuspayPaymentInfo$Outbound;
326
328
  };
327
329
 
328
330
  /** @internal */
@@ -334,8 +336,8 @@ export const CreateOrderContent$outboundSchema: z.ZodType<
334
336
  order: components.Order$outboundSchema,
335
337
  paymentRequired: z.boolean(),
336
338
  paymentInfo: z.union([
337
- components.JuspayPaymentInfo$outboundSchema,
338
339
  components.PayuPaymentInfo$outboundSchema,
340
+ components.JuspayPaymentInfo$outboundSchema,
339
341
  ]),
340
342
  }).transform((v) => {
341
343
  return remap$(v, {
@@ -10,8 +10,8 @@ import * as components from "../components/index.js";
10
10
  import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
11
 
12
12
  export type GenerateOtpRequestBody =
13
- | components.GenerateOtpWithEmail
14
- | components.GenerateOtpWithPhone;
13
+ | components.GenerateOtpWithPhone
14
+ | components.GenerateOtpWithEmail;
15
15
 
16
16
  /**
17
17
  * An object containing the response content.
@@ -51,14 +51,14 @@ export const GenerateOtpRequestBody$inboundSchema: z.ZodType<
51
51
  z.ZodTypeDef,
52
52
  unknown
53
53
  > = z.union([
54
- components.GenerateOtpWithEmail$inboundSchema,
55
54
  components.GenerateOtpWithPhone$inboundSchema,
55
+ components.GenerateOtpWithEmail$inboundSchema,
56
56
  ]);
57
57
 
58
58
  /** @internal */
59
59
  export type GenerateOtpRequestBody$Outbound =
60
- | components.GenerateOtpWithEmail$Outbound
61
- | components.GenerateOtpWithPhone$Outbound;
60
+ | components.GenerateOtpWithPhone$Outbound
61
+ | components.GenerateOtpWithEmail$Outbound;
62
62
 
63
63
  /** @internal */
64
64
  export const GenerateOtpRequestBody$outboundSchema: z.ZodType<
@@ -66,8 +66,8 @@ export const GenerateOtpRequestBody$outboundSchema: z.ZodType<
66
66
  z.ZodTypeDef,
67
67
  GenerateOtpRequestBody
68
68
  > = z.union([
69
- components.GenerateOtpWithEmail$outboundSchema,
70
69
  components.GenerateOtpWithPhone$outboundSchema,
70
+ components.GenerateOtpWithEmail$outboundSchema,
71
71
  ]);
72
72
 
73
73
  /**
@@ -153,7 +153,7 @@ export const Address$inboundSchema: z.ZodType<Address, z.ZodTypeDef, unknown> =
153
153
  pincode: z.string(),
154
154
  city: z.string(),
155
155
  state: z.string(),
156
- country: z.literal("India").optional(),
156
+ country: z.literal("India").default("India").optional(),
157
157
  tax_identification_number: z.nullable(z.string()),
158
158
  business_name: z.nullable(z.string()),
159
159
  is_phone_verified: z.boolean(),
@@ -15,9 +15,9 @@ export type GetProductDetailRequest = {
15
15
  */
16
16
  productIdOrSlug: string;
17
17
  /**
18
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
18
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
19
19
  */
20
- customerGroupId?: string | undefined;
20
+ xCustomerGroupId?: string | undefined;
21
21
  };
22
22
 
23
23
  export type GetProductDetailContent = {
@@ -40,18 +40,18 @@ export const GetProductDetailRequest$inboundSchema: z.ZodType<
40
40
  unknown
41
41
  > = z.object({
42
42
  product_id_or_slug: z.string(),
43
- customer_group_id: z.string().optional(),
43
+ "x-customer-group-id": z.string().optional(),
44
44
  }).transform((v) => {
45
45
  return remap$(v, {
46
46
  "product_id_or_slug": "productIdOrSlug",
47
- "customer_group_id": "customerGroupId",
47
+ "x-customer-group-id": "xCustomerGroupId",
48
48
  });
49
49
  });
50
50
 
51
51
  /** @internal */
52
52
  export type GetProductDetailRequest$Outbound = {
53
53
  product_id_or_slug: string;
54
- customer_group_id?: string | undefined;
54
+ "x-customer-group-id"?: string | undefined;
55
55
  };
56
56
 
57
57
  /** @internal */
@@ -61,11 +61,11 @@ export const GetProductDetailRequest$outboundSchema: z.ZodType<
61
61
  GetProductDetailRequest
62
62
  > = z.object({
63
63
  productIdOrSlug: z.string(),
64
- customerGroupId: z.string().optional(),
64
+ xCustomerGroupId: z.string().optional(),
65
65
  }).transform((v) => {
66
66
  return remap$(v, {
67
67
  productIdOrSlug: "product_id_or_slug",
68
- customerGroupId: "customer_group_id",
68
+ xCustomerGroupId: "x-customer-group-id",
69
69
  });
70
70
  });
71
71
 
@@ -19,9 +19,9 @@ export type GetVariantDetailRequest = {
19
19
  */
20
20
  variantId: string;
21
21
  /**
22
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
22
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
23
23
  */
24
- customerGroupId?: string | undefined;
24
+ xCustomerGroupId?: string | undefined;
25
25
  };
26
26
 
27
27
  export type GetVariantDetailContent = {
@@ -45,12 +45,12 @@ export const GetVariantDetailRequest$inboundSchema: z.ZodType<
45
45
  > = z.object({
46
46
  product_id: z.string(),
47
47
  variant_id: z.string(),
48
- customer_group_id: z.string().optional(),
48
+ "x-customer-group-id": z.string().optional(),
49
49
  }).transform((v) => {
50
50
  return remap$(v, {
51
51
  "product_id": "productId",
52
52
  "variant_id": "variantId",
53
- "customer_group_id": "customerGroupId",
53
+ "x-customer-group-id": "xCustomerGroupId",
54
54
  });
55
55
  });
56
56
 
@@ -58,7 +58,7 @@ export const GetVariantDetailRequest$inboundSchema: z.ZodType<
58
58
  export type GetVariantDetailRequest$Outbound = {
59
59
  product_id: string;
60
60
  variant_id: string;
61
- customer_group_id?: string | undefined;
61
+ "x-customer-group-id"?: string | undefined;
62
62
  };
63
63
 
64
64
  /** @internal */
@@ -69,12 +69,12 @@ export const GetVariantDetailRequest$outboundSchema: z.ZodType<
69
69
  > = z.object({
70
70
  productId: z.string(),
71
71
  variantId: z.string(),
72
- customerGroupId: z.string().optional(),
72
+ xCustomerGroupId: z.string().optional(),
73
73
  }).transform((v) => {
74
74
  return remap$(v, {
75
75
  productId: "product_id",
76
76
  variantId: "variant_id",
77
- customerGroupId: "customer_group_id",
77
+ xCustomerGroupId: "x-customer-group-id",
78
78
  });
79
79
  });
80
80
 
@@ -166,7 +166,7 @@ export const Addresses$inboundSchema: z.ZodType<
166
166
  pincode: z.string(),
167
167
  city: z.string(),
168
168
  state: z.string(),
169
- country: z.literal("India").optional(),
169
+ country: z.literal("India").default("India").optional(),
170
170
  tax_identification_number: z.nullable(z.string()),
171
171
  business_name: z.nullable(z.string()),
172
172
  is_phone_verified: z.boolean(),
@@ -27,9 +27,9 @@ export type ListCrosssellProductsRequest = {
27
27
  */
28
28
  sortBy?: string | undefined;
29
29
  /**
30
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
30
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
31
31
  */
32
- customerGroupId?: string | undefined;
32
+ xCustomerGroupId?: string | undefined;
33
33
  };
34
34
 
35
35
  export type ListCrosssellProductsContent = {
@@ -59,12 +59,12 @@ export const ListCrosssellProductsRequest$inboundSchema: z.ZodType<
59
59
  page: z.number().int().optional(),
60
60
  limit: z.number().int().optional(),
61
61
  sort_by: z.string().optional(),
62
- customer_group_id: z.string().optional(),
62
+ "x-customer-group-id": z.string().optional(),
63
63
  }).transform((v) => {
64
64
  return remap$(v, {
65
65
  "product_id": "productId",
66
66
  "sort_by": "sortBy",
67
- "customer_group_id": "customerGroupId",
67
+ "x-customer-group-id": "xCustomerGroupId",
68
68
  });
69
69
  });
70
70
 
@@ -74,7 +74,7 @@ export type ListCrosssellProductsRequest$Outbound = {
74
74
  page?: number | undefined;
75
75
  limit?: number | undefined;
76
76
  sort_by?: string | undefined;
77
- customer_group_id?: string | undefined;
77
+ "x-customer-group-id"?: string | undefined;
78
78
  };
79
79
 
80
80
  /** @internal */
@@ -87,12 +87,12 @@ export const ListCrosssellProductsRequest$outboundSchema: z.ZodType<
87
87
  page: z.number().int().optional(),
88
88
  limit: z.number().int().optional(),
89
89
  sortBy: z.string().optional(),
90
- customerGroupId: z.string().optional(),
90
+ xCustomerGroupId: z.string().optional(),
91
91
  }).transform((v) => {
92
92
  return remap$(v, {
93
93
  productId: "product_id",
94
94
  sortBy: "sort_by",
95
- customerGroupId: "customer_group_id",
95
+ xCustomerGroupId: "x-customer-group-id",
96
96
  });
97
97
  });
98
98
 
@@ -27,9 +27,9 @@ export type ListProductsRequest = {
27
27
  */
28
28
  categoryId?: Array<string> | undefined;
29
29
  /**
30
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
30
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
31
31
  */
32
- customerGroupId?: string | undefined;
32
+ xCustomerGroupId?: string | undefined;
33
33
  /**
34
34
  * filter products by categories slugs
35
35
  */
@@ -63,13 +63,13 @@ export const ListProductsRequest$inboundSchema: z.ZodType<
63
63
  limit: z.number().int().optional(),
64
64
  sort_by: z.string().optional(),
65
65
  category_id: z.array(z.string()).optional(),
66
- customer_group_id: z.string().optional(),
66
+ "x-customer-group-id": z.string().optional(),
67
67
  category_slug: z.array(z.string()).optional(),
68
68
  }).transform((v) => {
69
69
  return remap$(v, {
70
70
  "sort_by": "sortBy",
71
71
  "category_id": "categoryId",
72
- "customer_group_id": "customerGroupId",
72
+ "x-customer-group-id": "xCustomerGroupId",
73
73
  "category_slug": "categorySlug",
74
74
  });
75
75
  });
@@ -80,7 +80,7 @@ export type ListProductsRequest$Outbound = {
80
80
  limit?: number | undefined;
81
81
  sort_by?: string | undefined;
82
82
  category_id?: Array<string> | undefined;
83
- customer_group_id?: string | undefined;
83
+ "x-customer-group-id"?: string | undefined;
84
84
  category_slug?: Array<string> | undefined;
85
85
  };
86
86
 
@@ -94,13 +94,13 @@ export const ListProductsRequest$outboundSchema: z.ZodType<
94
94
  limit: z.number().int().optional(),
95
95
  sortBy: z.string().optional(),
96
96
  categoryId: z.array(z.string()).optional(),
97
- customerGroupId: z.string().optional(),
97
+ xCustomerGroupId: z.string().optional(),
98
98
  categorySlug: z.array(z.string()).optional(),
99
99
  }).transform((v) => {
100
100
  return remap$(v, {
101
101
  sortBy: "sort_by",
102
102
  categoryId: "category_id",
103
- customerGroupId: "customer_group_id",
103
+ xCustomerGroupId: "x-customer-group-id",
104
104
  categorySlug: "category_slug",
105
105
  });
106
106
  });
@@ -15,9 +15,9 @@ export type ListProductVariantsRequest = {
15
15
  */
16
16
  productId: string;
17
17
  /**
18
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
18
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
19
19
  */
20
- customerGroupId?: string | undefined;
20
+ xCustomerGroupId?: string | undefined;
21
21
  };
22
22
 
23
23
  export type ListProductVariantsContent = {
@@ -40,18 +40,18 @@ export const ListProductVariantsRequest$inboundSchema: z.ZodType<
40
40
  unknown
41
41
  > = z.object({
42
42
  product_id: z.string(),
43
- customer_group_id: z.string().optional(),
43
+ "x-customer-group-id": z.string().optional(),
44
44
  }).transform((v) => {
45
45
  return remap$(v, {
46
46
  "product_id": "productId",
47
- "customer_group_id": "customerGroupId",
47
+ "x-customer-group-id": "xCustomerGroupId",
48
48
  });
49
49
  });
50
50
 
51
51
  /** @internal */
52
52
  export type ListProductVariantsRequest$Outbound = {
53
53
  product_id: string;
54
- customer_group_id?: string | undefined;
54
+ "x-customer-group-id"?: string | undefined;
55
55
  };
56
56
 
57
57
  /** @internal */
@@ -61,11 +61,11 @@ export const ListProductVariantsRequest$outboundSchema: z.ZodType<
61
61
  ListProductVariantsRequest
62
62
  > = z.object({
63
63
  productId: z.string(),
64
- customerGroupId: z.string().optional(),
64
+ xCustomerGroupId: z.string().optional(),
65
65
  }).transform((v) => {
66
66
  return remap$(v, {
67
67
  productId: "product_id",
68
- customerGroupId: "customer_group_id",
68
+ xCustomerGroupId: "x-customer-group-id",
69
69
  });
70
70
  });
71
71
 
@@ -27,9 +27,9 @@ export type ListSimilarProductsRequest = {
27
27
  */
28
28
  sortBy?: string | undefined;
29
29
  /**
30
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
30
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
31
31
  */
32
- customerGroupId?: string | undefined;
32
+ xCustomerGroupId?: string | undefined;
33
33
  };
34
34
 
35
35
  export type ListSimilarProductsContent = {
@@ -59,12 +59,12 @@ export const ListSimilarProductsRequest$inboundSchema: z.ZodType<
59
59
  page: z.number().int().optional(),
60
60
  limit: z.number().int().optional(),
61
61
  sort_by: z.string().optional(),
62
- customer_group_id: z.string().optional(),
62
+ "x-customer-group-id": z.string().optional(),
63
63
  }).transform((v) => {
64
64
  return remap$(v, {
65
65
  "product_id": "productId",
66
66
  "sort_by": "sortBy",
67
- "customer_group_id": "customerGroupId",
67
+ "x-customer-group-id": "xCustomerGroupId",
68
68
  });
69
69
  });
70
70
 
@@ -74,7 +74,7 @@ export type ListSimilarProductsRequest$Outbound = {
74
74
  page?: number | undefined;
75
75
  limit?: number | undefined;
76
76
  sort_by?: string | undefined;
77
- customer_group_id?: string | undefined;
77
+ "x-customer-group-id"?: string | undefined;
78
78
  };
79
79
 
80
80
  /** @internal */
@@ -87,12 +87,12 @@ export const ListSimilarProductsRequest$outboundSchema: z.ZodType<
87
87
  page: z.number().int().optional(),
88
88
  limit: z.number().int().optional(),
89
89
  sortBy: z.string().optional(),
90
- customerGroupId: z.string().optional(),
90
+ xCustomerGroupId: z.string().optional(),
91
91
  }).transform((v) => {
92
92
  return remap$(v, {
93
93
  productId: "product_id",
94
94
  sortBy: "sort_by",
95
- customerGroupId: "customer_group_id",
95
+ xCustomerGroupId: "x-customer-group-id",
96
96
  });
97
97
  });
98
98
 
@@ -31,9 +31,9 @@ export type ListSkusRequest = {
31
31
  */
32
32
  sku?: Array<string> | undefined;
33
33
  /**
34
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
34
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
35
35
  */
36
- customerGroupId?: string | undefined;
36
+ xCustomerGroupId?: string | undefined;
37
37
  };
38
38
 
39
39
  export type ListSkusContent = {
@@ -64,12 +64,12 @@ export const ListSkusRequest$inboundSchema: z.ZodType<
64
64
  sort_by: z.string().optional(),
65
65
  category_id: z.array(z.string()).optional(),
66
66
  sku: z.array(z.string()).optional(),
67
- customer_group_id: z.string().optional(),
67
+ "x-customer-group-id": z.string().optional(),
68
68
  }).transform((v) => {
69
69
  return remap$(v, {
70
70
  "sort_by": "sortBy",
71
71
  "category_id": "categoryId",
72
- "customer_group_id": "customerGroupId",
72
+ "x-customer-group-id": "xCustomerGroupId",
73
73
  });
74
74
  });
75
75
 
@@ -80,7 +80,7 @@ export type ListSkusRequest$Outbound = {
80
80
  sort_by?: string | undefined;
81
81
  category_id?: Array<string> | undefined;
82
82
  sku?: Array<string> | undefined;
83
- customer_group_id?: string | undefined;
83
+ "x-customer-group-id"?: string | undefined;
84
84
  };
85
85
 
86
86
  /** @internal */
@@ -94,12 +94,12 @@ export const ListSkusRequest$outboundSchema: z.ZodType<
94
94
  sortBy: z.string().optional(),
95
95
  categoryId: z.array(z.string()).optional(),
96
96
  sku: z.array(z.string()).optional(),
97
- customerGroupId: z.string().optional(),
97
+ xCustomerGroupId: z.string().optional(),
98
98
  }).transform((v) => {
99
99
  return remap$(v, {
100
100
  sortBy: "sort_by",
101
101
  categoryId: "category_id",
102
- customerGroupId: "customer_group_id",
102
+ xCustomerGroupId: "x-customer-group-id",
103
103
  });
104
104
  });
105
105
 
@@ -27,9 +27,9 @@ export type ListUpsellProductsRequest = {
27
27
  */
28
28
  sortBy?: string | undefined;
29
29
  /**
30
- * The customer_group_id is used to determine product pricing, promotions, and subscription rates. If a valid customer_group_id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer_group_id, the system will fall back to the default customer_group_id. If no data is found for the default group either, the highest applicable price will be returned.
30
+ * This param is used to determine product pricing, promotions, and subscription rates. If a valid customer group id is provided, pricing details will be retrieved accordingly. If no matching data is found for the specified customer group id, the system will fall back to the default customer group id. If no data is found for the default group either, the highest applicable price will be returned.
31
31
  */
32
- customerGroupId?: string | undefined;
32
+ xCustomerGroupId?: string | undefined;
33
33
  };
34
34
 
35
35
  export type ListUpsellProductsContent = {
@@ -62,12 +62,12 @@ export const ListUpsellProductsRequest$inboundSchema: z.ZodType<
62
62
  page: z.number().int().optional(),
63
63
  limit: z.number().int().optional(),
64
64
  sort_by: z.string().optional(),
65
- customer_group_id: z.string().optional(),
65
+ "x-customer-group-id": z.string().optional(),
66
66
  }).transform((v) => {
67
67
  return remap$(v, {
68
68
  "product_id": "productId",
69
69
  "sort_by": "sortBy",
70
- "customer_group_id": "customerGroupId",
70
+ "x-customer-group-id": "xCustomerGroupId",
71
71
  });
72
72
  });
73
73
 
@@ -77,7 +77,7 @@ export type ListUpsellProductsRequest$Outbound = {
77
77
  page?: number | undefined;
78
78
  limit?: number | undefined;
79
79
  sort_by?: string | undefined;
80
- customer_group_id?: string | undefined;
80
+ "x-customer-group-id"?: string | undefined;
81
81
  };
82
82
 
83
83
  /** @internal */
@@ -90,12 +90,12 @@ export const ListUpsellProductsRequest$outboundSchema: z.ZodType<
90
90
  page: z.number().int().optional(),
91
91
  limit: z.number().int().optional(),
92
92
  sortBy: z.string().optional(),
93
- customerGroupId: z.string().optional(),
93
+ xCustomerGroupId: z.string().optional(),
94
94
  }).transform((v) => {
95
95
  return remap$(v, {
96
96
  productId: "product_id",
97
97
  sortBy: "sort_by",
98
- customerGroupId: "customer_group_id",
98
+ xCustomerGroupId: "x-customer-group-id",
99
99
  });
100
100
  });
101
101
 
@@ -65,7 +65,7 @@ export const LoginWithWhatsappRequestBody$inboundSchema: z.ZodType<
65
65
  z.ZodTypeDef,
66
66
  unknown
67
67
  > = z.object({
68
- country_code: z.literal("+91").optional(),
68
+ country_code: z.literal("+91").default("+91").optional(),
69
69
  phone: z.string(),
70
70
  register_if_not_exists: z.boolean().optional(),
71
71
  }).transform((v) => {