@salesforce/lds-adapters-sales-eci 1.297.0 → 1.299.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,7 +4,7 @@
4
4
  * For full license text, see the LICENSE.txt file
5
5
  */
6
6
 
7
- import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$3, typeCheckConfig as typeCheckConfig$4, StoreKeyMap, createResourceParams as createResourceParams$4 } from '@luvio/engine';
7
+ import { serializeStructuredKey, ingestShape, deepFreeze, buildNetworkSnapshotCachePolicy as buildNetworkSnapshotCachePolicy$3, typeCheckConfig as typeCheckConfig$5, StoreKeyMap, createResourceParams as createResourceParams$5 } from '@luvio/engine';
8
8
 
9
9
  const { hasOwnProperty: ObjectPrototypeHasOwnProperty } = Object.prototype;
10
10
  const { keys: ObjectKeys$1, create: ObjectCreate$1 } = Object;
@@ -111,8 +111,8 @@ function createLink(ref) {
111
111
  };
112
112
  }
113
113
 
114
- const VERSION$4 = "c614c7bd04cb26f6e931c85a63d52c55";
115
- function validate$4(obj, path = 'ConversationGenerativeInsightRepresentation') {
114
+ const VERSION$5 = "c614c7bd04cb26f6e931c85a63d52c55";
115
+ function validate$5(obj, path = 'ConversationGenerativeInsightRepresentation') {
116
116
  const v_error = (() => {
117
117
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
118
118
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -140,10 +140,10 @@ function validate$4(obj, path = 'ConversationGenerativeInsightRepresentation') {
140
140
  })();
141
141
  return v_error === undefined ? null : v_error;
142
142
  }
143
- const select$8 = function ConversationGenerativeInsightRepresentationSelect() {
143
+ const select$a = function ConversationGenerativeInsightRepresentationSelect() {
144
144
  return {
145
145
  kind: 'Fragment',
146
- version: VERSION$4,
146
+ version: VERSION$5,
147
147
  private: [],
148
148
  selections: [
149
149
  {
@@ -165,7 +165,7 @@ const select$8 = function ConversationGenerativeInsightRepresentationSelect() {
165
165
  ]
166
166
  };
167
167
  };
168
- function equals$4(existing, incoming) {
168
+ function equals$5(existing, incoming) {
169
169
  const existing_generatedText = existing.generatedText;
170
170
  const incoming_generatedText = incoming.generatedText;
171
171
  if (!(existing_generatedText === incoming_generatedText)) {
@@ -189,9 +189,9 @@ function equals$4(existing, incoming) {
189
189
  return true;
190
190
  }
191
191
 
192
- const TTL$3 = 60000;
193
- const VERSION$3 = "1ddcdcaada7f739acdff16f101b69288";
194
- function validate$3(obj, path = 'ConversationGenInsightListRepresentation') {
192
+ const TTL$4 = 60000;
193
+ const VERSION$4 = "1ddcdcaada7f739acdff16f101b69288";
194
+ function validate$4(obj, path = 'ConversationGenInsightListRepresentation') {
195
195
  const v_error = (() => {
196
196
  if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
197
197
  return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
@@ -218,7 +218,7 @@ function validate$3(obj, path = 'ConversationGenInsightListRepresentation') {
218
218
  for (let i = 0; i < obj_generativeInsights.length; i++) {
219
219
  const obj_generativeInsights_item = obj_generativeInsights[i];
220
220
  const path_generativeInsights_item = path_generativeInsights + '[' + i + ']';
221
- const referencepath_generativeInsights_itemValidationError = validate$4(obj_generativeInsights_item, path_generativeInsights_item);
221
+ const referencepath_generativeInsights_itemValidationError = validate$5(obj_generativeInsights_item, path_generativeInsights_item);
222
222
  if (referencepath_generativeInsights_itemValidationError !== null) {
223
223
  let message = 'Object doesn\'t match ConversationGenerativeInsightRepresentation (at "' + path_generativeInsights_item + '")\n';
224
224
  message += referencepath_generativeInsights_itemValidationError.message.split('\n').map((line) => '\t' + line).join('\n');
@@ -233,24 +233,24 @@ function validate$3(obj, path = 'ConversationGenInsightListRepresentation') {
233
233
  })();
234
234
  return v_error === undefined ? null : v_error;
235
235
  }
236
- const RepresentationType$3 = 'ConversationGenInsightListRepresentation';
237
- function keyBuilder$8(luvio, config) {
238
- return keyPrefix + '::' + RepresentationType$3 + ':' + config.id;
236
+ const RepresentationType$4 = 'ConversationGenInsightListRepresentation';
237
+ function keyBuilder$9(luvio, config) {
238
+ return keyPrefix + '::' + RepresentationType$4 + ':' + config.id;
239
239
  }
240
- function keyBuilderFromType$2(luvio, object) {
240
+ function keyBuilderFromType$3(luvio, object) {
241
241
  const keyParams = {
242
242
  id: object.recordId
243
243
  };
244
- return keyBuilder$8(luvio, keyParams);
244
+ return keyBuilder$9(luvio, keyParams);
245
245
  }
246
- function normalize$3(input, existing, path, luvio, store, timestamp) {
246
+ function normalize$4(input, existing, path, luvio, store, timestamp) {
247
247
  return input;
248
248
  }
249
- const select$7 = function ConversationGenInsightListRepresentationSelect() {
250
- const { selections: ConversationGenerativeInsightRepresentation__selections, opaque: ConversationGenerativeInsightRepresentation__opaque, } = select$8();
249
+ const select$9 = function ConversationGenInsightListRepresentationSelect() {
250
+ const { selections: ConversationGenerativeInsightRepresentation__selections, opaque: ConversationGenerativeInsightRepresentation__opaque, } = select$a();
251
251
  return {
252
252
  kind: 'Fragment',
253
- version: VERSION$3,
253
+ version: VERSION$4,
254
254
  private: [],
255
255
  selections: [
256
256
  {
@@ -271,7 +271,7 @@ const select$7 = function ConversationGenInsightListRepresentationSelect() {
271
271
  ]
272
272
  };
273
273
  };
274
- function equals$3(existing, incoming) {
274
+ function equals$4(existing, incoming) {
275
275
  const existing_recordId = existing.recordId;
276
276
  const incoming_recordId = incoming.recordId;
277
277
  if (!(existing_recordId === incoming_recordId)) {
@@ -290,7 +290,7 @@ function equals$3(existing, incoming) {
290
290
  const existing_generativeInsights = existing.generativeInsights;
291
291
  const incoming_generativeInsights = incoming.generativeInsights;
292
292
  const equals_generativeInsights_items = equalsArray(existing_generativeInsights, incoming_generativeInsights, (existing_generativeInsights_item, incoming_generativeInsights_item) => {
293
- if (!(equals$4(existing_generativeInsights_item, incoming_generativeInsights_item))) {
293
+ if (!(equals$5(existing_generativeInsights_item, incoming_generativeInsights_item))) {
294
294
  return false;
295
295
  }
296
296
  });
@@ -299,46 +299,46 @@ function equals$3(existing, incoming) {
299
299
  }
300
300
  return true;
301
301
  }
302
- const ingest$3 = function ConversationGenInsightListRepresentationIngest(input, path, luvio, store, timestamp) {
302
+ const ingest$4 = function ConversationGenInsightListRepresentationIngest(input, path, luvio, store, timestamp) {
303
303
  if (process.env.NODE_ENV !== 'production') {
304
- const validateError = validate$3(input);
304
+ const validateError = validate$4(input);
305
305
  if (validateError !== null) {
306
306
  throw validateError;
307
307
  }
308
308
  }
309
- const key = keyBuilderFromType$2(luvio, input);
310
- const ttlToUse = TTL$3;
311
- ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$3, "eci", VERSION$3, RepresentationType$3, equals$3);
309
+ const key = keyBuilderFromType$3(luvio, input);
310
+ const ttlToUse = TTL$4;
311
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$4, "eci", VERSION$4, RepresentationType$4, equals$4);
312
312
  return createLink(key);
313
313
  };
314
- function getTypeCacheKeys$3(rootKeySet, luvio, input, fullPathFactory) {
314
+ function getTypeCacheKeys$4(rootKeySet, luvio, input, fullPathFactory) {
315
315
  // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
316
- const rootKey = keyBuilderFromType$2(luvio, input);
316
+ const rootKey = keyBuilderFromType$3(luvio, input);
317
317
  rootKeySet.set(rootKey, {
318
318
  namespace: keyPrefix,
319
- representationName: RepresentationType$3,
319
+ representationName: RepresentationType$4,
320
320
  mergeable: false
321
321
  });
322
322
  }
323
323
 
324
- function select$6(luvio, params) {
325
- return select$7();
324
+ function select$8(luvio, params) {
325
+ return select$9();
326
326
  }
327
- function keyBuilder$7(luvio, params) {
328
- return keyBuilder$8(luvio, {
327
+ function keyBuilder$8(luvio, params) {
328
+ return keyBuilder$9(luvio, {
329
329
  id: params.urlParams.id
330
330
  });
331
331
  }
332
- function getResponseCacheKeys$3(storeKeyMap, luvio, resourceParams, response) {
333
- getTypeCacheKeys$3(storeKeyMap, luvio, response);
332
+ function getResponseCacheKeys$4(storeKeyMap, luvio, resourceParams, response) {
333
+ getTypeCacheKeys$4(storeKeyMap, luvio, response);
334
334
  }
335
- function ingestSuccess$3(luvio, resourceParams, response, snapshotRefresh) {
335
+ function ingestSuccess$4(luvio, resourceParams, response, snapshotRefresh) {
336
336
  const { body } = response;
337
- const key = keyBuilder$7(luvio, resourceParams);
338
- luvio.storeIngest(key, ingest$3, body);
337
+ const key = keyBuilder$8(luvio, resourceParams);
338
+ luvio.storeIngest(key, ingest$4, body);
339
339
  const snapshot = luvio.storeLookup({
340
340
  recordId: key,
341
- node: select$6(),
341
+ node: select$8(),
342
342
  variables: {},
343
343
  }, snapshotRefresh);
344
344
  if (process.env.NODE_ENV !== 'production') {
@@ -350,18 +350,18 @@ function ingestSuccess$3(luvio, resourceParams, response, snapshotRefresh) {
350
350
  return snapshot;
351
351
  }
352
352
  function ingestError$2(luvio, params, error, snapshotRefresh) {
353
- const key = keyBuilder$7(luvio, params);
353
+ const key = keyBuilder$8(luvio, params);
354
354
  const errorSnapshot = luvio.errorSnapshot(error, snapshotRefresh);
355
355
  const storeMetadataParams = {
356
- ttl: TTL$3,
356
+ ttl: TTL$4,
357
357
  namespace: keyPrefix,
358
- version: VERSION$3,
359
- representationName: RepresentationType$3
358
+ version: VERSION$4,
359
+ representationName: RepresentationType$4
360
360
  };
361
361
  luvio.storeIngestError(key, errorSnapshot, storeMetadataParams);
362
362
  return errorSnapshot;
363
363
  }
364
- function createResourceRequest$3(config) {
364
+ function createResourceRequest$4(config) {
365
365
  const headers = {};
366
366
  return {
367
367
  baseUri: '/services/data/v62.0',
@@ -375,60 +375,60 @@ function createResourceRequest$3(config) {
375
375
  };
376
376
  }
377
377
 
378
- const adapterName$3 = 'getConversationGenerativeInsight';
378
+ const adapterName$4 = 'getConversationGenerativeInsight';
379
379
  const getConversationGenerativeInsight_ConfigPropertyMetadata = [
380
380
  generateParamConfigMetadata('id', true, 0 /* UrlParameter */, 0 /* String */),
381
381
  ];
382
- const getConversationGenerativeInsight_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$3, getConversationGenerativeInsight_ConfigPropertyMetadata);
383
- const createResourceParams$3 = /*#__PURE__*/ createResourceParams$4(getConversationGenerativeInsight_ConfigPropertyMetadata);
384
- function keyBuilder$6(luvio, config) {
385
- const resourceParams = createResourceParams$3(config);
386
- return keyBuilder$7(luvio, resourceParams);
382
+ const getConversationGenerativeInsight_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$4, getConversationGenerativeInsight_ConfigPropertyMetadata);
383
+ const createResourceParams$4 = /*#__PURE__*/ createResourceParams$5(getConversationGenerativeInsight_ConfigPropertyMetadata);
384
+ function keyBuilder$7(luvio, config) {
385
+ const resourceParams = createResourceParams$4(config);
386
+ return keyBuilder$8(luvio, resourceParams);
387
387
  }
388
- function typeCheckConfig$3(untrustedConfig) {
388
+ function typeCheckConfig$4(untrustedConfig) {
389
389
  const config = {};
390
- typeCheckConfig$4(untrustedConfig, config, getConversationGenerativeInsight_ConfigPropertyMetadata);
390
+ typeCheckConfig$5(untrustedConfig, config, getConversationGenerativeInsight_ConfigPropertyMetadata);
391
391
  return config;
392
392
  }
393
- function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
393
+ function validateAdapterConfig$4(untrustedConfig, configPropertyNames) {
394
394
  if (!untrustedIsObject(untrustedConfig)) {
395
395
  return null;
396
396
  }
397
397
  if (process.env.NODE_ENV !== 'production') {
398
398
  validateConfig(untrustedConfig, configPropertyNames);
399
399
  }
400
- const config = typeCheckConfig$3(untrustedConfig);
400
+ const config = typeCheckConfig$4(untrustedConfig);
401
401
  if (!areRequiredParametersPresent(config, configPropertyNames)) {
402
402
  return null;
403
403
  }
404
404
  return config;
405
405
  }
406
406
  function adapterFragment$2(luvio, config) {
407
- createResourceParams$3(config);
408
- return select$6();
407
+ createResourceParams$4(config);
408
+ return select$8();
409
409
  }
410
410
  function onFetchResponseSuccess$2(luvio, config, resourceParams, response) {
411
- const snapshot = ingestSuccess$3(luvio, resourceParams, response, {
411
+ const snapshot = ingestSuccess$4(luvio, resourceParams, response, {
412
412
  config,
413
- resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
413
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
414
414
  });
415
415
  return luvio.storeBroadcast().then(() => snapshot);
416
416
  }
417
417
  function onFetchResponseError$2(luvio, config, resourceParams, response) {
418
418
  const snapshot = ingestError$2(luvio, resourceParams, response, {
419
419
  config,
420
- resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
420
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
421
421
  });
422
422
  return luvio.storeBroadcast().then(() => snapshot);
423
423
  }
424
- function buildNetworkSnapshot$3(luvio, config, options) {
425
- const resourceParams = createResourceParams$3(config);
426
- const request = createResourceRequest$3(resourceParams);
424
+ function buildNetworkSnapshot$4(luvio, config, options) {
425
+ const resourceParams = createResourceParams$4(config);
426
+ const request = createResourceRequest$4(resourceParams);
427
427
  return luvio.dispatchResourceRequest(request, options)
428
428
  .then((response) => {
429
429
  return luvio.handleSuccessResponse(() => onFetchResponseSuccess$2(luvio, config, resourceParams, response), () => {
430
430
  const cache = new StoreKeyMap();
431
- getResponseCacheKeys$3(cache, luvio, resourceParams, response.body);
431
+ getResponseCacheKeys$4(cache, luvio, resourceParams, response.body);
432
432
  return cache;
433
433
  });
434
434
  }, (response) => {
@@ -436,23 +436,23 @@ function buildNetworkSnapshot$3(luvio, config, options) {
436
436
  });
437
437
  }
438
438
  function buildNetworkSnapshotCachePolicy$2(context, coercedAdapterRequestContext) {
439
- return buildNetworkSnapshotCachePolicy$3(context, coercedAdapterRequestContext, buildNetworkSnapshot$3, undefined, false);
439
+ return buildNetworkSnapshotCachePolicy$3(context, coercedAdapterRequestContext, buildNetworkSnapshot$4, undefined, false);
440
440
  }
441
441
  function buildCachedSnapshotCachePolicy$2(context, storeLookup) {
442
442
  const { luvio, config } = context;
443
443
  const selector = {
444
- recordId: keyBuilder$6(luvio, config),
444
+ recordId: keyBuilder$7(luvio, config),
445
445
  node: adapterFragment$2(luvio, config),
446
446
  variables: {},
447
447
  };
448
448
  const cacheSnapshot = storeLookup(selector, {
449
449
  config,
450
- resolve: () => buildNetworkSnapshot$3(luvio, config, snapshotRefreshOptions)
450
+ resolve: () => buildNetworkSnapshot$4(luvio, config, snapshotRefreshOptions)
451
451
  });
452
452
  return cacheSnapshot;
453
453
  }
454
454
  const getConversationGenerativeInsightAdapterFactory = (luvio) => function eci__getConversationGenerativeInsight(untrustedConfig, requestContext) {
455
- const config = validateAdapterConfig$3(untrustedConfig, getConversationGenerativeInsight_ConfigPropertyNames);
455
+ const config = validateAdapterConfig$4(untrustedConfig, getConversationGenerativeInsight_ConfigPropertyNames);
456
456
  // Invalid or incomplete config
457
457
  if (config === null) {
458
458
  return null;
@@ -461,6 +461,224 @@ const getConversationGenerativeInsightAdapterFactory = (luvio) => function eci__
461
461
  buildCachedSnapshotCachePolicy$2, buildNetworkSnapshotCachePolicy$2);
462
462
  };
463
463
 
464
+ const TTL$3 = 60000;
465
+ const VERSION$3 = "92b95a3b99090d0e464e4259ecac6bb4";
466
+ function validate$3(obj, path = 'ConversationRealtimeMeetingInitiationResponseRepresentation') {
467
+ const v_error = (() => {
468
+ if (typeof obj !== 'object' || ArrayIsArray(obj) || obj === null) {
469
+ return new TypeError('Expected "object" but received "' + typeof obj + '" (at "' + path + '")');
470
+ }
471
+ const obj_botId = obj.botId;
472
+ const path_botId = path + '.botId';
473
+ if (typeof obj_botId !== 'string') {
474
+ return new TypeError('Expected "string" but received "' + typeof obj_botId + '" (at "' + path_botId + '")');
475
+ }
476
+ const obj_error = obj.error;
477
+ const path_error = path + '.error';
478
+ if (typeof obj_error !== 'object' || ArrayIsArray(obj_error) || obj_error === null) {
479
+ return new TypeError('Expected "object" but received "' + typeof obj_error + '" (at "' + path_error + '")');
480
+ }
481
+ const obj_error_keys = ObjectKeys(obj_error);
482
+ for (let i = 0; i < obj_error_keys.length; i++) {
483
+ const key = obj_error_keys[i];
484
+ const obj_error_prop = obj_error[key];
485
+ const path_error_prop = path_error + '["' + key + '"]';
486
+ if (typeof obj_error_prop !== 'string') {
487
+ return new TypeError('Expected "string" but received "' + typeof obj_error_prop + '" (at "' + path_error_prop + '")');
488
+ }
489
+ }
490
+ const obj_jwtToken = obj.jwtToken;
491
+ const path_jwtToken = path + '.jwtToken';
492
+ if (typeof obj_jwtToken !== 'string') {
493
+ return new TypeError('Expected "string" but received "' + typeof obj_jwtToken + '" (at "' + path_jwtToken + '")');
494
+ }
495
+ const obj_webSocketUrl = obj.webSocketUrl;
496
+ const path_webSocketUrl = path + '.webSocketUrl';
497
+ if (typeof obj_webSocketUrl !== 'string') {
498
+ return new TypeError('Expected "string" but received "' + typeof obj_webSocketUrl + '" (at "' + path_webSocketUrl + '")');
499
+ }
500
+ })();
501
+ return v_error === undefined ? null : v_error;
502
+ }
503
+ const RepresentationType$3 = 'ConversationRealtimeMeetingInitiationResponseRepresentation';
504
+ function keyBuilder$6(luvio, config) {
505
+ return keyPrefix + '::' + RepresentationType$3 + ':' + config.id;
506
+ }
507
+ function keyBuilderFromType$2(luvio, object) {
508
+ const keyParams = {
509
+ id: object.botId
510
+ };
511
+ return keyBuilder$6(luvio, keyParams);
512
+ }
513
+ function normalize$3(input, existing, path, luvio, store, timestamp) {
514
+ return input;
515
+ }
516
+ const select$7 = function ConversationRealtimeMeetingInitiationResponseRepresentationSelect() {
517
+ return {
518
+ kind: 'Fragment',
519
+ version: VERSION$3,
520
+ private: [],
521
+ selections: [
522
+ {
523
+ name: 'botId',
524
+ kind: 'Scalar'
525
+ },
526
+ {
527
+ name: 'error',
528
+ kind: 'Scalar',
529
+ map: true
530
+ },
531
+ {
532
+ name: 'jwtToken',
533
+ kind: 'Scalar'
534
+ },
535
+ {
536
+ name: 'webSocketUrl',
537
+ kind: 'Scalar'
538
+ }
539
+ ]
540
+ };
541
+ };
542
+ function equals$3(existing, incoming) {
543
+ const existing_botId = existing.botId;
544
+ const incoming_botId = incoming.botId;
545
+ if (!(existing_botId === incoming_botId)) {
546
+ return false;
547
+ }
548
+ const existing_jwtToken = existing.jwtToken;
549
+ const incoming_jwtToken = incoming.jwtToken;
550
+ if (!(existing_jwtToken === incoming_jwtToken)) {
551
+ return false;
552
+ }
553
+ const existing_webSocketUrl = existing.webSocketUrl;
554
+ const incoming_webSocketUrl = incoming.webSocketUrl;
555
+ if (!(existing_webSocketUrl === incoming_webSocketUrl)) {
556
+ return false;
557
+ }
558
+ const existing_error = existing.error;
559
+ const incoming_error = incoming.error;
560
+ const equals_error_props = equalsObject(existing_error, incoming_error, (existing_error_prop, incoming_error_prop) => {
561
+ if (!(existing_error_prop === incoming_error_prop)) {
562
+ return false;
563
+ }
564
+ });
565
+ if (equals_error_props === false) {
566
+ return false;
567
+ }
568
+ return true;
569
+ }
570
+ const ingest$3 = function ConversationRealtimeMeetingInitiationResponseRepresentationIngest(input, path, luvio, store, timestamp) {
571
+ if (process.env.NODE_ENV !== 'production') {
572
+ const validateError = validate$3(input);
573
+ if (validateError !== null) {
574
+ throw validateError;
575
+ }
576
+ }
577
+ const key = keyBuilderFromType$2(luvio, input);
578
+ const ttlToUse = TTL$3;
579
+ ingestShape(input, path, luvio, store, timestamp, ttlToUse, key, normalize$3, "eci", VERSION$3, RepresentationType$3, equals$3);
580
+ return createLink(key);
581
+ };
582
+ function getTypeCacheKeys$3(rootKeySet, luvio, input, fullPathFactory) {
583
+ // root cache key (uses fullPathFactory if keyBuilderFromType isn't defined)
584
+ const rootKey = keyBuilderFromType$2(luvio, input);
585
+ rootKeySet.set(rootKey, {
586
+ namespace: keyPrefix,
587
+ representationName: RepresentationType$3,
588
+ mergeable: false
589
+ });
590
+ }
591
+
592
+ function select$6(luvio, params) {
593
+ return select$7();
594
+ }
595
+ function getResponseCacheKeys$3(storeKeyMap, luvio, resourceParams, response) {
596
+ getTypeCacheKeys$3(storeKeyMap, luvio, response);
597
+ }
598
+ function ingestSuccess$3(luvio, resourceParams, response) {
599
+ const { body } = response;
600
+ const key = keyBuilderFromType$2(luvio, body);
601
+ luvio.storeIngest(key, ingest$3, body);
602
+ const snapshot = luvio.storeLookup({
603
+ recordId: key,
604
+ node: select$6(),
605
+ variables: {},
606
+ });
607
+ if (process.env.NODE_ENV !== 'production') {
608
+ if (snapshot.state !== 'Fulfilled') {
609
+ throw new Error('Invalid network response. Expected resource response to result in Fulfilled snapshot');
610
+ }
611
+ }
612
+ deepFreeze(snapshot.data);
613
+ return snapshot;
614
+ }
615
+ function createResourceRequest$3(config) {
616
+ const headers = {};
617
+ return {
618
+ baseUri: '/services/data/v62.0',
619
+ basePath: '/conversation/realtime/insight/meeting/initiate',
620
+ method: 'post',
621
+ body: config.body,
622
+ urlParams: {},
623
+ queryParams: {},
624
+ headers,
625
+ priority: 'normal',
626
+ };
627
+ }
628
+
629
+ const adapterName$3 = 'initiateMeeting';
630
+ const initiateMeeting_ConfigPropertyMetadata = [
631
+ generateParamConfigMetadata('meetingUrl', true, 2 /* Body */, 0 /* String */),
632
+ ];
633
+ const initiateMeeting_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$3, initiateMeeting_ConfigPropertyMetadata);
634
+ const createResourceParams$3 = /*#__PURE__*/ createResourceParams$5(initiateMeeting_ConfigPropertyMetadata);
635
+ function typeCheckConfig$3(untrustedConfig) {
636
+ const config = {};
637
+ typeCheckConfig$5(untrustedConfig, config, initiateMeeting_ConfigPropertyMetadata);
638
+ return config;
639
+ }
640
+ function validateAdapterConfig$3(untrustedConfig, configPropertyNames) {
641
+ if (!untrustedIsObject(untrustedConfig)) {
642
+ return null;
643
+ }
644
+ if (process.env.NODE_ENV !== 'production') {
645
+ validateConfig(untrustedConfig, configPropertyNames);
646
+ }
647
+ const config = typeCheckConfig$3(untrustedConfig);
648
+ if (!areRequiredParametersPresent(config, configPropertyNames)) {
649
+ return null;
650
+ }
651
+ return config;
652
+ }
653
+ function buildNetworkSnapshot$3(luvio, config, options) {
654
+ const resourceParams = createResourceParams$3(config);
655
+ const request = createResourceRequest$3(resourceParams);
656
+ return luvio.dispatchResourceRequest(request, options)
657
+ .then((response) => {
658
+ return luvio.handleSuccessResponse(() => {
659
+ const snapshot = ingestSuccess$3(luvio, resourceParams, response);
660
+ return luvio.storeBroadcast().then(() => snapshot);
661
+ }, () => {
662
+ const cache = new StoreKeyMap();
663
+ getResponseCacheKeys$3(cache, luvio, resourceParams, response.body);
664
+ return cache;
665
+ });
666
+ }, (response) => {
667
+ deepFreeze(response);
668
+ throw response;
669
+ });
670
+ }
671
+ const initiateMeetingAdapterFactory = (luvio) => {
672
+ return function initiateMeeting(untrustedConfig) {
673
+ const config = validateAdapterConfig$3(untrustedConfig, initiateMeeting_ConfigPropertyNames);
674
+ // Invalid or incomplete config
675
+ if (config === null) {
676
+ throw new Error('Invalid config for "initiateMeeting"');
677
+ }
678
+ return buildNetworkSnapshot$3(luvio, config);
679
+ };
680
+ };
681
+
464
682
  const TTL$2 = 60000;
465
683
  const VERSION$2 = "10bf968dbd562928dfa701c7f6a854b2";
466
684
  function validate$2(obj, path = 'ConversationSummaryRepresentation') {
@@ -707,10 +925,10 @@ const generateConversationSummary_ConfigPropertyMetadata = [
707
925
  generateParamConfigMetadata('conversationId', true, 0 /* UrlParameter */, 0 /* String */),
708
926
  ];
709
927
  const generateConversationSummary_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$2, generateConversationSummary_ConfigPropertyMetadata);
710
- const createResourceParams$2 = /*#__PURE__*/ createResourceParams$4(generateConversationSummary_ConfigPropertyMetadata);
928
+ const createResourceParams$2 = /*#__PURE__*/ createResourceParams$5(generateConversationSummary_ConfigPropertyMetadata);
711
929
  function typeCheckConfig$2(untrustedConfig) {
712
930
  const config = {};
713
- typeCheckConfig$4(untrustedConfig, config, generateConversationSummary_ConfigPropertyMetadata);
931
+ typeCheckConfig$5(untrustedConfig, config, generateConversationSummary_ConfigPropertyMetadata);
714
932
  return config;
715
933
  }
716
934
  function validateAdapterConfig$2(untrustedConfig, configPropertyNames) {
@@ -960,14 +1178,14 @@ const getConversationSummaryRelatedList_ConfigPropertyMetadata = [
960
1178
  generateParamConfigMetadata('id', true, 0 /* UrlParameter */, 0 /* String */),
961
1179
  ];
962
1180
  const getConversationSummaryRelatedList_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName$1, getConversationSummaryRelatedList_ConfigPropertyMetadata);
963
- const createResourceParams$1 = /*#__PURE__*/ createResourceParams$4(getConversationSummaryRelatedList_ConfigPropertyMetadata);
1181
+ const createResourceParams$1 = /*#__PURE__*/ createResourceParams$5(getConversationSummaryRelatedList_ConfigPropertyMetadata);
964
1182
  function keyBuilder$2(luvio, config) {
965
1183
  const resourceParams = createResourceParams$1(config);
966
1184
  return keyBuilder$3(luvio, resourceParams);
967
1185
  }
968
1186
  function typeCheckConfig$1(untrustedConfig) {
969
1187
  const config = {};
970
- typeCheckConfig$4(untrustedConfig, config, getConversationSummaryRelatedList_ConfigPropertyMetadata);
1188
+ typeCheckConfig$5(untrustedConfig, config, getConversationSummaryRelatedList_ConfigPropertyMetadata);
971
1189
  return config;
972
1190
  }
973
1191
  function validateAdapterConfig$1(untrustedConfig, configPropertyNames) {
@@ -1211,14 +1429,14 @@ const getTranscript_ConfigPropertyMetadata = [
1211
1429
  generateParamConfigMetadata('includeData', false, 1 /* QueryParameter */, 1 /* Boolean */),
1212
1430
  ];
1213
1431
  const getTranscript_ConfigPropertyNames = /*#__PURE__*/ buildAdapterValidationConfig(adapterName, getTranscript_ConfigPropertyMetadata);
1214
- const createResourceParams = /*#__PURE__*/ createResourceParams$4(getTranscript_ConfigPropertyMetadata);
1432
+ const createResourceParams = /*#__PURE__*/ createResourceParams$5(getTranscript_ConfigPropertyMetadata);
1215
1433
  function keyBuilder(luvio, config) {
1216
1434
  const resourceParams = createResourceParams(config);
1217
1435
  return keyBuilder$1(luvio, resourceParams);
1218
1436
  }
1219
1437
  function typeCheckConfig(untrustedConfig) {
1220
1438
  const config = {};
1221
- typeCheckConfig$4(untrustedConfig, config, getTranscript_ConfigPropertyMetadata);
1439
+ typeCheckConfig$5(untrustedConfig, config, getTranscript_ConfigPropertyMetadata);
1222
1440
  return config;
1223
1441
  }
1224
1442
  function validateAdapterConfig(untrustedConfig, configPropertyNames) {
@@ -1292,4 +1510,4 @@ const getTranscriptAdapterFactory = (luvio) => function eci__getTranscript(untru
1292
1510
  buildCachedSnapshotCachePolicy, buildNetworkSnapshotCachePolicy);
1293
1511
  };
1294
1512
 
1295
- export { generateConversationSummaryAdapterFactory, getConversationGenerativeInsightAdapterFactory, getConversationSummaryRelatedListAdapterFactory, getTranscriptAdapterFactory };
1513
+ export { generateConversationSummaryAdapterFactory, getConversationGenerativeInsightAdapterFactory, getConversationSummaryRelatedListAdapterFactory, getTranscriptAdapterFactory, initiateMeetingAdapterFactory };
@@ -0,0 +1,15 @@
1
+ import { AdapterConfigMetadata as $64$luvio_engine_AdapterConfigMetadata, Luvio as $64$luvio_engine_Luvio, DispatchResourceRequestContext as $64$luvio_engine_DispatchResourceRequestContext, AdapterFactory as $64$luvio_engine_AdapterFactory } from '@luvio/engine';
2
+ import { Untrusted as adapter$45$utils_Untrusted, AdapterValidationConfig as adapter$45$utils_AdapterValidationConfig } from './adapter-utils';
3
+ import { ResourceRequestConfig as resources_postConversationRealtimeInsightMeetingInitiate_ResourceRequestConfig } from '../resources/postConversationRealtimeInsightMeetingInitiate';
4
+ import { ConversationRealtimeMeetingInitiationResponseRepresentation as types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation } from '../types/ConversationRealtimeMeetingInitiationResponseRepresentation';
5
+ export declare const adapterName = "initiateMeeting";
6
+ export declare const initiateMeeting_ConfigPropertyMetadata: $64$luvio_engine_AdapterConfigMetadata[];
7
+ export declare const initiateMeeting_ConfigPropertyNames: adapter$45$utils_AdapterValidationConfig;
8
+ export interface InitiateMeetingConfig {
9
+ meetingUrl: string;
10
+ }
11
+ export declare const createResourceParams: (config: InitiateMeetingConfig) => resources_postConversationRealtimeInsightMeetingInitiate_ResourceRequestConfig;
12
+ export declare function typeCheckConfig(untrustedConfig: adapter$45$utils_Untrusted<InitiateMeetingConfig>): adapter$45$utils_Untrusted<InitiateMeetingConfig>;
13
+ export declare function validateAdapterConfig(untrustedConfig: unknown, configPropertyNames: adapter$45$utils_AdapterValidationConfig): InitiateMeetingConfig | null;
14
+ export declare function buildNetworkSnapshot(luvio: $64$luvio_engine_Luvio, config: InitiateMeetingConfig, options?: $64$luvio_engine_DispatchResourceRequestContext): Promise<import("@luvio/engine").FulfilledSnapshot<types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation, {}> | import("@luvio/engine").StaleSnapshot<types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation, {}> | import("@luvio/engine").PendingSnapshot<types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation, any>>;
15
+ export declare const initiateMeetingAdapterFactory: $64$luvio_engine_AdapterFactory<InitiateMeetingConfig, types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation>;
@@ -1,4 +1,5 @@
1
1
  export { getConversationGenerativeInsightAdapterFactory } from '../adapters/getConversationGenerativeInsight';
2
+ export { initiateMeetingAdapterFactory } from '../adapters/initiateMeeting';
2
3
  export { generateConversationSummaryAdapterFactory } from '../adapters/generateConversationSummary';
3
4
  export { getConversationSummaryRelatedListAdapterFactory } from '../adapters/getConversationSummaryRelatedList';
4
5
  export { getTranscriptAdapterFactory } from '../adapters/getTranscript';
@@ -4,7 +4,8 @@ declare let getConversationGenerativeInsightNotifyChange: any;
4
4
  declare let getConversationSummaryRelatedList: any;
5
5
  declare let getConversationSummaryRelatedListNotifyChange: any;
6
6
  declare let getTranscript: any;
7
+ declare let initiateMeeting: any;
7
8
  declare let getConversationGenerativeInsight_imperative: any;
8
9
  declare let getConversationSummaryRelatedList_imperative: any;
9
10
  declare let getTranscript_imperative: any;
10
- export { generateConversationSummary, getConversationGenerativeInsight, getConversationGenerativeInsightNotifyChange, getConversationSummaryRelatedList, getConversationSummaryRelatedListNotifyChange, getTranscript, getConversationGenerativeInsight_imperative, getConversationSummaryRelatedList_imperative, getTranscript_imperative, };
11
+ export { generateConversationSummary, getConversationGenerativeInsight, getConversationGenerativeInsightNotifyChange, getConversationSummaryRelatedList, getConversationSummaryRelatedListNotifyChange, getTranscript, initiateMeeting, getConversationGenerativeInsight_imperative, getConversationSummaryRelatedList_imperative, getTranscript_imperative, };
@@ -0,0 +1,12 @@
1
+ import { Luvio as $64$luvio_engine_Luvio, Fragment as $64$luvio_engine_Fragment, FetchResponse as $64$luvio_engine_FetchResponse, FulfilledSnapshot as $64$luvio_engine_FulfilledSnapshot, StaleSnapshot as $64$luvio_engine_StaleSnapshot, PendingSnapshot as $64$luvio_engine_PendingSnapshot, ResourceRequest as $64$luvio_engine_ResourceRequest } from '@luvio/engine';
2
+ import { ConversationRealtimeMeetingInitiationResponseRepresentation as types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation } from '../types/ConversationRealtimeMeetingInitiationResponseRepresentation';
3
+ export interface ResourceRequestConfig {
4
+ body: {
5
+ meetingUrl: string;
6
+ };
7
+ }
8
+ export declare function select(luvio: $64$luvio_engine_Luvio, params: ResourceRequestConfig): $64$luvio_engine_Fragment;
9
+ export declare function getResponseCacheKeys(storeKeyMap: any, luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation): void;
10
+ export declare function ingestSuccess(luvio: $64$luvio_engine_Luvio, resourceParams: ResourceRequestConfig, response: $64$luvio_engine_FetchResponse<types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation>): $64$luvio_engine_FulfilledSnapshot<types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation, {}> | $64$luvio_engine_StaleSnapshot<types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation, {}> | $64$luvio_engine_PendingSnapshot<types_ConversationRealtimeMeetingInitiationResponseRepresentation_ConversationRealtimeMeetingInitiationResponseRepresentation, any>;
11
+ export declare function createResourceRequest(config: ResourceRequestConfig): $64$luvio_engine_ResourceRequest;
12
+ export default createResourceRequest;