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.
- package/README.md +93 -7
- package/bin/mcp-server.js +50005 -0
- package/bin/mcp-server.js.map +465 -0
- package/docs/sdks/catalog/README.md +0 -90
- package/esm/funcs/authCheckVerificationStatus.d.ts +2 -1
- package/esm/funcs/authCheckVerificationStatus.d.ts.map +1 -1
- package/esm/funcs/authCheckVerificationStatus.js +11 -7
- package/esm/funcs/authCheckVerificationStatus.js.map +1 -1
- package/esm/funcs/authCreateNotificationPreferences.d.ts +2 -1
- package/esm/funcs/authCreateNotificationPreferences.d.ts.map +1 -1
- package/esm/funcs/authCreateNotificationPreferences.js +11 -7
- package/esm/funcs/authCreateNotificationPreferences.js.map +1 -1
- package/esm/funcs/authGenerateOtp.d.ts +2 -1
- package/esm/funcs/authGenerateOtp.d.ts.map +1 -1
- package/esm/funcs/authGenerateOtp.js +11 -7
- package/esm/funcs/authGenerateOtp.js.map +1 -1
- package/esm/funcs/authGetAnonymousToken.d.ts +2 -1
- package/esm/funcs/authGetAnonymousToken.d.ts.map +1 -1
- package/esm/funcs/authGetAnonymousToken.js +10 -6
- package/esm/funcs/authGetAnonymousToken.js.map +1 -1
- package/esm/funcs/authGetNotificationPreferences.d.ts +2 -1
- package/esm/funcs/authGetNotificationPreferences.d.ts.map +1 -1
- package/esm/funcs/authGetNotificationPreferences.js +11 -7
- package/esm/funcs/authGetNotificationPreferences.js.map +1 -1
- package/esm/funcs/authGetUserDetail.d.ts +2 -1
- package/esm/funcs/authGetUserDetail.d.ts.map +1 -1
- package/esm/funcs/authGetUserDetail.js +11 -7
- package/esm/funcs/authGetUserDetail.js.map +1 -1
- package/esm/funcs/authLoginWithEmail.d.ts +2 -1
- package/esm/funcs/authLoginWithEmail.d.ts.map +1 -1
- package/esm/funcs/authLoginWithEmail.js +11 -7
- package/esm/funcs/authLoginWithEmail.js.map +1 -1
- package/esm/funcs/authLoginWithPhone.d.ts +2 -1
- package/esm/funcs/authLoginWithPhone.d.ts.map +1 -1
- package/esm/funcs/authLoginWithPhone.js +11 -7
- package/esm/funcs/authLoginWithPhone.js.map +1 -1
- package/esm/funcs/authLoginWithWhatsapp.d.ts +2 -1
- package/esm/funcs/authLoginWithWhatsapp.d.ts.map +1 -1
- package/esm/funcs/authLoginWithWhatsapp.js +11 -7
- package/esm/funcs/authLoginWithWhatsapp.js.map +1 -1
- package/esm/funcs/authLogout.d.ts +2 -1
- package/esm/funcs/authLogout.d.ts.map +1 -1
- package/esm/funcs/authLogout.js +10 -6
- package/esm/funcs/authLogout.js.map +1 -1
- package/esm/funcs/authRefreshToken.d.ts +2 -1
- package/esm/funcs/authRefreshToken.d.ts.map +1 -1
- package/esm/funcs/authRefreshToken.js +11 -7
- package/esm/funcs/authRefreshToken.js.map +1 -1
- package/esm/funcs/authUpdateNotificationPreferences.d.ts +2 -1
- package/esm/funcs/authUpdateNotificationPreferences.d.ts.map +1 -1
- package/esm/funcs/authUpdateNotificationPreferences.js +11 -7
- package/esm/funcs/authUpdateNotificationPreferences.js.map +1 -1
- package/esm/funcs/authUpdateUser.d.ts +2 -1
- package/esm/funcs/authUpdateUser.d.ts.map +1 -1
- package/esm/funcs/authUpdateUser.js +11 -7
- package/esm/funcs/authUpdateUser.js.map +1 -1
- package/esm/funcs/authVerifyOtp.d.ts +2 -1
- package/esm/funcs/authVerifyOtp.d.ts.map +1 -1
- package/esm/funcs/authVerifyOtp.js +11 -7
- package/esm/funcs/authVerifyOtp.js.map +1 -1
- package/esm/funcs/campaignsSubscribeNewsletter.d.ts +2 -1
- package/esm/funcs/campaignsSubscribeNewsletter.d.ts.map +1 -1
- package/esm/funcs/campaignsSubscribeNewsletter.js +11 -7
- package/esm/funcs/campaignsSubscribeNewsletter.js.map +1 -1
- package/esm/funcs/cartsApplyCoupon.d.ts +2 -1
- package/esm/funcs/cartsApplyCoupon.d.ts.map +1 -1
- package/esm/funcs/cartsApplyCoupon.js +11 -7
- package/esm/funcs/cartsApplyCoupon.js.map +1 -1
- package/esm/funcs/cartsCreateCart.d.ts +2 -1
- package/esm/funcs/cartsCreateCart.d.ts.map +1 -1
- package/esm/funcs/cartsCreateCart.js +11 -7
- package/esm/funcs/cartsCreateCart.js.map +1 -1
- package/esm/funcs/cartsCreateCartAddress.d.ts +2 -1
- package/esm/funcs/cartsCreateCartAddress.d.ts.map +1 -1
- package/esm/funcs/cartsCreateCartAddress.js +11 -7
- package/esm/funcs/cartsCreateCartAddress.js.map +1 -1
- package/esm/funcs/cartsDeleteCart.d.ts +2 -1
- package/esm/funcs/cartsDeleteCart.d.ts.map +1 -1
- package/esm/funcs/cartsDeleteCart.js +11 -7
- package/esm/funcs/cartsDeleteCart.js.map +1 -1
- package/esm/funcs/cartsGetCart.d.ts +2 -1
- package/esm/funcs/cartsGetCart.d.ts.map +1 -1
- package/esm/funcs/cartsGetCart.js +11 -7
- package/esm/funcs/cartsGetCart.js.map +1 -1
- package/esm/funcs/cartsGetUserCart.d.ts +2 -1
- package/esm/funcs/cartsGetUserCart.d.ts.map +1 -1
- package/esm/funcs/cartsGetUserCart.js +11 -7
- package/esm/funcs/cartsGetUserCart.js.map +1 -1
- package/esm/funcs/cartsRemoveCoupon.d.ts +2 -1
- package/esm/funcs/cartsRemoveCoupon.d.ts.map +1 -1
- package/esm/funcs/cartsRemoveCoupon.js +11 -7
- package/esm/funcs/cartsRemoveCoupon.js.map +1 -1
- package/esm/funcs/cartsRemoveUserCart.d.ts +2 -1
- package/esm/funcs/cartsRemoveUserCart.d.ts.map +1 -1
- package/esm/funcs/cartsRemoveUserCart.js +11 -7
- package/esm/funcs/cartsRemoveUserCart.js.map +1 -1
- package/esm/funcs/cartsUpdateCart.d.ts +2 -1
- package/esm/funcs/cartsUpdateCart.d.ts.map +1 -1
- package/esm/funcs/cartsUpdateCart.js +11 -7
- package/esm/funcs/cartsUpdateCart.js.map +1 -1
- package/esm/funcs/catalogGetProductDetail.d.ts +2 -1
- package/esm/funcs/catalogGetProductDetail.d.ts.map +1 -1
- package/esm/funcs/catalogGetProductDetail.js +11 -7
- package/esm/funcs/catalogGetProductDetail.js.map +1 -1
- package/esm/funcs/catalogGetVariantDetail.d.ts +2 -1
- package/esm/funcs/catalogGetVariantDetail.d.ts.map +1 -1
- package/esm/funcs/catalogGetVariantDetail.js +11 -7
- package/esm/funcs/catalogGetVariantDetail.js.map +1 -1
- package/esm/funcs/catalogListCategories.d.ts +2 -1
- package/esm/funcs/catalogListCategories.d.ts.map +1 -1
- package/esm/funcs/catalogListCategories.js +11 -7
- package/esm/funcs/catalogListCategories.js.map +1 -1
- package/esm/funcs/catalogListCrosssellProducts.d.ts +2 -1
- package/esm/funcs/catalogListCrosssellProducts.d.ts.map +1 -1
- package/esm/funcs/catalogListCrosssellProducts.js +11 -7
- package/esm/funcs/catalogListCrosssellProducts.js.map +1 -1
- package/esm/funcs/catalogListProductReviews.d.ts +2 -1
- package/esm/funcs/catalogListProductReviews.d.ts.map +1 -1
- package/esm/funcs/catalogListProductReviews.js +11 -7
- package/esm/funcs/catalogListProductReviews.js.map +1 -1
- package/esm/funcs/catalogListProductVariants.d.ts +2 -1
- package/esm/funcs/catalogListProductVariants.d.ts.map +1 -1
- package/esm/funcs/catalogListProductVariants.js +11 -7
- package/esm/funcs/catalogListProductVariants.js.map +1 -1
- package/esm/funcs/catalogListProducts.d.ts +2 -1
- package/esm/funcs/catalogListProducts.d.ts.map +1 -1
- package/esm/funcs/catalogListProducts.js +11 -7
- package/esm/funcs/catalogListProducts.js.map +1 -1
- package/esm/funcs/catalogListSimilarProducts.d.ts +2 -1
- package/esm/funcs/catalogListSimilarProducts.d.ts.map +1 -1
- package/esm/funcs/catalogListSimilarProducts.js +11 -7
- package/esm/funcs/catalogListSimilarProducts.js.map +1 -1
- package/esm/funcs/catalogListSkus.d.ts +2 -1
- package/esm/funcs/catalogListSkus.d.ts.map +1 -1
- package/esm/funcs/catalogListSkus.js +11 -7
- package/esm/funcs/catalogListSkus.js.map +1 -1
- package/esm/funcs/catalogListUpsellProducts.d.ts +2 -1
- package/esm/funcs/catalogListUpsellProducts.d.ts.map +1 -1
- package/esm/funcs/catalogListUpsellProducts.js +11 -7
- package/esm/funcs/catalogListUpsellProducts.js.map +1 -1
- package/esm/funcs/catalogSearchProducts.d.ts +2 -1
- package/esm/funcs/catalogSearchProducts.d.ts.map +1 -1
- package/esm/funcs/catalogSearchProducts.js +11 -7
- package/esm/funcs/catalogSearchProducts.js.map +1 -1
- package/esm/funcs/commonListCountryPincodes.d.ts +2 -1
- package/esm/funcs/commonListCountryPincodes.d.ts.map +1 -1
- package/esm/funcs/commonListCountryPincodes.js +11 -7
- package/esm/funcs/commonListCountryPincodes.js.map +1 -1
- package/esm/funcs/customersCreateAddress.d.ts +2 -1
- package/esm/funcs/customersCreateAddress.d.ts.map +1 -1
- package/esm/funcs/customersCreateAddress.js +11 -7
- package/esm/funcs/customersCreateAddress.js.map +1 -1
- package/esm/funcs/customersDeleteAddress.d.ts +2 -1
- package/esm/funcs/customersDeleteAddress.d.ts.map +1 -1
- package/esm/funcs/customersDeleteAddress.js +11 -7
- package/esm/funcs/customersDeleteAddress.js.map +1 -1
- package/esm/funcs/customersGetAddressDetail.d.ts +2 -1
- package/esm/funcs/customersGetAddressDetail.d.ts.map +1 -1
- package/esm/funcs/customersGetAddressDetail.js +11 -7
- package/esm/funcs/customersGetAddressDetail.js.map +1 -1
- package/esm/funcs/customersListAddresses.d.ts +2 -1
- package/esm/funcs/customersListAddresses.d.ts.map +1 -1
- package/esm/funcs/customersListAddresses.js +11 -7
- package/esm/funcs/customersListAddresses.js.map +1 -1
- package/esm/funcs/customersListUserReviews.d.ts +2 -1
- package/esm/funcs/customersListUserReviews.d.ts.map +1 -1
- package/esm/funcs/customersListUserReviews.js +11 -7
- package/esm/funcs/customersListUserReviews.js.map +1 -1
- package/esm/funcs/customersUpdateAddressDetail.d.ts +2 -1
- package/esm/funcs/customersUpdateAddressDetail.d.ts.map +1 -1
- package/esm/funcs/customersUpdateAddressDetail.js +11 -7
- package/esm/funcs/customersUpdateAddressDetail.js.map +1 -1
- package/esm/funcs/ordersCancelOrder.d.ts +2 -1
- package/esm/funcs/ordersCancelOrder.d.ts.map +1 -1
- package/esm/funcs/ordersCancelOrder.js +11 -7
- package/esm/funcs/ordersCancelOrder.js.map +1 -1
- package/esm/funcs/ordersCreateOrder.d.ts +2 -1
- package/esm/funcs/ordersCreateOrder.d.ts.map +1 -1
- package/esm/funcs/ordersCreateOrder.js +11 -7
- package/esm/funcs/ordersCreateOrder.js.map +1 -1
- package/esm/funcs/ordersGetOrderDetail.d.ts +2 -1
- package/esm/funcs/ordersGetOrderDetail.d.ts.map +1 -1
- package/esm/funcs/ordersGetOrderDetail.js +11 -7
- package/esm/funcs/ordersGetOrderDetail.js.map +1 -1
- package/esm/funcs/ordersGetPaymentStatus.d.ts +2 -1
- package/esm/funcs/ordersGetPaymentStatus.d.ts.map +1 -1
- package/esm/funcs/ordersGetPaymentStatus.js +11 -7
- package/esm/funcs/ordersGetPaymentStatus.js.map +1 -1
- package/esm/funcs/ordersListOrderShipments.d.ts +2 -1
- package/esm/funcs/ordersListOrderShipments.d.ts.map +1 -1
- package/esm/funcs/ordersListOrderShipments.js +11 -7
- package/esm/funcs/ordersListOrderShipments.js.map +1 -1
- package/esm/funcs/ordersListOrders.d.ts +2 -1
- package/esm/funcs/ordersListOrders.d.ts.map +1 -1
- package/esm/funcs/ordersListOrders.js +11 -7
- package/esm/funcs/ordersListOrders.js.map +1 -1
- package/esm/funcs/ordersRetryOrderPayment.d.ts +2 -1
- package/esm/funcs/ordersRetryOrderPayment.d.ts.map +1 -1
- package/esm/funcs/ordersRetryOrderPayment.js +11 -7
- package/esm/funcs/ordersRetryOrderPayment.js.map +1 -1
- package/esm/funcs/shippingCheckDeliveryAvailability.d.ts +2 -1
- package/esm/funcs/shippingCheckDeliveryAvailability.d.ts.map +1 -1
- package/esm/funcs/shippingCheckDeliveryAvailability.js +11 -7
- package/esm/funcs/shippingCheckDeliveryAvailability.js.map +1 -1
- package/esm/hooks/types.d.ts +1 -1
- package/esm/hooks/types.d.ts.map +1 -1
- package/esm/lib/config.d.ts +7 -7
- package/esm/lib/config.d.ts.map +1 -1
- package/esm/lib/config.js +3 -3
- package/esm/lib/files.js.map +1 -1
- package/esm/lib/primitives.d.ts +3 -0
- package/esm/lib/primitives.d.ts.map +1 -1
- package/esm/lib/primitives.js +6 -0
- package/esm/lib/primitives.js.map +1 -1
- package/esm/lib/sdks.d.ts +1 -1
- package/esm/lib/sdks.d.ts.map +1 -1
- package/esm/lib/sdks.js +2 -8
- package/esm/lib/sdks.js.map +1 -1
- package/esm/lib/security.d.ts +4 -3
- package/esm/lib/security.d.ts.map +1 -1
- package/esm/lib/security.js +6 -1
- package/esm/lib/security.js.map +1 -1
- package/esm/mcp-server/build.d.mts.map +1 -0
- package/esm/mcp-server/build.mjs +14 -0
- package/esm/mcp-server/build.mjs.map +1 -0
- package/esm/mcp-server/cli/start/command.d.ts +2 -0
- package/esm/mcp-server/cli/start/command.d.ts.map +1 -0
- package/esm/mcp-server/cli/start/command.js +108 -0
- package/esm/mcp-server/cli/start/command.js.map +1 -0
- package/esm/mcp-server/cli/start/impl.d.ts +19 -0
- package/esm/mcp-server/cli/start/impl.d.ts.map +1 -0
- package/esm/mcp-server/cli/start/impl.js +100 -0
- package/esm/mcp-server/cli/start/impl.js.map +1 -0
- package/esm/mcp-server/cli.d.ts +6 -0
- package/esm/mcp-server/cli.d.ts.map +1 -0
- package/esm/mcp-server/cli.js +7 -0
- package/esm/mcp-server/cli.js.map +1 -0
- package/esm/mcp-server/console-logger.d.ts +7 -0
- package/esm/mcp-server/console-logger.d.ts.map +1 -0
- package/esm/mcp-server/console-logger.js +55 -0
- package/esm/mcp-server/console-logger.js.map +1 -0
- package/esm/mcp-server/extensions.d.ts +11 -0
- package/esm/mcp-server/extensions.d.ts.map +1 -0
- package/esm/mcp-server/extensions.js +5 -0
- package/esm/mcp-server/extensions.js.map +1 -0
- package/esm/mcp-server/mcp-server.d.ts +2 -0
- package/esm/mcp-server/mcp-server.d.ts.map +1 -0
- package/esm/mcp-server/mcp-server.js +23 -0
- package/esm/mcp-server/mcp-server.js.map +1 -0
- package/esm/mcp-server/prompts.d.ts +26 -0
- package/esm/mcp-server/prompts.d.ts.map +1 -0
- package/esm/mcp-server/prompts.js +43 -0
- package/esm/mcp-server/prompts.js.map +1 -0
- package/esm/mcp-server/resources.d.ts +32 -0
- package/esm/mcp-server/resources.d.ts.map +1 -0
- package/esm/mcp-server/resources.js +74 -0
- package/esm/mcp-server/resources.js.map +1 -0
- package/esm/mcp-server/scopes.d.ts +3 -0
- package/esm/mcp-server/scopes.d.ts.map +1 -0
- package/esm/mcp-server/scopes.js +5 -0
- package/esm/mcp-server/scopes.js.map +1 -0
- package/esm/mcp-server/server.d.ts +14 -0
- package/esm/mcp-server/server.d.ts.map +1 -0
- package/esm/mcp-server/server.js +129 -0
- package/esm/mcp-server/server.js.map +1 -0
- package/esm/mcp-server/shared.d.ts +7 -0
- package/esm/mcp-server/shared.d.ts.map +1 -0
- package/esm/mcp-server/shared.js +59 -0
- package/esm/mcp-server/shared.js.map +1 -0
- package/esm/mcp-server/tools/authCheckVerificationStatus.d.ts +8 -0
- package/esm/mcp-server/tools/authCheckVerificationStatus.d.ts.map +1 -0
- package/esm/mcp-server/tools/authCheckVerificationStatus.js +28 -0
- package/esm/mcp-server/tools/authCheckVerificationStatus.js.map +1 -0
- package/esm/mcp-server/tools/authCreateNotificationPreferences.d.ts +8 -0
- package/esm/mcp-server/tools/authCreateNotificationPreferences.d.ts.map +1 -0
- package/esm/mcp-server/tools/authCreateNotificationPreferences.js +28 -0
- package/esm/mcp-server/tools/authCreateNotificationPreferences.js.map +1 -0
- package/esm/mcp-server/tools/authGenerateOtp.d.ts +8 -0
- package/esm/mcp-server/tools/authGenerateOtp.d.ts.map +1 -0
- package/esm/mcp-server/tools/authGenerateOtp.js +28 -0
- package/esm/mcp-server/tools/authGenerateOtp.js.map +1 -0
- package/esm/mcp-server/tools/authGetNotificationPreferences.d.ts +8 -0
- package/esm/mcp-server/tools/authGetNotificationPreferences.d.ts.map +1 -0
- package/esm/mcp-server/tools/authGetNotificationPreferences.js +28 -0
- package/esm/mcp-server/tools/authGetNotificationPreferences.js.map +1 -0
- package/esm/mcp-server/tools/authGetUserDetail.d.ts +8 -0
- package/esm/mcp-server/tools/authGetUserDetail.d.ts.map +1 -0
- package/esm/mcp-server/tools/authGetUserDetail.js +28 -0
- package/esm/mcp-server/tools/authGetUserDetail.js.map +1 -0
- package/esm/mcp-server/tools/authLoginWithEmail.d.ts +8 -0
- package/esm/mcp-server/tools/authLoginWithEmail.d.ts.map +1 -0
- package/esm/mcp-server/tools/authLoginWithEmail.js +28 -0
- package/esm/mcp-server/tools/authLoginWithEmail.js.map +1 -0
- package/esm/mcp-server/tools/authLoginWithPhone.d.ts +8 -0
- package/esm/mcp-server/tools/authLoginWithPhone.d.ts.map +1 -0
- package/esm/mcp-server/tools/authLoginWithPhone.js +28 -0
- package/esm/mcp-server/tools/authLoginWithPhone.js.map +1 -0
- package/esm/mcp-server/tools/authLoginWithWhatsapp.d.ts +8 -0
- package/esm/mcp-server/tools/authLoginWithWhatsapp.d.ts.map +1 -0
- package/esm/mcp-server/tools/authLoginWithWhatsapp.js +28 -0
- package/esm/mcp-server/tools/authLoginWithWhatsapp.js.map +1 -0
- package/esm/mcp-server/tools/authLogout.d.ts +3 -0
- package/esm/mcp-server/tools/authLogout.d.ts.map +1 -0
- package/esm/mcp-server/tools/authLogout.js +23 -0
- package/esm/mcp-server/tools/authLogout.js.map +1 -0
- package/esm/mcp-server/tools/authRefreshToken.d.ts +8 -0
- package/esm/mcp-server/tools/authRefreshToken.d.ts.map +1 -0
- package/esm/mcp-server/tools/authRefreshToken.js +28 -0
- package/esm/mcp-server/tools/authRefreshToken.js.map +1 -0
- package/esm/mcp-server/tools/authUpdateNotificationPreferences.d.ts +8 -0
- package/esm/mcp-server/tools/authUpdateNotificationPreferences.d.ts.map +1 -0
- package/esm/mcp-server/tools/authUpdateNotificationPreferences.js +28 -0
- package/esm/mcp-server/tools/authUpdateNotificationPreferences.js.map +1 -0
- package/esm/mcp-server/tools/authUpdateUser.d.ts +8 -0
- package/esm/mcp-server/tools/authUpdateUser.d.ts.map +1 -0
- package/esm/mcp-server/tools/authUpdateUser.js +28 -0
- package/esm/mcp-server/tools/authUpdateUser.js.map +1 -0
- package/esm/mcp-server/tools/authVerifyOtp.d.ts +8 -0
- package/esm/mcp-server/tools/authVerifyOtp.d.ts.map +1 -0
- package/esm/mcp-server/tools/authVerifyOtp.js +28 -0
- package/esm/mcp-server/tools/authVerifyOtp.js.map +1 -0
- package/esm/mcp-server/tools/campaignsSubscribeNewsletter.d.ts +8 -0
- package/esm/mcp-server/tools/campaignsSubscribeNewsletter.d.ts.map +1 -0
- package/esm/mcp-server/tools/campaignsSubscribeNewsletter.js +28 -0
- package/esm/mcp-server/tools/campaignsSubscribeNewsletter.js.map +1 -0
- package/esm/mcp-server/tools/cartsApplyCoupon.d.ts +8 -0
- package/esm/mcp-server/tools/cartsApplyCoupon.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsApplyCoupon.js +28 -0
- package/esm/mcp-server/tools/cartsApplyCoupon.js.map +1 -0
- package/esm/mcp-server/tools/cartsCreateCart.d.ts +8 -0
- package/esm/mcp-server/tools/cartsCreateCart.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsCreateCart.js +28 -0
- package/esm/mcp-server/tools/cartsCreateCart.js.map +1 -0
- package/esm/mcp-server/tools/cartsCreateCartAddress.d.ts +8 -0
- package/esm/mcp-server/tools/cartsCreateCartAddress.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsCreateCartAddress.js +28 -0
- package/esm/mcp-server/tools/cartsCreateCartAddress.js.map +1 -0
- package/esm/mcp-server/tools/cartsDeleteCart.d.ts +8 -0
- package/esm/mcp-server/tools/cartsDeleteCart.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsDeleteCart.js +28 -0
- package/esm/mcp-server/tools/cartsDeleteCart.js.map +1 -0
- package/esm/mcp-server/tools/cartsGetCart.d.ts +8 -0
- package/esm/mcp-server/tools/cartsGetCart.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsGetCart.js +28 -0
- package/esm/mcp-server/tools/cartsGetCart.js.map +1 -0
- package/esm/mcp-server/tools/cartsGetUserCart.d.ts +8 -0
- package/esm/mcp-server/tools/cartsGetUserCart.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsGetUserCart.js +28 -0
- package/esm/mcp-server/tools/cartsGetUserCart.js.map +1 -0
- package/esm/mcp-server/tools/cartsRemoveCoupon.d.ts +8 -0
- package/esm/mcp-server/tools/cartsRemoveCoupon.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsRemoveCoupon.js +28 -0
- package/esm/mcp-server/tools/cartsRemoveCoupon.js.map +1 -0
- package/esm/mcp-server/tools/cartsRemoveUserCart.d.ts +8 -0
- package/esm/mcp-server/tools/cartsRemoveUserCart.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsRemoveUserCart.js +28 -0
- package/esm/mcp-server/tools/cartsRemoveUserCart.js.map +1 -0
- package/esm/mcp-server/tools/cartsUpdateCart.d.ts +8 -0
- package/esm/mcp-server/tools/cartsUpdateCart.d.ts.map +1 -0
- package/esm/mcp-server/tools/cartsUpdateCart.js +28 -0
- package/esm/mcp-server/tools/cartsUpdateCart.js.map +1 -0
- package/esm/mcp-server/tools/catalogGetProductDetail.d.ts +8 -0
- package/esm/mcp-server/tools/catalogGetProductDetail.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogGetProductDetail.js +28 -0
- package/esm/mcp-server/tools/catalogGetProductDetail.js.map +1 -0
- package/esm/mcp-server/tools/catalogGetVariantDetail.d.ts +8 -0
- package/esm/mcp-server/tools/catalogGetVariantDetail.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogGetVariantDetail.js +28 -0
- package/esm/mcp-server/tools/catalogGetVariantDetail.js.map +1 -0
- package/esm/mcp-server/tools/catalogListCategories.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListCategories.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListCategories.js +28 -0
- package/esm/mcp-server/tools/catalogListCategories.js.map +1 -0
- package/esm/mcp-server/tools/catalogListCrosssellProducts.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListCrosssellProducts.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListCrosssellProducts.js +28 -0
- package/esm/mcp-server/tools/catalogListCrosssellProducts.js.map +1 -0
- package/esm/mcp-server/tools/catalogListProductReviews.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListProductReviews.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListProductReviews.js +28 -0
- package/esm/mcp-server/tools/catalogListProductReviews.js.map +1 -0
- package/esm/mcp-server/tools/catalogListProductVariants.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListProductVariants.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListProductVariants.js +28 -0
- package/esm/mcp-server/tools/catalogListProductVariants.js.map +1 -0
- package/esm/mcp-server/tools/catalogListProducts.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListProducts.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListProducts.js +28 -0
- package/esm/mcp-server/tools/catalogListProducts.js.map +1 -0
- package/esm/mcp-server/tools/catalogListSimilarProducts.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListSimilarProducts.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListSimilarProducts.js +28 -0
- package/esm/mcp-server/tools/catalogListSimilarProducts.js.map +1 -0
- package/esm/mcp-server/tools/catalogListSkus.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListSkus.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListSkus.js +28 -0
- package/esm/mcp-server/tools/catalogListSkus.js.map +1 -0
- package/esm/mcp-server/tools/catalogListUpsellProducts.d.ts +8 -0
- package/esm/mcp-server/tools/catalogListUpsellProducts.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogListUpsellProducts.js +28 -0
- package/esm/mcp-server/tools/catalogListUpsellProducts.js.map +1 -0
- package/esm/mcp-server/tools/catalogSearchProducts.d.ts +8 -0
- package/esm/mcp-server/tools/catalogSearchProducts.d.ts.map +1 -0
- package/esm/mcp-server/tools/catalogSearchProducts.js +28 -0
- package/esm/mcp-server/tools/catalogSearchProducts.js.map +1 -0
- package/esm/mcp-server/tools/commonListCountryPincodes.d.ts +8 -0
- package/esm/mcp-server/tools/commonListCountryPincodes.d.ts.map +1 -0
- package/esm/mcp-server/tools/commonListCountryPincodes.js +28 -0
- package/esm/mcp-server/tools/commonListCountryPincodes.js.map +1 -0
- package/esm/mcp-server/tools/customersCreateAddress.d.ts +8 -0
- package/esm/mcp-server/tools/customersCreateAddress.d.ts.map +1 -0
- package/esm/mcp-server/tools/customersCreateAddress.js +28 -0
- package/esm/mcp-server/tools/customersCreateAddress.js.map +1 -0
- package/esm/mcp-server/tools/customersDeleteAddress.d.ts +8 -0
- package/esm/mcp-server/tools/customersDeleteAddress.d.ts.map +1 -0
- package/esm/mcp-server/tools/customersDeleteAddress.js +28 -0
- package/esm/mcp-server/tools/customersDeleteAddress.js.map +1 -0
- package/esm/mcp-server/tools/customersGetAddressDetail.d.ts +8 -0
- package/esm/mcp-server/tools/customersGetAddressDetail.d.ts.map +1 -0
- package/esm/mcp-server/tools/customersGetAddressDetail.js +28 -0
- package/esm/mcp-server/tools/customersGetAddressDetail.js.map +1 -0
- package/esm/mcp-server/tools/customersListAddresses.d.ts +8 -0
- package/esm/mcp-server/tools/customersListAddresses.d.ts.map +1 -0
- package/esm/mcp-server/tools/customersListAddresses.js +28 -0
- package/esm/mcp-server/tools/customersListAddresses.js.map +1 -0
- package/esm/mcp-server/tools/customersListUserReviews.d.ts +8 -0
- package/esm/mcp-server/tools/customersListUserReviews.d.ts.map +1 -0
- package/esm/mcp-server/tools/customersListUserReviews.js +28 -0
- package/esm/mcp-server/tools/customersListUserReviews.js.map +1 -0
- package/esm/mcp-server/tools/customersUpdateAddressDetail.d.ts +8 -0
- package/esm/mcp-server/tools/customersUpdateAddressDetail.d.ts.map +1 -0
- package/esm/mcp-server/tools/customersUpdateAddressDetail.js +28 -0
- package/esm/mcp-server/tools/customersUpdateAddressDetail.js.map +1 -0
- package/esm/mcp-server/tools/ordersCancelOrder.d.ts +8 -0
- package/esm/mcp-server/tools/ordersCancelOrder.d.ts.map +1 -0
- package/esm/mcp-server/tools/ordersCancelOrder.js +28 -0
- package/esm/mcp-server/tools/ordersCancelOrder.js.map +1 -0
- package/esm/mcp-server/tools/ordersCreateOrder.d.ts +8 -0
- package/esm/mcp-server/tools/ordersCreateOrder.d.ts.map +1 -0
- package/esm/mcp-server/tools/ordersCreateOrder.js +28 -0
- package/esm/mcp-server/tools/ordersCreateOrder.js.map +1 -0
- package/esm/mcp-server/tools/ordersGetOrderDetail.d.ts +8 -0
- package/esm/mcp-server/tools/ordersGetOrderDetail.d.ts.map +1 -0
- package/esm/mcp-server/tools/ordersGetOrderDetail.js +28 -0
- package/esm/mcp-server/tools/ordersGetOrderDetail.js.map +1 -0
- package/esm/mcp-server/tools/ordersGetPaymentStatus.d.ts +8 -0
- package/esm/mcp-server/tools/ordersGetPaymentStatus.d.ts.map +1 -0
- package/esm/mcp-server/tools/ordersGetPaymentStatus.js +28 -0
- package/esm/mcp-server/tools/ordersGetPaymentStatus.js.map +1 -0
- package/esm/mcp-server/tools/ordersListOrderShipments.d.ts +8 -0
- package/esm/mcp-server/tools/ordersListOrderShipments.d.ts.map +1 -0
- package/esm/mcp-server/tools/ordersListOrderShipments.js +28 -0
- package/esm/mcp-server/tools/ordersListOrderShipments.js.map +1 -0
- package/esm/mcp-server/tools/ordersListOrders.d.ts +8 -0
- package/esm/mcp-server/tools/ordersListOrders.d.ts.map +1 -0
- package/esm/mcp-server/tools/ordersListOrders.js +28 -0
- package/esm/mcp-server/tools/ordersListOrders.js.map +1 -0
- package/esm/mcp-server/tools/ordersRetryOrderPayment.d.ts +8 -0
- package/esm/mcp-server/tools/ordersRetryOrderPayment.d.ts.map +1 -0
- package/esm/mcp-server/tools/ordersRetryOrderPayment.js +28 -0
- package/esm/mcp-server/tools/ordersRetryOrderPayment.js.map +1 -0
- package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.d.ts +8 -0
- package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.d.ts.map +1 -0
- package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.js +28 -0
- package/esm/mcp-server/tools/shippingCheckDeliveryAvailability.js.map +1 -0
- package/esm/mcp-server/tools.d.ts +25 -0
- package/esm/mcp-server/tools.d.ts.map +1 -0
- package/esm/mcp-server/tools.js +77 -0
- package/esm/mcp-server/tools.js.map +1 -0
- package/esm/models/components/index.d.ts +1 -2
- package/esm/models/components/index.d.ts.map +1 -1
- package/esm/models/components/index.js +1 -2
- package/esm/models/components/index.js.map +1 -1
- package/esm/models/components/{sku.d.ts → item.d.ts} +22 -22
- package/esm/models/components/item.d.ts.map +1 -0
- package/esm/models/components/{sku.js → item.js} +26 -27
- package/esm/models/components/item.js.map +1 -0
- package/esm/models/components/juspaypaymentinfo.d.ts +9 -9
- package/esm/models/components/juspaypaymentinfo.js +3 -3
- package/esm/models/components/juspaypaymentinfo.js.map +1 -1
- package/esm/models/components/productdetail.d.ts +2 -2
- package/esm/models/components/productdetail.d.ts.map +1 -1
- package/esm/models/components/productdetail.js +2 -2
- package/esm/models/components/productdetail.js.map +1 -1
- package/esm/models/operations/index.d.ts +0 -1
- package/esm/models/operations/index.d.ts.map +1 -1
- package/esm/models/operations/index.js +0 -1
- package/esm/models/operations/index.js.map +1 -1
- package/esm/models/operations/listaddresses.d.ts +2 -2
- package/esm/models/operations/listaddresses.d.ts.map +1 -1
- package/esm/models/operations/listaddresses.js +2 -2
- package/esm/models/operations/listaddresses.js.map +1 -1
- package/esm/models/operations/listcrosssellproducts.d.ts +2 -2
- package/esm/models/operations/listcrosssellproducts.d.ts.map +1 -1
- package/esm/models/operations/listcrosssellproducts.js +2 -2
- package/esm/models/operations/listcrosssellproducts.js.map +1 -1
- package/esm/models/operations/listsimilarproducts.d.ts +2 -2
- package/esm/models/operations/listsimilarproducts.d.ts.map +1 -1
- package/esm/models/operations/listsimilarproducts.js +2 -2
- package/esm/models/operations/listsimilarproducts.js.map +1 -1
- package/esm/models/operations/listskus.d.ts +2 -2
- package/esm/models/operations/listskus.d.ts.map +1 -1
- package/esm/models/operations/listskus.js +2 -2
- package/esm/models/operations/listskus.js.map +1 -1
- package/esm/models/operations/listupsellproducts.d.ts +2 -2
- package/esm/models/operations/listupsellproducts.d.ts.map +1 -1
- package/esm/models/operations/listupsellproducts.js +2 -2
- package/esm/models/operations/listupsellproducts.js.map +1 -1
- package/esm/models/operations/searchproducts.d.ts +2 -2
- package/esm/models/operations/searchproducts.d.ts.map +1 -1
- package/esm/models/operations/searchproducts.js +2 -2
- package/esm/models/operations/searchproducts.js.map +1 -1
- package/esm/sdk/catalog.d.ts +0 -7
- package/esm/sdk/catalog.d.ts.map +1 -1
- package/esm/sdk/catalog.js +0 -10
- package/esm/sdk/catalog.js.map +1 -1
- package/esm/types/async.d.ts +23 -0
- package/esm/types/async.d.ts.map +1 -0
- package/esm/types/async.js +40 -0
- package/esm/types/async.js.map +1 -0
- package/jsr.json +1 -1
- package/package.json +16 -2
- package/src/funcs/authCheckVerificationStatus.ts +35 -8
- package/src/funcs/authCreateNotificationPreferences.ts +35 -8
- package/src/funcs/authGenerateOtp.ts +35 -8
- package/src/funcs/authGetAnonymousToken.ts +34 -7
- package/src/funcs/authGetNotificationPreferences.ts +35 -8
- package/src/funcs/authGetUserDetail.ts +35 -8
- package/src/funcs/authLoginWithEmail.ts +35 -8
- package/src/funcs/authLoginWithPhone.ts +35 -8
- package/src/funcs/authLoginWithWhatsapp.ts +35 -8
- package/src/funcs/authLogout.ts +32 -7
- package/src/funcs/authRefreshToken.ts +35 -8
- package/src/funcs/authUpdateNotificationPreferences.ts +35 -8
- package/src/funcs/authUpdateUser.ts +35 -8
- package/src/funcs/authVerifyOtp.ts +35 -8
- package/src/funcs/campaignsSubscribeNewsletter.ts +35 -8
- package/src/funcs/cartsApplyCoupon.ts +37 -8
- package/src/funcs/cartsCreateCart.ts +35 -8
- package/src/funcs/cartsCreateCartAddress.ts +38 -8
- package/src/funcs/cartsDeleteCart.ts +37 -8
- package/src/funcs/cartsGetCart.ts +37 -8
- package/src/funcs/cartsGetUserCart.ts +37 -8
- package/src/funcs/cartsRemoveCoupon.ts +37 -8
- package/src/funcs/cartsRemoveUserCart.ts +37 -8
- package/src/funcs/cartsUpdateCart.ts +38 -8
- package/src/funcs/catalogGetProductDetail.ts +37 -8
- package/src/funcs/catalogGetVariantDetail.ts +37 -8
- package/src/funcs/catalogListCategories.ts +35 -8
- package/src/funcs/catalogListCrosssellProducts.ts +37 -8
- package/src/funcs/catalogListProductReviews.ts +37 -8
- package/src/funcs/catalogListProductVariants.ts +37 -8
- package/src/funcs/catalogListProducts.ts +37 -8
- package/src/funcs/catalogListSimilarProducts.ts +37 -8
- package/src/funcs/catalogListSkus.ts +37 -8
- package/src/funcs/catalogListUpsellProducts.ts +37 -8
- package/src/funcs/catalogSearchProducts.ts +36 -8
- package/src/funcs/commonListCountryPincodes.ts +35 -8
- package/src/funcs/customersCreateAddress.ts +37 -8
- package/src/funcs/customersDeleteAddress.ts +37 -8
- package/src/funcs/customersGetAddressDetail.ts +37 -8
- package/src/funcs/customersListAddresses.ts +35 -8
- package/src/funcs/customersListUserReviews.ts +35 -8
- package/src/funcs/customersUpdateAddressDetail.ts +38 -8
- package/src/funcs/ordersCancelOrder.ts +37 -8
- package/src/funcs/ordersCreateOrder.ts +38 -8
- package/src/funcs/ordersGetOrderDetail.ts +37 -8
- package/src/funcs/ordersGetPaymentStatus.ts +35 -8
- package/src/funcs/ordersListOrderShipments.ts +37 -8
- package/src/funcs/ordersListOrders.ts +35 -8
- package/src/funcs/ordersRetryOrderPayment.ts +38 -8
- package/src/funcs/shippingCheckDeliveryAvailability.ts +36 -8
- package/src/hooks/types.ts +1 -1
- package/src/lib/config.ts +7 -7
- package/src/lib/files.ts +1 -1
- package/src/lib/primitives.ts +14 -0
- package/src/lib/sdks.ts +3 -8
- package/src/lib/security.ts +11 -3
- package/src/mcp-server/cli/start/command.ts +113 -0
- package/src/mcp-server/cli/start/impl.ts +137 -0
- package/src/mcp-server/cli.ts +13 -0
- package/src/mcp-server/console-logger.ts +71 -0
- package/src/mcp-server/extensions.ts +17 -0
- package/src/mcp-server/mcp-server.ts +26 -0
- package/src/mcp-server/prompts.ts +110 -0
- package/src/mcp-server/resources.ts +158 -0
- package/src/mcp-server/scopes.ts +7 -0
- package/src/mcp-server/server.ts +159 -0
- package/src/mcp-server/shared.ts +75 -0
- package/src/mcp-server/tools/authCheckVerificationStatus.ts +37 -0
- package/src/mcp-server/tools/authCreateNotificationPreferences.ts +39 -0
- package/src/mcp-server/tools/authGenerateOtp.ts +37 -0
- package/src/mcp-server/tools/authGetNotificationPreferences.ts +38 -0
- package/src/mcp-server/tools/authGetUserDetail.ts +37 -0
- package/src/mcp-server/tools/authLoginWithEmail.ts +37 -0
- package/src/mcp-server/tools/authLoginWithPhone.ts +37 -0
- package/src/mcp-server/tools/authLoginWithWhatsapp.ts +37 -0
- package/src/mcp-server/tools/authLogout.ts +30 -0
- package/src/mcp-server/tools/authRefreshToken.ts +37 -0
- package/src/mcp-server/tools/authUpdateNotificationPreferences.ts +39 -0
- package/src/mcp-server/tools/authUpdateUser.ts +37 -0
- package/src/mcp-server/tools/authVerifyOtp.ts +37 -0
- package/src/mcp-server/tools/campaignsSubscribeNewsletter.ts +37 -0
- package/src/mcp-server/tools/cartsApplyCoupon.ts +37 -0
- package/src/mcp-server/tools/cartsCreateCart.ts +37 -0
- package/src/mcp-server/tools/cartsCreateCartAddress.ts +37 -0
- package/src/mcp-server/tools/cartsDeleteCart.ts +37 -0
- package/src/mcp-server/tools/cartsGetCart.ts +37 -0
- package/src/mcp-server/tools/cartsGetUserCart.ts +37 -0
- package/src/mcp-server/tools/cartsRemoveCoupon.ts +37 -0
- package/src/mcp-server/tools/cartsRemoveUserCart.ts +37 -0
- package/src/mcp-server/tools/cartsUpdateCart.ts +37 -0
- package/src/mcp-server/tools/catalogGetProductDetail.ts +37 -0
- package/src/mcp-server/tools/catalogGetVariantDetail.ts +37 -0
- package/src/mcp-server/tools/catalogListCategories.ts +37 -0
- package/src/mcp-server/tools/catalogListCrosssellProducts.ts +37 -0
- package/src/mcp-server/tools/catalogListProductReviews.ts +37 -0
- package/src/mcp-server/tools/catalogListProductVariants.ts +37 -0
- package/src/mcp-server/tools/catalogListProducts.ts +37 -0
- package/src/mcp-server/tools/catalogListSimilarProducts.ts +37 -0
- package/src/mcp-server/tools/catalogListSkus.ts +37 -0
- package/src/mcp-server/tools/catalogListUpsellProducts.ts +37 -0
- package/src/mcp-server/tools/catalogSearchProducts.ts +37 -0
- package/src/mcp-server/tools/commonListCountryPincodes.ts +37 -0
- package/src/mcp-server/tools/customersCreateAddress.ts +37 -0
- package/src/mcp-server/tools/customersDeleteAddress.ts +37 -0
- package/src/mcp-server/tools/customersGetAddressDetail.ts +37 -0
- package/src/mcp-server/tools/customersListAddresses.ts +37 -0
- package/src/mcp-server/tools/customersListUserReviews.ts +37 -0
- package/src/mcp-server/tools/customersUpdateAddressDetail.ts +37 -0
- package/src/mcp-server/tools/ordersCancelOrder.ts +37 -0
- package/src/mcp-server/tools/ordersCreateOrder.ts +37 -0
- package/src/mcp-server/tools/ordersGetOrderDetail.ts +37 -0
- package/src/mcp-server/tools/ordersGetPaymentStatus.ts +37 -0
- package/src/mcp-server/tools/ordersListOrderShipments.ts +37 -0
- package/src/mcp-server/tools/ordersListOrders.ts +37 -0
- package/src/mcp-server/tools/ordersRetryOrderPayment.ts +37 -0
- package/src/mcp-server/tools/shippingCheckDeliveryAvailability.ts +39 -0
- package/src/mcp-server/tools.ts +126 -0
- package/src/models/components/index.ts +1 -2
- package/src/models/components/{sku.ts → item.ts} +34 -34
- package/src/models/components/juspaypaymentinfo.ts +3 -3
- package/src/models/components/productdetail.ts +4 -4
- package/src/models/operations/index.ts +0 -1
- package/src/models/operations/listaddresses.ts +4 -4
- package/src/models/operations/listcrosssellproducts.ts +4 -4
- package/src/models/operations/listsimilarproducts.ts +4 -4
- package/src/models/operations/listskus.ts +4 -4
- package/src/models/operations/listupsellproducts.ts +4 -4
- package/src/models/operations/searchproducts.ts +4 -4
- package/src/sdk/catalog.ts +0 -18
- package/src/types/async.ts +68 -0
- package/esm/funcs/catalogCreateProductReview.d.ts +0 -16
- package/esm/funcs/catalogCreateProductReview.d.ts.map +0 -1
- package/esm/funcs/catalogCreateProductReview.js +0 -93
- package/esm/funcs/catalogCreateProductReview.js.map +0 -1
- package/esm/models/components/createreview.d.ts +0 -42
- package/esm/models/components/createreview.d.ts.map +0 -1
- package/esm/models/components/createreview.js +0 -54
- package/esm/models/components/createreview.js.map +0 -1
- package/esm/models/components/sku.d.ts.map +0 -1
- package/esm/models/components/sku.js.map +0 -1
- package/esm/models/operations/createproductreview.d.ts +0 -65
- package/esm/models/operations/createproductreview.d.ts.map +0 -1
- package/esm/models/operations/createproductreview.js +0 -72
- package/esm/models/operations/createproductreview.js.map +0 -1
- package/src/funcs/catalogCreateProductReview.ts +0 -161
- package/src/models/components/createreview.ts +0 -98
- package/src/models/operations/createproductreview.ts +0 -152
|
@@ -12,7 +12,6 @@
|
|
|
12
12
|
* [getVariantDetail](#getvariantdetail) - Retrieve variant detail
|
|
13
13
|
* [listCategories](#listcategories) - List all categories
|
|
14
14
|
* [listProductReviews](#listproductreviews) - List all product reviews
|
|
15
|
-
* [createProductReview](#createproductreview) - Create product review
|
|
16
15
|
* [listSimilarProducts](#listsimilarproducts) - Retrieve similar products
|
|
17
16
|
* [listUpsellProducts](#listupsellproducts) - Retrieve up-sell products
|
|
18
17
|
* [listCrosssellProducts](#listcrosssellproducts) - Retrieve cross-sell products
|
|
@@ -568,95 +567,6 @@ run();
|
|
|
568
567
|
| errors.NotFound | 404 | application/json |
|
|
569
568
|
| errors.CeError | 4XX, 5XX | \*/\* |
|
|
570
569
|
|
|
571
|
-
## createProductReview
|
|
572
|
-
|
|
573
|
-
Create a product review
|
|
574
|
-
|
|
575
|
-
### Example Usage
|
|
576
|
-
|
|
577
|
-
```typescript
|
|
578
|
-
import { CeStorefront } from "ce-storefront";
|
|
579
|
-
|
|
580
|
-
const ceStorefront = new CeStorefront({
|
|
581
|
-
authorization: "<YOUR_BEARER_TOKEN_HERE>",
|
|
582
|
-
});
|
|
583
|
-
|
|
584
|
-
async function run() {
|
|
585
|
-
const result = await ceStorefront.catalog.createProductReview({
|
|
586
|
-
productId: "<id>",
|
|
587
|
-
createReview: {
|
|
588
|
-
orderNumber: "<value>",
|
|
589
|
-
rating: 3345.02,
|
|
590
|
-
userId: "<id>",
|
|
591
|
-
},
|
|
592
|
-
});
|
|
593
|
-
|
|
594
|
-
// Handle the result
|
|
595
|
-
console.log(result);
|
|
596
|
-
}
|
|
597
|
-
|
|
598
|
-
run();
|
|
599
|
-
```
|
|
600
|
-
|
|
601
|
-
### Standalone function
|
|
602
|
-
|
|
603
|
-
The standalone function version of this method:
|
|
604
|
-
|
|
605
|
-
```typescript
|
|
606
|
-
import { CeStorefrontCore } from "ce-storefront/core.js";
|
|
607
|
-
import { catalogCreateProductReview } from "ce-storefront/funcs/catalogCreateProductReview.js";
|
|
608
|
-
|
|
609
|
-
// Use `CeStorefrontCore` for best tree-shaking performance.
|
|
610
|
-
// You can create one instance of it to use across an application.
|
|
611
|
-
const ceStorefront = new CeStorefrontCore({
|
|
612
|
-
authorization: "<YOUR_BEARER_TOKEN_HERE>",
|
|
613
|
-
});
|
|
614
|
-
|
|
615
|
-
async function run() {
|
|
616
|
-
const res = await catalogCreateProductReview(ceStorefront, {
|
|
617
|
-
productId: "<id>",
|
|
618
|
-
createReview: {
|
|
619
|
-
orderNumber: "<value>",
|
|
620
|
-
rating: 3345.02,
|
|
621
|
-
userId: "<id>",
|
|
622
|
-
},
|
|
623
|
-
});
|
|
624
|
-
|
|
625
|
-
if (!res.ok) {
|
|
626
|
-
throw res.error;
|
|
627
|
-
}
|
|
628
|
-
|
|
629
|
-
const { value: result } = res;
|
|
630
|
-
|
|
631
|
-
// Handle the result
|
|
632
|
-
console.log(result);
|
|
633
|
-
}
|
|
634
|
-
|
|
635
|
-
run();
|
|
636
|
-
```
|
|
637
|
-
|
|
638
|
-
### Parameters
|
|
639
|
-
|
|
640
|
-
| Parameter | Type | Required | Description |
|
|
641
|
-
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
642
|
-
| `request` | [operations.CreateProductReviewRequest](../../models/operations/createproductreviewrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
643
|
-
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
644
|
-
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
645
|
-
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
646
|
-
|
|
647
|
-
### Response
|
|
648
|
-
|
|
649
|
-
**Promise\<[operations.CreateProductReviewResponseBody](../../models/operations/createproductreviewresponsebody.md)\>**
|
|
650
|
-
|
|
651
|
-
### Errors
|
|
652
|
-
|
|
653
|
-
| Error Type | Status Code | Content Type |
|
|
654
|
-
| ------------------- | ------------------- | ------------------- |
|
|
655
|
-
| errors.BadRequest | 400 | application/json |
|
|
656
|
-
| errors.Unauthorized | 401 | application/json |
|
|
657
|
-
| errors.NotFound | 404 | application/json |
|
|
658
|
-
| errors.CeError | 4XX, 5XX | \*/\* |
|
|
659
|
-
|
|
660
570
|
## listSimilarProducts
|
|
661
571
|
|
|
662
572
|
Retrieves a list of products similar to a specified product based on their attributes and category. The similar products are returned sorted by relevance, with the most closely matching products appearing first. Useful for providing product recommendations to your customers.
|
|
@@ -4,6 +4,7 @@ import { CeError } from "../models/errors/ceerror.js";
|
|
|
4
4
|
import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
|
|
5
5
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
6
6
|
import * as operations from "../models/operations/index.js";
|
|
7
|
+
import { APIPromise } from "../types/async.js";
|
|
7
8
|
import { Result } from "../types/fp.js";
|
|
8
9
|
/**
|
|
9
10
|
* Check email/phone verification status
|
|
@@ -11,5 +12,5 @@ import { Result } from "../types/fp.js";
|
|
|
11
12
|
* @remarks
|
|
12
13
|
* The Check Verification Status API allows to verify the status of email and phone number verification for a specific user. Upon a successful request, the API responds with the verification status of the provided email and phone number. If the user is not found or there's an issue with the request, an error response is returned with an appropriate message.
|
|
13
14
|
*/
|
|
14
|
-
export declare function authCheckVerificationStatus(client: CeStorefrontCore, request: operations.CheckVerificationStatusRequestBody, options?: RequestOptions):
|
|
15
|
+
export declare function authCheckVerificationStatus(client: CeStorefrontCore, request: operations.CheckVerificationStatusRequestBody, options?: RequestOptions): APIPromise<Result<operations.CheckVerificationStatusResponseBody, CeError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
|
|
15
16
|
//# sourceMappingURL=authCheckVerificationStatus.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authCheckVerificationStatus.d.ts","sourceRoot":"","sources":["../../src/funcs/authCheckVerificationStatus.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,
|
|
1
|
+
{"version":3,"file":"authCheckVerificationStatus.d.ts","sourceRoot":"","sources":["../../src/funcs/authCheckVerificationStatus.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAW,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,gBAAgB,EACxB,OAAO,EAAE,UAAU,CAAC,kCAAkC,EACtD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CACX,MAAM,CACJ,UAAU,CAAC,mCAAmC,EAC5C,OAAO,GACP,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAMA"}
|
|
@@ -8,16 +8,20 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
8
8
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
9
9
|
import { pathToFunc } from "../lib/url.js";
|
|
10
10
|
import * as operations from "../models/operations/index.js";
|
|
11
|
+
import { APIPromise } from "../types/async.js";
|
|
11
12
|
/**
|
|
12
13
|
* Check email/phone verification status
|
|
13
14
|
*
|
|
14
15
|
* @remarks
|
|
15
16
|
* The Check Verification Status API allows to verify the status of email and phone number verification for a specific user. Upon a successful request, the API responds with the verification status of the provided email and phone number. If the user is not found or there's an issue with the request, an error response is returned with an appropriate message.
|
|
16
17
|
*/
|
|
17
|
-
export
|
|
18
|
+
export function authCheckVerificationStatus(client, request, options) {
|
|
19
|
+
return new APIPromise($do(client, request, options));
|
|
20
|
+
}
|
|
21
|
+
async function $do(client, request, options) {
|
|
18
22
|
const parsed = safeParse(request, (value) => operations.CheckVerificationStatusRequestBody$outboundSchema.parse(value), "Input validation failed");
|
|
19
23
|
if (!parsed.ok) {
|
|
20
|
-
return parsed;
|
|
24
|
+
return [parsed, { status: "invalid" }];
|
|
21
25
|
}
|
|
22
26
|
const payload = parsed.value;
|
|
23
27
|
const body = encodeJSON("body", payload, { explode: true });
|
|
@@ -30,7 +34,7 @@ export async function authCheckVerificationStatus(client, request, options) {
|
|
|
30
34
|
const securityInput = secConfig == null ? {} : { authorization: secConfig };
|
|
31
35
|
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
32
36
|
const context = {
|
|
33
|
-
baseURL: options?.serverURL ?? "",
|
|
37
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
34
38
|
operationID: "check-verification-status",
|
|
35
39
|
oAuth2Scopes: [],
|
|
36
40
|
resolvedSecurity: requestSecurity,
|
|
@@ -50,7 +54,7 @@ export async function authCheckVerificationStatus(client, request, options) {
|
|
|
50
54
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
51
55
|
}, options);
|
|
52
56
|
if (!requestRes.ok) {
|
|
53
|
-
return requestRes;
|
|
57
|
+
return [requestRes, { status: "invalid" }];
|
|
54
58
|
}
|
|
55
59
|
const req = requestRes.value;
|
|
56
60
|
const doResult = await client._do(req, {
|
|
@@ -60,13 +64,13 @@ export async function authCheckVerificationStatus(client, request, options) {
|
|
|
60
64
|
retryCodes: context.retryCodes,
|
|
61
65
|
});
|
|
62
66
|
if (!doResult.ok) {
|
|
63
|
-
return doResult;
|
|
67
|
+
return [doResult, { status: "request-error", request: req }];
|
|
64
68
|
}
|
|
65
69
|
const response = doResult.value;
|
|
66
70
|
const [result] = await M.match(M.json(200, operations.CheckVerificationStatusResponseBody$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response);
|
|
67
71
|
if (!result.ok) {
|
|
68
|
-
return result;
|
|
72
|
+
return [result, { status: "complete", request: req, response }];
|
|
69
73
|
}
|
|
70
|
-
return result;
|
|
74
|
+
return [result, { status: "complete", request: req, response }];
|
|
71
75
|
}
|
|
72
76
|
//# sourceMappingURL=authCheckVerificationStatus.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authCheckVerificationStatus.js","sourceRoot":"","sources":["../../src/funcs/authCheckVerificationStatus.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,KAAK,CAAC,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAE9C,OAAO,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAU3C,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"authCheckVerificationStatus.js","sourceR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ACnB,OAAO,CAAC,UAAU,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;IAC7C,CAAC;IACD,MAAM,GAAG,GAAG,UAAU,CAAC,KAAK,CAAC;IAE7B,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,GAAG,EAAE;QACrC,OAAO;QACP,UAAU,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC;QAC1B,WAAW,EAAE,OAAO,CAAC,WAAW;QAChC,UAAU,EAAE,OAAO,CAAC,UAAU;KAC/B,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,CAAC,QAAQ,EAAE,EAAE,MAAM,EAAE,eAAe,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,CAAC;IAC/D,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,MAAM,CAAC,GAAG,MAAM,CAAC,CAAC,KAAK,CAU5B,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,CAAC,iDAAiD,CAAC,EACzE,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,EACb,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CACd,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC;QACf,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;IAClE,CAAC;IAED,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;AAClE,CAAC"}
|
|
@@ -4,6 +4,7 @@ import { CeError } from "../models/errors/ceerror.js";
|
|
|
4
4
|
import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
|
|
5
5
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
6
6
|
import * as operations from "../models/operations/index.js";
|
|
7
|
+
import { APIPromise } from "../types/async.js";
|
|
7
8
|
import { Result } from "../types/fp.js";
|
|
8
9
|
/**
|
|
9
10
|
* Create user notification preferences
|
|
@@ -11,5 +12,5 @@ import { Result } from "../types/fp.js";
|
|
|
11
12
|
* @remarks
|
|
12
13
|
* Create user notification preferences API allows clients to create a user's notification preferences based on their unique user identifier (user_id).
|
|
13
14
|
*/
|
|
14
|
-
export declare function authCreateNotificationPreferences(client: CeStorefrontCore, request: operations.CreateNotificationPreferencesRequest, options?: RequestOptions):
|
|
15
|
+
export declare function authCreateNotificationPreferences(client: CeStorefrontCore, request: operations.CreateNotificationPreferencesRequest, options?: RequestOptions): APIPromise<Result<operations.CreateNotificationPreferencesResponseBody, CeError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
|
|
15
16
|
//# sourceMappingURL=authCreateNotificationPreferences.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authCreateNotificationPreferences.d.ts","sourceRoot":"","sources":["../../src/funcs/authCreateNotificationPreferences.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,
|
|
1
|
+
{"version":3,"file":"authCreateNotificationPreferences.d.ts","sourceRoot":"","sources":["../../src/funcs/authCreateNotificationPreferences.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAW,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAgB,iCAAiC,CAC/C,MAAM,EAAE,gBAAgB,EACxB,OAAO,EAAE,UAAU,CAAC,oCAAoC,EACxD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CACX,MAAM,CACJ,UAAU,CAAC,yCAAyC,EAClD,OAAO,GACP,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAMA"}
|
|
@@ -8,16 +8,20 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
8
8
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
9
9
|
import { pathToFunc } from "../lib/url.js";
|
|
10
10
|
import * as operations from "../models/operations/index.js";
|
|
11
|
+
import { APIPromise } from "../types/async.js";
|
|
11
12
|
/**
|
|
12
13
|
* Create user notification preferences
|
|
13
14
|
*
|
|
14
15
|
* @remarks
|
|
15
16
|
* Create user notification preferences API allows clients to create a user's notification preferences based on their unique user identifier (user_id).
|
|
16
17
|
*/
|
|
17
|
-
export
|
|
18
|
+
export function authCreateNotificationPreferences(client, request, options) {
|
|
19
|
+
return new APIPromise($do(client, request, options));
|
|
20
|
+
}
|
|
21
|
+
async function $do(client, request, options) {
|
|
18
22
|
const parsed = safeParse(request, (value) => operations.CreateNotificationPreferencesRequest$outboundSchema.parse(value), "Input validation failed");
|
|
19
23
|
if (!parsed.ok) {
|
|
20
|
-
return parsed;
|
|
24
|
+
return [parsed, { status: "invalid" }];
|
|
21
25
|
}
|
|
22
26
|
const payload = parsed.value;
|
|
23
27
|
const body = encodeJSON("body", payload.RequestBody, { explode: true });
|
|
@@ -36,7 +40,7 @@ export async function authCreateNotificationPreferences(client, request, options
|
|
|
36
40
|
const securityInput = secConfig == null ? {} : { authorization: secConfig };
|
|
37
41
|
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
38
42
|
const context = {
|
|
39
|
-
baseURL: options?.serverURL ?? "",
|
|
43
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
40
44
|
operationID: "create-notification-preferences",
|
|
41
45
|
oAuth2Scopes: [],
|
|
42
46
|
resolvedSecurity: requestSecurity,
|
|
@@ -56,7 +60,7 @@ export async function authCreateNotificationPreferences(client, request, options
|
|
|
56
60
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
57
61
|
}, options);
|
|
58
62
|
if (!requestRes.ok) {
|
|
59
|
-
return requestRes;
|
|
63
|
+
return [requestRes, { status: "invalid" }];
|
|
60
64
|
}
|
|
61
65
|
const req = requestRes.value;
|
|
62
66
|
const doResult = await client._do(req, {
|
|
@@ -66,13 +70,13 @@ export async function authCreateNotificationPreferences(client, request, options
|
|
|
66
70
|
retryCodes: context.retryCodes,
|
|
67
71
|
});
|
|
68
72
|
if (!doResult.ok) {
|
|
69
|
-
return doResult;
|
|
73
|
+
return [doResult, { status: "request-error", request: req }];
|
|
70
74
|
}
|
|
71
75
|
const response = doResult.value;
|
|
72
76
|
const [result] = await M.match(M.json(200, operations.CreateNotificationPreferencesResponseBody$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response);
|
|
73
77
|
if (!result.ok) {
|
|
74
|
-
return result;
|
|
78
|
+
return [result, { status: "complete", request: req, response }];
|
|
75
79
|
}
|
|
76
|
-
return result;
|
|
80
|
+
return [result, { status: "complete", request: req, response }];
|
|
77
81
|
}
|
|
78
82
|
//# sourceMappingURL=authCreateNotificationPreferences.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authCreateNotificationPreferences.js","sourceRoot":"","sources":["../../src/funcs/authCreateNotificationPreferences.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC/D,OAAO,KAAK,CAAC,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAE9C,OAAO,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAU3C,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"authCreateNotificationPreferences.js","sourceRoot":"","sources":["../../src/funcs/authCreateNotificationPreferences.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AAC/D,OAAO,KAAK,CAAC,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAE9C,OAAO,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAU3C,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OA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CAAC;QAC1B,WAAW,EAAE,OAAO,CAAC,WAAW;QAChC,UAAU,EAAE,OAAO,CAAC,UAAU;KAC/B,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,CAAC,QAAQ,EAAE,EAAE,MAAM,EAAE,eAAe,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,CAAC;IAC/D,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,MAAM,CAAC,GAAG,MAAM,CAAC,CAAC,KAAK,CAU5B,CAAC,CAAC,IAAI,CACJ,GAAG,EACH,UAAU,CAAC,uDAAuD,CACnE,EACD,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,EACb,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CACd,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC;QACf,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;IAClE,CAAC;IAED,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;AAClE,CAAC"}
|
|
@@ -4,6 +4,7 @@ import { CeError } from "../models/errors/ceerror.js";
|
|
|
4
4
|
import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
|
|
5
5
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
6
6
|
import * as operations from "../models/operations/index.js";
|
|
7
|
+
import { APIPromise } from "../types/async.js";
|
|
7
8
|
import { Result } from "../types/fp.js";
|
|
8
9
|
/**
|
|
9
10
|
* Generate OTP
|
|
@@ -11,5 +12,5 @@ import { Result } from "../types/fp.js";
|
|
|
11
12
|
* @remarks
|
|
12
13
|
* Generating a One-Time Password (OTP) typically involves creating a random code that is sent to a user for authentication or verification purposes.
|
|
13
14
|
*/
|
|
14
|
-
export declare function authGenerateOtp(client: CeStorefrontCore, request: operations.GenerateOtpRequestBody, options?: RequestOptions):
|
|
15
|
+
export declare function authGenerateOtp(client: CeStorefrontCore, request: operations.GenerateOtpRequestBody, options?: RequestOptions): APIPromise<Result<operations.GenerateOtpResponseBody, CeError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
|
|
15
16
|
//# sourceMappingURL=authGenerateOtp.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authGenerateOtp.d.ts","sourceRoot":"","sources":["../../src/funcs/authGenerateOtp.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,
|
|
1
|
+
{"version":3,"file":"authGenerateOtp.d.ts","sourceRoot":"","sources":["../../src/funcs/authGenerateOtp.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAW,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAgB,eAAe,CAC7B,MAAM,EAAE,gBAAgB,EACxB,OAAO,EAAE,UAAU,CAAC,sBAAsB,EAC1C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CACX,MAAM,CACJ,UAAU,CAAC,uBAAuB,EAChC,OAAO,GACP,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAMA"}
|
|
@@ -8,16 +8,20 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
8
8
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
9
9
|
import { pathToFunc } from "../lib/url.js";
|
|
10
10
|
import * as operations from "../models/operations/index.js";
|
|
11
|
+
import { APIPromise } from "../types/async.js";
|
|
11
12
|
/**
|
|
12
13
|
* Generate OTP
|
|
13
14
|
*
|
|
14
15
|
* @remarks
|
|
15
16
|
* Generating a One-Time Password (OTP) typically involves creating a random code that is sent to a user for authentication or verification purposes.
|
|
16
17
|
*/
|
|
17
|
-
export
|
|
18
|
+
export function authGenerateOtp(client, request, options) {
|
|
19
|
+
return new APIPromise($do(client, request, options));
|
|
20
|
+
}
|
|
21
|
+
async function $do(client, request, options) {
|
|
18
22
|
const parsed = safeParse(request, (value) => operations.GenerateOtpRequestBody$outboundSchema.parse(value), "Input validation failed");
|
|
19
23
|
if (!parsed.ok) {
|
|
20
|
-
return parsed;
|
|
24
|
+
return [parsed, { status: "invalid" }];
|
|
21
25
|
}
|
|
22
26
|
const payload = parsed.value;
|
|
23
27
|
const body = encodeJSON("body", payload, { explode: true });
|
|
@@ -30,7 +34,7 @@ export async function authGenerateOtp(client, request, options) {
|
|
|
30
34
|
const securityInput = secConfig == null ? {} : { authorization: secConfig };
|
|
31
35
|
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
32
36
|
const context = {
|
|
33
|
-
baseURL: options?.serverURL ?? "",
|
|
37
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
34
38
|
operationID: "generate-otp",
|
|
35
39
|
oAuth2Scopes: [],
|
|
36
40
|
resolvedSecurity: requestSecurity,
|
|
@@ -50,7 +54,7 @@ export async function authGenerateOtp(client, request, options) {
|
|
|
50
54
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
51
55
|
}, options);
|
|
52
56
|
if (!requestRes.ok) {
|
|
53
|
-
return requestRes;
|
|
57
|
+
return [requestRes, { status: "invalid" }];
|
|
54
58
|
}
|
|
55
59
|
const req = requestRes.value;
|
|
56
60
|
const doResult = await client._do(req, {
|
|
@@ -60,13 +64,13 @@ export async function authGenerateOtp(client, request, options) {
|
|
|
60
64
|
retryCodes: context.retryCodes,
|
|
61
65
|
});
|
|
62
66
|
if (!doResult.ok) {
|
|
63
|
-
return doResult;
|
|
67
|
+
return [doResult, { status: "request-error", request: req }];
|
|
64
68
|
}
|
|
65
69
|
const response = doResult.value;
|
|
66
70
|
const [result] = await M.match(M.json(200, operations.GenerateOtpResponseBody$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response);
|
|
67
71
|
if (!result.ok) {
|
|
68
|
-
return result;
|
|
72
|
+
return [result, { status: "complete", request: req, response }];
|
|
69
73
|
}
|
|
70
|
-
return result;
|
|
74
|
+
return [result, { status: "complete", request: req, response }];
|
|
71
75
|
}
|
|
72
76
|
//# sourceMappingURL=authGenerateOtp.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authGenerateOtp.js","sourceRoot":"","sources":["../../src/funcs/authGenerateOtp.ts"],"names":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IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC;QACf,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;IAClE,CAAC;IAED,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;AAClE,CAAC"}
|
|
@@ -4,6 +4,7 @@ import { CeError } from "../models/errors/ceerror.js";
|
|
|
4
4
|
import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
|
|
5
5
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
6
6
|
import * as operations from "../models/operations/index.js";
|
|
7
|
+
import { APIPromise } from "../types/async.js";
|
|
7
8
|
import { Result } from "../types/fp.js";
|
|
8
9
|
/**
|
|
9
10
|
* Anonymous user
|
|
@@ -12,5 +13,5 @@ import { Result } from "../types/fp.js";
|
|
|
12
13
|
* This API’s focus is on anonymous users who have not undergone the formal account creation process. These anonymous users are associated with a unique ID, ensuring that even in the absence of a fully realized account, there is a distinct and trackable identity for each user.
|
|
13
14
|
* To interact with the system, each anonymous user is issued an access token. This access token plays a dual role in the system: it serves as a means of authenticating the user and it also acts as a tool for authorization, determining what actions the authenticated user is permitted to perform.
|
|
14
15
|
*/
|
|
15
|
-
export declare function authGetAnonymousToken(client: CeStorefrontCore, security: operations.GetAnonymousTokenSecurity, options?: RequestOptions):
|
|
16
|
+
export declare function authGetAnonymousToken(client: CeStorefrontCore, security: operations.GetAnonymousTokenSecurity, options?: RequestOptions): APIPromise<Result<operations.GetAnonymousTokenResponseBody, CeError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
|
|
16
17
|
//# sourceMappingURL=authGetAnonymousToken.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authGetAnonymousToken.d.ts","sourceRoot":"","sources":["../../src/funcs/authGetAnonymousToken.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAG9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;;GAMG;AACH,
|
|
1
|
+
{"version":3,"file":"authGetAnonymousToken.d.ts","sourceRoot":"","sources":["../../src/funcs/authGetAnonymousToken.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAG9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAW,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,gBAAgB,EACxB,QAAQ,EAAE,UAAU,CAAC,yBAAyB,EAC9C,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CACX,MAAM,CACJ,UAAU,CAAC,6BAA6B,EACtC,OAAO,GACP,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAMA"}
|
|
@@ -6,6 +6,7 @@ import { compactMap } from "../lib/primitives.js";
|
|
|
6
6
|
import { resolveSecurity } from "../lib/security.js";
|
|
7
7
|
import { pathToFunc } from "../lib/url.js";
|
|
8
8
|
import * as operations from "../models/operations/index.js";
|
|
9
|
+
import { APIPromise } from "../types/async.js";
|
|
9
10
|
/**
|
|
10
11
|
* Anonymous user
|
|
11
12
|
*
|
|
@@ -13,7 +14,10 @@ import * as operations from "../models/operations/index.js";
|
|
|
13
14
|
* This API’s focus is on anonymous users who have not undergone the formal account creation process. These anonymous users are associated with a unique ID, ensuring that even in the absence of a fully realized account, there is a distinct and trackable identity for each user.
|
|
14
15
|
* To interact with the system, each anonymous user is issued an access token. This access token plays a dual role in the system: it serves as a means of authenticating the user and it also acts as a tool for authorization, determining what actions the authenticated user is permitted to perform.
|
|
15
16
|
*/
|
|
16
|
-
export
|
|
17
|
+
export function authGetAnonymousToken(client, security, options) {
|
|
18
|
+
return new APIPromise($do(client, security, options));
|
|
19
|
+
}
|
|
20
|
+
async function $do(client, security, options) {
|
|
17
21
|
const path = pathToFunc("/auth/anonymous")();
|
|
18
22
|
const headers = new Headers(compactMap({
|
|
19
23
|
Accept: "application/json",
|
|
@@ -26,7 +30,7 @@ export async function authGetAnonymousToken(client, security, options) {
|
|
|
26
30
|
},
|
|
27
31
|
]);
|
|
28
32
|
const context = {
|
|
29
|
-
baseURL: options?.serverURL ?? "",
|
|
33
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
30
34
|
operationID: "get-anonymous-token",
|
|
31
35
|
oAuth2Scopes: [],
|
|
32
36
|
resolvedSecurity: requestSecurity,
|
|
@@ -45,7 +49,7 @@ export async function authGetAnonymousToken(client, security, options) {
|
|
|
45
49
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
46
50
|
}, options);
|
|
47
51
|
if (!requestRes.ok) {
|
|
48
|
-
return requestRes;
|
|
52
|
+
return [requestRes, { status: "invalid" }];
|
|
49
53
|
}
|
|
50
54
|
const req = requestRes.value;
|
|
51
55
|
const doResult = await client._do(req, {
|
|
@@ -55,13 +59,13 @@ export async function authGetAnonymousToken(client, security, options) {
|
|
|
55
59
|
retryCodes: context.retryCodes,
|
|
56
60
|
});
|
|
57
61
|
if (!doResult.ok) {
|
|
58
|
-
return doResult;
|
|
62
|
+
return [doResult, { status: "request-error", request: req }];
|
|
59
63
|
}
|
|
60
64
|
const response = doResult.value;
|
|
61
65
|
const [result] = await M.match(M.json(200, operations.GetAnonymousTokenResponseBody$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response);
|
|
62
66
|
if (!result.ok) {
|
|
63
|
-
return result;
|
|
67
|
+
return [result, { status: "complete", request: req, response }];
|
|
64
68
|
}
|
|
65
|
-
return result;
|
|
69
|
+
return [result, { status: "complete", request: req, response }];
|
|
66
70
|
}
|
|
67
71
|
//# sourceMappingURL=authGetAnonymousToken.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authGetAnonymousToken.js","sourceRoot":"","sources":["../../src/funcs/authGetAnonymousToken.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,KAAK,CAAC,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAElD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAU3C,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"authGetAnonymousToken.js","sourceRoot":"","sources":["../../src/funcs/authGetAnonymousToken.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,KAAK,CAAC,MAA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AAE,EAAE,CAAC;QACf,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;IAClE,CAAC;IAED,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;AAClE,CAAC"}
|
|
@@ -4,6 +4,7 @@ import { CeError } from "../models/errors/ceerror.js";
|
|
|
4
4
|
import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
|
|
5
5
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
6
6
|
import * as operations from "../models/operations/index.js";
|
|
7
|
+
import { APIPromise } from "../types/async.js";
|
|
7
8
|
import { Result } from "../types/fp.js";
|
|
8
9
|
/**
|
|
9
10
|
* Retrieve user notification preferences
|
|
@@ -11,5 +12,5 @@ import { Result } from "../types/fp.js";
|
|
|
11
12
|
* @remarks
|
|
12
13
|
* The Retrieve Notification Preferences API allows clients to fetch a user's notification preferences based on their unique user identifier (user_id).
|
|
13
14
|
*/
|
|
14
|
-
export declare function authGetNotificationPreferences(client: CeStorefrontCore, request: operations.GetNotificationPreferencesRequest, options?: RequestOptions):
|
|
15
|
+
export declare function authGetNotificationPreferences(client: CeStorefrontCore, request: operations.GetNotificationPreferencesRequest, options?: RequestOptions): APIPromise<Result<operations.GetNotificationPreferencesResponseBody, CeError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
|
|
15
16
|
//# sourceMappingURL=authGetNotificationPreferences.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authGetNotificationPreferences.d.ts","sourceRoot":"","sources":["../../src/funcs/authGetNotificationPreferences.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,
|
|
1
|
+
{"version":3,"file":"authGetNotificationPreferences.d.ts","sourceRoot":"","sources":["../../src/funcs/authGetNotificationPreferences.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAK9C,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAGhD,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AACtD,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,kBAAkB,EAAE,MAAM,wCAAwC,CAAC;AAC5E,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;AAC5D,OAAO,EAAW,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACxD,OAAO,EAAE,MAAM,EAAE,MAAM,gBAAgB,CAAC;AAExC;;;;;GAKG;AACH,wBAAgB,8BAA8B,CAC5C,MAAM,EAAE,gBAAgB,EACxB,OAAO,EAAE,UAAU,CAAC,iCAAiC,EACrD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CACX,MAAM,CACJ,UAAU,CAAC,sCAAsC,EAC/C,OAAO,GACP,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,mBAAmB,GACnB,mBAAmB,GACnB,eAAe,CAClB,CACF,CAMA"}
|
|
@@ -8,16 +8,20 @@ import { safeParse } from "../lib/schemas.js";
|
|
|
8
8
|
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
9
9
|
import { pathToFunc } from "../lib/url.js";
|
|
10
10
|
import * as operations from "../models/operations/index.js";
|
|
11
|
+
import { APIPromise } from "../types/async.js";
|
|
11
12
|
/**
|
|
12
13
|
* Retrieve user notification preferences
|
|
13
14
|
*
|
|
14
15
|
* @remarks
|
|
15
16
|
* The Retrieve Notification Preferences API allows clients to fetch a user's notification preferences based on their unique user identifier (user_id).
|
|
16
17
|
*/
|
|
17
|
-
export
|
|
18
|
+
export function authGetNotificationPreferences(client, request, options) {
|
|
19
|
+
return new APIPromise($do(client, request, options));
|
|
20
|
+
}
|
|
21
|
+
async function $do(client, request, options) {
|
|
18
22
|
const parsed = safeParse(request, (value) => operations.GetNotificationPreferencesRequest$outboundSchema.parse(value), "Input validation failed");
|
|
19
23
|
if (!parsed.ok) {
|
|
20
|
-
return parsed;
|
|
24
|
+
return [parsed, { status: "invalid" }];
|
|
21
25
|
}
|
|
22
26
|
const payload = parsed.value;
|
|
23
27
|
const body = null;
|
|
@@ -35,7 +39,7 @@ export async function authGetNotificationPreferences(client, request, options) {
|
|
|
35
39
|
const securityInput = secConfig == null ? {} : { authorization: secConfig };
|
|
36
40
|
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
37
41
|
const context = {
|
|
38
|
-
baseURL: options?.serverURL ?? "",
|
|
42
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
39
43
|
operationID: "get-notification-preferences",
|
|
40
44
|
oAuth2Scopes: [],
|
|
41
45
|
resolvedSecurity: requestSecurity,
|
|
@@ -55,7 +59,7 @@ export async function authGetNotificationPreferences(client, request, options) {
|
|
|
55
59
|
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
56
60
|
}, options);
|
|
57
61
|
if (!requestRes.ok) {
|
|
58
|
-
return requestRes;
|
|
62
|
+
return [requestRes, { status: "invalid" }];
|
|
59
63
|
}
|
|
60
64
|
const req = requestRes.value;
|
|
61
65
|
const doResult = await client._do(req, {
|
|
@@ -65,13 +69,13 @@ export async function authGetNotificationPreferences(client, request, options) {
|
|
|
65
69
|
retryCodes: context.retryCodes,
|
|
66
70
|
});
|
|
67
71
|
if (!doResult.ok) {
|
|
68
|
-
return doResult;
|
|
72
|
+
return [doResult, { status: "request-error", request: req }];
|
|
69
73
|
}
|
|
70
74
|
const response = doResult.value;
|
|
71
75
|
const [result] = await M.match(M.json(200, operations.GetNotificationPreferencesResponseBody$inboundSchema), M.fail("4XX"), M.fail("5XX"))(response);
|
|
72
76
|
if (!result.ok) {
|
|
73
|
-
return result;
|
|
77
|
+
return [result, { status: "complete", request: req, response }];
|
|
74
78
|
}
|
|
75
|
-
return result;
|
|
79
|
+
return [result, { status: "complete", request: req, response }];
|
|
76
80
|
}
|
|
77
81
|
//# sourceMappingURL=authGetNotificationPreferences.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"authGetNotificationPreferences.js","sourceRoot":"","sources":["../../src/funcs/authGetNotificationPreferences.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,KAAK,CAAC,MAAM,oBAAoB,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAE9C,OAAO,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAC5E,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAU3C,OAAO,KAAK,UAAU,MAAM,+BAA+B,CAAC;
|
|
1
|
+
{"version":3,"file":"authGetNotificationPreferences.js","sourceRoot":"","sources":["../../src/funcs/authGetNotificationPreferences.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EAA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B,OAAO,CAAC,UAAU,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;IAC7C,CAAC;IACD,MAAM,GAAG,GAAG,UAAU,CAAC,KAAK,CAAC;IAE7B,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,GAAG,CAAC,GAAG,EAAE;QACrC,OAAO;QACP,UAAU,EAAE,CAAC,KAAK,EAAE,KAAK,CAAC;QAC1B,WAAW,EAAE,OAAO,CAAC,WAAW;QAChC,UAAU,EAAE,OAAO,CAAC,UAAU;KAC/B,CAAC,CAAC;IACH,IAAI,CAAC,QAAQ,CAAC,EAAE,EAAE,CAAC;QACjB,OAAO,CAAC,QAAQ,EAAE,EAAE,MAAM,EAAE,eAAe,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,CAAC;IAC/D,CAAC;IACD,MAAM,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC;IAEhC,MAAM,CAAC,MAAM,CAAC,GAAG,MAAM,CAAC,CAAC,KAAK,CAU5B,CAAC,CAAC,IAAI,CACJ,GAAG,EACH,UAAU,CAAC,oDAAoD,CAChE,EACD,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,EACb,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CACd,CAAC,QAAQ,CAAC,CAAC;IACZ,IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC;QACf,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;IAClE,CAAC;IAED,OAAO,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ,EAAE,CAAC,CAAC;AAClE,CAAC"}
|
|
@@ -4,6 +4,7 @@ import { CeError } from "../models/errors/ceerror.js";
|
|
|
4
4
|
import { ConnectionError, InvalidRequestError, RequestAbortedError, RequestTimeoutError, UnexpectedClientError } from "../models/errors/httpclienterrors.js";
|
|
5
5
|
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
6
6
|
import * as operations from "../models/operations/index.js";
|
|
7
|
+
import { APIPromise } from "../types/async.js";
|
|
7
8
|
import { Result } from "../types/fp.js";
|
|
8
9
|
/**
|
|
9
10
|
* Retrieve a user
|
|
@@ -11,5 +12,5 @@ import { Result } from "../types/fp.js";
|
|
|
11
12
|
* @remarks
|
|
12
13
|
* The Retrieve User API is designed to facilitate the retrieval of comprehensive user information from the system. A required parameter is a user-id of the user whose information needs to be retrieved.
|
|
13
14
|
*/
|
|
14
|
-
export declare function authGetUserDetail(client: CeStorefrontCore, request: operations.GetUserDetailRequest, options?: RequestOptions):
|
|
15
|
+
export declare function authGetUserDetail(client: CeStorefrontCore, request: operations.GetUserDetailRequest, options?: RequestOptions): APIPromise<Result<operations.GetUserDetailResponseBody, CeError | SDKValidationError | UnexpectedClientError | InvalidRequestError | RequestAbortedError | RequestTimeoutError | ConnectionError>>;
|
|
15
16
|
//# sourceMappingURL=authGetUserDetail.d.ts.map
|