ultracart_rest_api_v2_typescript 3.10.152 → 3.10.154

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- ## ultracart_rest_api_v2_typescript@3.10.152
1
+ ## ultracart_rest_api_v2_typescript@3.10.154
2
2
 
3
3
  This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
4
4
 
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
36
36
  _published:_
37
37
 
38
38
  ```
39
- npm install ultracart_rest_api_v2_typescript@3.10.152 --save
39
+ npm install ultracart_rest_api_v2_typescript@3.10.154 --save
40
40
  ```
41
41
 
42
42
  _unPublished (not recommended):_
@@ -54,6 +54,8 @@ Not every change is committed to every SDK.
54
54
 
55
55
  | Version | Date | Comments |
56
56
  | --: | :-: | --- |
57
+ | 3.10.154 | 08/14/2023 | esp - add require_order_within_last to the settings object |
58
+ | 3.10.153 | 08/14/2023 | esp - expose rate limiter values in settings object |
57
59
  | 3.10.152 | 07/27/2023 | dw bi - add settings to the report and page objects |
58
60
  | 3.10.151 | 07/19/2023 | dw bi - add data_source_uuid to filter connection obj |
59
61
  | 3.10.150 | 07/19/2023 | dw bi - add data_source_uuid to page visualization obj |
package/api.ts CHANGED
@@ -18999,6 +18999,24 @@ export interface EmailSendingDomainsResponse {
18999
18999
  * @interface EmailSettings
19000
19000
  */
19001
19001
  export interface EmailSettings {
19002
+ /**
19003
+ * Emails per day allowed
19004
+ * @type {number}
19005
+ * @memberof EmailSettings
19006
+ */
19007
+ emails_per_day?: number;
19008
+ /**
19009
+ * Emails per hour allowed
19010
+ * @type {number}
19011
+ * @memberof EmailSettings
19012
+ */
19013
+ emails_per_hour?: number;
19014
+ /**
19015
+ * Emails per month allowed
19016
+ * @type {number}
19017
+ * @memberof EmailSettings
19018
+ */
19019
+ emails_per_month?: number;
19002
19020
  /**
19003
19021
  *
19004
19022
  * @type {string}
@@ -19053,6 +19071,12 @@ export interface EmailSettings {
19053
19071
  * @memberof EmailSettings
19054
19072
  */
19055
19073
  postcard_from_state?: string;
19074
+ /**
19075
+ * Require order within last
19076
+ * @type {number}
19077
+ * @memberof EmailSettings
19078
+ */
19079
+ require_order_within_last?: number;
19056
19080
  /**
19057
19081
  * True if the Reviews.io integration is configured
19058
19082
  * @type {boolean}
@@ -33135,6 +33159,52 @@ export interface OrderUtm {
33135
33159
  wbraid?: string;
33136
33160
  }
33137
33161
 
33162
+ /**
33163
+ *
33164
+ * @export
33165
+ * @interface OrderValidationRequest
33166
+ */
33167
+ export interface OrderValidationRequest {
33168
+ /**
33169
+ * Checks to perform
33170
+ * @type {Array<string>}
33171
+ * @memberof OrderValidationRequest
33172
+ */
33173
+ checks?: Array<string>;
33174
+ /**
33175
+ *
33176
+ * @type {Order}
33177
+ * @memberof OrderValidationRequest
33178
+ */
33179
+ order?: Order;
33180
+ }
33181
+
33182
+ /**
33183
+ *
33184
+ * @export
33185
+ * @interface OrderValidationResponse
33186
+ */
33187
+ export interface OrderValidationResponse {
33188
+ /**
33189
+ * Errors to display to the merchant if they failed any of the validations checked
33190
+ * @type {Array<string>}
33191
+ * @memberof OrderValidationResponse
33192
+ */
33193
+ errors?: Array<string>;
33194
+ /**
33195
+ * Informational messages
33196
+ * @type {Array<string>}
33197
+ * @memberof OrderValidationResponse
33198
+ */
33199
+ messages?: Array<string>;
33200
+ /**
33201
+ * If true, this order was updated during the validation call. This may happen during address standardization fixes.
33202
+ * @type {boolean}
33203
+ * @memberof OrderValidationResponse
33204
+ */
33205
+ order_was_updated?: boolean;
33206
+ }
33207
+
33138
33208
  /**
33139
33209
  *
33140
33210
  * @export
@@ -63117,6 +63187,61 @@ export const OrderApiFetchParamCreator = function (configuration?: Configuration
63117
63187
  const needsSerialization = (<any>"Order" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
63118
63188
  localVarRequestOptions.body = needsSerialization ? JSON.stringify(order || {}) : (order || "");
63119
63189
 
63190
+ return {
63191
+ url: url.format(localVarUrlObj),
63192
+ options: localVarRequestOptions,
63193
+ };
63194
+ },
63195
+ /**
63196
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
63197
+ * @summary Validate
63198
+ * @param {OrderValidationRequest} validation_request Validation request
63199
+ * @param {*} [options] Override http request option.
63200
+ * @throws {RequiredError}
63201
+ */
63202
+ validateOrder(validation_request: OrderValidationRequest, options: any = {}): FetchArgs {
63203
+ // verify required parameter 'validation_request' is not null or undefined
63204
+ if (validation_request === null || validation_request === undefined) {
63205
+ throw new RequiredError('validation_request','Required parameter validation_request was null or undefined when calling validateOrder.');
63206
+ }
63207
+ const localVarPath = `/order/validate`;
63208
+ const localVarUrlObj = url.parse(localVarPath, true);
63209
+ const localVarRequestOptions = Object.assign({ method: 'POST' }, options);
63210
+ const localVarHeaderParameter = {} as any;
63211
+ const localVarQueryParameter = {} as any;
63212
+
63213
+ if(configuration && configuration.apiVersion) {
63214
+ localVarHeaderParameter["X-UltraCart-Api-Version"] = configuration.apiVersion;
63215
+ }
63216
+
63217
+
63218
+
63219
+ // authentication ultraCartOauth required
63220
+ // oauth required
63221
+ if (configuration && configuration.accessToken) {
63222
+ const localVarAccessTokenValue = typeof configuration.accessToken === 'function'
63223
+ ? configuration.accessToken("ultraCartOauth", ["order_read", "order_write"])
63224
+ : configuration.accessToken;
63225
+ localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue;
63226
+ }
63227
+
63228
+ // authentication ultraCartSimpleApiKey required
63229
+ if (configuration && configuration.apiKey) {
63230
+ const localVarApiKeyValue = typeof configuration.apiKey === 'function'
63231
+ ? configuration.apiKey("x-ultracart-simple-key")
63232
+ : configuration.apiKey;
63233
+ localVarHeaderParameter["x-ultracart-simple-key"] = localVarApiKeyValue;
63234
+ }
63235
+
63236
+ localVarHeaderParameter['Content-Type'] = 'application/json';
63237
+
63238
+ localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query);
63239
+ // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
63240
+ delete localVarUrlObj.search;
63241
+ localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers);
63242
+ const needsSerialization = (<any>"OrderValidationRequest" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
63243
+ localVarRequestOptions.body = needsSerialization ? JSON.stringify(validation_request || {}) : (validation_request || "");
63244
+
63120
63245
  return {
63121
63246
  url: url.format(localVarUrlObj),
63122
63247
  options: localVarRequestOptions,
@@ -63733,6 +63858,27 @@ export const OrderApiFp = function(configuration?: Configuration) {
63733
63858
  });
63734
63859
  };
63735
63860
  },
63861
+ /**
63862
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
63863
+ * @summary Validate
63864
+ * @param {OrderValidationRequest} validation_request Validation request
63865
+ * @param {*} [options] Override http request option.
63866
+ * @throws {RequiredError}
63867
+ */
63868
+ validateOrder(validation_request: OrderValidationRequest, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise<OrderValidationResponse> {
63869
+ const localVarFetchArgs = OrderApiFetchParamCreator(configuration).validateOrder(validation_request, options);
63870
+ return (fetch: FetchAPI = portableFetch, basePath: string = BASE_PATH) => {
63871
+ return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then((response) => {
63872
+
63873
+ if (response.status >= 200 && response.status < 300) {
63874
+ return response.json();
63875
+
63876
+ } else {
63877
+ throw response;
63878
+ }
63879
+ });
63880
+ };
63881
+ },
63736
63882
  }
63737
63883
  };
63738
63884
 
@@ -64058,6 +64204,16 @@ export const OrderApiFactory = function (configuration?: Configuration, fetch?:
64058
64204
  updateOrder(order: Order, order_id: string, _expand?: string, options?: any) {
64059
64205
  return OrderApiFp(configuration).updateOrder(order, order_id, _expand, options)(fetch, basePath);
64060
64206
  },
64207
+ /**
64208
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
64209
+ * @summary Validate
64210
+ * @param {OrderValidationRequest} validation_request Validation request
64211
+ * @param {*} [options] Override http request option.
64212
+ * @throws {RequiredError}
64213
+ */
64214
+ validateOrder(validation_request: OrderValidationRequest, options?: any) {
64215
+ return OrderApiFp(configuration).validateOrder(validation_request, options)(fetch, basePath);
64216
+ },
64061
64217
  };
64062
64218
  };
64063
64219
 
@@ -64383,6 +64539,16 @@ export interface OrderApiInterface {
64383
64539
  */
64384
64540
  updateOrder(order: Order, order_id: string, _expand?: string, options?: any): Promise<OrderResponse>;
64385
64541
 
64542
+ /**
64543
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
64544
+ * @summary Validate
64545
+ * @param {OrderValidationRequest} validation_request Validation request
64546
+ * @param {*} [options] Override http request option.
64547
+ * @throws {RequiredError}
64548
+ * @memberof OrderApiInterface
64549
+ */
64550
+ validateOrder(validation_request: OrderValidationRequest, options?: any): Promise<OrderValidationResponse>;
64551
+
64386
64552
  }
64387
64553
 
64388
64554
  /**
@@ -64760,6 +64926,18 @@ export class OrderApi extends BaseAPI implements OrderApiInterface {
64760
64926
  return OrderApiFp(this.configuration).updateOrder(order, order_id, _expand, options)(this.fetch, this.basePath);
64761
64927
  }
64762
64928
 
64929
+ /**
64930
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
64931
+ * @summary Validate
64932
+ * @param {OrderValidationRequest} validation_request Validation request
64933
+ * @param {*} [options] Override http request option.
64934
+ * @throws {RequiredError}
64935
+ * @memberof OrderApi
64936
+ */
64937
+ public validateOrder(validation_request: OrderValidationRequest, options?: any) {
64938
+ return OrderApiFp(this.configuration).validateOrder(validation_request, options)(this.fetch, this.basePath);
64939
+ }
64940
+
64763
64941
  }
64764
64942
 
64765
64943
  /**
package/dist/api.d.ts CHANGED
@@ -18570,6 +18570,24 @@ export interface EmailSendingDomainsResponse {
18570
18570
  * @interface EmailSettings
18571
18571
  */
18572
18572
  export interface EmailSettings {
18573
+ /**
18574
+ * Emails per day allowed
18575
+ * @type {number}
18576
+ * @memberof EmailSettings
18577
+ */
18578
+ emails_per_day?: number;
18579
+ /**
18580
+ * Emails per hour allowed
18581
+ * @type {number}
18582
+ * @memberof EmailSettings
18583
+ */
18584
+ emails_per_hour?: number;
18585
+ /**
18586
+ * Emails per month allowed
18587
+ * @type {number}
18588
+ * @memberof EmailSettings
18589
+ */
18590
+ emails_per_month?: number;
18573
18591
  /**
18574
18592
  *
18575
18593
  * @type {string}
@@ -18624,6 +18642,12 @@ export interface EmailSettings {
18624
18642
  * @memberof EmailSettings
18625
18643
  */
18626
18644
  postcard_from_state?: string;
18645
+ /**
18646
+ * Require order within last
18647
+ * @type {number}
18648
+ * @memberof EmailSettings
18649
+ */
18650
+ require_order_within_last?: number;
18627
18651
  /**
18628
18652
  * True if the Reviews.io integration is configured
18629
18653
  * @type {boolean}
@@ -32444,6 +32468,50 @@ export interface OrderUtm {
32444
32468
  */
32445
32469
  wbraid?: string;
32446
32470
  }
32471
+ /**
32472
+ *
32473
+ * @export
32474
+ * @interface OrderValidationRequest
32475
+ */
32476
+ export interface OrderValidationRequest {
32477
+ /**
32478
+ * Checks to perform
32479
+ * @type {Array<string>}
32480
+ * @memberof OrderValidationRequest
32481
+ */
32482
+ checks?: Array<string>;
32483
+ /**
32484
+ *
32485
+ * @type {Order}
32486
+ * @memberof OrderValidationRequest
32487
+ */
32488
+ order?: Order;
32489
+ }
32490
+ /**
32491
+ *
32492
+ * @export
32493
+ * @interface OrderValidationResponse
32494
+ */
32495
+ export interface OrderValidationResponse {
32496
+ /**
32497
+ * Errors to display to the merchant if they failed any of the validations checked
32498
+ * @type {Array<string>}
32499
+ * @memberof OrderValidationResponse
32500
+ */
32501
+ errors?: Array<string>;
32502
+ /**
32503
+ * Informational messages
32504
+ * @type {Array<string>}
32505
+ * @memberof OrderValidationResponse
32506
+ */
32507
+ messages?: Array<string>;
32508
+ /**
32509
+ * If true, this order was updated during the validation call. This may happen during address standardization fixes.
32510
+ * @type {boolean}
32511
+ * @memberof OrderValidationResponse
32512
+ */
32513
+ order_was_updated?: boolean;
32514
+ }
32447
32515
  /**
32448
32516
  *
32449
32517
  * @export
@@ -48674,6 +48742,14 @@ export declare const OrderApiFetchParamCreator: (configuration?: Configuration)
48674
48742
  * @throws {RequiredError}
48675
48743
  */
48676
48744
  updateOrder(order: Order, order_id: string, _expand?: string, options?: any): FetchArgs;
48745
+ /**
48746
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
48747
+ * @summary Validate
48748
+ * @param {OrderValidationRequest} validation_request Validation request
48749
+ * @param {*} [options] Override http request option.
48750
+ * @throws {RequiredError}
48751
+ */
48752
+ validateOrder(validation_request: OrderValidationRequest, options?: any): FetchArgs;
48677
48753
  };
48678
48754
  /**
48679
48755
  * OrderApi - functional programming interface
@@ -48944,6 +49020,14 @@ export declare const OrderApiFp: (configuration?: Configuration) => {
48944
49020
  * @throws {RequiredError}
48945
49021
  */
48946
49022
  updateOrder(order: Order, order_id: string, _expand?: string, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise<OrderResponse>;
49023
+ /**
49024
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
49025
+ * @summary Validate
49026
+ * @param {OrderValidationRequest} validation_request Validation request
49027
+ * @param {*} [options] Override http request option.
49028
+ * @throws {RequiredError}
49029
+ */
49030
+ validateOrder(validation_request: OrderValidationRequest, options?: any): (fetch?: FetchAPI, basePath?: string) => Promise<OrderValidationResponse>;
48947
49031
  };
48948
49032
  /**
48949
49033
  * OrderApi - factory interface
@@ -49214,6 +49298,14 @@ export declare const OrderApiFactory: (configuration?: Configuration, fetch?: Fe
49214
49298
  * @throws {RequiredError}
49215
49299
  */
49216
49300
  updateOrder(order: Order, order_id: string, _expand?: string, options?: any): Promise<OrderResponse>;
49301
+ /**
49302
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
49303
+ * @summary Validate
49304
+ * @param {OrderValidationRequest} validation_request Validation request
49305
+ * @param {*} [options] Override http request option.
49306
+ * @throws {RequiredError}
49307
+ */
49308
+ validateOrder(validation_request: OrderValidationRequest, options?: any): Promise<OrderValidationResponse>;
49217
49309
  };
49218
49310
  /**
49219
49311
  * OrderApi - interface
@@ -49511,6 +49603,15 @@ export interface OrderApiInterface {
49511
49603
  * @memberof OrderApiInterface
49512
49604
  */
49513
49605
  updateOrder(order: Order, order_id: string, _expand?: string, options?: any): Promise<OrderResponse>;
49606
+ /**
49607
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
49608
+ * @summary Validate
49609
+ * @param {OrderValidationRequest} validation_request Validation request
49610
+ * @param {*} [options] Override http request option.
49611
+ * @throws {RequiredError}
49612
+ * @memberof OrderApiInterface
49613
+ */
49614
+ validateOrder(validation_request: OrderValidationRequest, options?: any): Promise<OrderValidationResponse>;
49514
49615
  }
49515
49616
  /**
49516
49617
  * OrderApi - object-oriented interface
@@ -49809,6 +49910,15 @@ export declare class OrderApi extends BaseAPI implements OrderApiInterface {
49809
49910
  * @memberof OrderApi
49810
49911
  */
49811
49912
  updateOrder(order: Order, order_id: string, _expand?: string, options?: any): Promise<OrderResponse>;
49913
+ /**
49914
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
49915
+ * @summary Validate
49916
+ * @param {OrderValidationRequest} validation_request Validation request
49917
+ * @param {*} [options] Override http request option.
49918
+ * @throws {RequiredError}
49919
+ * @memberof OrderApi
49920
+ */
49921
+ validateOrder(validation_request: OrderValidationRequest, options?: any): Promise<OrderValidationResponse>;
49812
49922
  }
49813
49923
  /**
49814
49924
  * SsoApi - fetch parameter creator
package/dist/api.js CHANGED
@@ -20587,6 +20587,54 @@ var OrderApiFetchParamCreator = function (configuration) {
20587
20587
  options: localVarRequestOptions,
20588
20588
  };
20589
20589
  },
20590
+ /**
20591
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
20592
+ * @summary Validate
20593
+ * @param {OrderValidationRequest} validation_request Validation request
20594
+ * @param {*} [options] Override http request option.
20595
+ * @throws {RequiredError}
20596
+ */
20597
+ validateOrder: function (validation_request, options) {
20598
+ if (options === void 0) { options = {}; }
20599
+ // verify required parameter 'validation_request' is not null or undefined
20600
+ if (validation_request === null || validation_request === undefined) {
20601
+ throw new RequiredError('validation_request', 'Required parameter validation_request was null or undefined when calling validateOrder.');
20602
+ }
20603
+ var localVarPath = "/order/validate";
20604
+ var localVarUrlObj = url.parse(localVarPath, true);
20605
+ var localVarRequestOptions = Object.assign({ method: 'POST' }, options);
20606
+ var localVarHeaderParameter = {};
20607
+ var localVarQueryParameter = {};
20608
+ if (configuration && configuration.apiVersion) {
20609
+ localVarHeaderParameter["X-UltraCart-Api-Version"] = configuration.apiVersion;
20610
+ }
20611
+ // authentication ultraCartOauth required
20612
+ // oauth required
20613
+ if (configuration && configuration.accessToken) {
20614
+ var localVarAccessTokenValue = typeof configuration.accessToken === 'function'
20615
+ ? configuration.accessToken("ultraCartOauth", ["order_read", "order_write"])
20616
+ : configuration.accessToken;
20617
+ localVarHeaderParameter["Authorization"] = "Bearer " + localVarAccessTokenValue;
20618
+ }
20619
+ // authentication ultraCartSimpleApiKey required
20620
+ if (configuration && configuration.apiKey) {
20621
+ var localVarApiKeyValue = typeof configuration.apiKey === 'function'
20622
+ ? configuration.apiKey("x-ultracart-simple-key")
20623
+ : configuration.apiKey;
20624
+ localVarHeaderParameter["x-ultracart-simple-key"] = localVarApiKeyValue;
20625
+ }
20626
+ localVarHeaderParameter['Content-Type'] = 'application/json';
20627
+ localVarUrlObj.query = Object.assign({}, localVarUrlObj.query, localVarQueryParameter, options.query);
20628
+ // fix override query string Detail: https://stackoverflow.com/a/7517673/1077943
20629
+ delete localVarUrlObj.search;
20630
+ localVarRequestOptions.headers = Object.assign({}, localVarHeaderParameter, options.headers);
20631
+ var needsSerialization = ("OrderValidationRequest" !== "string") || localVarRequestOptions.headers['Content-Type'] === 'application/json';
20632
+ localVarRequestOptions.body = needsSerialization ? JSON.stringify(validation_request || {}) : (validation_request || "");
20633
+ return {
20634
+ url: url.format(localVarUrlObj),
20635
+ options: localVarRequestOptions,
20636
+ };
20637
+ },
20590
20638
  };
20591
20639
  };
20592
20640
  exports.OrderApiFetchParamCreator = OrderApiFetchParamCreator;
@@ -21224,6 +21272,28 @@ var OrderApiFp = function (configuration) {
21224
21272
  });
21225
21273
  };
21226
21274
  },
21275
+ /**
21276
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
21277
+ * @summary Validate
21278
+ * @param {OrderValidationRequest} validation_request Validation request
21279
+ * @param {*} [options] Override http request option.
21280
+ * @throws {RequiredError}
21281
+ */
21282
+ validateOrder: function (validation_request, options) {
21283
+ var localVarFetchArgs = (0, exports.OrderApiFetchParamCreator)(configuration).validateOrder(validation_request, options);
21284
+ return function (fetch, basePath) {
21285
+ if (fetch === void 0) { fetch = portableFetch; }
21286
+ if (basePath === void 0) { basePath = BASE_PATH; }
21287
+ return fetch(basePath + localVarFetchArgs.url, localVarFetchArgs.options).then(function (response) {
21288
+ if (response.status >= 200 && response.status < 300) {
21289
+ return response.json();
21290
+ }
21291
+ else {
21292
+ throw response;
21293
+ }
21294
+ });
21295
+ };
21296
+ },
21227
21297
  };
21228
21298
  };
21229
21299
  exports.OrderApiFp = OrderApiFp;
@@ -21549,6 +21619,16 @@ var OrderApiFactory = function (configuration, fetch, basePath) {
21549
21619
  updateOrder: function (order, order_id, _expand, options) {
21550
21620
  return (0, exports.OrderApiFp)(configuration).updateOrder(order, order_id, _expand, options)(fetch, basePath);
21551
21621
  },
21622
+ /**
21623
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
21624
+ * @summary Validate
21625
+ * @param {OrderValidationRequest} validation_request Validation request
21626
+ * @param {*} [options] Override http request option.
21627
+ * @throws {RequiredError}
21628
+ */
21629
+ validateOrder: function (validation_request, options) {
21630
+ return (0, exports.OrderApiFp)(configuration).validateOrder(validation_request, options)(fetch, basePath);
21631
+ },
21552
21632
  };
21553
21633
  };
21554
21634
  exports.OrderApiFactory = OrderApiFactory;
@@ -21905,6 +21985,17 @@ var OrderApi = /** @class */ (function (_super) {
21905
21985
  OrderApi.prototype.updateOrder = function (order, order_id, _expand, options) {
21906
21986
  return (0, exports.OrderApiFp)(this.configuration).updateOrder(order, order_id, _expand, options)(this.fetch, this.basePath);
21907
21987
  };
21988
+ /**
21989
+ * Validate the order for errors. Specific checks can be passed to fine tune what is validated. Read and write permissions are required because the validate method may fix obvious address issues automatically which require update permission.This rest call makes use of the built-in translation of rest objects to UltraCart internal objects which also contains a multitude of validation checks that cannot be trapped. Therefore any time this call is made, you should also trap api exceptions and examine their content because it may contain validation issues. So check the response object and trap any exceptions.
21990
+ * @summary Validate
21991
+ * @param {OrderValidationRequest} validation_request Validation request
21992
+ * @param {*} [options] Override http request option.
21993
+ * @throws {RequiredError}
21994
+ * @memberof OrderApi
21995
+ */
21996
+ OrderApi.prototype.validateOrder = function (validation_request, options) {
21997
+ return (0, exports.OrderApiFp)(this.configuration).validateOrder(validation_request, options)(this.fetch, this.basePath);
21998
+ };
21908
21999
  return OrderApi;
21909
22000
  }(BaseAPI));
21910
22001
  exports.OrderApi = OrderApi;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ultracart_rest_api_v2_typescript",
3
- "version": "3.10.152",
3
+ "version": "3.10.154",
4
4
  "description": "UltraCart Rest TypeScript SDK",
5
5
  "author": "UltraCart",
6
6
  "keywords": [