@salesforce/lds-adapters-industries-actionablelist 1.100.2

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.
Files changed (43) hide show
  1. package/LICENSE.txt +82 -0
  2. package/dist/es/es2018/industries-actionablelist.js +2925 -0
  3. package/dist/types/src/generated/adapters/adapter-utils.d.ts +66 -0
  4. package/dist/types/src/generated/adapters/createActionableListDefinition.d.ts +15 -0
  5. package/dist/types/src/generated/adapters/getActionableListDatasetInfo.d.ts +27 -0
  6. package/dist/types/src/generated/adapters/getActionableListDefinitions.d.ts +29 -0
  7. package/dist/types/src/generated/adapters/getActionableListMembers.d.ts +26 -0
  8. package/dist/types/src/generated/adapters/upsertActionableList.d.ts +15 -0
  9. package/dist/types/src/generated/artifacts/main.d.ts +5 -0
  10. package/dist/types/src/generated/artifacts/sfdc.d.ts +9 -0
  11. package/dist/types/src/generated/resources/getConnectActionableListDefinition.d.ts +18 -0
  12. package/dist/types/src/generated/resources/getConnectActionableListMembersById.d.ts +15 -0
  13. package/dist/types/src/generated/resources/postConnectActionableList.d.ts +13 -0
  14. package/dist/types/src/generated/resources/postConnectActionableListDefinition.d.ts +13 -0
  15. package/dist/types/src/generated/resources/postConnectActionableListDefinitionRows.d.ts +16 -0
  16. package/dist/types/src/generated/types/ALDDatasetColumnOutputRepresentation.d.ts +51 -0
  17. package/dist/types/src/generated/types/ALDMemberStatusOutputRepresentation.d.ts +36 -0
  18. package/dist/types/src/generated/types/ActionableListDatasetByDefinitionRepresentation.d.ts +45 -0
  19. package/dist/types/src/generated/types/ActionableListDatasetColumnRepresentation.d.ts +44 -0
  20. package/dist/types/src/generated/types/ActionableListDatasetInputRepresentation.d.ts +50 -0
  21. package/dist/types/src/generated/types/ActionableListDatasetRowRepresentation.d.ts +33 -0
  22. package/dist/types/src/generated/types/ActionableListDatasetWrapperInputRepresentation.d.ts +30 -0
  23. package/dist/types/src/generated/types/ActionableListDefinitionCreateInputRepresentation.d.ts +35 -0
  24. package/dist/types/src/generated/types/ActionableListDefinitionCreateOutputRepresentation.d.ts +42 -0
  25. package/dist/types/src/generated/types/ActionableListDefinitionGetAllOutputRepresentation.d.ts +31 -0
  26. package/dist/types/src/generated/types/ActionableListDefinitionOutputRepresentation.d.ts +59 -0
  27. package/dist/types/src/generated/types/ActionableListDefinitionStatusOutputRepresentation.d.ts +33 -0
  28. package/dist/types/src/generated/types/ActionableListDefinitionWrapperInputRepresentation.d.ts +30 -0
  29. package/dist/types/src/generated/types/ActionableListFilterInputRepresentation.d.ts +38 -0
  30. package/dist/types/src/generated/types/ActionableListFilterInputRepresentationList.d.ts +29 -0
  31. package/dist/types/src/generated/types/ActionableListMemberStatusRepresentation.d.ts +35 -0
  32. package/dist/types/src/generated/types/ActionableListMembersOutputRepresentation.d.ts +30 -0
  33. package/dist/types/src/generated/types/ActionableListUpsertInputRepresentation.d.ts +59 -0
  34. package/dist/types/src/generated/types/ActionableListUpsertOutputRepresentation.d.ts +45 -0
  35. package/dist/types/src/generated/types/ActionableListWrapperInputRepresentation.d.ts +30 -0
  36. package/dist/types/src/generated/types/type-utils.d.ts +39 -0
  37. package/dist/umd/es2018/industries-actionablelist.js +2937 -0
  38. package/dist/umd/es5/industries-actionablelist.js +2952 -0
  39. package/package.json +70 -0
  40. package/sfdc/index.d.ts +1 -0
  41. package/sfdc/index.js +2982 -0
  42. package/src/raml/api.raml +473 -0
  43. package/src/raml/luvio.raml +54 -0
@@ -0,0 +1,2937 @@
1
+ /**
2
+ * Copyright (c) 2022, Salesforce, Inc.,
3
+ * All rights reserved.
4
+ * For full license text, see the LICENSE.txt file
5
+ */
6
+
7
+ (function (global, factory) {
8
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@luvio/engine')) :
9
+ typeof define === 'function' && define.amd ? define(['exports', '@luvio/engine'], factory) :
10
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.industriesActionablelist = {}, global.engine));
11
+ })(this, (function (exports, engine) { 'use strict';
12
+
13
+ const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
14
+ const { keys: ObjectKeys$1, freeze: ObjectFreeze$1, create: ObjectCreate$1 } = Object;
15
+ const { isArray: ArrayIsArray$1 } = Array;
16
+ /**
17
+ * Validates an adapter config is well-formed.
18
+ * @param config The config to validate.
19
+ * @param adapter The adapter validation configuration.
20
+ * @param oneOf The keys the config must contain at least one of.
21
+ * @throws A TypeError if config doesn't satisfy the adapter's config validation.
22
+ */
23
+ function validateConfig(config, adapter, oneOf) {
24
+ const { displayName } = adapter;
25
+ const { required, optional, unsupported } = adapter.parameters;
26
+ if (config === undefined ||
27
+ required.every(req => ObjectPrototypeHasOwnProperty.call(config, req)) === false) {
28
+ throw new TypeError(`adapter ${displayName} configuration must specify ${required.sort().join(', ')}`);
29
+ }
30
+ if (oneOf && oneOf.some(req => ObjectPrototypeHasOwnProperty.call(config, req)) === false) {
31
+ throw new TypeError(`adapter ${displayName} configuration must specify one of ${oneOf.sort().join(', ')}`);
32
+ }
33
+ if (unsupported !== undefined &&
34
+ unsupported.some(req => ObjectPrototypeHasOwnProperty.call(config, req))) {
35
+ throw new TypeError(`adapter ${displayName} does not yet support ${unsupported.sort().join(', ')}`);
36
+ }
37
+ const supported = required.concat(optional);
38
+ if (ObjectKeys$1(config).some(key => !supported.includes(key))) {
39
+ throw new TypeError(`adapter ${displayName} configuration supports only ${supported.sort().join(', ')}`);
40
+ }
41
+ }
42
+ function untrustedIsObject(untrusted) {
43
+ return typeof untrusted === 'object' && untrusted !== null && ArrayIsArray$1(untrusted) === false;
44
+ }
45
+ function areRequiredParametersPresent(config, configPropertyNames) {
46
+ return configPropertyNames.parameters.required.every(req => req in config);
47
+ }
48
+ const snapshotRefreshOptions = {
49
+ overrides: {
50
+ headers: {
51
+ 'Cache-Control': 'no-cache',
52
+ },
53
+ }
54
+ };
55
+ const keyPrefix = 'actionablelist';
56
+
57
+ const { freeze: ObjectFreeze, keys: ObjectKeys, create: ObjectCreate, assign: ObjectAssign } = Object;
58
+ const { isArray: ArrayIsArray } = Array;
59
+ function equalsArray(a, b, equalsItem) {
60
+ const aLength = a.length;
61
+ const bLength = b.length;
62
+ if (aLength !== bLength) {
63
+ return false;
64
+ }
65
+ for (let i = 0; i < aLength; i++) {
66
+ if (equalsItem(a[i], b[i]) === false) {
67
+ return false;
68
+ }
69
+ }
70
+ return true;
71
+ }
72
+ function equalsObject(a, b, equalsProp) {
73
+ const aKeys = ObjectKeys(a).sort();
74
+ const bKeys = ObjectKeys(b).sort();
75
+ const aKeysLength = aKeys.length;
76
+ const bKeysLength = bKeys.length;
77
+ if (aKeysLength !== bKeysLength) {
78
+ return false;
79
+ }
80
+ for (let i = 0; i < aKeys.length; i++) {
81
+ const key = aKeys[i];
82
+ if (key !== bKeys[i]) {
83
+ return false;
84
+ }
85
+ if (equalsProp(a[key], b[key]) === false) {
86
+ return false;
87
+ }
88
+ }
89
+ return true;
90
+ }
91
+ function deepFreeze(value) {
92
+ // No need to freeze primitives
93
+ if (typeof value !== 'object' || value === null) {
94
+ return;
95
+ }
96
+ if (ArrayIsArray(value)) {
97
+ for (let i = 0, len = value.length; i < len; i += 1) {
98
+ deepFreeze(value[i]);
99
+ }
100
+ }
101
+ else {
102
+ const keys = ObjectKeys(value);
103
+ for (let i = 0, len = keys.length; i < len; i += 1) {
104
+ deepFreeze(value[keys[i]]);
105
+ }
106
+ }
107
+ ObjectFreeze(value);
108
+ }
109
+ function createLink(ref) {
110
+ return {
111
+ __ref: engine.serializeStructuredKey(ref),
112
+ };
113
+ }
114
+
115
+ const VERSION$b = "8d304f086ca6d70241ff9dc64e1c4652";
116
+ function validate$e(obj, path = 'ALDDatasetColumnOutputRepresentation') {
117
+ const v_error = (() => {
118
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
119
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
120
+ }
121
+ const obj_actionableListDefinitionId = obj.actionableListDefinitionId;
122
+ const path_actionableListDefinitionId = path + '.actionableListDefinitionId';
123
+ if (typeof obj_actionableListDefinitionId !== 'string') {
124
+ return new TypeError('Expected "string" but received "' + typeof obj_actionableListDefinitionId + '" (at "' + path_actionableListDefinitionId + '")');
125
+ }
126
+ const obj_dataDomain = obj.dataDomain;
127
+ const path_dataDomain = path + '.dataDomain';
128
+ let obj_dataDomain_union0 = null;
129
+ const obj_dataDomain_union0_error = (() => {
130
+ if (typeof obj_dataDomain !== 'string') {
131
+ return new TypeError('Expected "string" but received "' + typeof obj_dataDomain + '" (at "' + path_dataDomain + '")');
132
+ }
133
+ })();
134
+ if (obj_dataDomain_union0_error != null) {
135
+ obj_dataDomain_union0 = obj_dataDomain_union0_error.message;
136
+ }
137
+ let obj_dataDomain_union1 = null;
138
+ const obj_dataDomain_union1_error = (() => {
139
+ if (obj_dataDomain !== null) {
140
+ return new TypeError('Expected "null" but received "' + typeof obj_dataDomain + '" (at "' + path_dataDomain + '")');
141
+ }
142
+ })();
143
+ if (obj_dataDomain_union1_error != null) {
144
+ obj_dataDomain_union1 = obj_dataDomain_union1_error.message;
145
+ }
146
+ if (obj_dataDomain_union0 && obj_dataDomain_union1) {
147
+ let message = 'Object doesn\'t match union (at "' + path_dataDomain + '")';
148
+ message += '\n' + obj_dataDomain_union0.split('\n').map((line) => '\t' + line).join('\n');
149
+ message += '\n' + obj_dataDomain_union1.split('\n').map((line) => '\t' + line).join('\n');
150
+ return new TypeError(message);
151
+ }
152
+ const obj_dataType = obj.dataType;
153
+ const path_dataType = path + '.dataType';
154
+ let obj_dataType_union0 = null;
155
+ const obj_dataType_union0_error = (() => {
156
+ if (typeof obj_dataType !== 'string') {
157
+ return new TypeError('Expected "string" but received "' + typeof obj_dataType + '" (at "' + path_dataType + '")');
158
+ }
159
+ })();
160
+ if (obj_dataType_union0_error != null) {
161
+ obj_dataType_union0 = obj_dataType_union0_error.message;
162
+ }
163
+ let obj_dataType_union1 = null;
164
+ const obj_dataType_union1_error = (() => {
165
+ if (obj_dataType !== null) {
166
+ return new TypeError('Expected "null" but received "' + typeof obj_dataType + '" (at "' + path_dataType + '")');
167
+ }
168
+ })();
169
+ if (obj_dataType_union1_error != null) {
170
+ obj_dataType_union1 = obj_dataType_union1_error.message;
171
+ }
172
+ if (obj_dataType_union0 && obj_dataType_union1) {
173
+ let message = 'Object doesn\'t match union (at "' + path_dataType + '")';
174
+ message += '\n' + obj_dataType_union0.split('\n').map((line) => '\t' + line).join('\n');
175
+ message += '\n' + obj_dataType_union1.split('\n').map((line) => '\t' + line).join('\n');
176
+ return new TypeError(message);
177
+ }
178
+ const obj_id = obj.id;
179
+ const path_id = path + '.id';
180
+ if (typeof obj_id !== 'string') {
181
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
182
+ }
183
+ const obj_isDefault = obj.isDefault;
184
+ const path_isDefault = path + '.isDefault';
185
+ if (typeof obj_isDefault !== 'boolean') {
186
+ return new TypeError('Expected "boolean" but received "' + typeof obj_isDefault + '" (at "' + path_isDefault + '")');
187
+ }
188
+ const obj_objectName = obj.objectName;
189
+ const path_objectName = path + '.objectName';
190
+ let obj_objectName_union0 = null;
191
+ const obj_objectName_union0_error = (() => {
192
+ if (typeof obj_objectName !== 'string') {
193
+ return new TypeError('Expected "string" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
194
+ }
195
+ })();
196
+ if (obj_objectName_union0_error != null) {
197
+ obj_objectName_union0 = obj_objectName_union0_error.message;
198
+ }
199
+ let obj_objectName_union1 = null;
200
+ const obj_objectName_union1_error = (() => {
201
+ if (obj_objectName !== null) {
202
+ return new TypeError('Expected "null" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
203
+ }
204
+ })();
205
+ if (obj_objectName_union1_error != null) {
206
+ obj_objectName_union1 = obj_objectName_union1_error.message;
207
+ }
208
+ if (obj_objectName_union0 && obj_objectName_union1) {
209
+ let message = 'Object doesn\'t match union (at "' + path_objectName + '")';
210
+ message += '\n' + obj_objectName_union0.split('\n').map((line) => '\t' + line).join('\n');
211
+ message += '\n' + obj_objectName_union1.split('\n').map((line) => '\t' + line).join('\n');
212
+ return new TypeError(message);
213
+ }
214
+ const obj_sourceColumnApiName = obj.sourceColumnApiName;
215
+ const path_sourceColumnApiName = path + '.sourceColumnApiName';
216
+ let obj_sourceColumnApiName_union0 = null;
217
+ const obj_sourceColumnApiName_union0_error = (() => {
218
+ if (typeof obj_sourceColumnApiName !== 'string') {
219
+ return new TypeError('Expected "string" but received "' + typeof obj_sourceColumnApiName + '" (at "' + path_sourceColumnApiName + '")');
220
+ }
221
+ })();
222
+ if (obj_sourceColumnApiName_union0_error != null) {
223
+ obj_sourceColumnApiName_union0 = obj_sourceColumnApiName_union0_error.message;
224
+ }
225
+ let obj_sourceColumnApiName_union1 = null;
226
+ const obj_sourceColumnApiName_union1_error = (() => {
227
+ if (obj_sourceColumnApiName !== null) {
228
+ return new TypeError('Expected "null" but received "' + typeof obj_sourceColumnApiName + '" (at "' + path_sourceColumnApiName + '")');
229
+ }
230
+ })();
231
+ if (obj_sourceColumnApiName_union1_error != null) {
232
+ obj_sourceColumnApiName_union1 = obj_sourceColumnApiName_union1_error.message;
233
+ }
234
+ if (obj_sourceColumnApiName_union0 && obj_sourceColumnApiName_union1) {
235
+ let message = 'Object doesn\'t match union (at "' + path_sourceColumnApiName + '")';
236
+ message += '\n' + obj_sourceColumnApiName_union0.split('\n').map((line) => '\t' + line).join('\n');
237
+ message += '\n' + obj_sourceColumnApiName_union1.split('\n').map((line) => '\t' + line).join('\n');
238
+ return new TypeError(message);
239
+ }
240
+ const obj_sourceFieldName = obj.sourceFieldName;
241
+ const path_sourceFieldName = path + '.sourceFieldName';
242
+ let obj_sourceFieldName_union0 = null;
243
+ const obj_sourceFieldName_union0_error = (() => {
244
+ if (typeof obj_sourceFieldName !== 'string') {
245
+ return new TypeError('Expected "string" but received "' + typeof obj_sourceFieldName + '" (at "' + path_sourceFieldName + '")');
246
+ }
247
+ })();
248
+ if (obj_sourceFieldName_union0_error != null) {
249
+ obj_sourceFieldName_union0 = obj_sourceFieldName_union0_error.message;
250
+ }
251
+ let obj_sourceFieldName_union1 = null;
252
+ const obj_sourceFieldName_union1_error = (() => {
253
+ if (obj_sourceFieldName !== null) {
254
+ return new TypeError('Expected "null" but received "' + typeof obj_sourceFieldName + '" (at "' + path_sourceFieldName + '")');
255
+ }
256
+ })();
257
+ if (obj_sourceFieldName_union1_error != null) {
258
+ obj_sourceFieldName_union1 = obj_sourceFieldName_union1_error.message;
259
+ }
260
+ if (obj_sourceFieldName_union0 && obj_sourceFieldName_union1) {
261
+ let message = 'Object doesn\'t match union (at "' + path_sourceFieldName + '")';
262
+ message += '\n' + obj_sourceFieldName_union0.split('\n').map((line) => '\t' + line).join('\n');
263
+ message += '\n' + obj_sourceFieldName_union1.split('\n').map((line) => '\t' + line).join('\n');
264
+ return new TypeError(message);
265
+ }
266
+ })();
267
+ return v_error === undefined ? null : v_error;
268
+ }
269
+ const select$g = function ALDDatasetColumnOutputRepresentationSelect() {
270
+ return {
271
+ kind: 'Fragment',
272
+ version: VERSION$b,
273
+ private: [],
274
+ selections: [
275
+ {
276
+ name: 'actionableListDefinitionId',
277
+ kind: 'Scalar'
278
+ },
279
+ {
280
+ name: 'dataDomain',
281
+ kind: 'Scalar'
282
+ },
283
+ {
284
+ name: 'dataType',
285
+ kind: 'Scalar'
286
+ },
287
+ {
288
+ name: 'id',
289
+ kind: 'Scalar'
290
+ },
291
+ {
292
+ name: 'isDefault',
293
+ kind: 'Scalar'
294
+ },
295
+ {
296
+ name: 'objectName',
297
+ kind: 'Scalar'
298
+ },
299
+ {
300
+ name: 'sourceColumnApiName',
301
+ kind: 'Scalar'
302
+ },
303
+ {
304
+ name: 'sourceFieldName',
305
+ kind: 'Scalar'
306
+ }
307
+ ]
308
+ };
309
+ };
310
+ function equals$b(existing, incoming) {
311
+ const existing_isDefault = existing.isDefault;
312
+ const incoming_isDefault = incoming.isDefault;
313
+ if (!(existing_isDefault === incoming_isDefault)) {
314
+ return false;
315
+ }
316
+ const existing_actionableListDefinitionId = existing.actionableListDefinitionId;
317
+ const incoming_actionableListDefinitionId = incoming.actionableListDefinitionId;
318
+ if (!(existing_actionableListDefinitionId === incoming_actionableListDefinitionId)) {
319
+ return false;
320
+ }
321
+ const existing_id = existing.id;
322
+ const incoming_id = incoming.id;
323
+ if (!(existing_id === incoming_id)) {
324
+ return false;
325
+ }
326
+ const existing_dataDomain = existing.dataDomain;
327
+ const incoming_dataDomain = incoming.dataDomain;
328
+ if (!(existing_dataDomain === incoming_dataDomain)) {
329
+ return false;
330
+ }
331
+ const existing_dataType = existing.dataType;
332
+ const incoming_dataType = incoming.dataType;
333
+ if (!(existing_dataType === incoming_dataType)) {
334
+ return false;
335
+ }
336
+ const existing_objectName = existing.objectName;
337
+ const incoming_objectName = incoming.objectName;
338
+ if (!(existing_objectName === incoming_objectName)) {
339
+ return false;
340
+ }
341
+ const existing_sourceColumnApiName = existing.sourceColumnApiName;
342
+ const incoming_sourceColumnApiName = incoming.sourceColumnApiName;
343
+ if (!(existing_sourceColumnApiName === incoming_sourceColumnApiName)) {
344
+ return false;
345
+ }
346
+ const existing_sourceFieldName = existing.sourceFieldName;
347
+ const incoming_sourceFieldName = incoming.sourceFieldName;
348
+ if (!(existing_sourceFieldName === incoming_sourceFieldName)) {
349
+ return false;
350
+ }
351
+ return true;
352
+ }
353
+
354
+ const VERSION$a = "9d133a939d3bf9e4f6209870e525ff9f";
355
+ function validate$d(obj, path = 'ALDMemberStatusOutputRepresentation') {
356
+ const v_error = (() => {
357
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
358
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
359
+ }
360
+ const obj_iconName = obj.iconName;
361
+ const path_iconName = path + '.iconName';
362
+ if (typeof obj_iconName !== 'string') {
363
+ return new TypeError('Expected "string" but received "' + typeof obj_iconName + '" (at "' + path_iconName + '")');
364
+ }
365
+ const obj_id = obj.id;
366
+ const path_id = path + '.id';
367
+ if (typeof obj_id !== 'string') {
368
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
369
+ }
370
+ const obj_status = obj.status;
371
+ const path_status = path + '.status';
372
+ if (typeof obj_status !== 'string') {
373
+ return new TypeError('Expected "string" but received "' + typeof obj_status + '" (at "' + path_status + '")');
374
+ }
375
+ })();
376
+ return v_error === undefined ? null : v_error;
377
+ }
378
+ const select$f = function ALDMemberStatusOutputRepresentationSelect() {
379
+ return {
380
+ kind: 'Fragment',
381
+ version: VERSION$a,
382
+ private: [],
383
+ selections: [
384
+ {
385
+ name: 'iconName',
386
+ kind: 'Scalar'
387
+ },
388
+ {
389
+ name: 'id',
390
+ kind: 'Scalar'
391
+ },
392
+ {
393
+ name: 'status',
394
+ kind: 'Scalar'
395
+ }
396
+ ]
397
+ };
398
+ };
399
+ function equals$a(existing, incoming) {
400
+ const existing_iconName = existing.iconName;
401
+ const incoming_iconName = incoming.iconName;
402
+ if (!(existing_iconName === incoming_iconName)) {
403
+ return false;
404
+ }
405
+ const existing_id = existing.id;
406
+ const incoming_id = incoming.id;
407
+ if (!(existing_id === incoming_id)) {
408
+ return false;
409
+ }
410
+ const existing_status = existing.status;
411
+ const incoming_status = incoming.status;
412
+ if (!(existing_status === incoming_status)) {
413
+ return false;
414
+ }
415
+ return true;
416
+ }
417
+
418
+ const VERSION$9 = "63348e0d2a5e8d3cf7f7ddc110bf6cf4";
419
+ function validate$c(obj, path = 'ActionableListDefinitionOutputRepresentation') {
420
+ const v_error = (() => {
421
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
422
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
423
+ }
424
+ const obj_aldDatasetColumnOutputRepresentation = obj.aldDatasetColumnOutputRepresentation;
425
+ const path_aldDatasetColumnOutputRepresentation = path + '.aldDatasetColumnOutputRepresentation';
426
+ if (!ArrayIsArray(obj_aldDatasetColumnOutputRepresentation)) {
427
+ return new TypeError('Expected "array" but received "' + typeof obj_aldDatasetColumnOutputRepresentation + '" (at "' + path_aldDatasetColumnOutputRepresentation + '")');
428
+ }
429
+ for (let i = 0; i < obj_aldDatasetColumnOutputRepresentation.length; i++) {
430
+ const obj_aldDatasetColumnOutputRepresentation_item = obj_aldDatasetColumnOutputRepresentation[i];
431
+ const path_aldDatasetColumnOutputRepresentation_item = path_aldDatasetColumnOutputRepresentation + '[' + i + ']';
432
+ const referencepath_aldDatasetColumnOutputRepresentation_itemValidationError = validate$e(obj_aldDatasetColumnOutputRepresentation_item, path_aldDatasetColumnOutputRepresentation_item);
433
+ if (referencepath_aldDatasetColumnOutputRepresentation_itemValidationError !== null) {
434
+ let message = 'Object doesn\'t match ALDDatasetColumnOutputRepresentation (at "' + path_aldDatasetColumnOutputRepresentation_item + '")\n';
435
+ message += referencepath_aldDatasetColumnOutputRepresentation_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
436
+ return new TypeError(message);
437
+ }
438
+ }
439
+ const obj_aldMemberStatusOutputRepresentation = obj.aldMemberStatusOutputRepresentation;
440
+ const path_aldMemberStatusOutputRepresentation = path + '.aldMemberStatusOutputRepresentation';
441
+ if (!ArrayIsArray(obj_aldMemberStatusOutputRepresentation)) {
442
+ return new TypeError('Expected "array" but received "' + typeof obj_aldMemberStatusOutputRepresentation + '" (at "' + path_aldMemberStatusOutputRepresentation + '")');
443
+ }
444
+ for (let i = 0; i < obj_aldMemberStatusOutputRepresentation.length; i++) {
445
+ const obj_aldMemberStatusOutputRepresentation_item = obj_aldMemberStatusOutputRepresentation[i];
446
+ const path_aldMemberStatusOutputRepresentation_item = path_aldMemberStatusOutputRepresentation + '[' + i + ']';
447
+ const referencepath_aldMemberStatusOutputRepresentation_itemValidationError = validate$d(obj_aldMemberStatusOutputRepresentation_item, path_aldMemberStatusOutputRepresentation_item);
448
+ if (referencepath_aldMemberStatusOutputRepresentation_itemValidationError !== null) {
449
+ let message = 'Object doesn\'t match ALDMemberStatusOutputRepresentation (at "' + path_aldMemberStatusOutputRepresentation_item + '")\n';
450
+ message += referencepath_aldMemberStatusOutputRepresentation_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
451
+ return new TypeError(message);
452
+ }
453
+ }
454
+ const obj_batchCalcJobDefinitionId = obj.batchCalcJobDefinitionId;
455
+ const path_batchCalcJobDefinitionId = path + '.batchCalcJobDefinitionId';
456
+ let obj_batchCalcJobDefinitionId_union0 = null;
457
+ const obj_batchCalcJobDefinitionId_union0_error = (() => {
458
+ if (typeof obj_batchCalcJobDefinitionId !== 'string') {
459
+ return new TypeError('Expected "string" but received "' + typeof obj_batchCalcJobDefinitionId + '" (at "' + path_batchCalcJobDefinitionId + '")');
460
+ }
461
+ })();
462
+ if (obj_batchCalcJobDefinitionId_union0_error != null) {
463
+ obj_batchCalcJobDefinitionId_union0 = obj_batchCalcJobDefinitionId_union0_error.message;
464
+ }
465
+ let obj_batchCalcJobDefinitionId_union1 = null;
466
+ const obj_batchCalcJobDefinitionId_union1_error = (() => {
467
+ if (obj_batchCalcJobDefinitionId !== null) {
468
+ return new TypeError('Expected "null" but received "' + typeof obj_batchCalcJobDefinitionId + '" (at "' + path_batchCalcJobDefinitionId + '")');
469
+ }
470
+ })();
471
+ if (obj_batchCalcJobDefinitionId_union1_error != null) {
472
+ obj_batchCalcJobDefinitionId_union1 = obj_batchCalcJobDefinitionId_union1_error.message;
473
+ }
474
+ if (obj_batchCalcJobDefinitionId_union0 && obj_batchCalcJobDefinitionId_union1) {
475
+ let message = 'Object doesn\'t match union (at "' + path_batchCalcJobDefinitionId + '")';
476
+ message += '\n' + obj_batchCalcJobDefinitionId_union0.split('\n').map((line) => '\t' + line).join('\n');
477
+ message += '\n' + obj_batchCalcJobDefinitionId_union1.split('\n').map((line) => '\t' + line).join('\n');
478
+ return new TypeError(message);
479
+ }
480
+ const obj_fullName = obj.fullName;
481
+ const path_fullName = path + '.fullName';
482
+ if (typeof obj_fullName !== 'string') {
483
+ return new TypeError('Expected "string" but received "' + typeof obj_fullName + '" (at "' + path_fullName + '")');
484
+ }
485
+ const obj_id = obj.id;
486
+ const path_id = path + '.id';
487
+ if (typeof obj_id !== 'string') {
488
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
489
+ }
490
+ const obj_isActive = obj.isActive;
491
+ const path_isActive = path + '.isActive';
492
+ if (typeof obj_isActive !== 'boolean') {
493
+ return new TypeError('Expected "boolean" but received "' + typeof obj_isActive + '" (at "' + path_isActive + '")');
494
+ }
495
+ const obj_objectName = obj.objectName;
496
+ const path_objectName = path + '.objectName';
497
+ if (typeof obj_objectName !== 'string') {
498
+ return new TypeError('Expected "string" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
499
+ }
500
+ const obj_status = obj.status;
501
+ const path_status = path + '.status';
502
+ if (typeof obj_status !== 'string') {
503
+ return new TypeError('Expected "string" but received "' + typeof obj_status + '" (at "' + path_status + '")');
504
+ }
505
+ const obj_tcrmDatasetId = obj.tcrmDatasetId;
506
+ const path_tcrmDatasetId = path + '.tcrmDatasetId';
507
+ let obj_tcrmDatasetId_union0 = null;
508
+ const obj_tcrmDatasetId_union0_error = (() => {
509
+ if (typeof obj_tcrmDatasetId !== 'string') {
510
+ return new TypeError('Expected "string" but received "' + typeof obj_tcrmDatasetId + '" (at "' + path_tcrmDatasetId + '")');
511
+ }
512
+ })();
513
+ if (obj_tcrmDatasetId_union0_error != null) {
514
+ obj_tcrmDatasetId_union0 = obj_tcrmDatasetId_union0_error.message;
515
+ }
516
+ let obj_tcrmDatasetId_union1 = null;
517
+ const obj_tcrmDatasetId_union1_error = (() => {
518
+ if (obj_tcrmDatasetId !== null) {
519
+ return new TypeError('Expected "null" but received "' + typeof obj_tcrmDatasetId + '" (at "' + path_tcrmDatasetId + '")');
520
+ }
521
+ })();
522
+ if (obj_tcrmDatasetId_union1_error != null) {
523
+ obj_tcrmDatasetId_union1 = obj_tcrmDatasetId_union1_error.message;
524
+ }
525
+ if (obj_tcrmDatasetId_union0 && obj_tcrmDatasetId_union1) {
526
+ let message = 'Object doesn\'t match union (at "' + path_tcrmDatasetId + '")';
527
+ message += '\n' + obj_tcrmDatasetId_union0.split('\n').map((line) => '\t' + line).join('\n');
528
+ message += '\n' + obj_tcrmDatasetId_union1.split('\n').map((line) => '\t' + line).join('\n');
529
+ return new TypeError(message);
530
+ }
531
+ const obj_tcrmDatasetName = obj.tcrmDatasetName;
532
+ const path_tcrmDatasetName = path + '.tcrmDatasetName';
533
+ if (typeof obj_tcrmDatasetName !== 'string') {
534
+ return new TypeError('Expected "string" but received "' + typeof obj_tcrmDatasetName + '" (at "' + path_tcrmDatasetName + '")');
535
+ }
536
+ })();
537
+ return v_error === undefined ? null : v_error;
538
+ }
539
+ const select$e = function ActionableListDefinitionOutputRepresentationSelect() {
540
+ const { selections: ALDDatasetColumnOutputRepresentation__selections, opaque: ALDDatasetColumnOutputRepresentation__opaque, } = select$g();
541
+ const { selections: ALDMemberStatusOutputRepresentation__selections, opaque: ALDMemberStatusOutputRepresentation__opaque, } = select$f();
542
+ return {
543
+ kind: 'Fragment',
544
+ version: VERSION$9,
545
+ private: [],
546
+ selections: [
547
+ {
548
+ name: 'aldDatasetColumnOutputRepresentation',
549
+ kind: 'Object',
550
+ plural: true,
551
+ selections: ALDDatasetColumnOutputRepresentation__selections
552
+ },
553
+ {
554
+ name: 'aldMemberStatusOutputRepresentation',
555
+ kind: 'Object',
556
+ plural: true,
557
+ selections: ALDMemberStatusOutputRepresentation__selections
558
+ },
559
+ {
560
+ name: 'batchCalcJobDefinitionId',
561
+ kind: 'Scalar'
562
+ },
563
+ {
564
+ name: 'fullName',
565
+ kind: 'Scalar'
566
+ },
567
+ {
568
+ name: 'id',
569
+ kind: 'Scalar'
570
+ },
571
+ {
572
+ name: 'isActive',
573
+ kind: 'Scalar'
574
+ },
575
+ {
576
+ name: 'objectName',
577
+ kind: 'Scalar'
578
+ },
579
+ {
580
+ name: 'status',
581
+ kind: 'Scalar'
582
+ },
583
+ {
584
+ name: 'tcrmDatasetId',
585
+ kind: 'Scalar'
586
+ },
587
+ {
588
+ name: 'tcrmDatasetName',
589
+ kind: 'Scalar'
590
+ }
591
+ ]
592
+ };
593
+ };
594
+ function equals$9(existing, incoming) {
595
+ const existing_isActive = existing.isActive;
596
+ const incoming_isActive = incoming.isActive;
597
+ if (!(existing_isActive === incoming_isActive)) {
598
+ return false;
599
+ }
600
+ const existing_fullName = existing.fullName;
601
+ const incoming_fullName = incoming.fullName;
602
+ if (!(existing_fullName === incoming_fullName)) {
603
+ return false;
604
+ }
605
+ const existing_id = existing.id;
606
+ const incoming_id = incoming.id;
607
+ if (!(existing_id === incoming_id)) {
608
+ return false;
609
+ }
610
+ const existing_objectName = existing.objectName;
611
+ const incoming_objectName = incoming.objectName;
612
+ if (!(existing_objectName === incoming_objectName)) {
613
+ return false;
614
+ }
615
+ const existing_status = existing.status;
616
+ const incoming_status = incoming.status;
617
+ if (!(existing_status === incoming_status)) {
618
+ return false;
619
+ }
620
+ const existing_tcrmDatasetName = existing.tcrmDatasetName;
621
+ const incoming_tcrmDatasetName = incoming.tcrmDatasetName;
622
+ if (!(existing_tcrmDatasetName === incoming_tcrmDatasetName)) {
623
+ return false;
624
+ }
625
+ const existing_aldDatasetColumnOutputRepresentation = existing.aldDatasetColumnOutputRepresentation;
626
+ const incoming_aldDatasetColumnOutputRepresentation = incoming.aldDatasetColumnOutputRepresentation;
627
+ const equals_aldDatasetColumnOutputRepresentation_items = equalsArray(existing_aldDatasetColumnOutputRepresentation, incoming_aldDatasetColumnOutputRepresentation, (existing_aldDatasetColumnOutputRepresentation_item, incoming_aldDatasetColumnOutputRepresentation_item) => {
628
+ if (!(equals$b(existing_aldDatasetColumnOutputRepresentation_item, incoming_aldDatasetColumnOutputRepresentation_item))) {
629
+ return false;
630
+ }
631
+ });
632
+ if (equals_aldDatasetColumnOutputRepresentation_items === false) {
633
+ return false;
634
+ }
635
+ const existing_aldMemberStatusOutputRepresentation = existing.aldMemberStatusOutputRepresentation;
636
+ const incoming_aldMemberStatusOutputRepresentation = incoming.aldMemberStatusOutputRepresentation;
637
+ const equals_aldMemberStatusOutputRepresentation_items = equalsArray(existing_aldMemberStatusOutputRepresentation, incoming_aldMemberStatusOutputRepresentation, (existing_aldMemberStatusOutputRepresentation_item, incoming_aldMemberStatusOutputRepresentation_item) => {
638
+ if (!(equals$a(existing_aldMemberStatusOutputRepresentation_item, incoming_aldMemberStatusOutputRepresentation_item))) {
639
+ return false;
640
+ }
641
+ });
642
+ if (equals_aldMemberStatusOutputRepresentation_items === false) {
643
+ return false;
644
+ }
645
+ const existing_batchCalcJobDefinitionId = existing.batchCalcJobDefinitionId;
646
+ const incoming_batchCalcJobDefinitionId = incoming.batchCalcJobDefinitionId;
647
+ if (!(existing_batchCalcJobDefinitionId === incoming_batchCalcJobDefinitionId)) {
648
+ return false;
649
+ }
650
+ const existing_tcrmDatasetId = existing.tcrmDatasetId;
651
+ const incoming_tcrmDatasetId = incoming.tcrmDatasetId;
652
+ if (!(existing_tcrmDatasetId === incoming_tcrmDatasetId)) {
653
+ return false;
654
+ }
655
+ return true;
656
+ }
657
+
658
+ const TTL$4 = 100;
659
+ const VERSION$8 = "4c1ba3bd226b3670b78af4e7ea159854";
660
+ function validate$b(obj, path = 'ActionableListDefinitionGetAllOutputRepresentation') {
661
+ const v_error = (() => {
662
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
663
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
664
+ }
665
+ const obj_aldList = obj.aldList;
666
+ const path_aldList = path + '.aldList';
667
+ if (!ArrayIsArray(obj_aldList)) {
668
+ return new TypeError('Expected "array" but received "' + typeof obj_aldList + '" (at "' + path_aldList + '")');
669
+ }
670
+ for (let i = 0; i < obj_aldList.length; i++) {
671
+ const obj_aldList_item = obj_aldList[i];
672
+ const path_aldList_item = path_aldList + '[' + i + ']';
673
+ const referencepath_aldList_itemValidationError = validate$c(obj_aldList_item, path_aldList_item);
674
+ if (referencepath_aldList_itemValidationError !== null) {
675
+ let message = 'Object doesn\'t match ActionableListDefinitionOutputRepresentation (at "' + path_aldList_item + '")\n';
676
+ message += referencepath_aldList_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
677
+ return new TypeError(message);
678
+ }
679
+ }
680
+ })();
681
+ return v_error === undefined ? null : v_error;
682
+ }
683
+ const RepresentationType$4 = 'ActionableListDefinitionGetAllOutputRepresentation';
684
+ function normalize$4(input, existing, path, luvio, store, timestamp) {
685
+ return input;
686
+ }
687
+ const select$d = function ActionableListDefinitionGetAllOutputRepresentationSelect() {
688
+ const { selections: ActionableListDefinitionOutputRepresentation__selections, opaque: ActionableListDefinitionOutputRepresentation__opaque, } = select$e();
689
+ return {
690
+ kind: 'Fragment',
691
+ version: VERSION$8,
692
+ private: [],
693
+ selections: [
694
+ {
695
+ name: 'aldList',
696
+ kind: 'Object',
697
+ plural: true,
698
+ selections: ActionableListDefinitionOutputRepresentation__selections
699
+ }
700
+ ]
701
+ };
702
+ };
703
+ function equals$8(existing, incoming) {
704
+ const existing_aldList = existing.aldList;
705
+ const incoming_aldList = incoming.aldList;
706
+ const equals_aldList_items = equalsArray(existing_aldList, incoming_aldList, (existing_aldList_item, incoming_aldList_item) => {
707
+ if (!(equals$9(existing_aldList_item, incoming_aldList_item))) {
708
+ return false;
709
+ }
710
+ });
711
+ if (equals_aldList_items === false) {
712
+ return false;
713
+ }
714
+ return true;
715
+ }
716
+ const ingest$4 = function ActionableListDefinitionGetAllOutputRepresentationIngest(input, path, luvio, store, timestamp) {
717
+ if (process.env.NODE_ENV !== 'production') {
718
+ const validateError = validate$b(input);
719
+ if (validateError !== null) {
720
+ throw validateError;
721
+ }
722
+ }
723
+ const key = path.fullPath;
724
+ const existingRecord = store.readEntry(key);
725
+ const ttlToUse = TTL$4;
726
+ let incomingRecord = normalize$4(input, store.readEntry(key), {
727
+ fullPath: key,
728
+ parent: path.parent,
729
+ propertyName: path.propertyName,
730
+ ttl: ttlToUse
731
+ });
732
+ if (existingRecord === undefined || equals$8(existingRecord, incomingRecord) === false) {
733
+ luvio.storePublish(key, incomingRecord);
734
+ }
735
+ {
736
+ const storeMetadataParams = {
737
+ ttl: ttlToUse,
738
+ namespace: "actionablelist",
739
+ version: VERSION$8,
740
+ representationName: RepresentationType$4,
741
+ };
742
+ luvio.publishStoreMetadata(key, storeMetadataParams);
743
+ }
744
+ return createLink(key);
745
+ };
746
+ function getTypeCacheKeys$4(luvio, input, fullPathFactory) {
747
+ const rootKeySet = new engine.StoreKeyMap();
748
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
749
+ const rootKey = fullPathFactory();
750
+ rootKeySet.set(rootKey, {
751
+ namespace: keyPrefix,
752
+ representationName: RepresentationType$4,
753
+ mergeable: false
754
+ });
755
+ return rootKeySet;
756
+ }
757
+
758
+ function select$c(luvio, params) {
759
+ return select$d();
760
+ }
761
+ function keyBuilder$7(luvio, params) {
762
+ return keyPrefix + '::ActionableListDefinitionGetAllOutputRepresentation:(' + 'id:' + params.queryParams.id + ',' + 'isActive:' + params.queryParams.isActive + ',' + 'limit:' + params.queryParams.limit + ',' + 'offset:' + params.queryParams.offset + ')';
763
+ }
764
+ function getResponseCacheKeys$4(luvio, resourceParams, response) {
765
+ return getTypeCacheKeys$4(luvio, response, () => keyBuilder$7(luvio, resourceParams));
766
+ }
767
+ function ingestSuccess$4(luvio, resourceParams, response, snapshotRefresh) {
768
+ const { body } = response;
769
+ const key = keyBuilder$7(luvio, resourceParams);
770
+ luvio.storeIngest(key, ingest$4, body);
771
+ const snapshot = luvio.storeLookup({
772
+ recordId: key,
773
+ node: select$c(),
774
+ variables: {},
775
+ }, snapshotRefresh);
776
+ if (process.env.NODE_ENV !== 'production') {
777
+ if (snapshot.state !== 'Fulfilled') {
778
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
779
+ }
780
+ }
781
+ return snapshot;
782
+ }
783
+ function ingestError$2(luvio, params, error, snapshotRefresh) {
784
+ const key = keyBuilder$7(luvio, params);
785
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
786
+ const storeMetadataParams = {
787
+ ttl: TTL$4,
788
+ namespace: keyPrefix,
789
+ version: VERSION$8,
790
+ representationName: RepresentationType$4
791
+ };
792
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
793
+ return errorSnapshot;
794
+ }
795
+ function createResourceRequest$4(config) {
796
+ const headers = {};
797
+ return {
798
+ baseUri: '/services/data/v58.0',
799
+ basePath: '/connect/actionable-list-definition',
800
+ method: 'get',
801
+ body: null,
802
+ urlParams: {},
803
+ queryParams: config.queryParams,
804
+ headers,
805
+ priority: 'normal',
806
+ };
807
+ }
808
+
809
+ const getActionableListDefinitions_ConfigPropertyNames = {
810
+ displayName: 'getActionableListDefinitions',
811
+ parameters: {
812
+ required: [],
813
+ optional: ['id', 'isActive', 'limit', 'offset']
814
+ }
815
+ };
816
+ function createResourceParams$4(config) {
817
+ const resourceParams = {
818
+ queryParams: {
819
+ id: config.id, isActive: config.isActive, limit: config.limit, offset: config.offset
820
+ }
821
+ };
822
+ return resourceParams;
823
+ }
824
+ function keyBuilder$6(luvio, config) {
825
+ const resourceParams = createResourceParams$4(config);
826
+ return keyBuilder$7(luvio, resourceParams);
827
+ }
828
+ function typeCheckConfig$4(untrustedConfig) {
829
+ const config = {};
830
+ const untrustedConfig_id = untrustedConfig.id;
831
+ if (typeof untrustedConfig_id === 'string') {
832
+ config.id = untrustedConfig_id;
833
+ }
834
+ const untrustedConfig_isActive = untrustedConfig.isActive;
835
+ if (typeof untrustedConfig_isActive === 'boolean') {
836
+ config.isActive = untrustedConfig_isActive;
837
+ }
838
+ const untrustedConfig_limit = untrustedConfig.limit;
839
+ if (typeof untrustedConfig_limit === 'number' && Math.floor(untrustedConfig_limit) === untrustedConfig_limit) {
840
+ config.limit = untrustedConfig_limit;
841
+ }
842
+ const untrustedConfig_offset = untrustedConfig.offset;
843
+ if (typeof untrustedConfig_offset === 'number' && Math.floor(untrustedConfig_offset) === untrustedConfig_offset) {
844
+ config.offset = untrustedConfig_offset;
845
+ }
846
+ return config;
847
+ }
848
+ function validateAdapterConfig$4(untrustedConfig, configPropertyNames) {
849
+ if (!untrustedIsObject(untrustedConfig)) {
850
+ return null;
851
+ }
852
+ if (process.env.NODE_ENV !== 'production') {
853
+ validateConfig(untrustedConfig, configPropertyNames);
854
+ }
855
+ const config = typeCheckConfig$4(untrustedConfig);
856
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
857
+ return null;
858
+ }
859
+ return config;
860
+ }
861
+ function adapterFragment$2(luvio, config) {
862
+ createResourceParams$4(config);
863
+ return select$c();
864
+ }
865
+ function onFetchResponseSuccess$2(luvio, config, resourceParams, response) {
866
+ const snapshot = ingestSuccess$4(luvio, resourceParams, response, {
867
+ config,
868
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
869
+ });
870
+ return luvio.storeBroadcast().then(() => snapshot);
871
+ }
872
+ function onFetchResponseError$2(luvio, config, resourceParams, response) {
873
+ const snapshot = ingestError$2(luvio, resourceParams, response, {
874
+ config,
875
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
876
+ });
877
+ return luvio.storeBroadcast().then(() => snapshot);
878
+ }
879
+ function buildNetworkSnapshot$4(luvio, config, options) {
880
+ const resourceParams = createResourceParams$4(config);
881
+ const request = createResourceRequest$4(resourceParams);
882
+ return luvio.dispatchResourceRequest(request, options)
883
+ .then((response) => {
884
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$2(luvio, config, resourceParams, response), () => getResponseCacheKeys$4(luvio, resourceParams, response.body));
885
+ }, (response) => {
886
+ return luvio.handleErrorResponse(() => onFetchResponseError$2(luvio, config, resourceParams, response));
887
+ });
888
+ }
889
+ function buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext) {
890
+ const { luvio, config } = context;
891
+ const { networkPriority, requestCorrelator, eventObservers } = coercedAdapterRequestContext;
892
+ const dispatchOptions = {
893
+ resourceRequestContext: {
894
+ requestCorrelator,
895
+ luvioRequestMethod: undefined,
896
+ },
897
+ eventObservers
898
+ };
899
+ if (networkPriority !== 'normal') {
900
+ dispatchOptions.overrides = {
901
+ priority: networkPriority
902
+ };
903
+ }
904
+ return buildNetworkSnapshot$4(luvio, config, dispatchOptions);
905
+ }
906
+ function buildCachedSnapshotCachePolicy$2(context, storeLookup) {
907
+ const { luvio, config } = context;
908
+ const selector = {
909
+ recordId: keyBuilder$6(luvio, config),
910
+ node: adapterFragment$2(luvio, config),
911
+ variables: {},
912
+ };
913
+ const cacheSnapshot = storeLookup(selector, {
914
+ config,
915
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
916
+ });
917
+ return cacheSnapshot;
918
+ }
919
+ const getActionableListDefinitionsAdapterFactory = (luvio) => function actionablelist__getActionableListDefinitions(untrustedConfig, requestContext) {
920
+ const config = validateAdapterConfig$4(untrustedConfig, getActionableListDefinitions_ConfigPropertyNames);
921
+ // Invalid or incomplete config
922
+ if (config === null) {
923
+ return null;
924
+ }
925
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
926
+ buildCachedSnapshotCachePolicy$2, buildNetworkSnapshotCachePolicy$2);
927
+ };
928
+
929
+ function validate$a(obj, path = 'ActionableListDefinitionCreateInputRepresentation') {
930
+ const v_error = (() => {
931
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
932
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
933
+ }
934
+ const obj_developerName = obj.developerName;
935
+ const path_developerName = path + '.developerName';
936
+ if (typeof obj_developerName !== 'string') {
937
+ return new TypeError('Expected "string" but received "' + typeof obj_developerName + '" (at "' + path_developerName + '")');
938
+ }
939
+ const obj_label = obj.label;
940
+ const path_label = path + '.label';
941
+ if (typeof obj_label !== 'string') {
942
+ return new TypeError('Expected "string" but received "' + typeof obj_label + '" (at "' + path_label + '")');
943
+ }
944
+ const obj_objectName = obj.objectName;
945
+ const path_objectName = path + '.objectName';
946
+ if (typeof obj_objectName !== 'string') {
947
+ return new TypeError('Expected "string" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
948
+ }
949
+ })();
950
+ return v_error === undefined ? null : v_error;
951
+ }
952
+
953
+ const VERSION$7 = "c011e92d9100cd54f4f75b6951999c39";
954
+ function validate$9(obj, path = 'ActionableListDefinitionStatusOutputRepresentation') {
955
+ const v_error = (() => {
956
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
957
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
958
+ }
959
+ const obj_code = obj.code;
960
+ const path_code = path + '.code';
961
+ if (typeof obj_code !== 'number' || (typeof obj_code === 'number' && Math.floor(obj_code) !== obj_code)) {
962
+ return new TypeError('Expected "integer" but received "' + typeof obj_code + '" (at "' + path_code + '")');
963
+ }
964
+ const obj_message = obj.message;
965
+ const path_message = path + '.message';
966
+ if (typeof obj_message !== 'string') {
967
+ return new TypeError('Expected "string" but received "' + typeof obj_message + '" (at "' + path_message + '")');
968
+ }
969
+ })();
970
+ return v_error === undefined ? null : v_error;
971
+ }
972
+ const select$b = function ActionableListDefinitionStatusOutputRepresentationSelect() {
973
+ return {
974
+ kind: 'Fragment',
975
+ version: VERSION$7,
976
+ private: [],
977
+ selections: [
978
+ {
979
+ name: 'code',
980
+ kind: 'Scalar'
981
+ },
982
+ {
983
+ name: 'message',
984
+ kind: 'Scalar'
985
+ }
986
+ ]
987
+ };
988
+ };
989
+ function equals$7(existing, incoming) {
990
+ const existing_code = existing.code;
991
+ const incoming_code = incoming.code;
992
+ if (!(existing_code === incoming_code)) {
993
+ return false;
994
+ }
995
+ const existing_message = existing.message;
996
+ const incoming_message = incoming.message;
997
+ if (!(existing_message === incoming_message)) {
998
+ return false;
999
+ }
1000
+ return true;
1001
+ }
1002
+
1003
+ const TTL$3 = 100;
1004
+ const VERSION$6 = "7f7f8555df2466c8cbc7878266c1decd";
1005
+ function validate$8(obj, path = 'ActionableListDefinitionCreateOutputRepresentation') {
1006
+ const v_error = (() => {
1007
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1008
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1009
+ }
1010
+ const obj_actionableListDefinition = obj.actionableListDefinition;
1011
+ const path_actionableListDefinition = path + '.actionableListDefinition';
1012
+ const referencepath_actionableListDefinitionValidationError = validate$c(obj_actionableListDefinition, path_actionableListDefinition);
1013
+ if (referencepath_actionableListDefinitionValidationError !== null) {
1014
+ let message = 'Object doesn\'t match ActionableListDefinitionOutputRepresentation (at "' + path_actionableListDefinition + '")\n';
1015
+ message += referencepath_actionableListDefinitionValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
1016
+ return new TypeError(message);
1017
+ }
1018
+ const obj_status = obj.status;
1019
+ const path_status = path + '.status';
1020
+ const referencepath_statusValidationError = validate$9(obj_status, path_status);
1021
+ if (referencepath_statusValidationError !== null) {
1022
+ let message = 'Object doesn\'t match ActionableListDefinitionStatusOutputRepresentation (at "' + path_status + '")\n';
1023
+ message += referencepath_statusValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
1024
+ return new TypeError(message);
1025
+ }
1026
+ })();
1027
+ return v_error === undefined ? null : v_error;
1028
+ }
1029
+ const RepresentationType$3 = 'ActionableListDefinitionCreateOutputRepresentation';
1030
+ function keyBuilder$5(luvio, config) {
1031
+ return keyPrefix + '::' + RepresentationType$3 + ':' + config.id;
1032
+ }
1033
+ function keyBuilderFromType$1(luvio, object) {
1034
+ const keyParams = {
1035
+ id: object.actionableListDefinition.id
1036
+ };
1037
+ return keyBuilder$5(luvio, keyParams);
1038
+ }
1039
+ function normalize$3(input, existing, path, luvio, store, timestamp) {
1040
+ return input;
1041
+ }
1042
+ const select$a = function ActionableListDefinitionCreateOutputRepresentationSelect() {
1043
+ const { selections: ActionableListDefinitionOutputRepresentation__selections, opaque: ActionableListDefinitionOutputRepresentation__opaque, } = select$e();
1044
+ const { selections: ActionableListDefinitionStatusOutputRepresentation__selections, opaque: ActionableListDefinitionStatusOutputRepresentation__opaque, } = select$b();
1045
+ return {
1046
+ kind: 'Fragment',
1047
+ version: VERSION$6,
1048
+ private: [],
1049
+ selections: [
1050
+ {
1051
+ name: 'actionableListDefinition',
1052
+ kind: 'Object',
1053
+ selections: ActionableListDefinitionOutputRepresentation__selections
1054
+ },
1055
+ {
1056
+ name: 'status',
1057
+ kind: 'Object',
1058
+ selections: ActionableListDefinitionStatusOutputRepresentation__selections
1059
+ }
1060
+ ]
1061
+ };
1062
+ };
1063
+ function equals$6(existing, incoming) {
1064
+ const existing_actionableListDefinition = existing.actionableListDefinition;
1065
+ const incoming_actionableListDefinition = incoming.actionableListDefinition;
1066
+ if (!(equals$9(existing_actionableListDefinition, incoming_actionableListDefinition))) {
1067
+ return false;
1068
+ }
1069
+ const existing_status = existing.status;
1070
+ const incoming_status = incoming.status;
1071
+ if (!(equals$7(existing_status, incoming_status))) {
1072
+ return false;
1073
+ }
1074
+ return true;
1075
+ }
1076
+ const ingest$3 = function ActionableListDefinitionCreateOutputRepresentationIngest(input, path, luvio, store, timestamp) {
1077
+ if (process.env.NODE_ENV !== 'production') {
1078
+ const validateError = validate$8(input);
1079
+ if (validateError !== null) {
1080
+ throw validateError;
1081
+ }
1082
+ }
1083
+ const key = keyBuilderFromType$1(luvio, input);
1084
+ const existingRecord = store.readEntry(key);
1085
+ const ttlToUse = TTL$3;
1086
+ let incomingRecord = normalize$3(input, store.readEntry(key), {
1087
+ fullPath: key,
1088
+ parent: path.parent,
1089
+ propertyName: path.propertyName,
1090
+ ttl: ttlToUse
1091
+ });
1092
+ if (existingRecord === undefined || equals$6(existingRecord, incomingRecord) === false) {
1093
+ luvio.storePublish(key, incomingRecord);
1094
+ }
1095
+ {
1096
+ const storeMetadataParams = {
1097
+ ttl: ttlToUse,
1098
+ namespace: "actionablelist",
1099
+ version: VERSION$6,
1100
+ representationName: RepresentationType$3,
1101
+ };
1102
+ luvio.publishStoreMetadata(key, storeMetadataParams);
1103
+ }
1104
+ return createLink(key);
1105
+ };
1106
+ function getTypeCacheKeys$3(luvio, input, fullPathFactory) {
1107
+ const rootKeySet = new engine.StoreKeyMap();
1108
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
1109
+ const rootKey = keyBuilderFromType$1(luvio, input);
1110
+ rootKeySet.set(rootKey, {
1111
+ namespace: keyPrefix,
1112
+ representationName: RepresentationType$3,
1113
+ mergeable: false
1114
+ });
1115
+ return rootKeySet;
1116
+ }
1117
+
1118
+ function select$9(luvio, params) {
1119
+ return select$a();
1120
+ }
1121
+ function getResponseCacheKeys$3(luvio, resourceParams, response) {
1122
+ return getTypeCacheKeys$3(luvio, response);
1123
+ }
1124
+ function ingestSuccess$3(luvio, resourceParams, response) {
1125
+ const { body } = response;
1126
+ const key = keyBuilderFromType$1(luvio, body);
1127
+ luvio.storeIngest(key, ingest$3, body);
1128
+ const snapshot = luvio.storeLookup({
1129
+ recordId: key,
1130
+ node: select$9(),
1131
+ variables: {},
1132
+ });
1133
+ if (process.env.NODE_ENV !== 'production') {
1134
+ if (snapshot.state !== 'Fulfilled') {
1135
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
1136
+ }
1137
+ }
1138
+ return snapshot;
1139
+ }
1140
+ function createResourceRequest$3(config) {
1141
+ const headers = {};
1142
+ return {
1143
+ baseUri: '/services/data/v58.0',
1144
+ basePath: '/connect/actionable-list-definition',
1145
+ method: 'post',
1146
+ body: config.body,
1147
+ urlParams: {},
1148
+ queryParams: {},
1149
+ headers,
1150
+ priority: 'normal',
1151
+ };
1152
+ }
1153
+
1154
+ const createActionableListDefinition_ConfigPropertyNames = {
1155
+ displayName: 'createActionableListDefinition',
1156
+ parameters: {
1157
+ required: ['actionableListDefinitionCreateInput'],
1158
+ optional: []
1159
+ }
1160
+ };
1161
+ function createResourceParams$3(config) {
1162
+ const resourceParams = {
1163
+ body: {
1164
+ actionableListDefinitionCreateInput: config.actionableListDefinitionCreateInput
1165
+ }
1166
+ };
1167
+ return resourceParams;
1168
+ }
1169
+ function typeCheckConfig$3(untrustedConfig) {
1170
+ const config = {};
1171
+ const untrustedConfig_actionableListDefinitionCreateInput = untrustedConfig.actionableListDefinitionCreateInput;
1172
+ const referenceActionableListDefinitionCreateInputRepresentationValidationError = validate$a(untrustedConfig_actionableListDefinitionCreateInput);
1173
+ if (referenceActionableListDefinitionCreateInputRepresentationValidationError === null) {
1174
+ config.actionableListDefinitionCreateInput = untrustedConfig_actionableListDefinitionCreateInput;
1175
+ }
1176
+ return config;
1177
+ }
1178
+ function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
1179
+ if (!untrustedIsObject(untrustedConfig)) {
1180
+ return null;
1181
+ }
1182
+ if (process.env.NODE_ENV !== 'production') {
1183
+ validateConfig(untrustedConfig, configPropertyNames);
1184
+ }
1185
+ const config = typeCheckConfig$3(untrustedConfig);
1186
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
1187
+ return null;
1188
+ }
1189
+ return config;
1190
+ }
1191
+ function buildNetworkSnapshot$3(luvio, config, options) {
1192
+ const resourceParams = createResourceParams$3(config);
1193
+ const request = createResourceRequest$3(resourceParams);
1194
+ return luvio.dispatchResourceRequest(request, options)
1195
+ .then((response) => {
1196
+ return luvio.handleSuccessResponse(() => {
1197
+ const snapshot = ingestSuccess$3(luvio, resourceParams, response);
1198
+ return luvio.storeBroadcast().then(() => snapshot);
1199
+ }, () => getResponseCacheKeys$3(luvio, resourceParams, response.body));
1200
+ }, (response) => {
1201
+ deepFreeze(response);
1202
+ throw response;
1203
+ });
1204
+ }
1205
+ const createActionableListDefinitionAdapterFactory = (luvio) => {
1206
+ return function createActionableListDefinition(untrustedConfig) {
1207
+ const config = validateAdapterConfig$3(untrustedConfig, createActionableListDefinition_ConfigPropertyNames);
1208
+ // Invalid or incomplete config
1209
+ if (config === null) {
1210
+ throw new Error('Invalid config for "createActionableListDefinition"');
1211
+ }
1212
+ return buildNetworkSnapshot$3(luvio, config);
1213
+ };
1214
+ };
1215
+
1216
+ const TTL$2 = 100;
1217
+ const VERSION$5 = "6ddedf71126866b776255aa167159b36";
1218
+ function validate$7(obj, path = 'ActionableListMembersOutputRepresentation') {
1219
+ const v_error = (() => {
1220
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1221
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1222
+ }
1223
+ const obj_memberIds = obj.memberIds;
1224
+ const path_memberIds = path + '.memberIds';
1225
+ if (!ArrayIsArray(obj_memberIds)) {
1226
+ return new TypeError('Expected "array" but received "' + typeof obj_memberIds + '" (at "' + path_memberIds + '")');
1227
+ }
1228
+ for (let i = 0; i < obj_memberIds.length; i++) {
1229
+ const obj_memberIds_item = obj_memberIds[i];
1230
+ const path_memberIds_item = path_memberIds + '[' + i + ']';
1231
+ if (typeof obj_memberIds_item !== 'string') {
1232
+ return new TypeError('Expected "string" but received "' + typeof obj_memberIds_item + '" (at "' + path_memberIds_item + '")');
1233
+ }
1234
+ }
1235
+ })();
1236
+ return v_error === undefined ? null : v_error;
1237
+ }
1238
+ const RepresentationType$2 = 'ActionableListMembersOutputRepresentation';
1239
+ function normalize$2(input, existing, path, luvio, store, timestamp) {
1240
+ return input;
1241
+ }
1242
+ const select$8 = function ActionableListMembersOutputRepresentationSelect() {
1243
+ return {
1244
+ kind: 'Fragment',
1245
+ version: VERSION$5,
1246
+ private: [],
1247
+ selections: [
1248
+ {
1249
+ name: 'memberIds',
1250
+ kind: 'Scalar',
1251
+ plural: true
1252
+ }
1253
+ ]
1254
+ };
1255
+ };
1256
+ function equals$5(existing, incoming) {
1257
+ const existing_memberIds = existing.memberIds;
1258
+ const incoming_memberIds = incoming.memberIds;
1259
+ const equals_memberIds_items = equalsArray(existing_memberIds, incoming_memberIds, (existing_memberIds_item, incoming_memberIds_item) => {
1260
+ if (!(existing_memberIds_item === incoming_memberIds_item)) {
1261
+ return false;
1262
+ }
1263
+ });
1264
+ if (equals_memberIds_items === false) {
1265
+ return false;
1266
+ }
1267
+ return true;
1268
+ }
1269
+ const ingest$2 = function ActionableListMembersOutputRepresentationIngest(input, path, luvio, store, timestamp) {
1270
+ if (process.env.NODE_ENV !== 'production') {
1271
+ const validateError = validate$7(input);
1272
+ if (validateError !== null) {
1273
+ throw validateError;
1274
+ }
1275
+ }
1276
+ const key = path.fullPath;
1277
+ const existingRecord = store.readEntry(key);
1278
+ const ttlToUse = TTL$2;
1279
+ let incomingRecord = normalize$2(input, store.readEntry(key), {
1280
+ fullPath: key,
1281
+ parent: path.parent,
1282
+ propertyName: path.propertyName,
1283
+ ttl: ttlToUse
1284
+ });
1285
+ if (existingRecord === undefined || equals$5(existingRecord, incomingRecord) === false) {
1286
+ luvio.storePublish(key, incomingRecord);
1287
+ }
1288
+ {
1289
+ const storeMetadataParams = {
1290
+ ttl: ttlToUse,
1291
+ namespace: "actionablelist",
1292
+ version: VERSION$5,
1293
+ representationName: RepresentationType$2,
1294
+ };
1295
+ luvio.publishStoreMetadata(key, storeMetadataParams);
1296
+ }
1297
+ return createLink(key);
1298
+ };
1299
+ function getTypeCacheKeys$2(luvio, input, fullPathFactory) {
1300
+ const rootKeySet = new engine.StoreKeyMap();
1301
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
1302
+ const rootKey = fullPathFactory();
1303
+ rootKeySet.set(rootKey, {
1304
+ namespace: keyPrefix,
1305
+ representationName: RepresentationType$2,
1306
+ mergeable: false
1307
+ });
1308
+ return rootKeySet;
1309
+ }
1310
+
1311
+ function select$7(luvio, params) {
1312
+ return select$8();
1313
+ }
1314
+ function keyBuilder$4(luvio, params) {
1315
+ return keyPrefix + '::ActionableListMembersOutputRepresentation:(' + 'id:' + params.urlParams.id + ')';
1316
+ }
1317
+ function getResponseCacheKeys$2(luvio, resourceParams, response) {
1318
+ return getTypeCacheKeys$2(luvio, response, () => keyBuilder$4(luvio, resourceParams));
1319
+ }
1320
+ function ingestSuccess$2(luvio, resourceParams, response, snapshotRefresh) {
1321
+ const { body } = response;
1322
+ const key = keyBuilder$4(luvio, resourceParams);
1323
+ luvio.storeIngest(key, ingest$2, body);
1324
+ const snapshot = luvio.storeLookup({
1325
+ recordId: key,
1326
+ node: select$7(),
1327
+ variables: {},
1328
+ }, snapshotRefresh);
1329
+ if (process.env.NODE_ENV !== 'production') {
1330
+ if (snapshot.state !== 'Fulfilled') {
1331
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
1332
+ }
1333
+ }
1334
+ return snapshot;
1335
+ }
1336
+ function ingestError$1(luvio, params, error, snapshotRefresh) {
1337
+ const key = keyBuilder$4(luvio, params);
1338
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
1339
+ const storeMetadataParams = {
1340
+ ttl: TTL$2,
1341
+ namespace: keyPrefix,
1342
+ version: VERSION$5,
1343
+ representationName: RepresentationType$2
1344
+ };
1345
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
1346
+ return errorSnapshot;
1347
+ }
1348
+ function createResourceRequest$2(config) {
1349
+ const headers = {};
1350
+ return {
1351
+ baseUri: '/services/data/v58.0',
1352
+ basePath: '/connect/actionable-list/' + config.urlParams.id + '/members',
1353
+ method: 'get',
1354
+ body: null,
1355
+ urlParams: config.urlParams,
1356
+ queryParams: {},
1357
+ headers,
1358
+ priority: 'normal',
1359
+ };
1360
+ }
1361
+
1362
+ const getActionableListMembers_ConfigPropertyNames = {
1363
+ displayName: 'getActionableListMembers',
1364
+ parameters: {
1365
+ required: ['id'],
1366
+ optional: []
1367
+ }
1368
+ };
1369
+ function createResourceParams$2(config) {
1370
+ const resourceParams = {
1371
+ urlParams: {
1372
+ id: config.id
1373
+ }
1374
+ };
1375
+ return resourceParams;
1376
+ }
1377
+ function keyBuilder$3(luvio, config) {
1378
+ const resourceParams = createResourceParams$2(config);
1379
+ return keyBuilder$4(luvio, resourceParams);
1380
+ }
1381
+ function typeCheckConfig$2(untrustedConfig) {
1382
+ const config = {};
1383
+ const untrustedConfig_id = untrustedConfig.id;
1384
+ if (typeof untrustedConfig_id === 'string') {
1385
+ config.id = untrustedConfig_id;
1386
+ }
1387
+ return config;
1388
+ }
1389
+ function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
1390
+ if (!untrustedIsObject(untrustedConfig)) {
1391
+ return null;
1392
+ }
1393
+ if (process.env.NODE_ENV !== 'production') {
1394
+ validateConfig(untrustedConfig, configPropertyNames);
1395
+ }
1396
+ const config = typeCheckConfig$2(untrustedConfig);
1397
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
1398
+ return null;
1399
+ }
1400
+ return config;
1401
+ }
1402
+ function adapterFragment$1(luvio, config) {
1403
+ createResourceParams$2(config);
1404
+ return select$7();
1405
+ }
1406
+ function onFetchResponseSuccess$1(luvio, config, resourceParams, response) {
1407
+ const snapshot = ingestSuccess$2(luvio, resourceParams, response, {
1408
+ config,
1409
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
1410
+ });
1411
+ return luvio.storeBroadcast().then(() => snapshot);
1412
+ }
1413
+ function onFetchResponseError$1(luvio, config, resourceParams, response) {
1414
+ const snapshot = ingestError$1(luvio, resourceParams, response, {
1415
+ config,
1416
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
1417
+ });
1418
+ return luvio.storeBroadcast().then(() => snapshot);
1419
+ }
1420
+ function buildNetworkSnapshot$2(luvio, config, options) {
1421
+ const resourceParams = createResourceParams$2(config);
1422
+ const request = createResourceRequest$2(resourceParams);
1423
+ return luvio.dispatchResourceRequest(request, options)
1424
+ .then((response) => {
1425
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess$1(luvio, config, resourceParams, response), () => getResponseCacheKeys$2(luvio, resourceParams, response.body));
1426
+ }, (response) => {
1427
+ return luvio.handleErrorResponse(() => onFetchResponseError$1(luvio, config, resourceParams, response));
1428
+ });
1429
+ }
1430
+ function buildNetworkSnapshotCachePolicy$1(context, coercedAdapterRequestContext) {
1431
+ const { luvio, config } = context;
1432
+ const { networkPriority, requestCorrelator, eventObservers } = coercedAdapterRequestContext;
1433
+ const dispatchOptions = {
1434
+ resourceRequestContext: {
1435
+ requestCorrelator,
1436
+ luvioRequestMethod: undefined,
1437
+ },
1438
+ eventObservers
1439
+ };
1440
+ if (networkPriority !== 'normal') {
1441
+ dispatchOptions.overrides = {
1442
+ priority: networkPriority
1443
+ };
1444
+ }
1445
+ return buildNetworkSnapshot$2(luvio, config, dispatchOptions);
1446
+ }
1447
+ function buildCachedSnapshotCachePolicy$1(context, storeLookup) {
1448
+ const { luvio, config } = context;
1449
+ const selector = {
1450
+ recordId: keyBuilder$3(luvio, config),
1451
+ node: adapterFragment$1(luvio, config),
1452
+ variables: {},
1453
+ };
1454
+ const cacheSnapshot = storeLookup(selector, {
1455
+ config,
1456
+ resolve: () => buildNetworkSnapshot$2(luvio, config, snapshotRefreshOptions)
1457
+ });
1458
+ return cacheSnapshot;
1459
+ }
1460
+ const getActionableListMembersAdapterFactory = (luvio) => function actionablelist__getActionableListMembers(untrustedConfig, requestContext) {
1461
+ const config = validateAdapterConfig$2(untrustedConfig, getActionableListMembers_ConfigPropertyNames);
1462
+ // Invalid or incomplete config
1463
+ if (config === null) {
1464
+ return null;
1465
+ }
1466
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
1467
+ buildCachedSnapshotCachePolicy$1, buildNetworkSnapshotCachePolicy$1);
1468
+ };
1469
+
1470
+ function validate$6(obj, path = 'ActionableListUpsertInputRepresentation') {
1471
+ const v_error = (() => {
1472
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1473
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1474
+ }
1475
+ if (obj.actionableListColumns !== undefined) {
1476
+ const obj_actionableListColumns = obj.actionableListColumns;
1477
+ const path_actionableListColumns = path + '.actionableListColumns';
1478
+ if (!ArrayIsArray(obj_actionableListColumns)) {
1479
+ return new TypeError('Expected "array" but received "' + typeof obj_actionableListColumns + '" (at "' + path_actionableListColumns + '")');
1480
+ }
1481
+ for (let i = 0; i < obj_actionableListColumns.length; i++) {
1482
+ const obj_actionableListColumns_item = obj_actionableListColumns[i];
1483
+ const path_actionableListColumns_item = path_actionableListColumns + '[' + i + ']';
1484
+ if (typeof obj_actionableListColumns_item !== 'string') {
1485
+ return new TypeError('Expected "string" but received "' + typeof obj_actionableListColumns_item + '" (at "' + path_actionableListColumns_item + '")');
1486
+ }
1487
+ }
1488
+ }
1489
+ if (obj.actionableListDefinitionId !== undefined) {
1490
+ const obj_actionableListDefinitionId = obj.actionableListDefinitionId;
1491
+ const path_actionableListDefinitionId = path + '.actionableListDefinitionId';
1492
+ let obj_actionableListDefinitionId_union0 = null;
1493
+ const obj_actionableListDefinitionId_union0_error = (() => {
1494
+ if (typeof obj_actionableListDefinitionId !== 'string') {
1495
+ return new TypeError('Expected "string" but received "' + typeof obj_actionableListDefinitionId + '" (at "' + path_actionableListDefinitionId + '")');
1496
+ }
1497
+ })();
1498
+ if (obj_actionableListDefinitionId_union0_error != null) {
1499
+ obj_actionableListDefinitionId_union0 = obj_actionableListDefinitionId_union0_error.message;
1500
+ }
1501
+ let obj_actionableListDefinitionId_union1 = null;
1502
+ const obj_actionableListDefinitionId_union1_error = (() => {
1503
+ if (obj_actionableListDefinitionId !== null) {
1504
+ return new TypeError('Expected "null" but received "' + typeof obj_actionableListDefinitionId + '" (at "' + path_actionableListDefinitionId + '")');
1505
+ }
1506
+ })();
1507
+ if (obj_actionableListDefinitionId_union1_error != null) {
1508
+ obj_actionableListDefinitionId_union1 = obj_actionableListDefinitionId_union1_error.message;
1509
+ }
1510
+ if (obj_actionableListDefinitionId_union0 && obj_actionableListDefinitionId_union1) {
1511
+ let message = 'Object doesn\'t match union (at "' + path_actionableListDefinitionId + '")';
1512
+ message += '\n' + obj_actionableListDefinitionId_union0.split('\n').map((line) => '\t' + line).join('\n');
1513
+ message += '\n' + obj_actionableListDefinitionId_union1.split('\n').map((line) => '\t' + line).join('\n');
1514
+ return new TypeError(message);
1515
+ }
1516
+ }
1517
+ if (obj.actionableListMemberIds !== undefined) {
1518
+ const obj_actionableListMemberIds = obj.actionableListMemberIds;
1519
+ const path_actionableListMemberIds = path + '.actionableListMemberIds';
1520
+ if (!ArrayIsArray(obj_actionableListMemberIds)) {
1521
+ return new TypeError('Expected "array" but received "' + typeof obj_actionableListMemberIds + '" (at "' + path_actionableListMemberIds + '")');
1522
+ }
1523
+ for (let i = 0; i < obj_actionableListMemberIds.length; i++) {
1524
+ const obj_actionableListMemberIds_item = obj_actionableListMemberIds[i];
1525
+ const path_actionableListMemberIds_item = path_actionableListMemberIds + '[' + i + ']';
1526
+ if (typeof obj_actionableListMemberIds_item !== 'string') {
1527
+ return new TypeError('Expected "string" but received "' + typeof obj_actionableListMemberIds_item + '" (at "' + path_actionableListMemberIds_item + '")');
1528
+ }
1529
+ }
1530
+ }
1531
+ if (obj.defaultMemberStatusId !== undefined) {
1532
+ const obj_defaultMemberStatusId = obj.defaultMemberStatusId;
1533
+ const path_defaultMemberStatusId = path + '.defaultMemberStatusId';
1534
+ let obj_defaultMemberStatusId_union0 = null;
1535
+ const obj_defaultMemberStatusId_union0_error = (() => {
1536
+ if (typeof obj_defaultMemberStatusId !== 'string') {
1537
+ return new TypeError('Expected "string" but received "' + typeof obj_defaultMemberStatusId + '" (at "' + path_defaultMemberStatusId + '")');
1538
+ }
1539
+ })();
1540
+ if (obj_defaultMemberStatusId_union0_error != null) {
1541
+ obj_defaultMemberStatusId_union0 = obj_defaultMemberStatusId_union0_error.message;
1542
+ }
1543
+ let obj_defaultMemberStatusId_union1 = null;
1544
+ const obj_defaultMemberStatusId_union1_error = (() => {
1545
+ if (obj_defaultMemberStatusId !== null) {
1546
+ return new TypeError('Expected "null" but received "' + typeof obj_defaultMemberStatusId + '" (at "' + path_defaultMemberStatusId + '")');
1547
+ }
1548
+ })();
1549
+ if (obj_defaultMemberStatusId_union1_error != null) {
1550
+ obj_defaultMemberStatusId_union1 = obj_defaultMemberStatusId_union1_error.message;
1551
+ }
1552
+ if (obj_defaultMemberStatusId_union0 && obj_defaultMemberStatusId_union1) {
1553
+ let message = 'Object doesn\'t match union (at "' + path_defaultMemberStatusId + '")';
1554
+ message += '\n' + obj_defaultMemberStatusId_union0.split('\n').map((line) => '\t' + line).join('\n');
1555
+ message += '\n' + obj_defaultMemberStatusId_union1.split('\n').map((line) => '\t' + line).join('\n');
1556
+ return new TypeError(message);
1557
+ }
1558
+ }
1559
+ if (obj.description !== undefined) {
1560
+ const obj_description = obj.description;
1561
+ const path_description = path + '.description';
1562
+ let obj_description_union0 = null;
1563
+ const obj_description_union0_error = (() => {
1564
+ if (typeof obj_description !== 'string') {
1565
+ return new TypeError('Expected "string" but received "' + typeof obj_description + '" (at "' + path_description + '")');
1566
+ }
1567
+ })();
1568
+ if (obj_description_union0_error != null) {
1569
+ obj_description_union0 = obj_description_union0_error.message;
1570
+ }
1571
+ let obj_description_union1 = null;
1572
+ const obj_description_union1_error = (() => {
1573
+ if (obj_description !== null) {
1574
+ return new TypeError('Expected "null" but received "' + typeof obj_description + '" (at "' + path_description + '")');
1575
+ }
1576
+ })();
1577
+ if (obj_description_union1_error != null) {
1578
+ obj_description_union1 = obj_description_union1_error.message;
1579
+ }
1580
+ if (obj_description_union0 && obj_description_union1) {
1581
+ let message = 'Object doesn\'t match union (at "' + path_description + '")';
1582
+ message += '\n' + obj_description_union0.split('\n').map((line) => '\t' + line).join('\n');
1583
+ message += '\n' + obj_description_union1.split('\n').map((line) => '\t' + line).join('\n');
1584
+ return new TypeError(message);
1585
+ }
1586
+ }
1587
+ if (obj.filterLogic !== undefined) {
1588
+ const obj_filterLogic = obj.filterLogic;
1589
+ const path_filterLogic = path + '.filterLogic';
1590
+ if (typeof obj_filterLogic !== 'string') {
1591
+ return new TypeError('Expected "string" but received "' + typeof obj_filterLogic + '" (at "' + path_filterLogic + '")');
1592
+ }
1593
+ }
1594
+ if (obj.filters !== undefined) {
1595
+ const obj_filters = obj.filters;
1596
+ const path_filters = path + '.filters';
1597
+ if (typeof obj_filters !== 'object' || ArrayIsArray(obj_filters) || obj_filters === null) {
1598
+ return new TypeError('Expected "object" but received "' + typeof obj_filters + '" (at "' + path_filters + '")');
1599
+ }
1600
+ }
1601
+ if (obj.id !== undefined) {
1602
+ const obj_id = obj.id;
1603
+ const path_id = path + '.id';
1604
+ let obj_id_union0 = null;
1605
+ const obj_id_union0_error = (() => {
1606
+ if (typeof obj_id !== 'string') {
1607
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
1608
+ }
1609
+ })();
1610
+ if (obj_id_union0_error != null) {
1611
+ obj_id_union0 = obj_id_union0_error.message;
1612
+ }
1613
+ let obj_id_union1 = null;
1614
+ const obj_id_union1_error = (() => {
1615
+ if (obj_id !== null) {
1616
+ return new TypeError('Expected "null" but received "' + typeof obj_id + '" (at "' + path_id + '")');
1617
+ }
1618
+ })();
1619
+ if (obj_id_union1_error != null) {
1620
+ obj_id_union1 = obj_id_union1_error.message;
1621
+ }
1622
+ if (obj_id_union0 && obj_id_union1) {
1623
+ let message = 'Object doesn\'t match union (at "' + path_id + '")';
1624
+ message += '\n' + obj_id_union0.split('\n').map((line) => '\t' + line).join('\n');
1625
+ message += '\n' + obj_id_union1.split('\n').map((line) => '\t' + line).join('\n');
1626
+ return new TypeError(message);
1627
+ }
1628
+ }
1629
+ if (obj.isAsync !== undefined) {
1630
+ const obj_isAsync = obj.isAsync;
1631
+ const path_isAsync = path + '.isAsync';
1632
+ if (typeof obj_isAsync !== 'boolean') {
1633
+ return new TypeError('Expected "boolean" but received "' + typeof obj_isAsync + '" (at "' + path_isAsync + '")');
1634
+ }
1635
+ }
1636
+ if (obj.name !== undefined) {
1637
+ const obj_name = obj.name;
1638
+ const path_name = path + '.name';
1639
+ let obj_name_union0 = null;
1640
+ const obj_name_union0_error = (() => {
1641
+ if (typeof obj_name !== 'string') {
1642
+ return new TypeError('Expected "string" but received "' + typeof obj_name + '" (at "' + path_name + '")');
1643
+ }
1644
+ })();
1645
+ if (obj_name_union0_error != null) {
1646
+ obj_name_union0 = obj_name_union0_error.message;
1647
+ }
1648
+ let obj_name_union1 = null;
1649
+ const obj_name_union1_error = (() => {
1650
+ if (obj_name !== null) {
1651
+ return new TypeError('Expected "null" but received "' + typeof obj_name + '" (at "' + path_name + '")');
1652
+ }
1653
+ })();
1654
+ if (obj_name_union1_error != null) {
1655
+ obj_name_union1 = obj_name_union1_error.message;
1656
+ }
1657
+ if (obj_name_union0 && obj_name_union1) {
1658
+ let message = 'Object doesn\'t match union (at "' + path_name + '")';
1659
+ message += '\n' + obj_name_union0.split('\n').map((line) => '\t' + line).join('\n');
1660
+ message += '\n' + obj_name_union1.split('\n').map((line) => '\t' + line).join('\n');
1661
+ return new TypeError(message);
1662
+ }
1663
+ }
1664
+ if (obj.objectName !== undefined) {
1665
+ const obj_objectName = obj.objectName;
1666
+ const path_objectName = path + '.objectName';
1667
+ let obj_objectName_union0 = null;
1668
+ const obj_objectName_union0_error = (() => {
1669
+ if (typeof obj_objectName !== 'string') {
1670
+ return new TypeError('Expected "string" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
1671
+ }
1672
+ })();
1673
+ if (obj_objectName_union0_error != null) {
1674
+ obj_objectName_union0 = obj_objectName_union0_error.message;
1675
+ }
1676
+ let obj_objectName_union1 = null;
1677
+ const obj_objectName_union1_error = (() => {
1678
+ if (obj_objectName !== null) {
1679
+ return new TypeError('Expected "null" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
1680
+ }
1681
+ })();
1682
+ if (obj_objectName_union1_error != null) {
1683
+ obj_objectName_union1 = obj_objectName_union1_error.message;
1684
+ }
1685
+ if (obj_objectName_union0 && obj_objectName_union1) {
1686
+ let message = 'Object doesn\'t match union (at "' + path_objectName + '")';
1687
+ message += '\n' + obj_objectName_union0.split('\n').map((line) => '\t' + line).join('\n');
1688
+ message += '\n' + obj_objectName_union1.split('\n').map((line) => '\t' + line).join('\n');
1689
+ return new TypeError(message);
1690
+ }
1691
+ }
1692
+ })();
1693
+ return v_error === undefined ? null : v_error;
1694
+ }
1695
+
1696
+ const TTL$1 = 100;
1697
+ const VERSION$4 = "e644bfad74e67f4d67a107b89ef51c01";
1698
+ function validate$5(obj, path = 'ActionableListUpsertOutputRepresentation') {
1699
+ const v_error = (() => {
1700
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1701
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1702
+ }
1703
+ const obj_errorMessage = obj.errorMessage;
1704
+ const path_errorMessage = path + '.errorMessage';
1705
+ let obj_errorMessage_union0 = null;
1706
+ const obj_errorMessage_union0_error = (() => {
1707
+ if (typeof obj_errorMessage !== 'string') {
1708
+ return new TypeError('Expected "string" but received "' + typeof obj_errorMessage + '" (at "' + path_errorMessage + '")');
1709
+ }
1710
+ })();
1711
+ if (obj_errorMessage_union0_error != null) {
1712
+ obj_errorMessage_union0 = obj_errorMessage_union0_error.message;
1713
+ }
1714
+ let obj_errorMessage_union1 = null;
1715
+ const obj_errorMessage_union1_error = (() => {
1716
+ if (obj_errorMessage !== null) {
1717
+ return new TypeError('Expected "null" but received "' + typeof obj_errorMessage + '" (at "' + path_errorMessage + '")');
1718
+ }
1719
+ })();
1720
+ if (obj_errorMessage_union1_error != null) {
1721
+ obj_errorMessage_union1 = obj_errorMessage_union1_error.message;
1722
+ }
1723
+ if (obj_errorMessage_union0 && obj_errorMessage_union1) {
1724
+ let message = 'Object doesn\'t match union (at "' + path_errorMessage + '")';
1725
+ message += '\n' + obj_errorMessage_union0.split('\n').map((line) => '\t' + line).join('\n');
1726
+ message += '\n' + obj_errorMessage_union1.split('\n').map((line) => '\t' + line).join('\n');
1727
+ return new TypeError(message);
1728
+ }
1729
+ const obj_id = obj.id;
1730
+ const path_id = path + '.id';
1731
+ let obj_id_union0 = null;
1732
+ const obj_id_union0_error = (() => {
1733
+ if (typeof obj_id !== 'string') {
1734
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
1735
+ }
1736
+ })();
1737
+ if (obj_id_union0_error != null) {
1738
+ obj_id_union0 = obj_id_union0_error.message;
1739
+ }
1740
+ let obj_id_union1 = null;
1741
+ const obj_id_union1_error = (() => {
1742
+ if (obj_id !== null) {
1743
+ return new TypeError('Expected "null" but received "' + typeof obj_id + '" (at "' + path_id + '")');
1744
+ }
1745
+ })();
1746
+ if (obj_id_union1_error != null) {
1747
+ obj_id_union1 = obj_id_union1_error.message;
1748
+ }
1749
+ if (obj_id_union0 && obj_id_union1) {
1750
+ let message = 'Object doesn\'t match union (at "' + path_id + '")';
1751
+ message += '\n' + obj_id_union0.split('\n').map((line) => '\t' + line).join('\n');
1752
+ message += '\n' + obj_id_union1.split('\n').map((line) => '\t' + line).join('\n');
1753
+ return new TypeError(message);
1754
+ }
1755
+ const obj_isSuccess = obj.isSuccess;
1756
+ const path_isSuccess = path + '.isSuccess';
1757
+ let obj_isSuccess_union0 = null;
1758
+ const obj_isSuccess_union0_error = (() => {
1759
+ if (typeof obj_isSuccess !== 'string') {
1760
+ return new TypeError('Expected "string" but received "' + typeof obj_isSuccess + '" (at "' + path_isSuccess + '")');
1761
+ }
1762
+ })();
1763
+ if (obj_isSuccess_union0_error != null) {
1764
+ obj_isSuccess_union0 = obj_isSuccess_union0_error.message;
1765
+ }
1766
+ let obj_isSuccess_union1 = null;
1767
+ const obj_isSuccess_union1_error = (() => {
1768
+ if (obj_isSuccess !== null) {
1769
+ return new TypeError('Expected "null" but received "' + typeof obj_isSuccess + '" (at "' + path_isSuccess + '")');
1770
+ }
1771
+ })();
1772
+ if (obj_isSuccess_union1_error != null) {
1773
+ obj_isSuccess_union1 = obj_isSuccess_union1_error.message;
1774
+ }
1775
+ if (obj_isSuccess_union0 && obj_isSuccess_union1) {
1776
+ let message = 'Object doesn\'t match union (at "' + path_isSuccess + '")';
1777
+ message += '\n' + obj_isSuccess_union0.split('\n').map((line) => '\t' + line).join('\n');
1778
+ message += '\n' + obj_isSuccess_union1.split('\n').map((line) => '\t' + line).join('\n');
1779
+ return new TypeError(message);
1780
+ }
1781
+ })();
1782
+ return v_error === undefined ? null : v_error;
1783
+ }
1784
+ const RepresentationType$1 = 'ActionableListUpsertOutputRepresentation';
1785
+ function keyBuilder$2(luvio, config) {
1786
+ return keyPrefix + '::' + RepresentationType$1 + ':' + (config.id === null ? '' : config.id);
1787
+ }
1788
+ function keyBuilderFromType(luvio, object) {
1789
+ const keyParams = {
1790
+ id: object.id
1791
+ };
1792
+ return keyBuilder$2(luvio, keyParams);
1793
+ }
1794
+ function normalize$1(input, existing, path, luvio, store, timestamp) {
1795
+ return input;
1796
+ }
1797
+ const select$6 = function ActionableListUpsertOutputRepresentationSelect() {
1798
+ return {
1799
+ kind: 'Fragment',
1800
+ version: VERSION$4,
1801
+ private: [],
1802
+ selections: [
1803
+ {
1804
+ name: 'errorMessage',
1805
+ kind: 'Scalar'
1806
+ },
1807
+ {
1808
+ name: 'id',
1809
+ kind: 'Scalar'
1810
+ },
1811
+ {
1812
+ name: 'isSuccess',
1813
+ kind: 'Scalar'
1814
+ }
1815
+ ]
1816
+ };
1817
+ };
1818
+ function equals$4(existing, incoming) {
1819
+ const existing_errorMessage = existing.errorMessage;
1820
+ const incoming_errorMessage = incoming.errorMessage;
1821
+ if (!(existing_errorMessage === incoming_errorMessage)) {
1822
+ return false;
1823
+ }
1824
+ const existing_id = existing.id;
1825
+ const incoming_id = incoming.id;
1826
+ if (!(existing_id === incoming_id)) {
1827
+ return false;
1828
+ }
1829
+ const existing_isSuccess = existing.isSuccess;
1830
+ const incoming_isSuccess = incoming.isSuccess;
1831
+ if (!(existing_isSuccess === incoming_isSuccess)) {
1832
+ return false;
1833
+ }
1834
+ return true;
1835
+ }
1836
+ const ingest$1 = function ActionableListUpsertOutputRepresentationIngest(input, path, luvio, store, timestamp) {
1837
+ if (process.env.NODE_ENV !== 'production') {
1838
+ const validateError = validate$5(input);
1839
+ if (validateError !== null) {
1840
+ throw validateError;
1841
+ }
1842
+ }
1843
+ const key = keyBuilderFromType(luvio, input);
1844
+ const existingRecord = store.readEntry(key);
1845
+ const ttlToUse = TTL$1;
1846
+ let incomingRecord = normalize$1(input, store.readEntry(key), {
1847
+ fullPath: key,
1848
+ parent: path.parent,
1849
+ propertyName: path.propertyName,
1850
+ ttl: ttlToUse
1851
+ });
1852
+ if (existingRecord === undefined || equals$4(existingRecord, incomingRecord) === false) {
1853
+ luvio.storePublish(key, incomingRecord);
1854
+ }
1855
+ {
1856
+ const storeMetadataParams = {
1857
+ ttl: ttlToUse,
1858
+ namespace: "actionablelist",
1859
+ version: VERSION$4,
1860
+ representationName: RepresentationType$1,
1861
+ };
1862
+ luvio.publishStoreMetadata(key, storeMetadataParams);
1863
+ }
1864
+ return createLink(key);
1865
+ };
1866
+ function getTypeCacheKeys$1(luvio, input, fullPathFactory) {
1867
+ const rootKeySet = new engine.StoreKeyMap();
1868
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
1869
+ const rootKey = keyBuilderFromType(luvio, input);
1870
+ rootKeySet.set(rootKey, {
1871
+ namespace: keyPrefix,
1872
+ representationName: RepresentationType$1,
1873
+ mergeable: false
1874
+ });
1875
+ return rootKeySet;
1876
+ }
1877
+
1878
+ function select$5(luvio, params) {
1879
+ return select$6();
1880
+ }
1881
+ function getResponseCacheKeys$1(luvio, resourceParams, response) {
1882
+ return getTypeCacheKeys$1(luvio, response);
1883
+ }
1884
+ function ingestSuccess$1(luvio, resourceParams, response) {
1885
+ const { body } = response;
1886
+ const key = keyBuilderFromType(luvio, body);
1887
+ luvio.storeIngest(key, ingest$1, body);
1888
+ const snapshot = luvio.storeLookup({
1889
+ recordId: key,
1890
+ node: select$5(),
1891
+ variables: {},
1892
+ });
1893
+ if (process.env.NODE_ENV !== 'production') {
1894
+ if (snapshot.state !== 'Fulfilled') {
1895
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
1896
+ }
1897
+ }
1898
+ return snapshot;
1899
+ }
1900
+ function createResourceRequest$1(config) {
1901
+ const headers = {};
1902
+ return {
1903
+ baseUri: '/services/data/v58.0',
1904
+ basePath: '/connect/actionable-list',
1905
+ method: 'post',
1906
+ body: config.body,
1907
+ urlParams: {},
1908
+ queryParams: {},
1909
+ headers,
1910
+ priority: 'normal',
1911
+ };
1912
+ }
1913
+
1914
+ const upsertActionableList_ConfigPropertyNames = {
1915
+ displayName: 'upsertActionableList',
1916
+ parameters: {
1917
+ required: ['actionableListUpsertInput'],
1918
+ optional: []
1919
+ }
1920
+ };
1921
+ function createResourceParams$1(config) {
1922
+ const resourceParams = {
1923
+ body: {
1924
+ actionableListUpsertInput: config.actionableListUpsertInput
1925
+ }
1926
+ };
1927
+ return resourceParams;
1928
+ }
1929
+ function typeCheckConfig$1(untrustedConfig) {
1930
+ const config = {};
1931
+ const untrustedConfig_actionableListUpsertInput = untrustedConfig.actionableListUpsertInput;
1932
+ const referenceActionableListUpsertInputRepresentationValidationError = validate$6(untrustedConfig_actionableListUpsertInput);
1933
+ if (referenceActionableListUpsertInputRepresentationValidationError === null) {
1934
+ config.actionableListUpsertInput = untrustedConfig_actionableListUpsertInput;
1935
+ }
1936
+ return config;
1937
+ }
1938
+ function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
1939
+ if (!untrustedIsObject(untrustedConfig)) {
1940
+ return null;
1941
+ }
1942
+ if (process.env.NODE_ENV !== 'production') {
1943
+ validateConfig(untrustedConfig, configPropertyNames);
1944
+ }
1945
+ const config = typeCheckConfig$1(untrustedConfig);
1946
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
1947
+ return null;
1948
+ }
1949
+ return config;
1950
+ }
1951
+ function buildNetworkSnapshot$1(luvio, config, options) {
1952
+ const resourceParams = createResourceParams$1(config);
1953
+ const request = createResourceRequest$1(resourceParams);
1954
+ return luvio.dispatchResourceRequest(request, options)
1955
+ .then((response) => {
1956
+ return luvio.handleSuccessResponse(() => {
1957
+ const snapshot = ingestSuccess$1(luvio, resourceParams, response);
1958
+ return luvio.storeBroadcast().then(() => snapshot);
1959
+ }, () => getResponseCacheKeys$1(luvio, resourceParams, response.body));
1960
+ }, (response) => {
1961
+ deepFreeze(response);
1962
+ throw response;
1963
+ });
1964
+ }
1965
+ const upsertActionableListAdapterFactory = (luvio) => {
1966
+ return function upsertActionableList(untrustedConfig) {
1967
+ const config = validateAdapterConfig$1(untrustedConfig, upsertActionableList_ConfigPropertyNames);
1968
+ // Invalid or incomplete config
1969
+ if (config === null) {
1970
+ throw new Error('Invalid config for "upsertActionableList"');
1971
+ }
1972
+ return buildNetworkSnapshot$1(luvio, config);
1973
+ };
1974
+ };
1975
+
1976
+ function validate$4(obj, path = 'ActionableListDatasetInputRepresentation') {
1977
+ const v_error = (() => {
1978
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
1979
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
1980
+ }
1981
+ if (obj.actionableListDefinitionId !== undefined) {
1982
+ const obj_actionableListDefinitionId = obj.actionableListDefinitionId;
1983
+ const path_actionableListDefinitionId = path + '.actionableListDefinitionId';
1984
+ let obj_actionableListDefinitionId_union0 = null;
1985
+ const obj_actionableListDefinitionId_union0_error = (() => {
1986
+ if (typeof obj_actionableListDefinitionId !== 'string') {
1987
+ return new TypeError('Expected "string" but received "' + typeof obj_actionableListDefinitionId + '" (at "' + path_actionableListDefinitionId + '")');
1988
+ }
1989
+ })();
1990
+ if (obj_actionableListDefinitionId_union0_error != null) {
1991
+ obj_actionableListDefinitionId_union0 = obj_actionableListDefinitionId_union0_error.message;
1992
+ }
1993
+ let obj_actionableListDefinitionId_union1 = null;
1994
+ const obj_actionableListDefinitionId_union1_error = (() => {
1995
+ if (obj_actionableListDefinitionId !== null) {
1996
+ return new TypeError('Expected "null" but received "' + typeof obj_actionableListDefinitionId + '" (at "' + path_actionableListDefinitionId + '")');
1997
+ }
1998
+ })();
1999
+ if (obj_actionableListDefinitionId_union1_error != null) {
2000
+ obj_actionableListDefinitionId_union1 = obj_actionableListDefinitionId_union1_error.message;
2001
+ }
2002
+ if (obj_actionableListDefinitionId_union0 && obj_actionableListDefinitionId_union1) {
2003
+ let message = 'Object doesn\'t match union (at "' + path_actionableListDefinitionId + '")';
2004
+ message += '\n' + obj_actionableListDefinitionId_union0.split('\n').map((line) => '\t' + line).join('\n');
2005
+ message += '\n' + obj_actionableListDefinitionId_union1.split('\n').map((line) => '\t' + line).join('\n');
2006
+ return new TypeError(message);
2007
+ }
2008
+ }
2009
+ if (obj.filterLogic !== undefined) {
2010
+ const obj_filterLogic = obj.filterLogic;
2011
+ const path_filterLogic = path + '.filterLogic';
2012
+ if (typeof obj_filterLogic !== 'string') {
2013
+ return new TypeError('Expected "string" but received "' + typeof obj_filterLogic + '" (at "' + path_filterLogic + '")');
2014
+ }
2015
+ }
2016
+ if (obj.filters !== undefined) {
2017
+ const obj_filters = obj.filters;
2018
+ const path_filters = path + '.filters';
2019
+ if (typeof obj_filters !== 'object' || ArrayIsArray(obj_filters) || obj_filters === null) {
2020
+ return new TypeError('Expected "object" but received "' + typeof obj_filters + '" (at "' + path_filters + '")');
2021
+ }
2022
+ }
2023
+ if (obj.offset !== undefined) {
2024
+ const obj_offset = obj.offset;
2025
+ const path_offset = path + '.offset';
2026
+ let obj_offset_union0 = null;
2027
+ const obj_offset_union0_error = (() => {
2028
+ if (typeof obj_offset !== 'number' || (typeof obj_offset === 'number' && Math.floor(obj_offset) !== obj_offset)) {
2029
+ return new TypeError('Expected "integer" but received "' + typeof obj_offset + '" (at "' + path_offset + '")');
2030
+ }
2031
+ })();
2032
+ if (obj_offset_union0_error != null) {
2033
+ obj_offset_union0 = obj_offset_union0_error.message;
2034
+ }
2035
+ let obj_offset_union1 = null;
2036
+ const obj_offset_union1_error = (() => {
2037
+ if (obj_offset !== null) {
2038
+ return new TypeError('Expected "null" but received "' + typeof obj_offset + '" (at "' + path_offset + '")');
2039
+ }
2040
+ })();
2041
+ if (obj_offset_union1_error != null) {
2042
+ obj_offset_union1 = obj_offset_union1_error.message;
2043
+ }
2044
+ if (obj_offset_union0 && obj_offset_union1) {
2045
+ let message = 'Object doesn\'t match union (at "' + path_offset + '")';
2046
+ message += '\n' + obj_offset_union0.split('\n').map((line) => '\t' + line).join('\n');
2047
+ message += '\n' + obj_offset_union1.split('\n').map((line) => '\t' + line).join('\n');
2048
+ return new TypeError(message);
2049
+ }
2050
+ }
2051
+ if (obj.orderBy !== undefined) {
2052
+ const obj_orderBy = obj.orderBy;
2053
+ const path_orderBy = path + '.orderBy';
2054
+ let obj_orderBy_union0 = null;
2055
+ const obj_orderBy_union0_error = (() => {
2056
+ if (typeof obj_orderBy !== 'string') {
2057
+ return new TypeError('Expected "string" but received "' + typeof obj_orderBy + '" (at "' + path_orderBy + '")');
2058
+ }
2059
+ })();
2060
+ if (obj_orderBy_union0_error != null) {
2061
+ obj_orderBy_union0 = obj_orderBy_union0_error.message;
2062
+ }
2063
+ let obj_orderBy_union1 = null;
2064
+ const obj_orderBy_union1_error = (() => {
2065
+ if (obj_orderBy !== null) {
2066
+ return new TypeError('Expected "null" but received "' + typeof obj_orderBy + '" (at "' + path_orderBy + '")');
2067
+ }
2068
+ })();
2069
+ if (obj_orderBy_union1_error != null) {
2070
+ obj_orderBy_union1 = obj_orderBy_union1_error.message;
2071
+ }
2072
+ if (obj_orderBy_union0 && obj_orderBy_union1) {
2073
+ let message = 'Object doesn\'t match union (at "' + path_orderBy + '")';
2074
+ message += '\n' + obj_orderBy_union0.split('\n').map((line) => '\t' + line).join('\n');
2075
+ message += '\n' + obj_orderBy_union1.split('\n').map((line) => '\t' + line).join('\n');
2076
+ return new TypeError(message);
2077
+ }
2078
+ }
2079
+ if (obj.rowLimit !== undefined) {
2080
+ const obj_rowLimit = obj.rowLimit;
2081
+ const path_rowLimit = path + '.rowLimit';
2082
+ let obj_rowLimit_union0 = null;
2083
+ const obj_rowLimit_union0_error = (() => {
2084
+ if (typeof obj_rowLimit !== 'number' || (typeof obj_rowLimit === 'number' && Math.floor(obj_rowLimit) !== obj_rowLimit)) {
2085
+ return new TypeError('Expected "integer" but received "' + typeof obj_rowLimit + '" (at "' + path_rowLimit + '")');
2086
+ }
2087
+ })();
2088
+ if (obj_rowLimit_union0_error != null) {
2089
+ obj_rowLimit_union0 = obj_rowLimit_union0_error.message;
2090
+ }
2091
+ let obj_rowLimit_union1 = null;
2092
+ const obj_rowLimit_union1_error = (() => {
2093
+ if (obj_rowLimit !== null) {
2094
+ return new TypeError('Expected "null" but received "' + typeof obj_rowLimit + '" (at "' + path_rowLimit + '")');
2095
+ }
2096
+ })();
2097
+ if (obj_rowLimit_union1_error != null) {
2098
+ obj_rowLimit_union1 = obj_rowLimit_union1_error.message;
2099
+ }
2100
+ if (obj_rowLimit_union0 && obj_rowLimit_union1) {
2101
+ let message = 'Object doesn\'t match union (at "' + path_rowLimit + '")';
2102
+ message += '\n' + obj_rowLimit_union0.split('\n').map((line) => '\t' + line).join('\n');
2103
+ message += '\n' + obj_rowLimit_union1.split('\n').map((line) => '\t' + line).join('\n');
2104
+ return new TypeError(message);
2105
+ }
2106
+ }
2107
+ if (obj.shouldReturnCurrencyCode !== undefined) {
2108
+ const obj_shouldReturnCurrencyCode = obj.shouldReturnCurrencyCode;
2109
+ const path_shouldReturnCurrencyCode = path + '.shouldReturnCurrencyCode';
2110
+ if (typeof obj_shouldReturnCurrencyCode !== 'boolean') {
2111
+ return new TypeError('Expected "boolean" but received "' + typeof obj_shouldReturnCurrencyCode + '" (at "' + path_shouldReturnCurrencyCode + '")');
2112
+ }
2113
+ }
2114
+ if (obj.sortOrder !== undefined) {
2115
+ const obj_sortOrder = obj.sortOrder;
2116
+ const path_sortOrder = path + '.sortOrder';
2117
+ let obj_sortOrder_union0 = null;
2118
+ const obj_sortOrder_union0_error = (() => {
2119
+ if (typeof obj_sortOrder !== 'string') {
2120
+ return new TypeError('Expected "string" but received "' + typeof obj_sortOrder + '" (at "' + path_sortOrder + '")');
2121
+ }
2122
+ })();
2123
+ if (obj_sortOrder_union0_error != null) {
2124
+ obj_sortOrder_union0 = obj_sortOrder_union0_error.message;
2125
+ }
2126
+ let obj_sortOrder_union1 = null;
2127
+ const obj_sortOrder_union1_error = (() => {
2128
+ if (obj_sortOrder !== null) {
2129
+ return new TypeError('Expected "null" but received "' + typeof obj_sortOrder + '" (at "' + path_sortOrder + '")');
2130
+ }
2131
+ })();
2132
+ if (obj_sortOrder_union1_error != null) {
2133
+ obj_sortOrder_union1 = obj_sortOrder_union1_error.message;
2134
+ }
2135
+ if (obj_sortOrder_union0 && obj_sortOrder_union1) {
2136
+ let message = 'Object doesn\'t match union (at "' + path_sortOrder + '")';
2137
+ message += '\n' + obj_sortOrder_union0.split('\n').map((line) => '\t' + line).join('\n');
2138
+ message += '\n' + obj_sortOrder_union1.split('\n').map((line) => '\t' + line).join('\n');
2139
+ return new TypeError(message);
2140
+ }
2141
+ }
2142
+ })();
2143
+ return v_error === undefined ? null : v_error;
2144
+ }
2145
+
2146
+ const VERSION$3 = "0d035b8885aca0b70b9d3d7cec487492";
2147
+ function validate$3(obj, path = 'ActionableListDatasetColumnRepresentation') {
2148
+ const v_error = (() => {
2149
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2150
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
2151
+ }
2152
+ const obj_dataDomain = obj.dataDomain;
2153
+ const path_dataDomain = path + '.dataDomain';
2154
+ let obj_dataDomain_union0 = null;
2155
+ const obj_dataDomain_union0_error = (() => {
2156
+ if (typeof obj_dataDomain !== 'string') {
2157
+ return new TypeError('Expected "string" but received "' + typeof obj_dataDomain + '" (at "' + path_dataDomain + '")');
2158
+ }
2159
+ })();
2160
+ if (obj_dataDomain_union0_error != null) {
2161
+ obj_dataDomain_union0 = obj_dataDomain_union0_error.message;
2162
+ }
2163
+ let obj_dataDomain_union1 = null;
2164
+ const obj_dataDomain_union1_error = (() => {
2165
+ if (obj_dataDomain !== null) {
2166
+ return new TypeError('Expected "null" but received "' + typeof obj_dataDomain + '" (at "' + path_dataDomain + '")');
2167
+ }
2168
+ })();
2169
+ if (obj_dataDomain_union1_error != null) {
2170
+ obj_dataDomain_union1 = obj_dataDomain_union1_error.message;
2171
+ }
2172
+ if (obj_dataDomain_union0 && obj_dataDomain_union1) {
2173
+ let message = 'Object doesn\'t match union (at "' + path_dataDomain + '")';
2174
+ message += '\n' + obj_dataDomain_union0.split('\n').map((line) => '\t' + line).join('\n');
2175
+ message += '\n' + obj_dataDomain_union1.split('\n').map((line) => '\t' + line).join('\n');
2176
+ return new TypeError(message);
2177
+ }
2178
+ const obj_dataType = obj.dataType;
2179
+ const path_dataType = path + '.dataType';
2180
+ let obj_dataType_union0 = null;
2181
+ const obj_dataType_union0_error = (() => {
2182
+ if (typeof obj_dataType !== 'string') {
2183
+ return new TypeError('Expected "string" but received "' + typeof obj_dataType + '" (at "' + path_dataType + '")');
2184
+ }
2185
+ })();
2186
+ if (obj_dataType_union0_error != null) {
2187
+ obj_dataType_union0 = obj_dataType_union0_error.message;
2188
+ }
2189
+ let obj_dataType_union1 = null;
2190
+ const obj_dataType_union1_error = (() => {
2191
+ if (obj_dataType !== null) {
2192
+ return new TypeError('Expected "null" but received "' + typeof obj_dataType + '" (at "' + path_dataType + '")');
2193
+ }
2194
+ })();
2195
+ if (obj_dataType_union1_error != null) {
2196
+ obj_dataType_union1 = obj_dataType_union1_error.message;
2197
+ }
2198
+ if (obj_dataType_union0 && obj_dataType_union1) {
2199
+ let message = 'Object doesn\'t match union (at "' + path_dataType + '")';
2200
+ message += '\n' + obj_dataType_union0.split('\n').map((line) => '\t' + line).join('\n');
2201
+ message += '\n' + obj_dataType_union1.split('\n').map((line) => '\t' + line).join('\n');
2202
+ return new TypeError(message);
2203
+ }
2204
+ const obj_isDefault = obj.isDefault;
2205
+ const path_isDefault = path + '.isDefault';
2206
+ let obj_isDefault_union0 = null;
2207
+ const obj_isDefault_union0_error = (() => {
2208
+ if (typeof obj_isDefault !== 'boolean') {
2209
+ return new TypeError('Expected "boolean" but received "' + typeof obj_isDefault + '" (at "' + path_isDefault + '")');
2210
+ }
2211
+ })();
2212
+ if (obj_isDefault_union0_error != null) {
2213
+ obj_isDefault_union0 = obj_isDefault_union0_error.message;
2214
+ }
2215
+ let obj_isDefault_union1 = null;
2216
+ const obj_isDefault_union1_error = (() => {
2217
+ if (obj_isDefault !== null) {
2218
+ return new TypeError('Expected "null" but received "' + typeof obj_isDefault + '" (at "' + path_isDefault + '")');
2219
+ }
2220
+ })();
2221
+ if (obj_isDefault_union1_error != null) {
2222
+ obj_isDefault_union1 = obj_isDefault_union1_error.message;
2223
+ }
2224
+ if (obj_isDefault_union0 && obj_isDefault_union1) {
2225
+ let message = 'Object doesn\'t match union (at "' + path_isDefault + '")';
2226
+ message += '\n' + obj_isDefault_union0.split('\n').map((line) => '\t' + line).join('\n');
2227
+ message += '\n' + obj_isDefault_union1.split('\n').map((line) => '\t' + line).join('\n');
2228
+ return new TypeError(message);
2229
+ }
2230
+ const obj_objectName = obj.objectName;
2231
+ const path_objectName = path + '.objectName';
2232
+ let obj_objectName_union0 = null;
2233
+ const obj_objectName_union0_error = (() => {
2234
+ if (typeof obj_objectName !== 'string') {
2235
+ return new TypeError('Expected "string" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
2236
+ }
2237
+ })();
2238
+ if (obj_objectName_union0_error != null) {
2239
+ obj_objectName_union0 = obj_objectName_union0_error.message;
2240
+ }
2241
+ let obj_objectName_union1 = null;
2242
+ const obj_objectName_union1_error = (() => {
2243
+ if (obj_objectName !== null) {
2244
+ return new TypeError('Expected "null" but received "' + typeof obj_objectName + '" (at "' + path_objectName + '")');
2245
+ }
2246
+ })();
2247
+ if (obj_objectName_union1_error != null) {
2248
+ obj_objectName_union1 = obj_objectName_union1_error.message;
2249
+ }
2250
+ if (obj_objectName_union0 && obj_objectName_union1) {
2251
+ let message = 'Object doesn\'t match union (at "' + path_objectName + '")';
2252
+ message += '\n' + obj_objectName_union0.split('\n').map((line) => '\t' + line).join('\n');
2253
+ message += '\n' + obj_objectName_union1.split('\n').map((line) => '\t' + line).join('\n');
2254
+ return new TypeError(message);
2255
+ }
2256
+ const obj_sourceColumnApiName = obj.sourceColumnApiName;
2257
+ const path_sourceColumnApiName = path + '.sourceColumnApiName';
2258
+ let obj_sourceColumnApiName_union0 = null;
2259
+ const obj_sourceColumnApiName_union0_error = (() => {
2260
+ if (typeof obj_sourceColumnApiName !== 'string') {
2261
+ return new TypeError('Expected "string" but received "' + typeof obj_sourceColumnApiName + '" (at "' + path_sourceColumnApiName + '")');
2262
+ }
2263
+ })();
2264
+ if (obj_sourceColumnApiName_union0_error != null) {
2265
+ obj_sourceColumnApiName_union0 = obj_sourceColumnApiName_union0_error.message;
2266
+ }
2267
+ let obj_sourceColumnApiName_union1 = null;
2268
+ const obj_sourceColumnApiName_union1_error = (() => {
2269
+ if (obj_sourceColumnApiName !== null) {
2270
+ return new TypeError('Expected "null" but received "' + typeof obj_sourceColumnApiName + '" (at "' + path_sourceColumnApiName + '")');
2271
+ }
2272
+ })();
2273
+ if (obj_sourceColumnApiName_union1_error != null) {
2274
+ obj_sourceColumnApiName_union1 = obj_sourceColumnApiName_union1_error.message;
2275
+ }
2276
+ if (obj_sourceColumnApiName_union0 && obj_sourceColumnApiName_union1) {
2277
+ let message = 'Object doesn\'t match union (at "' + path_sourceColumnApiName + '")';
2278
+ message += '\n' + obj_sourceColumnApiName_union0.split('\n').map((line) => '\t' + line).join('\n');
2279
+ message += '\n' + obj_sourceColumnApiName_union1.split('\n').map((line) => '\t' + line).join('\n');
2280
+ return new TypeError(message);
2281
+ }
2282
+ const obj_sourceFieldName = obj.sourceFieldName;
2283
+ const path_sourceFieldName = path + '.sourceFieldName';
2284
+ let obj_sourceFieldName_union0 = null;
2285
+ const obj_sourceFieldName_union0_error = (() => {
2286
+ if (typeof obj_sourceFieldName !== 'string') {
2287
+ return new TypeError('Expected "string" but received "' + typeof obj_sourceFieldName + '" (at "' + path_sourceFieldName + '")');
2288
+ }
2289
+ })();
2290
+ if (obj_sourceFieldName_union0_error != null) {
2291
+ obj_sourceFieldName_union0 = obj_sourceFieldName_union0_error.message;
2292
+ }
2293
+ let obj_sourceFieldName_union1 = null;
2294
+ const obj_sourceFieldName_union1_error = (() => {
2295
+ if (obj_sourceFieldName !== null) {
2296
+ return new TypeError('Expected "null" but received "' + typeof obj_sourceFieldName + '" (at "' + path_sourceFieldName + '")');
2297
+ }
2298
+ })();
2299
+ if (obj_sourceFieldName_union1_error != null) {
2300
+ obj_sourceFieldName_union1 = obj_sourceFieldName_union1_error.message;
2301
+ }
2302
+ if (obj_sourceFieldName_union0 && obj_sourceFieldName_union1) {
2303
+ let message = 'Object doesn\'t match union (at "' + path_sourceFieldName + '")';
2304
+ message += '\n' + obj_sourceFieldName_union0.split('\n').map((line) => '\t' + line).join('\n');
2305
+ message += '\n' + obj_sourceFieldName_union1.split('\n').map((line) => '\t' + line).join('\n');
2306
+ return new TypeError(message);
2307
+ }
2308
+ })();
2309
+ return v_error === undefined ? null : v_error;
2310
+ }
2311
+ const select$4 = function ActionableListDatasetColumnRepresentationSelect() {
2312
+ return {
2313
+ kind: 'Fragment',
2314
+ version: VERSION$3,
2315
+ private: [],
2316
+ selections: [
2317
+ {
2318
+ name: 'dataDomain',
2319
+ kind: 'Scalar'
2320
+ },
2321
+ {
2322
+ name: 'dataType',
2323
+ kind: 'Scalar'
2324
+ },
2325
+ {
2326
+ name: 'isDefault',
2327
+ kind: 'Scalar'
2328
+ },
2329
+ {
2330
+ name: 'objectName',
2331
+ kind: 'Scalar'
2332
+ },
2333
+ {
2334
+ name: 'sourceColumnApiName',
2335
+ kind: 'Scalar'
2336
+ },
2337
+ {
2338
+ name: 'sourceFieldName',
2339
+ kind: 'Scalar'
2340
+ }
2341
+ ]
2342
+ };
2343
+ };
2344
+ function equals$3(existing, incoming) {
2345
+ const existing_dataDomain = existing.dataDomain;
2346
+ const incoming_dataDomain = incoming.dataDomain;
2347
+ if (!(existing_dataDomain === incoming_dataDomain)) {
2348
+ return false;
2349
+ }
2350
+ const existing_dataType = existing.dataType;
2351
+ const incoming_dataType = incoming.dataType;
2352
+ if (!(existing_dataType === incoming_dataType)) {
2353
+ return false;
2354
+ }
2355
+ const existing_isDefault = existing.isDefault;
2356
+ const incoming_isDefault = incoming.isDefault;
2357
+ if (!(existing_isDefault === incoming_isDefault)) {
2358
+ return false;
2359
+ }
2360
+ const existing_objectName = existing.objectName;
2361
+ const incoming_objectName = incoming.objectName;
2362
+ if (!(existing_objectName === incoming_objectName)) {
2363
+ return false;
2364
+ }
2365
+ const existing_sourceColumnApiName = existing.sourceColumnApiName;
2366
+ const incoming_sourceColumnApiName = incoming.sourceColumnApiName;
2367
+ if (!(existing_sourceColumnApiName === incoming_sourceColumnApiName)) {
2368
+ return false;
2369
+ }
2370
+ const existing_sourceFieldName = existing.sourceFieldName;
2371
+ const incoming_sourceFieldName = incoming.sourceFieldName;
2372
+ if (!(existing_sourceFieldName === incoming_sourceFieldName)) {
2373
+ return false;
2374
+ }
2375
+ return true;
2376
+ }
2377
+
2378
+ const VERSION$2 = "ad799b06e079ea81d47ce361336c5282";
2379
+ function validate$2(obj, path = 'ActionableListDatasetRowRepresentation') {
2380
+ const v_error = (() => {
2381
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2382
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
2383
+ }
2384
+ const obj_rowMap = obj.rowMap;
2385
+ const path_rowMap = path + '.rowMap';
2386
+ if (typeof obj_rowMap !== 'object' || ArrayIsArray(obj_rowMap) || obj_rowMap === null) {
2387
+ return new TypeError('Expected "object" but received "' + typeof obj_rowMap + '" (at "' + path_rowMap + '")');
2388
+ }
2389
+ const obj_rowMap_keys = ObjectKeys(obj_rowMap);
2390
+ for (let i = 0; i < obj_rowMap_keys.length; i++) {
2391
+ const key = obj_rowMap_keys[i];
2392
+ const obj_rowMap_prop = obj_rowMap[key];
2393
+ const path_rowMap_prop = path_rowMap + '["' + key + '"]';
2394
+ if (typeof obj_rowMap_prop !== 'string') {
2395
+ return new TypeError('Expected "string" but received "' + typeof obj_rowMap_prop + '" (at "' + path_rowMap_prop + '")');
2396
+ }
2397
+ }
2398
+ })();
2399
+ return v_error === undefined ? null : v_error;
2400
+ }
2401
+ const select$3 = function ActionableListDatasetRowRepresentationSelect() {
2402
+ return {
2403
+ kind: 'Fragment',
2404
+ version: VERSION$2,
2405
+ private: [],
2406
+ selections: [
2407
+ {
2408
+ name: 'rowMap',
2409
+ kind: 'Scalar',
2410
+ map: true
2411
+ }
2412
+ ]
2413
+ };
2414
+ };
2415
+ function equals$2(existing, incoming) {
2416
+ const existing_rowMap = existing.rowMap;
2417
+ const incoming_rowMap = incoming.rowMap;
2418
+ const equals_rowMap_props = equalsObject(existing_rowMap, incoming_rowMap, (existing_rowMap_prop, incoming_rowMap_prop) => {
2419
+ if (!(existing_rowMap_prop === incoming_rowMap_prop)) {
2420
+ return false;
2421
+ }
2422
+ });
2423
+ if (equals_rowMap_props === false) {
2424
+ return false;
2425
+ }
2426
+ return true;
2427
+ }
2428
+
2429
+ const VERSION$1 = "4ddcc2754150af16fd09c10d9fdabfbc";
2430
+ function validate$1(obj, path = 'ActionableListMemberStatusRepresentation') {
2431
+ const v_error = (() => {
2432
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2433
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
2434
+ }
2435
+ const obj_iconName = obj.iconName;
2436
+ const path_iconName = path + '.iconName';
2437
+ let obj_iconName_union0 = null;
2438
+ const obj_iconName_union0_error = (() => {
2439
+ if (typeof obj_iconName !== 'string') {
2440
+ return new TypeError('Expected "string" but received "' + typeof obj_iconName + '" (at "' + path_iconName + '")');
2441
+ }
2442
+ })();
2443
+ if (obj_iconName_union0_error != null) {
2444
+ obj_iconName_union0 = obj_iconName_union0_error.message;
2445
+ }
2446
+ let obj_iconName_union1 = null;
2447
+ const obj_iconName_union1_error = (() => {
2448
+ if (obj_iconName !== null) {
2449
+ return new TypeError('Expected "null" but received "' + typeof obj_iconName + '" (at "' + path_iconName + '")');
2450
+ }
2451
+ })();
2452
+ if (obj_iconName_union1_error != null) {
2453
+ obj_iconName_union1 = obj_iconName_union1_error.message;
2454
+ }
2455
+ if (obj_iconName_union0 && obj_iconName_union1) {
2456
+ let message = 'Object doesn\'t match union (at "' + path_iconName + '")';
2457
+ message += '\n' + obj_iconName_union0.split('\n').map((line) => '\t' + line).join('\n');
2458
+ message += '\n' + obj_iconName_union1.split('\n').map((line) => '\t' + line).join('\n');
2459
+ return new TypeError(message);
2460
+ }
2461
+ const obj_id = obj.id;
2462
+ const path_id = path + '.id';
2463
+ let obj_id_union0 = null;
2464
+ const obj_id_union0_error = (() => {
2465
+ if (typeof obj_id !== 'string') {
2466
+ return new TypeError('Expected "string" but received "' + typeof obj_id + '" (at "' + path_id + '")');
2467
+ }
2468
+ })();
2469
+ if (obj_id_union0_error != null) {
2470
+ obj_id_union0 = obj_id_union0_error.message;
2471
+ }
2472
+ let obj_id_union1 = null;
2473
+ const obj_id_union1_error = (() => {
2474
+ if (obj_id !== null) {
2475
+ return new TypeError('Expected "null" but received "' + typeof obj_id + '" (at "' + path_id + '")');
2476
+ }
2477
+ })();
2478
+ if (obj_id_union1_error != null) {
2479
+ obj_id_union1 = obj_id_union1_error.message;
2480
+ }
2481
+ if (obj_id_union0 && obj_id_union1) {
2482
+ let message = 'Object doesn\'t match union (at "' + path_id + '")';
2483
+ message += '\n' + obj_id_union0.split('\n').map((line) => '\t' + line).join('\n');
2484
+ message += '\n' + obj_id_union1.split('\n').map((line) => '\t' + line).join('\n');
2485
+ return new TypeError(message);
2486
+ }
2487
+ const obj_status = obj.status;
2488
+ const path_status = path + '.status';
2489
+ let obj_status_union0 = null;
2490
+ const obj_status_union0_error = (() => {
2491
+ if (typeof obj_status !== 'string') {
2492
+ return new TypeError('Expected "string" but received "' + typeof obj_status + '" (at "' + path_status + '")');
2493
+ }
2494
+ })();
2495
+ if (obj_status_union0_error != null) {
2496
+ obj_status_union0 = obj_status_union0_error.message;
2497
+ }
2498
+ let obj_status_union1 = null;
2499
+ const obj_status_union1_error = (() => {
2500
+ if (obj_status !== null) {
2501
+ return new TypeError('Expected "null" but received "' + typeof obj_status + '" (at "' + path_status + '")');
2502
+ }
2503
+ })();
2504
+ if (obj_status_union1_error != null) {
2505
+ obj_status_union1 = obj_status_union1_error.message;
2506
+ }
2507
+ if (obj_status_union0 && obj_status_union1) {
2508
+ let message = 'Object doesn\'t match union (at "' + path_status + '")';
2509
+ message += '\n' + obj_status_union0.split('\n').map((line) => '\t' + line).join('\n');
2510
+ message += '\n' + obj_status_union1.split('\n').map((line) => '\t' + line).join('\n');
2511
+ return new TypeError(message);
2512
+ }
2513
+ })();
2514
+ return v_error === undefined ? null : v_error;
2515
+ }
2516
+ const select$2 = function ActionableListMemberStatusRepresentationSelect() {
2517
+ return {
2518
+ kind: 'Fragment',
2519
+ version: VERSION$1,
2520
+ private: [],
2521
+ selections: [
2522
+ {
2523
+ name: 'iconName',
2524
+ kind: 'Scalar'
2525
+ },
2526
+ {
2527
+ name: 'id',
2528
+ kind: 'Scalar'
2529
+ },
2530
+ {
2531
+ name: 'status',
2532
+ kind: 'Scalar'
2533
+ }
2534
+ ]
2535
+ };
2536
+ };
2537
+ function equals$1(existing, incoming) {
2538
+ const existing_iconName = existing.iconName;
2539
+ const incoming_iconName = incoming.iconName;
2540
+ if (!(existing_iconName === incoming_iconName)) {
2541
+ return false;
2542
+ }
2543
+ const existing_id = existing.id;
2544
+ const incoming_id = incoming.id;
2545
+ if (!(existing_id === incoming_id)) {
2546
+ return false;
2547
+ }
2548
+ const existing_status = existing.status;
2549
+ const incoming_status = incoming.status;
2550
+ if (!(existing_status === incoming_status)) {
2551
+ return false;
2552
+ }
2553
+ return true;
2554
+ }
2555
+
2556
+ const TTL = 100;
2557
+ const VERSION = "c2472d63cf7565f324c596127a5840a6";
2558
+ function validate(obj, path = 'ActionableListDatasetByDefinitionRepresentation') {
2559
+ const v_error = (() => {
2560
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
2561
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
2562
+ }
2563
+ const obj_currencyCode = obj.currencyCode;
2564
+ const path_currencyCode = path + '.currencyCode';
2565
+ let obj_currencyCode_union0 = null;
2566
+ const obj_currencyCode_union0_error = (() => {
2567
+ if (typeof obj_currencyCode !== 'string') {
2568
+ return new TypeError('Expected "string" but received "' + typeof obj_currencyCode + '" (at "' + path_currencyCode + '")');
2569
+ }
2570
+ })();
2571
+ if (obj_currencyCode_union0_error != null) {
2572
+ obj_currencyCode_union0 = obj_currencyCode_union0_error.message;
2573
+ }
2574
+ let obj_currencyCode_union1 = null;
2575
+ const obj_currencyCode_union1_error = (() => {
2576
+ if (obj_currencyCode !== null) {
2577
+ return new TypeError('Expected "null" but received "' + typeof obj_currencyCode + '" (at "' + path_currencyCode + '")');
2578
+ }
2579
+ })();
2580
+ if (obj_currencyCode_union1_error != null) {
2581
+ obj_currencyCode_union1 = obj_currencyCode_union1_error.message;
2582
+ }
2583
+ if (obj_currencyCode_union0 && obj_currencyCode_union1) {
2584
+ let message = 'Object doesn\'t match union (at "' + path_currencyCode + '")';
2585
+ message += '\n' + obj_currencyCode_union0.split('\n').map((line) => '\t' + line).join('\n');
2586
+ message += '\n' + obj_currencyCode_union1.split('\n').map((line) => '\t' + line).join('\n');
2587
+ return new TypeError(message);
2588
+ }
2589
+ const obj_datasetColumns = obj.datasetColumns;
2590
+ const path_datasetColumns = path + '.datasetColumns';
2591
+ if (!ArrayIsArray(obj_datasetColumns)) {
2592
+ return new TypeError('Expected "array" but received "' + typeof obj_datasetColumns + '" (at "' + path_datasetColumns + '")');
2593
+ }
2594
+ for (let i = 0; i < obj_datasetColumns.length; i++) {
2595
+ const obj_datasetColumns_item = obj_datasetColumns[i];
2596
+ const path_datasetColumns_item = path_datasetColumns + '[' + i + ']';
2597
+ const referencepath_datasetColumns_itemValidationError = validate$3(obj_datasetColumns_item, path_datasetColumns_item);
2598
+ if (referencepath_datasetColumns_itemValidationError !== null) {
2599
+ let message = 'Object doesn\'t match ActionableListDatasetColumnRepresentation (at "' + path_datasetColumns_item + '")\n';
2600
+ message += referencepath_datasetColumns_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
2601
+ return new TypeError(message);
2602
+ }
2603
+ }
2604
+ const obj_datasetRows = obj.datasetRows;
2605
+ const path_datasetRows = path + '.datasetRows';
2606
+ if (!ArrayIsArray(obj_datasetRows)) {
2607
+ return new TypeError('Expected "array" but received "' + typeof obj_datasetRows + '" (at "' + path_datasetRows + '")');
2608
+ }
2609
+ for (let i = 0; i < obj_datasetRows.length; i++) {
2610
+ const obj_datasetRows_item = obj_datasetRows[i];
2611
+ const path_datasetRows_item = path_datasetRows + '[' + i + ']';
2612
+ const referencepath_datasetRows_itemValidationError = validate$2(obj_datasetRows_item, path_datasetRows_item);
2613
+ if (referencepath_datasetRows_itemValidationError !== null) {
2614
+ let message = 'Object doesn\'t match ActionableListDatasetRowRepresentation (at "' + path_datasetRows_item + '")\n';
2615
+ message += referencepath_datasetRows_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
2616
+ return new TypeError(message);
2617
+ }
2618
+ }
2619
+ const obj_memberStatuses = obj.memberStatuses;
2620
+ const path_memberStatuses = path + '.memberStatuses';
2621
+ if (!ArrayIsArray(obj_memberStatuses)) {
2622
+ return new TypeError('Expected "array" but received "' + typeof obj_memberStatuses + '" (at "' + path_memberStatuses + '")');
2623
+ }
2624
+ for (let i = 0; i < obj_memberStatuses.length; i++) {
2625
+ const obj_memberStatuses_item = obj_memberStatuses[i];
2626
+ const path_memberStatuses_item = path_memberStatuses + '[' + i + ']';
2627
+ const referencepath_memberStatuses_itemValidationError = validate$1(obj_memberStatuses_item, path_memberStatuses_item);
2628
+ if (referencepath_memberStatuses_itemValidationError !== null) {
2629
+ let message = 'Object doesn\'t match ActionableListMemberStatusRepresentation (at "' + path_memberStatuses_item + '")\n';
2630
+ message += referencepath_memberStatuses_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
2631
+ return new TypeError(message);
2632
+ }
2633
+ }
2634
+ const obj_responseId = obj.responseId;
2635
+ const path_responseId = path + '.responseId';
2636
+ if (typeof obj_responseId !== 'string') {
2637
+ return new TypeError('Expected "string" but received "' + typeof obj_responseId + '" (at "' + path_responseId + '")');
2638
+ }
2639
+ })();
2640
+ return v_error === undefined ? null : v_error;
2641
+ }
2642
+ const RepresentationType = 'ActionableListDatasetByDefinitionRepresentation';
2643
+ function normalize(input, existing, path, luvio, store, timestamp) {
2644
+ return input;
2645
+ }
2646
+ const select$1 = function ActionableListDatasetByDefinitionRepresentationSelect() {
2647
+ const { selections: ActionableListDatasetColumnRepresentation__selections, opaque: ActionableListDatasetColumnRepresentation__opaque, } = select$4();
2648
+ const { selections: ActionableListDatasetRowRepresentation__selections, opaque: ActionableListDatasetRowRepresentation__opaque, } = select$3();
2649
+ const { selections: ActionableListMemberStatusRepresentation__selections, opaque: ActionableListMemberStatusRepresentation__opaque, } = select$2();
2650
+ return {
2651
+ kind: 'Fragment',
2652
+ version: VERSION,
2653
+ private: [],
2654
+ selections: [
2655
+ {
2656
+ name: 'currencyCode',
2657
+ kind: 'Scalar'
2658
+ },
2659
+ {
2660
+ name: 'datasetColumns',
2661
+ kind: 'Object',
2662
+ plural: true,
2663
+ selections: ActionableListDatasetColumnRepresentation__selections
2664
+ },
2665
+ {
2666
+ name: 'datasetRows',
2667
+ kind: 'Object',
2668
+ plural: true,
2669
+ selections: ActionableListDatasetRowRepresentation__selections
2670
+ },
2671
+ {
2672
+ name: 'memberStatuses',
2673
+ kind: 'Object',
2674
+ plural: true,
2675
+ selections: ActionableListMemberStatusRepresentation__selections
2676
+ },
2677
+ {
2678
+ name: 'responseId',
2679
+ kind: 'Scalar'
2680
+ }
2681
+ ]
2682
+ };
2683
+ };
2684
+ function equals(existing, incoming) {
2685
+ const existing_responseId = existing.responseId;
2686
+ const incoming_responseId = incoming.responseId;
2687
+ if (!(existing_responseId === incoming_responseId)) {
2688
+ return false;
2689
+ }
2690
+ const existing_currencyCode = existing.currencyCode;
2691
+ const incoming_currencyCode = incoming.currencyCode;
2692
+ if (!(existing_currencyCode === incoming_currencyCode)) {
2693
+ return false;
2694
+ }
2695
+ const existing_datasetColumns = existing.datasetColumns;
2696
+ const incoming_datasetColumns = incoming.datasetColumns;
2697
+ const equals_datasetColumns_items = equalsArray(existing_datasetColumns, incoming_datasetColumns, (existing_datasetColumns_item, incoming_datasetColumns_item) => {
2698
+ if (!(equals$3(existing_datasetColumns_item, incoming_datasetColumns_item))) {
2699
+ return false;
2700
+ }
2701
+ });
2702
+ if (equals_datasetColumns_items === false) {
2703
+ return false;
2704
+ }
2705
+ const existing_datasetRows = existing.datasetRows;
2706
+ const incoming_datasetRows = incoming.datasetRows;
2707
+ const equals_datasetRows_items = equalsArray(existing_datasetRows, incoming_datasetRows, (existing_datasetRows_item, incoming_datasetRows_item) => {
2708
+ if (!(equals$2(existing_datasetRows_item, incoming_datasetRows_item))) {
2709
+ return false;
2710
+ }
2711
+ });
2712
+ if (equals_datasetRows_items === false) {
2713
+ return false;
2714
+ }
2715
+ const existing_memberStatuses = existing.memberStatuses;
2716
+ const incoming_memberStatuses = incoming.memberStatuses;
2717
+ const equals_memberStatuses_items = equalsArray(existing_memberStatuses, incoming_memberStatuses, (existing_memberStatuses_item, incoming_memberStatuses_item) => {
2718
+ if (!(equals$1(existing_memberStatuses_item, incoming_memberStatuses_item))) {
2719
+ return false;
2720
+ }
2721
+ });
2722
+ if (equals_memberStatuses_items === false) {
2723
+ return false;
2724
+ }
2725
+ return true;
2726
+ }
2727
+ const ingest = function ActionableListDatasetByDefinitionRepresentationIngest(input, path, luvio, store, timestamp) {
2728
+ if (process.env.NODE_ENV !== 'production') {
2729
+ const validateError = validate(input);
2730
+ if (validateError !== null) {
2731
+ throw validateError;
2732
+ }
2733
+ }
2734
+ const key = path.fullPath;
2735
+ const existingRecord = store.readEntry(key);
2736
+ const ttlToUse = TTL;
2737
+ let incomingRecord = normalize(input, store.readEntry(key), {
2738
+ fullPath: key,
2739
+ parent: path.parent,
2740
+ propertyName: path.propertyName,
2741
+ ttl: ttlToUse
2742
+ });
2743
+ if (existingRecord === undefined || equals(existingRecord, incomingRecord) === false) {
2744
+ luvio.storePublish(key, incomingRecord);
2745
+ }
2746
+ {
2747
+ const storeMetadataParams = {
2748
+ ttl: ttlToUse,
2749
+ namespace: "actionablelist",
2750
+ version: VERSION,
2751
+ representationName: RepresentationType,
2752
+ };
2753
+ luvio.publishStoreMetadata(key, storeMetadataParams);
2754
+ }
2755
+ return createLink(key);
2756
+ };
2757
+ function getTypeCacheKeys(luvio, input, fullPathFactory) {
2758
+ const rootKeySet = new engine.StoreKeyMap();
2759
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
2760
+ const rootKey = fullPathFactory();
2761
+ rootKeySet.set(rootKey, {
2762
+ namespace: keyPrefix,
2763
+ representationName: RepresentationType,
2764
+ mergeable: false
2765
+ });
2766
+ return rootKeySet;
2767
+ }
2768
+
2769
+ function select(luvio, params) {
2770
+ return select$1();
2771
+ }
2772
+ function keyBuilder$1(luvio, params) {
2773
+ return keyPrefix + '::ActionableListDatasetByDefinitionRepresentation:(' + (params.body.actionableListDataset.actionableListDefinitionId === undefined ? 'actionableListDataset.actionableListDefinitionId' : 'actionableListDataset.actionableListDefinitionId:' + params.body.actionableListDataset.actionableListDefinitionId) + '::' + (params.body.actionableListDataset.filterLogic === undefined ? 'actionableListDataset.filterLogic' : 'actionableListDataset.filterLogic:' + params.body.actionableListDataset.filterLogic) + '::' + +'::' + (params.body.actionableListDataset.offset === undefined ? 'actionableListDataset.offset' : 'actionableListDataset.offset:' + params.body.actionableListDataset.offset) + '::' + (params.body.actionableListDataset.orderBy === undefined ? 'actionableListDataset.orderBy' : 'actionableListDataset.orderBy:' + params.body.actionableListDataset.orderBy) + '::' + (params.body.actionableListDataset.rowLimit === undefined ? 'actionableListDataset.rowLimit' : 'actionableListDataset.rowLimit:' + params.body.actionableListDataset.rowLimit) + '::' + (params.body.actionableListDataset.shouldReturnCurrencyCode === undefined ? 'actionableListDataset.shouldReturnCurrencyCode' : 'actionableListDataset.shouldReturnCurrencyCode:' + params.body.actionableListDataset.shouldReturnCurrencyCode) + '::' + (params.body.actionableListDataset.sortOrder === undefined ? 'actionableListDataset.sortOrder' : 'actionableListDataset.sortOrder:' + params.body.actionableListDataset.sortOrder) + ')';
2774
+ }
2775
+ function getResponseCacheKeys(luvio, resourceParams, response) {
2776
+ return getTypeCacheKeys(luvio, response, () => keyBuilder$1(luvio, resourceParams));
2777
+ }
2778
+ function ingestSuccess(luvio, resourceParams, response, snapshotRefresh) {
2779
+ const { body } = response;
2780
+ const key = keyBuilder$1(luvio, resourceParams);
2781
+ luvio.storeIngest(key, ingest, body);
2782
+ const snapshot = luvio.storeLookup({
2783
+ recordId: key,
2784
+ node: select(),
2785
+ variables: {},
2786
+ }, snapshotRefresh);
2787
+ if (process.env.NODE_ENV !== 'production') {
2788
+ if (snapshot.state !== 'Fulfilled') {
2789
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
2790
+ }
2791
+ }
2792
+ return snapshot;
2793
+ }
2794
+ function ingestError(luvio, params, error, snapshotRefresh) {
2795
+ const key = keyBuilder$1(luvio, params);
2796
+ const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
2797
+ const storeMetadataParams = {
2798
+ ttl: TTL,
2799
+ namespace: keyPrefix,
2800
+ version: VERSION,
2801
+ representationName: RepresentationType
2802
+ };
2803
+ luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
2804
+ return errorSnapshot;
2805
+ }
2806
+ function createResourceRequest(config) {
2807
+ const headers = {};
2808
+ return {
2809
+ baseUri: '/services/data/v58.0',
2810
+ basePath: '/connect/actionable-list-definition/rows',
2811
+ method: 'post',
2812
+ body: config.body,
2813
+ urlParams: {},
2814
+ queryParams: {},
2815
+ headers,
2816
+ priority: 'normal',
2817
+ };
2818
+ }
2819
+
2820
+ const getActionableListDatasetInfo_ConfigPropertyNames = {
2821
+ displayName: 'getActionableListDatasetInfo',
2822
+ parameters: {
2823
+ required: ['actionableListDataset'],
2824
+ optional: []
2825
+ }
2826
+ };
2827
+ function createResourceParams(config) {
2828
+ const resourceParams = {
2829
+ body: {
2830
+ actionableListDataset: config.actionableListDataset
2831
+ }
2832
+ };
2833
+ return resourceParams;
2834
+ }
2835
+ function keyBuilder(luvio, config) {
2836
+ const resourceParams = createResourceParams(config);
2837
+ return keyBuilder$1(luvio, resourceParams);
2838
+ }
2839
+ function typeCheckConfig(untrustedConfig) {
2840
+ const config = {};
2841
+ const untrustedConfig_actionableListDataset = untrustedConfig.actionableListDataset;
2842
+ const referenceActionableListDatasetInputRepresentationValidationError = validate$4(untrustedConfig_actionableListDataset);
2843
+ if (referenceActionableListDatasetInputRepresentationValidationError === null) {
2844
+ config.actionableListDataset = untrustedConfig_actionableListDataset;
2845
+ }
2846
+ return config;
2847
+ }
2848
+ function validateAdapterConfig(untrustedConfig, configPropertyNames) {
2849
+ if (!untrustedIsObject(untrustedConfig)) {
2850
+ return null;
2851
+ }
2852
+ if (process.env.NODE_ENV !== 'production') {
2853
+ validateConfig(untrustedConfig, configPropertyNames);
2854
+ }
2855
+ const config = typeCheckConfig(untrustedConfig);
2856
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
2857
+ return null;
2858
+ }
2859
+ return config;
2860
+ }
2861
+ function adapterFragment(luvio, config) {
2862
+ createResourceParams(config);
2863
+ return select();
2864
+ }
2865
+ function onFetchResponseSuccess(luvio, config, resourceParams, response) {
2866
+ const snapshot = ingestSuccess(luvio, resourceParams, response, {
2867
+ config,
2868
+ resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
2869
+ });
2870
+ return luvio.storeBroadcast().then(() => snapshot);
2871
+ }
2872
+ function onFetchResponseError(luvio, config, resourceParams, response) {
2873
+ const snapshot = ingestError(luvio, resourceParams, response, {
2874
+ config,
2875
+ resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
2876
+ });
2877
+ return luvio.storeBroadcast().then(() => snapshot);
2878
+ }
2879
+ function buildNetworkSnapshot(luvio, config, options) {
2880
+ const resourceParams = createResourceParams(config);
2881
+ const request = createResourceRequest(resourceParams);
2882
+ return luvio.dispatchResourceRequest(request, options)
2883
+ .then((response) => {
2884
+ return luvio.handleSuccessResponse(() => onFetchResponseSuccess(luvio, config, resourceParams, response), () => getResponseCacheKeys(luvio, resourceParams, response.body));
2885
+ }, (response) => {
2886
+ return luvio.handleErrorResponse(() => onFetchResponseError(luvio, config, resourceParams, response));
2887
+ });
2888
+ }
2889
+ function buildNetworkSnapshotCachePolicy(context, coercedAdapterRequestContext) {
2890
+ const { luvio, config } = context;
2891
+ const { networkPriority, requestCorrelator, eventObservers } = coercedAdapterRequestContext;
2892
+ const dispatchOptions = {
2893
+ resourceRequestContext: {
2894
+ requestCorrelator,
2895
+ luvioRequestMethod: 'get',
2896
+ },
2897
+ eventObservers
2898
+ };
2899
+ if (networkPriority !== 'normal') {
2900
+ dispatchOptions.overrides = {
2901
+ priority: networkPriority
2902
+ };
2903
+ }
2904
+ return buildNetworkSnapshot(luvio, config, dispatchOptions);
2905
+ }
2906
+ function buildCachedSnapshotCachePolicy(context, storeLookup) {
2907
+ const { luvio, config } = context;
2908
+ const selector = {
2909
+ recordId: keyBuilder(luvio, config),
2910
+ node: adapterFragment(luvio, config),
2911
+ variables: {},
2912
+ };
2913
+ const cacheSnapshot = storeLookup(selector, {
2914
+ config,
2915
+ resolve: () => buildNetworkSnapshot(luvio, config, snapshotRefreshOptions)
2916
+ });
2917
+ return cacheSnapshot;
2918
+ }
2919
+ const getActionableListDatasetInfoAdapterFactory = (luvio) => function actionablelist__getActionableListDatasetInfo(untrustedConfig, requestContext) {
2920
+ const config = validateAdapterConfig(untrustedConfig, getActionableListDatasetInfo_ConfigPropertyNames);
2921
+ // Invalid or incomplete config
2922
+ if (config === null) {
2923
+ return null;
2924
+ }
2925
+ return luvio.applyCachePolicy((requestContext || {}), { config, luvio }, // BuildSnapshotContext
2926
+ buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
2927
+ };
2928
+
2929
+ exports.createActionableListDefinitionAdapterFactory = createActionableListDefinitionAdapterFactory;
2930
+ exports.getActionableListDatasetInfoAdapterFactory = getActionableListDatasetInfoAdapterFactory;
2931
+ exports.getActionableListDefinitionsAdapterFactory = getActionableListDefinitionsAdapterFactory;
2932
+ exports.getActionableListMembersAdapterFactory = getActionableListMembersAdapterFactory;
2933
+ exports.upsertActionableListAdapterFactory = upsertActionableListAdapterFactory;
2934
+
2935
+ Object.defineProperty(exports, '__esModule', { value: true });
2936
+
2937
+ }));