@salesforce/lds-adapters-revenue-place-quote 1.215.0 → 1.217.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.
@@ -4,7 +4,7 @@
4
4
  * For full license text, see the LICENSE.txt file
5
5
  */
6
6
 
7
- import { serializeStructuredKey, ingestShape, deepFreeze, StoreKeyMap } from '@luvio/engine';
7
+ import { serializeStructuredKey, ingestShape, deepFreeze, StoreKeyMap, createResourceParams as createResourceParams$1 } from '@luvio/engine';
8
8
 
9
9
  const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
10
10
  const { keys: ObjectKeys, create: ObjectCreate } = Object;
@@ -41,10 +41,13 @@ function untrustedIsObject(untrusted) {
41
41
  function areRequiredParametersPresent(config, configPropertyNames) {
42
42
  return configPropertyNames.parameters.required.every(req => req in config);
43
43
  }
44
- function generateParamConfigMetadata(name, required, coerceFn) {
44
+ function generateParamConfigMetadata(name, required, resourceType, typeCheckShape, isArrayShape = false, coerceFn) {
45
45
  return {
46
46
  name,
47
47
  required,
48
+ resourceType,
49
+ typeCheckShape,
50
+ isArrayShape,
48
51
  coerceFn,
49
52
  };
50
53
  }
@@ -245,17 +248,10 @@ function createResourceRequest(config) {
245
248
 
246
249
  const adapterName = 'updateQuote';
247
250
  const updateQuote_ConfigPropertyMetadata = [
248
- generateParamConfigMetadata('PlaceQuoteInput', true),
251
+ generateParamConfigMetadata('PlaceQuoteInput', true, 2 /* Body */, 4 /* Unsupported */),
249
252
  ];
250
253
  const updateQuote_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, updateQuote_ConfigPropertyMetadata);
251
- function createResourceParams(config) {
252
- const resourceParams = {
253
- body: {
254
- PlaceQuoteInput: config.PlaceQuoteInput
255
- }
256
- };
257
- return resourceParams;
258
- }
254
+ const createResourceParams = /*#__PURE__*/ createResourceParams$1(updateQuote_ConfigPropertyMetadata);
259
255
  function typeCheckConfig(untrustedConfig) {
260
256
  const config = {};
261
257
  const untrustedConfig_PlaceQuoteInput = untrustedConfig.PlaceQuoteInput;
@@ -57,6 +57,6 @@ export declare const snapshotRefreshOptions: {
57
57
  export declare function stableJSONStringify(node: any): string | undefined;
58
58
  export declare function getFetchResponseStatusText(status: number): string;
59
59
  export declare function isUnfulfilledSnapshot<T, U>(snapshot: $64$luvio_engine_Snapshot<T, U>): snapshot is $64$luvio_engine_UnfulfilledSnapshot<T, U>;
60
- export declare function generateParamConfigMetadata(name: string, required: boolean, coerceFn?: (v: unknown) => unknown): $64$luvio_engine_AdapterConfigMetadata;
60
+ export declare function generateParamConfigMetadata(name: string, required: boolean, resourceType: $64$luvio_engine_AdapterConfigMetadata['resourceType'], typeCheckShape: $64$luvio_engine_AdapterConfigMetadata['typeCheckShape'], isArrayShape?: boolean, coerceFn?: (v: unknown) => unknown): $64$luvio_engine_AdapterConfigMetadata;
61
61
  export declare function buildAdapterValidationConfig(displayName: string, paramsMeta: $64$luvio_engine_AdapterConfigMetadata[]): AdapterValidationConfig;
62
62
  export declare const keyPrefix = "place-quote";
@@ -9,7 +9,7 @@ export declare const updateQuote_ConfigPropertyNames: adapter$45$utils_AdapterVa
9
9
  export interface UpdateQuoteConfig {
10
10
  PlaceQuoteInput: types_PlaceQuoteInputRepresentation_PlaceQuoteInputRepresentation;
11
11
  }
12
- export declare function createResourceParams(config: UpdateQuoteConfig): resources_postCommerceQuotesActionsPlace_ResourceRequestConfig;
12
+ export declare const createResourceParams: (config: UpdateQuoteConfig) => resources_postCommerceQuotesActionsPlace_ResourceRequestConfig;
13
13
  export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<UpdateQuoteConfig>): adapter$45$utils_Untrusted<UpdateQuoteConfig>;
14
14
  export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): UpdateQuoteConfig | null;
15
15
  export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: UpdateQuoteConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<import("@luvio/engine").FulfilledSnapshot<types_PlaceQuoteOutputRepresentation_PlaceQuoteOutputRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_PlaceQuoteOutputRepresentation_PlaceQuoteOutputRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_PlaceQuoteOutputRepresentation_PlaceQuoteOutputRepresentation, any>>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/lds-adapters-revenue-place-quote",
3
- "version": "1.215.0",
3
+ "version": "1.217.0",
4
4
  "description": "Place Quote API for partial items and price/taxation updates async",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "main": "dist/es/es2018/revenue-place-quote.js",
package/sfdc/index.js CHANGED
@@ -13,7 +13,7 @@
13
13
  */
14
14
  /* proxy-compat-disable */
15
15
  import { withDefaultLuvio } from 'force/ldsEngine';
16
- import { serializeStructuredKey, ingestShape, deepFreeze, StoreKeyMap } from 'force/luvioEngine';
16
+ import { serializeStructuredKey, ingestShape, deepFreeze, StoreKeyMap, createResourceParams as createResourceParams$1 } from 'force/luvioEngine';
17
17
 
18
18
  const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
19
19
  const { keys: ObjectKeys, create: ObjectCreate } = Object;
@@ -50,10 +50,13 @@ function untrustedIsObject(untrusted) {
50
50
  function areRequiredParametersPresent(config, configPropertyNames) {
51
51
  return configPropertyNames.parameters.required.every(req => req in config);
52
52
  }
53
- function generateParamConfigMetadata(name, required, coerceFn) {
53
+ function generateParamConfigMetadata(name, required, resourceType, typeCheckShape, isArrayShape = false, coerceFn) {
54
54
  return {
55
55
  name,
56
56
  required,
57
+ resourceType,
58
+ typeCheckShape,
59
+ isArrayShape,
57
60
  coerceFn,
58
61
  };
59
62
  }
@@ -254,17 +257,10 @@ function createResourceRequest(config) {
254
257
 
255
258
  const adapterName = 'updateQuote';
256
259
  const updateQuote_ConfigPropertyMetadata = [
257
- generateParamConfigMetadata('PlaceQuoteInput', true),
260
+ generateParamConfigMetadata('PlaceQuoteInput', true, 2 /* Body */, 4 /* Unsupported */),
258
261
  ];
259
262
  const updateQuote_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, updateQuote_ConfigPropertyMetadata);
260
- function createResourceParams(config) {
261
- const resourceParams = {
262
- body: {
263
- PlaceQuoteInput: config.PlaceQuoteInput
264
- }
265
- };
266
- return resourceParams;
267
- }
263
+ const createResourceParams = /*#__PURE__*/ createResourceParams$1(updateQuote_ConfigPropertyMetadata);
268
264
  function typeCheckConfig(untrustedConfig) {
269
265
  const config = {};
270
266
  const untrustedConfig_PlaceQuoteInput = untrustedConfig.PlaceQuoteInput;
@@ -334,4 +330,4 @@ withDefaultLuvio((luvio) => {
334
330
  });
335
331
 
336
332
  export { updateQuote };
337
- // version: 1.215.0-dc8d4056e
333
+ // version: 1.217.0-a59ee1de5