@commercelayer/sdk 4.25.0 → 4.26.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/api.d.ts +4 -2
- package/lib/cjs/api.js +8 -2
- package/lib/cjs/commercelayer.d.ts +4 -2
- package/lib/cjs/commercelayer.js +3 -1
- package/lib/cjs/model.d.ts +2 -0
- package/lib/cjs/resources/axerve_payments.d.ts +1 -0
- package/lib/cjs/resources/customer_payment_sources.d.ts +7 -3
- package/lib/cjs/resources/orders.d.ts +7 -3
- package/lib/cjs/resources/satispay_gateways.d.ts +39 -0
- package/lib/cjs/resources/satispay_gateways.js +41 -0
- package/lib/cjs/resources/satispay_payments.d.ts +43 -0
- package/lib/cjs/resources/satispay_payments.js +41 -0
- package/lib/esm/api.d.ts +4 -2
- package/lib/esm/api.js +4 -0
- package/lib/esm/commercelayer.d.ts +4 -2
- package/lib/esm/commercelayer.js +3 -1
- package/lib/esm/model.d.ts +2 -0
- package/lib/esm/resources/axerve_payments.d.ts +1 -0
- package/lib/esm/resources/customer_payment_sources.d.ts +7 -3
- package/lib/esm/resources/orders.d.ts +7 -3
- package/lib/esm/resources/satispay_gateways.d.ts +39 -0
- package/lib/esm/resources/satispay_gateways.js +39 -0
- package/lib/esm/resources/satispay_payments.d.ts +43 -0
- package/lib/esm/resources/satispay_payments.js +39 -0
- package/lib/tsconfig.esm.tsbuildinfo +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +7 -7
package/lib/cjs/api.d.ts
CHANGED
@@ -82,6 +82,8 @@ export { default as Promotions } from './resources/promotions';
|
|
82
82
|
export { default as Refunds } from './resources/refunds';
|
83
83
|
export { default as ReturnLineItems } from './resources/return_line_items';
|
84
84
|
export { default as Returns } from './resources/returns';
|
85
|
+
export { default as SatispayGateways } from './resources/satispay_gateways';
|
86
|
+
export { default as SatispayPayments } from './resources/satispay_payments';
|
85
87
|
export { default as Shipments } from './resources/shipments';
|
86
88
|
export { default as ShippingCategories } from './resources/shipping_categories';
|
87
89
|
export { default as ShippingMethodTiers } from './resources/shipping_method_tiers';
|
@@ -107,5 +109,5 @@ export { default as Transactions } from './resources/transactions';
|
|
107
109
|
export { default as Voids } from './resources/voids';
|
108
110
|
export { default as Webhooks } from './resources/webhooks';
|
109
111
|
export { default as WireTransfers } from './resources/wire_transfers';
|
110
|
-
export type ResourceTypeLock = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'application' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'captures' | 'carrier_accounts' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'event_callbacks' | 'events' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'geocoders' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscriptions' | 'order_validation_rules' | 'orders' | 'organization' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_gateways' | 'payment_methods' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_lists' | 'price_tiers' | 'price_volume_tiers' | 'prices' | 'promotion_rules' | 'promotions' | 'refunds' | 'return_line_items' | 'returns' | 'shipments' | 'shipping_categories' | 'shipping_method_tiers' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'tax_calculators' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'transactions' | 'voids' | 'webhooks' | 'wire_transfers';
|
111
|
-
export declare const resourceList: readonly ["addresses", "adjustments", "adyen_gateways", "adyen_payments", "application", "attachments", "authorizations", "avalara_accounts", "axerve_gateways", "axerve_payments", "billing_info_validation_rules", "bing_geocoders", "braintree_gateways", "braintree_payments", "bundles", "captures", "carrier_accounts", "checkout_com_gateways", "checkout_com_payments", "cleanups", "coupon_codes_promotion_rules", "coupon_recipients", "coupons", "customer_addresses", "customer_groups", "customer_password_resets", "customer_payment_sources", "customer_subscriptions", "customers", "delivery_lead_times", "event_callbacks", "events", "exports", "external_gateways", "external_payments", "external_promotions", "external_tax_calculators", "fixed_amount_promotions", "fixed_price_promotions", "free_gift_promotions", "free_shipping_promotions", "geocoders", "gift_card_recipients", "gift_cards", "google_geocoders", "imports", "in_stock_subscriptions", "inventory_models", "inventory_return_locations", "inventory_stock_locations", "klarna_gateways", "klarna_payments", "line_item_options", "line_items", "manual_gateways", "manual_tax_calculators", "markets", "merchants", "order_amount_promotion_rules", "order_copies", "order_subscriptions", "order_validation_rules", "orders", "organization", "packages", "parcel_line_items", "parcels", "payment_gateways", "payment_methods", "paypal_gateways", "paypal_payments", "percentage_discount_promotions", "price_lists", "price_tiers", "price_volume_tiers", "prices", "promotion_rules", "promotions", "refunds", "return_line_items", "returns", "shipments", "shipping_categories", "shipping_method_tiers", "shipping_methods", "shipping_weight_tiers", "shipping_zones", "sku_list_items", "sku_list_promotion_rules", "sku_lists", "sku_options", "skus", "stock_items", "stock_line_items", "stock_locations", "stock_transfers", "stripe_gateways", "stripe_payments", "tax_calculators", "tax_categories", "tax_rules", "taxjar_accounts", "transactions", "voids", "webhooks", "wire_transfers"];
|
112
|
+
export type ResourceTypeLock = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'application' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'captures' | 'carrier_accounts' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'event_callbacks' | 'events' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'geocoders' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscriptions' | 'order_validation_rules' | 'orders' | 'organization' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_gateways' | 'payment_methods' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_lists' | 'price_tiers' | 'price_volume_tiers' | 'prices' | 'promotion_rules' | 'promotions' | 'refunds' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_method_tiers' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'tax_calculators' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'transactions' | 'voids' | 'webhooks' | 'wire_transfers';
|
113
|
+
export declare const resourceList: readonly ["addresses", "adjustments", "adyen_gateways", "adyen_payments", "application", "attachments", "authorizations", "avalara_accounts", "axerve_gateways", "axerve_payments", "billing_info_validation_rules", "bing_geocoders", "braintree_gateways", "braintree_payments", "bundles", "captures", "carrier_accounts", "checkout_com_gateways", "checkout_com_payments", "cleanups", "coupon_codes_promotion_rules", "coupon_recipients", "coupons", "customer_addresses", "customer_groups", "customer_password_resets", "customer_payment_sources", "customer_subscriptions", "customers", "delivery_lead_times", "event_callbacks", "events", "exports", "external_gateways", "external_payments", "external_promotions", "external_tax_calculators", "fixed_amount_promotions", "fixed_price_promotions", "free_gift_promotions", "free_shipping_promotions", "geocoders", "gift_card_recipients", "gift_cards", "google_geocoders", "imports", "in_stock_subscriptions", "inventory_models", "inventory_return_locations", "inventory_stock_locations", "klarna_gateways", "klarna_payments", "line_item_options", "line_items", "manual_gateways", "manual_tax_calculators", "markets", "merchants", "order_amount_promotion_rules", "order_copies", "order_subscriptions", "order_validation_rules", "orders", "organization", "packages", "parcel_line_items", "parcels", "payment_gateways", "payment_methods", "paypal_gateways", "paypal_payments", "percentage_discount_promotions", "price_lists", "price_tiers", "price_volume_tiers", "prices", "promotion_rules", "promotions", "refunds", "return_line_items", "returns", "satispay_gateways", "satispay_payments", "shipments", "shipping_categories", "shipping_method_tiers", "shipping_methods", "shipping_weight_tiers", "shipping_zones", "sku_list_items", "sku_list_promotion_rules", "sku_lists", "sku_options", "skus", "stock_items", "stock_line_items", "stock_locations", "stock_transfers", "stripe_gateways", "stripe_payments", "tax_calculators", "tax_categories", "tax_rules", "taxjar_accounts", "transactions", "voids", "webhooks", "wire_transfers"];
|
package/lib/cjs/api.js
CHANGED
@@ -4,8 +4,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
6
|
exports.InventoryStockLocations = exports.InventoryReturnLocations = exports.InventoryModels = exports.InStockSubscriptions = exports.Imports = exports.GoogleGeocoders = exports.GiftCards = exports.GiftCardRecipients = exports.Geocoders = exports.FreeShippingPromotions = exports.FreeGiftPromotions = exports.FixedPricePromotions = exports.FixedAmountPromotions = exports.ExternalTaxCalculators = exports.ExternalPromotions = exports.ExternalPayments = exports.ExternalGateways = exports.Exports = exports.Events = exports.EventCallbacks = exports.DeliveryLeadTimes = exports.Customers = exports.CustomerSubscriptions = exports.CustomerPaymentSources = exports.CustomerPasswordResets = exports.CustomerGroups = exports.CustomerAddresses = exports.Coupons = exports.CouponRecipients = exports.CouponCodesPromotionRules = exports.Cleanups = exports.CheckoutComPayments = exports.CheckoutComGateways = exports.CarrierAccounts = exports.Captures = exports.Bundles = exports.BraintreePayments = exports.BraintreeGateways = exports.BingGeocoders = exports.BillingInfoValidationRules = exports.AxervePayments = exports.AxerveGateways = exports.AvalaraAccounts = exports.Authorizations = exports.Attachments = exports.Applications = exports.AdyenPayments = exports.AdyenGateways = exports.Adjustments = exports.Addresses = void 0;
|
7
|
-
exports.
|
8
|
-
exports.resourceList = exports.WireTransfers = exports.Webhooks = exports.Voids = exports.Transactions = exports.TaxjarAccounts = exports.TaxRules = void 0;
|
7
|
+
exports.StripePayments = exports.StripeGateways = exports.StockTransfers = exports.StockLocations = exports.StockLineItems = exports.StockItems = exports.Skus = exports.SkuOptions = exports.SkuLists = exports.SkuListPromotionRules = exports.SkuListItems = exports.ShippingZones = exports.ShippingWeightTiers = exports.ShippingMethods = exports.ShippingMethodTiers = exports.ShippingCategories = exports.Shipments = exports.SatispayPayments = exports.SatispayGateways = exports.Returns = exports.ReturnLineItems = exports.Refunds = exports.Promotions = exports.PromotionRules = exports.Prices = exports.PriceVolumeTiers = exports.PriceTiers = exports.PriceLists = exports.PercentageDiscountPromotions = exports.PaypalPayments = exports.PaypalGateways = exports.PaymentMethods = exports.PaymentGateways = exports.Parcels = exports.ParcelLineItems = exports.Packages = exports.Organizations = exports.Orders = exports.OrderValidationRules = exports.OrderSubscriptions = exports.OrderCopies = exports.OrderAmountPromotionRules = exports.Merchants = exports.Markets = exports.ManualTaxCalculators = exports.ManualGateways = exports.LineItems = exports.LineItemOptions = exports.KlarnaPayments = exports.KlarnaGateways = void 0;
|
8
|
+
exports.resourceList = exports.WireTransfers = exports.Webhooks = exports.Voids = exports.Transactions = exports.TaxjarAccounts = exports.TaxRules = exports.TaxCategories = exports.TaxCalculators = void 0;
|
9
9
|
// ##__API_RESOURCES_START__##
|
10
10
|
// ##__API_RESOURCES_TEMPLATE:: export { default as ##__RESOURCE_CLASS__## } from './resources/##__RESOURCE_TYPE__##'
|
11
11
|
/**
|
@@ -173,6 +173,10 @@ var return_line_items_1 = require("./resources/return_line_items");
|
|
173
173
|
Object.defineProperty(exports, "ReturnLineItems", { enumerable: true, get: function () { return __importDefault(return_line_items_1).default; } });
|
174
174
|
var returns_1 = require("./resources/returns");
|
175
175
|
Object.defineProperty(exports, "Returns", { enumerable: true, get: function () { return __importDefault(returns_1).default; } });
|
176
|
+
var satispay_gateways_1 = require("./resources/satispay_gateways");
|
177
|
+
Object.defineProperty(exports, "SatispayGateways", { enumerable: true, get: function () { return __importDefault(satispay_gateways_1).default; } });
|
178
|
+
var satispay_payments_1 = require("./resources/satispay_payments");
|
179
|
+
Object.defineProperty(exports, "SatispayPayments", { enumerable: true, get: function () { return __importDefault(satispay_payments_1).default; } });
|
176
180
|
var shipments_1 = require("./resources/shipments");
|
177
181
|
Object.defineProperty(exports, "Shipments", { enumerable: true, get: function () { return __importDefault(shipments_1).default; } });
|
178
182
|
var shipping_categories_1 = require("./resources/shipping_categories");
|
@@ -307,6 +311,8 @@ exports.resourceList = [
|
|
307
311
|
'refunds',
|
308
312
|
'return_line_items',
|
309
313
|
'returns',
|
314
|
+
'satispay_gateways',
|
315
|
+
'satispay_payments',
|
310
316
|
'shipments',
|
311
317
|
'shipping_categories',
|
312
318
|
'shipping_method_tiers',
|
@@ -2,7 +2,7 @@ import * as api from './api';
|
|
2
2
|
import { ApiError } from './error';
|
3
3
|
import type { ErrorInterceptor, InterceptorType, RawResponseReader, RequestInterceptor, ResponseInterceptor } from './interceptor';
|
4
4
|
import { ResourcesInitConfig } from './resource';
|
5
|
-
declare const OPEN_API_SCHEMA_VERSION = "
|
5
|
+
declare const OPEN_API_SCHEMA_VERSION = "4.0.1";
|
6
6
|
export { OPEN_API_SCHEMA_VERSION };
|
7
7
|
type SdkConfig = {};
|
8
8
|
type CommerceLayerInitConfig = SdkConfig & ResourcesInitConfig;
|
@@ -10,7 +10,7 @@ type CommerceLayerConfig = Partial<CommerceLayerInitConfig>;
|
|
10
10
|
declare class CommerceLayerClient {
|
11
11
|
#private;
|
12
12
|
static get openApiSchemaVersion(): string;
|
13
|
-
readonly openApiSchemaVersion = "
|
13
|
+
readonly openApiSchemaVersion = "4.0.1";
|
14
14
|
addresses: api.Addresses;
|
15
15
|
adjustments: api.Adjustments;
|
16
16
|
adyen_gateways: api.AdyenGateways;
|
@@ -92,6 +92,8 @@ declare class CommerceLayerClient {
|
|
92
92
|
refunds: api.Refunds;
|
93
93
|
return_line_items: api.ReturnLineItems;
|
94
94
|
returns: api.Returns;
|
95
|
+
satispay_gateways: api.SatispayGateways;
|
96
|
+
satispay_payments: api.SatispayPayments;
|
95
97
|
shipments: api.Shipments;
|
96
98
|
shipping_categories: api.ShippingCategories;
|
97
99
|
shipping_method_tiers: api.ShippingMethodTiers;
|
package/lib/cjs/commercelayer.js
CHANGED
@@ -45,7 +45,7 @@ const resource_1 = __importDefault(require("./resource"));
|
|
45
45
|
const debug_1 = __importDefault(require("./debug"));
|
46
46
|
const debug = (0, debug_1.default)('commercelayer');
|
47
47
|
// Autogenerated schema version number, do not remove this line
|
48
|
-
const OPEN_API_SCHEMA_VERSION = '
|
48
|
+
const OPEN_API_SCHEMA_VERSION = '4.0.1';
|
49
49
|
exports.OPEN_API_SCHEMA_VERSION = OPEN_API_SCHEMA_VERSION;
|
50
50
|
class CommerceLayerClient {
|
51
51
|
static get openApiSchemaVersion() { return OPEN_API_SCHEMA_VERSION; }
|
@@ -140,6 +140,8 @@ class CommerceLayerClient {
|
|
140
140
|
this.refunds = new api.Refunds(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
141
141
|
this.return_line_items = new api.ReturnLineItems(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
142
142
|
this.returns = new api.Returns(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
143
|
+
this.satispay_gateways = new api.SatispayGateways(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
144
|
+
this.satispay_payments = new api.SatispayPayments(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
143
145
|
this.shipments = new api.Shipments(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
144
146
|
this.shipping_categories = new api.ShippingCategories(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
145
147
|
this.shipping_method_tiers = new api.ShippingMethodTiers(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
package/lib/cjs/model.d.ts
CHANGED
@@ -82,6 +82,8 @@ export type { Promotion } from './resources/promotions';
|
|
82
82
|
export type { Refund } from './resources/refunds';
|
83
83
|
export type { ReturnLineItem, ReturnLineItemCreate, ReturnLineItemUpdate } from './resources/return_line_items';
|
84
84
|
export type { Return, ReturnCreate, ReturnUpdate } from './resources/returns';
|
85
|
+
export type { SatispayGateway, SatispayGatewayCreate, SatispayGatewayUpdate } from './resources/satispay_gateways';
|
86
|
+
export type { SatispayPayment, SatispayPaymentCreate, SatispayPaymentUpdate } from './resources/satispay_payments';
|
85
87
|
export type { Shipment, ShipmentUpdate } from './resources/shipments';
|
86
88
|
export type { ShippingCategory, ShippingCategoryCreate, ShippingCategoryUpdate } from './resources/shipping_categories';
|
87
89
|
export type { ShippingMethodTier } from './resources/shipping_method_tiers';
|
@@ -8,6 +8,7 @@ import type { CheckoutComPayment } from './checkout_com_payments';
|
|
8
8
|
import type { ExternalPayment } from './external_payments';
|
9
9
|
import type { KlarnaPayment } from './klarna_payments';
|
10
10
|
import type { PaypalPayment } from './paypal_payments';
|
11
|
+
import type { SatispayPayment } from './satispay_payments';
|
11
12
|
import type { StripePayment } from './stripe_payments';
|
12
13
|
import type { WireTransfer } from './wire_transfers';
|
13
14
|
type CustomerPaymentSourceRel = ResourceRel & {
|
@@ -37,6 +38,9 @@ type KlarnaPaymentRel = ResourceRel & {
|
|
37
38
|
type PaypalPaymentRel = ResourceRel & {
|
38
39
|
type: 'paypal_payments';
|
39
40
|
};
|
41
|
+
type SatispayPaymentRel = ResourceRel & {
|
42
|
+
type: 'satispay_payments';
|
43
|
+
};
|
40
44
|
type StripePaymentRel = ResourceRel & {
|
41
45
|
type: 'stripe_payments';
|
42
46
|
};
|
@@ -48,15 +52,15 @@ interface CustomerPaymentSource extends Resource {
|
|
48
52
|
customer_token?: string;
|
49
53
|
payment_source_token?: string;
|
50
54
|
customer?: Customer;
|
51
|
-
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | StripePayment | WireTransfer;
|
55
|
+
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | SatispayPayment | StripePayment | WireTransfer;
|
52
56
|
}
|
53
57
|
interface CustomerPaymentSourceCreate extends ResourceCreate {
|
54
58
|
customer: CustomerRel;
|
55
|
-
payment_source: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
59
|
+
payment_source: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
56
60
|
}
|
57
61
|
interface CustomerPaymentSourceUpdate extends ResourceUpdate {
|
58
62
|
customer?: CustomerRel;
|
59
|
-
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
63
|
+
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
60
64
|
}
|
61
65
|
declare class CustomerPaymentSources extends ApiResource {
|
62
66
|
static readonly TYPE: 'customer_payment_sources';
|
@@ -14,6 +14,7 @@ import type { CheckoutComPayment } from './checkout_com_payments';
|
|
14
14
|
import type { ExternalPayment } from './external_payments';
|
15
15
|
import type { KlarnaPayment } from './klarna_payments';
|
16
16
|
import type { PaypalPayment } from './paypal_payments';
|
17
|
+
import type { SatispayPayment } from './satispay_payments';
|
17
18
|
import type { StripePayment } from './stripe_payments';
|
18
19
|
import type { WireTransfer } from './wire_transfers';
|
19
20
|
import type { LineItem } from './line_items';
|
@@ -63,6 +64,9 @@ type KlarnaPaymentRel = ResourceRel & {
|
|
63
64
|
type PaypalPaymentRel = ResourceRel & {
|
64
65
|
type: 'paypal_payments';
|
65
66
|
};
|
67
|
+
type SatispayPaymentRel = ResourceRel & {
|
68
|
+
type: 'satispay_payments';
|
69
|
+
};
|
66
70
|
type StripePaymentRel = ResourceRel & {
|
67
71
|
type: 'stripe_payments';
|
68
72
|
};
|
@@ -177,7 +181,7 @@ interface Order extends Resource {
|
|
177
181
|
available_free_skus?: Sku[];
|
178
182
|
available_free_bundles?: Bundle[];
|
179
183
|
payment_method?: PaymentMethod;
|
180
|
-
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | StripePayment | WireTransfer;
|
184
|
+
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | SatispayPayment | StripePayment | WireTransfer;
|
181
185
|
line_items?: LineItem[];
|
182
186
|
shipments?: Shipment[];
|
183
187
|
transactions?: Array<Authorization | Void | Capture | Refund>;
|
@@ -210,7 +214,7 @@ interface OrderCreate extends ResourceCreate {
|
|
210
214
|
shipping_address?: AddressRel;
|
211
215
|
billing_address?: AddressRel;
|
212
216
|
payment_method?: PaymentMethodRel;
|
213
|
-
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
217
|
+
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
214
218
|
}
|
215
219
|
interface OrderUpdate extends ResourceUpdate {
|
216
220
|
autorefresh?: boolean;
|
@@ -255,7 +259,7 @@ interface OrderUpdate extends ResourceUpdate {
|
|
255
259
|
shipping_address?: AddressRel;
|
256
260
|
billing_address?: AddressRel;
|
257
261
|
payment_method?: PaymentMethodRel;
|
258
|
-
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
262
|
+
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
259
263
|
}
|
260
264
|
declare class Orders extends ApiResource {
|
261
265
|
static readonly TYPE: 'orders';
|
@@ -0,0 +1,39 @@
|
|
1
|
+
import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
|
2
|
+
import type { QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import type { PaymentMethod } from './payment_methods';
|
4
|
+
import type { SatispayPayment } from './satispay_payments';
|
5
|
+
type SatispayGatewayRel = ResourceRel & {
|
6
|
+
type: typeof SatispayGateways.TYPE;
|
7
|
+
};
|
8
|
+
type SatispayPaymentRel = ResourceRel & {
|
9
|
+
type: 'satispay_payments';
|
10
|
+
};
|
11
|
+
interface SatispayGateway extends Resource {
|
12
|
+
name?: string;
|
13
|
+
webhook_endpoint_url?: string;
|
14
|
+
payment_methods?: PaymentMethod[];
|
15
|
+
satispay_payments?: SatispayPayment[];
|
16
|
+
}
|
17
|
+
interface SatispayGatewayCreate extends ResourceCreate {
|
18
|
+
name: string;
|
19
|
+
satispay_payments?: SatispayPaymentRel[];
|
20
|
+
}
|
21
|
+
interface SatispayGatewayUpdate extends ResourceUpdate {
|
22
|
+
name?: string;
|
23
|
+
satispay_payments?: SatispayPaymentRel[];
|
24
|
+
}
|
25
|
+
declare class SatispayGateways extends ApiResource {
|
26
|
+
static readonly TYPE: 'satispay_gateways';
|
27
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SatispayGateway>>;
|
28
|
+
create(resource: SatispayGatewayCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SatispayGateway>;
|
29
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SatispayGateway>;
|
30
|
+
update(resource: SatispayGatewayUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SatispayGateway>;
|
31
|
+
delete(id: string, options?: ResourcesConfig): Promise<void>;
|
32
|
+
payment_methods(satispayGatewayId: string | SatispayGateway, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<PaymentMethod>>;
|
33
|
+
satispay_payments(satispayGatewayId: string | SatispayGateway, params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SatispayPayment>>;
|
34
|
+
isSatispayGateway(resource: any): resource is SatispayGateway;
|
35
|
+
relationship(id: string | ResourceId | null): SatispayGatewayRel;
|
36
|
+
type(): string;
|
37
|
+
}
|
38
|
+
export default SatispayGateways;
|
39
|
+
export { SatispayGateway, SatispayGatewayCreate, SatispayGatewayUpdate };
|
@@ -0,0 +1,41 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
const resource_1 = require("../resource");
|
4
|
+
class SatispayGateways extends resource_1.ApiResource {
|
5
|
+
// static readonly PATH = 'satispay_gateways'
|
6
|
+
async list(params, options) {
|
7
|
+
return this.resources.list({ type: SatispayGateways.TYPE }, params, options);
|
8
|
+
}
|
9
|
+
async create(resource, params, options) {
|
10
|
+
return this.resources.create(Object.assign(Object.assign({}, resource), { type: SatispayGateways.TYPE }), params, options);
|
11
|
+
}
|
12
|
+
async retrieve(id, params, options) {
|
13
|
+
return this.resources.retrieve({ type: SatispayGateways.TYPE, id }, params, options);
|
14
|
+
}
|
15
|
+
async update(resource, params, options) {
|
16
|
+
return this.resources.update(Object.assign(Object.assign({}, resource), { type: SatispayGateways.TYPE }), params, options);
|
17
|
+
}
|
18
|
+
async delete(id, options) {
|
19
|
+
await this.resources.delete({ type: SatispayGateways.TYPE, id }, options);
|
20
|
+
}
|
21
|
+
async payment_methods(satispayGatewayId, params, options) {
|
22
|
+
const _satispayGatewayId = satispayGatewayId.id || satispayGatewayId;
|
23
|
+
return this.resources.fetch({ type: 'payment_methods' }, `satispay_gateways/${_satispayGatewayId}/payment_methods`, params, options);
|
24
|
+
}
|
25
|
+
async satispay_payments(satispayGatewayId, params, options) {
|
26
|
+
const _satispayGatewayId = satispayGatewayId.id || satispayGatewayId;
|
27
|
+
return this.resources.fetch({ type: 'satispay_payments' }, `satispay_gateways/${_satispayGatewayId}/satispay_payments`, params, options);
|
28
|
+
}
|
29
|
+
// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types, @typescript-eslint/no-explicit-any
|
30
|
+
isSatispayGateway(resource) {
|
31
|
+
return resource.type && (resource.type === SatispayGateways.TYPE);
|
32
|
+
}
|
33
|
+
relationship(id) {
|
34
|
+
return ((id === null) || (typeof id === 'string')) ? { id, type: SatispayGateways.TYPE } : { id: id.id, type: SatispayGateways.TYPE };
|
35
|
+
}
|
36
|
+
type() {
|
37
|
+
return SatispayGateways.TYPE;
|
38
|
+
}
|
39
|
+
}
|
40
|
+
SatispayGateways.TYPE = 'satispay_gateways';
|
41
|
+
exports.default = SatispayGateways;
|
@@ -0,0 +1,43 @@
|
|
1
|
+
import { ApiResource, Resource, ResourceCreate, ResourceUpdate, ResourcesConfig, ResourceId, ResourceRel, ListResponse } from '../resource';
|
2
|
+
import type { QueryParamsList, QueryParamsRetrieve } from '../query';
|
3
|
+
import type { Order } from './orders';
|
4
|
+
import type { PaymentGateway } from './payment_gateways';
|
5
|
+
type SatispayPaymentRel = ResourceRel & {
|
6
|
+
type: typeof SatispayPayments.TYPE;
|
7
|
+
};
|
8
|
+
type OrderRel = ResourceRel & {
|
9
|
+
type: 'orders';
|
10
|
+
};
|
11
|
+
interface SatispayPayment extends Resource {
|
12
|
+
token?: string;
|
13
|
+
key_id?: string;
|
14
|
+
payment_id?: string;
|
15
|
+
redirect_url?: string;
|
16
|
+
order?: Order;
|
17
|
+
payment_gateway?: PaymentGateway;
|
18
|
+
}
|
19
|
+
interface SatispayPaymentCreate extends ResourceCreate {
|
20
|
+
token?: string;
|
21
|
+
redirect_url?: string;
|
22
|
+
order: OrderRel;
|
23
|
+
}
|
24
|
+
interface SatispayPaymentUpdate extends ResourceUpdate {
|
25
|
+
redirect_url?: string;
|
26
|
+
_refresh?: boolean;
|
27
|
+
order?: OrderRel;
|
28
|
+
}
|
29
|
+
declare class SatispayPayments extends ApiResource {
|
30
|
+
static readonly TYPE: 'satispay_payments';
|
31
|
+
list(params?: QueryParamsList, options?: ResourcesConfig): Promise<ListResponse<SatispayPayment>>;
|
32
|
+
create(resource: SatispayPaymentCreate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SatispayPayment>;
|
33
|
+
retrieve(id: string, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SatispayPayment>;
|
34
|
+
update(resource: SatispayPaymentUpdate, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<SatispayPayment>;
|
35
|
+
delete(id: string, options?: ResourcesConfig): Promise<void>;
|
36
|
+
order(satispayPaymentId: string | SatispayPayment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<Order>;
|
37
|
+
payment_gateway(satispayPaymentId: string | SatispayPayment, params?: QueryParamsRetrieve, options?: ResourcesConfig): Promise<PaymentGateway>;
|
38
|
+
isSatispayPayment(resource: any): resource is SatispayPayment;
|
39
|
+
relationship(id: string | ResourceId | null): SatispayPaymentRel;
|
40
|
+
type(): string;
|
41
|
+
}
|
42
|
+
export default SatispayPayments;
|
43
|
+
export { SatispayPayment, SatispayPaymentCreate, SatispayPaymentUpdate };
|
@@ -0,0 +1,41 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
const resource_1 = require("../resource");
|
4
|
+
class SatispayPayments extends resource_1.ApiResource {
|
5
|
+
// static readonly PATH = 'satispay_payments'
|
6
|
+
async list(params, options) {
|
7
|
+
return this.resources.list({ type: SatispayPayments.TYPE }, params, options);
|
8
|
+
}
|
9
|
+
async create(resource, params, options) {
|
10
|
+
return this.resources.create(Object.assign(Object.assign({}, resource), { type: SatispayPayments.TYPE }), params, options);
|
11
|
+
}
|
12
|
+
async retrieve(id, params, options) {
|
13
|
+
return this.resources.retrieve({ type: SatispayPayments.TYPE, id }, params, options);
|
14
|
+
}
|
15
|
+
async update(resource, params, options) {
|
16
|
+
return this.resources.update(Object.assign(Object.assign({}, resource), { type: SatispayPayments.TYPE }), params, options);
|
17
|
+
}
|
18
|
+
async delete(id, options) {
|
19
|
+
await this.resources.delete({ type: SatispayPayments.TYPE, id }, options);
|
20
|
+
}
|
21
|
+
async order(satispayPaymentId, params, options) {
|
22
|
+
const _satispayPaymentId = satispayPaymentId.id || satispayPaymentId;
|
23
|
+
return this.resources.fetch({ type: 'orders' }, `satispay_payments/${_satispayPaymentId}/order`, params, options);
|
24
|
+
}
|
25
|
+
async payment_gateway(satispayPaymentId, params, options) {
|
26
|
+
const _satispayPaymentId = satispayPaymentId.id || satispayPaymentId;
|
27
|
+
return this.resources.fetch({ type: 'payment_gateways' }, `satispay_payments/${_satispayPaymentId}/payment_gateway`, params, options);
|
28
|
+
}
|
29
|
+
// eslint-disable-next-line @typescript-eslint/explicit-module-boundary-types, @typescript-eslint/no-explicit-any
|
30
|
+
isSatispayPayment(resource) {
|
31
|
+
return resource.type && (resource.type === SatispayPayments.TYPE);
|
32
|
+
}
|
33
|
+
relationship(id) {
|
34
|
+
return ((id === null) || (typeof id === 'string')) ? { id, type: SatispayPayments.TYPE } : { id: id.id, type: SatispayPayments.TYPE };
|
35
|
+
}
|
36
|
+
type() {
|
37
|
+
return SatispayPayments.TYPE;
|
38
|
+
}
|
39
|
+
}
|
40
|
+
SatispayPayments.TYPE = 'satispay_payments';
|
41
|
+
exports.default = SatispayPayments;
|
package/lib/esm/api.d.ts
CHANGED
@@ -82,6 +82,8 @@ export { default as Promotions } from './resources/promotions';
|
|
82
82
|
export { default as Refunds } from './resources/refunds';
|
83
83
|
export { default as ReturnLineItems } from './resources/return_line_items';
|
84
84
|
export { default as Returns } from './resources/returns';
|
85
|
+
export { default as SatispayGateways } from './resources/satispay_gateways';
|
86
|
+
export { default as SatispayPayments } from './resources/satispay_payments';
|
85
87
|
export { default as Shipments } from './resources/shipments';
|
86
88
|
export { default as ShippingCategories } from './resources/shipping_categories';
|
87
89
|
export { default as ShippingMethodTiers } from './resources/shipping_method_tiers';
|
@@ -107,5 +109,5 @@ export { default as Transactions } from './resources/transactions';
|
|
107
109
|
export { default as Voids } from './resources/voids';
|
108
110
|
export { default as Webhooks } from './resources/webhooks';
|
109
111
|
export { default as WireTransfers } from './resources/wire_transfers';
|
110
|
-
export type ResourceTypeLock = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'application' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'captures' | 'carrier_accounts' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'event_callbacks' | 'events' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'geocoders' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscriptions' | 'order_validation_rules' | 'orders' | 'organization' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_gateways' | 'payment_methods' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_lists' | 'price_tiers' | 'price_volume_tiers' | 'prices' | 'promotion_rules' | 'promotions' | 'refunds' | 'return_line_items' | 'returns' | 'shipments' | 'shipping_categories' | 'shipping_method_tiers' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'tax_calculators' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'transactions' | 'voids' | 'webhooks' | 'wire_transfers';
|
111
|
-
export declare const resourceList: readonly ["addresses", "adjustments", "adyen_gateways", "adyen_payments", "application", "attachments", "authorizations", "avalara_accounts", "axerve_gateways", "axerve_payments", "billing_info_validation_rules", "bing_geocoders", "braintree_gateways", "braintree_payments", "bundles", "captures", "carrier_accounts", "checkout_com_gateways", "checkout_com_payments", "cleanups", "coupon_codes_promotion_rules", "coupon_recipients", "coupons", "customer_addresses", "customer_groups", "customer_password_resets", "customer_payment_sources", "customer_subscriptions", "customers", "delivery_lead_times", "event_callbacks", "events", "exports", "external_gateways", "external_payments", "external_promotions", "external_tax_calculators", "fixed_amount_promotions", "fixed_price_promotions", "free_gift_promotions", "free_shipping_promotions", "geocoders", "gift_card_recipients", "gift_cards", "google_geocoders", "imports", "in_stock_subscriptions", "inventory_models", "inventory_return_locations", "inventory_stock_locations", "klarna_gateways", "klarna_payments", "line_item_options", "line_items", "manual_gateways", "manual_tax_calculators", "markets", "merchants", "order_amount_promotion_rules", "order_copies", "order_subscriptions", "order_validation_rules", "orders", "organization", "packages", "parcel_line_items", "parcels", "payment_gateways", "payment_methods", "paypal_gateways", "paypal_payments", "percentage_discount_promotions", "price_lists", "price_tiers", "price_volume_tiers", "prices", "promotion_rules", "promotions", "refunds", "return_line_items", "returns", "shipments", "shipping_categories", "shipping_method_tiers", "shipping_methods", "shipping_weight_tiers", "shipping_zones", "sku_list_items", "sku_list_promotion_rules", "sku_lists", "sku_options", "skus", "stock_items", "stock_line_items", "stock_locations", "stock_transfers", "stripe_gateways", "stripe_payments", "tax_calculators", "tax_categories", "tax_rules", "taxjar_accounts", "transactions", "voids", "webhooks", "wire_transfers"];
|
112
|
+
export type ResourceTypeLock = 'addresses' | 'adjustments' | 'adyen_gateways' | 'adyen_payments' | 'application' | 'attachments' | 'authorizations' | 'avalara_accounts' | 'axerve_gateways' | 'axerve_payments' | 'billing_info_validation_rules' | 'bing_geocoders' | 'braintree_gateways' | 'braintree_payments' | 'bundles' | 'captures' | 'carrier_accounts' | 'checkout_com_gateways' | 'checkout_com_payments' | 'cleanups' | 'coupon_codes_promotion_rules' | 'coupon_recipients' | 'coupons' | 'customer_addresses' | 'customer_groups' | 'customer_password_resets' | 'customer_payment_sources' | 'customer_subscriptions' | 'customers' | 'delivery_lead_times' | 'event_callbacks' | 'events' | 'exports' | 'external_gateways' | 'external_payments' | 'external_promotions' | 'external_tax_calculators' | 'fixed_amount_promotions' | 'fixed_price_promotions' | 'free_gift_promotions' | 'free_shipping_promotions' | 'geocoders' | 'gift_card_recipients' | 'gift_cards' | 'google_geocoders' | 'imports' | 'in_stock_subscriptions' | 'inventory_models' | 'inventory_return_locations' | 'inventory_stock_locations' | 'klarna_gateways' | 'klarna_payments' | 'line_item_options' | 'line_items' | 'manual_gateways' | 'manual_tax_calculators' | 'markets' | 'merchants' | 'order_amount_promotion_rules' | 'order_copies' | 'order_subscriptions' | 'order_validation_rules' | 'orders' | 'organization' | 'packages' | 'parcel_line_items' | 'parcels' | 'payment_gateways' | 'payment_methods' | 'paypal_gateways' | 'paypal_payments' | 'percentage_discount_promotions' | 'price_lists' | 'price_tiers' | 'price_volume_tiers' | 'prices' | 'promotion_rules' | 'promotions' | 'refunds' | 'return_line_items' | 'returns' | 'satispay_gateways' | 'satispay_payments' | 'shipments' | 'shipping_categories' | 'shipping_method_tiers' | 'shipping_methods' | 'shipping_weight_tiers' | 'shipping_zones' | 'sku_list_items' | 'sku_list_promotion_rules' | 'sku_lists' | 'sku_options' | 'skus' | 'stock_items' | 'stock_line_items' | 'stock_locations' | 'stock_transfers' | 'stripe_gateways' | 'stripe_payments' | 'tax_calculators' | 'tax_categories' | 'tax_rules' | 'taxjar_accounts' | 'transactions' | 'voids' | 'webhooks' | 'wire_transfers';
|
113
|
+
export declare const resourceList: readonly ["addresses", "adjustments", "adyen_gateways", "adyen_payments", "application", "attachments", "authorizations", "avalara_accounts", "axerve_gateways", "axerve_payments", "billing_info_validation_rules", "bing_geocoders", "braintree_gateways", "braintree_payments", "bundles", "captures", "carrier_accounts", "checkout_com_gateways", "checkout_com_payments", "cleanups", "coupon_codes_promotion_rules", "coupon_recipients", "coupons", "customer_addresses", "customer_groups", "customer_password_resets", "customer_payment_sources", "customer_subscriptions", "customers", "delivery_lead_times", "event_callbacks", "events", "exports", "external_gateways", "external_payments", "external_promotions", "external_tax_calculators", "fixed_amount_promotions", "fixed_price_promotions", "free_gift_promotions", "free_shipping_promotions", "geocoders", "gift_card_recipients", "gift_cards", "google_geocoders", "imports", "in_stock_subscriptions", "inventory_models", "inventory_return_locations", "inventory_stock_locations", "klarna_gateways", "klarna_payments", "line_item_options", "line_items", "manual_gateways", "manual_tax_calculators", "markets", "merchants", "order_amount_promotion_rules", "order_copies", "order_subscriptions", "order_validation_rules", "orders", "organization", "packages", "parcel_line_items", "parcels", "payment_gateways", "payment_methods", "paypal_gateways", "paypal_payments", "percentage_discount_promotions", "price_lists", "price_tiers", "price_volume_tiers", "prices", "promotion_rules", "promotions", "refunds", "return_line_items", "returns", "satispay_gateways", "satispay_payments", "shipments", "shipping_categories", "shipping_method_tiers", "shipping_methods", "shipping_weight_tiers", "shipping_zones", "sku_list_items", "sku_list_promotion_rules", "sku_lists", "sku_options", "skus", "stock_items", "stock_line_items", "stock_locations", "stock_transfers", "stripe_gateways", "stripe_payments", "tax_calculators", "tax_categories", "tax_rules", "taxjar_accounts", "transactions", "voids", "webhooks", "wire_transfers"];
|
package/lib/esm/api.js
CHANGED
@@ -84,6 +84,8 @@ export { default as Promotions } from './resources/promotions';
|
|
84
84
|
export { default as Refunds } from './resources/refunds';
|
85
85
|
export { default as ReturnLineItems } from './resources/return_line_items';
|
86
86
|
export { default as Returns } from './resources/returns';
|
87
|
+
export { default as SatispayGateways } from './resources/satispay_gateways';
|
88
|
+
export { default as SatispayPayments } from './resources/satispay_payments';
|
87
89
|
export { default as Shipments } from './resources/shipments';
|
88
90
|
export { default as ShippingCategories } from './resources/shipping_categories';
|
89
91
|
export { default as ShippingMethodTiers } from './resources/shipping_method_tiers';
|
@@ -193,6 +195,8 @@ export const resourceList = [
|
|
193
195
|
'refunds',
|
194
196
|
'return_line_items',
|
195
197
|
'returns',
|
198
|
+
'satispay_gateways',
|
199
|
+
'satispay_payments',
|
196
200
|
'shipments',
|
197
201
|
'shipping_categories',
|
198
202
|
'shipping_method_tiers',
|
@@ -2,7 +2,7 @@ import * as api from './api';
|
|
2
2
|
import { ApiError } from './error';
|
3
3
|
import type { ErrorInterceptor, InterceptorType, RawResponseReader, RequestInterceptor, ResponseInterceptor } from './interceptor';
|
4
4
|
import { ResourcesInitConfig } from './resource';
|
5
|
-
declare const OPEN_API_SCHEMA_VERSION = "
|
5
|
+
declare const OPEN_API_SCHEMA_VERSION = "4.0.1";
|
6
6
|
export { OPEN_API_SCHEMA_VERSION };
|
7
7
|
type SdkConfig = {};
|
8
8
|
type CommerceLayerInitConfig = SdkConfig & ResourcesInitConfig;
|
@@ -10,7 +10,7 @@ type CommerceLayerConfig = Partial<CommerceLayerInitConfig>;
|
|
10
10
|
declare class CommerceLayerClient {
|
11
11
|
#private;
|
12
12
|
static get openApiSchemaVersion(): string;
|
13
|
-
readonly openApiSchemaVersion = "
|
13
|
+
readonly openApiSchemaVersion = "4.0.1";
|
14
14
|
addresses: api.Addresses;
|
15
15
|
adjustments: api.Adjustments;
|
16
16
|
adyen_gateways: api.AdyenGateways;
|
@@ -92,6 +92,8 @@ declare class CommerceLayerClient {
|
|
92
92
|
refunds: api.Refunds;
|
93
93
|
return_line_items: api.ReturnLineItems;
|
94
94
|
returns: api.Returns;
|
95
|
+
satispay_gateways: api.SatispayGateways;
|
96
|
+
satispay_payments: api.SatispayPayments;
|
95
97
|
shipments: api.Shipments;
|
96
98
|
shipping_categories: api.ShippingCategories;
|
97
99
|
shipping_method_tiers: api.ShippingMethodTiers;
|
package/lib/esm/commercelayer.js
CHANGED
@@ -16,7 +16,7 @@ import ResourceAdapter from './resource';
|
|
16
16
|
import Debug from './debug';
|
17
17
|
const debug = Debug('commercelayer');
|
18
18
|
// Autogenerated schema version number, do not remove this line
|
19
|
-
const OPEN_API_SCHEMA_VERSION = '
|
19
|
+
const OPEN_API_SCHEMA_VERSION = '4.0.1';
|
20
20
|
export { OPEN_API_SCHEMA_VERSION };
|
21
21
|
class CommerceLayerClient {
|
22
22
|
static get openApiSchemaVersion() { return OPEN_API_SCHEMA_VERSION; }
|
@@ -111,6 +111,8 @@ class CommerceLayerClient {
|
|
111
111
|
this.refunds = new api.Refunds(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
112
112
|
this.return_line_items = new api.ReturnLineItems(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
113
113
|
this.returns = new api.Returns(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
114
|
+
this.satispay_gateways = new api.SatispayGateways(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
115
|
+
this.satispay_payments = new api.SatispayPayments(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
114
116
|
this.shipments = new api.Shipments(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
115
117
|
this.shipping_categories = new api.ShippingCategories(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
116
118
|
this.shipping_method_tiers = new api.ShippingMethodTiers(__classPrivateFieldGet(this, _CommerceLayerClient_adapter, "f"));
|
package/lib/esm/model.d.ts
CHANGED
@@ -82,6 +82,8 @@ export type { Promotion } from './resources/promotions';
|
|
82
82
|
export type { Refund } from './resources/refunds';
|
83
83
|
export type { ReturnLineItem, ReturnLineItemCreate, ReturnLineItemUpdate } from './resources/return_line_items';
|
84
84
|
export type { Return, ReturnCreate, ReturnUpdate } from './resources/returns';
|
85
|
+
export type { SatispayGateway, SatispayGatewayCreate, SatispayGatewayUpdate } from './resources/satispay_gateways';
|
86
|
+
export type { SatispayPayment, SatispayPaymentCreate, SatispayPaymentUpdate } from './resources/satispay_payments';
|
85
87
|
export type { Shipment, ShipmentUpdate } from './resources/shipments';
|
86
88
|
export type { ShippingCategory, ShippingCategoryCreate, ShippingCategoryUpdate } from './resources/shipping_categories';
|
87
89
|
export type { ShippingMethodTier } from './resources/shipping_method_tiers';
|
@@ -8,6 +8,7 @@ import type { CheckoutComPayment } from './checkout_com_payments';
|
|
8
8
|
import type { ExternalPayment } from './external_payments';
|
9
9
|
import type { KlarnaPayment } from './klarna_payments';
|
10
10
|
import type { PaypalPayment } from './paypal_payments';
|
11
|
+
import type { SatispayPayment } from './satispay_payments';
|
11
12
|
import type { StripePayment } from './stripe_payments';
|
12
13
|
import type { WireTransfer } from './wire_transfers';
|
13
14
|
type CustomerPaymentSourceRel = ResourceRel & {
|
@@ -37,6 +38,9 @@ type KlarnaPaymentRel = ResourceRel & {
|
|
37
38
|
type PaypalPaymentRel = ResourceRel & {
|
38
39
|
type: 'paypal_payments';
|
39
40
|
};
|
41
|
+
type SatispayPaymentRel = ResourceRel & {
|
42
|
+
type: 'satispay_payments';
|
43
|
+
};
|
40
44
|
type StripePaymentRel = ResourceRel & {
|
41
45
|
type: 'stripe_payments';
|
42
46
|
};
|
@@ -48,15 +52,15 @@ interface CustomerPaymentSource extends Resource {
|
|
48
52
|
customer_token?: string;
|
49
53
|
payment_source_token?: string;
|
50
54
|
customer?: Customer;
|
51
|
-
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | StripePayment | WireTransfer;
|
55
|
+
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | SatispayPayment | StripePayment | WireTransfer;
|
52
56
|
}
|
53
57
|
interface CustomerPaymentSourceCreate extends ResourceCreate {
|
54
58
|
customer: CustomerRel;
|
55
|
-
payment_source: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
59
|
+
payment_source: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
56
60
|
}
|
57
61
|
interface CustomerPaymentSourceUpdate extends ResourceUpdate {
|
58
62
|
customer?: CustomerRel;
|
59
|
-
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
63
|
+
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
60
64
|
}
|
61
65
|
declare class CustomerPaymentSources extends ApiResource {
|
62
66
|
static readonly TYPE: 'customer_payment_sources';
|
@@ -14,6 +14,7 @@ import type { CheckoutComPayment } from './checkout_com_payments';
|
|
14
14
|
import type { ExternalPayment } from './external_payments';
|
15
15
|
import type { KlarnaPayment } from './klarna_payments';
|
16
16
|
import type { PaypalPayment } from './paypal_payments';
|
17
|
+
import type { SatispayPayment } from './satispay_payments';
|
17
18
|
import type { StripePayment } from './stripe_payments';
|
18
19
|
import type { WireTransfer } from './wire_transfers';
|
19
20
|
import type { LineItem } from './line_items';
|
@@ -63,6 +64,9 @@ type KlarnaPaymentRel = ResourceRel & {
|
|
63
64
|
type PaypalPaymentRel = ResourceRel & {
|
64
65
|
type: 'paypal_payments';
|
65
66
|
};
|
67
|
+
type SatispayPaymentRel = ResourceRel & {
|
68
|
+
type: 'satispay_payments';
|
69
|
+
};
|
66
70
|
type StripePaymentRel = ResourceRel & {
|
67
71
|
type: 'stripe_payments';
|
68
72
|
};
|
@@ -177,7 +181,7 @@ interface Order extends Resource {
|
|
177
181
|
available_free_skus?: Sku[];
|
178
182
|
available_free_bundles?: Bundle[];
|
179
183
|
payment_method?: PaymentMethod;
|
180
|
-
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | StripePayment | WireTransfer;
|
184
|
+
payment_source?: AdyenPayment | AxervePayment | BraintreePayment | CheckoutComPayment | ExternalPayment | KlarnaPayment | PaypalPayment | SatispayPayment | StripePayment | WireTransfer;
|
181
185
|
line_items?: LineItem[];
|
182
186
|
shipments?: Shipment[];
|
183
187
|
transactions?: Array<Authorization | Void | Capture | Refund>;
|
@@ -210,7 +214,7 @@ interface OrderCreate extends ResourceCreate {
|
|
210
214
|
shipping_address?: AddressRel;
|
211
215
|
billing_address?: AddressRel;
|
212
216
|
payment_method?: PaymentMethodRel;
|
213
|
-
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
217
|
+
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
214
218
|
}
|
215
219
|
interface OrderUpdate extends ResourceUpdate {
|
216
220
|
autorefresh?: boolean;
|
@@ -255,7 +259,7 @@ interface OrderUpdate extends ResourceUpdate {
|
|
255
259
|
shipping_address?: AddressRel;
|
256
260
|
billing_address?: AddressRel;
|
257
261
|
payment_method?: PaymentMethodRel;
|
258
|
-
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | StripePaymentRel | WireTransferRel;
|
262
|
+
payment_source?: AdyenPaymentRel | AxervePaymentRel | BraintreePaymentRel | CheckoutComPaymentRel | ExternalPaymentRel | KlarnaPaymentRel | PaypalPaymentRel | SatispayPaymentRel | StripePaymentRel | WireTransferRel;
|
259
263
|
}
|
260
264
|
declare class Orders extends ApiResource {
|
261
265
|
static readonly TYPE: 'orders';
|