@commercelayer/sdk 5.0.0-beta.15 → 5.0.0-beta.17
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/LICENSE +1 -1
- package/README.md +1 -0
- package/lib/cjs/client.d.ts +3 -5
- package/lib/cjs/commercelayer.d.ts +2 -2
- package/lib/cjs/commercelayer.js +2 -2
- package/lib/cjs/common.d.ts +1 -3
- package/lib/cjs/index.d.ts +1 -1
- package/lib/cjs/index.js +0 -16
- package/lib/cjs/query.d.ts +5 -13
- package/lib/cjs/resource.d.ts +4 -5
- package/lib/cjs/resources/addresses.d.ts +2 -1
- package/lib/cjs/resources/adjustments.d.ts +2 -1
- package/lib/cjs/resources/adyen_gateways.d.ts +2 -1
- package/lib/cjs/resources/adyen_payments.d.ts +2 -1
- package/lib/cjs/resources/application.d.ts +2 -1
- package/lib/cjs/resources/attachments.d.ts +2 -1
- package/lib/cjs/resources/authorizations.d.ts +2 -1
- package/lib/cjs/resources/avalara_accounts.d.ts +2 -1
- package/lib/cjs/resources/axerve_gateways.d.ts +2 -1
- package/lib/cjs/resources/axerve_payments.d.ts +2 -1
- package/lib/cjs/resources/billing_info_validation_rules.d.ts +2 -1
- package/lib/cjs/resources/bing_geocoders.d.ts +2 -1
- package/lib/cjs/resources/braintree_gateways.d.ts +2 -1
- package/lib/cjs/resources/braintree_payments.d.ts +2 -1
- package/lib/cjs/resources/bundles.d.ts +2 -1
- package/lib/cjs/resources/captures.d.ts +2 -1
- package/lib/cjs/resources/carrier_accounts.d.ts +2 -1
- package/lib/cjs/resources/checkout_com_gateways.d.ts +2 -1
- package/lib/cjs/resources/checkout_com_payments.d.ts +2 -1
- package/lib/cjs/resources/cleanups.d.ts +2 -1
- package/lib/cjs/resources/coupon_codes_promotion_rules.d.ts +2 -1
- package/lib/cjs/resources/coupon_recipients.d.ts +2 -1
- package/lib/cjs/resources/coupons.d.ts +2 -1
- package/lib/cjs/resources/customer_addresses.d.ts +2 -1
- package/lib/cjs/resources/customer_groups.d.ts +2 -1
- package/lib/cjs/resources/customer_password_resets.d.ts +2 -1
- package/lib/cjs/resources/customer_payment_sources.d.ts +2 -1
- package/lib/cjs/resources/customer_subscriptions.d.ts +2 -1
- package/lib/cjs/resources/customers.d.ts +2 -1
- package/lib/cjs/resources/delivery_lead_times.d.ts +2 -1
- package/lib/cjs/resources/event_callbacks.d.ts +2 -1
- package/lib/cjs/resources/events.d.ts +2 -1
- package/lib/cjs/resources/exports.d.ts +2 -1
- package/lib/cjs/resources/external_gateways.d.ts +2 -1
- package/lib/cjs/resources/external_payments.d.ts +2 -1
- package/lib/cjs/resources/external_promotions.d.ts +2 -1
- package/lib/cjs/resources/external_tax_calculators.d.ts +2 -1
- package/lib/cjs/resources/fixed_amount_promotions.d.ts +2 -1
- package/lib/cjs/resources/fixed_price_promotions.d.ts +2 -1
- package/lib/cjs/resources/free_gift_promotions.d.ts +2 -1
- package/lib/cjs/resources/free_shipping_promotions.d.ts +2 -1
- package/lib/cjs/resources/geocoders.d.ts +2 -1
- package/lib/cjs/resources/gift_card_recipients.d.ts +2 -1
- package/lib/cjs/resources/gift_cards.d.ts +2 -1
- package/lib/cjs/resources/google_geocoders.d.ts +2 -1
- package/lib/cjs/resources/imports.d.ts +2 -1
- package/lib/cjs/resources/in_stock_subscriptions.d.ts +2 -1
- package/lib/cjs/resources/inventory_models.d.ts +2 -1
- package/lib/cjs/resources/inventory_return_locations.d.ts +2 -1
- package/lib/cjs/resources/inventory_stock_locations.d.ts +2 -1
- package/lib/cjs/resources/klarna_gateways.d.ts +2 -1
- package/lib/cjs/resources/klarna_payments.d.ts +2 -1
- package/lib/cjs/resources/line_item_options.d.ts +2 -1
- package/lib/cjs/resources/line_items.d.ts +2 -1
- package/lib/cjs/resources/manual_gateways.d.ts +2 -1
- package/lib/cjs/resources/manual_tax_calculators.d.ts +2 -1
- package/lib/cjs/resources/markets.d.ts +2 -1
- package/lib/cjs/resources/merchants.d.ts +2 -1
- package/lib/cjs/resources/order_amount_promotion_rules.d.ts +2 -1
- package/lib/cjs/resources/order_copies.d.ts +2 -1
- package/lib/cjs/resources/order_factories.d.ts +2 -1
- package/lib/cjs/resources/order_subscription_items.d.ts +2 -1
- package/lib/cjs/resources/order_subscriptions.d.ts +2 -1
- package/lib/cjs/resources/order_validation_rules.d.ts +2 -1
- package/lib/cjs/resources/orders.d.ts +2 -1
- package/lib/cjs/resources/organization.d.ts +2 -1
- package/lib/cjs/resources/packages.d.ts +2 -1
- package/lib/cjs/resources/parcel_line_items.d.ts +2 -1
- package/lib/cjs/resources/parcels.d.ts +2 -1
- package/lib/cjs/resources/payment_gateways.d.ts +2 -1
- package/lib/cjs/resources/payment_methods.d.ts +2 -1
- package/lib/cjs/resources/paypal_gateways.d.ts +2 -1
- package/lib/cjs/resources/paypal_payments.d.ts +2 -1
- package/lib/cjs/resources/percentage_discount_promotions.d.ts +2 -1
- package/lib/cjs/resources/price_frequency_tiers.d.ts +2 -1
- package/lib/cjs/resources/price_lists.d.ts +2 -1
- package/lib/cjs/resources/price_tiers.d.ts +2 -1
- package/lib/cjs/resources/price_volume_tiers.d.ts +2 -1
- package/lib/cjs/resources/prices.d.ts +2 -1
- package/lib/cjs/resources/promotion_rules.d.ts +2 -1
- package/lib/cjs/resources/promotions.d.ts +2 -1
- package/lib/cjs/resources/recurring_order_copies.d.ts +2 -1
- package/lib/cjs/resources/refunds.d.ts +2 -1
- package/lib/cjs/resources/return_line_items.d.ts +2 -1
- package/lib/cjs/resources/returns.d.ts +2 -1
- package/lib/cjs/resources/satispay_gateways.d.ts +2 -1
- package/lib/cjs/resources/satispay_payments.d.ts +2 -1
- package/lib/cjs/resources/shipments.d.ts +2 -1
- package/lib/cjs/resources/shipping_categories.d.ts +2 -1
- package/lib/cjs/resources/shipping_method_tiers.d.ts +2 -1
- package/lib/cjs/resources/shipping_methods.d.ts +2 -1
- package/lib/cjs/resources/shipping_weight_tiers.d.ts +2 -1
- package/lib/cjs/resources/shipping_zones.d.ts +2 -1
- package/lib/cjs/resources/sku_list_items.d.ts +2 -1
- package/lib/cjs/resources/sku_list_promotion_rules.d.ts +2 -1
- package/lib/cjs/resources/sku_lists.d.ts +2 -1
- package/lib/cjs/resources/sku_options.d.ts +2 -1
- package/lib/cjs/resources/skus.d.ts +2 -1
- package/lib/cjs/resources/stock_items.d.ts +2 -1
- package/lib/cjs/resources/stock_line_items.d.ts +2 -1
- package/lib/cjs/resources/stock_locations.d.ts +2 -1
- package/lib/cjs/resources/stock_transfers.d.ts +2 -1
- package/lib/cjs/resources/stripe_gateways.d.ts +2 -1
- package/lib/cjs/resources/stripe_payments.d.ts +2 -1
- package/lib/cjs/resources/subscription_models.d.ts +2 -1
- package/lib/cjs/resources/tax_calculators.d.ts +2 -1
- package/lib/cjs/resources/tax_categories.d.ts +2 -1
- package/lib/cjs/resources/tax_rules.d.ts +2 -1
- package/lib/cjs/resources/taxjar_accounts.d.ts +2 -1
- package/lib/cjs/resources/transactions.d.ts +2 -1
- package/lib/cjs/resources/voids.d.ts +2 -1
- package/lib/cjs/resources/webhooks.d.ts +2 -1
- package/lib/cjs/resources/wire_transfers.d.ts +2 -1
- package/lib/esm/client.d.ts +3 -5
- package/lib/esm/commercelayer.d.ts +2 -2
- package/lib/esm/commercelayer.js +2 -2
- package/lib/esm/common.d.ts +1 -3
- package/lib/esm/index.d.ts +1 -1
- package/lib/esm/index.js +0 -2
- package/lib/esm/query.d.ts +5 -13
- package/lib/esm/resource.d.ts +4 -5
- package/lib/esm/resources/addresses.d.ts +2 -1
- package/lib/esm/resources/adjustments.d.ts +2 -1
- package/lib/esm/resources/adyen_gateways.d.ts +2 -1
- package/lib/esm/resources/adyen_payments.d.ts +2 -1
- package/lib/esm/resources/application.d.ts +2 -1
- package/lib/esm/resources/attachments.d.ts +2 -1
- package/lib/esm/resources/authorizations.d.ts +2 -1
- package/lib/esm/resources/avalara_accounts.d.ts +2 -1
- package/lib/esm/resources/axerve_gateways.d.ts +2 -1
- package/lib/esm/resources/axerve_payments.d.ts +2 -1
- package/lib/esm/resources/billing_info_validation_rules.d.ts +2 -1
- package/lib/esm/resources/bing_geocoders.d.ts +2 -1
- package/lib/esm/resources/braintree_gateways.d.ts +2 -1
- package/lib/esm/resources/braintree_payments.d.ts +2 -1
- package/lib/esm/resources/bundles.d.ts +2 -1
- package/lib/esm/resources/captures.d.ts +2 -1
- package/lib/esm/resources/carrier_accounts.d.ts +2 -1
- package/lib/esm/resources/checkout_com_gateways.d.ts +2 -1
- package/lib/esm/resources/checkout_com_payments.d.ts +2 -1
- package/lib/esm/resources/cleanups.d.ts +2 -1
- package/lib/esm/resources/coupon_codes_promotion_rules.d.ts +2 -1
- package/lib/esm/resources/coupon_recipients.d.ts +2 -1
- package/lib/esm/resources/coupons.d.ts +2 -1
- package/lib/esm/resources/customer_addresses.d.ts +2 -1
- package/lib/esm/resources/customer_groups.d.ts +2 -1
- package/lib/esm/resources/customer_password_resets.d.ts +2 -1
- package/lib/esm/resources/customer_payment_sources.d.ts +2 -1
- package/lib/esm/resources/customer_subscriptions.d.ts +2 -1
- package/lib/esm/resources/customers.d.ts +2 -1
- package/lib/esm/resources/delivery_lead_times.d.ts +2 -1
- package/lib/esm/resources/event_callbacks.d.ts +2 -1
- package/lib/esm/resources/events.d.ts +2 -1
- package/lib/esm/resources/exports.d.ts +2 -1
- package/lib/esm/resources/external_gateways.d.ts +2 -1
- package/lib/esm/resources/external_payments.d.ts +2 -1
- package/lib/esm/resources/external_promotions.d.ts +2 -1
- package/lib/esm/resources/external_tax_calculators.d.ts +2 -1
- package/lib/esm/resources/fixed_amount_promotions.d.ts +2 -1
- package/lib/esm/resources/fixed_price_promotions.d.ts +2 -1
- package/lib/esm/resources/free_gift_promotions.d.ts +2 -1
- package/lib/esm/resources/free_shipping_promotions.d.ts +2 -1
- package/lib/esm/resources/geocoders.d.ts +2 -1
- package/lib/esm/resources/gift_card_recipients.d.ts +2 -1
- package/lib/esm/resources/gift_cards.d.ts +2 -1
- package/lib/esm/resources/google_geocoders.d.ts +2 -1
- package/lib/esm/resources/imports.d.ts +2 -1
- package/lib/esm/resources/in_stock_subscriptions.d.ts +2 -1
- package/lib/esm/resources/inventory_models.d.ts +2 -1
- package/lib/esm/resources/inventory_return_locations.d.ts +2 -1
- package/lib/esm/resources/inventory_stock_locations.d.ts +2 -1
- package/lib/esm/resources/klarna_gateways.d.ts +2 -1
- package/lib/esm/resources/klarna_payments.d.ts +2 -1
- package/lib/esm/resources/line_item_options.d.ts +2 -1
- package/lib/esm/resources/line_items.d.ts +2 -1
- package/lib/esm/resources/manual_gateways.d.ts +2 -1
- package/lib/esm/resources/manual_tax_calculators.d.ts +2 -1
- package/lib/esm/resources/markets.d.ts +2 -1
- package/lib/esm/resources/merchants.d.ts +2 -1
- package/lib/esm/resources/order_amount_promotion_rules.d.ts +2 -1
- package/lib/esm/resources/order_copies.d.ts +2 -1
- package/lib/esm/resources/order_factories.d.ts +2 -1
- package/lib/esm/resources/order_subscription_items.d.ts +2 -1
- package/lib/esm/resources/order_subscriptions.d.ts +2 -1
- package/lib/esm/resources/order_validation_rules.d.ts +2 -1
- package/lib/esm/resources/orders.d.ts +2 -1
- package/lib/esm/resources/organization.d.ts +2 -1
- package/lib/esm/resources/packages.d.ts +2 -1
- package/lib/esm/resources/parcel_line_items.d.ts +2 -1
- package/lib/esm/resources/parcels.d.ts +2 -1
- package/lib/esm/resources/payment_gateways.d.ts +2 -1
- package/lib/esm/resources/payment_methods.d.ts +2 -1
- package/lib/esm/resources/paypal_gateways.d.ts +2 -1
- package/lib/esm/resources/paypal_payments.d.ts +2 -1
- package/lib/esm/resources/percentage_discount_promotions.d.ts +2 -1
- package/lib/esm/resources/price_frequency_tiers.d.ts +2 -1
- package/lib/esm/resources/price_lists.d.ts +2 -1
- package/lib/esm/resources/price_tiers.d.ts +2 -1
- package/lib/esm/resources/price_volume_tiers.d.ts +2 -1
- package/lib/esm/resources/prices.d.ts +2 -1
- package/lib/esm/resources/promotion_rules.d.ts +2 -1
- package/lib/esm/resources/promotions.d.ts +2 -1
- package/lib/esm/resources/recurring_order_copies.d.ts +2 -1
- package/lib/esm/resources/refunds.d.ts +2 -1
- package/lib/esm/resources/return_line_items.d.ts +2 -1
- package/lib/esm/resources/returns.d.ts +2 -1
- package/lib/esm/resources/satispay_gateways.d.ts +2 -1
- package/lib/esm/resources/satispay_payments.d.ts +2 -1
- package/lib/esm/resources/shipments.d.ts +2 -1
- package/lib/esm/resources/shipping_categories.d.ts +2 -1
- package/lib/esm/resources/shipping_method_tiers.d.ts +2 -1
- package/lib/esm/resources/shipping_methods.d.ts +2 -1
- package/lib/esm/resources/shipping_weight_tiers.d.ts +2 -1
- package/lib/esm/resources/shipping_zones.d.ts +2 -1
- package/lib/esm/resources/sku_list_items.d.ts +2 -1
- package/lib/esm/resources/sku_list_promotion_rules.d.ts +2 -1
- package/lib/esm/resources/sku_lists.d.ts +2 -1
- package/lib/esm/resources/sku_options.d.ts +2 -1
- package/lib/esm/resources/skus.d.ts +2 -1
- package/lib/esm/resources/stock_items.d.ts +2 -1
- package/lib/esm/resources/stock_line_items.d.ts +2 -1
- package/lib/esm/resources/stock_locations.d.ts +2 -1
- package/lib/esm/resources/stock_transfers.d.ts +2 -1
- package/lib/esm/resources/stripe_gateways.d.ts +2 -1
- package/lib/esm/resources/stripe_payments.d.ts +2 -1
- package/lib/esm/resources/subscription_models.d.ts +2 -1
- package/lib/esm/resources/tax_calculators.d.ts +2 -1
- package/lib/esm/resources/tax_categories.d.ts +2 -1
- package/lib/esm/resources/tax_rules.d.ts +2 -1
- package/lib/esm/resources/taxjar_accounts.d.ts +2 -1
- package/lib/esm/resources/transactions.d.ts +2 -1
- package/lib/esm/resources/voids.d.ts +2 -1
- package/lib/esm/resources/webhooks.d.ts +2 -1
- package/lib/esm/resources/wire_transfers.d.ts +2 -1
- package/lib/tsconfig.esm.tsbuildinfo +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +5 -5
package/LICENSE
CHANGED
package/README.md
CHANGED
@@ -6,6 +6,7 @@
|
|
6
6
|
[](https://github.com/semantic-release/semantic-release)
|
7
7
|
[](https://github.com/commercelayer/commercelayer-sdk/actions/workflows/semantic-release.yml)
|
8
8
|
[](https://github.com/commercelayer/commercelayer-cli/actions/workflows/codeql-analysis.yml)
|
9
|
+
[](https://www.typescriptlang.org/)
|
9
10
|
|
10
11
|
A JavaScript Library wrapper that makes it quick and easy to interact with the [Commerce Layer API](https://docs.commercelayer.io/developers).
|
11
12
|
|
package/lib/cjs/client.d.ts
CHANGED
@@ -1,15 +1,13 @@
|
|
1
1
|
/// <reference types="node" />
|
2
2
|
/// <reference types="node" />
|
3
|
-
import { AxiosProxyConfig, Method } from 'axios';
|
3
|
+
import { type AxiosProxyConfig, type Method } from 'axios';
|
4
4
|
import type { InterceptorManager } from './interceptor';
|
5
5
|
import type { Agent as HttpAgent } from 'http';
|
6
6
|
import type { Agent as HttpsAgent } from 'https';
|
7
7
|
type ProxyConfig = AxiosProxyConfig | false;
|
8
8
|
type RequestConfig = {
|
9
9
|
timeout?: number;
|
10
|
-
params?:
|
11
|
-
[key: string]: string | number | boolean;
|
12
|
-
};
|
10
|
+
params?: Record<string, string | number | boolean>;
|
13
11
|
httpAgent?: HttpAgent;
|
14
12
|
httpsAgent?: HttpsAgent;
|
15
13
|
proxy?: ProxyConfig;
|
@@ -30,4 +28,4 @@ declare class ApiClient {
|
|
30
28
|
request(method: Method, path: string, body?: any, options?: ApiClientConfig): Promise<any>;
|
31
29
|
}
|
32
30
|
export default ApiClient;
|
33
|
-
export { ApiClientInitConfig, ApiClientConfig, RequestConfig };
|
31
|
+
export type { ApiClientInitConfig, ApiClientConfig, RequestConfig };
|
@@ -1,10 +1,10 @@
|
|
1
1
|
import * as api from './api';
|
2
2
|
import type { ApiError } from './error';
|
3
3
|
import type { ErrorInterceptor, InterceptorType, RawResponseReader, RequestInterceptor, ResponseInterceptor } from './interceptor';
|
4
|
-
import type
|
4
|
+
import { type ResourcesInitConfig } from './resource';
|
5
5
|
declare const OPEN_API_SCHEMA_VERSION = "4.1.3";
|
6
6
|
export { OPEN_API_SCHEMA_VERSION };
|
7
|
-
type SdkConfig =
|
7
|
+
type SdkConfig = Record<string, unknown>;
|
8
8
|
type CommerceLayerInitConfig = SdkConfig & ResourcesInitConfig;
|
9
9
|
type CommerceLayerConfig = Partial<CommerceLayerInitConfig>;
|
10
10
|
declare class CommerceLayerClient {
|
package/lib/cjs/commercelayer.js
CHANGED
@@ -203,7 +203,7 @@ class CommerceLayerClient {
|
|
203
203
|
return __classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f").interceptors.response.use(onFulfilled, onRejected);
|
204
204
|
}
|
205
205
|
removeInterceptor(type, id) {
|
206
|
-
|
206
|
+
__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f").interceptors[type].eject(id);
|
207
207
|
}
|
208
208
|
addRawResponseReader(options) {
|
209
209
|
const reader = {
|
@@ -224,7 +224,7 @@ class CommerceLayerClient {
|
|
224
224
|
removeRawResponseReader(reader) {
|
225
225
|
const id = (typeof reader === 'number') ? reader : reader === null || reader === void 0 ? void 0 : reader.id;
|
226
226
|
if (id && (id >= 0))
|
227
|
-
|
227
|
+
this.removeInterceptor('response', id);
|
228
228
|
}
|
229
229
|
}
|
230
230
|
_CommerceLayerClient_adapter = new WeakMap(), _CommerceLayerClient_organization = new WeakMap();
|
package/lib/cjs/common.d.ts
CHANGED
@@ -2,6 +2,4 @@ import type { ResourceId, ResourceType } from './resource';
|
|
2
2
|
declare const isResourceId: (resource: any) => resource is ResourceId;
|
3
3
|
declare const isResourceType: (resource: any) => resource is ResourceType;
|
4
4
|
export { isResourceId, isResourceType };
|
5
|
-
export type ObjectType =
|
6
|
-
[key: string]: any;
|
7
|
-
};
|
5
|
+
export type ObjectType = Record<string, any>;
|
package/lib/cjs/index.d.ts
CHANGED
@@ -2,6 +2,6 @@ export { default, CommerceLayer } from './commercelayer';
|
|
2
2
|
export type { CommerceLayerClient } from './commercelayer';
|
3
3
|
export { CommerceLayerStatic } from './static';
|
4
4
|
export type { QueryParamsRetrieve, QueryParamsList, QueryParams } from './query';
|
5
|
-
export * from './model';
|
5
|
+
export type * from './model';
|
6
6
|
export type { RequestObj, ResponseObj, ErrorObj, HeadersObj } from './interceptor';
|
7
7
|
export type { SdkError, ApiError, ErrorType } from './error';
|
package/lib/cjs/index.js
CHANGED
@@ -1,18 +1,4 @@
|
|
1
1
|
"use strict";
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
-
if (k2 === undefined) k2 = k;
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
-
}
|
8
|
-
Object.defineProperty(o, k2, desc);
|
9
|
-
}) : (function(o, m, k, k2) {
|
10
|
-
if (k2 === undefined) k2 = k;
|
11
|
-
o[k2] = m[k];
|
12
|
-
}));
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
|
-
};
|
16
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
17
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
18
4
|
};
|
@@ -25,5 +11,3 @@ Object.defineProperty(exports, "CommerceLayer", { enumerable: true, get: functio
|
|
25
11
|
// Commerce Layer static functions
|
26
12
|
var static_1 = require("./static");
|
27
13
|
Object.defineProperty(exports, "CommerceLayerStatic", { enumerable: true, get: function () { return static_1.CommerceLayerStatic; } });
|
28
|
-
// Resource model types
|
29
|
-
__exportStar(require("./model"), exports);
|
package/lib/cjs/query.d.ts
CHANGED
@@ -1,25 +1,17 @@
|
|
1
1
|
import type { ResourceType } from "./resource";
|
2
|
-
type QueryFilter =
|
3
|
-
[key: string]: string | number | boolean;
|
4
|
-
};
|
2
|
+
type QueryFilter = Record<string, string | number | boolean>;
|
5
3
|
interface QueryParamsRetrieve {
|
6
4
|
include?: string[];
|
7
|
-
fields?: string[] |
|
8
|
-
[key: string]: string[];
|
9
|
-
};
|
5
|
+
fields?: string[] | Record<string, string[]>;
|
10
6
|
}
|
11
7
|
interface QueryParamsList extends QueryParamsRetrieve {
|
12
|
-
sort?: string[] |
|
13
|
-
[key: string]: 'asc' | 'desc';
|
14
|
-
};
|
8
|
+
sort?: string[] | Record<string, 'asc' | 'desc'>;
|
15
9
|
filters?: QueryFilter;
|
16
10
|
pageNumber?: number;
|
17
11
|
pageSize?: number;
|
18
12
|
}
|
19
13
|
type QueryParams = QueryParamsRetrieve | QueryParamsList;
|
20
|
-
export { QueryParamsRetrieve, QueryParamsList, QueryParams, QueryFilter };
|
14
|
+
export type { QueryParamsRetrieve, QueryParamsList, QueryParams, QueryFilter };
|
21
15
|
declare const isParamsList: (params: any) => params is QueryParamsList;
|
22
|
-
declare const generateQueryStringParams: (params: QueryParamsRetrieve | QueryParamsList | undefined, res: string | ResourceType) =>
|
23
|
-
[key: string]: string;
|
24
|
-
};
|
16
|
+
declare const generateQueryStringParams: (params: QueryParamsRetrieve | QueryParamsList | undefined, res: string | ResourceType) => Record<string, string>;
|
25
17
|
export { generateQueryStringParams, isParamsList };
|
package/lib/cjs/resource.d.ts
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import type
|
1
|
+
import { type ApiClientInitConfig } from './client';
|
2
2
|
import type { QueryParamsRetrieve, QueryParamsList, QueryFilter, QueryParams } from './query';
|
3
3
|
import type { ResourceTypeLock } from './api';
|
4
4
|
import type { InterceptorManager } from './interceptor';
|
@@ -6,9 +6,7 @@ type ResourceNull = {
|
|
6
6
|
id: null;
|
7
7
|
} & ResourceType;
|
8
8
|
type ResourceRel = ResourceId | ResourceNull;
|
9
|
-
type Metadata =
|
10
|
-
[key: string]: any;
|
11
|
-
};
|
9
|
+
type Metadata = Record<string, any>;
|
12
10
|
interface ResourceType {
|
13
11
|
readonly type: ResourceTypeLock;
|
14
12
|
}
|
@@ -83,4 +81,5 @@ declare abstract class ApiSingleton<R extends Resource> extends ApiResourceBase<
|
|
83
81
|
retrieve(params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<R>;
|
84
82
|
}
|
85
83
|
export default ResourceAdapter;
|
86
|
-
export { ApiResource, ApiSingleton
|
84
|
+
export { ApiResource, ApiSingleton };
|
85
|
+
export type { ResourcesConfig, ResourcesInitConfig };
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Geocoder, GeocoderType } from './geocoders';
|
4
5
|
type AddressType = 'addresses';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
type AdjustmentType = 'adjustments';
|
4
5
|
type AdjustmentRel = ResourceRel & {
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { PaymentMethod } from './payment_methods';
|
4
5
|
import type { AdyenPayment, AdyenPaymentType } from './adyen_payments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Order, OrderType } from './orders';
|
4
5
|
import type { PaymentGateway } from './payment_gateways';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiSingleton
|
1
|
+
import { ApiSingleton } from '../resource';
|
2
|
+
import type { Resource, ResourceId, ResourceRel } from '../resource';
|
2
3
|
type ApplicationType = 'application';
|
3
4
|
type ApplicationRel = ResourceRel & {
|
4
5
|
type: ApplicationType;
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Bundle, BundleType } from './bundles';
|
4
5
|
import type { CarrierAccount, CarrierAccountType } from './carrier_accounts';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Order } from './orders';
|
4
5
|
import type { Capture } from './captures';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market } from './markets';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { PaymentMethod } from './payment_methods';
|
4
5
|
import type { AxervePayment, AxervePaymentType } from './axerve_payments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Order, OrderType } from './orders';
|
4
5
|
import type { PaymentGateway } from './payment_gateways';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Address } from './addresses';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { PaymentMethod } from './payment_methods';
|
4
5
|
import type { BraintreePayment, BraintreePaymentType } from './braintree_payments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Order, OrderType } from './orders';
|
4
5
|
import type { PaymentGateway } from './payment_gateways';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { SkuList, SkuListType } from './sku_lists';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Order } from './orders';
|
4
5
|
import type { Authorization } from './authorizations';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market } from './markets';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { PaymentMethod } from './payment_methods';
|
4
5
|
import type { CheckoutComPayment, CheckoutComPaymentType } from './checkout_com_payments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Order, OrderType } from './orders';
|
4
5
|
import type { PaymentGateway } from './payment_gateways';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Event } from './events';
|
4
5
|
type CleanupType = 'cleanups';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { PercentageDiscountPromotion, PercentageDiscountPromotionType } from './percentage_discount_promotions';
|
4
5
|
import type { FreeShippingPromotion, FreeShippingPromotionType } from './free_shipping_promotions';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Customer, CustomerType } from './customers';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { CouponCodesPromotionRule, CouponCodesPromotionRuleType } from './coupon_codes_promotion_rules';
|
4
5
|
type CouponType = 'coupons';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Customer, CustomerType } from './customers';
|
4
5
|
import type { Address, AddressType } from './addresses';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Customer } from './customers';
|
4
5
|
import type { Market } from './markets';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Customer } from './customers';
|
4
5
|
import type { Event } from './events';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Customer, CustomerType } from './customers';
|
4
5
|
import type { AdyenPayment, AdyenPaymentType } from './adyen_payments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Customer } from './customers';
|
4
5
|
import type { Event } from './events';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { CustomerGroup, CustomerGroupType } from './customer_groups';
|
4
5
|
import type { CustomerAddress } from './customer_addresses';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { StockLocation, StockLocationType } from './stock_locations';
|
4
5
|
import type { ShippingMethod, ShippingMethodType } from './shipping_methods';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Webhook } from './webhooks';
|
4
5
|
type EventCallbackType = 'event_callbacks';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsList } from '../query';
|
3
4
|
import type { EventCallback } from './event_callbacks';
|
4
5
|
import type { Webhook } from './webhooks';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Event } from './events';
|
4
5
|
type ExportType = 'exports';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { PaymentMethod } from './payment_methods';
|
4
5
|
import type { ExternalPayment } from './external_payments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { Order, OrderType } from './orders';
|
4
5
|
import type { PaymentGateway } from './payment_gateways';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { PromotionRule, PromotionRuleType } from './promotion_rules';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market } from './markets';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { PromotionRule, PromotionRuleType } from './promotion_rules';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { PromotionRule, PromotionRuleType } from './promotion_rules';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { PromotionRule, PromotionRuleType } from './promotion_rules';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { PromotionRule, PromotionRuleType } from './promotion_rules';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsList } from '../query';
|
3
4
|
import type { Address } from './addresses';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Customer, CustomerType } from './customers';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { GiftCardRecipient, GiftCardRecipientType } from './gift_card_recipients';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Address } from './addresses';
|
4
5
|
import type { Attachment } from './attachments';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Event } from './events';
|
4
5
|
type ImportType = 'imports';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { Market, MarketType } from './markets';
|
4
5
|
import type { Customer, CustomerType } from './customers';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel, ListResponse } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve, QueryParamsList } from '../query';
|
3
4
|
import type { InventoryStockLocation } from './inventory_stock_locations';
|
4
5
|
import type { InventoryReturnLocation } from './inventory_return_locations';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { StockLocation, StockLocationType } from './stock_locations';
|
4
5
|
import type { InventoryModel, InventoryModelType } from './inventory_models';
|
@@ -1,4 +1,5 @@
|
|
1
|
-
import { ApiResource
|
1
|
+
import { ApiResource } from '../resource';
|
2
|
+
import type { Resource, ResourceCreate, ResourceUpdate, ResourceId, ResourcesConfig, ResourceRel } from '../resource';
|
2
3
|
import type { QueryParamsRetrieve } from '../query';
|
3
4
|
import type { StockLocation, StockLocationType } from './stock_locations';
|
4
5
|
import type { InventoryModel, InventoryModelType } from './inventory_models';
|