@salesforce/lds-adapters-commerce-extensions 1.210.0 → 1.211.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.
@@ -6,7 +6,7 @@ export declare const adapterName = "createMapping";
6
6
  export declare const createMapping_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
7
7
  export interface CreateMappingConfig {
8
8
  epn: string;
9
- id?: string;
9
+ id: string;
10
10
  providerName: string;
11
11
  webstoreId: string;
12
12
  }
@@ -0,0 +1,27 @@
1
+ import { AdapterValidationConfig as adapter$45$utils_AdapterValidationConfig, Untrusted as adapter$45$utils_Untrusted, UncoercedConfiguration as adapter$45$utils_UncoercedConfiguration } from './adapter-utils';
2
+ import { ResourceRequestConfig as resources_getCommerceExtensionProvidersByProviderId_ResourceRequestConfig } from '../resources/getCommerceExtensionProvidersByProviderId';
3
+ import { Luvio as $64$luvio_engine_Luvio, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, Fragment as $64$luvio_engine_Fragment, Snapshot as $64$luvio_engine_Snapshot, FetchResponse as $64$luvio_engine_FetchResponse, ErrorResponse as $64$luvio_engine_ErrorResponse, DispatchResourceRequestContext as $64$luvio_engine_DispatchResourceRequestContext, CoercedAdapterRequestContext as $64$luvio_engine_CoercedAdapterRequestContext, StoreLookup as $64$luvio_engine_StoreLookup, AdapterFactory as $64$luvio_engine_AdapterFactory } from '@luvio/engine';
4
+ import { ProviderOutputRepresentation as types_ProviderOutputRepresentation_ProviderOutputRepresentation, KeyParams as types_ProviderOutputRepresentation_KeyParams } from '../types/ProviderOutputRepresentation';
5
+ export declare const adapterName = "getProvider";
6
+ export declare const getProvider_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
7
+ export interface GetProviderConfig {
8
+ providerId: string;
9
+ }
10
+ export declare function createResourceParams(config: GetProviderConfig): resources_getCommerceExtensionProvidersByProviderId_ResourceRequestConfig;
11
+ export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: GetProviderConfig): string;
12
+ export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: GetProviderConfig): $64$luvio_engine_NormalizedKeyMetadata;
13
+ export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<GetProviderConfig>): adapter$45$utils_Untrusted<GetProviderConfig>;
14
+ export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): GetProviderConfig | null;
15
+ export declare function adapterFragment(luvio: $64$luvio_engine_Luvio, config: GetProviderConfig): $64$luvio_engine_Fragment;
16
+ export declare function buildCachedSnapshot(luvio: $64$luvio_engine_Luvio, config: GetProviderConfig): $64$luvio_engine_Snapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, any>;
17
+ export declare function onFetchResponseSuccess(luvio: $64$luvio_engine_Luvio, config: GetProviderConfig, resourceParams: resources_getCommerceExtensionProvidersByProviderId_ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_ProviderOutputRepresentation_ProviderOutputRepresentation>): Promise<import("@luvio/engine").FulfilledSnapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, any>>;
18
+ export declare function onFetchResponseError(luvio: $64$luvio_engine_Luvio, config: GetProviderConfig, resourceParams: resources_getCommerceExtensionProvidersByProviderId_ResourceRequestConfig, response: $64$luvio_engine_ErrorResponse): Promise<import("@luvio/engine").ErrorSnapshot>;
19
+ export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: GetProviderConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<$64$luvio_engine_Snapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, any>>;
20
+ export type BuildSnapshotContext = {
21
+ luvio: $64$luvio_engine_Luvio;
22
+ config: GetProviderConfig;
23
+ };
24
+ export declare function buildNetworkSnapshotCachePolicy(context: BuildSnapshotContext, coercedAdapterRequestContext: $64$luvio_engine_CoercedAdapterRequestContext): Promise<$64$luvio_engine_Snapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, any>>;
25
+ export declare function buildCachedSnapshotCachePolicy(context: BuildSnapshotContext, storeLookup: $64$luvio_engine_StoreLookup<types_ProviderOutputRepresentation_ProviderOutputRepresentation>): $64$luvio_engine_Snapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, any>;
26
+ export declare const getProviderAdapterFactory: $64$luvio_engine_AdapterFactory<GetProviderConfig, types_ProviderOutputRepresentation_ProviderOutputRepresentation>;
27
+ export declare const notifyChangeFactory: (luvio: $64$luvio_engine_Luvio, options?: $64$luvio_engine_DispatchResourceRequestContext) => (configs: adapter$45$utils_UncoercedConfiguration<types_ProviderOutputRepresentation_KeyParams, any>[]) => void;
@@ -7,7 +7,7 @@ export declare const updateMapping_ConfigPropertyNames: adapter$45$utils_Adapter
7
7
  export interface UpdateMappingConfig {
8
8
  mappingId: string;
9
9
  epn: string;
10
- id?: string;
10
+ id: string;
11
11
  providerName: string;
12
12
  webstoreId: string;
13
13
  }
@@ -5,3 +5,4 @@ export { deleteMappingAdapterFactory } from '../adapters/deleteMapping';
5
5
  export { getMappingAdapterFactory } from '../adapters/getMapping';
6
6
  export { updateMappingAdapterFactory } from '../adapters/updateMapping';
7
7
  export { getProvidersAdapterFactory } from '../adapters/getProviders';
8
+ export { getProviderAdapterFactory } from '../adapters/getProvider';
@@ -4,10 +4,13 @@ declare let getExtensions: any;
4
4
  declare let getMapping: any;
5
5
  declare let getMappingNotifyChange: any;
6
6
  declare let getMappings: any;
7
+ declare let getProvider: any;
8
+ declare let getProviderNotifyChange: any;
7
9
  declare let getProviders: any;
8
10
  declare let updateMapping: any;
9
11
  declare let getExtensions_imperative: any;
10
12
  declare let getMapping_imperative: any;
11
13
  declare let getMappings_imperative: any;
14
+ declare let getProvider_imperative: any;
12
15
  declare let getProviders_imperative: any;
13
- export { createMapping, deleteMapping, getExtensions, getMapping, getMappingNotifyChange, getMappings, getProviders, updateMapping, getExtensions_imperative, getMapping_imperative, getMappings_imperative, getProviders_imperative };
16
+ export { createMapping, deleteMapping, getExtensions, getMapping, getMappingNotifyChange, getMappings, getProvider, getProviderNotifyChange, getProviders, updateMapping, getExtensions_imperative, getMapping_imperative, getMappings_imperative, getProvider_imperative, getProviders_imperative };
@@ -0,0 +1,16 @@
1
+ import { Luvio as $64$luvio_engine_Luvio, Fragment as $64$luvio_engine_Fragment, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, FetchResponse as $64$luvio_engine_FetchResponse, SnapshotRefresh as $64$luvio_engine_SnapshotRefresh, FulfilledSnapshot as $64$luvio_engine_FulfilledSnapshot, StaleSnapshot as $64$luvio_engine_StaleSnapshot, PendingSnapshot as $64$luvio_engine_PendingSnapshot, ErrorResponse as $64$luvio_engine_ErrorResponse, ErrorSnapshot as $64$luvio_engine_ErrorSnapshot, ResourceRequest as $64$luvio_engine_ResourceRequest } from '@luvio/engine';
2
+ import { ProviderOutputRepresentation as types_ProviderOutputRepresentation_ProviderOutputRepresentation } from '../types/ProviderOutputRepresentation';
3
+ export interface ResourceRequestConfig {
4
+ urlParams: {
5
+ providerId: string;
6
+ };
7
+ }
8
+ export declare function select(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_Fragment;
9
+ export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): string;
10
+ export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_NormalizedKeyMetadata;
11
+ export declare function getResponseCacheKeys(storeKeyMap: any, luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: types_ProviderOutputRepresentation_ProviderOutputRepresentation): void;
12
+ export declare function ingestSuccess(luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_ProviderOutputRepresentation_ProviderOutputRepresentation>, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_ProviderOutputRepresentation_ProviderOutputRepresentation>): $64$luvio_engine_FulfilledSnapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, {}> | $64$luvio_engine_StaleSnapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, {}> | $64$luvio_engine_PendingSnapshot<types_ProviderOutputRepresentation_ProviderOutputRepresentation, any>;
13
+ export declare function ingestError(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig, error: $64$luvio_engine_ErrorResponse, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_ProviderOutputRepresentation_ProviderOutputRepresentation>): $64$luvio_engine_ErrorSnapshot;
14
+ export declare function createResourceRequest(config: ResourceRequestConfig): $64$luvio_engine_ResourceRequest;
15
+ export default createResourceRequest;
16
+ export declare function createResourceRequestFromRepresentation(representation: types_ProviderOutputRepresentation_ProviderOutputRepresentation): $64$luvio_engine_ResourceRequest;
@@ -3,7 +3,7 @@ import { MappingOutputRepresentation as types_MappingOutputRepresentation_Mappin
3
3
  export interface ResourceRequestConfig {
4
4
  body: {
5
5
  epn: string;
6
- id?: string;
6
+ id: string;
7
7
  providerName: string;
8
8
  webstoreId: string;
9
9
  };
@@ -6,7 +6,7 @@ export interface ResourceRequestConfig {
6
6
  };
7
7
  body: {
8
8
  epn: string;
9
- id?: string;
9
+ id: string;
10
10
  providerName: string;
11
11
  webstoreId: string;
12
12
  };
@@ -1,6 +1,6 @@
1
1
  import { IngestPath as $64$luvio_engine_IngestPath, Luvio as $64$luvio_engine_Luvio, Store as $64$luvio_engine_Store, FragmentSelection as $64$luvio_engine_FragmentSelection, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
2
2
  export declare const TTL = 60000;
3
- export declare const VERSION = "4a8c0a159a66b5d5ed44fde4dee698a8";
3
+ export declare const VERSION = "3681813e3cc3e527c19b9c433118cfa2";
4
4
  export declare function validate(obj: any, path?: string): TypeError | null;
5
5
  export declare const RepresentationType: string;
6
6
  export declare function normalize(input: MappingInputRepresentation, existing: MappingInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): MappingInputRepresentationNormalized;
@@ -18,7 +18,7 @@ export interface MappingInputRepresentationNormalized {
18
18
  /** The extension this provider corresponds to. */
19
19
  epn: string;
20
20
  /** The unique mapping identifier */
21
- id?: string;
21
+ id: string;
22
22
  /** Unique name of the extension provider. */
23
23
  providerName: string;
24
24
  /** The Id of the webstore this mapping corresponds to. */
@@ -32,7 +32,7 @@ export interface MappingInputRepresentationNormalized {
32
32
  */
33
33
  export interface MappingInputRepresentation {
34
34
  epn: string;
35
- id?: string;
35
+ id: string;
36
36
  providerName: string;
37
37
  webstoreId: string;
38
38
  }
@@ -2,11 +2,11 @@ import { ApexClassOutputRepresentation as ApexClassOutputRepresentation_ApexClas
2
2
  import { EffectiveMappingRepresentation as EffectiveMappingRepresentation_EffectiveMappingRepresentation } from './EffectiveMappingRepresentation';
3
3
  import { KeyMetadata as $64$luvio_engine_KeyMetadata, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata, Luvio as $64$luvio_engine_Luvio, IngestPath as $64$luvio_engine_IngestPath, Store as $64$luvio_engine_Store, FragmentSelection as $64$luvio_engine_FragmentSelection, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap } from '@luvio/engine';
4
4
  export declare const TTL = 60000;
5
- export declare const VERSION = "9e92dd6efb0ca494bcd06a4ad326b6a0";
5
+ export declare const VERSION = "13fc665c9ed137c0ed2ffe53eccfb051";
6
6
  export declare function validate(obj: any, path?: string): TypeError | null;
7
7
  export declare const RepresentationType: string;
8
8
  export interface KeyParams extends $64$luvio_engine_KeyMetadata {
9
- name: string;
9
+ id: string;
10
10
  }
11
11
  export type ProviderOutputRepresentationNormalizedKeyMetadata = KeyParams & $64$luvio_engine_NormalizedKeyMetadata;
12
12
  export type PartialProviderOutputRepresentationNormalizedKeyMetadata = Partial<KeyParams> & $64$luvio_engine_NormalizedKeyMetadata;
@@ -23,15 +23,25 @@ export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableSto
23
23
  * Output representation of a Provider
24
24
  *
25
25
  * Keys:
26
- * name (string): name
26
+ * id (string): id
27
27
  */
28
28
  export interface ProviderOutputRepresentationNormalized {
29
29
  /** Information about the Apex class implementing this Provider */
30
30
  apexClass: ApexClassOutputRepresentation_ApexClassOutputRepresentation;
31
+ /** The URL of the administrative application used to configure the provider. */
32
+ configUrl: string;
33
+ /** Description of the provider. */
34
+ description: string;
31
35
  /** List of mappings this provider is associated with. */
32
36
  effectiveMappings: Array<EffectiveMappingRepresentation_EffectiveMappingRepresentation>;
33
37
  /** The extension this provider corresponds to. */
34
38
  epn: string;
39
+ /** Representing the extension provider. */
40
+ iconUri: string;
41
+ /** The unique provider identifier */
42
+ id: string;
43
+ /** If the extension provider is contained within a managed package. */
44
+ isApplication: boolean;
35
45
  /** Unique name of the extension provider. */
36
46
  name: string;
37
47
  /** The type of extension. */
@@ -41,12 +51,17 @@ export interface ProviderOutputRepresentationNormalized {
41
51
  * Output representation of a Provider
42
52
  *
43
53
  * Keys:
44
- * name (string): name
54
+ * id (string): id
45
55
  */
46
56
  export interface ProviderOutputRepresentation {
47
57
  apexClass: ApexClassOutputRepresentation_ApexClassOutputRepresentation;
58
+ configUrl: string;
59
+ description: string;
48
60
  effectiveMappings: Array<EffectiveMappingRepresentation_EffectiveMappingRepresentation>;
49
61
  epn: string;
62
+ iconUri: string;
63
+ id: string;
64
+ isApplication: boolean;
50
65
  name: string;
51
66
  type: string;
52
67
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/lds-adapters-commerce-extensions",
3
- "version": "1.210.0",
3
+ "version": "1.211.0",
4
4
  "description": "APIs to manage providers for commerce extensions and which will be used for each store.",
5
5
  "license": "SEE LICENSE IN LICENSE.txt",
6
6
  "main": "dist/umd/es2018/commerce-extensions.js",