@salesforce/lds-adapters-platform-flow 1.396.0 → 1.398.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-flow.js +47 -165
- package/dist/es/es2018/types/src/artifacts/main.d.ts +0 -1
- package/dist/es/es2018/types/src/artifacts/sfdc.d.ts +1 -2
- package/dist/es/es2018/types/src/generated/artifacts/main.d.ts +0 -1
- package/dist/es/es2018/types/src/generated/artifacts/sfdc.d.ts +1 -3
- package/package.json +4 -4
- package/sfdc/index.js +52 -172
- package/src/raml/api.raml +0 -42
- package/src/raml/luvio.raml +0 -14
- package/dist/es/es2018/types/src/adapters/invokeAction.d.ts +0 -6
- package/dist/es/es2018/types/src/generated/adapters/invokeAction.d.ts +0 -28
- package/dist/es/es2018/types/src/generated/resources/postConnectInteractionRuntimeInvokeAction.d.ts +0 -16
- package/dist/es/es2018/types/src/generated/types/FlowRuntimeInvokeActionInputRepresentation.d.ts +0 -42
- package/dist/es/es2018/types/src/generated/types/FlowRuntimeInvokeActionInputWrapperRepresentation.d.ts +0 -37
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* For full license text, see the LICENSE.txt file
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import { createResourceParams as createResourceParams$
|
|
7
|
+
import { createResourceParams as createResourceParams$3, typeCheckConfig as typeCheckConfig$3, deepFreeze, StoreKeyMap } from '@luvio/engine';
|
|
8
8
|
|
|
9
9
|
const { keys: ObjectKeys$1, create: ObjectCreate$1, assign: ObjectAssign } = Object;
|
|
10
10
|
const { isArray: ArrayIsArray$1 } = Array;
|
|
@@ -134,13 +134,13 @@ function getTypeCacheKeys(rootKeySet, luvio, input, fullPathFactory) {
|
|
|
134
134
|
});
|
|
135
135
|
}
|
|
136
136
|
|
|
137
|
-
function keyBuilder$
|
|
137
|
+
function keyBuilder$2(luvio, params) {
|
|
138
138
|
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'flowDevName:' + params.body.flowDevName + '::' + (params.body.flowVersionId === undefined ? 'flowVersionId' : 'flowVersionId:' + params.body.flowVersionId) + '::' + (params.body.arguments === undefined ? 'arguments' : 'arguments:' + params.body.arguments) + '::' + (params.body.enableTrace === undefined ? 'enableTrace' : 'enableTrace:' + params.body.enableTrace) + '::' + (params.body.enableRollbackMode === undefined ? 'enableRollbackMode' : 'enableRollbackMode:' + params.body.enableRollbackMode) + '::' + (params.body.useLatestSubflow === undefined ? 'useLatestSubflow' : 'useLatestSubflow:' + params.body.useLatestSubflow) + '::' + (params.body.debugAsUserId === undefined ? 'debugAsUserId' : 'debugAsUserId:' + params.body.debugAsUserId) + '::' + (params.body.isBuilderDebug === undefined ? 'isBuilderDebug' : 'isBuilderDebug:' + params.body.isBuilderDebug) + ')';
|
|
139
139
|
}
|
|
140
|
-
function getResponseCacheKeys$
|
|
141
|
-
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$
|
|
140
|
+
function getResponseCacheKeys$2(storeKeyMap, luvio, resourceParams, response) {
|
|
141
|
+
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$2(luvio, resourceParams));
|
|
142
142
|
}
|
|
143
|
-
function createResourceRequest$
|
|
143
|
+
function createResourceRequest$2(config) {
|
|
144
144
|
const headers = {};
|
|
145
145
|
return {
|
|
146
146
|
baseUri: '/services/data/v66.0',
|
|
@@ -154,7 +154,7 @@ function createResourceRequest$3(config) {
|
|
|
154
154
|
};
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
-
const adapterName$
|
|
157
|
+
const adapterName$2 = 'startFlow';
|
|
158
158
|
const startFlow_ConfigPropertyMetadata = [
|
|
159
159
|
generateParamConfigMetadata('flowDevName', true, 2 /* Body */, 0 /* String */),
|
|
160
160
|
generateParamConfigMetadata('flowVersionId', false, 2 /* Body */, 0 /* String */),
|
|
@@ -165,30 +165,30 @@ const startFlow_ConfigPropertyMetadata = [
|
|
|
165
165
|
generateParamConfigMetadata('debugAsUserId', false, 2 /* Body */, 0 /* String */),
|
|
166
166
|
generateParamConfigMetadata('isBuilderDebug', false, 2 /* Body */, 1 /* Boolean */),
|
|
167
167
|
];
|
|
168
|
-
const startFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
169
|
-
const createResourceParams$
|
|
170
|
-
function typeCheckConfig$
|
|
168
|
+
const startFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, startFlow_ConfigPropertyMetadata);
|
|
169
|
+
const createResourceParams$2 = /*#__PURE__*/ createResourceParams$3(startFlow_ConfigPropertyMetadata);
|
|
170
|
+
function typeCheckConfig$2(untrustedConfig) {
|
|
171
171
|
const config = {};
|
|
172
|
-
typeCheckConfig$
|
|
172
|
+
typeCheckConfig$3(untrustedConfig, config, startFlow_ConfigPropertyMetadata);
|
|
173
173
|
return config;
|
|
174
174
|
}
|
|
175
|
-
function validateAdapterConfig$
|
|
175
|
+
function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
|
|
176
176
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
177
177
|
return null;
|
|
178
178
|
}
|
|
179
179
|
if (process.env.NODE_ENV !== 'production') {
|
|
180
180
|
validateConfig(untrustedConfig, configPropertyNames);
|
|
181
181
|
}
|
|
182
|
-
const config = typeCheckConfig$
|
|
182
|
+
const config = typeCheckConfig$2(untrustedConfig);
|
|
183
183
|
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
184
184
|
return null;
|
|
185
185
|
}
|
|
186
186
|
return config;
|
|
187
187
|
}
|
|
188
188
|
|
|
189
|
-
function buildNetworkSnapshot$
|
|
190
|
-
const resourceParams = createResourceParams$
|
|
191
|
-
const request = createResourceRequest$
|
|
189
|
+
function buildNetworkSnapshot$2(luvio, config, options) {
|
|
190
|
+
const resourceParams = createResourceParams$2(config);
|
|
191
|
+
const request = createResourceRequest$2(resourceParams);
|
|
192
192
|
return luvio
|
|
193
193
|
.dispatchResourceRequest(request, options)
|
|
194
194
|
.then((response) => {
|
|
@@ -197,7 +197,7 @@ function buildNetworkSnapshot$3(luvio, config, options) {
|
|
|
197
197
|
return Promise.resolve(response.body);
|
|
198
198
|
}, () => {
|
|
199
199
|
const cacheKeys = new StoreKeyMap();
|
|
200
|
-
getResponseCacheKeys$
|
|
200
|
+
getResponseCacheKeys$2(cacheKeys, luvio, resourceParams, response.body);
|
|
201
201
|
return cacheKeys;
|
|
202
202
|
});
|
|
203
203
|
}, (response) => {
|
|
@@ -209,21 +209,21 @@ function buildNetworkSnapshot$3(luvio, config, options) {
|
|
|
209
209
|
});
|
|
210
210
|
}
|
|
211
211
|
const startFlowAdapterFactory = (luvio) => function flowRuntime__startFlow(untrustedConfig) {
|
|
212
|
-
const config = validateAdapterConfig$
|
|
212
|
+
const config = validateAdapterConfig$2(untrustedConfig, startFlow_ConfigPropertyNames);
|
|
213
213
|
// Invalid or incomplete config
|
|
214
214
|
if (config === null) {
|
|
215
215
|
return null;
|
|
216
216
|
}
|
|
217
|
-
return buildNetworkSnapshot$
|
|
217
|
+
return buildNetworkSnapshot$2(luvio, config);
|
|
218
218
|
};
|
|
219
219
|
|
|
220
|
-
function keyBuilder$
|
|
220
|
+
function keyBuilder$1(luvio, params) {
|
|
221
221
|
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'request.action:' + params.body.request.action + '::' + 'request.serializedState:' + params.body.request.serializedState + '::' + (params.body.request.fields === undefined ? undefined : ('[' + params.body.request.fields.map(element => 'request.fields.field:' + element.field + '::' + (element.isVisible === undefined ? 'request.fields.isVisible' : 'request.fields.isVisible:' + element.isVisible) + '::' + (element.value === undefined ? 'request.fields.value' : 'request.fields.value:' + element.value)).join(',') + ']')) + '::' + (params.body.request.uiElementVisited === undefined ? 'request.uiElementVisited' : 'request.uiElementVisited:' + params.body.request.uiElementVisited) + '::' + (params.body.request.enableTrace === undefined ? 'request.enableTrace' : 'request.enableTrace:' + params.body.request.enableTrace) + '::' + stableJSONStringify(params.body.request.lcErrors) + '::' + (params.body.request.isBuilderDebug === undefined ? 'request.isBuilderDebug' : 'request.isBuilderDebug:' + params.body.request.isBuilderDebug) + ')';
|
|
222
222
|
}
|
|
223
|
-
function getResponseCacheKeys$
|
|
224
|
-
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$
|
|
223
|
+
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
224
|
+
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
|
|
225
225
|
}
|
|
226
|
-
function createResourceRequest$
|
|
226
|
+
function createResourceRequest$1(config) {
|
|
227
227
|
const headers = {};
|
|
228
228
|
return {
|
|
229
229
|
baseUri: '/services/data/v66.0',
|
|
@@ -237,7 +237,7 @@ function createResourceRequest$2(config) {
|
|
|
237
237
|
};
|
|
238
238
|
}
|
|
239
239
|
|
|
240
|
-
function validate$
|
|
240
|
+
function validate$2(obj, path = 'FlowRuntimeNavigationFieldValue') {
|
|
241
241
|
const v_error = (() => {
|
|
242
242
|
if (typeof obj !== 'object' || ArrayIsArray$1(obj) || obj === null) {
|
|
243
243
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -286,7 +286,7 @@ function validate$3(obj, path = 'FlowRuntimeNavigationFieldValue') {
|
|
|
286
286
|
return v_error === undefined ? null : v_error;
|
|
287
287
|
}
|
|
288
288
|
|
|
289
|
-
function validate$
|
|
289
|
+
function validate$1(obj, path = 'FlowRuntimeHashbagRepresentation') {
|
|
290
290
|
const v_error = (() => {
|
|
291
291
|
if (typeof obj !== 'object' || ArrayIsArray$1(obj) || obj === null) {
|
|
292
292
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -304,7 +304,7 @@ function validate$2(obj, path = 'FlowRuntimeHashbagRepresentation') {
|
|
|
304
304
|
return v_error === undefined ? null : v_error;
|
|
305
305
|
}
|
|
306
306
|
|
|
307
|
-
function validate
|
|
307
|
+
function validate(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
308
308
|
const v_error = (() => {
|
|
309
309
|
if (typeof obj !== 'object' || ArrayIsArray$1(obj) || obj === null) {
|
|
310
310
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -330,7 +330,7 @@ function validate$1(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
|
330
330
|
for (let i = 0; i < obj_fields.length; i++) {
|
|
331
331
|
const obj_fields_item = obj_fields[i];
|
|
332
332
|
const path_fields_item = path_fields + '[' + i + ']';
|
|
333
|
-
const referencepath_fields_itemValidationError = validate$
|
|
333
|
+
const referencepath_fields_itemValidationError = validate$2(obj_fields_item, path_fields_item);
|
|
334
334
|
if (referencepath_fields_itemValidationError !== null) {
|
|
335
335
|
let message = 'Object doesn\'t match FlowRuntimeNavigationFieldValue (at "' + path_fields_item + '")\n';
|
|
336
336
|
message += referencepath_fields_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -348,7 +348,7 @@ function validate$1(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
|
348
348
|
if (obj.lcErrors !== undefined) {
|
|
349
349
|
const obj_lcErrors = obj.lcErrors;
|
|
350
350
|
const path_lcErrors = path + '.lcErrors';
|
|
351
|
-
const referencepath_lcErrorsValidationError = validate$
|
|
351
|
+
const referencepath_lcErrorsValidationError = validate$1(obj_lcErrors, path_lcErrors);
|
|
352
352
|
if (referencepath_lcErrorsValidationError !== null) {
|
|
353
353
|
let message = 'Object doesn\'t match FlowRuntimeHashbagRepresentation (at "' + path_lcErrors + '")\n';
|
|
354
354
|
message += referencepath_lcErrorsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -371,97 +371,21 @@ function validate$1(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
|
371
371
|
return v_error === undefined ? null : v_error;
|
|
372
372
|
}
|
|
373
373
|
|
|
374
|
-
const adapterName$
|
|
374
|
+
const adapterName$1 = 'navigateFlow';
|
|
375
375
|
const navigateFlow_ConfigPropertyMetadata = [
|
|
376
376
|
generateParamConfigMetadata('request', true, 2 /* Body */, 4 /* Unsupported */),
|
|
377
377
|
];
|
|
378
|
-
const navigateFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
379
|
-
const createResourceParams$
|
|
380
|
-
function typeCheckConfig$
|
|
378
|
+
const navigateFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, navigateFlow_ConfigPropertyMetadata);
|
|
379
|
+
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$3(navigateFlow_ConfigPropertyMetadata);
|
|
380
|
+
function typeCheckConfig$1(untrustedConfig) {
|
|
381
381
|
const config = {};
|
|
382
382
|
const untrustedConfig_request = untrustedConfig.request;
|
|
383
|
-
const referenceFlowRuntimeNavigateFlowRepresentationValidationError = validate
|
|
383
|
+
const referenceFlowRuntimeNavigateFlowRepresentationValidationError = validate(untrustedConfig_request);
|
|
384
384
|
if (referenceFlowRuntimeNavigateFlowRepresentationValidationError === null) {
|
|
385
385
|
config.request = untrustedConfig_request;
|
|
386
386
|
}
|
|
387
387
|
return config;
|
|
388
388
|
}
|
|
389
|
-
function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
|
|
390
|
-
if (!untrustedIsObject(untrustedConfig)) {
|
|
391
|
-
return null;
|
|
392
|
-
}
|
|
393
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
394
|
-
validateConfig(untrustedConfig, configPropertyNames);
|
|
395
|
-
}
|
|
396
|
-
const config = typeCheckConfig$2(untrustedConfig);
|
|
397
|
-
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
398
|
-
return null;
|
|
399
|
-
}
|
|
400
|
-
return config;
|
|
401
|
-
}
|
|
402
|
-
|
|
403
|
-
function buildNetworkSnapshot$2(luvio, config, context) {
|
|
404
|
-
const resourceParams = createResourceParams$2(config);
|
|
405
|
-
const request = createResourceRequest$2(resourceParams);
|
|
406
|
-
return luvio
|
|
407
|
-
.dispatchResourceRequest(request, context)
|
|
408
|
-
.then((response) => {
|
|
409
|
-
return luvio.handleSuccessResponse(() => {
|
|
410
|
-
deepFreeze(response.body);
|
|
411
|
-
return Promise.resolve(response.body);
|
|
412
|
-
}, () => {
|
|
413
|
-
const cacheKeys = new StoreKeyMap();
|
|
414
|
-
getResponseCacheKeys$2(cacheKeys, luvio, resourceParams, response.body);
|
|
415
|
-
return cacheKeys;
|
|
416
|
-
});
|
|
417
|
-
}, (response) => {
|
|
418
|
-
return luvio.handleErrorResponse(() => {
|
|
419
|
-
// We want to throw these exceptions to be caught in the runtime layer
|
|
420
|
-
// eslint-disable-next-line @salesforce/lds/no-error-in-production
|
|
421
|
-
throw new Error(response.body.message || response.body.error || response.body);
|
|
422
|
-
});
|
|
423
|
-
});
|
|
424
|
-
}
|
|
425
|
-
const navigateFlowAdapterFactory = (luvio) => function flowRuntime__navigateFlow(untrustedConfig) {
|
|
426
|
-
const config = validateAdapterConfig$2(untrustedConfig, navigateFlow_ConfigPropertyNames);
|
|
427
|
-
// Invalid or incomplete config
|
|
428
|
-
if (config === null) {
|
|
429
|
-
return null;
|
|
430
|
-
}
|
|
431
|
-
return buildNetworkSnapshot$2(luvio, config);
|
|
432
|
-
};
|
|
433
|
-
|
|
434
|
-
function keyBuilder$1(luvio, params) {
|
|
435
|
-
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'pausedInterviewId:' + params.body.pausedInterviewId + ')';
|
|
436
|
-
}
|
|
437
|
-
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
438
|
-
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
|
|
439
|
-
}
|
|
440
|
-
function createResourceRequest$1(config) {
|
|
441
|
-
const headers = {};
|
|
442
|
-
return {
|
|
443
|
-
baseUri: '/services/data/v66.0',
|
|
444
|
-
basePath: '/connect/interaction/runtime/resumeFlow',
|
|
445
|
-
method: 'post',
|
|
446
|
-
body: config.body,
|
|
447
|
-
urlParams: {},
|
|
448
|
-
queryParams: {},
|
|
449
|
-
headers,
|
|
450
|
-
priority: 'normal',
|
|
451
|
-
};
|
|
452
|
-
}
|
|
453
|
-
|
|
454
|
-
const adapterName$1 = 'resumeFlow';
|
|
455
|
-
const resumeFlow_ConfigPropertyMetadata = [
|
|
456
|
-
generateParamConfigMetadata('pausedInterviewId', true, 2 /* Body */, 0 /* String */),
|
|
457
|
-
];
|
|
458
|
-
const resumeFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, resumeFlow_ConfigPropertyMetadata);
|
|
459
|
-
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$4(resumeFlow_ConfigPropertyMetadata);
|
|
460
|
-
function typeCheckConfig$1(untrustedConfig) {
|
|
461
|
-
const config = {};
|
|
462
|
-
typeCheckConfig$4(untrustedConfig, config, resumeFlow_ConfigPropertyMetadata);
|
|
463
|
-
return config;
|
|
464
|
-
}
|
|
465
389
|
function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
466
390
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
467
391
|
return null;
|
|
@@ -476,11 +400,11 @@ function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
|
476
400
|
return config;
|
|
477
401
|
}
|
|
478
402
|
|
|
479
|
-
function buildNetworkSnapshot$1(luvio, config,
|
|
403
|
+
function buildNetworkSnapshot$1(luvio, config, context) {
|
|
480
404
|
const resourceParams = createResourceParams$1(config);
|
|
481
405
|
const request = createResourceRequest$1(resourceParams);
|
|
482
406
|
return luvio
|
|
483
|
-
.dispatchResourceRequest(request,
|
|
407
|
+
.dispatchResourceRequest(request, context)
|
|
484
408
|
.then((response) => {
|
|
485
409
|
return luvio.handleSuccessResponse(() => {
|
|
486
410
|
deepFreeze(response.body);
|
|
@@ -498,8 +422,8 @@ function buildNetworkSnapshot$1(luvio, config, options) {
|
|
|
498
422
|
});
|
|
499
423
|
});
|
|
500
424
|
}
|
|
501
|
-
const
|
|
502
|
-
const config = validateAdapterConfig$1(untrustedConfig,
|
|
425
|
+
const navigateFlowAdapterFactory = (luvio) => function flowRuntime__navigateFlow(untrustedConfig) {
|
|
426
|
+
const config = validateAdapterConfig$1(untrustedConfig, navigateFlow_ConfigPropertyNames);
|
|
503
427
|
// Invalid or incomplete config
|
|
504
428
|
if (config === null) {
|
|
505
429
|
return null;
|
|
@@ -508,7 +432,7 @@ const resumeFlowAdapterFactory = (luvio) => function flowRuntime__resumeFlow(unt
|
|
|
508
432
|
};
|
|
509
433
|
|
|
510
434
|
function keyBuilder(luvio, params) {
|
|
511
|
-
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + '
|
|
435
|
+
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'pausedInterviewId:' + params.body.pausedInterviewId + ')';
|
|
512
436
|
}
|
|
513
437
|
function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
|
|
514
438
|
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder(luvio, resourceParams));
|
|
@@ -517,7 +441,7 @@ function createResourceRequest(config) {
|
|
|
517
441
|
const headers = {};
|
|
518
442
|
return {
|
|
519
443
|
baseUri: '/services/data/v66.0',
|
|
520
|
-
basePath: '/connect/interaction/runtime/
|
|
444
|
+
basePath: '/connect/interaction/runtime/resumeFlow',
|
|
521
445
|
method: 'post',
|
|
522
446
|
body: config.body,
|
|
523
447
|
urlParams: {},
|
|
@@ -527,57 +451,15 @@ function createResourceRequest(config) {
|
|
|
527
451
|
};
|
|
528
452
|
}
|
|
529
453
|
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
534
|
-
}
|
|
535
|
-
const obj_actionName = obj.actionName;
|
|
536
|
-
const path_actionName = path + '.actionName';
|
|
537
|
-
if (typeof obj_actionName !== 'string') {
|
|
538
|
-
return new TypeError('Expected "string" but received "' + typeof obj_actionName + '" (at "' + path_actionName + '")');
|
|
539
|
-
}
|
|
540
|
-
const obj_actionType = obj.actionType;
|
|
541
|
-
const path_actionType = path + '.actionType';
|
|
542
|
-
if (typeof obj_actionType !== 'string') {
|
|
543
|
-
return new TypeError('Expected "string" but received "' + typeof obj_actionType + '" (at "' + path_actionType + '")');
|
|
544
|
-
}
|
|
545
|
-
const obj_flowVersionId = obj.flowVersionId;
|
|
546
|
-
const path_flowVersionId = path + '.flowVersionId';
|
|
547
|
-
if (typeof obj_flowVersionId !== 'string') {
|
|
548
|
-
return new TypeError('Expected "string" but received "' + typeof obj_flowVersionId + '" (at "' + path_flowVersionId + '")');
|
|
549
|
-
}
|
|
550
|
-
const obj_inputValues = obj.inputValues;
|
|
551
|
-
const path_inputValues = path + '.inputValues';
|
|
552
|
-
if (typeof obj_inputValues !== 'object' || ArrayIsArray$1(obj_inputValues) || obj_inputValues === null) {
|
|
553
|
-
return new TypeError('Expected "object" but received "' + typeof obj_inputValues + '" (at "' + path_inputValues + '")');
|
|
554
|
-
}
|
|
555
|
-
const obj_inputValues_keys = ObjectKeys$1(obj_inputValues);
|
|
556
|
-
for (let i = 0; i < obj_inputValues_keys.length; i++) {
|
|
557
|
-
const key = obj_inputValues_keys[i];
|
|
558
|
-
const obj_inputValues_prop = obj_inputValues[key];
|
|
559
|
-
const path_inputValues_prop = path_inputValues + '["' + key + '"]';
|
|
560
|
-
if (obj_inputValues_prop === undefined) {
|
|
561
|
-
return new TypeError('Expected "defined" but received "' + typeof obj_inputValues_prop + '" (at "' + path_inputValues_prop + '")');
|
|
562
|
-
}
|
|
563
|
-
}
|
|
564
|
-
})();
|
|
565
|
-
return v_error === undefined ? null : v_error;
|
|
566
|
-
}
|
|
567
|
-
|
|
568
|
-
const adapterName = 'invokeAction';
|
|
569
|
-
const invokeAction_ConfigPropertyMetadata = [
|
|
570
|
-
generateParamConfigMetadata('request', true, 2 /* Body */, 4 /* Unsupported */),
|
|
454
|
+
const adapterName = 'resumeFlow';
|
|
455
|
+
const resumeFlow_ConfigPropertyMetadata = [
|
|
456
|
+
generateParamConfigMetadata('pausedInterviewId', true, 2 /* Body */, 0 /* String */),
|
|
571
457
|
];
|
|
572
|
-
const
|
|
573
|
-
const createResourceParams = /*#__PURE__*/ createResourceParams$
|
|
458
|
+
const resumeFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, resumeFlow_ConfigPropertyMetadata);
|
|
459
|
+
const createResourceParams = /*#__PURE__*/ createResourceParams$3(resumeFlow_ConfigPropertyMetadata);
|
|
574
460
|
function typeCheckConfig(untrustedConfig) {
|
|
575
461
|
const config = {};
|
|
576
|
-
|
|
577
|
-
const referenceFlowRuntimeInvokeActionInputRepresentationValidationError = validate(untrustedConfig_request);
|
|
578
|
-
if (referenceFlowRuntimeInvokeActionInputRepresentationValidationError === null) {
|
|
579
|
-
config.request = untrustedConfig_request;
|
|
580
|
-
}
|
|
462
|
+
typeCheckConfig$3(untrustedConfig, config, resumeFlow_ConfigPropertyMetadata);
|
|
581
463
|
return config;
|
|
582
464
|
}
|
|
583
465
|
function validateAdapterConfig(untrustedConfig, configPropertyNames) {
|
|
@@ -616,8 +498,8 @@ function buildNetworkSnapshot(luvio, config, options) {
|
|
|
616
498
|
});
|
|
617
499
|
});
|
|
618
500
|
}
|
|
619
|
-
const
|
|
620
|
-
const config = validateAdapterConfig(untrustedConfig,
|
|
501
|
+
const resumeFlowAdapterFactory = (luvio) => function flowRuntime__resumeFlow(untrustedConfig) {
|
|
502
|
+
const config = validateAdapterConfig(untrustedConfig, resumeFlow_ConfigPropertyNames);
|
|
621
503
|
// Invalid or incomplete config
|
|
622
504
|
if (config === null) {
|
|
623
505
|
return null;
|
|
@@ -625,4 +507,4 @@ const invokeActionAdapterFactory = (luvio) => function FlowRuntime__invokeAction
|
|
|
625
507
|
return buildNetworkSnapshot(luvio, config);
|
|
626
508
|
};
|
|
627
509
|
|
|
628
|
-
export {
|
|
510
|
+
export { navigateFlowAdapterFactory, resumeFlowAdapterFactory, startFlowAdapterFactory };
|
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
export { startFlowAdapterFactory } from '../adapters/startFlow';
|
|
2
2
|
export { navigateFlowAdapterFactory } from '../adapters/navigateFlow';
|
|
3
3
|
export { resumeFlowAdapterFactory } from '../adapters/resumeFlow';
|
|
4
|
-
export { invokeActionAdapterFactory } from '../adapters/invokeAction';
|
|
@@ -1,4 +1,3 @@
|
|
|
1
1
|
export { startFlowAdapterFactory } from '../adapters/startFlow';
|
|
2
2
|
export { navigateFlowAdapterFactory } from '../adapters/navigateFlow';
|
|
3
3
|
export { resumeFlowAdapterFactory } from '../adapters/resumeFlow';
|
|
4
|
-
export { invokeActionAdapterFactory } from '../adapters/invokeAction';
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
declare let invokeAction: any;
|
|
2
1
|
declare let navigateFlow: any;
|
|
3
2
|
declare let resumeFlow: any;
|
|
4
3
|
declare let startFlow: any;
|
|
5
|
-
declare let invokeAction_imperative: any;
|
|
6
4
|
declare let navigateFlow_imperative: any;
|
|
7
5
|
declare let resumeFlow_imperative: any;
|
|
8
6
|
declare let startFlow_imperative: any;
|
|
9
|
-
export {
|
|
7
|
+
export { navigateFlow, resumeFlow, startFlow, navigateFlow_imperative, resumeFlow_imperative, startFlow_imperative, };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforce/lds-adapters-platform-flow",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.398.0",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
5
5
|
"description": "Flow Runtime APIs",
|
|
6
6
|
"main": "dist/es/es2018/platform-flow.js",
|
|
@@ -37,11 +37,11 @@
|
|
|
37
37
|
"release:core": "../../scripts/release/core.js --adapter=lds-adapters-platform-flow"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@salesforce/lds-bindings": "^1.
|
|
40
|
+
"@salesforce/lds-bindings": "^1.398.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@salesforce/lds-compiler-plugins": "^1.
|
|
44
|
-
"@salesforce/lds-karma": "^1.
|
|
43
|
+
"@salesforce/lds-compiler-plugins": "^1.398.0",
|
|
44
|
+
"@salesforce/lds-karma": "^1.398.0"
|
|
45
45
|
},
|
|
46
46
|
"nx": {
|
|
47
47
|
"targets": {
|
package/sfdc/index.js
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
/* proxy-compat-disable */
|
|
15
15
|
import { createLDSAdapter } from 'force/ldsBindings';
|
|
16
16
|
import { withDefaultLuvio } from 'force/ldsEngine';
|
|
17
|
-
import { createResourceParams as createResourceParams$
|
|
17
|
+
import { createResourceParams as createResourceParams$3, deepFreeze, StoreKeyMap, typeCheckConfig as typeCheckConfig$3 } from 'force/luvioEngine';
|
|
18
18
|
|
|
19
19
|
const { keys: ObjectKeys$1, create: ObjectCreate$1, assign: ObjectAssign } = Object;
|
|
20
20
|
const { isArray: ArrayIsArray$1 } = Array;
|
|
@@ -144,13 +144,13 @@ function getTypeCacheKeys(rootKeySet, luvio, input, fullPathFactory) {
|
|
|
144
144
|
});
|
|
145
145
|
}
|
|
146
146
|
|
|
147
|
-
function keyBuilder$
|
|
147
|
+
function keyBuilder$2(luvio, params) {
|
|
148
148
|
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'request.action:' + params.body.request.action + '::' + 'request.serializedState:' + params.body.request.serializedState + '::' + (params.body.request.fields === undefined ? undefined : ('[' + params.body.request.fields.map(element => 'request.fields.field:' + element.field + '::' + (element.isVisible === undefined ? 'request.fields.isVisible' : 'request.fields.isVisible:' + element.isVisible) + '::' + (element.value === undefined ? 'request.fields.value' : 'request.fields.value:' + element.value)).join(',') + ']')) + '::' + (params.body.request.uiElementVisited === undefined ? 'request.uiElementVisited' : 'request.uiElementVisited:' + params.body.request.uiElementVisited) + '::' + (params.body.request.enableTrace === undefined ? 'request.enableTrace' : 'request.enableTrace:' + params.body.request.enableTrace) + '::' + stableJSONStringify(params.body.request.lcErrors) + '::' + (params.body.request.isBuilderDebug === undefined ? 'request.isBuilderDebug' : 'request.isBuilderDebug:' + params.body.request.isBuilderDebug) + ')';
|
|
149
149
|
}
|
|
150
|
-
function getResponseCacheKeys$
|
|
151
|
-
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$
|
|
150
|
+
function getResponseCacheKeys$2(storeKeyMap, luvio, resourceParams, response) {
|
|
151
|
+
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$2(luvio, resourceParams));
|
|
152
152
|
}
|
|
153
|
-
function createResourceRequest$
|
|
153
|
+
function createResourceRequest$2(config) {
|
|
154
154
|
const headers = {};
|
|
155
155
|
return {
|
|
156
156
|
baseUri: '/services/data/v66.0',
|
|
@@ -164,7 +164,7 @@ function createResourceRequest$3(config) {
|
|
|
164
164
|
};
|
|
165
165
|
}
|
|
166
166
|
|
|
167
|
-
function validate$
|
|
167
|
+
function validate$2(obj, path = 'FlowRuntimeNavigationFieldValue') {
|
|
168
168
|
const v_error = (() => {
|
|
169
169
|
if (typeof obj !== 'object' || ArrayIsArray$1(obj) || obj === null) {
|
|
170
170
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -213,7 +213,7 @@ function validate$3(obj, path = 'FlowRuntimeNavigationFieldValue') {
|
|
|
213
213
|
return v_error === undefined ? null : v_error;
|
|
214
214
|
}
|
|
215
215
|
|
|
216
|
-
function validate$
|
|
216
|
+
function validate$1(obj, path = 'FlowRuntimeHashbagRepresentation') {
|
|
217
217
|
const v_error = (() => {
|
|
218
218
|
if (typeof obj !== 'object' || ArrayIsArray$1(obj) || obj === null) {
|
|
219
219
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -231,7 +231,7 @@ function validate$2(obj, path = 'FlowRuntimeHashbagRepresentation') {
|
|
|
231
231
|
return v_error === undefined ? null : v_error;
|
|
232
232
|
}
|
|
233
233
|
|
|
234
|
-
function validate
|
|
234
|
+
function validate(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
235
235
|
const v_error = (() => {
|
|
236
236
|
if (typeof obj !== 'object' || ArrayIsArray$1(obj) || obj === null) {
|
|
237
237
|
return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
|
|
@@ -257,7 +257,7 @@ function validate$1(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
|
257
257
|
for (let i = 0; i < obj_fields.length; i++) {
|
|
258
258
|
const obj_fields_item = obj_fields[i];
|
|
259
259
|
const path_fields_item = path_fields + '[' + i + ']';
|
|
260
|
-
const referencepath_fields_itemValidationError = validate$
|
|
260
|
+
const referencepath_fields_itemValidationError = validate$2(obj_fields_item, path_fields_item);
|
|
261
261
|
if (referencepath_fields_itemValidationError !== null) {
|
|
262
262
|
let message = 'Object doesn\'t match FlowRuntimeNavigationFieldValue (at "' + path_fields_item + '")\n';
|
|
263
263
|
message += referencepath_fields_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -275,7 +275,7 @@ function validate$1(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
|
275
275
|
if (obj.lcErrors !== undefined) {
|
|
276
276
|
const obj_lcErrors = obj.lcErrors;
|
|
277
277
|
const path_lcErrors = path + '.lcErrors';
|
|
278
|
-
const referencepath_lcErrorsValidationError = validate$
|
|
278
|
+
const referencepath_lcErrorsValidationError = validate$1(obj_lcErrors, path_lcErrors);
|
|
279
279
|
if (referencepath_lcErrorsValidationError !== null) {
|
|
280
280
|
let message = 'Object doesn\'t match FlowRuntimeHashbagRepresentation (at "' + path_lcErrors + '")\n';
|
|
281
281
|
message += referencepath_lcErrorsValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
|
|
@@ -298,97 +298,21 @@ function validate$1(obj, path = 'FlowRuntimeNavigateFlowRepresentation') {
|
|
|
298
298
|
return v_error === undefined ? null : v_error;
|
|
299
299
|
}
|
|
300
300
|
|
|
301
|
-
const adapterName$
|
|
301
|
+
const adapterName$2 = 'navigateFlow';
|
|
302
302
|
const navigateFlow_ConfigPropertyMetadata = [
|
|
303
303
|
generateParamConfigMetadata('request', true, 2 /* Body */, 4 /* Unsupported */),
|
|
304
304
|
];
|
|
305
|
-
const navigateFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$
|
|
306
|
-
const createResourceParams$
|
|
307
|
-
function typeCheckConfig$
|
|
305
|
+
const navigateFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, navigateFlow_ConfigPropertyMetadata);
|
|
306
|
+
const createResourceParams$2 = /*#__PURE__*/ createResourceParams$3(navigateFlow_ConfigPropertyMetadata);
|
|
307
|
+
function typeCheckConfig$2(untrustedConfig) {
|
|
308
308
|
const config = {};
|
|
309
309
|
const untrustedConfig_request = untrustedConfig.request;
|
|
310
|
-
const referenceFlowRuntimeNavigateFlowRepresentationValidationError = validate
|
|
310
|
+
const referenceFlowRuntimeNavigateFlowRepresentationValidationError = validate(untrustedConfig_request);
|
|
311
311
|
if (referenceFlowRuntimeNavigateFlowRepresentationValidationError === null) {
|
|
312
312
|
config.request = untrustedConfig_request;
|
|
313
313
|
}
|
|
314
314
|
return config;
|
|
315
315
|
}
|
|
316
|
-
function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
|
|
317
|
-
if (!untrustedIsObject(untrustedConfig)) {
|
|
318
|
-
return null;
|
|
319
|
-
}
|
|
320
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
321
|
-
validateConfig(untrustedConfig, configPropertyNames);
|
|
322
|
-
}
|
|
323
|
-
const config = typeCheckConfig$3(untrustedConfig);
|
|
324
|
-
if (!areRequiredParametersPresent(config, configPropertyNames)) {
|
|
325
|
-
return null;
|
|
326
|
-
}
|
|
327
|
-
return config;
|
|
328
|
-
}
|
|
329
|
-
|
|
330
|
-
function buildNetworkSnapshot$3(luvio, config, context) {
|
|
331
|
-
const resourceParams = createResourceParams$3(config);
|
|
332
|
-
const request = createResourceRequest$3(resourceParams);
|
|
333
|
-
return luvio
|
|
334
|
-
.dispatchResourceRequest(request, context)
|
|
335
|
-
.then((response) => {
|
|
336
|
-
return luvio.handleSuccessResponse(() => {
|
|
337
|
-
deepFreeze(response.body);
|
|
338
|
-
return Promise.resolve(response.body);
|
|
339
|
-
}, () => {
|
|
340
|
-
const cacheKeys = new StoreKeyMap();
|
|
341
|
-
getResponseCacheKeys$3(cacheKeys, luvio, resourceParams, response.body);
|
|
342
|
-
return cacheKeys;
|
|
343
|
-
});
|
|
344
|
-
}, (response) => {
|
|
345
|
-
return luvio.handleErrorResponse(() => {
|
|
346
|
-
// We want to throw these exceptions to be caught in the runtime layer
|
|
347
|
-
// eslint-disable-next-line @salesforce/lds/no-error-in-production
|
|
348
|
-
throw new Error(response.body.message || response.body.error || response.body);
|
|
349
|
-
});
|
|
350
|
-
});
|
|
351
|
-
}
|
|
352
|
-
const navigateFlowAdapterFactory = (luvio) => function flowRuntime__navigateFlow(untrustedConfig) {
|
|
353
|
-
const config = validateAdapterConfig$3(untrustedConfig, navigateFlow_ConfigPropertyNames);
|
|
354
|
-
// Invalid or incomplete config
|
|
355
|
-
if (config === null) {
|
|
356
|
-
return null;
|
|
357
|
-
}
|
|
358
|
-
return buildNetworkSnapshot$3(luvio, config);
|
|
359
|
-
};
|
|
360
|
-
|
|
361
|
-
function keyBuilder$2(luvio, params) {
|
|
362
|
-
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'pausedInterviewId:' + params.body.pausedInterviewId + ')';
|
|
363
|
-
}
|
|
364
|
-
function getResponseCacheKeys$2(storeKeyMap, luvio, resourceParams, response) {
|
|
365
|
-
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$2(luvio, resourceParams));
|
|
366
|
-
}
|
|
367
|
-
function createResourceRequest$2(config) {
|
|
368
|
-
const headers = {};
|
|
369
|
-
return {
|
|
370
|
-
baseUri: '/services/data/v66.0',
|
|
371
|
-
basePath: '/connect/interaction/runtime/resumeFlow',
|
|
372
|
-
method: 'post',
|
|
373
|
-
body: config.body,
|
|
374
|
-
urlParams: {},
|
|
375
|
-
queryParams: {},
|
|
376
|
-
headers,
|
|
377
|
-
priority: 'normal',
|
|
378
|
-
};
|
|
379
|
-
}
|
|
380
|
-
|
|
381
|
-
const adapterName$2 = 'resumeFlow';
|
|
382
|
-
const resumeFlow_ConfigPropertyMetadata = [
|
|
383
|
-
generateParamConfigMetadata('pausedInterviewId', true, 2 /* Body */, 0 /* String */),
|
|
384
|
-
];
|
|
385
|
-
const resumeFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, resumeFlow_ConfigPropertyMetadata);
|
|
386
|
-
const createResourceParams$2 = /*#__PURE__*/ createResourceParams$4(resumeFlow_ConfigPropertyMetadata);
|
|
387
|
-
function typeCheckConfig$2(untrustedConfig) {
|
|
388
|
-
const config = {};
|
|
389
|
-
typeCheckConfig$4(untrustedConfig, config, resumeFlow_ConfigPropertyMetadata);
|
|
390
|
-
return config;
|
|
391
|
-
}
|
|
392
316
|
function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
|
|
393
317
|
if (!untrustedIsObject(untrustedConfig)) {
|
|
394
318
|
return null;
|
|
@@ -403,11 +327,11 @@ function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
|
|
|
403
327
|
return config;
|
|
404
328
|
}
|
|
405
329
|
|
|
406
|
-
function buildNetworkSnapshot$2(luvio, config,
|
|
330
|
+
function buildNetworkSnapshot$2(luvio, config, context) {
|
|
407
331
|
const resourceParams = createResourceParams$2(config);
|
|
408
332
|
const request = createResourceRequest$2(resourceParams);
|
|
409
333
|
return luvio
|
|
410
|
-
.dispatchResourceRequest(request,
|
|
334
|
+
.dispatchResourceRequest(request, context)
|
|
411
335
|
.then((response) => {
|
|
412
336
|
return luvio.handleSuccessResponse(() => {
|
|
413
337
|
deepFreeze(response.body);
|
|
@@ -425,8 +349,8 @@ function buildNetworkSnapshot$2(luvio, config, options) {
|
|
|
425
349
|
});
|
|
426
350
|
});
|
|
427
351
|
}
|
|
428
|
-
const
|
|
429
|
-
const config = validateAdapterConfig$2(untrustedConfig,
|
|
352
|
+
const navigateFlowAdapterFactory = (luvio) => function flowRuntime__navigateFlow(untrustedConfig) {
|
|
353
|
+
const config = validateAdapterConfig$2(untrustedConfig, navigateFlow_ConfigPropertyNames);
|
|
430
354
|
// Invalid or incomplete config
|
|
431
355
|
if (config === null) {
|
|
432
356
|
return null;
|
|
@@ -435,7 +359,7 @@ const resumeFlowAdapterFactory = (luvio) => function flowRuntime__resumeFlow(unt
|
|
|
435
359
|
};
|
|
436
360
|
|
|
437
361
|
function keyBuilder$1(luvio, params) {
|
|
438
|
-
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + '
|
|
362
|
+
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'pausedInterviewId:' + params.body.pausedInterviewId + ')';
|
|
439
363
|
}
|
|
440
364
|
function getResponseCacheKeys$1(storeKeyMap, luvio, resourceParams, response) {
|
|
441
365
|
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder$1(luvio, resourceParams));
|
|
@@ -444,7 +368,7 @@ function createResourceRequest$1(config) {
|
|
|
444
368
|
const headers = {};
|
|
445
369
|
return {
|
|
446
370
|
baseUri: '/services/data/v66.0',
|
|
447
|
-
basePath: '/connect/interaction/runtime/
|
|
371
|
+
basePath: '/connect/interaction/runtime/resumeFlow',
|
|
448
372
|
method: 'post',
|
|
449
373
|
body: config.body,
|
|
450
374
|
urlParams: {},
|
|
@@ -454,22 +378,15 @@ function createResourceRequest$1(config) {
|
|
|
454
378
|
};
|
|
455
379
|
}
|
|
456
380
|
|
|
457
|
-
const adapterName$1 = '
|
|
458
|
-
const
|
|
459
|
-
generateParamConfigMetadata('
|
|
460
|
-
generateParamConfigMetadata('flowVersionId', false, 2 /* Body */, 0 /* String */),
|
|
461
|
-
generateParamConfigMetadata('arguments', false, 2 /* Body */, 0 /* String */),
|
|
462
|
-
generateParamConfigMetadata('enableTrace', false, 2 /* Body */, 1 /* Boolean */),
|
|
463
|
-
generateParamConfigMetadata('enableRollbackMode', false, 2 /* Body */, 1 /* Boolean */),
|
|
464
|
-
generateParamConfigMetadata('useLatestSubflow', false, 2 /* Body */, 1 /* Boolean */),
|
|
465
|
-
generateParamConfigMetadata('debugAsUserId', false, 2 /* Body */, 0 /* String */),
|
|
466
|
-
generateParamConfigMetadata('isBuilderDebug', false, 2 /* Body */, 1 /* Boolean */),
|
|
381
|
+
const adapterName$1 = 'resumeFlow';
|
|
382
|
+
const resumeFlow_ConfigPropertyMetadata = [
|
|
383
|
+
generateParamConfigMetadata('pausedInterviewId', true, 2 /* Body */, 0 /* String */),
|
|
467
384
|
];
|
|
468
|
-
const
|
|
469
|
-
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$
|
|
385
|
+
const resumeFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, resumeFlow_ConfigPropertyMetadata);
|
|
386
|
+
const createResourceParams$1 = /*#__PURE__*/ createResourceParams$3(resumeFlow_ConfigPropertyMetadata);
|
|
470
387
|
function typeCheckConfig$1(untrustedConfig) {
|
|
471
388
|
const config = {};
|
|
472
|
-
typeCheckConfig$
|
|
389
|
+
typeCheckConfig$3(untrustedConfig, config, resumeFlow_ConfigPropertyMetadata);
|
|
473
390
|
return config;
|
|
474
391
|
}
|
|
475
392
|
function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
|
|
@@ -508,8 +425,8 @@ function buildNetworkSnapshot$1(luvio, config, options) {
|
|
|
508
425
|
});
|
|
509
426
|
});
|
|
510
427
|
}
|
|
511
|
-
const
|
|
512
|
-
const config = validateAdapterConfig$1(untrustedConfig,
|
|
428
|
+
const resumeFlowAdapterFactory = (luvio) => function flowRuntime__resumeFlow(untrustedConfig) {
|
|
429
|
+
const config = validateAdapterConfig$1(untrustedConfig, resumeFlow_ConfigPropertyNames);
|
|
513
430
|
// Invalid or incomplete config
|
|
514
431
|
if (config === null) {
|
|
515
432
|
return null;
|
|
@@ -518,7 +435,7 @@ const startFlowAdapterFactory = (luvio) => function flowRuntime__startFlow(untru
|
|
|
518
435
|
};
|
|
519
436
|
|
|
520
437
|
function keyBuilder(luvio, params) {
|
|
521
|
-
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + '
|
|
438
|
+
return keyPrefix + '::FlowRuntimeResponseRepresentation:(' + 'flowDevName:' + params.body.flowDevName + '::' + (params.body.flowVersionId === undefined ? 'flowVersionId' : 'flowVersionId:' + params.body.flowVersionId) + '::' + (params.body.arguments === undefined ? 'arguments' : 'arguments:' + params.body.arguments) + '::' + (params.body.enableTrace === undefined ? 'enableTrace' : 'enableTrace:' + params.body.enableTrace) + '::' + (params.body.enableRollbackMode === undefined ? 'enableRollbackMode' : 'enableRollbackMode:' + params.body.enableRollbackMode) + '::' + (params.body.useLatestSubflow === undefined ? 'useLatestSubflow' : 'useLatestSubflow:' + params.body.useLatestSubflow) + '::' + (params.body.debugAsUserId === undefined ? 'debugAsUserId' : 'debugAsUserId:' + params.body.debugAsUserId) + '::' + (params.body.isBuilderDebug === undefined ? 'isBuilderDebug' : 'isBuilderDebug:' + params.body.isBuilderDebug) + ')';
|
|
522
439
|
}
|
|
523
440
|
function getResponseCacheKeys(storeKeyMap, luvio, resourceParams, response) {
|
|
524
441
|
getTypeCacheKeys(storeKeyMap, luvio, response, () => keyBuilder(luvio, resourceParams));
|
|
@@ -527,7 +444,7 @@ function createResourceRequest(config) {
|
|
|
527
444
|
const headers = {};
|
|
528
445
|
return {
|
|
529
446
|
baseUri: '/services/data/v66.0',
|
|
530
|
-
basePath: '/connect/interaction/runtime/
|
|
447
|
+
basePath: '/connect/interaction/runtime/startFlow',
|
|
531
448
|
method: 'post',
|
|
532
449
|
body: config.body,
|
|
533
450
|
urlParams: {},
|
|
@@ -537,57 +454,22 @@ function createResourceRequest(config) {
|
|
|
537
454
|
};
|
|
538
455
|
}
|
|
539
456
|
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
const obj_actionType = obj.actionType;
|
|
551
|
-
const path_actionType = path + '.actionType';
|
|
552
|
-
if (typeof obj_actionType !== 'string') {
|
|
553
|
-
return new TypeError('Expected "string" but received "' + typeof obj_actionType + '" (at "' + path_actionType + '")');
|
|
554
|
-
}
|
|
555
|
-
const obj_flowVersionId = obj.flowVersionId;
|
|
556
|
-
const path_flowVersionId = path + '.flowVersionId';
|
|
557
|
-
if (typeof obj_flowVersionId !== 'string') {
|
|
558
|
-
return new TypeError('Expected "string" but received "' + typeof obj_flowVersionId + '" (at "' + path_flowVersionId + '")');
|
|
559
|
-
}
|
|
560
|
-
const obj_inputValues = obj.inputValues;
|
|
561
|
-
const path_inputValues = path + '.inputValues';
|
|
562
|
-
if (typeof obj_inputValues !== 'object' || ArrayIsArray$1(obj_inputValues) || obj_inputValues === null) {
|
|
563
|
-
return new TypeError('Expected "object" but received "' + typeof obj_inputValues + '" (at "' + path_inputValues + '")');
|
|
564
|
-
}
|
|
565
|
-
const obj_inputValues_keys = ObjectKeys$1(obj_inputValues);
|
|
566
|
-
for (let i = 0; i < obj_inputValues_keys.length; i++) {
|
|
567
|
-
const key = obj_inputValues_keys[i];
|
|
568
|
-
const obj_inputValues_prop = obj_inputValues[key];
|
|
569
|
-
const path_inputValues_prop = path_inputValues + '["' + key + '"]';
|
|
570
|
-
if (obj_inputValues_prop === undefined) {
|
|
571
|
-
return new TypeError('Expected "defined" but received "' + typeof obj_inputValues_prop + '" (at "' + path_inputValues_prop + '")');
|
|
572
|
-
}
|
|
573
|
-
}
|
|
574
|
-
})();
|
|
575
|
-
return v_error === undefined ? null : v_error;
|
|
576
|
-
}
|
|
577
|
-
|
|
578
|
-
const adapterName = 'invokeAction';
|
|
579
|
-
const invokeAction_ConfigPropertyMetadata = [
|
|
580
|
-
generateParamConfigMetadata('request', true, 2 /* Body */, 4 /* Unsupported */),
|
|
457
|
+
const adapterName = 'startFlow';
|
|
458
|
+
const startFlow_ConfigPropertyMetadata = [
|
|
459
|
+
generateParamConfigMetadata('flowDevName', true, 2 /* Body */, 0 /* String */),
|
|
460
|
+
generateParamConfigMetadata('flowVersionId', false, 2 /* Body */, 0 /* String */),
|
|
461
|
+
generateParamConfigMetadata('arguments', false, 2 /* Body */, 0 /* String */),
|
|
462
|
+
generateParamConfigMetadata('enableTrace', false, 2 /* Body */, 1 /* Boolean */),
|
|
463
|
+
generateParamConfigMetadata('enableRollbackMode', false, 2 /* Body */, 1 /* Boolean */),
|
|
464
|
+
generateParamConfigMetadata('useLatestSubflow', false, 2 /* Body */, 1 /* Boolean */),
|
|
465
|
+
generateParamConfigMetadata('debugAsUserId', false, 2 /* Body */, 0 /* String */),
|
|
466
|
+
generateParamConfigMetadata('isBuilderDebug', false, 2 /* Body */, 1 /* Boolean */),
|
|
581
467
|
];
|
|
582
|
-
const
|
|
583
|
-
const createResourceParams = /*#__PURE__*/ createResourceParams$
|
|
468
|
+
const startFlow_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, startFlow_ConfigPropertyMetadata);
|
|
469
|
+
const createResourceParams = /*#__PURE__*/ createResourceParams$3(startFlow_ConfigPropertyMetadata);
|
|
584
470
|
function typeCheckConfig(untrustedConfig) {
|
|
585
471
|
const config = {};
|
|
586
|
-
|
|
587
|
-
const referenceFlowRuntimeInvokeActionInputRepresentationValidationError = validate(untrustedConfig_request);
|
|
588
|
-
if (referenceFlowRuntimeInvokeActionInputRepresentationValidationError === null) {
|
|
589
|
-
config.request = untrustedConfig_request;
|
|
590
|
-
}
|
|
472
|
+
typeCheckConfig$3(untrustedConfig, config, startFlow_ConfigPropertyMetadata);
|
|
591
473
|
return config;
|
|
592
474
|
}
|
|
593
475
|
function validateAdapterConfig(untrustedConfig, configPropertyNames) {
|
|
@@ -626,8 +508,8 @@ function buildNetworkSnapshot(luvio, config, options) {
|
|
|
626
508
|
});
|
|
627
509
|
});
|
|
628
510
|
}
|
|
629
|
-
const
|
|
630
|
-
const config = validateAdapterConfig(untrustedConfig,
|
|
511
|
+
const startFlowAdapterFactory = (luvio) => function flowRuntime__startFlow(untrustedConfig) {
|
|
512
|
+
const config = validateAdapterConfig(untrustedConfig, startFlow_ConfigPropertyNames);
|
|
631
513
|
// Invalid or incomplete config
|
|
632
514
|
if (config === null) {
|
|
633
515
|
return null;
|
|
@@ -638,18 +520,16 @@ const invokeActionAdapterFactory = (luvio) => function FlowRuntime__invokeAction
|
|
|
638
520
|
let navigateFlow;
|
|
639
521
|
let resumeFlow;
|
|
640
522
|
let startFlow;
|
|
641
|
-
let invokeAction;
|
|
642
523
|
function bindExportsTo(luvio) {
|
|
643
524
|
return {
|
|
644
|
-
navigateFlow: createLDSAdapter(luvio, adapterName$
|
|
645
|
-
resumeFlow: createLDSAdapter(luvio, adapterName$
|
|
646
|
-
startFlow: createLDSAdapter(luvio, adapterName
|
|
647
|
-
invokeAction: createLDSAdapter(luvio, adapterName, invokeActionAdapterFactory),
|
|
525
|
+
navigateFlow: createLDSAdapter(luvio, adapterName$2, navigateFlowAdapterFactory),
|
|
526
|
+
resumeFlow: createLDSAdapter(luvio, adapterName$1, resumeFlowAdapterFactory),
|
|
527
|
+
startFlow: createLDSAdapter(luvio, adapterName, startFlowAdapterFactory),
|
|
648
528
|
};
|
|
649
529
|
}
|
|
650
530
|
withDefaultLuvio((luvio) => {
|
|
651
|
-
({ navigateFlow, resumeFlow, startFlow
|
|
531
|
+
({ navigateFlow, resumeFlow, startFlow } = bindExportsTo(luvio));
|
|
652
532
|
});
|
|
653
533
|
|
|
654
|
-
export {
|
|
655
|
-
// version: 1.
|
|
534
|
+
export { navigateFlow, resumeFlow, startFlow };
|
|
535
|
+
// version: 1.398.0-ada864f72d
|
package/src/raml/api.raml
CHANGED
|
@@ -130,33 +130,6 @@ types:
|
|
|
130
130
|
type: FlowRuntimeNavigationResult | nil
|
|
131
131
|
required: false
|
|
132
132
|
|
|
133
|
-
FlowRuntimeInvokeActionInputWrapperRepresentation:
|
|
134
|
-
type: object
|
|
135
|
-
properties:
|
|
136
|
-
request:
|
|
137
|
-
type: FlowRuntimeInvokeActionInputRepresentation
|
|
138
|
-
required: true
|
|
139
|
-
|
|
140
|
-
FlowRuntimeInvokeActionInputRepresentation:
|
|
141
|
-
description: Invocable actions input values representation
|
|
142
|
-
type: object
|
|
143
|
-
properties:
|
|
144
|
-
actionName:
|
|
145
|
-
description: ActionName
|
|
146
|
-
type: string
|
|
147
|
-
actionType:
|
|
148
|
-
description: ActionType
|
|
149
|
-
type: string
|
|
150
|
-
flowVersionId:
|
|
151
|
-
description: FlowVersionId
|
|
152
|
-
type: string
|
|
153
|
-
inputValues:
|
|
154
|
-
description: InputValues
|
|
155
|
-
type: object
|
|
156
|
-
properties:
|
|
157
|
-
//:
|
|
158
|
-
type: any
|
|
159
|
-
|
|
160
133
|
/connect/interaction/runtime/startFlow:
|
|
161
134
|
post:
|
|
162
135
|
responses:
|
|
@@ -193,18 +166,3 @@ types:
|
|
|
193
166
|
body:
|
|
194
167
|
application/json:
|
|
195
168
|
type: FlowRuntimeResumeFlowRepresentation
|
|
196
|
-
|
|
197
|
-
/connect/interaction/runtime/invokeAction:
|
|
198
|
-
post:
|
|
199
|
-
displayName: postFlowRuntimeInvokeAction
|
|
200
|
-
description: Invokes an invocable action
|
|
201
|
-
responses:
|
|
202
|
-
'200':
|
|
203
|
-
description: Success
|
|
204
|
-
body:
|
|
205
|
-
application/json:
|
|
206
|
-
type: FlowRuntimeResponseRepresentation
|
|
207
|
-
body:
|
|
208
|
-
application/json:
|
|
209
|
-
type: FlowRuntimeInvokeActionInputWrapperRepresentation
|
|
210
|
-
(oas-body-name): request
|
package/src/raml/luvio.raml
CHANGED
|
@@ -11,14 +11,6 @@ types:
|
|
|
11
11
|
FlowRuntimeResponseRepresentation:
|
|
12
12
|
(luvio.opaque): true
|
|
13
13
|
|
|
14
|
-
FlowRuntimeInvokeActionInputRepresentation:
|
|
15
|
-
(luvio.ttl): 500
|
|
16
|
-
(luvio.opaque): true
|
|
17
|
-
|
|
18
|
-
FlowRuntimeInvokeActionOutputRepresentation:
|
|
19
|
-
(luvio.ttl): 500
|
|
20
|
-
(luvio.opaque): true
|
|
21
|
-
|
|
22
14
|
/connect/interaction/runtime/startFlow:
|
|
23
15
|
post:
|
|
24
16
|
(luvio.adapter):
|
|
@@ -36,9 +28,3 @@ types:
|
|
|
36
28
|
(luvio.adapter):
|
|
37
29
|
name: resumeFlow
|
|
38
30
|
(luvio.method): get
|
|
39
|
-
|
|
40
|
-
/connect/interaction/runtime/invokeAction:
|
|
41
|
-
post:
|
|
42
|
-
(luvio.adapter):
|
|
43
|
-
name: invokeAction
|
|
44
|
-
(luvio.method): get
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import type { Luvio as $64$luvio_engine_Luvio, DispatchResourceRequestContext } from '@luvio/engine';
|
|
2
|
-
import type { FlowRuntimeResponseRepresentation as types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation } from '../generated/types/FlowRuntimeResponseRepresentation';
|
|
3
|
-
import type { InvokeActionConfig } from '../generated/adapters/invokeAction';
|
|
4
|
-
export { adapterName } from '../generated/adapters/invokeAction';
|
|
5
|
-
export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig, options?: DispatchResourceRequestContext): Promise<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation>;
|
|
6
|
-
export declare const invokeActionAdapterFactory: any;
|
|
@@ -1,28 +0,0 @@
|
|
|
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 { FlowRuntimeInvokeActionInputRepresentation as types_FlowRuntimeInvokeActionInputRepresentation_FlowRuntimeInvokeActionInputRepresentation } from '../types/FlowRuntimeInvokeActionInputRepresentation';
|
|
4
|
-
import { ResourceRequestConfig as resources_postConnectInteractionRuntimeInvokeAction_ResourceRequestConfig } from '../resources/postConnectInteractionRuntimeInvokeAction';
|
|
5
|
-
import { FlowRuntimeResponseRepresentation as types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation } from '../types/FlowRuntimeResponseRepresentation';
|
|
6
|
-
export declare const adapterName = "invokeAction";
|
|
7
|
-
export declare const invokeAction_ConfigPropertyMetadata: $64$luvio_engine_AdapterConfigMetadata[];
|
|
8
|
-
export declare const invokeAction_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
|
|
9
|
-
export interface InvokeActionConfig {
|
|
10
|
-
request: types_FlowRuntimeInvokeActionInputRepresentation_FlowRuntimeInvokeActionInputRepresentation;
|
|
11
|
-
}
|
|
12
|
-
export declare const createResourceParams: (config: InvokeActionConfig) => resources_postConnectInteractionRuntimeInvokeAction_ResourceRequestConfig;
|
|
13
|
-
export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig): string;
|
|
14
|
-
export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig): $64$luvio_engine_NormalizedKeyMetadata;
|
|
15
|
-
export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<InvokeActionConfig>): adapter$45$utils_Untrusted<InvokeActionConfig>;
|
|
16
|
-
export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): InvokeActionConfig | null;
|
|
17
|
-
export declare function adapterFragment(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig): $64$luvio_engine_Fragment;
|
|
18
|
-
export declare function buildCachedSnapshot(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig): $64$luvio_engine_Snapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, any>;
|
|
19
|
-
export declare function onFetchResponseSuccess(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig, resourceParams: resources_postConnectInteractionRuntimeInvokeAction_ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation>): Promise<import("@luvio/engine").FulfilledSnapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, any>>;
|
|
20
|
-
export declare function onFetchResponseError(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig, resourceParams: resources_postConnectInteractionRuntimeInvokeAction_ResourceRequestConfig, response: $64$luvio_engine_ErrorResponse): Promise<import("@luvio/engine").ErrorSnapshot>;
|
|
21
|
-
export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: InvokeActionConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<$64$luvio_engine_Snapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, any>>;
|
|
22
|
-
export type BuildSnapshotContext = {
|
|
23
|
-
luvio: $64$luvio_engine_Luvio;
|
|
24
|
-
config: InvokeActionConfig;
|
|
25
|
-
};
|
|
26
|
-
export declare function buildNetworkSnapshotCachePolicy(context: BuildSnapshotContext, coercedAdapterRequestContext: $64$luvio_engine_CoercedAdapterRequestContext): Promise<$64$luvio_engine_Snapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, any>>;
|
|
27
|
-
export declare function buildCachedSnapshotCachePolicy(context: BuildSnapshotContext, storeLookup: $64$luvio_engine_StoreLookup<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation>): $64$luvio_engine_Snapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, any>;
|
|
28
|
-
export declare const invokeActionAdapterFactory: $64$luvio_engine_AdapterFactory<InvokeActionConfig, types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation>;
|
package/dist/es/es2018/types/src/generated/resources/postConnectInteractionRuntimeInvokeAction.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { FlowRuntimeInvokeActionInputRepresentation as types_FlowRuntimeInvokeActionInputRepresentation_FlowRuntimeInvokeActionInputRepresentation } from '../types/FlowRuntimeInvokeActionInputRepresentation';
|
|
2
|
-
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';
|
|
3
|
-
import { FlowRuntimeResponseRepresentation as types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation } from '../types/FlowRuntimeResponseRepresentation';
|
|
4
|
-
export interface ResourceRequestConfig {
|
|
5
|
-
body: {
|
|
6
|
-
request: types_FlowRuntimeInvokeActionInputRepresentation_FlowRuntimeInvokeActionInputRepresentation;
|
|
7
|
-
};
|
|
8
|
-
}
|
|
9
|
-
export declare function select(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_Fragment;
|
|
10
|
-
export declare function keyBuilder(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): string;
|
|
11
|
-
export declare function keyBuilder_StructuredKey(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_NormalizedKeyMetadata;
|
|
12
|
-
export declare function getResponseCacheKeys(storeKeyMap: any, luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation): void;
|
|
13
|
-
export declare function ingestSuccess(luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation>, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation>): $64$luvio_engine_FulfilledSnapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, {}> | $64$luvio_engine_StaleSnapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, {}> | $64$luvio_engine_PendingSnapshot<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation, any>;
|
|
14
|
-
export declare function ingestError(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig, error: $64$luvio_engine_ErrorResponse, snapshotRefresh?: $64$luvio_engine_SnapshotRefresh<types_FlowRuntimeResponseRepresentation_FlowRuntimeResponseRepresentation>): $64$luvio_engine_ErrorSnapshot;
|
|
15
|
-
export declare function createResourceRequest(config: ResourceRequestConfig): $64$luvio_engine_ResourceRequest;
|
|
16
|
-
export default createResourceRequest;
|
package/dist/es/es2018/types/src/generated/types/FlowRuntimeInvokeActionInputRepresentation.d.ts
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { IngestPath as $64$luvio_engine_IngestPath, Luvio as $64$luvio_engine_Luvio, Store as $64$luvio_engine_Store, BaseFragment as $64$luvio_engine_BaseFragment, ResourceIngest as $64$luvio_engine_ResourceIngest, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
|
|
2
|
-
export declare const TTL = 500;
|
|
3
|
-
export declare const VERSION = "49a9ed1295d4bdf865f29837aa52a9c3";
|
|
4
|
-
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
5
|
-
export declare const RepresentationType: string;
|
|
6
|
-
export declare function normalize(input: FlowRuntimeInvokeActionInputRepresentation, existing: FlowRuntimeInvokeActionInputRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): FlowRuntimeInvokeActionInputRepresentationNormalized;
|
|
7
|
-
export declare const select: () => $64$luvio_engine_BaseFragment;
|
|
8
|
-
export declare function equals(existing: FlowRuntimeInvokeActionInputRepresentationNormalized, incoming: FlowRuntimeInvokeActionInputRepresentationNormalized): boolean;
|
|
9
|
-
export declare const ingest: $64$luvio_engine_ResourceIngest;
|
|
10
|
-
export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableStoreKeyMetadataMap, luvio: $64$luvio_engine_Luvio, input: FlowRuntimeInvokeActionInputRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): void;
|
|
11
|
-
/**
|
|
12
|
-
* Invocable actions input values representation
|
|
13
|
-
*
|
|
14
|
-
* Keys:
|
|
15
|
-
* (none)
|
|
16
|
-
*/
|
|
17
|
-
export interface FlowRuntimeInvokeActionInputRepresentationNormalized {
|
|
18
|
-
/** ActionName */
|
|
19
|
-
actionName: string;
|
|
20
|
-
/** ActionType */
|
|
21
|
-
actionType: string;
|
|
22
|
-
/** FlowVersionId */
|
|
23
|
-
flowVersionId: string;
|
|
24
|
-
/** InputValues */
|
|
25
|
-
inputValues: {
|
|
26
|
-
[key: string]: unknown;
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Invocable actions input values representation
|
|
31
|
-
*
|
|
32
|
-
* Keys:
|
|
33
|
-
* (none)
|
|
34
|
-
*/
|
|
35
|
-
export interface FlowRuntimeInvokeActionInputRepresentation {
|
|
36
|
-
actionName: string;
|
|
37
|
-
actionType: string;
|
|
38
|
-
flowVersionId: string;
|
|
39
|
-
inputValues: {
|
|
40
|
-
[key: string]: unknown;
|
|
41
|
-
};
|
|
42
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { IngestPath as $64$luvio_engine_IngestPath, Luvio as $64$luvio_engine_Luvio, Store as $64$luvio_engine_Store, ResourceIngest as $64$luvio_engine_ResourceIngest, FragmentSelection as $64$luvio_engine_FragmentSelection, LinkSelection as $64$luvio_engine_LinkSelection, StoreLink as $64$luvio_engine_StoreLink, DurableStoreKeyMetadataMap as $64$luvio_engine_DurableStoreKeyMetadataMap, NormalizedKeyMetadata as $64$luvio_engine_NormalizedKeyMetadata } from '@luvio/engine';
|
|
2
|
-
import { FlowRuntimeInvokeActionInputRepresentation as FlowRuntimeInvokeActionInputRepresentation_FlowRuntimeInvokeActionInputRepresentation } from './FlowRuntimeInvokeActionInputRepresentation';
|
|
3
|
-
export declare const VERSION = "b4445cc62ae092236ca7c13655b78bc6";
|
|
4
|
-
export declare function validate(obj: any, path?: string): TypeError | null;
|
|
5
|
-
export declare const RepresentationType: string;
|
|
6
|
-
export declare function normalize(input: FlowRuntimeInvokeActionInputWrapperRepresentation, existing: FlowRuntimeInvokeActionInputWrapperRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number): FlowRuntimeInvokeActionInputWrapperRepresentationNormalized;
|
|
7
|
-
export interface DynamicIngestParams {
|
|
8
|
-
request: $64$luvio_engine_ResourceIngest;
|
|
9
|
-
}
|
|
10
|
-
export declare function dynamicNormalize(ingestParams: DynamicIngestParams): (input: FlowRuntimeInvokeActionInputWrapperRepresentation, existing: FlowRuntimeInvokeActionInputWrapperRepresentationNormalized, path: $64$luvio_engine_IngestPath, luvio: $64$luvio_engine_Luvio, store: $64$luvio_engine_Store, timestamp: number) => FlowRuntimeInvokeActionInputWrapperRepresentationNormalized;
|
|
11
|
-
export declare const select: () => $64$luvio_engine_FragmentSelection;
|
|
12
|
-
export interface DynamicSelectParams {
|
|
13
|
-
request?: $64$luvio_engine_LinkSelection;
|
|
14
|
-
}
|
|
15
|
-
export declare const dynamicSelect: (params: DynamicSelectParams) => $64$luvio_engine_FragmentSelection;
|
|
16
|
-
export declare function equals(existing: FlowRuntimeInvokeActionInputWrapperRepresentationNormalized, incoming: FlowRuntimeInvokeActionInputWrapperRepresentationNormalized): boolean;
|
|
17
|
-
export declare const ingest: $64$luvio_engine_ResourceIngest;
|
|
18
|
-
export declare function getTypeCacheKeys(rootKeySet: $64$luvio_engine_DurableStoreKeyMetadataMap, luvio: $64$luvio_engine_Luvio, input: FlowRuntimeInvokeActionInputWrapperRepresentation, fullPathFactory: () => string | $64$luvio_engine_NormalizedKeyMetadata): void;
|
|
19
|
-
export declare function dynamicIngest(ingestParams: DynamicIngestParams): $64$luvio_engine_ResourceIngest;
|
|
20
|
-
/**
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* Keys:
|
|
24
|
-
* (none)
|
|
25
|
-
*/
|
|
26
|
-
export interface FlowRuntimeInvokeActionInputWrapperRepresentationNormalized {
|
|
27
|
-
request: $64$luvio_engine_StoreLink;
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
* Keys:
|
|
33
|
-
* (none)
|
|
34
|
-
*/
|
|
35
|
-
export interface FlowRuntimeInvokeActionInputWrapperRepresentation {
|
|
36
|
-
request: FlowRuntimeInvokeActionInputRepresentation_FlowRuntimeInvokeActionInputRepresentation;
|
|
37
|
-
}
|