ce-storefront 0.7.3 → 0.8.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 (669) hide show
  1. package/README.md +93 -7
  2. package/bin/mcp-server.js +50005 -0
  3. package/bin/mcp-server.js.map +465 -0
  4. package/docs/sdks/catalog/README.md +0 -90
  5. package/esm/funcs/authCheckVerificationStatus.d.ts +2 -1
  6. package/esm/funcs/authCheckVerificationStatus.d.ts.map +1 -1
  7. package/esm/funcs/authCheckVerificationStatus.js +11 -7
  8. package/esm/funcs/authCheckVerificationStatus.js.map +1 -1
  9. package/esm/funcs/authCreateNotificationPreferences.d.ts +2 -1
  10. package/esm/funcs/authCreateNotificationPreferences.d.ts.map +1 -1
  11. package/esm/funcs/authCreateNotificationPreferences.js +11 -7
  12. package/esm/funcs/authCreateNotificationPreferences.js.map +1 -1
  13. package/esm/funcs/authGenerateOtp.d.ts +2 -1
  14. package/esm/funcs/authGenerateOtp.d.ts.map +1 -1
  15. package/esm/funcs/authGenerateOtp.js +11 -7
  16. package/esm/funcs/authGenerateOtp.js.map +1 -1
  17. package/esm/funcs/authGetAnonymousToken.d.ts +2 -1
  18. package/esm/funcs/authGetAnonymousToken.d.ts.map +1 -1
  19. package/esm/funcs/authGetAnonymousToken.js +10 -6
  20. package/esm/funcs/authGetAnonymousToken.js.map +1 -1
  21. package/esm/funcs/authGetNotificationPreferences.d.ts +2 -1
  22. package/esm/funcs/authGetNotificationPreferences.d.ts.map +1 -1
  23. package/esm/funcs/authGetNotificationPreferences.js +11 -7
  24. package/esm/funcs/authGetNotificationPreferences.js.map +1 -1
  25. package/esm/funcs/authGetUserDetail.d.ts +2 -1
  26. package/esm/funcs/authGetUserDetail.d.ts.map +1 -1
  27. package/esm/funcs/authGetUserDetail.js +11 -7
  28. package/esm/funcs/authGetUserDetail.js.map +1 -1
  29. package/esm/funcs/authLoginWithEmail.d.ts +2 -1
  30. package/esm/funcs/authLoginWithEmail.d.ts.map +1 -1
  31. package/esm/funcs/authLoginWithEmail.js +11 -7
  32. package/esm/funcs/authLoginWithEmail.js.map +1 -1
  33. package/esm/funcs/authLoginWithPhone.d.ts +2 -1
  34. package/esm/funcs/authLoginWithPhone.d.ts.map +1 -1
  35. package/esm/funcs/authLoginWithPhone.js +11 -7
  36. package/esm/funcs/authLoginWithPhone.js.map +1 -1
  37. package/esm/funcs/authLoginWithWhatsapp.d.ts +2 -1
  38. package/esm/funcs/authLoginWithWhatsapp.d.ts.map +1 -1
  39. package/esm/funcs/authLoginWithWhatsapp.js +11 -7
  40. package/esm/funcs/authLoginWithWhatsapp.js.map +1 -1
  41. package/esm/funcs/authLogout.d.ts +2 -1
  42. package/esm/funcs/authLogout.d.ts.map +1 -1
  43. package/esm/funcs/authLogout.js +10 -6
  44. package/esm/funcs/authLogout.js.map +1 -1
  45. package/esm/funcs/authRefreshToken.d.ts +2 -1
  46. package/esm/funcs/authRefreshToken.d.ts.map +1 -1
  47. package/esm/funcs/authRefreshToken.js +11 -7
  48. package/esm/funcs/authRefreshToken.js.map +1 -1
  49. package/esm/funcs/authUpdateNotificationPreferences.d.ts +2 -1
  50. package/esm/funcs/authUpdateNotificationPreferences.d.ts.map +1 -1
  51. package/esm/funcs/authUpdateNotificationPreferences.js +11 -7
  52. package/esm/funcs/authUpdateNotificationPreferences.js.map +1 -1
  53. package/esm/funcs/authUpdateUser.d.ts +2 -1
  54. package/esm/funcs/authUpdateUser.d.ts.map +1 -1
  55. package/esm/funcs/authUpdateUser.js +11 -7
  56. package/esm/funcs/authUpdateUser.js.map +1 -1
  57. package/esm/funcs/authVerifyOtp.d.ts +2 -1
  58. package/esm/funcs/authVerifyOtp.d.ts.map +1 -1
  59. package/esm/funcs/authVerifyOtp.js +11 -7
  60. package/esm/funcs/authVerifyOtp.js.map +1 -1
  61. package/esm/funcs/campaignsSubscribeNewsletter.d.ts +2 -1
  62. package/esm/funcs/campaignsSubscribeNewsletter.d.ts.map +1 -1
  63. package/esm/funcs/campaignsSubscribeNewsletter.js +11 -7
  64. package/esm/funcs/campaignsSubscribeNewsletter.js.map +1 -1
  65. package/esm/funcs/cartsApplyCoupon.d.ts +2 -1
  66. package/esm/funcs/cartsApplyCoupon.d.ts.map +1 -1
  67. package/esm/funcs/cartsApplyCoupon.js +11 -7
  68. package/esm/funcs/cartsApplyCoupon.js.map +1 -1
  69. package/esm/funcs/cartsCreateCart.d.ts +2 -1
  70. package/esm/funcs/cartsCreateCart.d.ts.map +1 -1
  71. package/esm/funcs/cartsCreateCart.js +11 -7
  72. package/esm/funcs/cartsCreateCart.js.map +1 -1
  73. package/esm/funcs/cartsCreateCartAddress.d.ts +2 -1
  74. package/esm/funcs/cartsCreateCartAddress.d.ts.map +1 -1
  75. package/esm/funcs/cartsCreateCartAddress.js +11 -7
  76. package/esm/funcs/cartsCreateCartAddress.js.map +1 -1
  77. package/esm/funcs/cartsDeleteCart.d.ts +2 -1
  78. package/esm/funcs/cartsDeleteCart.d.ts.map +1 -1
  79. package/esm/funcs/cartsDeleteCart.js +11 -7
  80. package/esm/funcs/cartsDeleteCart.js.map +1 -1
  81. package/esm/funcs/cartsGetCart.d.ts +2 -1
  82. package/esm/funcs/cartsGetCart.d.ts.map +1 -1
  83. package/esm/funcs/cartsGetCart.js +11 -7
  84. package/esm/funcs/cartsGetCart.js.map +1 -1
  85. package/esm/funcs/cartsGetUserCart.d.ts +2 -1
  86. package/esm/funcs/cartsGetUserCart.d.ts.map +1 -1
  87. package/esm/funcs/cartsGetUserCart.js +11 -7
  88. package/esm/funcs/cartsGetUserCart.js.map +1 -1
  89. package/esm/funcs/cartsRemoveCoupon.d.ts +2 -1
  90. package/esm/funcs/cartsRemoveCoupon.d.ts.map +1 -1
  91. package/esm/funcs/cartsRemoveCoupon.js +11 -7
  92. package/esm/funcs/cartsRemoveCoupon.js.map +1 -1
  93. package/esm/funcs/cartsRemoveUserCart.d.ts +2 -1
  94. package/esm/funcs/cartsRemoveUserCart.d.ts.map +1 -1
  95. package/esm/funcs/cartsRemoveUserCart.js +11 -7
  96. package/esm/funcs/cartsRemoveUserCart.js.map +1 -1
  97. package/esm/funcs/cartsUpdateCart.d.ts +2 -1
  98. package/esm/funcs/cartsUpdateCart.d.ts.map +1 -1
  99. package/esm/funcs/cartsUpdateCart.js +11 -7
  100. package/esm/funcs/cartsUpdateCart.js.map +1 -1
  101. package/esm/funcs/catalogGetProductDetail.d.ts +2 -1
  102. package/esm/funcs/catalogGetProductDetail.d.ts.map +1 -1
  103. package/esm/funcs/catalogGetProductDetail.js +11 -7
  104. package/esm/funcs/catalogGetProductDetail.js.map +1 -1
  105. package/esm/funcs/catalogGetVariantDetail.d.ts +2 -1
  106. package/esm/funcs/catalogGetVariantDetail.d.ts.map +1 -1
  107. package/esm/funcs/catalogGetVariantDetail.js +11 -7
  108. package/esm/funcs/catalogGetVariantDetail.js.map +1 -1
  109. package/esm/funcs/catalogListCategories.d.ts +2 -1
  110. package/esm/funcs/catalogListCategories.d.ts.map +1 -1
  111. package/esm/funcs/catalogListCategories.js +11 -7
  112. package/esm/funcs/catalogListCategories.js.map +1 -1
  113. package/esm/funcs/catalogListCrosssellProducts.d.ts +2 -1
  114. package/esm/funcs/catalogListCrosssellProducts.d.ts.map +1 -1
  115. package/esm/funcs/catalogListCrosssellProducts.js +11 -7
  116. package/esm/funcs/catalogListCrosssellProducts.js.map +1 -1
  117. package/esm/funcs/catalogListProductReviews.d.ts +2 -1
  118. package/esm/funcs/catalogListProductReviews.d.ts.map +1 -1
  119. package/esm/funcs/catalogListProductReviews.js +11 -7
  120. package/esm/funcs/catalogListProductReviews.js.map +1 -1
  121. package/esm/funcs/catalogListProductVariants.d.ts +2 -1
  122. package/esm/funcs/catalogListProductVariants.d.ts.map +1 -1
  123. package/esm/funcs/catalogListProductVariants.js +11 -7
  124. package/esm/funcs/catalogListProductVariants.js.map +1 -1
  125. package/esm/funcs/catalogListProducts.d.ts +2 -1
  126. package/esm/funcs/catalogListProducts.d.ts.map +1 -1
  127. package/esm/funcs/catalogListProducts.js +11 -7
  128. package/esm/funcs/catalogListProducts.js.map +1 -1
  129. package/esm/funcs/catalogListSimilarProducts.d.ts +2 -1
  130. package/esm/funcs/catalogListSimilarProducts.d.ts.map +1 -1
  131. package/esm/funcs/catalogListSimilarProducts.js +11 -7
  132. package/esm/funcs/catalogListSimilarProducts.js.map +1 -1
  133. package/esm/funcs/catalogListSkus.d.ts +2 -1
  134. package/esm/funcs/catalogListSkus.d.ts.map +1 -1
  135. package/esm/funcs/catalogListSkus.js +11 -7
  136. package/esm/funcs/catalogListSkus.js.map +1 -1
  137. package/esm/funcs/catalogListUpsellProducts.d.ts +2 -1
  138. package/esm/funcs/catalogListUpsellProducts.d.ts.map +1 -1
  139. package/esm/funcs/catalogListUpsellProducts.js +11 -7
  140. package/esm/funcs/catalogListUpsellProducts.js.map +1 -1
  141. package/esm/funcs/catalogSearchProducts.d.ts +2 -1
  142. package/esm/funcs/catalogSearchProducts.d.ts.map +1 -1
  143. package/esm/funcs/catalogSearchProducts.js +11 -7
  144. package/esm/funcs/catalogSearchProducts.js.map +1 -1
  145. package/esm/funcs/commonListCountryPincodes.d.ts +2 -1
  146. package/esm/funcs/commonListCountryPincodes.d.ts.map +1 -1
  147. package/esm/funcs/commonListCountryPincodes.js +11 -7
  148. package/esm/funcs/commonListCountryPincodes.js.map +1 -1
  149. package/esm/funcs/customersCreateAddress.d.ts +2 -1
  150. package/esm/funcs/customersCreateAddress.d.ts.map +1 -1
  151. package/esm/funcs/customersCreateAddress.js +11 -7
  152. package/esm/funcs/customersCreateAddress.js.map +1 -1
  153. package/esm/funcs/customersDeleteAddress.d.ts +2 -1
  154. package/esm/funcs/customersDeleteAddress.d.ts.map +1 -1
  155. package/esm/funcs/customersDeleteAddress.js +11 -7
  156. package/esm/funcs/customersDeleteAddress.js.map +1 -1
  157. package/esm/funcs/customersGetAddressDetail.d.ts +2 -1
  158. package/esm/funcs/customersGetAddressDetail.d.ts.map +1 -1
  159. package/esm/funcs/customersGetAddressDetail.js +11 -7
  160. package/esm/funcs/customersGetAddressDetail.js.map +1 -1
  161. package/esm/funcs/customersListAddresses.d.ts +2 -1
  162. package/esm/funcs/customersListAddresses.d.ts.map +1 -1
  163. package/esm/funcs/customersListAddresses.js +11 -7
  164. package/esm/funcs/customersListAddresses.js.map +1 -1
  165. package/esm/funcs/customersListUserReviews.d.ts +2 -1
  166. package/esm/funcs/customersListUserReviews.d.ts.map +1 -1
  167. package/esm/funcs/customersListUserReviews.js +11 -7
  168. package/esm/funcs/customersListUserReviews.js.map +1 -1
  169. package/esm/funcs/customersUpdateAddressDetail.d.ts +2 -1
  170. package/esm/funcs/customersUpdateAddressDetail.d.ts.map +1 -1
  171. package/esm/funcs/customersUpdateAddressDetail.js +11 -7
  172. package/esm/funcs/customersUpdateAddressDetail.js.map +1 -1
  173. package/esm/funcs/ordersCancelOrder.d.ts +2 -1
  174. package/esm/funcs/ordersCancelOrder.d.ts.map +1 -1
  175. package/esm/funcs/ordersCancelOrder.js +11 -7
  176. package/esm/funcs/ordersCancelOrder.js.map +1 -1
  177. package/esm/funcs/ordersCreateOrder.d.ts +2 -1
  178. package/esm/funcs/ordersCreateOrder.d.ts.map +1 -1
  179. package/esm/funcs/ordersCreateOrder.js +11 -7
  180. package/esm/funcs/ordersCreateOrder.js.map +1 -1
  181. package/esm/funcs/ordersGetOrderDetail.d.ts +2 -1
  182. package/esm/funcs/ordersGetOrderDetail.d.ts.map +1 -1
  183. package/esm/funcs/ordersGetOrderDetail.js +11 -7
  184. package/esm/funcs/ordersGetOrderDetail.js.map +1 -1
  185. package/esm/funcs/ordersGetPaymentStatus.d.ts +2 -1
  186. package/esm/funcs/ordersGetPaymentStatus.d.ts.map +1 -1
  187. package/esm/funcs/ordersGetPaymentStatus.js +11 -7
  188. package/esm/funcs/ordersGetPaymentStatus.js.map +1 -1
  189. package/esm/funcs/ordersListOrderShipments.d.ts +2 -1
  190. package/esm/funcs/ordersListOrderShipments.d.ts.map +1 -1
  191. package/esm/funcs/ordersListOrderShipments.js +11 -7
  192. package/esm/funcs/ordersListOrderShipments.js.map +1 -1
  193. package/esm/funcs/ordersListOrders.d.ts +2 -1
  194. package/esm/funcs/ordersListOrders.d.ts.map +1 -1
  195. package/esm/funcs/ordersListOrders.js +11 -7
  196. package/esm/funcs/ordersListOrders.js.map +1 -1
  197. package/esm/funcs/ordersRetryOrderPayment.d.ts +2 -1
  198. package/esm/funcs/ordersRetryOrderPayment.d.ts.map +1 -1
  199. package/esm/funcs/ordersRetryOrderPayment.js +11 -7
  200. package/esm/funcs/ordersRetryOrderPayment.js.map +1 -1
  201. package/esm/funcs/shippingCheckDeliveryAvailability.d.ts +2 -1
  202. package/esm/funcs/shippingCheckDeliveryAvailability.d.ts.map +1 -1
  203. package/esm/funcs/shippingCheckDeliveryAvailability.js +11 -7
  204. package/esm/funcs/shippingCheckDeliveryAvailability.js.map +1 -1
  205. package/esm/hooks/types.d.ts +1 -1
  206. package/esm/hooks/types.d.ts.map +1 -1
  207. package/esm/lib/config.d.ts +7 -7
  208. package/esm/lib/config.d.ts.map +1 -1
  209. package/esm/lib/config.js +3 -3
  210. package/esm/lib/files.js.map +1 -1
  211. package/esm/lib/primitives.d.ts +3 -0
  212. package/esm/lib/primitives.d.ts.map +1 -1
  213. package/esm/lib/primitives.js +6 -0
  214. package/esm/lib/primitives.js.map +1 -1
  215. package/esm/lib/sdks.d.ts +1 -1
  216. package/esm/lib/sdks.d.ts.map +1 -1
  217. package/esm/lib/sdks.js +2 -8
  218. package/esm/lib/sdks.js.map +1 -1
  219. package/esm/lib/security.d.ts +4 -3
  220. package/esm/lib/security.d.ts.map +1 -1
  221. package/esm/lib/security.js +6 -1
  222. package/esm/lib/security.js.map +1 -1
  223. package/esm/mcp-server/build.d.mts.map +1 -0
  224. package/esm/mcp-server/build.mjs +14 -0
  225. package/esm/mcp-server/build.mjs.map +1 -0
  226. package/esm/mcp-server/cli/start/command.d.ts +2 -0
  227. package/esm/mcp-server/cli/start/command.d.ts.map +1 -0
  228. package/esm/mcp-server/cli/start/command.js +108 -0
  229. package/esm/mcp-server/cli/start/command.js.map +1 -0
  230. package/esm/mcp-server/cli/start/impl.d.ts +19 -0
  231. package/esm/mcp-server/cli/start/impl.d.ts.map +1 -0
  232. package/esm/mcp-server/cli/start/impl.js +100 -0
  233. package/esm/mcp-server/cli/start/impl.js.map +1 -0
  234. package/esm/mcp-server/cli.d.ts +6 -0
  235. package/esm/mcp-server/cli.d.ts.map +1 -0
  236. package/esm/mcp-server/cli.js +7 -0
  237. package/esm/mcp-server/cli.js.map +1 -0
  238. package/esm/mcp-server/console-logger.d.ts +7 -0
  239. package/esm/mcp-server/console-logger.d.ts.map +1 -0
  240. package/esm/mcp-server/console-logger.js +55 -0
  241. package/esm/mcp-server/console-logger.js.map +1 -0
  242. package/esm/mcp-server/extensions.d.ts +11 -0
  243. package/esm/mcp-server/extensions.d.ts.map +1 -0
  244. package/esm/mcp-server/extensions.js +5 -0
  245. package/esm/mcp-server/extensions.js.map +1 -0
  246. package/esm/mcp-server/mcp-server.d.ts +2 -0
  247. package/esm/mcp-server/mcp-server.d.ts.map +1 -0
  248. package/esm/mcp-server/mcp-server.js +23 -0
  249. package/esm/mcp-server/mcp-server.js.map +1 -0
  250. package/esm/mcp-server/prompts.d.ts +26 -0
  251. package/esm/mcp-server/prompts.d.ts.map +1 -0
  252. package/esm/mcp-server/prompts.js +43 -0
  253. package/esm/mcp-server/prompts.js.map +1 -0
  254. package/esm/mcp-server/resources.d.ts +32 -0
  255. package/esm/mcp-server/resources.d.ts.map +1 -0
  256. package/esm/mcp-server/resources.js +74 -0
  257. package/esm/mcp-server/resources.js.map +1 -0
  258. package/esm/mcp-server/scopes.d.ts +3 -0
  259. package/esm/mcp-server/scopes.d.ts.map +1 -0
  260. package/esm/mcp-server/scopes.js +5 -0
  261. package/esm/mcp-server/scopes.js.map +1 -0
  262. package/esm/mcp-server/server.d.ts +14 -0
  263. package/esm/mcp-server/server.d.ts.map +1 -0
  264. package/esm/mcp-server/server.js +129 -0
  265. package/esm/mcp-server/server.js.map +1 -0
  266. package/esm/mcp-server/shared.d.ts +7 -0
  267. package/esm/mcp-server/shared.d.ts.map +1 -0
  268. package/esm/mcp-server/shared.js +59 -0
  269. package/esm/mcp-server/shared.js.map +1 -0
  270. package/esm/mcp-server/tools/authCheckVerificationStatus.d.ts +8 -0
  271. package/esm/mcp-server/tools/authCheckVerificationStatus.d.ts.map +1 -0
  272. package/esm/mcp-server/tools/authCheckVerificationStatus.js +28 -0
  273. package/esm/mcp-server/tools/authCheckVerificationStatus.js.map +1 -0
  274. package/esm/mcp-server/tools/authCreateNotificationPreferences.d.ts +8 -0
  275. package/esm/mcp-server/tools/authCreateNotificationPreferences.d.ts.map +1 -0
  276. package/esm/mcp-server/tools/authCreateNotificationPreferences.js +28 -0
  277. package/esm/mcp-server/tools/authCreateNotificationPreferences.js.map +1 -0
  278. package/esm/mcp-server/tools/authGenerateOtp.d.ts +8 -0
  279. package/esm/mcp-server/tools/authGenerateOtp.d.ts.map +1 -0
  280. package/esm/mcp-server/tools/authGenerateOtp.js +28 -0
  281. package/esm/mcp-server/tools/authGenerateOtp.js.map +1 -0
  282. package/esm/mcp-server/tools/authGetNotificationPreferences.d.ts +8 -0
  283. package/esm/mcp-server/tools/authGetNotificationPreferences.d.ts.map +1 -0
  284. package/esm/mcp-server/tools/authGetNotificationPreferences.js +28 -0
  285. package/esm/mcp-server/tools/authGetNotificationPreferences.js.map +1 -0
  286. package/esm/mcp-server/tools/authGetUserDetail.d.ts +8 -0
  287. package/esm/mcp-server/tools/authGetUserDetail.d.ts.map +1 -0
  288. package/esm/mcp-server/tools/authGetUserDetail.js +28 -0
  289. package/esm/mcp-server/tools/authGetUserDetail.js.map +1 -0
  290. package/esm/mcp-server/tools/authLoginWithEmail.d.ts +8 -0
  291. package/esm/mcp-server/tools/authLoginWithEmail.d.ts.map +1 -0
  292. package/esm/mcp-server/tools/authLoginWithEmail.js +28 -0
  293. package/esm/mcp-server/tools/authLoginWithEmail.js.map +1 -0
  294. package/esm/mcp-server/tools/authLoginWithPhone.d.ts +8 -0
  295. package/esm/mcp-server/tools/authLoginWithPhone.d.ts.map +1 -0
  296. package/esm/mcp-server/tools/authLoginWithPhone.js +28 -0
  297. package/esm/mcp-server/tools/authLoginWithPhone.js.map +1 -0
  298. package/esm/mcp-server/tools/authLoginWithWhatsapp.d.ts +8 -0
  299. package/esm/mcp-server/tools/authLoginWithWhatsapp.d.ts.map +1 -0
  300. package/esm/mcp-server/tools/authLoginWithWhatsapp.js +28 -0
  301. package/esm/mcp-server/tools/authLoginWithWhatsapp.js.map +1 -0
  302. package/esm/mcp-server/tools/authLogout.d.ts +3 -0
  303. package/esm/mcp-server/tools/authLogout.d.ts.map +1 -0
  304. package/esm/mcp-server/tools/authLogout.js +23 -0
  305. package/esm/mcp-server/tools/authLogout.js.map +1 -0
  306. package/esm/mcp-server/tools/authRefreshToken.d.ts +8 -0
  307. package/esm/mcp-server/tools/authRefreshToken.d.ts.map +1 -0
  308. package/esm/mcp-server/tools/authRefreshToken.js +28 -0
  309. package/esm/mcp-server/tools/authRefreshToken.js.map +1 -0
  310. package/esm/mcp-server/tools/authUpdateNotificationPreferences.d.ts +8 -0
  311. package/esm/mcp-server/tools/authUpdateNotificationPreferences.d.ts.map +1 -0
  312. package/esm/mcp-server/tools/authUpdateNotificationPreferences.js +28 -0
  313. package/esm/mcp-server/tools/authUpdateNotificationPreferences.js.map +1 -0
  314. package/esm/mcp-server/tools/authUpdateUser.d.ts +8 -0
  315. package/esm/mcp-server/tools/authUpdateUser.d.ts.map +1 -0
  316. package/esm/mcp-server/tools/authUpdateUser.js +28 -0
  317. package/esm/mcp-server/tools/authUpdateUser.js.map +1 -0
  318. package/esm/mcp-server/tools/authVerifyOtp.d.ts +8 -0
  319. package/esm/mcp-server/tools/authVerifyOtp.d.ts.map +1 -0
  320. package/esm/mcp-server/tools/authVerifyOtp.js +28 -0
  321. package/esm/mcp-server/tools/authVerifyOtp.js.map +1 -0
  322. package/esm/mcp-server/tools/campaignsSubscribeNewsletter.d.ts +8 -0
  323. package/esm/mcp-server/tools/campaignsSubscribeNewsletter.d.ts.map +1 -0
  324. package/esm/mcp-server/tools/campaignsSubscribeNewsletter.js +28 -0
  325. package/esm/mcp-server/tools/campaignsSubscribeNewsletter.js.map +1 -0
  326. package/esm/mcp-server/tools/cartsApplyCoupon.d.ts +8 -0
  327. package/esm/mcp-server/tools/cartsApplyCoupon.d.ts.map +1 -0
  328. package/esm/mcp-server/tools/cartsApplyCoupon.js +28 -0
  329. package/esm/mcp-server/tools/cartsApplyCoupon.js.map +1 -0
  330. package/esm/mcp-server/tools/cartsCreateCart.d.ts +8 -0
  331. package/esm/mcp-server/tools/cartsCreateCart.d.ts.map +1 -0
  332. package/esm/mcp-server/tools/cartsCreateCart.js +28 -0
  333. package/esm/mcp-server/tools/cartsCreateCart.js.map +1 -0
  334. package/esm/mcp-server/tools/cartsCreateCartAddress.d.ts +8 -0
  335. package/esm/mcp-server/tools/cartsCreateCartAddress.d.ts.map +1 -0
  336. package/esm/mcp-server/tools/cartsCreateCartAddress.js +28 -0
  337. package/esm/mcp-server/tools/cartsCreateCartAddress.js.map +1 -0
  338. package/esm/mcp-server/tools/cartsDeleteCart.d.ts +8 -0
  339. package/esm/mcp-server/tools/cartsDeleteCart.d.ts.map +1 -0
  340. package/esm/mcp-server/tools/cartsDeleteCart.js +28 -0
  341. package/esm/mcp-server/tools/cartsDeleteCart.js.map +1 -0
  342. package/esm/mcp-server/tools/cartsGetCart.d.ts +8 -0
  343. package/esm/mcp-server/tools/cartsGetCart.d.ts.map +1 -0
  344. package/esm/mcp-server/tools/cartsGetCart.js +28 -0
  345. package/esm/mcp-server/tools/cartsGetCart.js.map +1 -0
  346. package/esm/mcp-server/tools/cartsGetUserCart.d.ts +8 -0
  347. package/esm/mcp-server/tools/cartsGetUserCart.d.ts.map +1 -0
  348. package/esm/mcp-server/tools/cartsGetUserCart.js +28 -0
  349. package/esm/mcp-server/tools/cartsGetUserCart.js.map +1 -0
  350. package/esm/mcp-server/tools/cartsRemoveCoupon.d.ts +8 -0
  351. package/esm/mcp-server/tools/cartsRemoveCoupon.d.ts.map +1 -0
  352. package/esm/mcp-server/tools/cartsRemoveCoupon.js +28 -0
  353. package/esm/mcp-server/tools/cartsRemoveCoupon.js.map +1 -0
  354. package/esm/mcp-server/tools/cartsRemoveUserCart.d.ts +8 -0
  355. package/esm/mcp-server/tools/cartsRemoveUserCart.d.ts.map +1 -0
  356. package/esm/mcp-server/tools/cartsRemoveUserCart.js +28 -0
  357. package/esm/mcp-server/tools/cartsRemoveUserCart.js.map +1 -0
  358. package/esm/mcp-server/tools/cartsUpdateCart.d.ts +8 -0
  359. package/esm/mcp-server/tools/cartsUpdateCart.d.ts.map +1 -0
  360. package/esm/mcp-server/tools/cartsUpdateCart.js +28 -0
  361. package/esm/mcp-server/tools/cartsUpdateCart.js.map +1 -0
  362. package/esm/mcp-server/tools/catalogGetProductDetail.d.ts +8 -0
  363. package/esm/mcp-server/tools/catalogGetProductDetail.d.ts.map +1 -0
  364. package/esm/mcp-server/tools/catalogGetProductDetail.js +28 -0
  365. package/esm/mcp-server/tools/catalogGetProductDetail.js.map +1 -0
  366. package/esm/mcp-server/tools/catalogGetVariantDetail.d.ts +8 -0
  367. package/esm/mcp-server/tools/catalogGetVariantDetail.d.ts.map +1 -0
  368. package/esm/mcp-server/tools/catalogGetVariantDetail.js +28 -0
  369. package/esm/mcp-server/tools/catalogGetVariantDetail.js.map +1 -0
  370. package/esm/mcp-server/tools/catalogListCategories.d.ts +8 -0
  371. package/esm/mcp-server/tools/catalogListCategories.d.ts.map +1 -0
  372. package/esm/mcp-server/tools/catalogListCategories.js +28 -0
  373. package/esm/mcp-server/tools/catalogListCategories.js.map +1 -0
  374. package/esm/mcp-server/tools/catalogListCrosssellProducts.d.ts +8 -0
  375. package/esm/mcp-server/tools/catalogListCrosssellProducts.d.ts.map +1 -0
  376. package/esm/mcp-server/tools/catalogListCrosssellProducts.js +28 -0
  377. package/esm/mcp-server/tools/catalogListCrosssellProducts.js.map +1 -0
  378. package/esm/mcp-server/tools/catalogListProductReviews.d.ts +8 -0
  379. package/esm/mcp-server/tools/catalogListProductReviews.d.ts.map +1 -0
  380. package/esm/mcp-server/tools/catalogListProductReviews.js +28 -0
  381. package/esm/mcp-server/tools/catalogListProductReviews.js.map +1 -0
  382. package/esm/mcp-server/tools/catalogListProductVariants.d.ts +8 -0
  383. package/esm/mcp-server/tools/catalogListProductVariants.d.ts.map +1 -0
  384. package/esm/mcp-server/tools/catalogListProductVariants.js +28 -0
  385. package/esm/mcp-server/tools/catalogListProductVariants.js.map +1 -0
  386. package/esm/mcp-server/tools/catalogListProducts.d.ts +8 -0
  387. package/esm/mcp-server/tools/catalogListProducts.d.ts.map +1 -0
  388. package/esm/mcp-server/tools/catalogListProducts.js +28 -0
  389. package/esm/mcp-server/tools/catalogListProducts.js.map +1 -0
  390. package/esm/mcp-server/tools/catalogListSimilarProducts.d.ts +8 -0
  391. package/esm/mcp-server/tools/catalogListSimilarProducts.d.ts.map +1 -0
  392. package/esm/mcp-server/tools/catalogListSimilarProducts.js +28 -0
  393. package/esm/mcp-server/tools/catalogListSimilarProducts.js.map +1 -0
  394. package/esm/mcp-server/tools/catalogListSkus.d.ts +8 -0
  395. package/esm/mcp-server/tools/catalogListSkus.d.ts.map +1 -0
  396. package/esm/mcp-server/tools/catalogListSkus.js +28 -0
  397. package/esm/mcp-server/tools/catalogListSkus.js.map +1 -0
  398. package/esm/mcp-server/tools/catalogListUpsellProducts.d.ts +8 -0
  399. package/esm/mcp-server/tools/catalogListUpsellProducts.d.ts.map +1 -0
  400. package/esm/mcp-server/tools/catalogListUpsellProducts.js +28 -0
  401. package/esm/mcp-server/tools/catalogListUpsellProducts.js.map +1 -0
  402. package/esm/mcp-server/tools/catalogSearchProducts.d.ts +8 -0
  403. package/esm/mcp-server/tools/catalogSearchProducts.d.ts.map +1 -0
  404. package/esm/mcp-server/tools/catalogSearchProducts.js +28 -0
  405. package/esm/mcp-server/tools/catalogSearchProducts.js.map +1 -0
  406. package/esm/mcp-server/tools/commonListCountryPincodes.d.ts +8 -0
  407. package/esm/mcp-server/tools/commonListCountryPincodes.d.ts.map +1 -0
  408. package/esm/mcp-server/tools/commonListCountryPincodes.js +28 -0
  409. package/esm/mcp-server/tools/commonListCountryPincodes.js.map +1 -0
  410. package/esm/mcp-server/tools/customersCreateAddress.d.ts +8 -0
  411. package/esm/mcp-server/tools/customersCreateAddress.d.ts.map +1 -0
  412. package/esm/mcp-server/tools/customersCreateAddress.js +28 -0
  413. package/esm/mcp-server/tools/customersCreateAddress.js.map +1 -0
  414. package/esm/mcp-server/tools/customersDeleteAddress.d.ts +8 -0
  415. package/esm/mcp-server/tools/customersDeleteAddress.d.ts.map +1 -0
  416. package/esm/mcp-server/tools/customersDeleteAddress.js +28 -0
  417. package/esm/mcp-server/tools/customersDeleteAddress.js.map +1 -0
  418. package/esm/mcp-server/tools/customersGetAddressDetail.d.ts +8 -0
  419. package/esm/mcp-server/tools/customersGetAddressDetail.d.ts.map +1 -0
  420. package/esm/mcp-server/tools/customersGetAddressDetail.js +28 -0
  421. package/esm/mcp-server/tools/customersGetAddressDetail.js.map +1 -0
  422. package/esm/mcp-server/tools/customersListAddresses.d.ts +8 -0
  423. package/esm/mcp-server/tools/customersListAddresses.d.ts.map +1 -0
  424. package/esm/mcp-server/tools/customersListAddresses.js +28 -0
  425. package/esm/mcp-server/tools/customersListAddresses.js.map +1 -0
  426. package/esm/mcp-server/tools/customersListUserReviews.d.ts +8 -0
  427. package/esm/mcp-server/tools/customersListUserReviews.d.ts.map +1 -0
  428. package/esm/mcp-server/tools/customersListUserReviews.js +28 -0
  429. package/esm/mcp-server/tools/customersListUserReviews.js.map +1 -0
  430. package/esm/mcp-server/tools/customersUpdateAddressDetail.d.ts +8 -0
  431. package/esm/mcp-server/tools/customersUpdateAddressDetail.d.ts.map +1 -0
  432. package/esm/mcp-server/tools/customersUpdateAddressDetail.js +28 -0
  433. package/esm/mcp-server/tools/customersUpdateAddressDetail.js.map +1 -0
  434. package/esm/mcp-server/tools/ordersCancelOrder.d.ts +8 -0
  435. package/esm/mcp-server/tools/ordersCancelOrder.d.ts.map +1 -0
  436. package/esm/mcp-server/tools/ordersCancelOrder.js +28 -0
  437. package/esm/mcp-server/tools/ordersCancelOrder.js.map +1 -0
  438. package/esm/mcp-server/tools/ordersCreateOrder.d.ts +8 -0
  439. package/esm/mcp-server/tools/ordersCreateOrder.d.ts.map +1 -0
  440. package/esm/mcp-server/tools/ordersCreateOrder.js +28 -0
  441. package/esm/mcp-server/tools/ordersCreateOrder.js.map +1 -0
  442. package/esm/mcp-server/tools/ordersGetOrderDetail.d.ts +8 -0
  443. package/esm/mcp-server/tools/ordersGetOrderDetail.d.ts.map +1 -0
  444. package/esm/mcp-server/tools/ordersGetOrderDetail.js +28 -0
  445. package/esm/mcp-server/tools/ordersGetOrderDetail.js.map +1 -0
  446. package/esm/mcp-server/tools/ordersGetPaymentStatus.d.ts +8 -0
  447. package/esm/mcp-server/tools/ordersGetPaymentStatus.d.ts.map +1 -0
  448. package/esm/mcp-server/tools/ordersGetPaymentStatus.js +28 -0
  449. package/esm/mcp-server/tools/ordersGetPaymentStatus.js.map +1 -0
  450. package/esm/mcp-server/tools/ordersListOrderShipments.d.ts +8 -0
  451. package/esm/mcp-server/tools/ordersListOrderShipments.d.ts.map +1 -0
  452. package/esm/mcp-server/tools/ordersListOrderShipments.js +28 -0
  453. package/esm/mcp-server/tools/ordersListOrderShipments.js.map +1 -0
  454. package/esm/mcp-server/tools/ordersListOrders.d.ts +8 -0
  455. package/esm/mcp-server/tools/ordersListOrders.d.ts.map +1 -0
  456. package/esm/mcp-server/tools/ordersListOrders.js +28 -0
  457. package/esm/mcp-server/tools/ordersListOrders.js.map +1 -0
  458. package/esm/mcp-server/tools/ordersRetryOrderPayment.d.ts +8 -0
  459. package/esm/mcp-server/tools/ordersRetryOrderPayment.d.ts.map +1 -0
  460. package/esm/mcp-server/tools/ordersRetryOrderPayment.js +28 -0
  461. package/esm/mcp-server/tools/ordersRetryOrderPayment.js.map +1 -0
  462. package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.d.ts +8 -0
  463. package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.d.ts.map +1 -0
  464. package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.js +28 -0
  465. package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.js.map +1 -0
  466. package/esm/mcp-server/tools.d.ts +25 -0
  467. package/esm/mcp-server/tools.d.ts.map +1 -0
  468. package/esm/mcp-server/tools.js +77 -0
  469. package/esm/mcp-server/tools.js.map +1 -0
  470. package/esm/models/components/index.d.ts +1 -2
  471. package/esm/models/components/index.d.ts.map +1 -1
  472. package/esm/models/components/index.js +1 -2
  473. package/esm/models/components/index.js.map +1 -1
  474. package/esm/models/components/{sku.d.ts → item.d.ts} +22 -22
  475. package/esm/models/components/item.d.ts.map +1 -0
  476. package/esm/models/components/{sku.js → item.js} +26 -27
  477. package/esm/models/components/item.js.map +1 -0
  478. package/esm/models/components/juspaypaymentinfo.d.ts +9 -9
  479. package/esm/models/components/juspaypaymentinfo.js +3 -3
  480. package/esm/models/components/juspaypaymentinfo.js.map +1 -1
  481. package/esm/models/components/productdetail.d.ts +2 -2
  482. package/esm/models/components/productdetail.d.ts.map +1 -1
  483. package/esm/models/components/productdetail.js +2 -2
  484. package/esm/models/components/productdetail.js.map +1 -1
  485. package/esm/models/operations/index.d.ts +0 -1
  486. package/esm/models/operations/index.d.ts.map +1 -1
  487. package/esm/models/operations/index.js +0 -1
  488. package/esm/models/operations/index.js.map +1 -1
  489. package/esm/models/operations/listaddresses.d.ts +2 -2
  490. package/esm/models/operations/listaddresses.d.ts.map +1 -1
  491. package/esm/models/operations/listaddresses.js +2 -2
  492. package/esm/models/operations/listaddresses.js.map +1 -1
  493. package/esm/models/operations/listcrosssellproducts.d.ts +2 -2
  494. package/esm/models/operations/listcrosssellproducts.d.ts.map +1 -1
  495. package/esm/models/operations/listcrosssellproducts.js +2 -2
  496. package/esm/models/operations/listcrosssellproducts.js.map +1 -1
  497. package/esm/models/operations/listsimilarproducts.d.ts +2 -2
  498. package/esm/models/operations/listsimilarproducts.d.ts.map +1 -1
  499. package/esm/models/operations/listsimilarproducts.js +2 -2
  500. package/esm/models/operations/listsimilarproducts.js.map +1 -1
  501. package/esm/models/operations/listskus.d.ts +2 -2
  502. package/esm/models/operations/listskus.d.ts.map +1 -1
  503. package/esm/models/operations/listskus.js +2 -2
  504. package/esm/models/operations/listskus.js.map +1 -1
  505. package/esm/models/operations/listupsellproducts.d.ts +2 -2
  506. package/esm/models/operations/listupsellproducts.d.ts.map +1 -1
  507. package/esm/models/operations/listupsellproducts.js +2 -2
  508. package/esm/models/operations/listupsellproducts.js.map +1 -1
  509. package/esm/models/operations/searchproducts.d.ts +2 -2
  510. package/esm/models/operations/searchproducts.d.ts.map +1 -1
  511. package/esm/models/operations/searchproducts.js +2 -2
  512. package/esm/models/operations/searchproducts.js.map +1 -1
  513. package/esm/sdk/catalog.d.ts +0 -7
  514. package/esm/sdk/catalog.d.ts.map +1 -1
  515. package/esm/sdk/catalog.js +0 -10
  516. package/esm/sdk/catalog.js.map +1 -1
  517. package/esm/types/async.d.ts +23 -0
  518. package/esm/types/async.d.ts.map +1 -0
  519. package/esm/types/async.js +40 -0
  520. package/esm/types/async.js.map +1 -0
  521. package/jsr.json +1 -1
  522. package/package.json +16 -2
  523. package/src/funcs/authCheckVerificationStatus.ts +35 -8
  524. package/src/funcs/authCreateNotificationPreferences.ts +35 -8
  525. package/src/funcs/authGenerateOtp.ts +35 -8
  526. package/src/funcs/authGetAnonymousToken.ts +34 -7
  527. package/src/funcs/authGetNotificationPreferences.ts +35 -8
  528. package/src/funcs/authGetUserDetail.ts +35 -8
  529. package/src/funcs/authLoginWithEmail.ts +35 -8
  530. package/src/funcs/authLoginWithPhone.ts +35 -8
  531. package/src/funcs/authLoginWithWhatsapp.ts +35 -8
  532. package/src/funcs/authLogout.ts +32 -7
  533. package/src/funcs/authRefreshToken.ts +35 -8
  534. package/src/funcs/authUpdateNotificationPreferences.ts +35 -8
  535. package/src/funcs/authUpdateUser.ts +35 -8
  536. package/src/funcs/authVerifyOtp.ts +35 -8
  537. package/src/funcs/campaignsSubscribeNewsletter.ts +35 -8
  538. package/src/funcs/cartsApplyCoupon.ts +37 -8
  539. package/src/funcs/cartsCreateCart.ts +35 -8
  540. package/src/funcs/cartsCreateCartAddress.ts +38 -8
  541. package/src/funcs/cartsDeleteCart.ts +37 -8
  542. package/src/funcs/cartsGetCart.ts +37 -8
  543. package/src/funcs/cartsGetUserCart.ts +37 -8
  544. package/src/funcs/cartsRemoveCoupon.ts +37 -8
  545. package/src/funcs/cartsRemoveUserCart.ts +37 -8
  546. package/src/funcs/cartsUpdateCart.ts +38 -8
  547. package/src/funcs/catalogGetProductDetail.ts +37 -8
  548. package/src/funcs/catalogGetVariantDetail.ts +37 -8
  549. package/src/funcs/catalogListCategories.ts +35 -8
  550. package/src/funcs/catalogListCrosssellProducts.ts +37 -8
  551. package/src/funcs/catalogListProductReviews.ts +37 -8
  552. package/src/funcs/catalogListProductVariants.ts +37 -8
  553. package/src/funcs/catalogListProducts.ts +37 -8
  554. package/src/funcs/catalogListSimilarProducts.ts +37 -8
  555. package/src/funcs/catalogListSkus.ts +37 -8
  556. package/src/funcs/catalogListUpsellProducts.ts +37 -8
  557. package/src/funcs/catalogSearchProducts.ts +36 -8
  558. package/src/funcs/commonListCountryPincodes.ts +35 -8
  559. package/src/funcs/customersCreateAddress.ts +37 -8
  560. package/src/funcs/customersDeleteAddress.ts +37 -8
  561. package/src/funcs/customersGetAddressDetail.ts +37 -8
  562. package/src/funcs/customersListAddresses.ts +35 -8
  563. package/src/funcs/customersListUserReviews.ts +35 -8
  564. package/src/funcs/customersUpdateAddressDetail.ts +38 -8
  565. package/src/funcs/ordersCancelOrder.ts +37 -8
  566. package/src/funcs/ordersCreateOrder.ts +38 -8
  567. package/src/funcs/ordersGetOrderDetail.ts +37 -8
  568. package/src/funcs/ordersGetPaymentStatus.ts +35 -8
  569. package/src/funcs/ordersListOrderShipments.ts +37 -8
  570. package/src/funcs/ordersListOrders.ts +35 -8
  571. package/src/funcs/ordersRetryOrderPayment.ts +38 -8
  572. package/src/funcs/shippingCheckDeliveryAvailability.ts +36 -8
  573. package/src/hooks/types.ts +1 -1
  574. package/src/lib/config.ts +7 -7
  575. package/src/lib/files.ts +1 -1
  576. package/src/lib/primitives.ts +14 -0
  577. package/src/lib/sdks.ts +3 -8
  578. package/src/lib/security.ts +11 -3
  579. package/src/mcp-server/cli/start/command.ts +113 -0
  580. package/src/mcp-server/cli/start/impl.ts +137 -0
  581. package/src/mcp-server/cli.ts +13 -0
  582. package/src/mcp-server/console-logger.ts +71 -0
  583. package/src/mcp-server/extensions.ts +17 -0
  584. package/src/mcp-server/mcp-server.ts +26 -0
  585. package/src/mcp-server/prompts.ts +110 -0
  586. package/src/mcp-server/resources.ts +158 -0
  587. package/src/mcp-server/scopes.ts +7 -0
  588. package/src/mcp-server/server.ts +159 -0
  589. package/src/mcp-server/shared.ts +75 -0
  590. package/src/mcp-server/tools/authCheckVerificationStatus.ts +37 -0
  591. package/src/mcp-server/tools/authCreateNotificationPreferences.ts +39 -0
  592. package/src/mcp-server/tools/authGenerateOtp.ts +37 -0
  593. package/src/mcp-server/tools/authGetNotificationPreferences.ts +38 -0
  594. package/src/mcp-server/tools/authGetUserDetail.ts +37 -0
  595. package/src/mcp-server/tools/authLoginWithEmail.ts +37 -0
  596. package/src/mcp-server/tools/authLoginWithPhone.ts +37 -0
  597. package/src/mcp-server/tools/authLoginWithWhatsapp.ts +37 -0
  598. package/src/mcp-server/tools/authLogout.ts +30 -0
  599. package/src/mcp-server/tools/authRefreshToken.ts +37 -0
  600. package/src/mcp-server/tools/authUpdateNotificationPreferences.ts +39 -0
  601. package/src/mcp-server/tools/authUpdateUser.ts +37 -0
  602. package/src/mcp-server/tools/authVerifyOtp.ts +37 -0
  603. package/src/mcp-server/tools/campaignsSubscribeNewsletter.ts +37 -0
  604. package/src/mcp-server/tools/cartsApplyCoupon.ts +37 -0
  605. package/src/mcp-server/tools/cartsCreateCart.ts +37 -0
  606. package/src/mcp-server/tools/cartsCreateCartAddress.ts +37 -0
  607. package/src/mcp-server/tools/cartsDeleteCart.ts +37 -0
  608. package/src/mcp-server/tools/cartsGetCart.ts +37 -0
  609. package/src/mcp-server/tools/cartsGetUserCart.ts +37 -0
  610. package/src/mcp-server/tools/cartsRemoveCoupon.ts +37 -0
  611. package/src/mcp-server/tools/cartsRemoveUserCart.ts +37 -0
  612. package/src/mcp-server/tools/cartsUpdateCart.ts +37 -0
  613. package/src/mcp-server/tools/catalogGetProductDetail.ts +37 -0
  614. package/src/mcp-server/tools/catalogGetVariantDetail.ts +37 -0
  615. package/src/mcp-server/tools/catalogListCategories.ts +37 -0
  616. package/src/mcp-server/tools/catalogListCrosssellProducts.ts +37 -0
  617. package/src/mcp-server/tools/catalogListProductReviews.ts +37 -0
  618. package/src/mcp-server/tools/catalogListProductVariants.ts +37 -0
  619. package/src/mcp-server/tools/catalogListProducts.ts +37 -0
  620. package/src/mcp-server/tools/catalogListSimilarProducts.ts +37 -0
  621. package/src/mcp-server/tools/catalogListSkus.ts +37 -0
  622. package/src/mcp-server/tools/catalogListUpsellProducts.ts +37 -0
  623. package/src/mcp-server/tools/catalogSearchProducts.ts +37 -0
  624. package/src/mcp-server/tools/commonListCountryPincodes.ts +37 -0
  625. package/src/mcp-server/tools/customersCreateAddress.ts +37 -0
  626. package/src/mcp-server/tools/customersDeleteAddress.ts +37 -0
  627. package/src/mcp-server/tools/customersGetAddressDetail.ts +37 -0
  628. package/src/mcp-server/tools/customersListAddresses.ts +37 -0
  629. package/src/mcp-server/tools/customersListUserReviews.ts +37 -0
  630. package/src/mcp-server/tools/customersUpdateAddressDetail.ts +37 -0
  631. package/src/mcp-server/tools/ordersCancelOrder.ts +37 -0
  632. package/src/mcp-server/tools/ordersCreateOrder.ts +37 -0
  633. package/src/mcp-server/tools/ordersGetOrderDetail.ts +37 -0
  634. package/src/mcp-server/tools/ordersGetPaymentStatus.ts +37 -0
  635. package/src/mcp-server/tools/ordersListOrderShipments.ts +37 -0
  636. package/src/mcp-server/tools/ordersListOrders.ts +37 -0
  637. package/src/mcp-server/tools/ordersRetryOrderPayment.ts +37 -0
  638. package/src/mcp-server/tools/shippingCheckDeliveryAvailability.ts +39 -0
  639. package/src/mcp-server/tools.ts +126 -0
  640. package/src/models/components/index.ts +1 -2
  641. package/src/models/components/{sku.ts → item.ts} +34 -34
  642. package/src/models/components/juspaypaymentinfo.ts +3 -3
  643. package/src/models/components/productdetail.ts +4 -4
  644. package/src/models/operations/index.ts +0 -1
  645. package/src/models/operations/listaddresses.ts +4 -4
  646. package/src/models/operations/listcrosssellproducts.ts +4 -4
  647. package/src/models/operations/listsimilarproducts.ts +4 -4
  648. package/src/models/operations/listskus.ts +4 -4
  649. package/src/models/operations/listupsellproducts.ts +4 -4
  650. package/src/models/operations/searchproducts.ts +4 -4
  651. package/src/sdk/catalog.ts +0 -18
  652. package/src/types/async.ts +68 -0
  653. package/esm/funcs/catalogCreateProductReview.d.ts +0 -16
  654. package/esm/funcs/catalogCreateProductReview.d.ts.map +0 -1
  655. package/esm/funcs/catalogCreateProductReview.js +0 -93
  656. package/esm/funcs/catalogCreateProductReview.js.map +0 -1
  657. package/esm/models/components/createreview.d.ts +0 -42
  658. package/esm/models/components/createreview.d.ts.map +0 -1
  659. package/esm/models/components/createreview.js +0 -54
  660. package/esm/models/components/createreview.js.map +0 -1
  661. package/esm/models/components/sku.d.ts.map +0 -1
  662. package/esm/models/components/sku.js.map +0 -1
  663. package/esm/models/operations/createproductreview.d.ts +0 -65
  664. package/esm/models/operations/createproductreview.d.ts.map +0 -1
  665. package/esm/models/operations/createproductreview.js +0 -72
  666. package/esm/models/operations/createproductreview.js.map +0 -1
  667. package/src/funcs/catalogCreateProductReview.ts +0 -161
  668. package/src/models/components/createreview.ts +0 -98
  669. package/src/models/operations/createproductreview.ts +0 -152
@@ -20,6 +20,7 @@ import {
20
20
  } from "../models/errors/httpclienterrors.js";
21
21
  import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
22
22
  import * as operations from "../models/operations/index.js";
23
+ import { APICall, APIPromise } from "../types/async.js";
23
24
  import { Result } from "../types/fp.js";
24
25
 
25
26
  /**
@@ -28,11 +29,11 @@ import { Result } from "../types/fp.js";
28
29
  * @remarks
29
30
  * Retrieve pincodes
30
31
  */
31
- export async function commonListCountryPincodes(
32
+ export function commonListCountryPincodes(
32
33
  client: CeStorefrontCore,
33
34
  request: operations.ListCountryPincodesRequest,
34
35
  options?: RequestOptions,
35
- ): Promise<
36
+ ): APIPromise<
36
37
  Result<
37
38
  operations.ListCountryPincodesResponseBody,
38
39
  | CeError
@@ -43,6 +44,32 @@ export async function commonListCountryPincodes(
43
44
  | RequestTimeoutError
44
45
  | ConnectionError
45
46
  >
47
+ > {
48
+ return new APIPromise($do(
49
+ client,
50
+ request,
51
+ options,
52
+ ));
53
+ }
54
+
55
+ async function $do(
56
+ client: CeStorefrontCore,
57
+ request: operations.ListCountryPincodesRequest,
58
+ options?: RequestOptions,
59
+ ): Promise<
60
+ [
61
+ Result<
62
+ operations.ListCountryPincodesResponseBody,
63
+ | CeError
64
+ | SDKValidationError
65
+ | UnexpectedClientError
66
+ | InvalidRequestError
67
+ | RequestAbortedError
68
+ | RequestTimeoutError
69
+ | ConnectionError
70
+ >,
71
+ APICall,
72
+ ]
46
73
  > {
47
74
  const parsed = safeParse(
48
75
  request,
@@ -51,7 +78,7 @@ export async function commonListCountryPincodes(
51
78
  "Input validation failed",
52
79
  );
53
80
  if (!parsed.ok) {
54
- return parsed;
81
+ return [parsed, { status: "invalid" }];
55
82
  }
56
83
  const payload = parsed.value;
57
84
  const body = null;
@@ -83,7 +110,7 @@ export async function commonListCountryPincodes(
83
110
  const requestSecurity = resolveGlobalSecurity(securityInput);
84
111
 
85
112
  const context = {
86
- baseURL: options?.serverURL ?? "",
113
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
87
114
  operationID: "list-country-pincodes",
88
115
  oAuth2Scopes: [],
89
116
 
@@ -107,7 +134,7 @@ export async function commonListCountryPincodes(
107
134
  timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
108
135
  }, options);
109
136
  if (!requestRes.ok) {
110
- return requestRes;
137
+ return [requestRes, { status: "invalid" }];
111
138
  }
112
139
  const req = requestRes.value;
113
140
 
@@ -118,7 +145,7 @@ export async function commonListCountryPincodes(
118
145
  retryCodes: context.retryCodes,
119
146
  });
120
147
  if (!doResult.ok) {
121
- return doResult;
148
+ return [doResult, { status: "request-error", request: req }];
122
149
  }
123
150
  const response = doResult.value;
124
151
 
@@ -137,8 +164,8 @@ export async function commonListCountryPincodes(
137
164
  M.fail("5XX"),
138
165
  )(response);
139
166
  if (!result.ok) {
140
- return result;
167
+ return [result, { status: "complete", request: req, response }];
141
168
  }
142
169
 
143
- return result;
170
+ return [result, { status: "complete", request: req, response }];
144
171
  }
@@ -21,6 +21,7 @@ import {
21
21
  import * as errors from "../models/errors/index.js";
22
22
  import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
23
23
  import * as operations from "../models/operations/index.js";
24
+ import { APICall, APIPromise } from "../types/async.js";
24
25
  import { Result } from "../types/fp.js";
25
26
 
26
27
  /**
@@ -29,11 +30,11 @@ import { Result } from "../types/fp.js";
29
30
  * @remarks
30
31
  * Add new address
31
32
  */
32
- export async function customersCreateAddress(
33
+ export function customersCreateAddress(
33
34
  client: CeStorefrontCore,
34
35
  request: operations.CreateAddressRequest,
35
36
  options?: RequestOptions,
36
- ): Promise<
37
+ ): APIPromise<
37
38
  Result<
38
39
  operations.CreateAddressResponseBody,
39
40
  | errors.BadRequest
@@ -46,6 +47,34 @@ export async function customersCreateAddress(
46
47
  | RequestTimeoutError
47
48
  | ConnectionError
48
49
  >
50
+ > {
51
+ return new APIPromise($do(
52
+ client,
53
+ request,
54
+ options,
55
+ ));
56
+ }
57
+
58
+ async function $do(
59
+ client: CeStorefrontCore,
60
+ request: operations.CreateAddressRequest,
61
+ options?: RequestOptions,
62
+ ): Promise<
63
+ [
64
+ Result<
65
+ operations.CreateAddressResponseBody,
66
+ | errors.BadRequest
67
+ | errors.Unauthorized
68
+ | CeError
69
+ | SDKValidationError
70
+ | UnexpectedClientError
71
+ | InvalidRequestError
72
+ | RequestAbortedError
73
+ | RequestTimeoutError
74
+ | ConnectionError
75
+ >,
76
+ APICall,
77
+ ]
49
78
  > {
50
79
  const parsed = safeParse(
51
80
  request,
@@ -53,7 +82,7 @@ export async function customersCreateAddress(
53
82
  "Input validation failed",
54
83
  );
55
84
  if (!parsed.ok) {
56
- return parsed;
85
+ return [parsed, { status: "invalid" }];
57
86
  }
58
87
  const payload = parsed.value;
59
88
  const body = encodeJSON("body", payload.RequestBody, { explode: true });
@@ -77,7 +106,7 @@ export async function customersCreateAddress(
77
106
  const requestSecurity = resolveGlobalSecurity(securityInput);
78
107
 
79
108
  const context = {
80
- baseURL: options?.serverURL ?? "",
109
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
81
110
  operationID: "create-address",
82
111
  oAuth2Scopes: [],
83
112
 
@@ -100,7 +129,7 @@ export async function customersCreateAddress(
100
129
  timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
101
130
  }, options);
102
131
  if (!requestRes.ok) {
103
- return requestRes;
132
+ return [requestRes, { status: "invalid" }];
104
133
  }
105
134
  const req = requestRes.value;
106
135
 
@@ -111,7 +140,7 @@ export async function customersCreateAddress(
111
140
  retryCodes: context.retryCodes,
112
141
  });
113
142
  if (!doResult.ok) {
114
- return doResult;
143
+ return [doResult, { status: "request-error", request: req }];
115
144
  }
116
145
  const response = doResult.value;
117
146
 
@@ -138,8 +167,8 @@ export async function customersCreateAddress(
138
167
  M.fail("5XX"),
139
168
  )(response, { extraFields: responseFields });
140
169
  if (!result.ok) {
141
- return result;
170
+ return [result, { status: "complete", request: req, response }];
142
171
  }
143
172
 
144
- return result;
173
+ return [result, { status: "complete", request: req, response }];
145
174
  }
@@ -21,6 +21,7 @@ import {
21
21
  import * as errors from "../models/errors/index.js";
22
22
  import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
23
23
  import * as operations from "../models/operations/index.js";
24
+ import { APICall, APIPromise } from "../types/async.js";
24
25
  import { Result } from "../types/fp.js";
25
26
 
26
27
  /**
@@ -29,11 +30,11 @@ import { Result } from "../types/fp.js";
29
30
  * @remarks
30
31
  * Delete address
31
32
  */
32
- export async function customersDeleteAddress(
33
+ export function customersDeleteAddress(
33
34
  client: CeStorefrontCore,
34
35
  request: operations.DeleteAddressRequest,
35
36
  options?: RequestOptions,
36
- ): Promise<
37
+ ): APIPromise<
37
38
  Result<
38
39
  operations.DeleteAddressResponseBody,
39
40
  | errors.Unauthorized
@@ -46,6 +47,34 @@ export async function customersDeleteAddress(
46
47
  | RequestTimeoutError
47
48
  | ConnectionError
48
49
  >
50
+ > {
51
+ return new APIPromise($do(
52
+ client,
53
+ request,
54
+ options,
55
+ ));
56
+ }
57
+
58
+ async function $do(
59
+ client: CeStorefrontCore,
60
+ request: operations.DeleteAddressRequest,
61
+ options?: RequestOptions,
62
+ ): Promise<
63
+ [
64
+ Result<
65
+ operations.DeleteAddressResponseBody,
66
+ | errors.Unauthorized
67
+ | errors.NotFound
68
+ | CeError
69
+ | SDKValidationError
70
+ | UnexpectedClientError
71
+ | InvalidRequestError
72
+ | RequestAbortedError
73
+ | RequestTimeoutError
74
+ | ConnectionError
75
+ >,
76
+ APICall,
77
+ ]
49
78
  > {
50
79
  const parsed = safeParse(
51
80
  request,
@@ -53,7 +82,7 @@ export async function customersDeleteAddress(
53
82
  "Input validation failed",
54
83
  );
55
84
  if (!parsed.ok) {
56
- return parsed;
85
+ return [parsed, { status: "invalid" }];
57
86
  }
58
87
  const payload = parsed.value;
59
88
  const body = null;
@@ -82,7 +111,7 @@ export async function customersDeleteAddress(
82
111
  const requestSecurity = resolveGlobalSecurity(securityInput);
83
112
 
84
113
  const context = {
85
- baseURL: options?.serverURL ?? "",
114
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
86
115
  operationID: "delete-address",
87
116
  oAuth2Scopes: [],
88
117
 
@@ -105,7 +134,7 @@ export async function customersDeleteAddress(
105
134
  timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
106
135
  }, options);
107
136
  if (!requestRes.ok) {
108
- return requestRes;
137
+ return [requestRes, { status: "invalid" }];
109
138
  }
110
139
  const req = requestRes.value;
111
140
 
@@ -116,7 +145,7 @@ export async function customersDeleteAddress(
116
145
  retryCodes: context.retryCodes,
117
146
  });
118
147
  if (!doResult.ok) {
119
- return doResult;
148
+ return [doResult, { status: "request-error", request: req }];
120
149
  }
121
150
  const response = doResult.value;
122
151
 
@@ -143,8 +172,8 @@ export async function customersDeleteAddress(
143
172
  M.fail("5XX"),
144
173
  )(response, { extraFields: responseFields });
145
174
  if (!result.ok) {
146
- return result;
175
+ return [result, { status: "complete", request: req, response }];
147
176
  }
148
177
 
149
- return result;
178
+ return [result, { status: "complete", request: req, response }];
150
179
  }
@@ -21,6 +21,7 @@ import {
21
21
  import * as errors from "../models/errors/index.js";
22
22
  import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
23
23
  import * as operations from "../models/operations/index.js";
24
+ import { APICall, APIPromise } from "../types/async.js";
24
25
  import { Result } from "../types/fp.js";
25
26
 
26
27
  /**
@@ -29,11 +30,11 @@ import { Result } from "../types/fp.js";
29
30
  * @remarks
30
31
  * Retrieve address
31
32
  */
32
- export async function customersGetAddressDetail(
33
+ export function customersGetAddressDetail(
33
34
  client: CeStorefrontCore,
34
35
  request: operations.GetAddressDetailRequest,
35
36
  options?: RequestOptions,
36
- ): Promise<
37
+ ): APIPromise<
37
38
  Result<
38
39
  operations.GetAddressDetailResponseBody,
39
40
  | errors.Unauthorized
@@ -46,6 +47,34 @@ export async function customersGetAddressDetail(
46
47
  | RequestTimeoutError
47
48
  | ConnectionError
48
49
  >
50
+ > {
51
+ return new APIPromise($do(
52
+ client,
53
+ request,
54
+ options,
55
+ ));
56
+ }
57
+
58
+ async function $do(
59
+ client: CeStorefrontCore,
60
+ request: operations.GetAddressDetailRequest,
61
+ options?: RequestOptions,
62
+ ): Promise<
63
+ [
64
+ Result<
65
+ operations.GetAddressDetailResponseBody,
66
+ | errors.Unauthorized
67
+ | errors.NotFound
68
+ | CeError
69
+ | SDKValidationError
70
+ | UnexpectedClientError
71
+ | InvalidRequestError
72
+ | RequestAbortedError
73
+ | RequestTimeoutError
74
+ | ConnectionError
75
+ >,
76
+ APICall,
77
+ ]
49
78
  > {
50
79
  const parsed = safeParse(
51
80
  request,
@@ -53,7 +82,7 @@ export async function customersGetAddressDetail(
53
82
  "Input validation failed",
54
83
  );
55
84
  if (!parsed.ok) {
56
- return parsed;
85
+ return [parsed, { status: "invalid" }];
57
86
  }
58
87
  const payload = parsed.value;
59
88
  const body = null;
@@ -82,7 +111,7 @@ export async function customersGetAddressDetail(
82
111
  const requestSecurity = resolveGlobalSecurity(securityInput);
83
112
 
84
113
  const context = {
85
- baseURL: options?.serverURL ?? "",
114
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
86
115
  operationID: "get-address-detail",
87
116
  oAuth2Scopes: [],
88
117
 
@@ -105,7 +134,7 @@ export async function customersGetAddressDetail(
105
134
  timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
106
135
  }, options);
107
136
  if (!requestRes.ok) {
108
- return requestRes;
137
+ return [requestRes, { status: "invalid" }];
109
138
  }
110
139
  const req = requestRes.value;
111
140
 
@@ -116,7 +145,7 @@ export async function customersGetAddressDetail(
116
145
  retryCodes: context.retryCodes,
117
146
  });
118
147
  if (!doResult.ok) {
119
- return doResult;
148
+ return [doResult, { status: "request-error", request: req }];
120
149
  }
121
150
  const response = doResult.value;
122
151
 
@@ -143,8 +172,8 @@ export async function customersGetAddressDetail(
143
172
  M.fail("5XX"),
144
173
  )(response, { extraFields: responseFields });
145
174
  if (!result.ok) {
146
- return result;
175
+ return [result, { status: "complete", request: req, response }];
147
176
  }
148
177
 
149
- return result;
178
+ return [result, { status: "complete", request: req, response }];
150
179
  }
@@ -20,6 +20,7 @@ import {
20
20
  } from "../models/errors/httpclienterrors.js";
21
21
  import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
22
22
  import * as operations from "../models/operations/index.js";
23
+ import { APICall, APIPromise } from "../types/async.js";
23
24
  import { Result } from "../types/fp.js";
24
25
 
25
26
  /**
@@ -28,11 +29,11 @@ import { Result } from "../types/fp.js";
28
29
  * @remarks
29
30
  * Retrieve billing and shipping address of particular customer
30
31
  */
31
- export async function customersListAddresses(
32
+ export function customersListAddresses(
32
33
  client: CeStorefrontCore,
33
34
  request: operations.ListAddressesRequest,
34
35
  options?: RequestOptions,
35
- ): Promise<
36
+ ): APIPromise<
36
37
  Result<
37
38
  operations.ListAddressesResponseBody,
38
39
  | CeError
@@ -43,6 +44,32 @@ export async function customersListAddresses(
43
44
  | RequestTimeoutError
44
45
  | ConnectionError
45
46
  >
47
+ > {
48
+ return new APIPromise($do(
49
+ client,
50
+ request,
51
+ options,
52
+ ));
53
+ }
54
+
55
+ async function $do(
56
+ client: CeStorefrontCore,
57
+ request: operations.ListAddressesRequest,
58
+ options?: RequestOptions,
59
+ ): Promise<
60
+ [
61
+ Result<
62
+ operations.ListAddressesResponseBody,
63
+ | CeError
64
+ | SDKValidationError
65
+ | UnexpectedClientError
66
+ | InvalidRequestError
67
+ | RequestAbortedError
68
+ | RequestTimeoutError
69
+ | ConnectionError
70
+ >,
71
+ APICall,
72
+ ]
46
73
  > {
47
74
  const parsed = safeParse(
48
75
  request,
@@ -50,7 +77,7 @@ export async function customersListAddresses(
50
77
  "Input validation failed",
51
78
  );
52
79
  if (!parsed.ok) {
53
- return parsed;
80
+ return [parsed, { status: "invalid" }];
54
81
  }
55
82
  const payload = parsed.value;
56
83
  const body = null;
@@ -78,7 +105,7 @@ export async function customersListAddresses(
78
105
  const requestSecurity = resolveGlobalSecurity(securityInput);
79
106
 
80
107
  const context = {
81
- baseURL: options?.serverURL ?? "",
108
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
82
109
  operationID: "list-addresses",
83
110
  oAuth2Scopes: [],
84
111
 
@@ -102,7 +129,7 @@ export async function customersListAddresses(
102
129
  timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
103
130
  }, options);
104
131
  if (!requestRes.ok) {
105
- return requestRes;
132
+ return [requestRes, { status: "invalid" }];
106
133
  }
107
134
  const req = requestRes.value;
108
135
 
@@ -113,7 +140,7 @@ export async function customersListAddresses(
113
140
  retryCodes: context.retryCodes,
114
141
  });
115
142
  if (!doResult.ok) {
116
- return doResult;
143
+ return [doResult, { status: "request-error", request: req }];
117
144
  }
118
145
  const response = doResult.value;
119
146
 
@@ -132,8 +159,8 @@ export async function customersListAddresses(
132
159
  M.fail("5XX"),
133
160
  )(response);
134
161
  if (!result.ok) {
135
- return result;
162
+ return [result, { status: "complete", request: req, response }];
136
163
  }
137
164
 
138
- return result;
165
+ return [result, { status: "complete", request: req, response }];
139
166
  }
@@ -20,6 +20,7 @@ import {
20
20
  } from "../models/errors/httpclienterrors.js";
21
21
  import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
22
22
  import * as operations from "../models/operations/index.js";
23
+ import { APICall, APIPromise } from "../types/async.js";
23
24
  import { Result } from "../types/fp.js";
24
25
 
25
26
  /**
@@ -28,11 +29,11 @@ import { Result } from "../types/fp.js";
28
29
  * @remarks
29
30
  * Retrieve all reviews
30
31
  */
31
- export async function customersListUserReviews(
32
+ export function customersListUserReviews(
32
33
  client: CeStorefrontCore,
33
34
  request: operations.ListUserReviewsRequest,
34
35
  options?: RequestOptions,
35
- ): Promise<
36
+ ): APIPromise<
36
37
  Result<
37
38
  operations.ListUserReviewsResponseBody,
38
39
  | CeError
@@ -43,6 +44,32 @@ export async function customersListUserReviews(
43
44
  | RequestTimeoutError
44
45
  | ConnectionError
45
46
  >
47
+ > {
48
+ return new APIPromise($do(
49
+ client,
50
+ request,
51
+ options,
52
+ ));
53
+ }
54
+
55
+ async function $do(
56
+ client: CeStorefrontCore,
57
+ request: operations.ListUserReviewsRequest,
58
+ options?: RequestOptions,
59
+ ): Promise<
60
+ [
61
+ Result<
62
+ operations.ListUserReviewsResponseBody,
63
+ | CeError
64
+ | SDKValidationError
65
+ | UnexpectedClientError
66
+ | InvalidRequestError
67
+ | RequestAbortedError
68
+ | RequestTimeoutError
69
+ | ConnectionError
70
+ >,
71
+ APICall,
72
+ ]
46
73
  > {
47
74
  const parsed = safeParse(
48
75
  request,
@@ -50,7 +77,7 @@ export async function customersListUserReviews(
50
77
  "Input validation failed",
51
78
  );
52
79
  if (!parsed.ok) {
53
- return parsed;
80
+ return [parsed, { status: "invalid" }];
54
81
  }
55
82
  const payload = parsed.value;
56
83
  const body = null;
@@ -73,7 +100,7 @@ export async function customersListUserReviews(
73
100
  const requestSecurity = resolveGlobalSecurity(securityInput);
74
101
 
75
102
  const context = {
76
- baseURL: options?.serverURL ?? "",
103
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
77
104
  operationID: "list-user-reviews",
78
105
  oAuth2Scopes: [],
79
106
 
@@ -96,7 +123,7 @@ export async function customersListUserReviews(
96
123
  timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
97
124
  }, options);
98
125
  if (!requestRes.ok) {
99
- return requestRes;
126
+ return [requestRes, { status: "invalid" }];
100
127
  }
101
128
  const req = requestRes.value;
102
129
 
@@ -107,7 +134,7 @@ export async function customersListUserReviews(
107
134
  retryCodes: context.retryCodes,
108
135
  });
109
136
  if (!doResult.ok) {
110
- return doResult;
137
+ return [doResult, { status: "request-error", request: req }];
111
138
  }
112
139
  const response = doResult.value;
113
140
 
@@ -126,8 +153,8 @@ export async function customersListUserReviews(
126
153
  M.fail("5XX"),
127
154
  )(response);
128
155
  if (!result.ok) {
129
- return result;
156
+ return [result, { status: "complete", request: req, response }];
130
157
  }
131
158
 
132
- return result;
159
+ return [result, { status: "complete", request: req, response }];
133
160
  }
@@ -21,6 +21,7 @@ import {
21
21
  import * as errors from "../models/errors/index.js";
22
22
  import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
23
23
  import * as operations from "../models/operations/index.js";
24
+ import { APICall, APIPromise } from "../types/async.js";
24
25
  import { Result } from "../types/fp.js";
25
26
 
26
27
  /**
@@ -29,11 +30,11 @@ import { Result } from "../types/fp.js";
29
30
  * @remarks
30
31
  * Update address
31
32
  */
32
- export async function customersUpdateAddressDetail(
33
+ export function customersUpdateAddressDetail(
33
34
  client: CeStorefrontCore,
34
35
  request: operations.UpdateAddressDetailRequest,
35
36
  options?: RequestOptions,
36
- ): Promise<
37
+ ): APIPromise<
37
38
  Result<
38
39
  operations.UpdateAddressDetailResponseBody,
39
40
  | errors.BadRequest
@@ -47,6 +48,35 @@ export async function customersUpdateAddressDetail(
47
48
  | RequestTimeoutError
48
49
  | ConnectionError
49
50
  >
51
+ > {
52
+ return new APIPromise($do(
53
+ client,
54
+ request,
55
+ options,
56
+ ));
57
+ }
58
+
59
+ async function $do(
60
+ client: CeStorefrontCore,
61
+ request: operations.UpdateAddressDetailRequest,
62
+ options?: RequestOptions,
63
+ ): Promise<
64
+ [
65
+ Result<
66
+ operations.UpdateAddressDetailResponseBody,
67
+ | errors.BadRequest
68
+ | errors.Unauthorized
69
+ | errors.NotFound
70
+ | CeError
71
+ | SDKValidationError
72
+ | UnexpectedClientError
73
+ | InvalidRequestError
74
+ | RequestAbortedError
75
+ | RequestTimeoutError
76
+ | ConnectionError
77
+ >,
78
+ APICall,
79
+ ]
50
80
  > {
51
81
  const parsed = safeParse(
52
82
  request,
@@ -55,7 +85,7 @@ export async function customersUpdateAddressDetail(
55
85
  "Input validation failed",
56
86
  );
57
87
  if (!parsed.ok) {
58
- return parsed;
88
+ return [parsed, { status: "invalid" }];
59
89
  }
60
90
  const payload = parsed.value;
61
91
  const body = encodeJSON("body", payload.RequestBody, { explode: true });
@@ -85,7 +115,7 @@ export async function customersUpdateAddressDetail(
85
115
  const requestSecurity = resolveGlobalSecurity(securityInput);
86
116
 
87
117
  const context = {
88
- baseURL: options?.serverURL ?? "",
118
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
89
119
  operationID: "update-address-detail",
90
120
  oAuth2Scopes: [],
91
121
 
@@ -108,7 +138,7 @@ export async function customersUpdateAddressDetail(
108
138
  timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
109
139
  }, options);
110
140
  if (!requestRes.ok) {
111
- return requestRes;
141
+ return [requestRes, { status: "invalid" }];
112
142
  }
113
143
  const req = requestRes.value;
114
144
 
@@ -119,7 +149,7 @@ export async function customersUpdateAddressDetail(
119
149
  retryCodes: context.retryCodes,
120
150
  });
121
151
  if (!doResult.ok) {
122
- return doResult;
152
+ return [doResult, { status: "request-error", request: req }];
123
153
  }
124
154
  const response = doResult.value;
125
155
 
@@ -148,8 +178,8 @@ export async function customersUpdateAddressDetail(
148
178
  M.fail("5XX"),
149
179
  )(response, { extraFields: responseFields });
150
180
  if (!result.ok) {
151
- return result;
181
+ return [result, { status: "complete", request: req, response }];
152
182
  }
153
183
 
154
- return result;
184
+ return [result, { status: "complete", request: req, response }];
155
185
  }