@salesforce/lds-adapters-platform-interaction-orchestrator 1.315.0 → 1.316.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/dist/es/es2018/platform-interaction-orchestrator.js +183 -13
- package/dist/es/es2018/types/src/generated/adapters/getOrchestrationInstance.d.ts +27 -0
- package/dist/es/es2018/types/src/generated/artifacts/main.d.ts +1 -0
- package/dist/es/es2018/types/src/generated/artifacts/sfdc.d.ts +3 -1
- package/dist/es/es2018/types/src/generated/resources/getConnectInteractionOrchestrationInstanceDetail.d.ts +15 -0
- package/dist/es/es2018/types/src/generated/types/FlowOrchestrationInstanceRepresentation.d.ts +1 -0
- package/package.json +6 -8
- package/sfdc/index.js +200 -16
- package/src/raml/api.raml +13 -0
- package/src/raml/luvio.raml +8 -0
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$
|
|
7
|
+
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$2, typeCheckConfig as typeCheckConfig$2, StoreKeyMap, createResourceParams as createResourceParams$2 } from '@luvio/engine';
|
|
8
8
|
|
|
9
9
|
const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
|
|
10
10
|
const { keys: ObjectKeys, create: ObjectCreate } = Object;
|
|
@@ -244,7 +244,7 @@ function validate$4(obj, path = 'FlowOrchestrationWorkItemRepresentation') {
|
|
|
244
244
|
})();
|
|
245
245
|
return v_error === undefined ? null : v_error;
|
|
246
246
|
}
|
|
247
|
-
const select$
|
|
247
|
+
const select$6 = function FlowOrchestrationWorkItemRepresentationSelect() {
|
|
248
248
|
return {
|
|
249
249
|
kind: 'Fragment',
|
|
250
250
|
version: VERSION$4,
|
|
@@ -456,8 +456,8 @@ function validate$3(obj, path = 'FlowOrchestrationStepInstanceRepresentation') {
|
|
|
456
456
|
})();
|
|
457
457
|
return v_error === undefined ? null : v_error;
|
|
458
458
|
}
|
|
459
|
-
const select$
|
|
460
|
-
const { selections: FlowOrchestrationWorkItemRepresentation__selections, opaque: FlowOrchestrationWorkItemRepresentation__opaque, } = select$
|
|
459
|
+
const select$5 = function FlowOrchestrationStepInstanceRepresentationSelect() {
|
|
460
|
+
const { selections: FlowOrchestrationWorkItemRepresentation__selections, opaque: FlowOrchestrationWorkItemRepresentation__opaque, } = select$6();
|
|
461
461
|
return {
|
|
462
462
|
kind: 'Fragment',
|
|
463
463
|
version: VERSION$3,
|
|
@@ -617,8 +617,8 @@ function validate$2(obj, path = 'FlowOrchestrationStageInstanceRepresentation')
|
|
|
617
617
|
})();
|
|
618
618
|
return v_error === undefined ? null : v_error;
|
|
619
619
|
}
|
|
620
|
-
const select$
|
|
621
|
-
const { selections: FlowOrchestrationStepInstanceRepresentation__selections, opaque: FlowOrchestrationStepInstanceRepresentation__opaque, } = select$
|
|
620
|
+
const select$4 = function FlowOrchestrationStageInstanceRepresentationSelect() {
|
|
621
|
+
const { selections: FlowOrchestrationStepInstanceRepresentation__selections, opaque: FlowOrchestrationStepInstanceRepresentation__opaque, } = select$5();
|
|
622
622
|
return {
|
|
623
623
|
kind: 'Fragment',
|
|
624
624
|
version: VERSION$2,
|
|
@@ -683,6 +683,7 @@ function equals$2(existing, incoming) {
|
|
|
683
683
|
return true;
|
|
684
684
|
}
|
|
685
685
|
|
|
686
|
+
const TTL$1 = 100;
|
|
686
687
|
const VERSION$1 = "5cd09fe6e4e088f4787a6cf1b9ab7a2a";
|
|
687
688
|
function validate$1(obj, path = 'FlowOrchestrationInstanceRepresentation') {
|
|
688
689
|
const v_error = (() => {
|
|
@@ -821,8 +822,12 @@ function validate$1(obj, path = 'FlowOrchestrationInstanceRepresentation') {
|
|
|
821
822
|
})();
|
|
822
823
|
return v_error === undefined ? null : v_error;
|
|
823
824
|
}
|
|
824
|
-
const
|
|
825
|
-
|
|
825
|
+
const RepresentationType$1 = 'FlowOrchestrationInstanceRepresentation';
|
|
826
|
+
function normalize$1(input, existing, path, luvio, store, timestamp) {
|
|
827
|
+
return input;
|
|
828
|
+
}
|
|
829
|
+
const select$3 = function FlowOrchestrationInstanceRepresentationSelect() {
|
|
830
|
+
const { selections: FlowOrchestrationStageInstanceRepresentation__selections, opaque: FlowOrchestrationStageInstanceRepresentation__opaque, } = select$4();
|
|
826
831
|
return {
|
|
827
832
|
kind: 'Fragment',
|
|
828
833
|
version: VERSION$1,
|
|
@@ -904,6 +909,171 @@ function equals$1(existing, incoming) {
|
|
|
904
909
|
}
|
|
905
910
|
return true;
|
|
906
911
|
}
|
|
912
|
+
const ingest$1 = function FlowOrchestrationInstanceRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
913
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
914
|
+
const validateError = validate$1(input);
|
|
915
|
+
if (validateError !== null) {
|
|
916
|
+
throw validateError;
|
|
917
|
+
}
|
|
918
|
+
}
|
|
919
|
+
const key = path.fullPath;
|
|
920
|
+
const ttlToUse = TTL$1;
|
|
921
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$1, "InteractionOrchestrator", VERSION$1, RepresentationType$1, equals$1);
|
|
922
|
+
return createLink(key);
|
|
923
|
+
};
|
|
924
|
+
function getTypeCacheKeys$1(rootKeySet, luvio, input, fullPathFactory) {
|
|
925
|
+
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
926
|
+
const rootKey = fullPathFactory();
|
|
927
|
+
rootKeySet.set(rootKey, {
|
|
928
|
+
namespace: keyPrefix,
|
|
929
|
+
representationName: RepresentationType$1,
|
|
930
|
+
mergeable: false
|
|
931
|
+
});
|
|
932
|
+
}
|
|
933
|
+
|
|
934
|
+
function select$2(luvio, params) {
|
|
935
|
+
return select$3();
|
|
936
|
+
}
|
|
937
|
+
function keyBuilder$3(luvio, params) {
|
|
938
|
+
return keyPrefix + '::FlowOrchestrationInstanceRepresentation:(' + 'instanceId:' + params.queryParams.instanceId + ')';
|
|
939
|
+
}
|
|
940
|
+
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
941
|
+
getTypeCacheKeys$1(storeKeyMap, luvio, response, () => keyBuilder$3(luvio, resourceParams));
|
|
942
|
+
}
|
|
943
|
+
function ingestSuccess$1(luvio, resourceParams, response, snapshotRefresh) {
|
|
944
|
+
const { body } = response;
|
|
945
|
+
const key = keyBuilder$3(luvio, resourceParams);
|
|
946
|
+
luvio.storeIngest(key, ingest$1, body);
|
|
947
|
+
const snapshot = luvio.storeLookup({
|
|
948
|
+
recordId: key,
|
|
949
|
+
node: select$2(),
|
|
950
|
+
variables: {},
|
|
951
|
+
}, snapshotRefresh);
|
|
952
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
953
|
+
if (snapshot.state !== 'Fulfilled') {
|
|
954
|
+
throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
|
|
955
|
+
}
|
|
956
|
+
}
|
|
957
|
+
deepFreeze(snapshot.data);
|
|
958
|
+
return snapshot;
|
|
959
|
+
}
|
|
960
|
+
function ingestError$1(luvio, params, error, snapshotRefresh) {
|
|
961
|
+
const key = keyBuilder$3(luvio, params);
|
|
962
|
+
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
963
|
+
const storeMetadataParams = {
|
|
964
|
+
ttl: TTL$1,
|
|
965
|
+
namespace: keyPrefix,
|
|
966
|
+
version: VERSION$1,
|
|
967
|
+
representationName: RepresentationType$1
|
|
968
|
+
};
|
|
969
|
+
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
970
|
+
return errorSnapshot;
|
|
971
|
+
}
|
|
972
|
+
function createResourceRequest$1(config) {
|
|
973
|
+
const headers = {};
|
|
974
|
+
return {
|
|
975
|
+
baseUri: '/services/data/v63.0',
|
|
976
|
+
basePath: '/connect/interaction/orchestration/instance/detail',
|
|
977
|
+
method: 'get',
|
|
978
|
+
body: null,
|
|
979
|
+
urlParams: {},
|
|
980
|
+
queryParams: config.queryParams,
|
|
981
|
+
headers,
|
|
982
|
+
priority: 'normal',
|
|
983
|
+
};
|
|
984
|
+
}
|
|
985
|
+
|
|
986
|
+
const adapterName$1 = 'getOrchestrationInstance';
|
|
987
|
+
const oneOfConfigPropertiesIdentifier$1 = [
|
|
988
|
+
'instanceId'
|
|
989
|
+
];
|
|
990
|
+
const getOrchestrationInstance_ConfigPropertyMetadata = [
|
|
991
|
+
generateParamConfigMetadata('instanceId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
992
|
+
];
|
|
993
|
+
const getOrchestrationInstance_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getOrchestrationInstance_ConfigPropertyMetadata);
|
|
994
|
+
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$2(getOrchestrationInstance_ConfigPropertyMetadata);
|
|
995
|
+
function keyBuilder$2(luvio, config) {
|
|
996
|
+
const resourceParams = createResourceParams$1(config);
|
|
997
|
+
return keyBuilder$3(luvio, resourceParams);
|
|
998
|
+
}
|
|
999
|
+
function typeCheckConfig$1(untrustedConfig) {
|
|
1000
|
+
const config = {};
|
|
1001
|
+
typeCheckConfig$2(untrustedConfig, config, getOrchestrationInstance_ConfigPropertyMetadata);
|
|
1002
|
+
return config;
|
|
1003
|
+
}
|
|
1004
|
+
function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
1005
|
+
if (!untrustedIsObject(untrustedConfig)) {
|
|
1006
|
+
return null;
|
|
1007
|
+
}
|
|
1008
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
1009
|
+
validateConfig(untrustedConfig, configPropertyNames, oneOfConfigPropertiesIdentifier$1);
|
|
1010
|
+
}
|
|
1011
|
+
const config = typeCheckConfig$1(untrustedConfig);
|
|
1012
|
+
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
1013
|
+
return null;
|
|
1014
|
+
}
|
|
1015
|
+
if (config.instanceId === undefined) {
|
|
1016
|
+
return null;
|
|
1017
|
+
}
|
|
1018
|
+
return config;
|
|
1019
|
+
}
|
|
1020
|
+
function adapterFragment$1(luvio, config) {
|
|
1021
|
+
createResourceParams$1(config);
|
|
1022
|
+
return select$2();
|
|
1023
|
+
}
|
|
1024
|
+
function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
|
|
1025
|
+
const snapshot = ingestSuccess$1(luvio, resourceParams, response, {
|
|
1026
|
+
config,
|
|
1027
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
1028
|
+
});
|
|
1029
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
1030
|
+
}
|
|
1031
|
+
function onFetchResponseError$1(luvio, config, resourceParams, response) {
|
|
1032
|
+
const snapshot = ingestError$1(luvio, resourceParams, response, {
|
|
1033
|
+
config,
|
|
1034
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
1035
|
+
});
|
|
1036
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
1037
|
+
}
|
|
1038
|
+
function buildNetworkSnapshot$1(luvio, config, options) {
|
|
1039
|
+
const resourceParams = createResourceParams$1(config);
|
|
1040
|
+
const request = createResourceRequest$1(resourceParams);
|
|
1041
|
+
return luvio.dispatchResourceRequest(request, options)
|
|
1042
|
+
.then((response) => {
|
|
1043
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
|
|
1044
|
+
const cache = new StoreKeyMap();
|
|
1045
|
+
getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
|
|
1046
|
+
return cache;
|
|
1047
|
+
});
|
|
1048
|
+
}, (response) => {
|
|
1049
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$1(luvio, config, resourceParams, response));
|
|
1050
|
+
});
|
|
1051
|
+
}
|
|
1052
|
+
function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
|
|
1053
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot$1, undefined, false);
|
|
1054
|
+
}
|
|
1055
|
+
function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
|
|
1056
|
+
const { luvio, config } = context;
|
|
1057
|
+
const selector = {
|
|
1058
|
+
recordId: keyBuilder$2(luvio, config),
|
|
1059
|
+
node: adapterFragment$1(luvio, config),
|
|
1060
|
+
variables: {},
|
|
1061
|
+
};
|
|
1062
|
+
const cacheSnapshot = storeLookup(selector, {
|
|
1063
|
+
config,
|
|
1064
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
1065
|
+
});
|
|
1066
|
+
return cacheSnapshot;
|
|
1067
|
+
}
|
|
1068
|
+
const getOrchestrationInstanceAdapterFactory = (luvio) => function InteractionOrchestrator__getOrchestrationInstance(untrustedConfig, requestContext) {
|
|
1069
|
+
const config = validateAdapterConfig$1(untrustedConfig, getOrchestrationInstance_ConfigPropertyNames);
|
|
1070
|
+
// Invalid or incomplete config
|
|
1071
|
+
if (config === null) {
|
|
1072
|
+
return null;
|
|
1073
|
+
}
|
|
1074
|
+
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
1075
|
+
buildCachedSnapshotCachePolicy$1, buildNetworkSnapshotCachePolicy$1);
|
|
1076
|
+
};
|
|
907
1077
|
|
|
908
1078
|
const TTL = 100;
|
|
909
1079
|
const VERSION = "ff1028f6e4a6a9aeed322135fdf518b5";
|
|
@@ -935,7 +1105,7 @@ function normalize(input, existing, path, luvio, store, timestamp) {
|
|
|
935
1105
|
return input;
|
|
936
1106
|
}
|
|
937
1107
|
const select$1 = function FlowOrchestrationInstanceCollectionRepresentationSelect() {
|
|
938
|
-
const { selections: FlowOrchestrationInstanceRepresentation__selections, opaque: FlowOrchestrationInstanceRepresentation__opaque, } = select$
|
|
1108
|
+
const { selections: FlowOrchestrationInstanceRepresentation__selections, opaque: FlowOrchestrationInstanceRepresentation__opaque, } = select$3();
|
|
939
1109
|
return {
|
|
940
1110
|
kind: 'Fragment',
|
|
941
1111
|
version: VERSION,
|
|
@@ -1046,14 +1216,14 @@ const getOrchestrationInstanceCollection_ConfigPropertyMetadata = [
|
|
|
1046
1216
|
generateParamConfigMetadata('relatedRecordId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
1047
1217
|
];
|
|
1048
1218
|
const getOrchestrationInstanceCollection_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getOrchestrationInstanceCollection_ConfigPropertyMetadata);
|
|
1049
|
-
const createResourceParams = /*#__PURE__*/ createResourceParams$
|
|
1219
|
+
const createResourceParams = /*#__PURE__*/ createResourceParams$2(getOrchestrationInstanceCollection_ConfigPropertyMetadata);
|
|
1050
1220
|
function keyBuilder(luvio, config) {
|
|
1051
1221
|
const resourceParams = createResourceParams(config);
|
|
1052
1222
|
return keyBuilder$1(luvio, resourceParams);
|
|
1053
1223
|
}
|
|
1054
1224
|
function typeCheckConfig(untrustedConfig) {
|
|
1055
1225
|
const config = {};
|
|
1056
|
-
typeCheckConfig$
|
|
1226
|
+
typeCheckConfig$2(untrustedConfig, config, getOrchestrationInstanceCollection_ConfigPropertyMetadata);
|
|
1057
1227
|
return config;
|
|
1058
1228
|
}
|
|
1059
1229
|
function validateAdapterConfig(untrustedConfig, configPropertyNames) {
|
|
@@ -1105,7 +1275,7 @@ function buildNetworkSnapshot(luvio, config, options) {
|
|
|
1105
1275
|
});
|
|
1106
1276
|
}
|
|
1107
1277
|
function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
|
|
1108
|
-
return buildNetworkSnapshotCachePolicy$
|
|
1278
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot, undefined, false);
|
|
1109
1279
|
}
|
|
1110
1280
|
function buildCachedSnapshotCachePolicy(context, storeLookup) {
|
|
1111
1281
|
const { luvio, config } = context;
|
|
@@ -1130,4 +1300,4 @@ const getOrchestrationInstanceCollectionAdapterFactory = (luvio) => function Int
|
|
|
1130
1300
|
buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
|
|
1131
1301
|
};
|
|
1132
1302
|
|
|
1133
|
-
export { getOrchestrationInstanceCollectionAdapterFactory };
|
|
1303
|
+
export { getOrchestrationInstanceAdapterFactory, getOrchestrationInstanceCollectionAdapterFactory };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { AdapterConfigMetadata as $64$luvio_engine_AdapterConfigMetadata, 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';
|
|
2
|
+
import { Untrusted as adapter$45$utils_Untrusted, AdapterValidationConfig as adapter$45$utils_AdapterValidationConfig } from './adapter-utils';
|
|
3
|
+
import { ResourceRequestConfig as resources_getConnectInteractionOrchestrationInstanceDetail_ResourceRequestConfig } from '../resources/getConnectInteractionOrchestrationInstanceDetail';
|
|
4
|
+
import { FlowOrchestrationInstanceRepresentation as types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation } from '../types/FlowOrchestrationInstanceRepresentation';
|
|
5
|
+
export declare const adapterName = "getOrchestrationInstance";
|
|
6
|
+
export declare const getOrchestrationInstance_ConfigPropertyMetadata: $64$luvio_engine_AdapterConfigMetadata[];
|
|
7
|
+
export declare const getOrchestrationInstance_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
|
|
8
|
+
export interface GetOrchestrationInstanceConfig {
|
|
9
|
+
instanceId?: string;
|
|
10
|
+
}
|
|
11
|
+
export declare const createResourceParams: (config: GetOrchestrationInstanceConfig) => resources_getConnectInteractionOrchestrationInstanceDetail_ResourceRequestConfig;
|
|
12
|
+
export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: GetOrchestrationInstanceConfig): string;
|
|
13
|
+
export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: GetOrchestrationInstanceConfig): $64$luvio_engine_NormalizedKeyMetadata;
|
|
14
|
+
export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<GetOrchestrationInstanceConfig>): adapter$45$utils_Untrusted<GetOrchestrationInstanceConfig>;
|
|
15
|
+
export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): GetOrchestrationInstanceConfig | null;
|
|
16
|
+
export declare function adapterFragment(luvio: $64$luvio_engine_Luvio, config: GetOrchestrationInstanceConfig): $64$luvio_engine_Fragment;
|
|
17
|
+
export declare function buildCachedSnapshot(luvio: $64$luvio_engine_Luvio, config: GetOrchestrationInstanceConfig): $64$luvio_engine_Snapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, any>;
|
|
18
|
+
export declare function onFetchResponseSuccess(luvio: $64$luvio_engine_Luvio, config: GetOrchestrationInstanceConfig, resourceParams: resources_getConnectInteractionOrchestrationInstanceDetail_ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation>): Promise<import("@luvio/engine").FulfilledSnapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, any>>;
|
|
19
|
+
export declare function onFetchResponseError(luvio: $64$luvio_engine_Luvio, config: GetOrchestrationInstanceConfig, resourceParams: resources_getConnectInteractionOrchestrationInstanceDetail_ResourceRequestConfig, response: $64$luvio_engine_ErrorResponse): Promise<import("@luvio/engine").ErrorSnapshot>;
|
|
20
|
+
export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: GetOrchestrationInstanceConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<$64$luvio_engine_Snapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, any>>;
|
|
21
|
+
export type BuildSnapshotContext = {
|
|
22
|
+
luvio: $64$luvio_engine_Luvio;
|
|
23
|
+
config: GetOrchestrationInstanceConfig;
|
|
24
|
+
};
|
|
25
|
+
export declare function buildNetworkSnapshotCachePolicy(context: BuildSnapshotContext, coercedAdapterRequestContext: $64$luvio_engine_CoercedAdapterRequestContext): Promise<$64$luvio_engine_Snapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, any>>;
|
|
26
|
+
export declare function buildCachedSnapshotCachePolicy(context: BuildSnapshotContext, storeLookup: $64$luvio_engine_StoreLookup<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation>): $64$luvio_engine_Snapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, any>;
|
|
27
|
+
export declare const getOrchestrationInstanceAdapterFactory: $64$luvio_engine_AdapterFactory<GetOrchestrationInstanceConfig, types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation>;
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
declare let getOrchestrationInstance: any;
|
|
1
2
|
declare let getOrchestrationInstanceCollection: any;
|
|
3
|
+
declare let getOrchestrationInstance_imperative: any;
|
|
2
4
|
declare let getOrchestrationInstanceCollection_imperative: any;
|
|
3
|
-
export { getOrchestrationInstanceCollection, getOrchestrationInstanceCollection_imperative };
|
|
5
|
+
export { getOrchestrationInstance, getOrchestrationInstanceCollection, getOrchestrationInstance_imperative, getOrchestrationInstanceCollection_imperative, };
|
|
@@ -0,0 +1,15 @@
|
|
|
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 { FlowOrchestrationInstanceRepresentation as types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation } from '../types/FlowOrchestrationInstanceRepresentation';
|
|
3
|
+
export interface ResourceRequestConfig {
|
|
4
|
+
queryParams: {
|
|
5
|
+
instanceId?: 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_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation): void;
|
|
12
|
+
export declare function ingestSuccess(luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation>, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation>): $64$luvio_engine_FulfilledSnapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, {}> | $64$luvio_engine_StaleSnapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, {}> | $64$luvio_engine_PendingSnapshot<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation, any>;
|
|
13
|
+
export declare function ingestError(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig, error: $64$luvio_engine_ErrorResponse, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_FlowOrchestrationInstanceRepresentation_FlowOrchestrationInstanceRepresentation>): $64$luvio_engine_ErrorSnapshot;
|
|
14
|
+
export declare function createResourceRequest(config: ResourceRequestConfig): $64$luvio_engine_ResourceRequest;
|
|
15
|
+
export default createResourceRequest;
|
package/dist/es/es2018/types/src/generated/types/FlowOrchestrationInstanceRepresentation.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { FlowOrchestrationStageInstanceRepresentation as FlowOrchestrationStageInstanceRepresentation_FlowOrchestrationStageInstanceRepresentation } from './FlowOrchestrationStageInstanceRepresentation';
|
|
2
2
|
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';
|
|
3
|
+
export declare const TTL = 100;
|
|
3
4
|
export declare const VERSION = "5cd09fe6e4e088f4787a6cf1b9ab7a2a";
|
|
4
5
|
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
5
6
|
export declare const RepresentationType: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-adapters-platform-interaction-orchestrator",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.316.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "Interaction Orchestrator APIs",
|
|
6
6
|
"main": "dist/es/es2018/platform-interaction-orchestrator.js",
|
|
@@ -32,21 +32,19 @@
|
|
|
32
32
|
"module": "platformInteractionOrchestratorApi"
|
|
33
33
|
},
|
|
34
34
|
"scripts": {
|
|
35
|
-
"build": "yarn build:services",
|
|
36
|
-
"build:karma": "rollup --bundleConfigAsCjs --config rollup.config.karma.js",
|
|
35
|
+
"build": "yarn build:raml && yarn build:services",
|
|
37
36
|
"build:raml": "luvio generate src/raml/luvio.raml src/generated -p '../lds-compiler-plugins'",
|
|
38
37
|
"build:services": "rollup --bundleConfigAsCjs --config rollup.config.js",
|
|
39
38
|
"clean": "rm -rf dist sfdc src/generated karma/dist",
|
|
40
|
-
"
|
|
41
|
-
"test": "nx build:karma && karma start --single-run",
|
|
39
|
+
"test:unit": "jest --config=./jest.config.js",
|
|
42
40
|
"release:core": "../../scripts/release/core.js --adapter=lds-adapters-platform-interaction-orchestrator"
|
|
43
41
|
},
|
|
44
42
|
"dependencies": {
|
|
45
|
-
"@salesforce/lds-bindings": "^1.
|
|
43
|
+
"@salesforce/lds-bindings": "^1.316.0"
|
|
46
44
|
},
|
|
47
45
|
"devDependencies": {
|
|
48
|
-
"@salesforce/lds-compiler-plugins": "^1.
|
|
49
|
-
"@salesforce/lds-karma": "^1.
|
|
46
|
+
"@salesforce/lds-compiler-plugins": "^1.316.0",
|
|
47
|
+
"@salesforce/lds-karma": "^1.316.0"
|
|
50
48
|
},
|
|
51
49
|
"nx": {
|
|
52
50
|
"targets": {
|
package/sfdc/index.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
/* proxy-compat-disable */
|
|
15
15
|
import { createInstrumentedAdapter, createLDSAdapter, createWireAdapterConstructor, createImperativeAdapter } from 'force/ldsBindings';
|
|
16
16
|
import { withDefaultLuvio } from 'force/ldsEngine';
|
|
17
|
-
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$
|
|
17
|
+
import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$2, typeCheckConfig as typeCheckConfig$2, StoreKeyMap, createResourceParams as createResourceParams$2 } from 'force/luvioEngine';
|
|
18
18
|
|
|
19
19
|
const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
|
|
20
20
|
const { keys: ObjectKeys, create: ObjectCreate } = Object;
|
|
@@ -254,7 +254,7 @@ function validate$4(obj, path = 'FlowOrchestrationWorkItemRepresentation') {
|
|
|
254
254
|
})();
|
|
255
255
|
return v_error === undefined ? null : v_error;
|
|
256
256
|
}
|
|
257
|
-
const select$
|
|
257
|
+
const select$6 = function FlowOrchestrationWorkItemRepresentationSelect() {
|
|
258
258
|
return {
|
|
259
259
|
kind: 'Fragment',
|
|
260
260
|
version: VERSION$4,
|
|
@@ -466,8 +466,8 @@ function validate$3(obj, path = 'FlowOrchestrationStepInstanceRepresentation') {
|
|
|
466
466
|
})();
|
|
467
467
|
return v_error === undefined ? null : v_error;
|
|
468
468
|
}
|
|
469
|
-
const select$
|
|
470
|
-
const { selections: FlowOrchestrationWorkItemRepresentation__selections, opaque: FlowOrchestrationWorkItemRepresentation__opaque, } = select$
|
|
469
|
+
const select$5 = function FlowOrchestrationStepInstanceRepresentationSelect() {
|
|
470
|
+
const { selections: FlowOrchestrationWorkItemRepresentation__selections, opaque: FlowOrchestrationWorkItemRepresentation__opaque, } = select$6();
|
|
471
471
|
return {
|
|
472
472
|
kind: 'Fragment',
|
|
473
473
|
version: VERSION$3,
|
|
@@ -627,8 +627,8 @@ function validate$2(obj, path = 'FlowOrchestrationStageInstanceRepresentation')
|
|
|
627
627
|
})();
|
|
628
628
|
return v_error === undefined ? null : v_error;
|
|
629
629
|
}
|
|
630
|
-
const select$
|
|
631
|
-
const { selections: FlowOrchestrationStepInstanceRepresentation__selections, opaque: FlowOrchestrationStepInstanceRepresentation__opaque, } = select$
|
|
630
|
+
const select$4 = function FlowOrchestrationStageInstanceRepresentationSelect() {
|
|
631
|
+
const { selections: FlowOrchestrationStepInstanceRepresentation__selections, opaque: FlowOrchestrationStepInstanceRepresentation__opaque, } = select$5();
|
|
632
632
|
return {
|
|
633
633
|
kind: 'Fragment',
|
|
634
634
|
version: VERSION$2,
|
|
@@ -693,6 +693,7 @@ function equals$2(existing, incoming) {
|
|
|
693
693
|
return true;
|
|
694
694
|
}
|
|
695
695
|
|
|
696
|
+
const TTL$1 = 100;
|
|
696
697
|
const VERSION$1 = "5cd09fe6e4e088f4787a6cf1b9ab7a2a";
|
|
697
698
|
function validate$1(obj, path = 'FlowOrchestrationInstanceRepresentation') {
|
|
698
699
|
const v_error = (() => {
|
|
@@ -831,8 +832,12 @@ function validate$1(obj, path = 'FlowOrchestrationInstanceRepresentation') {
|
|
|
831
832
|
})();
|
|
832
833
|
return v_error === undefined ? null : v_error;
|
|
833
834
|
}
|
|
834
|
-
const
|
|
835
|
-
|
|
835
|
+
const RepresentationType$1 = 'FlowOrchestrationInstanceRepresentation';
|
|
836
|
+
function normalize$1(input, existing, path, luvio, store, timestamp) {
|
|
837
|
+
return input;
|
|
838
|
+
}
|
|
839
|
+
const select$3 = function FlowOrchestrationInstanceRepresentationSelect() {
|
|
840
|
+
const { selections: FlowOrchestrationStageInstanceRepresentation__selections, opaque: FlowOrchestrationStageInstanceRepresentation__opaque, } = select$4();
|
|
836
841
|
return {
|
|
837
842
|
kind: 'Fragment',
|
|
838
843
|
version: VERSION$1,
|
|
@@ -914,6 +919,171 @@ function equals$1(existing, incoming) {
|
|
|
914
919
|
}
|
|
915
920
|
return true;
|
|
916
921
|
}
|
|
922
|
+
const ingest$1 = function FlowOrchestrationInstanceRepresentationIngest(input, path, luvio, store, timestamp) {
|
|
923
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
924
|
+
const validateError = validate$1(input);
|
|
925
|
+
if (validateError !== null) {
|
|
926
|
+
throw validateError;
|
|
927
|
+
}
|
|
928
|
+
}
|
|
929
|
+
const key = path.fullPath;
|
|
930
|
+
const ttlToUse = TTL$1;
|
|
931
|
+
ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$1, "InteractionOrchestrator", VERSION$1, RepresentationType$1, equals$1);
|
|
932
|
+
return createLink(key);
|
|
933
|
+
};
|
|
934
|
+
function getTypeCacheKeys$1(rootKeySet, luvio, input, fullPathFactory) {
|
|
935
|
+
// root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
|
|
936
|
+
const rootKey = fullPathFactory();
|
|
937
|
+
rootKeySet.set(rootKey, {
|
|
938
|
+
namespace: keyPrefix,
|
|
939
|
+
representationName: RepresentationType$1,
|
|
940
|
+
mergeable: false
|
|
941
|
+
});
|
|
942
|
+
}
|
|
943
|
+
|
|
944
|
+
function select$2(luvio, params) {
|
|
945
|
+
return select$3();
|
|
946
|
+
}
|
|
947
|
+
function keyBuilder$3(luvio, params) {
|
|
948
|
+
return keyPrefix + '::FlowOrchestrationInstanceRepresentation:(' + 'instanceId:' + params.queryParams.instanceId + ')';
|
|
949
|
+
}
|
|
950
|
+
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
951
|
+
getTypeCacheKeys$1(storeKeyMap, luvio, response, () => keyBuilder$3(luvio, resourceParams));
|
|
952
|
+
}
|
|
953
|
+
function ingestSuccess$1(luvio, resourceParams, response, snapshotRefresh) {
|
|
954
|
+
const { body } = response;
|
|
955
|
+
const key = keyBuilder$3(luvio, resourceParams);
|
|
956
|
+
luvio.storeIngest(key, ingest$1, body);
|
|
957
|
+
const snapshot = luvio.storeLookup({
|
|
958
|
+
recordId: key,
|
|
959
|
+
node: select$2(),
|
|
960
|
+
variables: {},
|
|
961
|
+
}, snapshotRefresh);
|
|
962
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
963
|
+
if (snapshot.state !== 'Fulfilled') {
|
|
964
|
+
throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
|
|
965
|
+
}
|
|
966
|
+
}
|
|
967
|
+
deepFreeze(snapshot.data);
|
|
968
|
+
return snapshot;
|
|
969
|
+
}
|
|
970
|
+
function ingestError$1(luvio, params, error, snapshotRefresh) {
|
|
971
|
+
const key = keyBuilder$3(luvio, params);
|
|
972
|
+
const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
|
|
973
|
+
const storeMetadataParams = {
|
|
974
|
+
ttl: TTL$1,
|
|
975
|
+
namespace: keyPrefix,
|
|
976
|
+
version: VERSION$1,
|
|
977
|
+
representationName: RepresentationType$1
|
|
978
|
+
};
|
|
979
|
+
luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
|
|
980
|
+
return errorSnapshot;
|
|
981
|
+
}
|
|
982
|
+
function createResourceRequest$1(config) {
|
|
983
|
+
const headers = {};
|
|
984
|
+
return {
|
|
985
|
+
baseUri: '/services/data/v63.0',
|
|
986
|
+
basePath: '/connect/interaction/orchestration/instance/detail',
|
|
987
|
+
method: 'get',
|
|
988
|
+
body: null,
|
|
989
|
+
urlParams: {},
|
|
990
|
+
queryParams: config.queryParams,
|
|
991
|
+
headers,
|
|
992
|
+
priority: 'normal',
|
|
993
|
+
};
|
|
994
|
+
}
|
|
995
|
+
|
|
996
|
+
const adapterName$1 = 'getOrchestrationInstance';
|
|
997
|
+
const oneOfConfigPropertiesIdentifier$1 = [
|
|
998
|
+
'instanceId'
|
|
999
|
+
];
|
|
1000
|
+
const getOrchestrationInstance_ConfigPropertyMetadata = [
|
|
1001
|
+
generateParamConfigMetadata('instanceId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
1002
|
+
];
|
|
1003
|
+
const getOrchestrationInstance_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getOrchestrationInstance_ConfigPropertyMetadata);
|
|
1004
|
+
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$2(getOrchestrationInstance_ConfigPropertyMetadata);
|
|
1005
|
+
function keyBuilder$2(luvio, config) {
|
|
1006
|
+
const resourceParams = createResourceParams$1(config);
|
|
1007
|
+
return keyBuilder$3(luvio, resourceParams);
|
|
1008
|
+
}
|
|
1009
|
+
function typeCheckConfig$1(untrustedConfig) {
|
|
1010
|
+
const config = {};
|
|
1011
|
+
typeCheckConfig$2(untrustedConfig, config, getOrchestrationInstance_ConfigPropertyMetadata);
|
|
1012
|
+
return config;
|
|
1013
|
+
}
|
|
1014
|
+
function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
1015
|
+
if (!untrustedIsObject(untrustedConfig)) {
|
|
1016
|
+
return null;
|
|
1017
|
+
}
|
|
1018
|
+
if (process.env.NODE_ENV !== 'production') {
|
|
1019
|
+
validateConfig(untrustedConfig, configPropertyNames, oneOfConfigPropertiesIdentifier$1);
|
|
1020
|
+
}
|
|
1021
|
+
const config = typeCheckConfig$1(untrustedConfig);
|
|
1022
|
+
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
1023
|
+
return null;
|
|
1024
|
+
}
|
|
1025
|
+
if (config.instanceId === undefined) {
|
|
1026
|
+
return null;
|
|
1027
|
+
}
|
|
1028
|
+
return config;
|
|
1029
|
+
}
|
|
1030
|
+
function adapterFragment$1(luvio, config) {
|
|
1031
|
+
createResourceParams$1(config);
|
|
1032
|
+
return select$2();
|
|
1033
|
+
}
|
|
1034
|
+
function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
|
|
1035
|
+
const snapshot = ingestSuccess$1(luvio, resourceParams, response, {
|
|
1036
|
+
config,
|
|
1037
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
1038
|
+
});
|
|
1039
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
1040
|
+
}
|
|
1041
|
+
function onFetchResponseError$1(luvio, config, resourceParams, response) {
|
|
1042
|
+
const snapshot = ingestError$1(luvio, resourceParams, response, {
|
|
1043
|
+
config,
|
|
1044
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
1045
|
+
});
|
|
1046
|
+
return luvio.storeBroadcast().then(() => snapshot);
|
|
1047
|
+
}
|
|
1048
|
+
function buildNetworkSnapshot$1(luvio, config, options) {
|
|
1049
|
+
const resourceParams = createResourceParams$1(config);
|
|
1050
|
+
const request = createResourceRequest$1(resourceParams);
|
|
1051
|
+
return luvio.dispatchResourceRequest(request, options)
|
|
1052
|
+
.then((response) => {
|
|
1053
|
+
return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => {
|
|
1054
|
+
const cache = new StoreKeyMap();
|
|
1055
|
+
getResponseCacheKeys$1(cache, luvio, resourceParams, response.body);
|
|
1056
|
+
return cache;
|
|
1057
|
+
});
|
|
1058
|
+
}, (response) => {
|
|
1059
|
+
return luvio.handleErrorResponse(() => onFetchResponseError$1(luvio, config, resourceParams, response));
|
|
1060
|
+
});
|
|
1061
|
+
}
|
|
1062
|
+
function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
|
|
1063
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot$1, undefined, false);
|
|
1064
|
+
}
|
|
1065
|
+
function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
|
|
1066
|
+
const { luvio, config } = context;
|
|
1067
|
+
const selector = {
|
|
1068
|
+
recordId: keyBuilder$2(luvio, config),
|
|
1069
|
+
node: adapterFragment$1(luvio, config),
|
|
1070
|
+
variables: {},
|
|
1071
|
+
};
|
|
1072
|
+
const cacheSnapshot = storeLookup(selector, {
|
|
1073
|
+
config,
|
|
1074
|
+
resolve: () => buildNetworkSnapshot$1(luvio, config, snapshotRefreshOptions)
|
|
1075
|
+
});
|
|
1076
|
+
return cacheSnapshot;
|
|
1077
|
+
}
|
|
1078
|
+
const getOrchestrationInstanceAdapterFactory = (luvio) => function InteractionOrchestrator__getOrchestrationInstance(untrustedConfig, requestContext) {
|
|
1079
|
+
const config = validateAdapterConfig$1(untrustedConfig, getOrchestrationInstance_ConfigPropertyNames);
|
|
1080
|
+
// Invalid or incomplete config
|
|
1081
|
+
if (config === null) {
|
|
1082
|
+
return null;
|
|
1083
|
+
}
|
|
1084
|
+
return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
|
|
1085
|
+
buildCachedSnapshotCachePolicy$1, buildNetworkSnapshotCachePolicy$1);
|
|
1086
|
+
};
|
|
917
1087
|
|
|
918
1088
|
const TTL = 100;
|
|
919
1089
|
const VERSION = "ff1028f6e4a6a9aeed322135fdf518b5";
|
|
@@ -945,7 +1115,7 @@ function normalize(input, existing, path, luvio, store, timestamp) {
|
|
|
945
1115
|
return input;
|
|
946
1116
|
}
|
|
947
1117
|
const select$1 = function FlowOrchestrationInstanceCollectionRepresentationSelect() {
|
|
948
|
-
const { selections: FlowOrchestrationInstanceRepresentation__selections, opaque: FlowOrchestrationInstanceRepresentation__opaque, } = select$
|
|
1118
|
+
const { selections: FlowOrchestrationInstanceRepresentation__selections, opaque: FlowOrchestrationInstanceRepresentation__opaque, } = select$3();
|
|
949
1119
|
return {
|
|
950
1120
|
kind: 'Fragment',
|
|
951
1121
|
version: VERSION,
|
|
@@ -1056,14 +1226,14 @@ const getOrchestrationInstanceCollection_ConfigPropertyMetadata = [
|
|
|
1056
1226
|
generateParamConfigMetadata('relatedRecordId', false, 1 /* QueryParameter */, 0 /* String */),
|
|
1057
1227
|
];
|
|
1058
1228
|
const getOrchestrationInstanceCollection_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getOrchestrationInstanceCollection_ConfigPropertyMetadata);
|
|
1059
|
-
const createResourceParams = /*#__PURE__*/ createResourceParams$
|
|
1229
|
+
const createResourceParams = /*#__PURE__*/ createResourceParams$2(getOrchestrationInstanceCollection_ConfigPropertyMetadata);
|
|
1060
1230
|
function keyBuilder(luvio, config) {
|
|
1061
1231
|
const resourceParams = createResourceParams(config);
|
|
1062
1232
|
return keyBuilder$1(luvio, resourceParams);
|
|
1063
1233
|
}
|
|
1064
1234
|
function typeCheckConfig(untrustedConfig) {
|
|
1065
1235
|
const config = {};
|
|
1066
|
-
typeCheckConfig$
|
|
1236
|
+
typeCheckConfig$2(untrustedConfig, config, getOrchestrationInstanceCollection_ConfigPropertyMetadata);
|
|
1067
1237
|
return config;
|
|
1068
1238
|
}
|
|
1069
1239
|
function validateAdapterConfig(untrustedConfig, configPropertyNames) {
|
|
@@ -1115,7 +1285,7 @@ function buildNetworkSnapshot(luvio, config, options) {
|
|
|
1115
1285
|
});
|
|
1116
1286
|
}
|
|
1117
1287
|
function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
|
|
1118
|
-
return buildNetworkSnapshotCachePolicy$
|
|
1288
|
+
return buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext, buildNetworkSnapshot, undefined, false);
|
|
1119
1289
|
}
|
|
1120
1290
|
function buildCachedSnapshotCachePolicy(context, storeLookup) {
|
|
1121
1291
|
const { luvio, config } = context;
|
|
@@ -1140,10 +1310,17 @@ const getOrchestrationInstanceCollectionAdapterFactory = (luvio) => function Int
|
|
|
1140
1310
|
buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
|
|
1141
1311
|
};
|
|
1142
1312
|
|
|
1313
|
+
let getOrchestrationInstance;
|
|
1143
1314
|
let getOrchestrationInstanceCollection;
|
|
1144
1315
|
// Imperative GET Adapters
|
|
1316
|
+
let getOrchestrationInstance_imperative;
|
|
1145
1317
|
let getOrchestrationInstanceCollection_imperative;
|
|
1146
1318
|
// Adapter Metadata
|
|
1319
|
+
const getOrchestrationInstanceMetadata = {
|
|
1320
|
+
apiFamily: 'InteractionOrchestrator',
|
|
1321
|
+
name: 'getOrchestrationInstance',
|
|
1322
|
+
ttl: 100,
|
|
1323
|
+
};
|
|
1147
1324
|
const getOrchestrationInstanceCollectionMetadata = {
|
|
1148
1325
|
apiFamily: 'InteractionOrchestrator',
|
|
1149
1326
|
name: 'getOrchestrationInstanceCollection',
|
|
@@ -1152,18 +1329,25 @@ const getOrchestrationInstanceCollectionMetadata = {
|
|
|
1152
1329
|
// Notify Update Available
|
|
1153
1330
|
function bindExportsTo(luvio) {
|
|
1154
1331
|
// LDS Adapters
|
|
1332
|
+
const getOrchestrationInstance_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getOrchestrationInstance', getOrchestrationInstanceAdapterFactory), getOrchestrationInstanceMetadata);
|
|
1155
1333
|
const getOrchestrationInstanceCollection_ldsAdapter = createInstrumentedAdapter(createLDSAdapter(luvio, 'getOrchestrationInstanceCollection', getOrchestrationInstanceCollectionAdapterFactory), getOrchestrationInstanceCollectionMetadata);
|
|
1156
1334
|
return {
|
|
1335
|
+
getOrchestrationInstance: createWireAdapterConstructor(luvio, getOrchestrationInstance_ldsAdapter, getOrchestrationInstanceMetadata),
|
|
1157
1336
|
getOrchestrationInstanceCollection: createWireAdapterConstructor(luvio, getOrchestrationInstanceCollection_ldsAdapter, getOrchestrationInstanceCollectionMetadata),
|
|
1158
1337
|
// Imperative GET Adapters
|
|
1338
|
+
getOrchestrationInstance_imperative: createImperativeAdapter(luvio, getOrchestrationInstance_ldsAdapter, getOrchestrationInstanceMetadata),
|
|
1159
1339
|
getOrchestrationInstanceCollection_imperative: createImperativeAdapter(luvio, getOrchestrationInstanceCollection_ldsAdapter, getOrchestrationInstanceCollectionMetadata),
|
|
1160
1340
|
// Notify Update Availables
|
|
1161
1341
|
};
|
|
1162
1342
|
}
|
|
1163
1343
|
withDefaultLuvio((luvio) => {
|
|
1164
|
-
({
|
|
1165
|
-
|
|
1344
|
+
({
|
|
1345
|
+
getOrchestrationInstance,
|
|
1346
|
+
getOrchestrationInstanceCollection,
|
|
1347
|
+
getOrchestrationInstance_imperative,
|
|
1348
|
+
getOrchestrationInstanceCollection_imperative,
|
|
1349
|
+
} = bindExportsTo(luvio));
|
|
1166
1350
|
});
|
|
1167
1351
|
|
|
1168
|
-
export { getOrchestrationInstanceCollection, getOrchestrationInstanceCollection_imperative };
|
|
1169
|
-
// version: 1.
|
|
1352
|
+
export { getOrchestrationInstance, getOrchestrationInstanceCollection, getOrchestrationInstanceCollection_imperative, getOrchestrationInstance_imperative };
|
|
1353
|
+
// version: 1.316.0-4453f1e2b6
|
package/src/raml/api.raml
CHANGED
|
@@ -173,6 +173,19 @@ types:
|
|
|
173
173
|
- InProgress
|
|
174
174
|
- NotStarted
|
|
175
175
|
/connect/interaction/orchestration:
|
|
176
|
+
/instance/detail:
|
|
177
|
+
get:
|
|
178
|
+
description: Retrieves run details of an Orchestration instance
|
|
179
|
+
responses:
|
|
180
|
+
'200':
|
|
181
|
+
description: Success
|
|
182
|
+
body:
|
|
183
|
+
application/json:
|
|
184
|
+
type: FlowOrchestrationInstanceRepresentation
|
|
185
|
+
queryParameters:
|
|
186
|
+
instanceId:
|
|
187
|
+
type: string
|
|
188
|
+
required: false
|
|
176
189
|
/instances:
|
|
177
190
|
get:
|
|
178
191
|
description: Retrieves a collection of Orchestration instances
|
package/src/raml/luvio.raml
CHANGED
|
@@ -8,10 +8,18 @@ uses:
|
|
|
8
8
|
(luvio.ttl): 2592000000
|
|
9
9
|
|
|
10
10
|
types:
|
|
11
|
+
FlowOrchestrationInstanceRepresentation:
|
|
12
|
+
(luvio.ttl): 100
|
|
11
13
|
FlowOrchestrationInstanceCollectionRepresentation:
|
|
12
14
|
(luvio.ttl): 100
|
|
13
15
|
|
|
14
16
|
/connect/interaction/orchestration:
|
|
17
|
+
/instance/detail:
|
|
18
|
+
get:
|
|
19
|
+
(luvio.adapter):
|
|
20
|
+
name: getOrchestrationInstance
|
|
21
|
+
oneOfParams:
|
|
22
|
+
- instanceId
|
|
15
23
|
/instances:
|
|
16
24
|
get:
|
|
17
25
|
(luvio.adapter):
|