@commercelayer/sdk 4.50.0 → 4.53.0
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/lib/cjs/commercelayer.d.ts +1 -1
- package/lib/cjs/commercelayer.js +1 -1
- package/lib/cjs/resources/gift_cards.d.ts +1 -1
- package/lib/cjs/resources/order_subscriptions.d.ts +1 -1
- package/lib/cjs/resources/orders.d.ts +1 -1
- package/lib/cjs/resources/shipments.d.ts +1 -1
- package/lib/cjs/resources/stock_transfers.d.ts +1 -1
- package/lib/cjs/resources/stripe_payments.d.ts +1 -1
- package/lib/esm/commercelayer.d.ts +1 -1
- package/lib/esm/commercelayer.js +1 -1
- package/lib/esm/resources/gift_cards.d.ts +1 -1
- package/lib/esm/resources/order_subscriptions.d.ts +1 -1
- package/lib/esm/resources/orders.d.ts +1 -1
- package/lib/esm/resources/shipments.d.ts +1 -1
- package/lib/esm/resources/stock_transfers.d.ts +1 -1
- package/lib/esm/resources/stripe_payments.d.ts +1 -1
- package/lib/tsconfig.esm.tsbuildinfo +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
@@ -1 +1 @@
|
|
1
|
-
import*as api from'./api';import{ApiError}from'./error';import type{ErrorInterceptor,InterceptorType,RawResponseReader,RequestInterceptor,ResponseInterceptor}from'./interceptor';import{ResourcesInitConfig}from'./resource';declare const OPEN_API_SCHEMA_VERSION="5.3.
|
1
|
+
import*as api from'./api';import{ApiError}from'./error';import type{ErrorInterceptor,InterceptorType,RawResponseReader,RequestInterceptor,ResponseInterceptor}from'./interceptor';import{ResourcesInitConfig}from'./resource';declare const OPEN_API_SCHEMA_VERSION="5.3.3";export{OPEN_API_SCHEMA_VERSION};type SdkConfig={};type CommerceLayerInitConfig=SdkConfig&ResourcesInitConfig;type CommerceLayerConfig=Partial<CommerceLayerInitConfig>;declare class CommerceLayerClient{#private;static get openApiSchemaVersion():string;readonly openApiSchemaVersion="5.3.3";addresses:api.Addresses;adjustments:api.Adjustments;adyen_gateways:api.AdyenGateways;adyen_payments:api.AdyenPayments;application:api.Applications;attachments:api.Attachments;authorizations:api.Authorizations;avalara_accounts:api.AvalaraAccounts;axerve_gateways:api.AxerveGateways;axerve_payments:api.AxervePayments;billing_info_validation_rules:api.BillingInfoValidationRules;bing_geocoders:api.BingGeocoders;braintree_gateways:api.BraintreeGateways;braintree_payments:api.BraintreePayments;bundles:api.Bundles;buy_x_pay_y_promotions:api.BuyXPayYPromotions;captures:api.Captures;carrier_accounts:api.CarrierAccounts;checkout_com_gateways:api.CheckoutComGateways;checkout_com_payments:api.CheckoutComPayments;cleanups:api.Cleanups;coupon_codes_promotion_rules:api.CouponCodesPromotionRules;coupon_recipients:api.CouponRecipients;coupons:api.Coupons;custom_promotion_rules:api.CustomPromotionRules;customer_addresses:api.CustomerAddresses;customer_groups:api.CustomerGroups;customer_password_resets:api.CustomerPasswordResets;customer_payment_sources:api.CustomerPaymentSources;customer_subscriptions:api.CustomerSubscriptions;customers:api.Customers;delivery_lead_times:api.DeliveryLeadTimes;event_callbacks:api.EventCallbacks;events:api.Events;exports:api.Exports;external_gateways:api.ExternalGateways;external_payments:api.ExternalPayments;external_promotions:api.ExternalPromotions;external_tax_calculators:api.ExternalTaxCalculators;fixed_amount_promotions:api.FixedAmountPromotions;fixed_price_promotions:api.FixedPricePromotions;free_gift_promotions:api.FreeGiftPromotions;free_shipping_promotions:api.FreeShippingPromotions;geocoders:api.Geocoders;gift_card_recipients:api.GiftCardRecipients;gift_cards:api.GiftCards;google_geocoders:api.GoogleGeocoders;imports:api.Imports;in_stock_subscriptions:api.InStockSubscriptions;inventory_models:api.InventoryModels;inventory_return_locations:api.InventoryReturnLocations;inventory_stock_locations:api.InventoryStockLocations;klarna_gateways:api.KlarnaGateways;klarna_payments:api.KlarnaPayments;line_item_options:api.LineItemOptions;line_items:api.LineItems;manual_gateways:api.ManualGateways;manual_tax_calculators:api.ManualTaxCalculators;markets:api.Markets;merchants:api.Merchants;order_amount_promotion_rules:api.OrderAmountPromotionRules;order_copies:api.OrderCopies;order_factories:api.OrderFactories;order_subscription_items:api.OrderSubscriptionItems;order_subscriptions:api.OrderSubscriptions;order_validation_rules:api.OrderValidationRules;orders:api.Orders;organization:api.Organizations;packages:api.Packages;parcel_line_items:api.ParcelLineItems;parcels:api.Parcels;payment_gateways:api.PaymentGateways;payment_methods:api.PaymentMethods;payment_options:api.PaymentOptions;paypal_gateways:api.PaypalGateways;paypal_payments:api.PaypalPayments;percentage_discount_promotions:api.PercentageDiscountPromotions;price_frequency_tiers:api.PriceFrequencyTiers;price_list_schedulers:api.PriceListSchedulers;price_lists:api.PriceLists;price_tiers:api.PriceTiers;price_volume_tiers:api.PriceVolumeTiers;prices:api.Prices;promotion_rules:api.PromotionRules;promotions:api.Promotions;recurring_order_copies:api.RecurringOrderCopies;refunds:api.Refunds;reserved_stocks:api.ReservedStocks;resource_errors:api.ResourceErrors;return_line_items:api.ReturnLineItems;returns:api.Returns;satispay_gateways:api.SatispayGateways;satispay_payments:api.SatispayPayments;shipments:api.Shipments;shipping_categories:api.ShippingCategories;shipping_method_tiers:api.ShippingMethodTiers;shipping_methods:api.ShippingMethods;shipping_weight_tiers:api.ShippingWeightTiers;shipping_zones:api.ShippingZones;sku_list_items:api.SkuListItems;sku_list_promotion_rules:api.SkuListPromotionRules;sku_lists:api.SkuLists;sku_options:api.SkuOptions;skus:api.Skus;stock_items:api.StockItems;stock_line_items:api.StockLineItems;stock_locations:api.StockLocations;stock_reservations:api.StockReservations;stock_transfers:api.StockTransfers;stripe_gateways:api.StripeGateways;stripe_payments:api.StripePayments;subscription_models:api.SubscriptionModels;tags:api.Tags;tax_calculators:api.TaxCalculators;tax_categories:api.TaxCategories;tax_rules:api.TaxRules;taxjar_accounts:api.TaxjarAccounts;transactions:api.Transactions;versions:api.Versions;voids:api.Voids;webhooks:api.Webhooks;wire_transfers:api.WireTransfers;constructor(config:CommerceLayerInitConfig);get currentOrganization():string;private localConfig;config(config:CommerceLayerConfig):void;resources():readonly string[];isApiError(error:any):error is ApiError;addRequestInterceptor(onFulfilled?:RequestInterceptor,onRejected?:ErrorInterceptor):number;addResponseInterceptor(onFulfilled?:ResponseInterceptor,onRejected?:ErrorInterceptor):number;removeInterceptor(type:InterceptorType,id:number):void;addRawResponseReader(options?:{headers:boolean;}):RawResponseReader;removeRawResponseReader(reader:number|RawResponseReader):void;}declare const CommerceLayer:(config:CommerceLayerInitConfig)=>CommerceLayerClient;export default CommerceLayer;export{CommerceLayer};export type{CommerceLayerClient,CommerceLayerConfig,CommerceLayerInitConfig};
|
package/lib/cjs/commercelayer.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
"use strict";var __createBinding=this&&this.__createBinding||(Object.create?function(e,t,s,i){i===void 0&&(i=s);var n=Object.getOwnPropertyDescriptor(t,s);(!n||("get"in n?!t.__esModule:n.writable||n.configurable))&&(n={enumerable:!0,get:function(){return t[s]}}),Object.defineProperty(e,i,n)}:function(e,t,s,i){i===void 0&&(i=s),e[i]=t[s]}),__setModuleDefault=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),__importStar=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var s in e)s!=="default"&&Object.prototype.hasOwnProperty.call(e,s)&&__createBinding(t,e,s);return __setModuleDefault(t,e),t},__classPrivateFieldSet=this&&this.__classPrivateFieldSet||function(e,t,s,i,n){if(i==="m")throw new TypeError("Private method is not writable");if(i==="a"&&!n)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return i==="a"?n.call(e,s):n?n.value=s:t.set(e,s),s},__classPrivateFieldGet=this&&this.__classPrivateFieldGet||function(e,t,s,i){if(s==="a"&&!i)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?i:s==="a"?i.call(e):i?i.value:t.get(e)},__importDefault=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},_CommerceLayerClient_adapter,_CommerceLayerClient_organization;Object.defineProperty(exports,"__esModule",{value:!0}),exports.CommerceLayer=exports.OPEN_API_SCHEMA_VERSION=void 0;const api=__importStar(require("./api")),static_1=require("./static"),resource_1=__importDefault(require("./resource")),debug_1=__importDefault(require("./debug")),debug=(0,debug_1.default)("commercelayer"),OPEN_API_SCHEMA_VERSION="5.3.0";exports.OPEN_API_SCHEMA_VERSION=OPEN_API_SCHEMA_VERSION;class CommerceLayerClient{static get openApiSchemaVersion(){return OPEN_API_SCHEMA_VERSION}constructor(t){this.openApiSchemaVersion=OPEN_API_SCHEMA_VERSION,_CommerceLayerClient_adapter.set(this,void 0),_CommerceLayerClient_organization.set(this,void 0),debug("new commercelayer instance %O",t),__classPrivateFieldSet(this,_CommerceLayerClient_adapter,new resource_1.default(t),"f"),__classPrivateFieldSet(this,_CommerceLayerClient_organization,t.organization,"f"),this.addresses=new api.Addresses(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.adjustments=new api.Adjustments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.adyen_gateways=new api.AdyenGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.adyen_payments=new api.AdyenPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.application=new api.Applications(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.attachments=new api.Attachments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.authorizations=new api.Authorizations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.avalara_accounts=new api.AvalaraAccounts(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.axerve_gateways=new api.AxerveGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.axerve_payments=new api.AxervePayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.billing_info_validation_rules=new api.BillingInfoValidationRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.bing_geocoders=new api.BingGeocoders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.braintree_gateways=new api.BraintreeGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.braintree_payments=new api.BraintreePayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.bundles=new api.Bundles(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.buy_x_pay_y_promotions=new api.BuyXPayYPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.captures=new api.Captures(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.carrier_accounts=new api.CarrierAccounts(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.checkout_com_gateways=new api.CheckoutComGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.checkout_com_payments=new api.CheckoutComPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.cleanups=new api.Cleanups(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.coupon_codes_promotion_rules=new api.CouponCodesPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.coupon_recipients=new api.CouponRecipients(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.coupons=new api.Coupons(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.custom_promotion_rules=new api.CustomPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_addresses=new api.CustomerAddresses(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_groups=new api.CustomerGroups(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_password_resets=new api.CustomerPasswordResets(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_payment_sources=new api.CustomerPaymentSources(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_subscriptions=new api.CustomerSubscriptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customers=new api.Customers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.delivery_lead_times=new api.DeliveryLeadTimes(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.event_callbacks=new api.EventCallbacks(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.events=new api.Events(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.exports=new api.Exports(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_gateways=new api.ExternalGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_payments=new api.ExternalPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_promotions=new api.ExternalPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_tax_calculators=new api.ExternalTaxCalculators(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.fixed_amount_promotions=new api.FixedAmountPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.fixed_price_promotions=new api.FixedPricePromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.free_gift_promotions=new api.FreeGiftPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.free_shipping_promotions=new api.FreeShippingPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.geocoders=new api.Geocoders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.gift_card_recipients=new api.GiftCardRecipients(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.gift_cards=new api.GiftCards(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.google_geocoders=new api.GoogleGeocoders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.imports=new api.Imports(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.in_stock_subscriptions=new api.InStockSubscriptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.inventory_models=new api.InventoryModels(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.inventory_return_locations=new api.InventoryReturnLocations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.inventory_stock_locations=new api.InventoryStockLocations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.klarna_gateways=new api.KlarnaGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.klarna_payments=new api.KlarnaPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.line_item_options=new api.LineItemOptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.line_items=new api.LineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.manual_gateways=new api.ManualGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.manual_tax_calculators=new api.ManualTaxCalculators(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.markets=new api.Markets(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.merchants=new api.Merchants(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_amount_promotion_rules=new api.OrderAmountPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_copies=new api.OrderCopies(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_factories=new api.OrderFactories(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_subscription_items=new api.OrderSubscriptionItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_subscriptions=new api.OrderSubscriptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_validation_rules=new api.OrderValidationRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.orders=new api.Orders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.organization=new api.Organizations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.packages=new api.Packages(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.parcel_line_items=new api.ParcelLineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.parcels=new api.Parcels(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.payment_gateways=new api.PaymentGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.payment_methods=new api.PaymentMethods(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.payment_options=new api.PaymentOptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.paypal_gateways=new api.PaypalGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.paypal_payments=new api.PaypalPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.percentage_discount_promotions=new api.PercentageDiscountPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_frequency_tiers=new api.PriceFrequencyTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_list_schedulers=new api.PriceListSchedulers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_lists=new api.PriceLists(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_tiers=new api.PriceTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_volume_tiers=new api.PriceVolumeTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.prices=new api.Prices(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.promotion_rules=new api.PromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.promotions=new api.Promotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.recurring_order_copies=new api.RecurringOrderCopies(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.refunds=new api.Refunds(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.reserved_stocks=new api.ReservedStocks(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.resource_errors=new api.ResourceErrors(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.return_line_items=new api.ReturnLineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.returns=new api.Returns(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.satispay_gateways=new api.SatispayGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.satispay_payments=new api.SatispayPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipments=new api.Shipments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_categories=new api.ShippingCategories(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_method_tiers=new api.ShippingMethodTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_methods=new api.ShippingMethods(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_weight_tiers=new api.ShippingWeightTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_zones=new api.ShippingZones(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_list_items=new api.SkuListItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_list_promotion_rules=new api.SkuListPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_lists=new api.SkuLists(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_options=new api.SkuOptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.skus=new api.Skus(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_items=new api.StockItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_line_items=new api.StockLineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_locations=new api.StockLocations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_reservations=new api.StockReservations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_transfers=new api.StockTransfers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stripe_gateways=new api.StripeGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stripe_payments=new api.StripePayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.subscription_models=new api.SubscriptionModels(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tags=new api.Tags(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tax_calculators=new api.TaxCalculators(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tax_categories=new api.TaxCategories(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tax_rules=new api.TaxRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.taxjar_accounts=new api.TaxjarAccounts(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.transactions=new api.Transactions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.versions=new api.Versions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.voids=new api.Voids(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.webhooks=new api.Webhooks(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.wire_transfers=new api.WireTransfers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f"))}get currentOrganization(){return __classPrivateFieldGet(this,_CommerceLayerClient_organization,"f")}localConfig(t){t.organization&&__classPrivateFieldSet(this,_CommerceLayerClient_organization,t.organization,"f")}config(t){debug("config %o",t),this.localConfig(t),t.organization||(t.organization=this.currentOrganization),__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").config(t)}resources(){return static_1.CommerceLayerStatic.resources()}isApiError(t){return static_1.CommerceLayerStatic.isApiError(t)}addRequestInterceptor(t,s){return __classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").interceptors.request.use(t,s)}addResponseInterceptor(t,s){return __classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").interceptors.response.use(t,s)}removeInterceptor(t,s){return __classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").interceptors[t].eject(s)}addRawResponseReader(t){const s={id:void 0,rawResponse:void 0,headers:void 0};function i(r){return s.rawResponse=r?.data,t?.headers&&(s.headers=r.headers),r}const n=this.addResponseInterceptor(i);return s.id=n,s}removeRawResponseReader(t){const s=typeof t=="number"?t:t?.id;if(s&&s>=0)return this.removeInterceptor("response",s)}}_CommerceLayerClient_adapter=new WeakMap,_CommerceLayerClient_organization=new WeakMap;const CommerceLayer=e=>new CommerceLayerClient(e);exports.CommerceLayer=CommerceLayer,exports.default=CommerceLayer;
|
1
|
+
"use strict";var __createBinding=this&&this.__createBinding||(Object.create?function(e,t,s,i){i===void 0&&(i=s);var n=Object.getOwnPropertyDescriptor(t,s);(!n||("get"in n?!t.__esModule:n.writable||n.configurable))&&(n={enumerable:!0,get:function(){return t[s]}}),Object.defineProperty(e,i,n)}:function(e,t,s,i){i===void 0&&(i=s),e[i]=t[s]}),__setModuleDefault=this&&this.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),__importStar=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(e!=null)for(var s in e)s!=="default"&&Object.prototype.hasOwnProperty.call(e,s)&&__createBinding(t,e,s);return __setModuleDefault(t,e),t},__classPrivateFieldSet=this&&this.__classPrivateFieldSet||function(e,t,s,i,n){if(i==="m")throw new TypeError("Private method is not writable");if(i==="a"&&!n)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!n:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return i==="a"?n.call(e,s):n?n.value=s:t.set(e,s),s},__classPrivateFieldGet=this&&this.__classPrivateFieldGet||function(e,t,s,i){if(s==="a"&&!i)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return s==="m"?i:s==="a"?i.call(e):i?i.value:t.get(e)},__importDefault=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},_CommerceLayerClient_adapter,_CommerceLayerClient_organization;Object.defineProperty(exports,"__esModule",{value:!0}),exports.CommerceLayer=exports.OPEN_API_SCHEMA_VERSION=void 0;const api=__importStar(require("./api")),static_1=require("./static"),resource_1=__importDefault(require("./resource")),debug_1=__importDefault(require("./debug")),debug=(0,debug_1.default)("commercelayer"),OPEN_API_SCHEMA_VERSION="5.3.3";exports.OPEN_API_SCHEMA_VERSION=OPEN_API_SCHEMA_VERSION;class CommerceLayerClient{static get openApiSchemaVersion(){return OPEN_API_SCHEMA_VERSION}constructor(t){this.openApiSchemaVersion=OPEN_API_SCHEMA_VERSION,_CommerceLayerClient_adapter.set(this,void 0),_CommerceLayerClient_organization.set(this,void 0),debug("new commercelayer instance %O",t),__classPrivateFieldSet(this,_CommerceLayerClient_adapter,new resource_1.default(t),"f"),__classPrivateFieldSet(this,_CommerceLayerClient_organization,t.organization,"f"),this.addresses=new api.Addresses(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.adjustments=new api.Adjustments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.adyen_gateways=new api.AdyenGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.adyen_payments=new api.AdyenPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.application=new api.Applications(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.attachments=new api.Attachments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.authorizations=new api.Authorizations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.avalara_accounts=new api.AvalaraAccounts(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.axerve_gateways=new api.AxerveGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.axerve_payments=new api.AxervePayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.billing_info_validation_rules=new api.BillingInfoValidationRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.bing_geocoders=new api.BingGeocoders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.braintree_gateways=new api.BraintreeGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.braintree_payments=new api.BraintreePayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.bundles=new api.Bundles(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.buy_x_pay_y_promotions=new api.BuyXPayYPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.captures=new api.Captures(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.carrier_accounts=new api.CarrierAccounts(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.checkout_com_gateways=new api.CheckoutComGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.checkout_com_payments=new api.CheckoutComPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.cleanups=new api.Cleanups(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.coupon_codes_promotion_rules=new api.CouponCodesPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.coupon_recipients=new api.CouponRecipients(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.coupons=new api.Coupons(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.custom_promotion_rules=new api.CustomPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_addresses=new api.CustomerAddresses(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_groups=new api.CustomerGroups(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_password_resets=new api.CustomerPasswordResets(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_payment_sources=new api.CustomerPaymentSources(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customer_subscriptions=new api.CustomerSubscriptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.customers=new api.Customers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.delivery_lead_times=new api.DeliveryLeadTimes(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.event_callbacks=new api.EventCallbacks(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.events=new api.Events(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.exports=new api.Exports(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_gateways=new api.ExternalGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_payments=new api.ExternalPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_promotions=new api.ExternalPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.external_tax_calculators=new api.ExternalTaxCalculators(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.fixed_amount_promotions=new api.FixedAmountPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.fixed_price_promotions=new api.FixedPricePromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.free_gift_promotions=new api.FreeGiftPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.free_shipping_promotions=new api.FreeShippingPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.geocoders=new api.Geocoders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.gift_card_recipients=new api.GiftCardRecipients(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.gift_cards=new api.GiftCards(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.google_geocoders=new api.GoogleGeocoders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.imports=new api.Imports(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.in_stock_subscriptions=new api.InStockSubscriptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.inventory_models=new api.InventoryModels(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.inventory_return_locations=new api.InventoryReturnLocations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.inventory_stock_locations=new api.InventoryStockLocations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.klarna_gateways=new api.KlarnaGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.klarna_payments=new api.KlarnaPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.line_item_options=new api.LineItemOptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.line_items=new api.LineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.manual_gateways=new api.ManualGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.manual_tax_calculators=new api.ManualTaxCalculators(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.markets=new api.Markets(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.merchants=new api.Merchants(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_amount_promotion_rules=new api.OrderAmountPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_copies=new api.OrderCopies(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_factories=new api.OrderFactories(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_subscription_items=new api.OrderSubscriptionItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_subscriptions=new api.OrderSubscriptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.order_validation_rules=new api.OrderValidationRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.orders=new api.Orders(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.organization=new api.Organizations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.packages=new api.Packages(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.parcel_line_items=new api.ParcelLineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.parcels=new api.Parcels(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.payment_gateways=new api.PaymentGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.payment_methods=new api.PaymentMethods(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.payment_options=new api.PaymentOptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.paypal_gateways=new api.PaypalGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.paypal_payments=new api.PaypalPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.percentage_discount_promotions=new api.PercentageDiscountPromotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_frequency_tiers=new api.PriceFrequencyTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_list_schedulers=new api.PriceListSchedulers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_lists=new api.PriceLists(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_tiers=new api.PriceTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.price_volume_tiers=new api.PriceVolumeTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.prices=new api.Prices(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.promotion_rules=new api.PromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.promotions=new api.Promotions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.recurring_order_copies=new api.RecurringOrderCopies(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.refunds=new api.Refunds(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.reserved_stocks=new api.ReservedStocks(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.resource_errors=new api.ResourceErrors(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.return_line_items=new api.ReturnLineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.returns=new api.Returns(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.satispay_gateways=new api.SatispayGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.satispay_payments=new api.SatispayPayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipments=new api.Shipments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_categories=new api.ShippingCategories(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_method_tiers=new api.ShippingMethodTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_methods=new api.ShippingMethods(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_weight_tiers=new api.ShippingWeightTiers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.shipping_zones=new api.ShippingZones(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_list_items=new api.SkuListItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_list_promotion_rules=new api.SkuListPromotionRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_lists=new api.SkuLists(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.sku_options=new api.SkuOptions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.skus=new api.Skus(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_items=new api.StockItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_line_items=new api.StockLineItems(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_locations=new api.StockLocations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_reservations=new api.StockReservations(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stock_transfers=new api.StockTransfers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stripe_gateways=new api.StripeGateways(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.stripe_payments=new api.StripePayments(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.subscription_models=new api.SubscriptionModels(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tags=new api.Tags(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tax_calculators=new api.TaxCalculators(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tax_categories=new api.TaxCategories(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.tax_rules=new api.TaxRules(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.taxjar_accounts=new api.TaxjarAccounts(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.transactions=new api.Transactions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.versions=new api.Versions(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.voids=new api.Voids(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.webhooks=new api.Webhooks(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f")),this.wire_transfers=new api.WireTransfers(__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f"))}get currentOrganization(){return __classPrivateFieldGet(this,_CommerceLayerClient_organization,"f")}localConfig(t){t.organization&&__classPrivateFieldSet(this,_CommerceLayerClient_organization,t.organization,"f")}config(t){debug("config %o",t),this.localConfig(t),t.organization||(t.organization=this.currentOrganization),__classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").config(t)}resources(){return static_1.CommerceLayerStatic.resources()}isApiError(t){return static_1.CommerceLayerStatic.isApiError(t)}addRequestInterceptor(t,s){return __classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").interceptors.request.use(t,s)}addResponseInterceptor(t,s){return __classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").interceptors.response.use(t,s)}removeInterceptor(t,s){return __classPrivateFieldGet(this,_CommerceLayerClient_adapter,"f").interceptors[t].eject(s)}addRawResponseReader(t){const s={id:void 0,rawResponse:void 0,headers:void 0};function i(r){return s.rawResponse=r?.data,t?.headers&&(s.headers=r.headers),r}const n=this.addResponseInterceptor(i);return s.id=n,s}removeRawResponseReader(t){const s=typeof t=="number"?t:t?.id;if(s&&s>=0)return this.removeInterceptor("response",s)}}_CommerceLayerClient_adapter=new WeakMap,_CommerceLayerClient_organization=new WeakMap;const CommerceLayer=e=>new CommerceLayerClient(e);exports.CommerceLayer=CommerceLayer,exports.default=CommerceLayer;
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{GiftCardRecipient}from'./gift_card_recipients';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type GiftCardRel=ResourceRel&{type:typeof GiftCards.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type GiftCardRecipientRel=ResourceRel&{type:'gift_card_recipients';};type TagRel=ResourceRel&{type:'tags';};interface GiftCard extends Resource{status?:string;code?:string;currency_code?:string;initial_balance_cents?:number;initial_balance_float?:number;formatted_initial_balance?:string;balance_cents?:number;balance_float?:number;formatted_balance?:string;balance_max_cents?:string;balance_max_float?:number;formatted_balance_max?:string;balance_log?:object[];single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:Market;gift_card_recipient?:GiftCardRecipient;attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface GiftCardCreate extends ResourceCreate{code?:string;currency_code?:string;balance_cents:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}interface GiftCardUpdate extends ResourceUpdate{currency_code?:string;balance_cents?:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;_purchase?:boolean;_activate?:boolean;_deactivate?:boolean;_balance_change_cents?:number;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}declare class GiftCards extends ApiResource{static readonly TYPE:'gift_cards';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<GiftCard>>;create(resource:GiftCardCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;update(resource:GiftCardUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;gift_card_recipient(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;attachments(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isGiftCard(resource:any):resource is GiftCard;relationship(id:string|ResourceId|null):GiftCardRel;type():string;}export default GiftCards;export{GiftCard,GiftCardCreate,GiftCardUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{GiftCardRecipient}from'./gift_card_recipients';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type GiftCardRel=ResourceRel&{type:typeof GiftCards.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type GiftCardRecipientRel=ResourceRel&{type:'gift_card_recipients';};type TagRel=ResourceRel&{type:'tags';};interface GiftCard extends Resource{status?:string;code?:string;currency_code?:string;initial_balance_cents?:number;initial_balance_float?:number;formatted_initial_balance?:string;balance_cents?:number;balance_float?:number;formatted_balance?:string;balance_max_cents?:string;balance_max_float?:number;formatted_balance_max?:string;balance_log?:object[];usage_log?:object;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:Market;gift_card_recipient?:GiftCardRecipient;attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface GiftCardCreate extends ResourceCreate{code?:string;currency_code?:string;balance_cents:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}interface GiftCardUpdate extends ResourceUpdate{currency_code?:string;balance_cents?:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;_purchase?:boolean;_activate?:boolean;_deactivate?:boolean;_balance_change_cents?:number;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}declare class GiftCards extends ApiResource{static readonly TYPE:'gift_cards';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<GiftCard>>;create(resource:GiftCardCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;update(resource:GiftCardUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;gift_card_recipient(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;attachments(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isGiftCard(resource:any):resource is GiftCard;relationship(id:string|ResourceId|null):GiftCardRel;type():string;}export default GiftCards;export{GiftCard,GiftCardCreate,GiftCardUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{SubscriptionModel}from'./subscription_models';import type{Order}from'./orders';import type{Customer}from'./customers';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{OrderSubscriptionItem}from'./order_subscription_items';import type{OrderFactory}from'./order_factories';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Event}from'./events';import type{Version}from'./versions';type OrderSubscriptionRel=ResourceRel&{type:typeof OrderSubscriptions.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type OrderRel=ResourceRel&{type:'orders';};type CustomerPaymentSourceRel=ResourceRel&{type:'customer_payment_sources';};interface OrderSubscription extends Resource{number?:string;status?:string;frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;customer_email?:string;starts_at?:string;expires_at?:string;last_run_at?:string;next_run_at?:string;occurrencies?:number;errors_count?:number;succeeded_on_last_run?:boolean;market?:Market;subscription_model?:SubscriptionModel;source_order?:Order;customer?:Customer;customer_payment_source?:CustomerPaymentSource;order_subscription_items?:OrderSubscriptionItem[];order_factories?:OrderFactory[];recurring_order_copies?:RecurringOrderCopy[];orders?:Order[];events?:Event[];versions?:Version[];}interface OrderSubscriptionCreate extends ResourceCreate{frequency:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;starts_at?:string;expires_at?:string;market?:MarketRel;source_order:OrderRel;}interface OrderSubscriptionUpdate extends ResourceUpdate{frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;expires_at?:string;next_run_at?:string;_activate?:boolean;_deactivate?:boolean;_cancel?:boolean;customer_payment_source?:CustomerPaymentSourceRel;}declare class OrderSubscriptions extends ApiResource{static readonly TYPE:'order_subscriptions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;create(resource:OrderSubscriptionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;update(resource:OrderSubscriptionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;subscription_model(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SubscriptionModel>;source_order(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;customer(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;customer_payment_source(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;order_subscription_items(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscriptionItem>>;order_factories(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;recurring_order_copies(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;orders(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;events(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrderSubscription(resource:any):resource is OrderSubscription;relationship(id:string|ResourceId|null):OrderSubscriptionRel;type():string;}export default OrderSubscriptions;export{OrderSubscription,OrderSubscriptionCreate,OrderSubscriptionUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{SubscriptionModel}from'./subscription_models';import type{Order}from'./orders';import type{Customer}from'./customers';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{OrderSubscriptionItem}from'./order_subscription_items';import type{OrderFactory}from'./order_factories';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Event}from'./events';import type{Version}from'./versions';type OrderSubscriptionRel=ResourceRel&{type:typeof OrderSubscriptions.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type OrderRel=ResourceRel&{type:'orders';};type CustomerPaymentSourceRel=ResourceRel&{type:'customer_payment_sources';};interface OrderSubscription extends Resource{number?:string;status?:string;frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;customer_email?:string;starts_at?:string;expires_at?:string;last_run_at?:string;next_run_at?:string;occurrencies?:number;errors_count?:number;succeeded_on_last_run?:boolean;market?:Market;subscription_model?:SubscriptionModel;source_order?:Order;customer?:Customer;customer_payment_source?:CustomerPaymentSource;order_subscription_items?:OrderSubscriptionItem[];order_factories?:OrderFactory[];recurring_order_copies?:RecurringOrderCopy[];orders?:Order[];events?:Event[];versions?:Version[];}interface OrderSubscriptionCreate extends ResourceCreate{frequency:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;starts_at?:string;expires_at?:string;market?:MarketRel;source_order:OrderRel;}interface OrderSubscriptionUpdate extends ResourceUpdate{frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;expires_at?:string;next_run_at?:string;_activate?:boolean;_deactivate?:boolean;_cancel?:boolean;_convert?:boolean;customer_payment_source?:CustomerPaymentSourceRel;}declare class OrderSubscriptions extends ApiResource{static readonly TYPE:'order_subscriptions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;create(resource:OrderSubscriptionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;update(resource:OrderSubscriptionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;subscription_model(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SubscriptionModel>;source_order(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;customer(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;customer_payment_source(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;order_subscription_items(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscriptionItem>>;order_factories(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;recurring_order_copies(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;orders(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;events(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrderSubscription(resource:any):resource is OrderSubscription;relationship(id:string|ResourceId|null):OrderSubscriptionRel;type():string;}export default OrderSubscriptions;export{OrderSubscription,OrderSubscriptionCreate,OrderSubscriptionUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{Customer}from'./customers';import type{Address}from'./addresses';import type{PaymentMethod}from'./payment_methods';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{Sku}from'./skus';import type{Bundle}from'./bundles';import type{AdyenPayment}from'./adyen_payments';import type{AxervePayment}from'./axerve_payments';import type{BraintreePayment}from'./braintree_payments';import type{CheckoutComPayment}from'./checkout_com_payments';import type{ExternalPayment}from'./external_payments';import type{KlarnaPayment}from'./klarna_payments';import type{PaypalPayment}from'./paypal_payments';import type{SatispayPayment}from'./satispay_payments';import type{StripePayment}from'./stripe_payments';import type{WireTransfer}from'./wire_transfers';import type{LineItem}from'./line_items';import type{LineItemOption}from'./line_item_options';import type{StockReservation}from'./stock_reservations';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{Shipment}from'./shipments';import type{PaymentOption}from'./payment_options';import type{Authorization}from'./authorizations';import type{Capture}from'./captures';import type{Void}from'./voids';import type{Refund}from'./refunds';import type{Return}from'./returns';import type{OrderSubscription}from'./order_subscriptions';import type{OrderFactory}from'./order_factories';import type{OrderCopy}from'./order_copies';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Attachment}from'./attachments';import type{ResourceError}from'./resource_errors';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type OrderRel=ResourceRel&{type:typeof Orders.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type CustomerRel=ResourceRel&{type:'customers';};type AddressRel=ResourceRel&{type:'addresses';};type PaymentMethodRel=ResourceRel&{type:'payment_methods';};type AdyenPaymentRel=ResourceRel&{type:'adyen_payments';};type AxervePaymentRel=ResourceRel&{type:'axerve_payments';};type BraintreePaymentRel=ResourceRel&{type:'braintree_payments';};type CheckoutComPaymentRel=ResourceRel&{type:'checkout_com_payments';};type ExternalPaymentRel=ResourceRel&{type:'external_payments';};type KlarnaPaymentRel=ResourceRel&{type:'klarna_payments';};type PaypalPaymentRel=ResourceRel&{type:'paypal_payments';};type SatispayPaymentRel=ResourceRel&{type:'satispay_payments';};type StripePaymentRel=ResourceRel&{type:'stripe_payments';};type WireTransferRel=ResourceRel&{type:'wire_transfers';};type TagRel=ResourceRel&{type:'tags';};interface Order extends Resource{number?:string;autorefresh?:boolean;place_async?:boolean;status?:string;payment_status?:string;fulfillment_status?:string;guest?:boolean;editable?:boolean;customer_email?:string;language_code?:string;currency_code?:string;tax_included?:boolean;tax_rate?:number;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;requires_billing_info?:boolean;country_code?:string;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;subtotal_amount_cents?:number;subtotal_amount_float?:number;formatted_subtotal_amount?:string;shipping_amount_cents?:number;shipping_amount_float?:number;formatted_shipping_amount?:string;payment_method_amount_cents?:number;payment_method_amount_float?:number;formatted_payment_method_amount?:string;discount_amount_cents?:number;discount_amount_float?:number;formatted_discount_amount?:string;adjustment_amount_cents?:number;adjustment_amount_float?:number;formatted_adjustment_amount?:string;gift_card_amount_cents?:number;gift_card_amount_float?:number;formatted_gift_card_amount?:string;total_tax_amount_cents?:number;total_tax_amount_float?:number;formatted_total_tax_amount?:string;subtotal_tax_amount_cents?:number;subtotal_tax_amount_float?:number;formatted_subtotal_tax_amount?:string;shipping_tax_amount_cents?:number;shipping_tax_amount_float?:number;formatted_shipping_tax_amount?:string;payment_method_tax_amount_cents?:number;payment_method_tax_amount_float?:number;formatted_payment_method_tax_amount?:string;adjustment_tax_amount_cents?:number;adjustment_tax_amount_float?:number;formatted_adjustment_tax_amount?:string;total_amount_cents?:number;total_amount_float?:number;formatted_total_amount?:string;total_taxable_amount_cents?:number;total_taxable_amount_float?:number;formatted_total_taxable_amount?:string;subtotal_taxable_amount_cents?:number;subtotal_taxable_amount_float?:number;formatted_subtotal_taxable_amount?:string;shipping_taxable_amount_cents?:number;shipping_taxable_amount_float?:number;formatted_shipping_taxable_amount?:string;payment_method_taxable_amount_cents?:number;payment_method_taxable_amount_float?:number;formatted_payment_method_taxable_amount?:string;adjustment_taxable_amount_cents?:number;adjustment_taxable_amount_float?:number;formatted_adjustment_taxable_amount?:string;total_amount_with_taxes_cents?:number;total_amount_with_taxes_float?:number;formatted_total_amount_with_taxes?:string;fees_amount_cents?:number;fees_amount_float?:number;formatted_fees_amount?:string;duty_amount_cents?:number;duty_amount_float?:number;formatted_duty_amount?:string;place_total_amount_cents?:number;place_total_amount_float?:number;formatted_place_total_amount?:string;skus_count?:number;line_item_options_count?:number;shipments_count?:number;tax_calculations_count?:number;validations_count?:number;errors_count?:number;payment_source_details?:object;token?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;checkout_url?:string;placed_at?:string;approved_at?:string;cancelled_at?:string;payment_updated_at?:string;fulfillment_updated_at?:string;refreshed_at?:string;archived_at?:string;expires_at?:string;subscription_created_at?:string;circuit_state?:string;circuit_failure_count?:number;market?:Market;customer?:Customer;shipping_address?:Address;billing_address?:Address;available_payment_methods?:PaymentMethod[];available_customer_payment_sources?:CustomerPaymentSource[];available_free_skus?:Sku[];available_free_bundles?:Bundle[];payment_method?:PaymentMethod;payment_source?:AdyenPayment|AxervePayment|BraintreePayment|CheckoutComPayment|ExternalPayment|KlarnaPayment|PaypalPayment|SatispayPayment|StripePayment|WireTransfer;line_items?:LineItem[];line_item_options?:LineItemOption[];stock_reservations?:StockReservation[];stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];shipments?:Shipment[];payment_options?:PaymentOption[];transactions?:Array<Authorization|Capture|Void|Refund>;authorizations?:Authorization[];captures?:Capture[];voids?:Void[];refunds?:Refund[];returns?:Return[];order_subscription?:OrderSubscription;order_subscriptions?:OrderSubscription[];order_factories?:OrderFactory[];order_copies?:OrderCopy[];recurring_order_copies?:RecurringOrderCopy[];attachments?:Attachment[];resource_errors?:ResourceError[];events?:Event[];tags?:Tag[];versions?:Version[];}interface OrderCreate extends ResourceCreate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}interface OrderUpdate extends ResourceUpdate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;_archive?:boolean;_unarchive?:boolean;_pending?:boolean;_place?:boolean;_cancel?:boolean;_approve?:boolean;_approve_and_capture?:boolean;_authorize?:boolean;_authorization_amount_cents?:number;_capture?:boolean;_refund?:boolean;_update_taxes?:boolean;_nullify_payment_source?:boolean;_billing_address_clone_id?:string;_shipping_address_clone_id?:string;_customer_payment_source_id?:string;_shipping_address_same_as_billing?:boolean;_billing_address_same_as_shipping?:boolean;_commit_invoice?:boolean;_refund_invoice?:boolean;_save_payment_source_to_customer_wallet?:boolean;_save_shipping_address_to_customer_address_book?:boolean;_save_billing_address_to_customer_address_book?:boolean;_refresh?:boolean;_validate?:boolean;_create_subscriptions?:boolean;_start_editing?:boolean;_stop_editing?:boolean;_reset_circuit?:boolean;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}declare class Orders extends ApiResource{static readonly TYPE:'orders';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;create(resource:OrderCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;update(resource:OrderUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;customer(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;shipping_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;billing_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;available_payment_methods(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;available_customer_payment_sources(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerPaymentSource>>;available_free_skus(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Sku>>;available_free_bundles(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Bundle>>;payment_method(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentMethod>;line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;line_item_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItemOption>>;stock_reservations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockReservation>>;stock_line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;shipments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;payment_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentOption>>;authorizations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Authorization>>;captures(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Capture>>;voids(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Void>>;refunds(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Refund>>;returns(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Return>>;order_subscription(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;order_subscriptions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;order_factories(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderCopy>>;recurring_order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;attachments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;resource_errors(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ResourceError>>;events(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrder(resource:any):resource is Order;relationship(id:string|ResourceId|null):OrderRel;type():string;}export default Orders;export{Order,OrderCreate,OrderUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{Customer}from'./customers';import type{Address}from'./addresses';import type{PaymentMethod}from'./payment_methods';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{Sku}from'./skus';import type{Bundle}from'./bundles';import type{AdyenPayment}from'./adyen_payments';import type{AxervePayment}from'./axerve_payments';import type{BraintreePayment}from'./braintree_payments';import type{CheckoutComPayment}from'./checkout_com_payments';import type{ExternalPayment}from'./external_payments';import type{KlarnaPayment}from'./klarna_payments';import type{PaypalPayment}from'./paypal_payments';import type{SatispayPayment}from'./satispay_payments';import type{StripePayment}from'./stripe_payments';import type{WireTransfer}from'./wire_transfers';import type{LineItem}from'./line_items';import type{LineItemOption}from'./line_item_options';import type{StockReservation}from'./stock_reservations';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{Shipment}from'./shipments';import type{PaymentOption}from'./payment_options';import type{Authorization}from'./authorizations';import type{Capture}from'./captures';import type{Void}from'./voids';import type{Refund}from'./refunds';import type{Return}from'./returns';import type{OrderSubscription}from'./order_subscriptions';import type{OrderFactory}from'./order_factories';import type{OrderCopy}from'./order_copies';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Attachment}from'./attachments';import type{ResourceError}from'./resource_errors';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type OrderRel=ResourceRel&{type:typeof Orders.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type CustomerRel=ResourceRel&{type:'customers';};type AddressRel=ResourceRel&{type:'addresses';};type PaymentMethodRel=ResourceRel&{type:'payment_methods';};type AdyenPaymentRel=ResourceRel&{type:'adyen_payments';};type AxervePaymentRel=ResourceRel&{type:'axerve_payments';};type BraintreePaymentRel=ResourceRel&{type:'braintree_payments';};type CheckoutComPaymentRel=ResourceRel&{type:'checkout_com_payments';};type ExternalPaymentRel=ResourceRel&{type:'external_payments';};type KlarnaPaymentRel=ResourceRel&{type:'klarna_payments';};type PaypalPaymentRel=ResourceRel&{type:'paypal_payments';};type SatispayPaymentRel=ResourceRel&{type:'satispay_payments';};type StripePaymentRel=ResourceRel&{type:'stripe_payments';};type WireTransferRel=ResourceRel&{type:'wire_transfers';};type TagRel=ResourceRel&{type:'tags';};interface Order extends Resource{number?:string;autorefresh?:boolean;place_async?:boolean;status?:string;payment_status?:string;fulfillment_status?:string;guest?:boolean;editable?:boolean;customer_email?:string;language_code?:string;currency_code?:string;tax_included?:boolean;tax_rate?:number;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;requires_billing_info?:boolean;country_code?:string;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;subtotal_amount_cents?:number;subtotal_amount_float?:number;formatted_subtotal_amount?:string;shipping_amount_cents?:number;shipping_amount_float?:number;formatted_shipping_amount?:string;payment_method_amount_cents?:number;payment_method_amount_float?:number;formatted_payment_method_amount?:string;discount_amount_cents?:number;discount_amount_float?:number;formatted_discount_amount?:string;adjustment_amount_cents?:number;adjustment_amount_float?:number;formatted_adjustment_amount?:string;gift_card_amount_cents?:number;gift_card_amount_float?:number;formatted_gift_card_amount?:string;total_tax_amount_cents?:number;total_tax_amount_float?:number;formatted_total_tax_amount?:string;subtotal_tax_amount_cents?:number;subtotal_tax_amount_float?:number;formatted_subtotal_tax_amount?:string;shipping_tax_amount_cents?:number;shipping_tax_amount_float?:number;formatted_shipping_tax_amount?:string;payment_method_tax_amount_cents?:number;payment_method_tax_amount_float?:number;formatted_payment_method_tax_amount?:string;adjustment_tax_amount_cents?:number;adjustment_tax_amount_float?:number;formatted_adjustment_tax_amount?:string;total_amount_cents?:number;total_amount_float?:number;formatted_total_amount?:string;total_taxable_amount_cents?:number;total_taxable_amount_float?:number;formatted_total_taxable_amount?:string;subtotal_taxable_amount_cents?:number;subtotal_taxable_amount_float?:number;formatted_subtotal_taxable_amount?:string;shipping_taxable_amount_cents?:number;shipping_taxable_amount_float?:number;formatted_shipping_taxable_amount?:string;payment_method_taxable_amount_cents?:number;payment_method_taxable_amount_float?:number;formatted_payment_method_taxable_amount?:string;adjustment_taxable_amount_cents?:number;adjustment_taxable_amount_float?:number;formatted_adjustment_taxable_amount?:string;total_amount_with_taxes_cents?:number;total_amount_with_taxes_float?:number;formatted_total_amount_with_taxes?:string;fees_amount_cents?:number;fees_amount_float?:number;formatted_fees_amount?:string;duty_amount_cents?:number;duty_amount_float?:number;formatted_duty_amount?:string;place_total_amount_cents?:number;place_total_amount_float?:number;formatted_place_total_amount?:string;skus_count?:number;line_item_options_count?:number;shipments_count?:number;tax_calculations_count?:number;validations_count?:number;errors_count?:number;payment_source_details?:object;token?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;checkout_url?:string;placed_at?:string;approved_at?:string;cancelled_at?:string;payment_updated_at?:string;fulfillment_updated_at?:string;refreshed_at?:string;archived_at?:string;expires_at?:string;subscription_created_at?:string;circuit_state?:string;circuit_failure_count?:number;market?:Market;customer?:Customer;shipping_address?:Address;billing_address?:Address;available_payment_methods?:PaymentMethod[];available_customer_payment_sources?:CustomerPaymentSource[];available_free_skus?:Sku[];available_free_bundles?:Bundle[];payment_method?:PaymentMethod;payment_source?:AdyenPayment|AxervePayment|BraintreePayment|CheckoutComPayment|ExternalPayment|KlarnaPayment|PaypalPayment|SatispayPayment|StripePayment|WireTransfer;line_items?:LineItem[];line_item_options?:LineItemOption[];stock_reservations?:StockReservation[];stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];shipments?:Shipment[];payment_options?:PaymentOption[];transactions?:Array<Authorization|Capture|Void|Refund>;authorizations?:Authorization[];captures?:Capture[];voids?:Void[];refunds?:Refund[];returns?:Return[];order_subscription?:OrderSubscription;order_subscriptions?:OrderSubscription[];order_factories?:OrderFactory[];order_copies?:OrderCopy[];recurring_order_copies?:RecurringOrderCopy[];attachments?:Attachment[];resource_errors?:ResourceError[];events?:Event[];tags?:Tag[];versions?:Version[];}interface OrderCreate extends ResourceCreate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}interface OrderUpdate extends ResourceUpdate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;_archive?:boolean;_unarchive?:boolean;_pending?:boolean;_place?:boolean;_cancel?:boolean;_approve?:boolean;_approve_and_capture?:boolean;_authorize?:boolean;_authorization_amount_cents?:number;_capture?:boolean;_refund?:boolean;_fulfill?:boolean;_update_taxes?:boolean;_nullify_payment_source?:boolean;_billing_address_clone_id?:string;_shipping_address_clone_id?:string;_customer_payment_source_id?:string;_shipping_address_same_as_billing?:boolean;_billing_address_same_as_shipping?:boolean;_commit_invoice?:boolean;_refund_invoice?:boolean;_save_payment_source_to_customer_wallet?:boolean;_save_shipping_address_to_customer_address_book?:boolean;_save_billing_address_to_customer_address_book?:boolean;_refresh?:boolean;_validate?:boolean;_create_subscriptions?:boolean;_start_editing?:boolean;_stop_editing?:boolean;_reset_circuit?:boolean;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}declare class Orders extends ApiResource{static readonly TYPE:'orders';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;create(resource:OrderCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;update(resource:OrderUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;customer(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;shipping_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;billing_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;available_payment_methods(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;available_customer_payment_sources(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerPaymentSource>>;available_free_skus(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Sku>>;available_free_bundles(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Bundle>>;payment_method(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentMethod>;line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;line_item_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItemOption>>;stock_reservations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockReservation>>;stock_line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;shipments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;payment_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentOption>>;authorizations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Authorization>>;captures(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Capture>>;voids(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Void>>;refunds(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Refund>>;returns(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Return>>;order_subscription(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;order_subscriptions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;order_factories(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderCopy>>;recurring_order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;attachments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;resource_errors(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ResourceError>>;events(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrder(resource:any):resource is Order;relationship(id:string|ResourceId|null):OrderRel;type():string;}export default Orders;export{Order,OrderCreate,OrderUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{ShippingCategory}from'./shipping_categories';import type{InventoryStockLocation}from'./inventory_stock_locations';import type{StockLocation}from'./stock_locations';import type{Address}from'./addresses';import type{ShippingMethod}from'./shipping_methods';import type{DeliveryLeadTime}from'./delivery_lead_times';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{LineItem}from'./line_items';import type{CarrierAccount}from'./carrier_accounts';import type{Parcel}from'./parcels';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type ShipmentRel=ResourceRel&{type:typeof Shipments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};type ShippingCategoryRel=ResourceRel&{type:'shipping_categories';};type InventoryStockLocationRel=ResourceRel&{type:'inventory_stock_locations';};type AddressRel=ResourceRel&{type:'addresses';};type ShippingMethodRel=ResourceRel&{type:'shipping_methods';};type TagRel=ResourceRel&{type:'tags';};interface Shipment extends Resource{number?:string;status?:string;currency_code?:string;cost_amount_cents?:number;cost_amount_float?:number;formatted_cost_amount?:string;skus_count?:number;selected_rate_id?:string;rates?:object[];purchase_error_code?:string;purchase_error_message?:string;get_rates_errors?:object[];get_rates_started_at?:string;get_rates_completed_at?:string;purchase_started_at?:string;purchase_completed_at?:string;purchase_failed_at?:string;on_hold_at?:string;picking_at?:string;packing_at?:string;ready_to_ship_at?:string;shipped_at?:string;order?:Order;shipping_category?:ShippingCategory;inventory_stock_location?:InventoryStockLocation;stock_location?:StockLocation;origin_address?:Address;shipping_address?:Address;shipping_method?:ShippingMethod;delivery_lead_time?:DeliveryLeadTime;stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];line_items?:LineItem[];available_shipping_methods?:ShippingMethod[];carrier_accounts?:CarrierAccount[];parcels?:Parcel[];attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface ShipmentCreate extends ResourceCreate{order:OrderRel;shipping_category?:ShippingCategoryRel;inventory_stock_location:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}interface ShipmentUpdate extends ResourceUpdate{_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_packing?:boolean;_ready_to_ship?:boolean;_ship?:boolean;_reserve_stock?:boolean;_release_stock?:boolean;_decrement_stock?:boolean;_get_rates?:boolean;selected_rate_id?:string;_purchase?:boolean;shipping_category?:ShippingCategoryRel;inventory_stock_location?:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}declare class Shipments extends ApiResource{static readonly TYPE:'shipments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;create(resource:ShipmentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;update(resource:ShipmentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;shipping_category(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingCategory>;inventory_stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryStockLocation>;stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;origin_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_method(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingMethod>;delivery_lead_time(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<DeliveryLeadTime>;stock_line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;available_shipping_methods(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ShippingMethod>>;carrier_accounts(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CarrierAccount>>;parcels(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Parcel>>;attachments(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isShipment(resource:any):resource is Shipment;relationship(id:string|ResourceId|null):ShipmentRel;type():string;}export default Shipments;export{Shipment,ShipmentCreate,ShipmentUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{ShippingCategory}from'./shipping_categories';import type{InventoryStockLocation}from'./inventory_stock_locations';import type{StockLocation}from'./stock_locations';import type{Address}from'./addresses';import type{ShippingMethod}from'./shipping_methods';import type{DeliveryLeadTime}from'./delivery_lead_times';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{LineItem}from'./line_items';import type{CarrierAccount}from'./carrier_accounts';import type{Parcel}from'./parcels';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type ShipmentRel=ResourceRel&{type:typeof Shipments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};type ShippingCategoryRel=ResourceRel&{type:'shipping_categories';};type InventoryStockLocationRel=ResourceRel&{type:'inventory_stock_locations';};type AddressRel=ResourceRel&{type:'addresses';};type ShippingMethodRel=ResourceRel&{type:'shipping_methods';};type TagRel=ResourceRel&{type:'tags';};interface Shipment extends Resource{number?:string;status?:string;currency_code?:string;cost_amount_cents?:number;cost_amount_float?:number;formatted_cost_amount?:string;skus_count?:number;selected_rate_id?:string;rates?:object[];purchase_error_code?:string;purchase_error_message?:string;get_rates_errors?:object[];get_rates_started_at?:string;get_rates_completed_at?:string;purchase_started_at?:string;purchase_completed_at?:string;purchase_failed_at?:string;on_hold_at?:string;picking_at?:string;packing_at?:string;ready_to_ship_at?:string;shipped_at?:string;order?:Order;shipping_category?:ShippingCategory;inventory_stock_location?:InventoryStockLocation;stock_location?:StockLocation;origin_address?:Address;shipping_address?:Address;shipping_method?:ShippingMethod;delivery_lead_time?:DeliveryLeadTime;stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];line_items?:LineItem[];available_shipping_methods?:ShippingMethod[];carrier_accounts?:CarrierAccount[];parcels?:Parcel[];attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface ShipmentCreate extends ResourceCreate{order:OrderRel;shipping_category?:ShippingCategoryRel;inventory_stock_location:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}interface ShipmentUpdate extends ResourceUpdate{number?:string;_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_packing?:boolean;_ready_to_ship?:boolean;_ship?:boolean;_deliver?:boolean;_reserve_stock?:boolean;_release_stock?:boolean;_decrement_stock?:boolean;_get_rates?:boolean;selected_rate_id?:string;_purchase?:boolean;shipping_category?:ShippingCategoryRel;inventory_stock_location?:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}declare class Shipments extends ApiResource{static readonly TYPE:'shipments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;create(resource:ShipmentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;update(resource:ShipmentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;shipping_category(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingCategory>;inventory_stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryStockLocation>;stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;origin_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_method(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingMethod>;delivery_lead_time(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<DeliveryLeadTime>;stock_line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;available_shipping_methods(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ShippingMethod>>;carrier_accounts(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CarrierAccount>>;parcels(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Parcel>>;attachments(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isShipment(resource:any):resource is Shipment;relationship(id:string|ResourceId|null):ShipmentRel;type():string;}export default Shipments;export{Shipment,ShipmentCreate,ShipmentUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Sku}from'./skus';import type{StockLocation}from'./stock_locations';import type{Shipment}from'./shipments';import type{LineItem}from'./line_items';import type{Event}from'./events';import type{Version}from'./versions';type StockTransferRel=ResourceRel&{type:typeof StockTransfers.TYPE;};type SkuRel=ResourceRel&{type:'skus';};type StockLocationRel=ResourceRel&{type:'stock_locations';};type ShipmentRel=ResourceRel&{type:'shipments';};type LineItemRel=ResourceRel&{type:'line_items';};interface StockTransfer extends Resource{number?:string;sku_code?:string;status?:string;quantity?:number;completed_at?:string;cancelled_at?:string;sku?:Sku;origin_stock_location?:StockLocation;destination_stock_location?:StockLocation;shipment?:Shipment;line_item?:LineItem;events?:Event[];versions?:Version[];}interface StockTransferCreate extends ResourceCreate{sku_code?:string;quantity:number;sku:SkuRel;origin_stock_location:StockLocationRel;destination_stock_location:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}interface StockTransferUpdate extends ResourceUpdate{sku_code?:string;_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_in_transit?:boolean;_complete?:boolean;_cancel?:boolean;sku?:SkuRel;origin_stock_location?:StockLocationRel;destination_stock_location?:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}declare class StockTransfers extends ApiResource{static readonly TYPE:'stock_transfers';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;create(resource:StockTransferCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;update(resource:StockTransferUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;delete(id:string,options?:ResourcesConfig):Promise<void>;sku(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Sku>;origin_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;destination_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;shipment(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;line_item(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;events(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStockTransfer(resource:any):resource is StockTransfer;relationship(id:string|ResourceId|null):StockTransferRel;type():string;}export default StockTransfers;export{StockTransfer,StockTransferCreate,StockTransferUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Sku}from'./skus';import type{StockLocation}from'./stock_locations';import type{Shipment}from'./shipments';import type{LineItem}from'./line_items';import type{Event}from'./events';import type{Version}from'./versions';type StockTransferRel=ResourceRel&{type:typeof StockTransfers.TYPE;};type SkuRel=ResourceRel&{type:'skus';};type StockLocationRel=ResourceRel&{type:'stock_locations';};type ShipmentRel=ResourceRel&{type:'shipments';};type LineItemRel=ResourceRel&{type:'line_items';};interface StockTransfer extends Resource{number?:string;sku_code?:string;status?:string;quantity?:number;completed_at?:string;cancelled_at?:string;sku?:Sku;origin_stock_location?:StockLocation;destination_stock_location?:StockLocation;shipment?:Shipment;line_item?:LineItem;events?:Event[];versions?:Version[];}interface StockTransferCreate extends ResourceCreate{number?:string;sku_code?:string;quantity:number;sku:SkuRel;origin_stock_location:StockLocationRel;destination_stock_location:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}interface StockTransferUpdate extends ResourceUpdate{number?:string;sku_code?:string;_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_in_transit?:boolean;_complete?:boolean;_cancel?:boolean;sku?:SkuRel;origin_stock_location?:StockLocationRel;destination_stock_location?:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}declare class StockTransfers extends ApiResource{static readonly TYPE:'stock_transfers';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;create(resource:StockTransferCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;update(resource:StockTransferUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;delete(id:string,options?:ResourcesConfig):Promise<void>;sku(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Sku>;origin_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;destination_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;shipment(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;line_item(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;events(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStockTransfer(resource:any):resource is StockTransfer;relationship(id:string|ResourceId|null):StockTransferRel;type():string;}export default StockTransfers;export{StockTransfer,StockTransferCreate,StockTransferUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{PaymentGateway}from'./payment_gateways';import type{Version}from'./versions';type StripePaymentRel=ResourceRel&{type:typeof StripePayments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};interface StripePayment extends Resource{stripe_id?:string;client_secret?:string;publishable_key?:string;options?:object;payment_method?:object;mismatched_amounts?:boolean;return_url?:string;receipt_email?:string;payment_instrument?:object;order?:Order;payment_gateway?:PaymentGateway;versions?:Version[];}interface StripePaymentCreate extends ResourceCreate{stripe_id?:string;client_secret?:string;options?:object;return_url?:string;receipt_email?:string;order:OrderRel;}interface StripePaymentUpdate extends ResourceUpdate{options?:object;return_url?:string;_update?:boolean;_refresh?:boolean;order?:OrderRel;}declare class StripePayments extends ApiResource{static readonly TYPE:'stripe_payments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StripePayment>>;create(resource:StripePaymentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;update(resource:StripePaymentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;payment_gateway(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentGateway>;versions(stripePaymentId:string|StripePayment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStripePayment(resource:any):resource is StripePayment;relationship(id:string|ResourceId|null):StripePaymentRel;type():string;}export default StripePayments;export{StripePayment,StripePaymentCreate,StripePaymentUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{PaymentGateway}from'./payment_gateways';import type{Version}from'./versions';type StripePaymentRel=ResourceRel&{type:typeof StripePayments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};interface StripePayment extends Resource{stripe_id?:string;client_secret?:string;charge_id?:string;publishable_key?:string;options?:object;payment_method?:object;mismatched_amounts?:boolean;return_url?:string;receipt_email?:string;payment_instrument?:object;order?:Order;payment_gateway?:PaymentGateway;versions?:Version[];}interface StripePaymentCreate extends ResourceCreate{stripe_id?:string;client_secret?:string;options?:object;return_url?:string;receipt_email?:string;order:OrderRel;}interface StripePaymentUpdate extends ResourceUpdate{options?:object;return_url?:string;_update?:boolean;_refresh?:boolean;order?:OrderRel;}declare class StripePayments extends ApiResource{static readonly TYPE:'stripe_payments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StripePayment>>;create(resource:StripePaymentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;update(resource:StripePaymentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;payment_gateway(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentGateway>;versions(stripePaymentId:string|StripePayment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStripePayment(resource:any):resource is StripePayment;relationship(id:string|ResourceId|null):StripePaymentRel;type():string;}export default StripePayments;export{StripePayment,StripePaymentCreate,StripePaymentUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import*as api from'./api';import{ApiError}from'./error';import type{ErrorInterceptor,InterceptorType,RawResponseReader,RequestInterceptor,ResponseInterceptor}from'./interceptor';import{ResourcesInitConfig}from'./resource';declare const OPEN_API_SCHEMA_VERSION="5.3.
|
1
|
+
import*as api from'./api';import{ApiError}from'./error';import type{ErrorInterceptor,InterceptorType,RawResponseReader,RequestInterceptor,ResponseInterceptor}from'./interceptor';import{ResourcesInitConfig}from'./resource';declare const OPEN_API_SCHEMA_VERSION="5.3.3";export{OPEN_API_SCHEMA_VERSION};type SdkConfig={};type CommerceLayerInitConfig=SdkConfig&ResourcesInitConfig;type CommerceLayerConfig=Partial<CommerceLayerInitConfig>;declare class CommerceLayerClient{#private;static get openApiSchemaVersion():string;readonly openApiSchemaVersion="5.3.3";addresses:api.Addresses;adjustments:api.Adjustments;adyen_gateways:api.AdyenGateways;adyen_payments:api.AdyenPayments;application:api.Applications;attachments:api.Attachments;authorizations:api.Authorizations;avalara_accounts:api.AvalaraAccounts;axerve_gateways:api.AxerveGateways;axerve_payments:api.AxervePayments;billing_info_validation_rules:api.BillingInfoValidationRules;bing_geocoders:api.BingGeocoders;braintree_gateways:api.BraintreeGateways;braintree_payments:api.BraintreePayments;bundles:api.Bundles;buy_x_pay_y_promotions:api.BuyXPayYPromotions;captures:api.Captures;carrier_accounts:api.CarrierAccounts;checkout_com_gateways:api.CheckoutComGateways;checkout_com_payments:api.CheckoutComPayments;cleanups:api.Cleanups;coupon_codes_promotion_rules:api.CouponCodesPromotionRules;coupon_recipients:api.CouponRecipients;coupons:api.Coupons;custom_promotion_rules:api.CustomPromotionRules;customer_addresses:api.CustomerAddresses;customer_groups:api.CustomerGroups;customer_password_resets:api.CustomerPasswordResets;customer_payment_sources:api.CustomerPaymentSources;customer_subscriptions:api.CustomerSubscriptions;customers:api.Customers;delivery_lead_times:api.DeliveryLeadTimes;event_callbacks:api.EventCallbacks;events:api.Events;exports:api.Exports;external_gateways:api.ExternalGateways;external_payments:api.ExternalPayments;external_promotions:api.ExternalPromotions;external_tax_calculators:api.ExternalTaxCalculators;fixed_amount_promotions:api.FixedAmountPromotions;fixed_price_promotions:api.FixedPricePromotions;free_gift_promotions:api.FreeGiftPromotions;free_shipping_promotions:api.FreeShippingPromotions;geocoders:api.Geocoders;gift_card_recipients:api.GiftCardRecipients;gift_cards:api.GiftCards;google_geocoders:api.GoogleGeocoders;imports:api.Imports;in_stock_subscriptions:api.InStockSubscriptions;inventory_models:api.InventoryModels;inventory_return_locations:api.InventoryReturnLocations;inventory_stock_locations:api.InventoryStockLocations;klarna_gateways:api.KlarnaGateways;klarna_payments:api.KlarnaPayments;line_item_options:api.LineItemOptions;line_items:api.LineItems;manual_gateways:api.ManualGateways;manual_tax_calculators:api.ManualTaxCalculators;markets:api.Markets;merchants:api.Merchants;order_amount_promotion_rules:api.OrderAmountPromotionRules;order_copies:api.OrderCopies;order_factories:api.OrderFactories;order_subscription_items:api.OrderSubscriptionItems;order_subscriptions:api.OrderSubscriptions;order_validation_rules:api.OrderValidationRules;orders:api.Orders;organization:api.Organizations;packages:api.Packages;parcel_line_items:api.ParcelLineItems;parcels:api.Parcels;payment_gateways:api.PaymentGateways;payment_methods:api.PaymentMethods;payment_options:api.PaymentOptions;paypal_gateways:api.PaypalGateways;paypal_payments:api.PaypalPayments;percentage_discount_promotions:api.PercentageDiscountPromotions;price_frequency_tiers:api.PriceFrequencyTiers;price_list_schedulers:api.PriceListSchedulers;price_lists:api.PriceLists;price_tiers:api.PriceTiers;price_volume_tiers:api.PriceVolumeTiers;prices:api.Prices;promotion_rules:api.PromotionRules;promotions:api.Promotions;recurring_order_copies:api.RecurringOrderCopies;refunds:api.Refunds;reserved_stocks:api.ReservedStocks;resource_errors:api.ResourceErrors;return_line_items:api.ReturnLineItems;returns:api.Returns;satispay_gateways:api.SatispayGateways;satispay_payments:api.SatispayPayments;shipments:api.Shipments;shipping_categories:api.ShippingCategories;shipping_method_tiers:api.ShippingMethodTiers;shipping_methods:api.ShippingMethods;shipping_weight_tiers:api.ShippingWeightTiers;shipping_zones:api.ShippingZones;sku_list_items:api.SkuListItems;sku_list_promotion_rules:api.SkuListPromotionRules;sku_lists:api.SkuLists;sku_options:api.SkuOptions;skus:api.Skus;stock_items:api.StockItems;stock_line_items:api.StockLineItems;stock_locations:api.StockLocations;stock_reservations:api.StockReservations;stock_transfers:api.StockTransfers;stripe_gateways:api.StripeGateways;stripe_payments:api.StripePayments;subscription_models:api.SubscriptionModels;tags:api.Tags;tax_calculators:api.TaxCalculators;tax_categories:api.TaxCategories;tax_rules:api.TaxRules;taxjar_accounts:api.TaxjarAccounts;transactions:api.Transactions;versions:api.Versions;voids:api.Voids;webhooks:api.Webhooks;wire_transfers:api.WireTransfers;constructor(config:CommerceLayerInitConfig);get currentOrganization():string;private localConfig;config(config:CommerceLayerConfig):void;resources():readonly string[];isApiError(error:any):error is ApiError;addRequestInterceptor(onFulfilled?:RequestInterceptor,onRejected?:ErrorInterceptor):number;addResponseInterceptor(onFulfilled?:ResponseInterceptor,onRejected?:ErrorInterceptor):number;removeInterceptor(type:InterceptorType,id:number):void;addRawResponseReader(options?:{headers:boolean;}):RawResponseReader;removeRawResponseReader(reader:number|RawResponseReader):void;}declare const CommerceLayer:(config:CommerceLayerInitConfig)=>CommerceLayerClient;export default CommerceLayer;export{CommerceLayer};export type{CommerceLayerClient,CommerceLayerConfig,CommerceLayerInitConfig};
|
package/lib/esm/commercelayer.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
var w=function(r,i,n,o,a){if(o==="m")throw new TypeError("Private method is not writable");if(o==="a"&&!a)throw new TypeError("Private accessor was defined without a setter");if(typeof i=="function"?r!==i||!a:!i.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return o==="a"?a.call(r,n):a?a.value=n:i.set(r,n),n},t=function(r,i,n,o){if(n==="a"&&!o)throw new TypeError("Private accessor was defined without a getter");if(typeof i=="function"?r!==i||!o:!i.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?o:n==="a"?o.call(r):o?o.value:i.get(r)},s,c;import*as e from"./api";import{CommerceLayerStatic as p}from"./static";import _ from"./resource";import l from"./debug";const u=l("commercelayer"),f="5.3.
|
1
|
+
var w=function(r,i,n,o,a){if(o==="m")throw new TypeError("Private method is not writable");if(o==="a"&&!a)throw new TypeError("Private accessor was defined without a setter");if(typeof i=="function"?r!==i||!a:!i.has(r))throw new TypeError("Cannot write private member to an object whose class did not declare it");return o==="a"?a.call(r,n):a?a.value=n:i.set(r,n),n},t=function(r,i,n,o){if(n==="a"&&!o)throw new TypeError("Private accessor was defined without a getter");if(typeof i=="function"?r!==i||!o:!i.has(r))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?o:n==="a"?o.call(r):o?o.value:i.get(r)},s,c;import*as e from"./api";import{CommerceLayerStatic as p}from"./static";import _ from"./resource";import l from"./debug";const u=l("commercelayer"),f="5.3.3";export{f as OPEN_API_SCHEMA_VERSION};class d{static get openApiSchemaVersion(){return f}constructor(i){this.openApiSchemaVersion=f,s.set(this,void 0),c.set(this,void 0),u("new commercelayer instance %O",i),w(this,s,new _(i),"f"),w(this,c,i.organization,"f"),this.addresses=new e.Addresses(t(this,s,"f")),this.adjustments=new e.Adjustments(t(this,s,"f")),this.adyen_gateways=new e.AdyenGateways(t(this,s,"f")),this.adyen_payments=new e.AdyenPayments(t(this,s,"f")),this.application=new e.Applications(t(this,s,"f")),this.attachments=new e.Attachments(t(this,s,"f")),this.authorizations=new e.Authorizations(t(this,s,"f")),this.avalara_accounts=new e.AvalaraAccounts(t(this,s,"f")),this.axerve_gateways=new e.AxerveGateways(t(this,s,"f")),this.axerve_payments=new e.AxervePayments(t(this,s,"f")),this.billing_info_validation_rules=new e.BillingInfoValidationRules(t(this,s,"f")),this.bing_geocoders=new e.BingGeocoders(t(this,s,"f")),this.braintree_gateways=new e.BraintreeGateways(t(this,s,"f")),this.braintree_payments=new e.BraintreePayments(t(this,s,"f")),this.bundles=new e.Bundles(t(this,s,"f")),this.buy_x_pay_y_promotions=new e.BuyXPayYPromotions(t(this,s,"f")),this.captures=new e.Captures(t(this,s,"f")),this.carrier_accounts=new e.CarrierAccounts(t(this,s,"f")),this.checkout_com_gateways=new e.CheckoutComGateways(t(this,s,"f")),this.checkout_com_payments=new e.CheckoutComPayments(t(this,s,"f")),this.cleanups=new e.Cleanups(t(this,s,"f")),this.coupon_codes_promotion_rules=new e.CouponCodesPromotionRules(t(this,s,"f")),this.coupon_recipients=new e.CouponRecipients(t(this,s,"f")),this.coupons=new e.Coupons(t(this,s,"f")),this.custom_promotion_rules=new e.CustomPromotionRules(t(this,s,"f")),this.customer_addresses=new e.CustomerAddresses(t(this,s,"f")),this.customer_groups=new e.CustomerGroups(t(this,s,"f")),this.customer_password_resets=new e.CustomerPasswordResets(t(this,s,"f")),this.customer_payment_sources=new e.CustomerPaymentSources(t(this,s,"f")),this.customer_subscriptions=new e.CustomerSubscriptions(t(this,s,"f")),this.customers=new e.Customers(t(this,s,"f")),this.delivery_lead_times=new e.DeliveryLeadTimes(t(this,s,"f")),this.event_callbacks=new e.EventCallbacks(t(this,s,"f")),this.events=new e.Events(t(this,s,"f")),this.exports=new e.Exports(t(this,s,"f")),this.external_gateways=new e.ExternalGateways(t(this,s,"f")),this.external_payments=new e.ExternalPayments(t(this,s,"f")),this.external_promotions=new e.ExternalPromotions(t(this,s,"f")),this.external_tax_calculators=new e.ExternalTaxCalculators(t(this,s,"f")),this.fixed_amount_promotions=new e.FixedAmountPromotions(t(this,s,"f")),this.fixed_price_promotions=new e.FixedPricePromotions(t(this,s,"f")),this.free_gift_promotions=new e.FreeGiftPromotions(t(this,s,"f")),this.free_shipping_promotions=new e.FreeShippingPromotions(t(this,s,"f")),this.geocoders=new e.Geocoders(t(this,s,"f")),this.gift_card_recipients=new e.GiftCardRecipients(t(this,s,"f")),this.gift_cards=new e.GiftCards(t(this,s,"f")),this.google_geocoders=new e.GoogleGeocoders(t(this,s,"f")),this.imports=new e.Imports(t(this,s,"f")),this.in_stock_subscriptions=new e.InStockSubscriptions(t(this,s,"f")),this.inventory_models=new e.InventoryModels(t(this,s,"f")),this.inventory_return_locations=new e.InventoryReturnLocations(t(this,s,"f")),this.inventory_stock_locations=new e.InventoryStockLocations(t(this,s,"f")),this.klarna_gateways=new e.KlarnaGateways(t(this,s,"f")),this.klarna_payments=new e.KlarnaPayments(t(this,s,"f")),this.line_item_options=new e.LineItemOptions(t(this,s,"f")),this.line_items=new e.LineItems(t(this,s,"f")),this.manual_gateways=new e.ManualGateways(t(this,s,"f")),this.manual_tax_calculators=new e.ManualTaxCalculators(t(this,s,"f")),this.markets=new e.Markets(t(this,s,"f")),this.merchants=new e.Merchants(t(this,s,"f")),this.order_amount_promotion_rules=new e.OrderAmountPromotionRules(t(this,s,"f")),this.order_copies=new e.OrderCopies(t(this,s,"f")),this.order_factories=new e.OrderFactories(t(this,s,"f")),this.order_subscription_items=new e.OrderSubscriptionItems(t(this,s,"f")),this.order_subscriptions=new e.OrderSubscriptions(t(this,s,"f")),this.order_validation_rules=new e.OrderValidationRules(t(this,s,"f")),this.orders=new e.Orders(t(this,s,"f")),this.organization=new e.Organizations(t(this,s,"f")),this.packages=new e.Packages(t(this,s,"f")),this.parcel_line_items=new e.ParcelLineItems(t(this,s,"f")),this.parcels=new e.Parcels(t(this,s,"f")),this.payment_gateways=new e.PaymentGateways(t(this,s,"f")),this.payment_methods=new e.PaymentMethods(t(this,s,"f")),this.payment_options=new e.PaymentOptions(t(this,s,"f")),this.paypal_gateways=new e.PaypalGateways(t(this,s,"f")),this.paypal_payments=new e.PaypalPayments(t(this,s,"f")),this.percentage_discount_promotions=new e.PercentageDiscountPromotions(t(this,s,"f")),this.price_frequency_tiers=new e.PriceFrequencyTiers(t(this,s,"f")),this.price_list_schedulers=new e.PriceListSchedulers(t(this,s,"f")),this.price_lists=new e.PriceLists(t(this,s,"f")),this.price_tiers=new e.PriceTiers(t(this,s,"f")),this.price_volume_tiers=new e.PriceVolumeTiers(t(this,s,"f")),this.prices=new e.Prices(t(this,s,"f")),this.promotion_rules=new e.PromotionRules(t(this,s,"f")),this.promotions=new e.Promotions(t(this,s,"f")),this.recurring_order_copies=new e.RecurringOrderCopies(t(this,s,"f")),this.refunds=new e.Refunds(t(this,s,"f")),this.reserved_stocks=new e.ReservedStocks(t(this,s,"f")),this.resource_errors=new e.ResourceErrors(t(this,s,"f")),this.return_line_items=new e.ReturnLineItems(t(this,s,"f")),this.returns=new e.Returns(t(this,s,"f")),this.satispay_gateways=new e.SatispayGateways(t(this,s,"f")),this.satispay_payments=new e.SatispayPayments(t(this,s,"f")),this.shipments=new e.Shipments(t(this,s,"f")),this.shipping_categories=new e.ShippingCategories(t(this,s,"f")),this.shipping_method_tiers=new e.ShippingMethodTiers(t(this,s,"f")),this.shipping_methods=new e.ShippingMethods(t(this,s,"f")),this.shipping_weight_tiers=new e.ShippingWeightTiers(t(this,s,"f")),this.shipping_zones=new e.ShippingZones(t(this,s,"f")),this.sku_list_items=new e.SkuListItems(t(this,s,"f")),this.sku_list_promotion_rules=new e.SkuListPromotionRules(t(this,s,"f")),this.sku_lists=new e.SkuLists(t(this,s,"f")),this.sku_options=new e.SkuOptions(t(this,s,"f")),this.skus=new e.Skus(t(this,s,"f")),this.stock_items=new e.StockItems(t(this,s,"f")),this.stock_line_items=new e.StockLineItems(t(this,s,"f")),this.stock_locations=new e.StockLocations(t(this,s,"f")),this.stock_reservations=new e.StockReservations(t(this,s,"f")),this.stock_transfers=new e.StockTransfers(t(this,s,"f")),this.stripe_gateways=new e.StripeGateways(t(this,s,"f")),this.stripe_payments=new e.StripePayments(t(this,s,"f")),this.subscription_models=new e.SubscriptionModels(t(this,s,"f")),this.tags=new e.Tags(t(this,s,"f")),this.tax_calculators=new e.TaxCalculators(t(this,s,"f")),this.tax_categories=new e.TaxCategories(t(this,s,"f")),this.tax_rules=new e.TaxRules(t(this,s,"f")),this.taxjar_accounts=new e.TaxjarAccounts(t(this,s,"f")),this.transactions=new e.Transactions(t(this,s,"f")),this.versions=new e.Versions(t(this,s,"f")),this.voids=new e.Voids(t(this,s,"f")),this.webhooks=new e.Webhooks(t(this,s,"f")),this.wire_transfers=new e.WireTransfers(t(this,s,"f"))}get currentOrganization(){return t(this,c,"f")}localConfig(i){i.organization&&w(this,c,i.organization,"f")}config(i){u("config %o",i),this.localConfig(i),i.organization||(i.organization=this.currentOrganization),t(this,s,"f").config(i)}resources(){return p.resources()}isApiError(i){return p.isApiError(i)}addRequestInterceptor(i,n){return t(this,s,"f").interceptors.request.use(i,n)}addResponseInterceptor(i,n){return t(this,s,"f").interceptors.response.use(i,n)}removeInterceptor(i,n){return t(this,s,"f").interceptors[i].eject(n)}addRawResponseReader(i){const n={id:void 0,rawResponse:void 0,headers:void 0};function o(h){return n.rawResponse=h?.data,i?.headers&&(n.headers=h.headers),h}const a=this.addResponseInterceptor(o);return n.id=a,n}removeRawResponseReader(i){const n=typeof i=="number"?i:i?.id;if(n&&n>=0)return this.removeInterceptor("response",n)}}s=new WeakMap,c=new WeakMap;const m=r=>new d(r);export default m;export{m as CommerceLayer};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{GiftCardRecipient}from'./gift_card_recipients';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type GiftCardRel=ResourceRel&{type:typeof GiftCards.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type GiftCardRecipientRel=ResourceRel&{type:'gift_card_recipients';};type TagRel=ResourceRel&{type:'tags';};interface GiftCard extends Resource{status?:string;code?:string;currency_code?:string;initial_balance_cents?:number;initial_balance_float?:number;formatted_initial_balance?:string;balance_cents?:number;balance_float?:number;formatted_balance?:string;balance_max_cents?:string;balance_max_float?:number;formatted_balance_max?:string;balance_log?:object[];single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:Market;gift_card_recipient?:GiftCardRecipient;attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface GiftCardCreate extends ResourceCreate{code?:string;currency_code?:string;balance_cents:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}interface GiftCardUpdate extends ResourceUpdate{currency_code?:string;balance_cents?:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;_purchase?:boolean;_activate?:boolean;_deactivate?:boolean;_balance_change_cents?:number;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}declare class GiftCards extends ApiResource{static readonly TYPE:'gift_cards';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<GiftCard>>;create(resource:GiftCardCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;update(resource:GiftCardUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;gift_card_recipient(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;attachments(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isGiftCard(resource:any):resource is GiftCard;relationship(id:string|ResourceId|null):GiftCardRel;type():string;}export default GiftCards;export{GiftCard,GiftCardCreate,GiftCardUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{GiftCardRecipient}from'./gift_card_recipients';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type GiftCardRel=ResourceRel&{type:typeof GiftCards.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type GiftCardRecipientRel=ResourceRel&{type:'gift_card_recipients';};type TagRel=ResourceRel&{type:'tags';};interface GiftCard extends Resource{status?:string;code?:string;currency_code?:string;initial_balance_cents?:number;initial_balance_float?:number;formatted_initial_balance?:string;balance_cents?:number;balance_float?:number;formatted_balance?:string;balance_max_cents?:string;balance_max_float?:number;formatted_balance_max?:string;balance_log?:object[];usage_log?:object;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:Market;gift_card_recipient?:GiftCardRecipient;attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface GiftCardCreate extends ResourceCreate{code?:string;currency_code?:string;balance_cents:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}interface GiftCardUpdate extends ResourceUpdate{currency_code?:string;balance_cents?:number;balance_max_cents?:string;single_use?:boolean;rechargeable?:boolean;distribute_discount?:boolean;image_url?:string;expires_at?:string;recipient_email?:string;_purchase?:boolean;_activate?:boolean;_deactivate?:boolean;_balance_change_cents?:number;market?:MarketRel;gift_card_recipient?:GiftCardRecipientRel;tags?:TagRel[];}declare class GiftCards extends ApiResource{static readonly TYPE:'gift_cards';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<GiftCard>>;create(resource:GiftCardCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;update(resource:GiftCardUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCard>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;gift_card_recipient(giftCardId:string|GiftCard,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<GiftCardRecipient>;attachments(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(giftCardId:string|GiftCard,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isGiftCard(resource:any):resource is GiftCard;relationship(id:string|ResourceId|null):GiftCardRel;type():string;}export default GiftCards;export{GiftCard,GiftCardCreate,GiftCardUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{SubscriptionModel}from'./subscription_models';import type{Order}from'./orders';import type{Customer}from'./customers';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{OrderSubscriptionItem}from'./order_subscription_items';import type{OrderFactory}from'./order_factories';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Event}from'./events';import type{Version}from'./versions';type OrderSubscriptionRel=ResourceRel&{type:typeof OrderSubscriptions.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type OrderRel=ResourceRel&{type:'orders';};type CustomerPaymentSourceRel=ResourceRel&{type:'customer_payment_sources';};interface OrderSubscription extends Resource{number?:string;status?:string;frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;customer_email?:string;starts_at?:string;expires_at?:string;last_run_at?:string;next_run_at?:string;occurrencies?:number;errors_count?:number;succeeded_on_last_run?:boolean;market?:Market;subscription_model?:SubscriptionModel;source_order?:Order;customer?:Customer;customer_payment_source?:CustomerPaymentSource;order_subscription_items?:OrderSubscriptionItem[];order_factories?:OrderFactory[];recurring_order_copies?:RecurringOrderCopy[];orders?:Order[];events?:Event[];versions?:Version[];}interface OrderSubscriptionCreate extends ResourceCreate{frequency:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;starts_at?:string;expires_at?:string;market?:MarketRel;source_order:OrderRel;}interface OrderSubscriptionUpdate extends ResourceUpdate{frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;expires_at?:string;next_run_at?:string;_activate?:boolean;_deactivate?:boolean;_cancel?:boolean;customer_payment_source?:CustomerPaymentSourceRel;}declare class OrderSubscriptions extends ApiResource{static readonly TYPE:'order_subscriptions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;create(resource:OrderSubscriptionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;update(resource:OrderSubscriptionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;subscription_model(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SubscriptionModel>;source_order(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;customer(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;customer_payment_source(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;order_subscription_items(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscriptionItem>>;order_factories(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;recurring_order_copies(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;orders(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;events(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrderSubscription(resource:any):resource is OrderSubscription;relationship(id:string|ResourceId|null):OrderSubscriptionRel;type():string;}export default OrderSubscriptions;export{OrderSubscription,OrderSubscriptionCreate,OrderSubscriptionUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{SubscriptionModel}from'./subscription_models';import type{Order}from'./orders';import type{Customer}from'./customers';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{OrderSubscriptionItem}from'./order_subscription_items';import type{OrderFactory}from'./order_factories';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Event}from'./events';import type{Version}from'./versions';type OrderSubscriptionRel=ResourceRel&{type:typeof OrderSubscriptions.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type OrderRel=ResourceRel&{type:'orders';};type CustomerPaymentSourceRel=ResourceRel&{type:'customer_payment_sources';};interface OrderSubscription extends Resource{number?:string;status?:string;frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;customer_email?:string;starts_at?:string;expires_at?:string;last_run_at?:string;next_run_at?:string;occurrencies?:number;errors_count?:number;succeeded_on_last_run?:boolean;market?:Market;subscription_model?:SubscriptionModel;source_order?:Order;customer?:Customer;customer_payment_source?:CustomerPaymentSource;order_subscription_items?:OrderSubscriptionItem[];order_factories?:OrderFactory[];recurring_order_copies?:RecurringOrderCopy[];orders?:Order[];events?:Event[];versions?:Version[];}interface OrderSubscriptionCreate extends ResourceCreate{frequency:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;starts_at?:string;expires_at?:string;market?:MarketRel;source_order:OrderRel;}interface OrderSubscriptionUpdate extends ResourceUpdate{frequency?:string;activate_by_source_order?:boolean;place_target_order?:boolean;renewal_alert_period?:number;expires_at?:string;next_run_at?:string;_activate?:boolean;_deactivate?:boolean;_cancel?:boolean;_convert?:boolean;customer_payment_source?:CustomerPaymentSourceRel;}declare class OrderSubscriptions extends ApiResource{static readonly TYPE:'order_subscriptions';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;create(resource:OrderSubscriptionCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;update(resource:OrderSubscriptionUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;subscription_model(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<SubscriptionModel>;source_order(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;customer(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;customer_payment_source(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<CustomerPaymentSource>;order_subscription_items(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscriptionItem>>;order_factories(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;recurring_order_copies(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;orders(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;events(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(orderSubscriptionId:string|OrderSubscription,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrderSubscription(resource:any):resource is OrderSubscription;relationship(id:string|ResourceId|null):OrderSubscriptionRel;type():string;}export default OrderSubscriptions;export{OrderSubscription,OrderSubscriptionCreate,OrderSubscriptionUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{Customer}from'./customers';import type{Address}from'./addresses';import type{PaymentMethod}from'./payment_methods';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{Sku}from'./skus';import type{Bundle}from'./bundles';import type{AdyenPayment}from'./adyen_payments';import type{AxervePayment}from'./axerve_payments';import type{BraintreePayment}from'./braintree_payments';import type{CheckoutComPayment}from'./checkout_com_payments';import type{ExternalPayment}from'./external_payments';import type{KlarnaPayment}from'./klarna_payments';import type{PaypalPayment}from'./paypal_payments';import type{SatispayPayment}from'./satispay_payments';import type{StripePayment}from'./stripe_payments';import type{WireTransfer}from'./wire_transfers';import type{LineItem}from'./line_items';import type{LineItemOption}from'./line_item_options';import type{StockReservation}from'./stock_reservations';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{Shipment}from'./shipments';import type{PaymentOption}from'./payment_options';import type{Authorization}from'./authorizations';import type{Capture}from'./captures';import type{Void}from'./voids';import type{Refund}from'./refunds';import type{Return}from'./returns';import type{OrderSubscription}from'./order_subscriptions';import type{OrderFactory}from'./order_factories';import type{OrderCopy}from'./order_copies';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Attachment}from'./attachments';import type{ResourceError}from'./resource_errors';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type OrderRel=ResourceRel&{type:typeof Orders.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type CustomerRel=ResourceRel&{type:'customers';};type AddressRel=ResourceRel&{type:'addresses';};type PaymentMethodRel=ResourceRel&{type:'payment_methods';};type AdyenPaymentRel=ResourceRel&{type:'adyen_payments';};type AxervePaymentRel=ResourceRel&{type:'axerve_payments';};type BraintreePaymentRel=ResourceRel&{type:'braintree_payments';};type CheckoutComPaymentRel=ResourceRel&{type:'checkout_com_payments';};type ExternalPaymentRel=ResourceRel&{type:'external_payments';};type KlarnaPaymentRel=ResourceRel&{type:'klarna_payments';};type PaypalPaymentRel=ResourceRel&{type:'paypal_payments';};type SatispayPaymentRel=ResourceRel&{type:'satispay_payments';};type StripePaymentRel=ResourceRel&{type:'stripe_payments';};type WireTransferRel=ResourceRel&{type:'wire_transfers';};type TagRel=ResourceRel&{type:'tags';};interface Order extends Resource{number?:string;autorefresh?:boolean;place_async?:boolean;status?:string;payment_status?:string;fulfillment_status?:string;guest?:boolean;editable?:boolean;customer_email?:string;language_code?:string;currency_code?:string;tax_included?:boolean;tax_rate?:number;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;requires_billing_info?:boolean;country_code?:string;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;subtotal_amount_cents?:number;subtotal_amount_float?:number;formatted_subtotal_amount?:string;shipping_amount_cents?:number;shipping_amount_float?:number;formatted_shipping_amount?:string;payment_method_amount_cents?:number;payment_method_amount_float?:number;formatted_payment_method_amount?:string;discount_amount_cents?:number;discount_amount_float?:number;formatted_discount_amount?:string;adjustment_amount_cents?:number;adjustment_amount_float?:number;formatted_adjustment_amount?:string;gift_card_amount_cents?:number;gift_card_amount_float?:number;formatted_gift_card_amount?:string;total_tax_amount_cents?:number;total_tax_amount_float?:number;formatted_total_tax_amount?:string;subtotal_tax_amount_cents?:number;subtotal_tax_amount_float?:number;formatted_subtotal_tax_amount?:string;shipping_tax_amount_cents?:number;shipping_tax_amount_float?:number;formatted_shipping_tax_amount?:string;payment_method_tax_amount_cents?:number;payment_method_tax_amount_float?:number;formatted_payment_method_tax_amount?:string;adjustment_tax_amount_cents?:number;adjustment_tax_amount_float?:number;formatted_adjustment_tax_amount?:string;total_amount_cents?:number;total_amount_float?:number;formatted_total_amount?:string;total_taxable_amount_cents?:number;total_taxable_amount_float?:number;formatted_total_taxable_amount?:string;subtotal_taxable_amount_cents?:number;subtotal_taxable_amount_float?:number;formatted_subtotal_taxable_amount?:string;shipping_taxable_amount_cents?:number;shipping_taxable_amount_float?:number;formatted_shipping_taxable_amount?:string;payment_method_taxable_amount_cents?:number;payment_method_taxable_amount_float?:number;formatted_payment_method_taxable_amount?:string;adjustment_taxable_amount_cents?:number;adjustment_taxable_amount_float?:number;formatted_adjustment_taxable_amount?:string;total_amount_with_taxes_cents?:number;total_amount_with_taxes_float?:number;formatted_total_amount_with_taxes?:string;fees_amount_cents?:number;fees_amount_float?:number;formatted_fees_amount?:string;duty_amount_cents?:number;duty_amount_float?:number;formatted_duty_amount?:string;place_total_amount_cents?:number;place_total_amount_float?:number;formatted_place_total_amount?:string;skus_count?:number;line_item_options_count?:number;shipments_count?:number;tax_calculations_count?:number;validations_count?:number;errors_count?:number;payment_source_details?:object;token?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;checkout_url?:string;placed_at?:string;approved_at?:string;cancelled_at?:string;payment_updated_at?:string;fulfillment_updated_at?:string;refreshed_at?:string;archived_at?:string;expires_at?:string;subscription_created_at?:string;circuit_state?:string;circuit_failure_count?:number;market?:Market;customer?:Customer;shipping_address?:Address;billing_address?:Address;available_payment_methods?:PaymentMethod[];available_customer_payment_sources?:CustomerPaymentSource[];available_free_skus?:Sku[];available_free_bundles?:Bundle[];payment_method?:PaymentMethod;payment_source?:AdyenPayment|AxervePayment|BraintreePayment|CheckoutComPayment|ExternalPayment|KlarnaPayment|PaypalPayment|SatispayPayment|StripePayment|WireTransfer;line_items?:LineItem[];line_item_options?:LineItemOption[];stock_reservations?:StockReservation[];stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];shipments?:Shipment[];payment_options?:PaymentOption[];transactions?:Array<Authorization|Capture|Void|Refund>;authorizations?:Authorization[];captures?:Capture[];voids?:Void[];refunds?:Refund[];returns?:Return[];order_subscription?:OrderSubscription;order_subscriptions?:OrderSubscription[];order_factories?:OrderFactory[];order_copies?:OrderCopy[];recurring_order_copies?:RecurringOrderCopy[];attachments?:Attachment[];resource_errors?:ResourceError[];events?:Event[];tags?:Tag[];versions?:Version[];}interface OrderCreate extends ResourceCreate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}interface OrderUpdate extends ResourceUpdate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;_archive?:boolean;_unarchive?:boolean;_pending?:boolean;_place?:boolean;_cancel?:boolean;_approve?:boolean;_approve_and_capture?:boolean;_authorize?:boolean;_authorization_amount_cents?:number;_capture?:boolean;_refund?:boolean;_update_taxes?:boolean;_nullify_payment_source?:boolean;_billing_address_clone_id?:string;_shipping_address_clone_id?:string;_customer_payment_source_id?:string;_shipping_address_same_as_billing?:boolean;_billing_address_same_as_shipping?:boolean;_commit_invoice?:boolean;_refund_invoice?:boolean;_save_payment_source_to_customer_wallet?:boolean;_save_shipping_address_to_customer_address_book?:boolean;_save_billing_address_to_customer_address_book?:boolean;_refresh?:boolean;_validate?:boolean;_create_subscriptions?:boolean;_start_editing?:boolean;_stop_editing?:boolean;_reset_circuit?:boolean;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}declare class Orders extends ApiResource{static readonly TYPE:'orders';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;create(resource:OrderCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;update(resource:OrderUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;customer(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;shipping_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;billing_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;available_payment_methods(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;available_customer_payment_sources(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerPaymentSource>>;available_free_skus(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Sku>>;available_free_bundles(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Bundle>>;payment_method(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentMethod>;line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;line_item_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItemOption>>;stock_reservations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockReservation>>;stock_line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;shipments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;payment_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentOption>>;authorizations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Authorization>>;captures(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Capture>>;voids(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Void>>;refunds(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Refund>>;returns(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Return>>;order_subscription(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;order_subscriptions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;order_factories(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderCopy>>;recurring_order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;attachments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;resource_errors(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ResourceError>>;events(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrder(resource:any):resource is Order;relationship(id:string|ResourceId|null):OrderRel;type():string;}export default Orders;export{Order,OrderCreate,OrderUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Market}from'./markets';import type{Customer}from'./customers';import type{Address}from'./addresses';import type{PaymentMethod}from'./payment_methods';import type{CustomerPaymentSource}from'./customer_payment_sources';import type{Sku}from'./skus';import type{Bundle}from'./bundles';import type{AdyenPayment}from'./adyen_payments';import type{AxervePayment}from'./axerve_payments';import type{BraintreePayment}from'./braintree_payments';import type{CheckoutComPayment}from'./checkout_com_payments';import type{ExternalPayment}from'./external_payments';import type{KlarnaPayment}from'./klarna_payments';import type{PaypalPayment}from'./paypal_payments';import type{SatispayPayment}from'./satispay_payments';import type{StripePayment}from'./stripe_payments';import type{WireTransfer}from'./wire_transfers';import type{LineItem}from'./line_items';import type{LineItemOption}from'./line_item_options';import type{StockReservation}from'./stock_reservations';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{Shipment}from'./shipments';import type{PaymentOption}from'./payment_options';import type{Authorization}from'./authorizations';import type{Capture}from'./captures';import type{Void}from'./voids';import type{Refund}from'./refunds';import type{Return}from'./returns';import type{OrderSubscription}from'./order_subscriptions';import type{OrderFactory}from'./order_factories';import type{OrderCopy}from'./order_copies';import type{RecurringOrderCopy}from'./recurring_order_copies';import type{Attachment}from'./attachments';import type{ResourceError}from'./resource_errors';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type OrderRel=ResourceRel&{type:typeof Orders.TYPE;};type MarketRel=ResourceRel&{type:'markets';};type CustomerRel=ResourceRel&{type:'customers';};type AddressRel=ResourceRel&{type:'addresses';};type PaymentMethodRel=ResourceRel&{type:'payment_methods';};type AdyenPaymentRel=ResourceRel&{type:'adyen_payments';};type AxervePaymentRel=ResourceRel&{type:'axerve_payments';};type BraintreePaymentRel=ResourceRel&{type:'braintree_payments';};type CheckoutComPaymentRel=ResourceRel&{type:'checkout_com_payments';};type ExternalPaymentRel=ResourceRel&{type:'external_payments';};type KlarnaPaymentRel=ResourceRel&{type:'klarna_payments';};type PaypalPaymentRel=ResourceRel&{type:'paypal_payments';};type SatispayPaymentRel=ResourceRel&{type:'satispay_payments';};type StripePaymentRel=ResourceRel&{type:'stripe_payments';};type WireTransferRel=ResourceRel&{type:'wire_transfers';};type TagRel=ResourceRel&{type:'tags';};interface Order extends Resource{number?:string;autorefresh?:boolean;place_async?:boolean;status?:string;payment_status?:string;fulfillment_status?:string;guest?:boolean;editable?:boolean;customer_email?:string;language_code?:string;currency_code?:string;tax_included?:boolean;tax_rate?:number;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;requires_billing_info?:boolean;country_code?:string;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;subtotal_amount_cents?:number;subtotal_amount_float?:number;formatted_subtotal_amount?:string;shipping_amount_cents?:number;shipping_amount_float?:number;formatted_shipping_amount?:string;payment_method_amount_cents?:number;payment_method_amount_float?:number;formatted_payment_method_amount?:string;discount_amount_cents?:number;discount_amount_float?:number;formatted_discount_amount?:string;adjustment_amount_cents?:number;adjustment_amount_float?:number;formatted_adjustment_amount?:string;gift_card_amount_cents?:number;gift_card_amount_float?:number;formatted_gift_card_amount?:string;total_tax_amount_cents?:number;total_tax_amount_float?:number;formatted_total_tax_amount?:string;subtotal_tax_amount_cents?:number;subtotal_tax_amount_float?:number;formatted_subtotal_tax_amount?:string;shipping_tax_amount_cents?:number;shipping_tax_amount_float?:number;formatted_shipping_tax_amount?:string;payment_method_tax_amount_cents?:number;payment_method_tax_amount_float?:number;formatted_payment_method_tax_amount?:string;adjustment_tax_amount_cents?:number;adjustment_tax_amount_float?:number;formatted_adjustment_tax_amount?:string;total_amount_cents?:number;total_amount_float?:number;formatted_total_amount?:string;total_taxable_amount_cents?:number;total_taxable_amount_float?:number;formatted_total_taxable_amount?:string;subtotal_taxable_amount_cents?:number;subtotal_taxable_amount_float?:number;formatted_subtotal_taxable_amount?:string;shipping_taxable_amount_cents?:number;shipping_taxable_amount_float?:number;formatted_shipping_taxable_amount?:string;payment_method_taxable_amount_cents?:number;payment_method_taxable_amount_float?:number;formatted_payment_method_taxable_amount?:string;adjustment_taxable_amount_cents?:number;adjustment_taxable_amount_float?:number;formatted_adjustment_taxable_amount?:string;total_amount_with_taxes_cents?:number;total_amount_with_taxes_float?:number;formatted_total_amount_with_taxes?:string;fees_amount_cents?:number;fees_amount_float?:number;formatted_fees_amount?:string;duty_amount_cents?:number;duty_amount_float?:number;formatted_duty_amount?:string;place_total_amount_cents?:number;place_total_amount_float?:number;formatted_place_total_amount?:string;skus_count?:number;line_item_options_count?:number;shipments_count?:number;tax_calculations_count?:number;validations_count?:number;errors_count?:number;payment_source_details?:object;token?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;checkout_url?:string;placed_at?:string;approved_at?:string;cancelled_at?:string;payment_updated_at?:string;fulfillment_updated_at?:string;refreshed_at?:string;archived_at?:string;expires_at?:string;subscription_created_at?:string;circuit_state?:string;circuit_failure_count?:number;market?:Market;customer?:Customer;shipping_address?:Address;billing_address?:Address;available_payment_methods?:PaymentMethod[];available_customer_payment_sources?:CustomerPaymentSource[];available_free_skus?:Sku[];available_free_bundles?:Bundle[];payment_method?:PaymentMethod;payment_source?:AdyenPayment|AxervePayment|BraintreePayment|CheckoutComPayment|ExternalPayment|KlarnaPayment|PaypalPayment|SatispayPayment|StripePayment|WireTransfer;line_items?:LineItem[];line_item_options?:LineItemOption[];stock_reservations?:StockReservation[];stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];shipments?:Shipment[];payment_options?:PaymentOption[];transactions?:Array<Authorization|Capture|Void|Refund>;authorizations?:Authorization[];captures?:Capture[];voids?:Void[];refunds?:Refund[];returns?:Return[];order_subscription?:OrderSubscription;order_subscriptions?:OrderSubscription[];order_factories?:OrderFactory[];order_copies?:OrderCopy[];recurring_order_copies?:RecurringOrderCopy[];attachments?:Attachment[];resource_errors?:ResourceError[];events?:Event[];tags?:Tag[];versions?:Version[];}interface OrderCreate extends ResourceCreate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}interface OrderUpdate extends ResourceUpdate{number?:string;autorefresh?:boolean;place_async?:boolean;guest?:boolean;customer_email?:string;customer_password?:string;language_code?:string;freight_taxable?:boolean;payment_method_taxable?:boolean;adjustment_taxable?:boolean;gift_card_taxable?:boolean;shipping_country_code_lock?:string;coupon_code?:string;gift_card_code?:string;cart_url?:string;return_url?:string;terms_url?:string;privacy_url?:string;_archive?:boolean;_unarchive?:boolean;_pending?:boolean;_place?:boolean;_cancel?:boolean;_approve?:boolean;_approve_and_capture?:boolean;_authorize?:boolean;_authorization_amount_cents?:number;_capture?:boolean;_refund?:boolean;_fulfill?:boolean;_update_taxes?:boolean;_nullify_payment_source?:boolean;_billing_address_clone_id?:string;_shipping_address_clone_id?:string;_customer_payment_source_id?:string;_shipping_address_same_as_billing?:boolean;_billing_address_same_as_shipping?:boolean;_commit_invoice?:boolean;_refund_invoice?:boolean;_save_payment_source_to_customer_wallet?:boolean;_save_shipping_address_to_customer_address_book?:boolean;_save_billing_address_to_customer_address_book?:boolean;_refresh?:boolean;_validate?:boolean;_create_subscriptions?:boolean;_start_editing?:boolean;_stop_editing?:boolean;_reset_circuit?:boolean;market?:MarketRel;customer?:CustomerRel;shipping_address?:AddressRel;billing_address?:AddressRel;payment_method?:PaymentMethodRel;payment_source?:AdyenPaymentRel|AxervePaymentRel|BraintreePaymentRel|CheckoutComPaymentRel|ExternalPaymentRel|KlarnaPaymentRel|PaypalPaymentRel|SatispayPaymentRel|StripePaymentRel|WireTransferRel;tags?:TagRel[];}declare class Orders extends ApiResource{static readonly TYPE:'orders';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Order>>;create(resource:OrderCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;update(resource:OrderUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;delete(id:string,options?:ResourcesConfig):Promise<void>;market(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Market>;customer(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Customer>;shipping_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;billing_address(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;available_payment_methods(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentMethod>>;available_customer_payment_sources(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CustomerPaymentSource>>;available_free_skus(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Sku>>;available_free_bundles(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Bundle>>;payment_method(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentMethod>;line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;line_item_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItemOption>>;stock_reservations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockReservation>>;stock_line_items(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;shipments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;payment_options(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<PaymentOption>>;authorizations(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Authorization>>;captures(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Capture>>;voids(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Void>>;refunds(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Refund>>;returns(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Return>>;order_subscription(orderId:string|Order,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<OrderSubscription>;order_subscriptions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderSubscription>>;order_factories(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderFactory>>;order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<OrderCopy>>;recurring_order_copies(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<RecurringOrderCopy>>;attachments(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;resource_errors(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ResourceError>>;events(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(orderId:string|Order,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isOrder(resource:any):resource is Order;relationship(id:string|ResourceId|null):OrderRel;type():string;}export default Orders;export{Order,OrderCreate,OrderUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{ShippingCategory}from'./shipping_categories';import type{InventoryStockLocation}from'./inventory_stock_locations';import type{StockLocation}from'./stock_locations';import type{Address}from'./addresses';import type{ShippingMethod}from'./shipping_methods';import type{DeliveryLeadTime}from'./delivery_lead_times';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{LineItem}from'./line_items';import type{CarrierAccount}from'./carrier_accounts';import type{Parcel}from'./parcels';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type ShipmentRel=ResourceRel&{type:typeof Shipments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};type ShippingCategoryRel=ResourceRel&{type:'shipping_categories';};type InventoryStockLocationRel=ResourceRel&{type:'inventory_stock_locations';};type AddressRel=ResourceRel&{type:'addresses';};type ShippingMethodRel=ResourceRel&{type:'shipping_methods';};type TagRel=ResourceRel&{type:'tags';};interface Shipment extends Resource{number?:string;status?:string;currency_code?:string;cost_amount_cents?:number;cost_amount_float?:number;formatted_cost_amount?:string;skus_count?:number;selected_rate_id?:string;rates?:object[];purchase_error_code?:string;purchase_error_message?:string;get_rates_errors?:object[];get_rates_started_at?:string;get_rates_completed_at?:string;purchase_started_at?:string;purchase_completed_at?:string;purchase_failed_at?:string;on_hold_at?:string;picking_at?:string;packing_at?:string;ready_to_ship_at?:string;shipped_at?:string;order?:Order;shipping_category?:ShippingCategory;inventory_stock_location?:InventoryStockLocation;stock_location?:StockLocation;origin_address?:Address;shipping_address?:Address;shipping_method?:ShippingMethod;delivery_lead_time?:DeliveryLeadTime;stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];line_items?:LineItem[];available_shipping_methods?:ShippingMethod[];carrier_accounts?:CarrierAccount[];parcels?:Parcel[];attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface ShipmentCreate extends ResourceCreate{order:OrderRel;shipping_category?:ShippingCategoryRel;inventory_stock_location:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}interface ShipmentUpdate extends ResourceUpdate{_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_packing?:boolean;_ready_to_ship?:boolean;_ship?:boolean;_reserve_stock?:boolean;_release_stock?:boolean;_decrement_stock?:boolean;_get_rates?:boolean;selected_rate_id?:string;_purchase?:boolean;shipping_category?:ShippingCategoryRel;inventory_stock_location?:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}declare class Shipments extends ApiResource{static readonly TYPE:'shipments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;create(resource:ShipmentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;update(resource:ShipmentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;shipping_category(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingCategory>;inventory_stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryStockLocation>;stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;origin_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_method(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingMethod>;delivery_lead_time(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<DeliveryLeadTime>;stock_line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;available_shipping_methods(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ShippingMethod>>;carrier_accounts(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CarrierAccount>>;parcels(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Parcel>>;attachments(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isShipment(resource:any):resource is Shipment;relationship(id:string|ResourceId|null):ShipmentRel;type():string;}export default Shipments;export{Shipment,ShipmentCreate,ShipmentUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{ShippingCategory}from'./shipping_categories';import type{InventoryStockLocation}from'./inventory_stock_locations';import type{StockLocation}from'./stock_locations';import type{Address}from'./addresses';import type{ShippingMethod}from'./shipping_methods';import type{DeliveryLeadTime}from'./delivery_lead_times';import type{StockLineItem}from'./stock_line_items';import type{StockTransfer}from'./stock_transfers';import type{LineItem}from'./line_items';import type{CarrierAccount}from'./carrier_accounts';import type{Parcel}from'./parcels';import type{Attachment}from'./attachments';import type{Event}from'./events';import type{Tag}from'./tags';import type{Version}from'./versions';type ShipmentRel=ResourceRel&{type:typeof Shipments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};type ShippingCategoryRel=ResourceRel&{type:'shipping_categories';};type InventoryStockLocationRel=ResourceRel&{type:'inventory_stock_locations';};type AddressRel=ResourceRel&{type:'addresses';};type ShippingMethodRel=ResourceRel&{type:'shipping_methods';};type TagRel=ResourceRel&{type:'tags';};interface Shipment extends Resource{number?:string;status?:string;currency_code?:string;cost_amount_cents?:number;cost_amount_float?:number;formatted_cost_amount?:string;skus_count?:number;selected_rate_id?:string;rates?:object[];purchase_error_code?:string;purchase_error_message?:string;get_rates_errors?:object[];get_rates_started_at?:string;get_rates_completed_at?:string;purchase_started_at?:string;purchase_completed_at?:string;purchase_failed_at?:string;on_hold_at?:string;picking_at?:string;packing_at?:string;ready_to_ship_at?:string;shipped_at?:string;order?:Order;shipping_category?:ShippingCategory;inventory_stock_location?:InventoryStockLocation;stock_location?:StockLocation;origin_address?:Address;shipping_address?:Address;shipping_method?:ShippingMethod;delivery_lead_time?:DeliveryLeadTime;stock_line_items?:StockLineItem[];stock_transfers?:StockTransfer[];line_items?:LineItem[];available_shipping_methods?:ShippingMethod[];carrier_accounts?:CarrierAccount[];parcels?:Parcel[];attachments?:Attachment[];events?:Event[];tags?:Tag[];versions?:Version[];}interface ShipmentCreate extends ResourceCreate{order:OrderRel;shipping_category?:ShippingCategoryRel;inventory_stock_location:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}interface ShipmentUpdate extends ResourceUpdate{number?:string;_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_packing?:boolean;_ready_to_ship?:boolean;_ship?:boolean;_deliver?:boolean;_reserve_stock?:boolean;_release_stock?:boolean;_decrement_stock?:boolean;_get_rates?:boolean;selected_rate_id?:string;_purchase?:boolean;shipping_category?:ShippingCategoryRel;inventory_stock_location?:InventoryStockLocationRel;shipping_address?:AddressRel;shipping_method?:ShippingMethodRel;tags?:TagRel[];}declare class Shipments extends ApiResource{static readonly TYPE:'shipments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Shipment>>;create(resource:ShipmentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;update(resource:ShipmentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;shipping_category(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingCategory>;inventory_stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<InventoryStockLocation>;stock_location(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;origin_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_address(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Address>;shipping_method(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<ShippingMethod>;delivery_lead_time(shipmentId:string|Shipment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<DeliveryLeadTime>;stock_line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockLineItem>>;stock_transfers(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;line_items(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<LineItem>>;available_shipping_methods(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<ShippingMethod>>;carrier_accounts(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<CarrierAccount>>;parcels(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Parcel>>;attachments(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Attachment>>;events(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;tags(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Tag>>;versions(shipmentId:string|Shipment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isShipment(resource:any):resource is Shipment;relationship(id:string|ResourceId|null):ShipmentRel;type():string;}export default Shipments;export{Shipment,ShipmentCreate,ShipmentUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Sku}from'./skus';import type{StockLocation}from'./stock_locations';import type{Shipment}from'./shipments';import type{LineItem}from'./line_items';import type{Event}from'./events';import type{Version}from'./versions';type StockTransferRel=ResourceRel&{type:typeof StockTransfers.TYPE;};type SkuRel=ResourceRel&{type:'skus';};type StockLocationRel=ResourceRel&{type:'stock_locations';};type ShipmentRel=ResourceRel&{type:'shipments';};type LineItemRel=ResourceRel&{type:'line_items';};interface StockTransfer extends Resource{number?:string;sku_code?:string;status?:string;quantity?:number;completed_at?:string;cancelled_at?:string;sku?:Sku;origin_stock_location?:StockLocation;destination_stock_location?:StockLocation;shipment?:Shipment;line_item?:LineItem;events?:Event[];versions?:Version[];}interface StockTransferCreate extends ResourceCreate{sku_code?:string;quantity:number;sku:SkuRel;origin_stock_location:StockLocationRel;destination_stock_location:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}interface StockTransferUpdate extends ResourceUpdate{sku_code?:string;_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_in_transit?:boolean;_complete?:boolean;_cancel?:boolean;sku?:SkuRel;origin_stock_location?:StockLocationRel;destination_stock_location?:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}declare class StockTransfers extends ApiResource{static readonly TYPE:'stock_transfers';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;create(resource:StockTransferCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;update(resource:StockTransferUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;delete(id:string,options?:ResourcesConfig):Promise<void>;sku(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Sku>;origin_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;destination_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;shipment(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;line_item(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;events(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStockTransfer(resource:any):resource is StockTransfer;relationship(id:string|ResourceId|null):StockTransferRel;type():string;}export default StockTransfers;export{StockTransfer,StockTransferCreate,StockTransferUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Sku}from'./skus';import type{StockLocation}from'./stock_locations';import type{Shipment}from'./shipments';import type{LineItem}from'./line_items';import type{Event}from'./events';import type{Version}from'./versions';type StockTransferRel=ResourceRel&{type:typeof StockTransfers.TYPE;};type SkuRel=ResourceRel&{type:'skus';};type StockLocationRel=ResourceRel&{type:'stock_locations';};type ShipmentRel=ResourceRel&{type:'shipments';};type LineItemRel=ResourceRel&{type:'line_items';};interface StockTransfer extends Resource{number?:string;sku_code?:string;status?:string;quantity?:number;completed_at?:string;cancelled_at?:string;sku?:Sku;origin_stock_location?:StockLocation;destination_stock_location?:StockLocation;shipment?:Shipment;line_item?:LineItem;events?:Event[];versions?:Version[];}interface StockTransferCreate extends ResourceCreate{number?:string;sku_code?:string;quantity:number;sku:SkuRel;origin_stock_location:StockLocationRel;destination_stock_location:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}interface StockTransferUpdate extends ResourceUpdate{number?:string;sku_code?:string;_upcoming?:boolean;_on_hold?:boolean;_picking?:boolean;_in_transit?:boolean;_complete?:boolean;_cancel?:boolean;sku?:SkuRel;origin_stock_location?:StockLocationRel;destination_stock_location?:StockLocationRel;shipment?:ShipmentRel;line_item?:LineItemRel;}declare class StockTransfers extends ApiResource{static readonly TYPE:'stock_transfers';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StockTransfer>>;create(resource:StockTransferCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;update(resource:StockTransferUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockTransfer>;delete(id:string,options?:ResourcesConfig):Promise<void>;sku(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Sku>;origin_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;destination_stock_location(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StockLocation>;shipment(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Shipment>;line_item(stockTransferId:string|StockTransfer,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<LineItem>;events(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Event>>;versions(stockTransferId:string|StockTransfer,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStockTransfer(resource:any):resource is StockTransfer;relationship(id:string|ResourceId|null):StockTransferRel;type():string;}export default StockTransfers;export{StockTransfer,StockTransferCreate,StockTransferUpdate};
|
@@ -1 +1 @@
|
|
1
|
-
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{PaymentGateway}from'./payment_gateways';import type{Version}from'./versions';type StripePaymentRel=ResourceRel&{type:typeof StripePayments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};interface StripePayment extends Resource{stripe_id?:string;client_secret?:string;publishable_key?:string;options?:object;payment_method?:object;mismatched_amounts?:boolean;return_url?:string;receipt_email?:string;payment_instrument?:object;order?:Order;payment_gateway?:PaymentGateway;versions?:Version[];}interface StripePaymentCreate extends ResourceCreate{stripe_id?:string;client_secret?:string;options?:object;return_url?:string;receipt_email?:string;order:OrderRel;}interface StripePaymentUpdate extends ResourceUpdate{options?:object;return_url?:string;_update?:boolean;_refresh?:boolean;order?:OrderRel;}declare class StripePayments extends ApiResource{static readonly TYPE:'stripe_payments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StripePayment>>;create(resource:StripePaymentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;update(resource:StripePaymentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;payment_gateway(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentGateway>;versions(stripePaymentId:string|StripePayment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStripePayment(resource:any):resource is StripePayment;relationship(id:string|ResourceId|null):StripePaymentRel;type():string;}export default StripePayments;export{StripePayment,StripePaymentCreate,StripePaymentUpdate};
|
1
|
+
import{ApiResource,Resource,ResourceCreate,ResourceUpdate,ResourcesConfig,ResourceId,ResourceRel,ListResponse}from'../resource';import type{QueryParamsList,QueryParamsRetrieve}from'../query';import type{Order}from'./orders';import type{PaymentGateway}from'./payment_gateways';import type{Version}from'./versions';type StripePaymentRel=ResourceRel&{type:typeof StripePayments.TYPE;};type OrderRel=ResourceRel&{type:'orders';};interface StripePayment extends Resource{stripe_id?:string;client_secret?:string;charge_id?:string;publishable_key?:string;options?:object;payment_method?:object;mismatched_amounts?:boolean;return_url?:string;receipt_email?:string;payment_instrument?:object;order?:Order;payment_gateway?:PaymentGateway;versions?:Version[];}interface StripePaymentCreate extends ResourceCreate{stripe_id?:string;client_secret?:string;options?:object;return_url?:string;receipt_email?:string;order:OrderRel;}interface StripePaymentUpdate extends ResourceUpdate{options?:object;return_url?:string;_update?:boolean;_refresh?:boolean;order?:OrderRel;}declare class StripePayments extends ApiResource{static readonly TYPE:'stripe_payments';list(params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<StripePayment>>;create(resource:StripePaymentCreate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;retrieve(id:string,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;update(resource:StripePaymentUpdate,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<StripePayment>;delete(id:string,options?:ResourcesConfig):Promise<void>;order(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<Order>;payment_gateway(stripePaymentId:string|StripePayment,params?:QueryParamsRetrieve,options?:ResourcesConfig):Promise<PaymentGateway>;versions(stripePaymentId:string|StripePayment,params?:QueryParamsList,options?:ResourcesConfig):Promise<ListResponse<Version>>;isStripePayment(resource:any):resource is StripePayment;relationship(id:string|ResourceId|null):StripePaymentRel;type():string;}export default StripePayments;export{StripePayment,StripePaymentCreate,StripePaymentUpdate};
|