@ikas/storefront-api 4.0.0-alpha.10
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/package.json +42 -0
- package/src/__api/models/AbandonedCartFlow.ts +34 -0
- package/src/__api/models/AbandonedCartFlowCustomerFilter.ts +25 -0
- package/src/__api/models/AddItemToCartInput.ts +29 -0
- package/src/__api/models/AdditionalPrice.ts +24 -0
- package/src/__api/models/ApplicableProductFilterValue.ts +23 -0
- package/src/__api/models/AppliedProduct.ts +15 -0
- package/src/__api/models/AppliedProductInput.ts +15 -0
- package/src/__api/models/AvailableShippingMethod.ts +24 -0
- package/src/__api/models/Blog.ts +55 -0
- package/src/__api/models/BlogCategory.ts +23 -0
- package/src/__api/models/BlogCategoryPaginationResponse.ts +24 -0
- package/src/__api/models/BlogContent.ts +20 -0
- package/src/__api/models/BlogMetadata.ts +32 -0
- package/src/__api/models/BlogMetadataPaginationResponse.ts +24 -0
- package/src/__api/models/BlogMetadataTargetTypeEnumFilter.ts +22 -0
- package/src/__api/models/BlogPaginationResponse.ts +23 -0
- package/src/__api/models/BlogTag.ts +16 -0
- package/src/__api/models/BlogWriter.ts +15 -0
- package/src/__api/models/BooleanFilterInput.ts +13 -0
- package/src/__api/models/BuyX.ts +20 -0
- package/src/__api/models/BuyXThenGetY.ts +22 -0
- package/src/__api/models/Campaign.ts +75 -0
- package/src/__api/models/CampaignDateRangeField.ts +16 -0
- package/src/__api/models/CampaignFilter.ts +16 -0
- package/src/__api/models/CampaignMinMaxRangeField.ts +16 -0
- package/src/__api/models/CampaignOffer.ts +50 -0
- package/src/__api/models/CampaignOfferProduct.ts +49 -0
- package/src/__api/models/CampaignOfferProductTranslation.ts +19 -0
- package/src/__api/models/CampaignOfferTriggerSettings.ts +19 -0
- package/src/__api/models/Cart.ts +61 -0
- package/src/__api/models/CartCampaignOffer.ts +31 -0
- package/src/__api/models/CartLineItemInput.ts +20 -0
- package/src/__api/models/CartLineOptionInput.ts +17 -0
- package/src/__api/models/CartLineVariantInput.ts +15 -0
- package/src/__api/models/CartStorefrontRouting.ts +28 -0
- package/src/__api/models/CartStorefrontRoutingDynamicCurrencySettings.ts +19 -0
- package/src/__api/models/CartV2.ts +159 -0
- package/src/__api/models/CartV2CampaignOffer.ts +36 -0
- package/src/__api/models/Category.ts +58 -0
- package/src/__api/models/CategoryCondition.ts +17 -0
- package/src/__api/models/CategoryFilterInput.ts +15 -0
- package/src/__api/models/CategoryPaginationResponse.ts +24 -0
- package/src/__api/models/CategoryPathFilterInput.ts +14 -0
- package/src/__api/models/CategoryPathItem.ts +33 -0
- package/src/__api/models/CategoryTranslation.ts +17 -0
- package/src/__api/models/CheckStocksLineInput.ts +17 -0
- package/src/__api/models/CheckStocksLineResponse.ts +18 -0
- package/src/__api/models/CheckStocksResponse.ts +16 -0
- package/src/__api/models/Checkout.ts +102 -0
- package/src/__api/models/CheckoutCustomer.ts +39 -0
- package/src/__api/models/CheckoutCustomerInput.ts +25 -0
- package/src/__api/models/CheckoutOption.ts +15 -0
- package/src/__api/models/CheckoutSettings.ts +62 -0
- package/src/__api/models/CheckoutSettingsPrice.ts +15 -0
- package/src/__api/models/City.ts +29 -0
- package/src/__api/models/Country.ts +41 -0
- package/src/__api/models/CreateCustomerEmailSubscriptionInput.ts +22 -0
- package/src/__api/models/CreateCustomerReviewInput.ts +38 -0
- package/src/__api/models/CreateSaleTransactionMasterPassPaymentMethodDetail.ts +19 -0
- package/src/__api/models/CreateSaleTransactionWithCartInput.ts +29 -0
- package/src/__api/models/CreateSaleTransactionWithCheckoutInput.ts +29 -0
- package/src/__api/models/CreateStripePaymentIntentResponse.ts +21 -0
- package/src/__api/models/CurrencyRate.ts +23 -0
- package/src/__api/models/CurrencyRateData.ts +15 -0
- package/src/__api/models/Customer.ts +81 -0
- package/src/__api/models/CustomerAddress.ts +64 -0
- package/src/__api/models/CustomerAddressCity.ts +17 -0
- package/src/__api/models/CustomerAddressCityInput.ts +18 -0
- package/src/__api/models/CustomerAddressCountry.ts +22 -0
- package/src/__api/models/CustomerAddressCountryInput.ts +23 -0
- package/src/__api/models/CustomerAddressDistrict.ts +18 -0
- package/src/__api/models/CustomerAddressDistrictInput.ts +19 -0
- package/src/__api/models/CustomerAddressState.ts +17 -0
- package/src/__api/models/CustomerAddressStateInput.ts +19 -0
- package/src/__api/models/CustomerAttribute.ts +36 -0
- package/src/__api/models/CustomerAttributeOption.ts +17 -0
- package/src/__api/models/CustomerAttributeOptionTranslation.ts +17 -0
- package/src/__api/models/CustomerAttributeSalesChannel.ts +28 -0
- package/src/__api/models/CustomerAttributeTranslation.ts +24 -0
- package/src/__api/models/CustomerAttributeValue.ts +18 -0
- package/src/__api/models/CustomerAttributeValueInput.ts +19 -0
- package/src/__api/models/CustomerCheckResponse.ts +13 -0
- package/src/__api/models/CustomerFavoriteProduct.ts +19 -0
- package/src/__api/models/CustomerLoginResponse.ts +18 -0
- package/src/__api/models/CustomerRefreshTokenResponse.ts +17 -0
- package/src/__api/models/CustomerReview.ts +43 -0
- package/src/__api/models/CustomerReviewSFPaginationResponse.ts +26 -0
- package/src/__api/models/CustomerReviewSummary.ts +25 -0
- package/src/__api/models/CustomerReviewSummaryPaginationResponse.ts +26 -0
- package/src/__api/models/CustomerReviewSummaryStar.ts +17 -0
- package/src/__api/models/DateFilterInput.ts +27 -0
- package/src/__api/models/District.ts +29 -0
- package/src/__api/models/FixedDiscount.ts +28 -0
- package/src/__api/models/GetAvailableStockLocation.ts +25 -0
- package/src/__api/models/GetAvailableStockLocationAddress.ts +36 -0
- package/src/__api/models/GetAvailableStockLocationAddressCity.ts +19 -0
- package/src/__api/models/GetAvailableStockLocationsResponse.ts +18 -0
- package/src/__api/models/GetOrderLineFile.ts +13 -0
- package/src/__api/models/GetProductCampaignsInput.ts +18 -0
- package/src/__api/models/GetProductCampaignsResponse.ts +20 -0
- package/src/__api/models/GetProductOptionFileUrl.ts +18 -0
- package/src/__api/models/GetVariantStockLocation.ts +21 -0
- package/src/__api/models/GetVariantStockLocationListResponse.ts +18 -0
- package/src/__api/models/GetY.ts +26 -0
- package/src/__api/models/HTMLMetaData.ts +44 -0
- package/src/__api/models/HTMLMetaDataOverride.ts +21 -0
- package/src/__api/models/HTMLMetaDataTargetTypeEnumFilter.ts +22 -0
- package/src/__api/models/HTMLMetaDataTranslation.ts +18 -0
- package/src/__api/models/Invoice.ts +26 -0
- package/src/__api/models/ListCustomerReviewInput.ts +14 -0
- package/src/__api/models/LocationTranslations.ts +15 -0
- package/src/__api/models/MasterPassTokenResponse.ts +18 -0
- package/src/__api/models/MerchantAddress.ts +48 -0
- package/src/__api/models/MerchantAddressCity.ts +17 -0
- package/src/__api/models/MerchantAddressCountry.ts +18 -0
- package/src/__api/models/MerchantAddressDistrict.ts +18 -0
- package/src/__api/models/MerchantAddressState.ts +17 -0
- package/src/__api/models/MerchantSettings.ts +32 -0
- package/src/__api/models/MerchantSettingsCurrencyFormat.ts +27 -0
- package/src/__api/models/OrderAddress.ts +53 -0
- package/src/__api/models/OrderAddressCity.ts +17 -0
- package/src/__api/models/OrderAddressCityInput.ts +17 -0
- package/src/__api/models/OrderAddressCountry.ts +21 -0
- package/src/__api/models/OrderAddressCountryInput.ts +22 -0
- package/src/__api/models/OrderAddressDistrict.ts +17 -0
- package/src/__api/models/OrderAddressDistrictInput.ts +19 -0
- package/src/__api/models/OrderAddressInput.ts +53 -0
- package/src/__api/models/OrderAddressState.ts +17 -0
- package/src/__api/models/OrderAddressStateInput.ts +18 -0
- package/src/__api/models/OrderAdjustment.ts +35 -0
- package/src/__api/models/OrderAdjustmentAppliedOrderLine.ts +24 -0
- package/src/__api/models/OrderAdjustmentInput.ts +26 -0
- package/src/__api/models/OrderCurrencyRate.ts +17 -0
- package/src/__api/models/OrderCustomer.ts +34 -0
- package/src/__api/models/OrderGiftPackageLine.ts +18 -0
- package/src/__api/models/OrderLineDiscount.ts +28 -0
- package/src/__api/models/OrderLineItem.ts +59 -0
- package/src/__api/models/OrderLineOption.ts +25 -0
- package/src/__api/models/OrderLineOptionValue.ts +18 -0
- package/src/__api/models/OrderLineVariant.ts +56 -0
- package/src/__api/models/OrderLineVariantBrand.ts +15 -0
- package/src/__api/models/OrderLineVariantCategory.ts +21 -0
- package/src/__api/models/OrderLineVariantCategoryPath.ts +17 -0
- package/src/__api/models/OrderLineVariantPrice.ts +27 -0
- package/src/__api/models/OrderLineVariantVariantValues.ts +23 -0
- package/src/__api/models/OrderPackage.ts +33 -0
- package/src/__api/models/OrderPaymentMethod.ts +22 -0
- package/src/__api/models/OrderRefundOrderLineInput.ts +17 -0
- package/src/__api/models/OrderRefundRequestInput.ts +21 -0
- package/src/__api/models/OrderRefundSettings.ts +28 -0
- package/src/__api/models/OrderShippingLine.ts +34 -0
- package/src/__api/models/OrderStorefrontRouting.ts +29 -0
- package/src/__api/models/OrderStorefrontRoutingDynamicCurrencySettings.ts +19 -0
- package/src/__api/models/OrderTaxLine.ts +15 -0
- package/src/__api/models/PaginationInput.ts +17 -0
- package/src/__api/models/PaymentGateway.ts +61 -0
- package/src/__api/models/PaymentGatewayPaymentMethod.ts +17 -0
- package/src/__api/models/PaymentGatewaySettings.ts +21 -0
- package/src/__api/models/PaymentGatewayTranslation.ts +19 -0
- package/src/__api/models/PaymentMethodDetailInput.ts +26 -0
- package/src/__api/models/Product.ts +69 -0
- package/src/__api/models/ProductAttribute.ts +36 -0
- package/src/__api/models/ProductAttributeOption.ts +17 -0
- package/src/__api/models/ProductAttributeOptionTranslation.ts +17 -0
- package/src/__api/models/ProductAttributeTableCellData.ts +17 -0
- package/src/__api/models/ProductAttributeTableTemplate.ts +22 -0
- package/src/__api/models/ProductAttributeTranslation.ts +24 -0
- package/src/__api/models/ProductAttributeValue.ts +19 -0
- package/src/__api/models/ProductBackInStockRemind.ts +25 -0
- package/src/__api/models/ProductBackInStockRemindInput.ts +19 -0
- package/src/__api/models/ProductBrand.ts +33 -0
- package/src/__api/models/ProductBrandPaginationResponse.ts +24 -0
- package/src/__api/models/ProductBrandTranslation.ts +18 -0
- package/src/__api/models/ProductFacetCount.ts +18 -0
- package/src/__api/models/ProductFacetCountValue.ts +16 -0
- package/src/__api/models/ProductFilterData.ts +21 -0
- package/src/__api/models/ProductFilterDataFilter.ts +49 -0
- package/src/__api/models/ProductFilterSettings.ts +25 -0
- package/src/__api/models/ProductImage.ts +20 -0
- package/src/__api/models/ProductItem.ts +18 -0
- package/src/__api/models/ProductItemInput.ts +18 -0
- package/src/__api/models/ProductLastViewed.ts +21 -0
- package/src/__api/models/ProductLastViewedInput.ts +22 -0
- package/src/__api/models/ProductOption.ts +62 -0
- package/src/__api/models/ProductOptionDateSettings.ts +29 -0
- package/src/__api/models/ProductOptionFileSettings.ts +25 -0
- package/src/__api/models/ProductOptionSelectSettings.ts +31 -0
- package/src/__api/models/ProductOptionSelectValue.ts +33 -0
- package/src/__api/models/ProductOptionSelectValueOtherPrice.ts +17 -0
- package/src/__api/models/ProductOptionSelectValueTranslations.ts +17 -0
- package/src/__api/models/ProductOptionSet.ts +26 -0
- package/src/__api/models/ProductOptionSetTranslations.ts +20 -0
- package/src/__api/models/ProductOptionTextSettings.ts +17 -0
- package/src/__api/models/ProductOptionTranslations.ts +24 -0
- package/src/__api/models/ProductPaginationResponse.ts +24 -0
- package/src/__api/models/ProductPrice.ts +27 -0
- package/src/__api/models/ProductSearchResponse.ts +31 -0
- package/src/__api/models/ProductStockLocation.ts +22 -0
- package/src/__api/models/ProductTagTranslation.ts +17 -0
- package/src/__api/models/ProductTranslation.ts +17 -0
- package/src/__api/models/ProductVariantType.ts +17 -0
- package/src/__api/models/Raffle.ts +49 -0
- package/src/__api/models/RaffleDateRangeField.ts +15 -0
- package/src/__api/models/RaffleMetadata.ts +32 -0
- package/src/__api/models/RaffleMetadataTargetTypeEnumFilter.ts +22 -0
- package/src/__api/models/RafflePaginationResponse.ts +23 -0
- package/src/__api/models/RaffleParticipants.ts +52 -0
- package/src/__api/models/RaffleParticipantsInput.ts +32 -0
- package/src/__api/models/RaffleParticipantsUpdateInput.ts +24 -0
- package/src/__api/models/RaffleVariantInformation.ts +16 -0
- package/src/__api/models/RetrieveInstallmentInfoInput.ts +19 -0
- package/src/__api/models/RetrieveInstallmentInfoResponse.ts +36 -0
- package/src/__api/models/SaveCartInput.ts +50 -0
- package/src/__api/models/SaveCheckoutInput.ts +56 -0
- package/src/__api/models/SaveItemToCartInput.ts +35 -0
- package/src/__api/models/SaveMyCustomerAddressInput.ts +63 -0
- package/src/__api/models/SaveMyCustomerInput.ts +30 -0
- package/src/__api/models/SearchCategory.ts +27 -0
- package/src/__api/models/SearchCategoryPath.ts +22 -0
- package/src/__api/models/SearchDynamicCurrencySettings.ts +17 -0
- package/src/__api/models/SearchHTMLMetaData.ts +36 -0
- package/src/__api/models/SearchHTMLMetaDataOverride.ts +23 -0
- package/src/__api/models/SearchInput.ts +64 -0
- package/src/__api/models/SearchInputFacetListInput.ts +20 -0
- package/src/__api/models/SearchInputFilterListInput.ts +27 -0
- package/src/__api/models/SearchInputOrderByInput.ts +17 -0
- package/src/__api/models/SearchProduct.ts +72 -0
- package/src/__api/models/SearchProductAttribute.ts +28 -0
- package/src/__api/models/SearchProductAttributeOption.ts +17 -0
- package/src/__api/models/SearchProductAttributeTableCellData.ts +17 -0
- package/src/__api/models/SearchProductAttributeTableTemplate.ts +22 -0
- package/src/__api/models/SearchProductAttributeValue.ts +27 -0
- package/src/__api/models/SearchProductBrand.ts +22 -0
- package/src/__api/models/SearchProductImage.ts +21 -0
- package/src/__api/models/SearchProductPrice.ts +27 -0
- package/src/__api/models/SearchProductStockLocation.ts +17 -0
- package/src/__api/models/SearchProductTag.ts +20 -0
- package/src/__api/models/SearchProductVariantType.ts +21 -0
- package/src/__api/models/SearchVariant.ts +58 -0
- package/src/__api/models/SearchVariantType.ts +27 -0
- package/src/__api/models/SearchVariantValue.ts +19 -0
- package/src/__api/models/SearchVariationValueRelation.ts +17 -0
- package/src/__api/models/SocialLoginSettings.ts +18 -0
- package/src/__api/models/State.ts +20 -0
- package/src/__api/models/StockLocation.ts +36 -0
- package/src/__api/models/StockLocationAddress.ts +35 -0
- package/src/__api/models/StockLocationAddressCity.ts +18 -0
- package/src/__api/models/StockLocationAddressCountry.ts +19 -0
- package/src/__api/models/StockLocationAddressDistrict.ts +19 -0
- package/src/__api/models/StockLocationAddressState.ts +19 -0
- package/src/__api/models/Storefront.ts +66 -0
- package/src/__api/models/StorefrontDomain.ts +25 -0
- package/src/__api/models/StorefrontDynamicCurrencySettings.ts +17 -0
- package/src/__api/models/StorefrontLocalization.ts +21 -0
- package/src/__api/models/StorefrontOrder.ts +116 -0
- package/src/__api/models/StorefrontRouting.ts +29 -0
- package/src/__api/models/StorefrontTheme.ts +25 -0
- package/src/__api/models/StorefrontTransaction.ts +53 -0
- package/src/__api/models/StringFilterInput.ts +21 -0
- package/src/__api/models/Town.ts +21 -0
- package/src/__api/models/TrackingInfo.ts +24 -0
- package/src/__api/models/TransactionError.ts +17 -0
- package/src/__api/models/TransactionInstallmentPrice.ts +36 -0
- package/src/__api/models/TransactionPaymentMethodDetail.ts +39 -0
- package/src/__api/models/TransactionResponse.ts +26 -0
- package/src/__api/models/UpdateCartCampaignOfferInput.ts +25 -0
- package/src/__api/models/Variant.ts +58 -0
- package/src/__api/models/VariantStock.ts +15 -0
- package/src/__api/models/VariantType.ts +29 -0
- package/src/__api/models/VariantTypeTranslation.ts +21 -0
- package/src/__api/models/VariantValue.ts +20 -0
- package/src/__api/models/VariantValueRelation.ts +15 -0
- package/src/__api/models/VariantValueTranslation.ts +16 -0
- package/src/__api/models/_base.ts +26 -0
- package/src/__api/mutations/activateCustomer.ts +38 -0
- package/src/__api/mutations/addCouponCodeToCheckout.ts +259 -0
- package/src/__api/mutations/addItemToCart.ts +284 -0
- package/src/__api/mutations/createCustomerEmailSubscription.ts +111 -0
- package/src/__api/mutations/createCustomerReview.ts +66 -0
- package/src/__api/mutations/createOrderRefundRequest.ts +240 -0
- package/src/__api/mutations/createSaleTransactionWithCart.ts +62 -0
- package/src/__api/mutations/createSaleTransactionWithCheckout.ts +62 -0
- package/src/__api/mutations/createStripePaymentIntent.ts +57 -0
- package/src/__api/mutations/customerForgotPassword.ts +41 -0
- package/src/__api/mutations/customerLogin.ts +113 -0
- package/src/__api/mutations/customerRecoverPassword.ts +44 -0
- package/src/__api/mutations/customerRefreshToken.ts +52 -0
- package/src/__api/mutations/deleteRaffleParticipantsList.ts +38 -0
- package/src/__api/mutations/getOrderLineFile.ts +39 -0
- package/src/__api/mutations/registerCustomer.ts +131 -0
- package/src/__api/mutations/retrieveInstallmentInfo.ts +65 -0
- package/src/__api/mutations/saveCart.ts +284 -0
- package/src/__api/mutations/saveCartCouponCode.ts +287 -0
- package/src/__api/mutations/saveCheckout.ts +256 -0
- package/src/__api/mutations/saveFavoriteProduct.ts +41 -0
- package/src/__api/mutations/saveItemToCart.ts +136 -0
- package/src/__api/mutations/saveLastViewedProducts.ts +62 -0
- package/src/__api/mutations/saveMyCustomer.ts +108 -0
- package/src/__api/mutations/saveProductBackInStockRemind.ts +63 -0
- package/src/__api/mutations/saveRaffleParticipant.ts +69 -0
- package/src/__api/mutations/sendContactFormToMerchant.ts +53 -0
- package/src/__api/mutations/updateCartCampaignOffer.ts +284 -0
- package/src/__api/mutations/updateRaffleParticipant.ts +72 -0
- package/src/__api/queries/checkCustomerEmail.ts +54 -0
- package/src/__api/queries/checkStocks.ts +53 -0
- package/src/__api/queries/customerSocialLogin.ts +113 -0
- package/src/__api/queries/getAvailableShippingCountries.ts +41 -0
- package/src/__api/queries/getAvailableStockLocations.ts +75 -0
- package/src/__api/queries/getCart.ts +142 -0
- package/src/__api/queries/getCartById.ts +287 -0
- package/src/__api/queries/getCheckoutByCartId.ts +256 -0
- package/src/__api/queries/getCheckoutById.ts +256 -0
- package/src/__api/queries/getCurrencyRate.ts +56 -0
- package/src/__api/queries/getCustomerOrders.ts +237 -0
- package/src/__api/queries/getLastViewedProducts.ts +62 -0
- package/src/__api/queries/getMasterPassRequestToken.ts +62 -0
- package/src/__api/queries/getMyCountry.ts +26 -0
- package/src/__api/queries/getMyCustomer.ts +95 -0
- package/src/__api/queries/getOrder.ts +237 -0
- package/src/__api/queries/getOrderByEmail.ts +240 -0
- package/src/__api/queries/getProductCampaigns.ts +92 -0
- package/src/__api/queries/getProductFilterData.ts +211 -0
- package/src/__api/queries/getProductOptionFileUrl.ts +59 -0
- package/src/__api/queries/getRaffleParticipants.ts +59 -0
- package/src/__api/queries/getRafflesByCustomerId.ts +74 -0
- package/src/__api/queries/getRelatedProducts.ts +60 -0
- package/src/__api/queries/getStorefront.ts +103 -0
- package/src/__api/queries/getStorefrontSettings.ts +26 -0
- package/src/__api/queries/getVariantStockLocations.ts +74 -0
- package/src/__api/queries/isFavoriteProduct.ts +38 -0
- package/src/__api/queries/listBlog.ts +136 -0
- package/src/__api/queries/listBlogCategory.ts +92 -0
- package/src/__api/queries/listBlogMetadata.ts +90 -0
- package/src/__api/queries/listCampaignOffer.ts +76 -0
- package/src/__api/queries/listCategory.ts +151 -0
- package/src/__api/queries/listCheckoutSettings.ts +75 -0
- package/src/__api/queries/listCity.ts +74 -0
- package/src/__api/queries/listCountry.ts +80 -0
- package/src/__api/queries/listCustomerAttribute.ts +62 -0
- package/src/__api/queries/listCustomerReviewSummary.ts +71 -0
- package/src/__api/queries/listCustomerReviews.ts +90 -0
- package/src/__api/queries/listDistrict.ts +77 -0
- package/src/__api/queries/listFavoriteProducts.ts +44 -0
- package/src/__api/queries/listHTMLMetaData.ts +88 -0
- package/src/__api/queries/listMerchantSettings.ts +90 -0
- package/src/__api/queries/listOrderRefundSettings.ts +73 -0
- package/src/__api/queries/listOrderTransactions.ts +89 -0
- package/src/__api/queries/listPaymentGateway.ts +85 -0
- package/src/__api/queries/listProduct.ts +156 -0
- package/src/__api/queries/listProductAttribute.ts +81 -0
- package/src/__api/queries/listProductBackInStockRemind.ts +79 -0
- package/src/__api/queries/listProductBrand.ts +110 -0
- package/src/__api/queries/listProductOptionSet.ts +105 -0
- package/src/__api/queries/listProductStockLocation.ts +62 -0
- package/src/__api/queries/listRaffle.ts +108 -0
- package/src/__api/queries/listRaffleMetadata.ts +83 -0
- package/src/__api/queries/listState.ts +67 -0
- package/src/__api/queries/listStockLocation.ts +76 -0
- package/src/__api/queries/listTown.ts +67 -0
- package/src/__api/queries/listVariantType.ts +74 -0
- package/src/__api/queries/searchProducts.ts +171 -0
- package/src/__api/types/index.ts +3047 -0
- package/src/api/blog/index.ts +70 -0
- package/src/api/brand/index.ts +27 -0
- package/src/api/cart/index.ts +113 -0
- package/src/api/category/index.ts +25 -0
- package/src/api/checkout/index.ts +121 -0
- package/src/api/customer/index.ts +380 -0
- package/src/api/file-upload/index.ts +38 -0
- package/src/api/html-meta-data/index.ts +25 -0
- package/src/api/location/index.ts +64 -0
- package/src/api/masterpass/index.ts +12 -0
- package/src/api/merchant/index.ts +24 -0
- package/src/api/product/index.ts +354 -0
- package/src/api/raffle/index.ts +80 -0
- package/src/api/storefront/index.ts +30 -0
- package/src/index.ts +68 -0
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchQuery,
|
|
3
|
+
ConfigType,
|
|
4
|
+
APIResponse,
|
|
5
|
+
handleAPIError,
|
|
6
|
+
} from "@ikas/fe-api-client";
|
|
7
|
+
import { CreateCustomerEmailSubscriptionInput, Customer } from "../types";
|
|
8
|
+
|
|
9
|
+
const createCustomerEmailSubscription = async (
|
|
10
|
+
variables: QueryParams,
|
|
11
|
+
fields?: string[],
|
|
12
|
+
config?: ConfigType
|
|
13
|
+
) => {
|
|
14
|
+
try {
|
|
15
|
+
const { data, errors } = await fetchQuery({
|
|
16
|
+
operationName: "createCustomerEmailSubscription",
|
|
17
|
+
config,
|
|
18
|
+
variables,
|
|
19
|
+
allReturnFields,
|
|
20
|
+
fields,
|
|
21
|
+
query: (returnFields: string) => `
|
|
22
|
+
mutation createCustomerEmailSubscription (
|
|
23
|
+
$input: CreateCustomerEmailSubscriptionInput!,
|
|
24
|
+
) {
|
|
25
|
+
createCustomerEmailSubscription (
|
|
26
|
+
input: $input,
|
|
27
|
+
) ${returnFields}
|
|
28
|
+
}
|
|
29
|
+
`,
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
return new APIResponse<Customer>(
|
|
33
|
+
data?.createCustomerEmailSubscription,
|
|
34
|
+
errors
|
|
35
|
+
);
|
|
36
|
+
} catch (err) {
|
|
37
|
+
return handleAPIError(err);
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
export default createCustomerEmailSubscription;
|
|
42
|
+
|
|
43
|
+
export type QueryParams = {
|
|
44
|
+
input: CreateCustomerEmailSubscriptionInput;
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
const allReturnFields =
|
|
48
|
+
"{accountStatus accountStatusUpdatedAt addresses {addressLine1 addressLine2 attributes {customerAttributeId customerAttributeOptionId value } city {code id name } company country {code id iso2 iso3 name } createdAt deleted district {code id name } firstName id identityNumber isDefault lastName phone postalCode state {code id name } taxNumber taxOffice title updatedAt } attributes {customerAttributeId customerAttributeOptionId value } createdAt customerGroupIds customerSequence deleted email emailVerifiedDate firstName fullName id isEmailVerified isPhoneVerified lastName note orderCount passwordUpdateDate phone phoneVerifiedDate registrationSource subscriptionStatus subscriptionStatusUpdatedAt tagIds updatedAt }";
|
|
49
|
+
|
|
50
|
+
export enum ResponseField {
|
|
51
|
+
ACCOUNT_STATUS = "accountStatus",
|
|
52
|
+
ACCOUNT_STATUS_UPDATED_AT = "accountStatusUpdatedAt",
|
|
53
|
+
ADDRESSES__ADDRESS_LINE1 = "addresses.addressLine1",
|
|
54
|
+
ADDRESSES__ADDRESS_LINE2 = "addresses.addressLine2",
|
|
55
|
+
ADDRESSES__ATTRIBUTES__CUSTOMER_ATTRIBUTE_ID = "addresses.attributes.customerAttributeId",
|
|
56
|
+
ADDRESSES__ATTRIBUTES__CUSTOMER_ATTRIBUTE_OPTION_ID = "addresses.attributes.customerAttributeOptionId",
|
|
57
|
+
ADDRESSES__ATTRIBUTES__VALUE = "addresses.attributes.value",
|
|
58
|
+
ADDRESSES__CITY__CODE = "addresses.city.code",
|
|
59
|
+
ADDRESSES__CITY__ID = "addresses.city.id",
|
|
60
|
+
ADDRESSES__CITY__NAME = "addresses.city.name",
|
|
61
|
+
ADDRESSES__COMPANY = "addresses.company",
|
|
62
|
+
ADDRESSES__COUNTRY__CODE = "addresses.country.code",
|
|
63
|
+
ADDRESSES__COUNTRY__ID = "addresses.country.id",
|
|
64
|
+
ADDRESSES__COUNTRY__ISO2 = "addresses.country.iso2",
|
|
65
|
+
ADDRESSES__COUNTRY__ISO3 = "addresses.country.iso3",
|
|
66
|
+
ADDRESSES__COUNTRY__NAME = "addresses.country.name",
|
|
67
|
+
ADDRESSES__CREATED_AT = "addresses.createdAt",
|
|
68
|
+
ADDRESSES__DELETED = "addresses.deleted",
|
|
69
|
+
ADDRESSES__DISTRICT__CODE = "addresses.district.code",
|
|
70
|
+
ADDRESSES__DISTRICT__ID = "addresses.district.id",
|
|
71
|
+
ADDRESSES__DISTRICT__NAME = "addresses.district.name",
|
|
72
|
+
ADDRESSES__FIRST_NAME = "addresses.firstName",
|
|
73
|
+
ADDRESSES__ID = "addresses.id",
|
|
74
|
+
ADDRESSES__IDENTITY_NUMBER = "addresses.identityNumber",
|
|
75
|
+
ADDRESSES__IS_DEFAULT = "addresses.isDefault",
|
|
76
|
+
ADDRESSES__LAST_NAME = "addresses.lastName",
|
|
77
|
+
ADDRESSES__PHONE = "addresses.phone",
|
|
78
|
+
ADDRESSES__POSTAL_CODE = "addresses.postalCode",
|
|
79
|
+
ADDRESSES__STATE__CODE = "addresses.state.code",
|
|
80
|
+
ADDRESSES__STATE__ID = "addresses.state.id",
|
|
81
|
+
ADDRESSES__STATE__NAME = "addresses.state.name",
|
|
82
|
+
ADDRESSES__TAX_NUMBER = "addresses.taxNumber",
|
|
83
|
+
ADDRESSES__TAX_OFFICE = "addresses.taxOffice",
|
|
84
|
+
ADDRESSES__TITLE = "addresses.title",
|
|
85
|
+
ADDRESSES__UPDATED_AT = "addresses.updatedAt",
|
|
86
|
+
ATTRIBUTES__CUSTOMER_ATTRIBUTE_ID = "attributes.customerAttributeId",
|
|
87
|
+
ATTRIBUTES__CUSTOMER_ATTRIBUTE_OPTION_ID = "attributes.customerAttributeOptionId",
|
|
88
|
+
ATTRIBUTES__VALUE = "attributes.value",
|
|
89
|
+
CREATED_AT = "createdAt",
|
|
90
|
+
CUSTOMER_GROUP_IDS = "customerGroupIds",
|
|
91
|
+
CUSTOMER_SEQUENCE = "customerSequence",
|
|
92
|
+
DELETED = "deleted",
|
|
93
|
+
EMAIL = "email",
|
|
94
|
+
EMAIL_VERIFIED_DATE = "emailVerifiedDate",
|
|
95
|
+
FIRST_NAME = "firstName",
|
|
96
|
+
FULL_NAME = "fullName",
|
|
97
|
+
ID = "id",
|
|
98
|
+
IS_EMAIL_VERIFIED = "isEmailVerified",
|
|
99
|
+
IS_PHONE_VERIFIED = "isPhoneVerified",
|
|
100
|
+
LAST_NAME = "lastName",
|
|
101
|
+
NOTE = "note",
|
|
102
|
+
ORDER_COUNT = "orderCount",
|
|
103
|
+
PASSWORD_UPDATE_DATE = "passwordUpdateDate",
|
|
104
|
+
PHONE = "phone",
|
|
105
|
+
PHONE_VERIFIED_DATE = "phoneVerifiedDate",
|
|
106
|
+
REGISTRATION_SOURCE = "registrationSource",
|
|
107
|
+
SUBSCRIPTION_STATUS = "subscriptionStatus",
|
|
108
|
+
SUBSCRIPTION_STATUS_UPDATED_AT = "subscriptionStatusUpdatedAt",
|
|
109
|
+
TAG_IDS = "tagIds",
|
|
110
|
+
UPDATED_AT = "updatedAt",
|
|
111
|
+
}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchQuery,
|
|
3
|
+
ConfigType,
|
|
4
|
+
APIResponse,
|
|
5
|
+
handleAPIError,
|
|
6
|
+
} from "@ikas/fe-api-client";
|
|
7
|
+
import { CreateCustomerReviewInput, CustomerReview } from "../types";
|
|
8
|
+
|
|
9
|
+
const createCustomerReview = async (
|
|
10
|
+
variables: QueryParams,
|
|
11
|
+
fields?: string[],
|
|
12
|
+
config?: ConfigType
|
|
13
|
+
) => {
|
|
14
|
+
try {
|
|
15
|
+
const { data, errors } = await fetchQuery({
|
|
16
|
+
operationName: "createCustomerReview",
|
|
17
|
+
config,
|
|
18
|
+
variables,
|
|
19
|
+
allReturnFields,
|
|
20
|
+
fields,
|
|
21
|
+
query: (returnFields: string) => `
|
|
22
|
+
mutation createCustomerReview (
|
|
23
|
+
$input: CreateCustomerReviewInput!,
|
|
24
|
+
) {
|
|
25
|
+
createCustomerReview (
|
|
26
|
+
input: $input,
|
|
27
|
+
) ${returnFields}
|
|
28
|
+
}
|
|
29
|
+
`,
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
return new APIResponse<CustomerReview>(data?.createCustomerReview, errors);
|
|
33
|
+
} catch (err) {
|
|
34
|
+
return handleAPIError(err);
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export default createCustomerReview;
|
|
39
|
+
|
|
40
|
+
export type QueryParams = {
|
|
41
|
+
input: CreateCustomerReviewInput;
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
const allReturnFields =
|
|
45
|
+
"{comment createdAt customerId deleted email firstName id imageIds lastName orderId orderNumber productId salesChannelId star status storefrontId title updatedAt }";
|
|
46
|
+
|
|
47
|
+
export enum ResponseField {
|
|
48
|
+
COMMENT = "comment",
|
|
49
|
+
CREATED_AT = "createdAt",
|
|
50
|
+
CUSTOMER_ID = "customerId",
|
|
51
|
+
DELETED = "deleted",
|
|
52
|
+
EMAIL = "email",
|
|
53
|
+
FIRST_NAME = "firstName",
|
|
54
|
+
ID = "id",
|
|
55
|
+
IMAGE_IDS = "imageIds",
|
|
56
|
+
LAST_NAME = "lastName",
|
|
57
|
+
ORDER_ID = "orderId",
|
|
58
|
+
ORDER_NUMBER = "orderNumber",
|
|
59
|
+
PRODUCT_ID = "productId",
|
|
60
|
+
SALES_CHANNEL_ID = "salesChannelId",
|
|
61
|
+
STAR = "star",
|
|
62
|
+
STATUS = "status",
|
|
63
|
+
STOREFRONT_ID = "storefrontId",
|
|
64
|
+
TITLE = "title",
|
|
65
|
+
UPDATED_AT = "updatedAt",
|
|
66
|
+
}
|
|
@@ -0,0 +1,240 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchQuery,
|
|
3
|
+
ConfigType,
|
|
4
|
+
APIResponse,
|
|
5
|
+
handleAPIError,
|
|
6
|
+
} from "@ikas/fe-api-client";
|
|
7
|
+
import { OrderRefundRequestInput, StorefrontOrder } from "../types";
|
|
8
|
+
|
|
9
|
+
const createOrderRefundRequest = async (
|
|
10
|
+
variables: QueryParams,
|
|
11
|
+
fields?: string[],
|
|
12
|
+
config?: ConfigType
|
|
13
|
+
) => {
|
|
14
|
+
try {
|
|
15
|
+
const { data, errors } = await fetchQuery({
|
|
16
|
+
operationName: "createOrderRefundRequest",
|
|
17
|
+
config,
|
|
18
|
+
variables,
|
|
19
|
+
allReturnFields,
|
|
20
|
+
fields,
|
|
21
|
+
query: (returnFields: string) => `
|
|
22
|
+
mutation createOrderRefundRequest (
|
|
23
|
+
$input: OrderRefundRequestInput!,
|
|
24
|
+
) {
|
|
25
|
+
createOrderRefundRequest (
|
|
26
|
+
input: $input,
|
|
27
|
+
) ${returnFields}
|
|
28
|
+
}
|
|
29
|
+
`,
|
|
30
|
+
});
|
|
31
|
+
|
|
32
|
+
return new APIResponse<StorefrontOrder>(
|
|
33
|
+
data?.createOrderRefundRequest,
|
|
34
|
+
errors
|
|
35
|
+
);
|
|
36
|
+
} catch (err) {
|
|
37
|
+
return handleAPIError(err);
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
export default createOrderRefundRequest;
|
|
42
|
+
|
|
43
|
+
export type QueryParams = {
|
|
44
|
+
input: OrderRefundRequestInput;
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
const allReturnFields =
|
|
48
|
+
"{billingAddress {addressLine1 addressLine2 city {code id name } company country {code id iso2 iso3 name } district {code id name } firstName id identityNumber isDefault lastName phone postalCode state {code id name } taxNumber taxOffice } cancelReason cancelledAt createdAt currencyCode currencyRates {code originalRate rate } customer {email firstName fullName id isGuestCheckout lastName notificationsAccepted phone } customerId deleted giftPackageLines {price taxValue } giftPackageNote id invoices {appId appName createdAt id invoiceNumber storeAppId type } isGiftPackage merchantId note orderAdjustments {amount amountType appliedOrderLines {amount appliedQuantity isAutoCreated orderLineId } campaignId campaignType couponId name order type } orderLineItems {createdAt currencyCode deleted discount {amount amountType campaignOfferId campaignOfferProductId maxApplicableQuantity reason } discountPrice finalPrice id options {name productOptionId productOptionsSetId type values {name price value } } originalOrderLineItemId price quantity status statusUpdatedAt stockLocationId taxValue updatedAt variant {barcodeList brand {id name } categories {categoryPath {id name } id name } id mainImageId name prices {buyPrice currency discountPrice priceListId sellPrice } productId sku slug tagIds taxValue type variantValues {order variantTypeId variantTypeName variantValueId variantValueName } weight } } orderNumber orderPackageStatus orderPackages {createdAt deleted errorMessage id note orderLineItemIds orderPackageFulfillStatus orderPackageNumber stockLocationId trackingInfo {barcode cargoCompany isSendNotification trackingLink trackingNumber } updatedAt } orderPaymentStatus orderTagIds orderedAt paymentMethods {paymentGatewayCode paymentGatewayId paymentGatewayName price type } shippingAddress {addressLine1 addressLine2 city {code id name } company country {code id iso2 iso3 name } district {code id name } firstName id identityNumber isDefault lastName phone postalCode state {code id name } taxNumber taxOffice } shippingLines {finalPrice isRefunded paymentMethod price shippingSettingsId shippingZoneRateId taxValue title } shippingMethod status taxLines {price rate } totalFinalPrice totalPrice updatedAt }";
|
|
49
|
+
|
|
50
|
+
export enum ResponseField {
|
|
51
|
+
BILLING_ADDRESS__ADDRESS_LINE1 = "billingAddress.addressLine1",
|
|
52
|
+
BILLING_ADDRESS__ADDRESS_LINE2 = "billingAddress.addressLine2",
|
|
53
|
+
BILLING_ADDRESS__CITY__CODE = "billingAddress.city.code",
|
|
54
|
+
BILLING_ADDRESS__CITY__ID = "billingAddress.city.id",
|
|
55
|
+
BILLING_ADDRESS__CITY__NAME = "billingAddress.city.name",
|
|
56
|
+
BILLING_ADDRESS__COMPANY = "billingAddress.company",
|
|
57
|
+
BILLING_ADDRESS__COUNTRY__CODE = "billingAddress.country.code",
|
|
58
|
+
BILLING_ADDRESS__COUNTRY__ID = "billingAddress.country.id",
|
|
59
|
+
BILLING_ADDRESS__COUNTRY__ISO2 = "billingAddress.country.iso2",
|
|
60
|
+
BILLING_ADDRESS__COUNTRY__ISO3 = "billingAddress.country.iso3",
|
|
61
|
+
BILLING_ADDRESS__COUNTRY__NAME = "billingAddress.country.name",
|
|
62
|
+
BILLING_ADDRESS__DISTRICT__CODE = "billingAddress.district.code",
|
|
63
|
+
BILLING_ADDRESS__DISTRICT__ID = "billingAddress.district.id",
|
|
64
|
+
BILLING_ADDRESS__DISTRICT__NAME = "billingAddress.district.name",
|
|
65
|
+
BILLING_ADDRESS__FIRST_NAME = "billingAddress.firstName",
|
|
66
|
+
BILLING_ADDRESS__ID = "billingAddress.id",
|
|
67
|
+
BILLING_ADDRESS__IDENTITY_NUMBER = "billingAddress.identityNumber",
|
|
68
|
+
BILLING_ADDRESS__IS_DEFAULT = "billingAddress.isDefault",
|
|
69
|
+
BILLING_ADDRESS__LAST_NAME = "billingAddress.lastName",
|
|
70
|
+
BILLING_ADDRESS__PHONE = "billingAddress.phone",
|
|
71
|
+
BILLING_ADDRESS__POSTAL_CODE = "billingAddress.postalCode",
|
|
72
|
+
BILLING_ADDRESS__STATE__CODE = "billingAddress.state.code",
|
|
73
|
+
BILLING_ADDRESS__STATE__ID = "billingAddress.state.id",
|
|
74
|
+
BILLING_ADDRESS__STATE__NAME = "billingAddress.state.name",
|
|
75
|
+
BILLING_ADDRESS__TAX_NUMBER = "billingAddress.taxNumber",
|
|
76
|
+
BILLING_ADDRESS__TAX_OFFICE = "billingAddress.taxOffice",
|
|
77
|
+
CANCEL_REASON = "cancelReason",
|
|
78
|
+
CANCELLED_AT = "cancelledAt",
|
|
79
|
+
CREATED_AT = "createdAt",
|
|
80
|
+
CURRENCY_CODE = "currencyCode",
|
|
81
|
+
CURRENCY_RATES__CODE = "currencyRates.code",
|
|
82
|
+
CURRENCY_RATES__ORIGINAL_RATE = "currencyRates.originalRate",
|
|
83
|
+
CURRENCY_RATES__RATE = "currencyRates.rate",
|
|
84
|
+
CUSTOMER__EMAIL = "customer.email",
|
|
85
|
+
CUSTOMER__FIRST_NAME = "customer.firstName",
|
|
86
|
+
CUSTOMER__FULL_NAME = "customer.fullName",
|
|
87
|
+
CUSTOMER__ID = "customer.id",
|
|
88
|
+
CUSTOMER__IS_GUEST_CHECKOUT = "customer.isGuestCheckout",
|
|
89
|
+
CUSTOMER__LAST_NAME = "customer.lastName",
|
|
90
|
+
CUSTOMER__NOTIFICATIONS_ACCEPTED = "customer.notificationsAccepted",
|
|
91
|
+
CUSTOMER__PHONE = "customer.phone",
|
|
92
|
+
CUSTOMER_ID = "customerId",
|
|
93
|
+
DELETED = "deleted",
|
|
94
|
+
GIFT_PACKAGE_LINES__PRICE = "giftPackageLines.price",
|
|
95
|
+
GIFT_PACKAGE_LINES__TAX_VALUE = "giftPackageLines.taxValue",
|
|
96
|
+
GIFT_PACKAGE_NOTE = "giftPackageNote",
|
|
97
|
+
ID = "id",
|
|
98
|
+
INVOICES__APP_ID = "invoices.appId",
|
|
99
|
+
INVOICES__APP_NAME = "invoices.appName",
|
|
100
|
+
INVOICES__CREATED_AT = "invoices.createdAt",
|
|
101
|
+
INVOICES__ID = "invoices.id",
|
|
102
|
+
INVOICES__INVOICE_NUMBER = "invoices.invoiceNumber",
|
|
103
|
+
INVOICES__STORE_APP_ID = "invoices.storeAppId",
|
|
104
|
+
INVOICES__TYPE = "invoices.type",
|
|
105
|
+
IS_GIFT_PACKAGE = "isGiftPackage",
|
|
106
|
+
MERCHANT_ID = "merchantId",
|
|
107
|
+
NOTE = "note",
|
|
108
|
+
ORDER_ADJUSTMENTS__AMOUNT = "orderAdjustments.amount",
|
|
109
|
+
ORDER_ADJUSTMENTS__AMOUNT_TYPE = "orderAdjustments.amountType",
|
|
110
|
+
ORDER_ADJUSTMENTS__APPLIED_ORDER_LINES__AMOUNT = "orderAdjustments.appliedOrderLines.amount",
|
|
111
|
+
ORDER_ADJUSTMENTS__APPLIED_ORDER_LINES__APPLIED_QUANTITY = "orderAdjustments.appliedOrderLines.appliedQuantity",
|
|
112
|
+
ORDER_ADJUSTMENTS__APPLIED_ORDER_LINES__IS_AUTO_CREATED = "orderAdjustments.appliedOrderLines.isAutoCreated",
|
|
113
|
+
ORDER_ADJUSTMENTS__APPLIED_ORDER_LINES__ORDER_LINE_ID = "orderAdjustments.appliedOrderLines.orderLineId",
|
|
114
|
+
ORDER_ADJUSTMENTS__CAMPAIGN_ID = "orderAdjustments.campaignId",
|
|
115
|
+
ORDER_ADJUSTMENTS__CAMPAIGN_TYPE = "orderAdjustments.campaignType",
|
|
116
|
+
ORDER_ADJUSTMENTS__COUPON_ID = "orderAdjustments.couponId",
|
|
117
|
+
ORDER_ADJUSTMENTS__NAME = "orderAdjustments.name",
|
|
118
|
+
ORDER_ADJUSTMENTS__ORDER = "orderAdjustments.order",
|
|
119
|
+
ORDER_ADJUSTMENTS__TYPE = "orderAdjustments.type",
|
|
120
|
+
ORDER_LINE_ITEMS__CREATED_AT = "orderLineItems.createdAt",
|
|
121
|
+
ORDER_LINE_ITEMS__CURRENCY_CODE = "orderLineItems.currencyCode",
|
|
122
|
+
ORDER_LINE_ITEMS__DELETED = "orderLineItems.deleted",
|
|
123
|
+
ORDER_LINE_ITEMS__DISCOUNT__AMOUNT = "orderLineItems.discount.amount",
|
|
124
|
+
ORDER_LINE_ITEMS__DISCOUNT__AMOUNT_TYPE = "orderLineItems.discount.amountType",
|
|
125
|
+
ORDER_LINE_ITEMS__DISCOUNT__CAMPAIGN_OFFER_ID = "orderLineItems.discount.campaignOfferId",
|
|
126
|
+
ORDER_LINE_ITEMS__DISCOUNT__CAMPAIGN_OFFER_PRODUCT_ID = "orderLineItems.discount.campaignOfferProductId",
|
|
127
|
+
ORDER_LINE_ITEMS__DISCOUNT__MAX_APPLICABLE_QUANTITY = "orderLineItems.discount.maxApplicableQuantity",
|
|
128
|
+
ORDER_LINE_ITEMS__DISCOUNT__REASON = "orderLineItems.discount.reason",
|
|
129
|
+
ORDER_LINE_ITEMS__DISCOUNT_PRICE = "orderLineItems.discountPrice",
|
|
130
|
+
ORDER_LINE_ITEMS__FINAL_PRICE = "orderLineItems.finalPrice",
|
|
131
|
+
ORDER_LINE_ITEMS__ID = "orderLineItems.id",
|
|
132
|
+
ORDER_LINE_ITEMS__OPTIONS__NAME = "orderLineItems.options.name",
|
|
133
|
+
ORDER_LINE_ITEMS__OPTIONS__PRODUCT_OPTION_ID = "orderLineItems.options.productOptionId",
|
|
134
|
+
ORDER_LINE_ITEMS__OPTIONS__PRODUCT_OPTIONS_SET_ID = "orderLineItems.options.productOptionsSetId",
|
|
135
|
+
ORDER_LINE_ITEMS__OPTIONS__TYPE = "orderLineItems.options.type",
|
|
136
|
+
ORDER_LINE_ITEMS__OPTIONS__VALUES__NAME = "orderLineItems.options.values.name",
|
|
137
|
+
ORDER_LINE_ITEMS__OPTIONS__VALUES__PRICE = "orderLineItems.options.values.price",
|
|
138
|
+
ORDER_LINE_ITEMS__OPTIONS__VALUES__VALUE = "orderLineItems.options.values.value",
|
|
139
|
+
ORDER_LINE_ITEMS__ORIGINAL_ORDER_LINE_ITEM_ID = "orderLineItems.originalOrderLineItemId",
|
|
140
|
+
ORDER_LINE_ITEMS__PRICE = "orderLineItems.price",
|
|
141
|
+
ORDER_LINE_ITEMS__QUANTITY = "orderLineItems.quantity",
|
|
142
|
+
ORDER_LINE_ITEMS__STATUS = "orderLineItems.status",
|
|
143
|
+
ORDER_LINE_ITEMS__STATUS_UPDATED_AT = "orderLineItems.statusUpdatedAt",
|
|
144
|
+
ORDER_LINE_ITEMS__STOCK_LOCATION_ID = "orderLineItems.stockLocationId",
|
|
145
|
+
ORDER_LINE_ITEMS__TAX_VALUE = "orderLineItems.taxValue",
|
|
146
|
+
ORDER_LINE_ITEMS__UPDATED_AT = "orderLineItems.updatedAt",
|
|
147
|
+
ORDER_LINE_ITEMS__VARIANT__BARCODE_LIST = "orderLineItems.variant.barcodeList",
|
|
148
|
+
ORDER_LINE_ITEMS__VARIANT__BRAND__ID = "orderLineItems.variant.brand.id",
|
|
149
|
+
ORDER_LINE_ITEMS__VARIANT__BRAND__NAME = "orderLineItems.variant.brand.name",
|
|
150
|
+
ORDER_LINE_ITEMS__VARIANT__CATEGORIES__CATEGORY_PATH__ID = "orderLineItems.variant.categories.categoryPath.id",
|
|
151
|
+
ORDER_LINE_ITEMS__VARIANT__CATEGORIES__CATEGORY_PATH__NAME = "orderLineItems.variant.categories.categoryPath.name",
|
|
152
|
+
ORDER_LINE_ITEMS__VARIANT__CATEGORIES__ID = "orderLineItems.variant.categories.id",
|
|
153
|
+
ORDER_LINE_ITEMS__VARIANT__CATEGORIES__NAME = "orderLineItems.variant.categories.name",
|
|
154
|
+
ORDER_LINE_ITEMS__VARIANT__ID = "orderLineItems.variant.id",
|
|
155
|
+
ORDER_LINE_ITEMS__VARIANT__MAIN_IMAGE_ID = "orderLineItems.variant.mainImageId",
|
|
156
|
+
ORDER_LINE_ITEMS__VARIANT__NAME = "orderLineItems.variant.name",
|
|
157
|
+
ORDER_LINE_ITEMS__VARIANT__PRICES__BUY_PRICE = "orderLineItems.variant.prices.buyPrice",
|
|
158
|
+
ORDER_LINE_ITEMS__VARIANT__PRICES__CURRENCY = "orderLineItems.variant.prices.currency",
|
|
159
|
+
ORDER_LINE_ITEMS__VARIANT__PRICES__DISCOUNT_PRICE = "orderLineItems.variant.prices.discountPrice",
|
|
160
|
+
ORDER_LINE_ITEMS__VARIANT__PRICES__PRICE_LIST_ID = "orderLineItems.variant.prices.priceListId",
|
|
161
|
+
ORDER_LINE_ITEMS__VARIANT__PRICES__SELL_PRICE = "orderLineItems.variant.prices.sellPrice",
|
|
162
|
+
ORDER_LINE_ITEMS__VARIANT__PRODUCT_ID = "orderLineItems.variant.productId",
|
|
163
|
+
ORDER_LINE_ITEMS__VARIANT__SKU = "orderLineItems.variant.sku",
|
|
164
|
+
ORDER_LINE_ITEMS__VARIANT__SLUG = "orderLineItems.variant.slug",
|
|
165
|
+
ORDER_LINE_ITEMS__VARIANT__TAG_IDS = "orderLineItems.variant.tagIds",
|
|
166
|
+
ORDER_LINE_ITEMS__VARIANT__TAX_VALUE = "orderLineItems.variant.taxValue",
|
|
167
|
+
ORDER_LINE_ITEMS__VARIANT__TYPE = "orderLineItems.variant.type",
|
|
168
|
+
ORDER_LINE_ITEMS__VARIANT__VARIANT_VALUES__ORDER = "orderLineItems.variant.variantValues.order",
|
|
169
|
+
ORDER_LINE_ITEMS__VARIANT__VARIANT_VALUES__VARIANT_TYPE_ID = "orderLineItems.variant.variantValues.variantTypeId",
|
|
170
|
+
ORDER_LINE_ITEMS__VARIANT__VARIANT_VALUES__VARIANT_TYPE_NAME = "orderLineItems.variant.variantValues.variantTypeName",
|
|
171
|
+
ORDER_LINE_ITEMS__VARIANT__VARIANT_VALUES__VARIANT_VALUE_ID = "orderLineItems.variant.variantValues.variantValueId",
|
|
172
|
+
ORDER_LINE_ITEMS__VARIANT__VARIANT_VALUES__VARIANT_VALUE_NAME = "orderLineItems.variant.variantValues.variantValueName",
|
|
173
|
+
ORDER_LINE_ITEMS__VARIANT__WEIGHT = "orderLineItems.variant.weight",
|
|
174
|
+
ORDER_NUMBER = "orderNumber",
|
|
175
|
+
ORDER_PACKAGE_STATUS = "orderPackageStatus",
|
|
176
|
+
ORDER_PACKAGES__CREATED_AT = "orderPackages.createdAt",
|
|
177
|
+
ORDER_PACKAGES__DELETED = "orderPackages.deleted",
|
|
178
|
+
ORDER_PACKAGES__ERROR_MESSAGE = "orderPackages.errorMessage",
|
|
179
|
+
ORDER_PACKAGES__ID = "orderPackages.id",
|
|
180
|
+
ORDER_PACKAGES__NOTE = "orderPackages.note",
|
|
181
|
+
ORDER_PACKAGES__ORDER_LINE_ITEM_IDS = "orderPackages.orderLineItemIds",
|
|
182
|
+
ORDER_PACKAGES__ORDER_PACKAGE_FULFILL_STATUS = "orderPackages.orderPackageFulfillStatus",
|
|
183
|
+
ORDER_PACKAGES__ORDER_PACKAGE_NUMBER = "orderPackages.orderPackageNumber",
|
|
184
|
+
ORDER_PACKAGES__STOCK_LOCATION_ID = "orderPackages.stockLocationId",
|
|
185
|
+
ORDER_PACKAGES__TRACKING_INFO__BARCODE = "orderPackages.trackingInfo.barcode",
|
|
186
|
+
ORDER_PACKAGES__TRACKING_INFO__CARGO_COMPANY = "orderPackages.trackingInfo.cargoCompany",
|
|
187
|
+
ORDER_PACKAGES__TRACKING_INFO__IS_SEND_NOTIFICATION = "orderPackages.trackingInfo.isSendNotification",
|
|
188
|
+
ORDER_PACKAGES__TRACKING_INFO__TRACKING_LINK = "orderPackages.trackingInfo.trackingLink",
|
|
189
|
+
ORDER_PACKAGES__TRACKING_INFO__TRACKING_NUMBER = "orderPackages.trackingInfo.trackingNumber",
|
|
190
|
+
ORDER_PACKAGES__UPDATED_AT = "orderPackages.updatedAt",
|
|
191
|
+
ORDER_PAYMENT_STATUS = "orderPaymentStatus",
|
|
192
|
+
ORDER_TAG_IDS = "orderTagIds",
|
|
193
|
+
ORDERED_AT = "orderedAt",
|
|
194
|
+
PAYMENT_METHODS__PAYMENT_GATEWAY_CODE = "paymentMethods.paymentGatewayCode",
|
|
195
|
+
PAYMENT_METHODS__PAYMENT_GATEWAY_ID = "paymentMethods.paymentGatewayId",
|
|
196
|
+
PAYMENT_METHODS__PAYMENT_GATEWAY_NAME = "paymentMethods.paymentGatewayName",
|
|
197
|
+
PAYMENT_METHODS__PRICE = "paymentMethods.price",
|
|
198
|
+
PAYMENT_METHODS__TYPE = "paymentMethods.type",
|
|
199
|
+
SHIPPING_ADDRESS__ADDRESS_LINE1 = "shippingAddress.addressLine1",
|
|
200
|
+
SHIPPING_ADDRESS__ADDRESS_LINE2 = "shippingAddress.addressLine2",
|
|
201
|
+
SHIPPING_ADDRESS__CITY__CODE = "shippingAddress.city.code",
|
|
202
|
+
SHIPPING_ADDRESS__CITY__ID = "shippingAddress.city.id",
|
|
203
|
+
SHIPPING_ADDRESS__CITY__NAME = "shippingAddress.city.name",
|
|
204
|
+
SHIPPING_ADDRESS__COMPANY = "shippingAddress.company",
|
|
205
|
+
SHIPPING_ADDRESS__COUNTRY__CODE = "shippingAddress.country.code",
|
|
206
|
+
SHIPPING_ADDRESS__COUNTRY__ID = "shippingAddress.country.id",
|
|
207
|
+
SHIPPING_ADDRESS__COUNTRY__ISO2 = "shippingAddress.country.iso2",
|
|
208
|
+
SHIPPING_ADDRESS__COUNTRY__ISO3 = "shippingAddress.country.iso3",
|
|
209
|
+
SHIPPING_ADDRESS__COUNTRY__NAME = "shippingAddress.country.name",
|
|
210
|
+
SHIPPING_ADDRESS__DISTRICT__CODE = "shippingAddress.district.code",
|
|
211
|
+
SHIPPING_ADDRESS__DISTRICT__ID = "shippingAddress.district.id",
|
|
212
|
+
SHIPPING_ADDRESS__DISTRICT__NAME = "shippingAddress.district.name",
|
|
213
|
+
SHIPPING_ADDRESS__FIRST_NAME = "shippingAddress.firstName",
|
|
214
|
+
SHIPPING_ADDRESS__ID = "shippingAddress.id",
|
|
215
|
+
SHIPPING_ADDRESS__IDENTITY_NUMBER = "shippingAddress.identityNumber",
|
|
216
|
+
SHIPPING_ADDRESS__IS_DEFAULT = "shippingAddress.isDefault",
|
|
217
|
+
SHIPPING_ADDRESS__LAST_NAME = "shippingAddress.lastName",
|
|
218
|
+
SHIPPING_ADDRESS__PHONE = "shippingAddress.phone",
|
|
219
|
+
SHIPPING_ADDRESS__POSTAL_CODE = "shippingAddress.postalCode",
|
|
220
|
+
SHIPPING_ADDRESS__STATE__CODE = "shippingAddress.state.code",
|
|
221
|
+
SHIPPING_ADDRESS__STATE__ID = "shippingAddress.state.id",
|
|
222
|
+
SHIPPING_ADDRESS__STATE__NAME = "shippingAddress.state.name",
|
|
223
|
+
SHIPPING_ADDRESS__TAX_NUMBER = "shippingAddress.taxNumber",
|
|
224
|
+
SHIPPING_ADDRESS__TAX_OFFICE = "shippingAddress.taxOffice",
|
|
225
|
+
SHIPPING_LINES__FINAL_PRICE = "shippingLines.finalPrice",
|
|
226
|
+
SHIPPING_LINES__IS_REFUNDED = "shippingLines.isRefunded",
|
|
227
|
+
SHIPPING_LINES__PAYMENT_METHOD = "shippingLines.paymentMethod",
|
|
228
|
+
SHIPPING_LINES__PRICE = "shippingLines.price",
|
|
229
|
+
SHIPPING_LINES__SHIPPING_SETTINGS_ID = "shippingLines.shippingSettingsId",
|
|
230
|
+
SHIPPING_LINES__SHIPPING_ZONE_RATE_ID = "shippingLines.shippingZoneRateId",
|
|
231
|
+
SHIPPING_LINES__TAX_VALUE = "shippingLines.taxValue",
|
|
232
|
+
SHIPPING_LINES__TITLE = "shippingLines.title",
|
|
233
|
+
SHIPPING_METHOD = "shippingMethod",
|
|
234
|
+
STATUS = "status",
|
|
235
|
+
TAX_LINES__PRICE = "taxLines.price",
|
|
236
|
+
TAX_LINES__RATE = "taxLines.rate",
|
|
237
|
+
TOTAL_FINAL_PRICE = "totalFinalPrice",
|
|
238
|
+
TOTAL_PRICE = "totalPrice",
|
|
239
|
+
UPDATED_AT = "updatedAt",
|
|
240
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchQuery,
|
|
3
|
+
ConfigType,
|
|
4
|
+
APIResponse,
|
|
5
|
+
handleAPIError,
|
|
6
|
+
} from "@ikas/fe-api-client";
|
|
7
|
+
import {
|
|
8
|
+
CreateSaleTransactionWithCartInput,
|
|
9
|
+
TransactionResponse,
|
|
10
|
+
} from "../types";
|
|
11
|
+
|
|
12
|
+
const createSaleTransactionWithCart = async (
|
|
13
|
+
variables: QueryParams,
|
|
14
|
+
fields?: string[],
|
|
15
|
+
config?: ConfigType
|
|
16
|
+
) => {
|
|
17
|
+
try {
|
|
18
|
+
const { data, errors } = await fetchQuery({
|
|
19
|
+
operationName: "createSaleTransactionWithCart",
|
|
20
|
+
config,
|
|
21
|
+
variables,
|
|
22
|
+
allReturnFields,
|
|
23
|
+
fields,
|
|
24
|
+
query: (returnFields: string) => `
|
|
25
|
+
mutation createSaleTransactionWithCart (
|
|
26
|
+
$input: CreateSaleTransactionWithCartInput!,
|
|
27
|
+
) {
|
|
28
|
+
createSaleTransactionWithCart (
|
|
29
|
+
input: $input,
|
|
30
|
+
) ${returnFields}
|
|
31
|
+
}
|
|
32
|
+
`,
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
return new APIResponse<TransactionResponse>(
|
|
36
|
+
data?.createSaleTransactionWithCart,
|
|
37
|
+
errors
|
|
38
|
+
);
|
|
39
|
+
} catch (err) {
|
|
40
|
+
return handleAPIError(err);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export default createSaleTransactionWithCart;
|
|
45
|
+
|
|
46
|
+
export type QueryParams = {
|
|
47
|
+
input: CreateSaleTransactionWithCartInput;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
const allReturnFields =
|
|
51
|
+
"{error {code declineCode message } orderId orderNumber returnSlug transactionId transactionStatus }";
|
|
52
|
+
|
|
53
|
+
export enum ResponseField {
|
|
54
|
+
ERROR__CODE = "error.code",
|
|
55
|
+
ERROR__DECLINE_CODE = "error.declineCode",
|
|
56
|
+
ERROR__MESSAGE = "error.message",
|
|
57
|
+
ORDER_ID = "orderId",
|
|
58
|
+
ORDER_NUMBER = "orderNumber",
|
|
59
|
+
RETURN_SLUG = "returnSlug",
|
|
60
|
+
TRANSACTION_ID = "transactionId",
|
|
61
|
+
TRANSACTION_STATUS = "transactionStatus",
|
|
62
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchQuery,
|
|
3
|
+
ConfigType,
|
|
4
|
+
APIResponse,
|
|
5
|
+
handleAPIError,
|
|
6
|
+
} from "@ikas/fe-api-client";
|
|
7
|
+
import {
|
|
8
|
+
CreateSaleTransactionWithCheckoutInput,
|
|
9
|
+
TransactionResponse,
|
|
10
|
+
} from "../types";
|
|
11
|
+
|
|
12
|
+
const createSaleTransactionWithCheckout = async (
|
|
13
|
+
variables: QueryParams,
|
|
14
|
+
fields?: string[],
|
|
15
|
+
config?: ConfigType
|
|
16
|
+
) => {
|
|
17
|
+
try {
|
|
18
|
+
const { data, errors } = await fetchQuery({
|
|
19
|
+
operationName: "createSaleTransactionWithCheckout",
|
|
20
|
+
config,
|
|
21
|
+
variables,
|
|
22
|
+
allReturnFields,
|
|
23
|
+
fields,
|
|
24
|
+
query: (returnFields: string) => `
|
|
25
|
+
mutation createSaleTransactionWithCheckout (
|
|
26
|
+
$input: CreateSaleTransactionWithCheckoutInput!,
|
|
27
|
+
) {
|
|
28
|
+
createSaleTransactionWithCheckout (
|
|
29
|
+
input: $input,
|
|
30
|
+
) ${returnFields}
|
|
31
|
+
}
|
|
32
|
+
`,
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
return new APIResponse<TransactionResponse>(
|
|
36
|
+
data?.createSaleTransactionWithCheckout,
|
|
37
|
+
errors
|
|
38
|
+
);
|
|
39
|
+
} catch (err) {
|
|
40
|
+
return handleAPIError(err);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export default createSaleTransactionWithCheckout;
|
|
45
|
+
|
|
46
|
+
export type QueryParams = {
|
|
47
|
+
input: CreateSaleTransactionWithCheckoutInput;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
const allReturnFields =
|
|
51
|
+
"{error {code declineCode message } orderId orderNumber returnSlug transactionId transactionStatus }";
|
|
52
|
+
|
|
53
|
+
export enum ResponseField {
|
|
54
|
+
ERROR__CODE = "error.code",
|
|
55
|
+
ERROR__DECLINE_CODE = "error.declineCode",
|
|
56
|
+
ERROR__MESSAGE = "error.message",
|
|
57
|
+
ORDER_ID = "orderId",
|
|
58
|
+
ORDER_NUMBER = "orderNumber",
|
|
59
|
+
RETURN_SLUG = "returnSlug",
|
|
60
|
+
TRANSACTION_ID = "transactionId",
|
|
61
|
+
TRANSACTION_STATUS = "transactionStatus",
|
|
62
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchQuery,
|
|
3
|
+
ConfigType,
|
|
4
|
+
APIResponse,
|
|
5
|
+
handleAPIError,
|
|
6
|
+
} from "@ikas/fe-api-client";
|
|
7
|
+
import {
|
|
8
|
+
CreateSaleTransactionWithCartInput,
|
|
9
|
+
CreateStripePaymentIntentResponse,
|
|
10
|
+
} from "../types";
|
|
11
|
+
|
|
12
|
+
const createStripePaymentIntent = async (
|
|
13
|
+
variables: QueryParams,
|
|
14
|
+
fields?: string[],
|
|
15
|
+
config?: ConfigType
|
|
16
|
+
) => {
|
|
17
|
+
try {
|
|
18
|
+
const { data, errors } = await fetchQuery({
|
|
19
|
+
operationName: "createStripePaymentIntent",
|
|
20
|
+
config,
|
|
21
|
+
variables,
|
|
22
|
+
allReturnFields,
|
|
23
|
+
fields,
|
|
24
|
+
query: (returnFields: string) => `
|
|
25
|
+
mutation createStripePaymentIntent (
|
|
26
|
+
$input: CreateSaleTransactionWithCartInput!,
|
|
27
|
+
) {
|
|
28
|
+
createStripePaymentIntent (
|
|
29
|
+
input: $input,
|
|
30
|
+
) ${returnFields}
|
|
31
|
+
}
|
|
32
|
+
`,
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
return new APIResponse<CreateStripePaymentIntentResponse>(
|
|
36
|
+
data?.createStripePaymentIntent,
|
|
37
|
+
errors
|
|
38
|
+
);
|
|
39
|
+
} catch (err) {
|
|
40
|
+
return handleAPIError(err);
|
|
41
|
+
}
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
export default createStripePaymentIntent;
|
|
45
|
+
|
|
46
|
+
export type QueryParams = {
|
|
47
|
+
input: CreateSaleTransactionWithCartInput;
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
const allReturnFields = "{accountId apiKey callbackUrl clientSecret }";
|
|
51
|
+
|
|
52
|
+
export enum ResponseField {
|
|
53
|
+
ACCOUNT_ID = "accountId",
|
|
54
|
+
API_KEY = "apiKey",
|
|
55
|
+
CALLBACK_URL = "callbackUrl",
|
|
56
|
+
CLIENT_SECRET = "clientSecret",
|
|
57
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import {
|
|
2
|
+
fetchQuery,
|
|
3
|
+
ConfigType,
|
|
4
|
+
APIResponse,
|
|
5
|
+
handleAPIError,
|
|
6
|
+
} from "@ikas/fe-api-client";
|
|
7
|
+
|
|
8
|
+
const customerForgotPassword = async (
|
|
9
|
+
variables: QueryParams,
|
|
10
|
+
config?: ConfigType
|
|
11
|
+
) => {
|
|
12
|
+
try {
|
|
13
|
+
const { data, errors } = await fetchQuery({
|
|
14
|
+
operationName: "customerForgotPassword",
|
|
15
|
+
config,
|
|
16
|
+
variables,
|
|
17
|
+
query: `
|
|
18
|
+
mutation customerForgotPassword (
|
|
19
|
+
$email: String!,
|
|
20
|
+
$locale: String,
|
|
21
|
+
) {
|
|
22
|
+
customerForgotPassword (
|
|
23
|
+
email: $email,
|
|
24
|
+
locale: $locale,
|
|
25
|
+
)
|
|
26
|
+
}
|
|
27
|
+
`,
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
return new APIResponse<boolean>(data?.customerForgotPassword, errors);
|
|
31
|
+
} catch (err) {
|
|
32
|
+
return handleAPIError(err);
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export default customerForgotPassword;
|
|
37
|
+
|
|
38
|
+
export type QueryParams = {
|
|
39
|
+
email: string;
|
|
40
|
+
locale?: string | null;
|
|
41
|
+
};
|