epicenter-libs 3.34.2 → 3.35.1

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 (40) hide show
  1. package/CHANGELOG.md +61 -0
  2. package/README.md +61 -86
  3. package/dist/browser/epicenter.js +1589 -228
  4. package/dist/browser/epicenter.js.map +1 -1
  5. package/dist/cjs/epicenter.js +1512 -144
  6. package/dist/cjs/epicenter.js.map +1 -1
  7. package/dist/epicenter.js +1595 -227
  8. package/dist/epicenter.js.map +1 -1
  9. package/dist/epicenter.min.js +1 -1
  10. package/dist/epicenter.min.js.map +1 -1
  11. package/dist/module/epicenter.js +1506 -145
  12. package/dist/module/epicenter.js.map +1 -1
  13. package/dist/types/adapters/docket.d.ts +80 -0
  14. package/dist/types/adapters/encyclopedia.d.ts +86 -0
  15. package/dist/types/adapters/file.d.ts +201 -0
  16. package/dist/types/adapters/git.d.ts +171 -0
  17. package/dist/types/adapters/index.d.ts +8 -1
  18. package/dist/types/adapters/pipeline.d.ts +88 -0
  19. package/dist/types/adapters/powerpoint.d.ts +130 -0
  20. package/dist/types/adapters/registration.d.ts +270 -0
  21. package/dist/types/adapters/task.d.ts +99 -37
  22. package/dist/types/epicenter.d.ts +2 -2
  23. package/dist/types/types.d.ts +6 -1
  24. package/dist/types/utils/router.d.ts +1 -0
  25. package/package.json +12 -7
  26. package/src/adapters/authentication.ts +2 -1
  27. package/src/adapters/cometd.ts +7 -2
  28. package/src/adapters/docket.ts +109 -0
  29. package/src/adapters/encyclopedia.ts +128 -0
  30. package/src/adapters/file.ts +332 -0
  31. package/src/adapters/git.ts +278 -0
  32. package/src/adapters/index.ts +14 -0
  33. package/src/adapters/pipeline.ts +145 -0
  34. package/src/adapters/powerpoint.ts +238 -0
  35. package/src/adapters/registration.ts +413 -0
  36. package/src/adapters/task.ts +170 -47
  37. package/src/epicenter.ts +10 -3
  38. package/src/globals.d.ts +6 -0
  39. package/src/types.ts +61 -0
  40. package/src/utils/router.ts +1 -0
package/dist/epicenter.js CHANGED
@@ -25,7 +25,7 @@
25
25
  if (hasRequiredRuntime) return runtime.exports;
26
26
  hasRequiredRuntime = 1;
27
27
  (function (module) {
28
- var runtime = (function (exports$1) {
28
+ var runtime = (function (exports) {
29
29
 
30
30
  var Op = Object.prototype;
31
31
  var hasOwn = Op.hasOwnProperty;
@@ -66,7 +66,7 @@
66
66
 
67
67
  return generator;
68
68
  }
69
- exports$1.wrap = wrap;
69
+ exports.wrap = wrap;
70
70
 
71
71
  // Try/catch helper to minimize deoptimizations. Returns a completion
72
72
  // record like context.tryEntries[i].completion. This interface could
@@ -145,7 +145,7 @@
145
145
  });
146
146
  }
147
147
 
148
- exports$1.isGeneratorFunction = function(genFun) {
148
+ exports.isGeneratorFunction = function(genFun) {
149
149
  var ctor = typeof genFun === "function" && genFun.constructor;
150
150
  return ctor
151
151
  ? ctor === GeneratorFunction ||
@@ -155,7 +155,7 @@
155
155
  : false;
156
156
  };
157
157
 
158
- exports$1.mark = function(genFun) {
158
+ exports.mark = function(genFun) {
159
159
  if (Object.setPrototypeOf) {
160
160
  Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
161
161
  } else {
@@ -170,7 +170,7 @@
170
170
  // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
171
171
  // `hasOwn.call(value, "__await")` to determine if the yielded value is
172
172
  // meant to be awaited.
173
- exports$1.awrap = function(arg) {
173
+ exports.awrap = function(arg) {
174
174
  return { __await: arg };
175
175
  };
176
176
 
@@ -245,12 +245,12 @@
245
245
  define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
246
246
  return this;
247
247
  });
248
- exports$1.AsyncIterator = AsyncIterator;
248
+ exports.AsyncIterator = AsyncIterator;
249
249
 
250
250
  // Note that simple async functions are implemented on top of
251
251
  // AsyncIterator objects; they just return a Promise for the value of
252
252
  // the final result produced by the iterator.
253
- exports$1.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {
253
+ exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {
254
254
  if (PromiseImpl === void 0) PromiseImpl = Promise;
255
255
 
256
256
  var iter = new AsyncIterator(
@@ -258,7 +258,7 @@
258
258
  PromiseImpl
259
259
  );
260
260
 
261
- return exports$1.isGeneratorFunction(outerFn)
261
+ return exports.isGeneratorFunction(outerFn)
262
262
  ? iter // If outerFn is a generator, return the full iterator.
263
263
  : iter.next().then(function(result) {
264
264
  return result.done ? result.value : iter.next();
@@ -478,7 +478,7 @@
478
478
  this.reset(true);
479
479
  }
480
480
 
481
- exports$1.keys = function(val) {
481
+ exports.keys = function(val) {
482
482
  var object = Object(val);
483
483
  var keys = [];
484
484
  for (var key in object) {
@@ -539,7 +539,7 @@
539
539
 
540
540
  throw new TypeError(typeof iterable + " is not iterable");
541
541
  }
542
- exports$1.values = values;
542
+ exports.values = values;
543
543
 
544
544
  function doneResult() {
545
545
  return { value: undefined$1, done: true };
@@ -749,7 +749,7 @@
749
749
  // or not, return the runtime object so that we can declare the variable
750
750
  // regeneratorRuntime in the outer scope, which allows this module to be
751
751
  // injected easily by `bin/regenerator --include-runtime script.js`.
752
- return exports$1;
752
+ return exports;
753
753
 
754
754
  }(
755
755
  // If this script is executing as a CommonJS module, use module.exports
@@ -826,7 +826,7 @@
826
826
  function requireBrowserPonyfill () {
827
827
  if (hasRequiredBrowserPonyfill) return browserPonyfill.exports;
828
828
  hasRequiredBrowserPonyfill = 1;
829
- (function (module, exports$1) {
829
+ (function (module, exports) {
830
830
  // Save global object in a variable
831
831
  var __global__ =
832
832
  (typeof globalThis !== 'undefined' && globalThis) ||
@@ -845,7 +845,7 @@
845
845
  // "globalThis" that's going to be patched
846
846
  (function(globalThis) {
847
847
 
848
- ((function (exports$1) {
848
+ ((function (exports) {
849
849
 
850
850
  /* eslint-disable no-prototype-builtins */
851
851
  var g =
@@ -1358,18 +1358,18 @@
1358
1358
  return new Response(null, {status: status, headers: {location: url}})
1359
1359
  };
1360
1360
 
1361
- exports$1.DOMException = g.DOMException;
1361
+ exports.DOMException = g.DOMException;
1362
1362
  try {
1363
- new exports$1.DOMException();
1363
+ new exports.DOMException();
1364
1364
  } catch (err) {
1365
- exports$1.DOMException = function(message, name) {
1365
+ exports.DOMException = function(message, name) {
1366
1366
  this.message = message;
1367
1367
  this.name = name;
1368
1368
  var error = Error(message);
1369
1369
  this.stack = error.stack;
1370
1370
  };
1371
- exports$1.DOMException.prototype = Object.create(Error.prototype);
1372
- exports$1.DOMException.prototype.constructor = exports$1.DOMException;
1371
+ exports.DOMException.prototype = Object.create(Error.prototype);
1372
+ exports.DOMException.prototype.constructor = exports.DOMException;
1373
1373
  }
1374
1374
 
1375
1375
  function fetch(input, init) {
@@ -1377,7 +1377,7 @@
1377
1377
  var request = new Request(input, init);
1378
1378
 
1379
1379
  if (request.signal && request.signal.aborted) {
1380
- return reject(new exports$1.DOMException('Aborted', 'AbortError'))
1380
+ return reject(new exports.DOMException('Aborted', 'AbortError'))
1381
1381
  }
1382
1382
 
1383
1383
  var xhr = new XMLHttpRequest();
@@ -1419,7 +1419,7 @@
1419
1419
 
1420
1420
  xhr.onabort = function() {
1421
1421
  setTimeout(function() {
1422
- reject(new exports$1.DOMException('Aborted', 'AbortError'));
1422
+ reject(new exports.DOMException('Aborted', 'AbortError'));
1423
1423
  }, 0);
1424
1424
  };
1425
1425
 
@@ -1490,14 +1490,14 @@
1490
1490
  g.Response = Response;
1491
1491
  }
1492
1492
 
1493
- exports$1.Headers = Headers;
1494
- exports$1.Request = Request;
1495
- exports$1.Response = Response;
1496
- exports$1.fetch = fetch;
1493
+ exports.Headers = Headers;
1494
+ exports.Request = Request;
1495
+ exports.Response = Response;
1496
+ exports.fetch = fetch;
1497
1497
 
1498
- Object.defineProperty(exports$1, '__esModule', { value: true });
1498
+ Object.defineProperty(exports, '__esModule', { value: true });
1499
1499
 
1500
- return exports$1;
1500
+ return exports;
1501
1501
 
1502
1502
  }))({});
1503
1503
  })(__globalThis__);
@@ -1506,13 +1506,13 @@
1506
1506
  delete __globalThis__.fetch.polyfill;
1507
1507
  // Choose between native implementation (__global__) or custom implementation (__globalThis__)
1508
1508
  var ctx = __global__.fetch ? __global__ : __globalThis__;
1509
- exports$1 = ctx.fetch; // To enable: import fetch from 'cross-fetch'
1510
- exports$1.default = ctx.fetch; // For TypeScript consumers without esModuleInterop.
1511
- exports$1.fetch = ctx.fetch; // To enable: import {fetch} from 'cross-fetch'
1512
- exports$1.Headers = ctx.Headers;
1513
- exports$1.Request = ctx.Request;
1514
- exports$1.Response = ctx.Response;
1515
- module.exports = exports$1;
1509
+ exports = ctx.fetch; // To enable: import fetch from 'cross-fetch'
1510
+ exports.default = ctx.fetch; // For TypeScript consumers without esModuleInterop.
1511
+ exports.fetch = ctx.fetch; // To enable: import {fetch} from 'cross-fetch'
1512
+ exports.Headers = ctx.Headers;
1513
+ exports.Request = ctx.Request;
1514
+ exports.Response = ctx.Response;
1515
+ module.exports = exports;
1516
1516
  } (browserPonyfill, browserPonyfill.exports));
1517
1517
  return browserPonyfill.exports;
1518
1518
  }
@@ -3318,7 +3318,7 @@
3318
3318
  * @param [optionals] Optional arguments; pass network call options overrides here.
3319
3319
  * @returns promise that resolves to the project object
3320
3320
  */
3321
- async function get$e(optionals = {}) {
3321
+ async function get$f(optionals = {}) {
3322
3322
  return await new Router().get('/project', optionals).then(({
3323
3323
  body
3324
3324
  }) => body);
@@ -3336,7 +3336,7 @@
3336
3336
  * @param [optionals] Optional arguments; pass network call options overrides here.
3337
3337
  * @returns promise that resolves to an array of project objects
3338
3338
  */
3339
- async function list$4(accountShortName, optionals = {}) {
3339
+ async function list$5(accountShortName, optionals = {}) {
3340
3340
  return await new Router().withAccountShortName(accountShortName).withProjectShortName('manager').get('/project/in', optionals).then(({
3341
3341
  body
3342
3342
  }) => body);
@@ -3349,8 +3349,8 @@
3349
3349
  PHYLOGENY: PHYLOGENY,
3350
3350
  WORKER_PARTITION: WORKER_PARTITION,
3351
3351
  channelsEnabled: channelsEnabled,
3352
- get: get$e,
3353
- list: list$4
3352
+ get: get$f,
3353
+ list: list$5
3354
3354
  });
3355
3355
 
3356
3356
  const AUTH_TOKEN_KEY = 'com.forio.epicenter.token';
@@ -3367,6 +3367,7 @@
3367
3367
  const DISCONNECT_META_CHANNEL = '/meta/disconnect';
3368
3368
  const HANDSHAKE_META_CHANNEL = '/meta/handshake';
3369
3369
  const COMETD_RECONNECTED = 'COMETD_RECONNECTED';
3370
+ const CHANNELS_NOT_ENABLED = 'CHANNELS_NOT_ENABLED';
3370
3371
  const DEFAULT_CHANNEL_PROTOCOL = 'cometd';
3371
3372
  // error messages that indicate session invalidation as
3372
3373
  // described in cometd documentation and oumuamua source code:
@@ -3417,8 +3418,8 @@
3417
3418
  logLevel: 'warn'
3418
3419
  }) {
3419
3420
  var _project$channelProto;
3420
- const project = await get$e();
3421
- if (!project.channelEnabled) throw new EpicenterError('Push Channels are not enabled on this project');
3421
+ const project = await get$f();
3422
+ if (!project.channelEnabled) throw new EpicenterError('Push Channels are not enabled on this project', CHANNELS_NOT_ENABLED);
3422
3423
  const channelProtocol = ((_project$channelProto = project.channelProtocol) === null || _project$channelProto === void 0 ? void 0 : _project$channelProto.toLowerCase()) || DEFAULT_CHANNEL_PROTOCOL;
3423
3424
  const {
3424
3425
  CometD
@@ -3524,7 +3525,11 @@
3524
3525
  }
3525
3526
  async init(options) {
3526
3527
  if (!this.initialization) {
3527
- this.initialization = this.startup(options);
3528
+ // A rejected startup must not be cached, or every later init() call re-throws it
3529
+ this.initialization = this.startup(options).catch(error => {
3530
+ this.initialization = undefined;
3531
+ throw error;
3532
+ });
3528
3533
  }
3529
3534
  return this.initialization;
3530
3535
  }
@@ -3941,7 +3946,8 @@
3941
3946
  */
3942
3947
  async function removeLocalSession() {
3943
3948
  identification.session = undefined;
3944
- await cometdAdapter.disconnect();
3949
+ // CometD disconnect is best-effort cleanup; its failure must not fail session removal
3950
+ await cometdAdapter.disconnect().catch(() => undefined);
3945
3951
  }
3946
3952
 
3947
3953
  /**
@@ -4237,7 +4243,7 @@
4237
4243
  * @param [optionals.tokenAccessSeconds] How long the presigned URL is valid for in seconds
4238
4244
  * @returns promise that resolves to an asset ticket containing the presigned upload URL
4239
4245
  */
4240
- async function create$a(file, scope, optionals = {}) {
4246
+ async function create$c(file, scope, optionals = {}) {
4241
4247
  const {
4242
4248
  scopeBoundary,
4243
4249
  scopeKey,
@@ -4342,7 +4348,7 @@
4342
4348
  * @param [optionals] Optional arguments; pass network call options overrides here.
4343
4349
  * @returns promise that resolves when the asset is deleted
4344
4350
  */
4345
- async function remove$4(assetKey, optionals = {}) {
4351
+ async function remove$5(assetKey, optionals = {}) {
4346
4352
  return await new Router().delete(`/asset/${assetKey}`, optionals).then(({
4347
4353
  body
4348
4354
  }) => body);
@@ -4390,7 +4396,7 @@
4390
4396
  * @param [optionals] Optional arguments; pass network call options overrides here.
4391
4397
  * @returns promise that resolves to the asset metadata
4392
4398
  */
4393
- async function get$d(assetKey, optionals = {}) {
4399
+ async function get$e(assetKey, optionals = {}) {
4394
4400
  const {
4395
4401
  server,
4396
4402
  accountShortName,
@@ -4426,7 +4432,7 @@
4426
4432
  * @param [optionals.filter] File pattern to filter assets (e.g., '*.pdf' for PDF files); defaults to '*' (all files)
4427
4433
  * @returns promise that resolves to a list of assets
4428
4434
  */
4429
- async function list$3(scope, optionals = {}) {
4435
+ async function list$4(scope, optionals = {}) {
4430
4436
  const {
4431
4437
  scopeBoundary,
4432
4438
  scopeKey,
@@ -4519,7 +4525,7 @@
4519
4525
  * @param [optionals.tokenAccessSeconds] How long the presigned URL is valid for in seconds
4520
4526
  * @returns promise that resolves when the download is complete
4521
4527
  */
4522
- async function download$1(assetKey, optionals = {}) {
4528
+ async function download$2(assetKey, optionals = {}) {
4523
4529
  const {
4524
4530
  tokenAccessSeconds,
4525
4531
  ...routingOptions
@@ -4607,7 +4613,7 @@
4607
4613
  const name = fileName !== null && fileName !== void 0 ? fileName : file.name;
4608
4614
  let presignedUrl = '';
4609
4615
  try {
4610
- const response = await create$a(name, scope, {
4616
+ const response = await create$c(name, scope, {
4611
4617
  inert: true,
4612
4618
  ...remaining
4613
4619
  });
@@ -4631,14 +4637,14 @@
4631
4637
 
4632
4638
  var asset = /*#__PURE__*/Object.freeze({
4633
4639
  __proto__: null,
4634
- create: create$a,
4635
- download: download$1,
4640
+ create: create$c,
4641
+ download: download$2,
4636
4642
  downloadWithScope: downloadWithScope,
4637
- get: get$d,
4643
+ get: get$e,
4638
4644
  getURL: getURL$1,
4639
4645
  getURLWithScope: getURLWithScope,
4640
- list: list$3,
4641
- remove: remove$4,
4646
+ list: list$4,
4647
+ remove: remove$5,
4642
4648
  removeFromScope: removeFromScope,
4643
4649
  store: store,
4644
4650
  update: update$6
@@ -4846,7 +4852,7 @@
4846
4852
  * @param [optionals.category] Optional argument to allow for establishing episode hierarchies
4847
4853
  * @returns promise that resolves to the newly created episode
4848
4854
  */
4849
- async function create$9(name, groupName, optionals = {}) {
4855
+ async function create$b(name, groupName, optionals = {}) {
4850
4856
  const {
4851
4857
  draft,
4852
4858
  runLimit,
@@ -4878,7 +4884,7 @@
4878
4884
  * @param [optionals] Optional arguments; pass network call options overrides here.
4879
4885
  * @returns promise that resolves to an episode
4880
4886
  */
4881
- async function get$c(episodeKey, optionals = {}) {
4887
+ async function get$d(episodeKey, optionals = {}) {
4882
4888
  return await new Router().get(`/episode/${episodeKey}`, optionals).then(({
4883
4889
  body
4884
4890
  }) => body);
@@ -4914,7 +4920,7 @@
4914
4920
  * @param [optionals] Optional arguments; pass network call options overrides here.
4915
4921
  * @returns promise that resolves to a page of episodes
4916
4922
  */
4917
- async function query$4(searchOptions, optionals = {}) {
4923
+ async function query$5(searchOptions, optionals = {}) {
4918
4924
  const {
4919
4925
  filter,
4920
4926
  sort = [],
@@ -4988,7 +4994,7 @@
4988
4994
  * @param [optionals] Optional arguments; pass network call options overrides here.
4989
4995
  * @returns promise that resolves to undefined if successful
4990
4996
  */
4991
- async function remove$3(episodeKey, optionals = {}) {
4997
+ async function remove$4(episodeKey, optionals = {}) {
4992
4998
  return await new Router().delete(`/episode/${episodeKey}`, optionals).then(({
4993
4999
  body
4994
5000
  }) => body);
@@ -4996,11 +5002,11 @@
4996
5002
 
4997
5003
  var episode = /*#__PURE__*/Object.freeze({
4998
5004
  __proto__: null,
4999
- create: create$9,
5005
+ create: create$b,
5000
5006
  forGroup: forGroup$1,
5001
- get: get$c,
5002
- query: query$4,
5003
- remove: remove$3,
5007
+ get: get$d,
5008
+ query: query$5,
5009
+ remove: remove$4,
5004
5010
  withName: withName
5005
5011
  });
5006
5012
 
@@ -5023,7 +5029,7 @@
5023
5029
  * @param [optionals.groupKey] Group key; if omitted will attempt to use the group associated with the current session
5024
5030
  * @returns promise that resolves to a group
5025
5031
  */
5026
- async function get$b(optionals = {}) {
5032
+ async function get$c(optionals = {}) {
5027
5033
  const {
5028
5034
  groupKey,
5029
5035
  augment,
@@ -5173,7 +5179,7 @@
5173
5179
  * @param [optionals] Optional arguments; pass network call options overrides here.
5174
5180
  * @returns promise that resolves to the newly created group
5175
5181
  */
5176
- async function create$8(group, optionals = {}) {
5182
+ async function create$a(group, optionals = {}) {
5177
5183
  const {
5178
5184
  name,
5179
5185
  runLimit,
@@ -5240,7 +5246,7 @@
5240
5246
  * @param [optionals] Optional arguments; pass network call options overrides here.
5241
5247
  * @returns promise that resolves to a page of groups
5242
5248
  */
5243
- async function query$3(searchOptions, optionals = {}) {
5249
+ async function query$4(searchOptions, optionals = {}) {
5244
5250
  const {
5245
5251
  filter,
5246
5252
  sort = [],
@@ -5279,7 +5285,7 @@
5279
5285
  max,
5280
5286
  quantized
5281
5287
  };
5282
- return await query$3(searchOptions, routingOptions);
5288
+ return await query$4(searchOptions, routingOptions);
5283
5289
  }
5284
5290
 
5285
5291
  /**
@@ -5652,14 +5658,14 @@
5652
5658
  var group = /*#__PURE__*/Object.freeze({
5653
5659
  __proto__: null,
5654
5660
  addUser: addUser$1,
5655
- create: create$8,
5661
+ create: create$a,
5656
5662
  destroy: destroy$2,
5657
5663
  forUser: forUser,
5658
5664
  gather: gather,
5659
- get: get$b,
5665
+ get: get$c,
5660
5666
  getSessionGroups: getSessionGroups,
5661
5667
  getWhitelistedUsers: getWhitelistedUsers,
5662
- query: query$3,
5668
+ query: query$4,
5663
5669
  removeUser: removeUser,
5664
5670
  search: search,
5665
5671
  selfRegister: selfRegister,
@@ -5758,7 +5764,7 @@
5758
5764
  * @param [optionals] Optional arguments; pass network call options overrides here.
5759
5765
  * @returns promise that resolves to a list of leaderboard entries
5760
5766
  */
5761
- async function list$2(collection, scope, searchOptions, optionals = {}) {
5767
+ async function list$3(collection, scope, searchOptions, optionals = {}) {
5762
5768
  const {
5763
5769
  scopeBoundary,
5764
5770
  scopeKey
@@ -5779,9 +5785,9 @@
5779
5785
  body
5780
5786
  }) => body);
5781
5787
  }
5782
- async function get$a(collection, scope, searchOptions, optionals = {}) {
5788
+ async function get$b(collection, scope, searchOptions, optionals = {}) {
5783
5789
  console.warn('DEPRECATION WARNING: leaderboardAdapter.get is deprecated and will be removed with the next release. Use leaderboardAdapter.list instead.');
5784
- return await list$2(collection, scope, searchOptions, optionals);
5790
+ return await list$3(collection, scope, searchOptions, optionals);
5785
5791
  }
5786
5792
 
5787
5793
  /**
@@ -5827,9 +5833,9 @@
5827
5833
 
5828
5834
  var leaderboard = /*#__PURE__*/Object.freeze({
5829
5835
  __proto__: null,
5830
- get: get$a,
5836
+ get: get$b,
5831
5837
  getCount: getCount,
5832
- list: list$2,
5838
+ list: list$3,
5833
5839
  update: update$4
5834
5840
  });
5835
5841
 
@@ -5978,7 +5984,7 @@
5978
5984
  * @param [optionals.allowChannel] Opt into push notifications for this resource. Applicable to projects with phylogeny >= SILENT
5979
5985
  * @returns promise that resolves to the newly created run
5980
5986
  */
5981
- async function create$7(model, scope, optionals = {}) {
5987
+ async function create$9(model, scope, optionals = {}) {
5982
5988
  const {
5983
5989
  scopeBoundary,
5984
5990
  scopeKey,
@@ -6269,7 +6275,7 @@
6269
6275
  * @param [optionals] Optional arguments; pass network call options overrides here.
6270
6276
  * @returns promise that resolve to undefined if successful
6271
6277
  */
6272
- async function remove$2(runKey, optionals = {}) {
6278
+ async function remove$3(runKey, optionals = {}) {
6273
6279
  return await new Router().delete(`/run/${runKey}`, optionals).then(({
6274
6280
  body
6275
6281
  }) => body);
@@ -6287,7 +6293,7 @@
6287
6293
  * @param [optionals] Optional arguments; pass network call options overrides here.
6288
6294
  * @returns promise that resolves to the run
6289
6295
  */
6290
- async function get$9(runKey, optionals = {}) {
6296
+ async function get$a(runKey, optionals = {}) {
6291
6297
  return await new Router().get(`/run/${runKey}`, optionals).then(({
6292
6298
  body
6293
6299
  }) => body);
@@ -6329,7 +6335,7 @@
6329
6335
  * @param [optionals] Optional arguments; pass network call options overrides here.
6330
6336
  * @returns promise that resolves to a page of runs
6331
6337
  */
6332
- async function query$2(model, searchOptions, optionals = {}) {
6338
+ async function query$3(model, searchOptions, optionals = {}) {
6333
6339
  const {
6334
6340
  filter,
6335
6341
  sort = [],
@@ -6886,15 +6892,15 @@
6886
6892
  };
6887
6893
  const {
6888
6894
  values: [lastRun]
6889
- } = await query$2(model, searchOptions);
6895
+ } = await query$3(model, searchOptions);
6890
6896
  if (!lastRun) {
6891
- const newRun = await create$7(model, scope, optionals);
6897
+ const newRun = await create$9(model, scope, optionals);
6892
6898
  // await serial(newRun.runKey, initOperations, optionals = {});
6893
6899
  return newRun;
6894
6900
  }
6895
6901
  return lastRun;
6896
6902
  } else if (strategy === 'reuse-never') {
6897
- const newRun = await create$7(model, scope, optionals);
6903
+ const newRun = await create$9(model, scope, optionals);
6898
6904
  // await serial(newRun.runKey, initOperations, optionals = {});
6899
6905
  return newRun;
6900
6906
  } else ;
@@ -6947,9 +6953,9 @@
6947
6953
  MORPHOLOGY: MORPHOLOGY,
6948
6954
  action: action,
6949
6955
  clone: clone,
6950
- create: create$7,
6956
+ create: create$9,
6951
6957
  createSingular: createSingular,
6952
- get: get$9,
6958
+ get: get$a,
6953
6959
  getMetadata: getMetadata,
6954
6960
  getSingularRunKey: getSingularRunKey,
6955
6961
  getVariable: getVariable,
@@ -6959,8 +6965,8 @@
6959
6965
  introspectWithRunKey: introspectWithRunKey,
6960
6966
  migrate: migrate,
6961
6967
  operation: operation,
6962
- query: query$2,
6963
- remove: remove$2,
6968
+ query: query$3,
6969
+ remove: remove$3,
6964
6970
  removeFromWorld: removeFromWorld,
6965
6971
  restore: restore,
6966
6972
  retrieveFromWorld: retrieveFromWorld,
@@ -7042,7 +7048,7 @@
7042
7048
  * @param [optionals] Optional arguments; pass network call options overrides here.
7043
7049
  * @returns promise that resolves to a user
7044
7050
  */
7045
- async function get$8(userKey, optionals = {}) {
7051
+ async function get$9(userKey, optionals = {}) {
7046
7052
  return await new Router().get(`/user/${userKey}`, optionals).then(({
7047
7053
  body
7048
7054
  }) => body);
@@ -7075,7 +7081,7 @@
7075
7081
  var user = /*#__PURE__*/Object.freeze({
7076
7082
  __proto__: null,
7077
7083
  createUser: createUser,
7078
- get: get$8,
7084
+ get: get$9,
7079
7085
  getWithHandle: getWithHandle,
7080
7086
  uploadCSV: uploadCSV
7081
7087
  });
@@ -7166,7 +7172,7 @@
7166
7172
  * @param [optionals] Optional arguments; pass network call options overrides here.
7167
7173
  * @returns promise that resolves to the vault, or undefined if not found
7168
7174
  */
7169
- async function get$7(vaultKey, optionals = {}) {
7175
+ async function get$8(vaultKey, optionals = {}) {
7170
7176
  return await new Router().get(`/vault/${vaultKey}`, optionals).catch(error => {
7171
7177
  if (error.status === NOT_FOUND$4) return {
7172
7178
  body: undefined
@@ -7266,7 +7272,7 @@
7266
7272
  * @param [optionals.mutationKey] Mutation key for optimistic concurrency control
7267
7273
  * @returns promise that resolves to undefined when successful
7268
7274
  */
7269
- async function remove$1(vaultKey, optionals = {}) {
7275
+ async function remove$2(vaultKey, optionals = {}) {
7270
7276
  const {
7271
7277
  mutationKey,
7272
7278
  ...routingOptions
@@ -7381,7 +7387,7 @@
7381
7387
  * @param [optionals.mutationStrategy] Mutation strategy: ALLOW (upsert), DISALLOW (insert without update), ERROR (insert with conflict exception if exists)
7382
7388
  * @returns promise that resolves to the created vault
7383
7389
  */
7384
- async function create$6(name, scope, items, optionals = {}) {
7390
+ async function create$8(name, scope, items, optionals = {}) {
7385
7391
  console.warn('DEPRECATION WARNING: vaultAdapter.create is deprecated and will be removed with the next release. Use vaultAdapter.define instead.');
7386
7392
  return await define(name, scope, {
7387
7393
  items,
@@ -7413,7 +7419,7 @@
7413
7419
  * @param [optionals.groupName] Name of the group
7414
7420
  * @returns promise that resolves to an array of vaults that match the search options
7415
7421
  */
7416
- async function list$1(searchOptions, optionals = {}) {
7422
+ async function list$2(searchOptions, optionals = {}) {
7417
7423
  const {
7418
7424
  first,
7419
7425
  filter,
@@ -7478,11 +7484,11 @@
7478
7484
  __proto__: null,
7479
7485
  byName: byName$1,
7480
7486
  count: count,
7481
- create: create$6,
7487
+ create: create$8,
7482
7488
  define: define,
7483
- get: get$7,
7484
- list: list$1,
7485
- remove: remove$1,
7489
+ get: get$8,
7490
+ list: list$2,
7491
+ remove: remove$2,
7486
7492
  update: update$2,
7487
7493
  updateProperties: updateProperties,
7488
7494
  withScope: withScope$1
@@ -7807,7 +7813,7 @@
7807
7813
  * @param [optionals] Optional arguments; pass network call options overrides here.
7808
7814
  * @returns promise that resolves to undefined when successful
7809
7815
  */
7810
- async function remove(videoKey, optionals = {}) {
7816
+ async function remove$1(videoKey, optionals = {}) {
7811
7817
  return deleteVideoByKey(videoKey, optionals);
7812
7818
  }
7813
7819
 
@@ -7832,7 +7838,7 @@
7832
7838
  * @param [optionals] Optional arguments; pass network call options overrides here.
7833
7839
  * @returns promise that resolves to a page of video objects
7834
7840
  */
7835
- async function query$1(searchOptions, optionals = {}) {
7841
+ async function query$2(searchOptions, optionals = {}) {
7836
7842
  const {
7837
7843
  filter,
7838
7844
  sort = [],
@@ -8022,7 +8028,7 @@
8022
8028
  * @param [optionals.videoKey] Key for the video object
8023
8029
  * @returns promise that resolves to undefined when download is complete
8024
8030
  */
8025
- async function download(file, optionals = {}) {
8031
+ async function download$1(file, optionals = {}) {
8026
8032
  const {
8027
8033
  scope,
8028
8034
  affiliate,
@@ -8041,12 +8047,12 @@
8041
8047
 
8042
8048
  var video = /*#__PURE__*/Object.freeze({
8043
8049
  __proto__: null,
8044
- download: download,
8050
+ download: download$1,
8045
8051
  getDirectoryURL: getDirectoryURL,
8046
8052
  getURL: getURL,
8047
8053
  processVideo: processVideo,
8048
- query: query$1,
8049
- remove: remove
8054
+ query: query$2,
8055
+ remove: remove$1
8050
8056
  });
8051
8057
 
8052
8058
  /**
@@ -8393,7 +8399,7 @@
8393
8399
  * @param [optionals.allowChannel] Opt into push notifications for this resource. Applicable to projects with phylogeny >= SILENT
8394
8400
  * @returns promise that resolves to the newly created world
8395
8401
  */
8396
- async function create$5(optionals = {}) {
8402
+ async function create$7(optionals = {}) {
8397
8403
  const {
8398
8404
  name,
8399
8405
  displayName,
@@ -8435,7 +8441,7 @@
8435
8441
  * @param [optionals.mine] Flag for indicating to get only the worlds the requesting user is in (based on session token)
8436
8442
  * @returns promise that resolves to a list of worlds
8437
8443
  */
8438
- async function get$6(optionals = {}) {
8444
+ async function get$7(optionals = {}) {
8439
8445
  const {
8440
8446
  groupName,
8441
8447
  episodeName,
@@ -8816,10 +8822,10 @@
8816
8822
  WORLD_NAME_GENERATOR_TYPE: WORLD_NAME_GENERATOR_TYPE,
8817
8823
  assignRun: assignRun,
8818
8824
  autoAssignUsers: autoAssignUsers,
8819
- create: create$5,
8825
+ create: create$7,
8820
8826
  destroy: destroy$1,
8821
8827
  editAssignments: editAssignments,
8822
- get: get$6,
8828
+ get: get$7,
8823
8829
  getAssignments: getAssignments,
8824
8830
  getAssignmentsByKey: getAssignmentsByKey,
8825
8831
  getPersonas: getPersonas,
@@ -8844,7 +8850,7 @@
8844
8850
  * @returns promise that resolves to the current server time in ISO 8601 format, or undefined if not found
8845
8851
  */
8846
8852
  const NOT_FOUND$3 = 404;
8847
- async function get$5(optionals = {}) {
8853
+ async function get$6(optionals = {}) {
8848
8854
  return await new Router().get('/time', optionals).catch(error => {
8849
8855
  if (error.status === NOT_FOUND$3) return {
8850
8856
  body: undefined
@@ -8857,15 +8863,13 @@
8857
8863
 
8858
8864
  var time = /*#__PURE__*/Object.freeze({
8859
8865
  __proto__: null,
8860
- get: get$5
8866
+ get: get$6
8861
8867
  });
8862
8868
 
8863
8869
  let RETRY_POLICY = /*#__PURE__*/function (RETRY_POLICY) {
8864
8870
  RETRY_POLICY["DO_NOTHING"] = "DO_NOTHING";
8865
8871
  // If the task fails, do nothing (this is the default)
8866
- RETRY_POLICY["RESCHEDULE"] = "RESCHEDULE";
8867
- // If the task fails retry at the next scheduled time point
8868
- RETRY_POLICY["FIRE_ON_FAIL_SAFE"] = "FIRE_ON_FAIL_SAFE"; // Will re-execute the task after it fails; how long until this occurs is equal to ttlSeconds
8872
+ RETRY_POLICY["FIRE_ON_FAIL_SAFE"] = "FIRE_ON_FAIL_SAFE"; // Retry within the task's fail-safe execution window
8869
8873
  return RETRY_POLICY;
8870
8874
  }({});
8871
8875
 
@@ -8882,7 +8886,7 @@
8882
8886
  // Task response structure
8883
8887
 
8884
8888
  /**
8885
- * Creates a task; requires support level authentication
8889
+ * Creates a task; requires facilitator (or higher) privileges
8886
8890
  * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/task`
8887
8891
  *
8888
8892
  * @example
@@ -8894,7 +8898,9 @@
8894
8898
  * const name = 'task-1-send-emails';
8895
8899
  * const payload = {
8896
8900
  * method: 'POST',
8897
- * url: 'https://forio.com/app/forio-dev/test-project/send-out-emails',
8901
+ * url: '/send-out-emails',
8902
+ * target: 'PROXY', // fire at the project's proxy server; omit to fire at the app
8903
+ * body: {},
8898
8904
  * };
8899
8905
  * const trigger = {
8900
8906
  * value: '0 7 15 * * ?', // triggers on day 15 7am of each month
@@ -8907,11 +8913,13 @@
8907
8913
  * @param scope.scopeKey Scope key, a unique identifier tied to the scope. E.g., if your `scopeBoundary` is `GROUP`, your `scopeKey` will be your `groupKey`; for `EPISODE`, `episodeKey`, etc.
8908
8914
  * @param [scope.userKey] Key associated with the user
8909
8915
  * @param name Name of the task
8910
- * @param payload An HTTP task object that will be executed when the task is triggered
8911
- * @param payload.method Type of method to use with the HTTP request (e.g., 'GET', 'POST', 'PATCH')
8912
- * @param payload.url The URL the HTTP request will be sent to
8913
- * @param [payload.body] The body of the HTTP request
8914
- * @param [payload.headers] Headers to send along with the HTTP request
8916
+ * @param payload An HTTP request or group-status change to execute when the task is triggered
8917
+ * @param payload.method Type of method to use with the HTTP request (e.g., 'GET', 'POST')
8918
+ * @param payload.url Relative URL the HTTP request will be sent to; the task runner builds the full URL as `{host}{targetPath}/{account}/{project}{url}`
8919
+ * @param [payload.target] Where the task fires: 'APPLICATION' (the project app, `/app`, the default) or 'PROXY' (the project's proxy server, `/proxy`)
8920
+ * @param payload.body The JSON body of the HTTP request
8921
+ * @param [payload.headers] Headers to send along with the HTTP request; must be non-empty when provided — omit rather than pass an empty object
8922
+ * @param [payload.timeoutSeconds] Request timeout in seconds (1–30)
8915
8923
  * @param trigger Object that determines when to run the task (cron, offset, or date)
8916
8924
  * @param [trigger.value] For cron: cron expression (e.g., '0 7 * * * ?'). For date: ISO-8601 date-time string
8917
8925
  * @param [trigger.objectType] Type of trigger: 'cron', 'offset', or 'date'
@@ -8922,23 +8930,24 @@
8922
8930
  * @param [optionals.accountShortName] Name of account (by default will be the account associated with the session)
8923
8931
  * @param [optionals.projectShortName] Name of project (by default will be the project associated with the session)
8924
8932
  * @param [optionals.retryPolicy] Specifies what to do should the task fail; see RETRY_POLICY
8925
- * @param [optionals.failSafeTermination] The ISO-8601 date-time when the task will be deleted regardless of any triggers; defaults to null
8926
- * @param [optionals.ttlSeconds] Max life expectancy of the task; used to determine if retrying the task is necessary
8933
+ * @param [optionals.failSafeTermination] ISO-8601 deadline after which the task terminates; the server defaults and caps this at one year from creation
8934
+ * @param [optionals.ttlSeconds] Execution fail-safe window in seconds; the server applies its configured minimum
8927
8935
  * @returns promise that resolves to the task object including the taskKey
8928
8936
  */
8929
- async function create$4(scope, name, payload, trigger, optionals = {}) {
8937
+ async function create$6(scope, name, payload, trigger, optionals = {}) {
8930
8938
  const {
8931
8939
  retryPolicy,
8932
8940
  failSafeTermination,
8933
8941
  ttlSeconds,
8934
8942
  ...routingOptions
8935
8943
  } = optionals;
8944
+ const normalizedPayload = payload.objectType === 'groupStatus' ? payload : {
8945
+ ...payload,
8946
+ objectType: 'http'
8947
+ };
8936
8948
  return await new Router().post('/task', {
8937
8949
  body: {
8938
- payload: {
8939
- objectType: 'http',
8940
- ...payload
8941
- },
8950
+ payload: normalizedPayload,
8942
8951
  trigger,
8943
8952
  retryPolicy,
8944
8953
  failSafeTermination,
@@ -8953,7 +8962,7 @@
8953
8962
  }
8954
8963
 
8955
8964
  /**
8956
- * Deletes a task (changes status to cancelled); requires support level authentication
8965
+ * Deletes a task (changes status to cancelled); requires facilitator (or higher) privileges
8957
8966
  * Base URL: DELETE `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/task/{TASK_KEY}`
8958
8967
  *
8959
8968
  * @example
@@ -8962,7 +8971,7 @@
8962
8971
  * await taskAdapter.destroy(taskKey);
8963
8972
  *
8964
8973
  * @param taskKey Unique key associated with a task
8965
- * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
8974
+ * @param [optionals] Optional arguments; pass network call options overrides here.
8966
8975
  * @param [optionals.accountShortName] Name of account (by default will be the account associated with the session)
8967
8976
  * @param [optionals.projectShortName] Name of project (by default will be the project associated with the session)
8968
8977
  * @returns promise that resolves to undefined when successful
@@ -8974,7 +8983,7 @@
8974
8983
  }
8975
8984
 
8976
8985
  /**
8977
- * Gets a task by taskKey; requires support level authentication
8986
+ * Gets a task by taskKey; requires facilitator (or higher) privileges
8978
8987
  * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/task/{TASK_KEY}`
8979
8988
  *
8980
8989
  * @example
@@ -8983,19 +8992,19 @@
8983
8992
  * const task = await taskAdapter.get(taskKey);
8984
8993
  *
8985
8994
  * @param taskKey Unique key associated with a task
8986
- * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
8995
+ * @param [optionals] Optional arguments; pass network call options overrides here.
8987
8996
  * @param [optionals.accountShortName] Name of account (by default will be the account associated with the session)
8988
8997
  * @param [optionals.projectShortName] Name of project (by default will be the project associated with the session)
8989
8998
  * @returns promise that resolves to the task object
8990
8999
  */
8991
- async function get$4(taskKey, optionals = {}) {
9000
+ async function get$5(taskKey, optionals = {}) {
8992
9001
  return await new Router().get(`/task/${taskKey}`, optionals).then(({
8993
9002
  body
8994
9003
  }) => body);
8995
9004
  }
8996
9005
 
8997
9006
  /**
8998
- * Gets the history (100 most recent times it has triggered) of a task by taskKey; requires support level authentication
9007
+ * Gets the history (100 most recent times it has triggered) of a task by taskKey; requires facilitator (or higher) privileges
8999
9008
  * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/task/history/{TASK_KEY}`
9000
9009
  *
9001
9010
  * @example
@@ -9004,19 +9013,32 @@
9004
9013
  * const history = await taskAdapter.getHistory(taskKey);
9005
9014
  *
9006
9015
  * @param taskKey Unique key associated with a task
9007
- * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
9016
+ * @param [optionals] Pagination and network options
9017
+ * @param [optionals.first] Zero-based index of the first history record; defaults to 0
9018
+ * @param [optionals.max] Maximum history records to return; defaults to 100 and cannot exceed 100
9008
9019
  * @param [optionals.accountShortName] Name of account (by default will be the account associated with the session)
9009
9020
  * @param [optionals.projectShortName] Name of project (by default will be the project associated with the session)
9010
- * @returns promise that resolves to an array of task history objects
9021
+ * @returns promise that resolves to a page of task history objects
9011
9022
  */
9012
9023
  async function getHistory(taskKey, optionals = {}) {
9013
- return await new Router().get(`/task/history/${taskKey}`, optionals).then(({
9024
+ const {
9025
+ first,
9026
+ max,
9027
+ ...routingOptions
9028
+ } = optionals;
9029
+ return await new Router().withSearchParams({
9030
+ first,
9031
+ max
9032
+ }).get(`/task/history/${taskKey}`, {
9033
+ paginated: true,
9034
+ ...routingOptions
9035
+ }).then(({
9014
9036
  body
9015
9037
  }) => body);
9016
9038
  }
9017
9039
 
9018
9040
  /**
9019
- * Gets most recent 100 tasks related to the selected scope; requires support level authentication
9041
+ * Gets most recent 100 tasks related to the selected scope; requires facilitator (or higher) privileges
9020
9042
  * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/task/in/{SCOPE_BOUNDARY}/{SCOPE_KEY}` or GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/task/in/{SCOPE_BOUNDARY}/{SCOPE_KEY}/{USER_KEY}`
9021
9043
  *
9022
9044
  * Note: Will retrieve all tasks that were CREATED in the specified scope. If something was created with episode scope, it will not be retrievable through group scoping.
@@ -9033,10 +9055,13 @@
9033
9055
  * @param scope.scopeBoundary Scope boundary, defines the type of scope; See [scope boundary](#SCOPE_BOUNDARY) for all types
9034
9056
  * @param scope.scopeKey Scope key, a unique identifier tied to the scope. E.g., if your `scopeBoundary` is `GROUP`, your `scopeKey` will be your `groupKey`; for `EPISODE`, `episodeKey`, etc.
9035
9057
  * @param [scope.userKey] Key associated with the user; will retrieve tasks in the scope that were made by the specified user
9036
- * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
9058
+ * @param [optionals] Pagination, sorting, and network options
9059
+ * @param [optionals.sort] Task fields to sort by
9060
+ * @param [optionals.first] Zero-based index of the first task; defaults to 0
9061
+ * @param [optionals.max] Maximum tasks to return; defaults to 100 and cannot exceed 100
9037
9062
  * @param [optionals.accountShortName] Name of account (by default will be the account associated with the session)
9038
9063
  * @param [optionals.projectShortName] Name of project (by default will be the project associated with the session)
9039
- * @returns promise that resolves to an array of task objects
9064
+ * @returns promise that resolves to a page of task objects
9040
9065
  */
9041
9066
  async function getTaskIn(scope, optionals = {}) {
9042
9067
  const {
@@ -9044,7 +9069,70 @@
9044
9069
  scopeKey,
9045
9070
  userKey
9046
9071
  } = scope;
9047
- return await new Router().get(`/task/in/${scopeBoundary}/${scopeKey}${userKey ? `/${userKey}` : ''}`, optionals).then(({
9072
+ const {
9073
+ sort = [],
9074
+ first,
9075
+ max,
9076
+ ...routingOptions
9077
+ } = optionals;
9078
+ return await new Router().withSearchParams({
9079
+ sort: sort.join(';') || undefined,
9080
+ first,
9081
+ max
9082
+ }).get(`/task/in/${scopeBoundary}/${scopeKey}${userKey ? `/${userKey}` : ''}`, {
9083
+ paginated: true,
9084
+ ...routingOptions
9085
+ }).then(({
9086
+ body
9087
+ }) => body);
9088
+ }
9089
+
9090
+ /**
9091
+ * Queries for tasks
9092
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/task/search`
9093
+ *
9094
+ * No authentication is required; results use facilitator-level row visibility.
9095
+ * Filterable/sortable fields include
9096
+ * `task.taskKey`, `task.name`, `task.status`, `task.scopeBoundary`, `task.scopeKey`,
9097
+ * `task.userKey`, `task.groupName`, `task.episodeName`, `task.nextExecution`,
9098
+ * `task.failSafeExecution`, and `task.created`.
9099
+ *
9100
+ * @example
9101
+ * import { taskAdapter } from 'epicenter-libs';
9102
+ * const page = await taskAdapter.query({
9103
+ * filter: [
9104
+ * 'task.scopeKey=0000017dd3bf540e5ada5b1e058f08f20461', // tasks scoped to this group
9105
+ * 'task.status=INITIALIZED', // that have not yet fired
9106
+ * ],
9107
+ * sort: ['-task.created'], // newest first
9108
+ * max: 10, // page should only include the first 10 items
9109
+ * });
9110
+ *
9111
+ * @param searchOptions Search options for the query
9112
+ * @param [searchOptions.filter] Filters for searching
9113
+ * @param [searchOptions.sort] Sorting criteria
9114
+ * @param [searchOptions.first] The starting index of the page returned
9115
+ * @param [searchOptions.max] The number of entries per page
9116
+ * @param [optionals] Optional arguments; pass network call options overrides here.
9117
+ * @returns promise that resolves to a page of tasks
9118
+ */
9119
+ async function query$1(searchOptions, optionals = {}) {
9120
+ const {
9121
+ filter,
9122
+ sort = [],
9123
+ first,
9124
+ max
9125
+ } = searchOptions;
9126
+ const searchParams = {
9127
+ filter: parseFilterInput(filter),
9128
+ sort: sort.join(';') || undefined,
9129
+ first,
9130
+ max
9131
+ };
9132
+ return await new Router().withSearchParams(searchParams).get('/task/search', {
9133
+ paginated: true,
9134
+ ...optionals
9135
+ }).then(({
9048
9136
  body
9049
9137
  }) => body);
9050
9138
  }
@@ -9052,11 +9140,12 @@
9052
9140
  var task = /*#__PURE__*/Object.freeze({
9053
9141
  __proto__: null,
9054
9142
  RETRY_POLICY: RETRY_POLICY,
9055
- create: create$4,
9143
+ create: create$6,
9056
9144
  destroy: destroy,
9057
- get: get$4,
9145
+ get: get$5,
9058
9146
  getHistory: getHistory,
9059
- getTaskIn: getTaskIn
9147
+ getTaskIn: getTaskIn,
9148
+ query: query$1
9060
9149
  });
9061
9150
 
9062
9151
  /**
@@ -9108,7 +9197,7 @@
9108
9197
  * @param [optionals] Optional arguments; pass network call options overrides here.
9109
9198
  * @returns promise that resolves to the newly created chat
9110
9199
  */
9111
- async function create$3(room, scope, permit, optionals = {}) {
9200
+ async function create$5(room, scope, permit, optionals = {}) {
9112
9201
  return new Router().post('/chat', {
9113
9202
  body: {
9114
9203
  scope: {
@@ -9136,7 +9225,7 @@
9136
9225
  * @param [optionals] Optional arguments; pass network call options overrides here.
9137
9226
  * @returns promise that resolves to the chat
9138
9227
  */
9139
- async function get$3(chatKey, optionals = {}) {
9228
+ async function get$4(chatKey, optionals = {}) {
9140
9229
  return new Router().get(`/chat/${chatKey}`, optionals).then(({
9141
9230
  body
9142
9231
  }) => body);
@@ -9352,8 +9441,8 @@
9352
9441
 
9353
9442
  var chat = /*#__PURE__*/Object.freeze({
9354
9443
  __proto__: null,
9355
- create: create$3,
9356
- get: get$3,
9444
+ create: create$5,
9445
+ get: get$4,
9357
9446
  getMessages: getMessages,
9358
9447
  getMessagesAdmin: getMessagesAdmin,
9359
9448
  getMessagesForUser: getMessagesForUser,
@@ -9396,7 +9485,7 @@
9396
9485
  * @param [optionals.allowChannel] Opt into push notifications for this resource. Applicable to projects with phylogeny >= SILENT
9397
9486
  * @returns promise that resolves to the newly created consensus barrier
9398
9487
  */
9399
- async function create$2(worldKey, name, stage, expectedRoles, defaultActions, optionals = {}) {
9488
+ async function create$4(worldKey, name, stage, expectedRoles, defaultActions, optionals = {}) {
9400
9489
  const {
9401
9490
  ttlSeconds,
9402
9491
  transparent = false,
@@ -9450,7 +9539,7 @@
9450
9539
  * @param [optionals] Optional arguments; pass network call options overrides here.
9451
9540
  * @returns promise that resolves to a list of consensus barriers
9452
9541
  */
9453
- async function list(worldKey, name, optionals = {}) {
9542
+ async function list$1(worldKey, name, optionals = {}) {
9454
9543
  return await new Router().get(`/consensus/${worldKey}/${name}`, optionals).then(({
9455
9544
  body
9456
9545
  }) => body);
@@ -9843,11 +9932,11 @@
9843
9932
  var consensus = /*#__PURE__*/Object.freeze({
9844
9933
  __proto__: null,
9845
9934
  collectInGroup: collectInGroup,
9846
- create: create$2,
9935
+ create: create$4,
9847
9936
  deleteAll: deleteAll,
9848
9937
  deleteBarrier: deleteBarrier,
9849
9938
  forceClose: forceClose,
9850
- list: list,
9939
+ list: list$1,
9851
9940
  load: load,
9852
9941
  pause: pause,
9853
9942
  removeRoleExpectationFor: removeRoleExpectationFor,
@@ -9885,7 +9974,7 @@
9885
9974
  * @returns promise that resolves to the newly created somebody object
9886
9975
  */
9887
9976
 
9888
- async function create$1(email, scope, optionals = {}) {
9977
+ async function create$3(email, scope, optionals = {}) {
9889
9978
  const {
9890
9979
  givenName,
9891
9980
  familyName,
@@ -9918,7 +10007,7 @@
9918
10007
  * @returns promise that resolves to the somebody object, or undefined if not found
9919
10008
  */
9920
10009
  const NOT_FOUND$2 = 404;
9921
- async function get$2(somebodyKey, optionals = {}) {
10010
+ async function get$3(somebodyKey, optionals = {}) {
9922
10011
  return await new Router().get(`/somebody/${somebodyKey}`, optionals).catch(error => {
9923
10012
  if (error.status === NOT_FOUND$2) return {
9924
10013
  body: undefined
@@ -10013,8 +10102,8 @@
10013
10102
  var somebody = /*#__PURE__*/Object.freeze({
10014
10103
  __proto__: null,
10015
10104
  byEmail: byEmail,
10016
- create: create$1,
10017
- get: get$2,
10105
+ create: create$3,
10106
+ get: get$3,
10018
10107
  inScope: inScope
10019
10108
  });
10020
10109
 
@@ -10037,7 +10126,7 @@
10037
10126
  * @param [optionals] Optional arguments; pass network call options overrides here.
10038
10127
  * @returns promise that resolves to the matchmaker list object
10039
10128
  */
10040
- async function create(name, partners, scope, optionals = {}) {
10129
+ async function create$2(name, partners, scope, optionals = {}) {
10041
10130
  const {
10042
10131
  accountShortName,
10043
10132
  projectShortName,
@@ -10120,7 +10209,7 @@
10120
10209
  * @param [optionals] Optional arguments; pass network call options overrides here.
10121
10210
  * @returns promise that resolves to the matchmaker list object, or undefined if not found
10122
10211
  */
10123
- async function get$1(udomeKey, optionals = {}) {
10212
+ async function get$2(udomeKey, optionals = {}) {
10124
10213
  const {
10125
10214
  accountShortName,
10126
10215
  projectShortName,
@@ -10178,9 +10267,9 @@
10178
10267
  __proto__: null,
10179
10268
  addUser: addUser,
10180
10269
  byName: byName,
10181
- create: create,
10270
+ create: create$2,
10182
10271
  edit: edit,
10183
- get: get$1
10272
+ get: get$2
10184
10273
  });
10185
10274
 
10186
10275
  const sleep = ms => new Promise(r => setTimeout(r, ms));
@@ -10484,7 +10573,7 @@
10484
10573
  * @param [optionals] Optional arguments; pass network call options overrides here.
10485
10574
  * @returns promise that resolves to the wallet
10486
10575
  */
10487
- async function get(scope, optionals = {}) {
10576
+ async function get$1(scope, optionals = {}) {
10488
10577
  const {
10489
10578
  scopeBoundary,
10490
10579
  scopeKey
@@ -10551,88 +10640,999 @@
10551
10640
 
10552
10641
  var wallet = /*#__PURE__*/Object.freeze({
10553
10642
  __proto__: null,
10554
- get: get,
10643
+ get: get$1,
10555
10644
  update: update,
10556
10645
  withScope: withScope
10557
10646
  });
10558
10647
 
10559
- // Generic type for push channel message custom data
10648
+ /**
10649
+ * Builds the NPM Docker images used by pipeline NPM operations.
10650
+ * Requires `system` (admin) authorization.
10651
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/pipeline/npm/images`
10652
+ *
10653
+ * @example
10654
+ * import { pipelineAdapter } from 'epicenter-libs';
10655
+ * const built = await pipelineAdapter.buildImages();
10656
+ *
10657
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10658
+ * @returns promise that resolves to `true` when the images were built successfully
10659
+ */
10660
+ async function buildImages(optionals = {}) {
10661
+ return await new Router().get('/pipeline/npm/images', optionals).then(({
10662
+ body
10663
+ }) => body);
10664
+ }
10560
10665
 
10561
- // Base structure for channel push messages
10666
+ /**
10667
+ * Executes a stored pipeline configuration. The operations to run are read server-side from the
10668
+ * named config file; only step inputs (such as credentials) are supplied here via `attributes`.
10669
+ * The execution runs asynchronously — the returned audit record starts in its `RUNNING` state and
10670
+ * is updated by the worker on completion (poll `getExecution` to observe progress).
10671
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/pipeline/{configName}`
10672
+ *
10673
+ * @example
10674
+ * import { pipelineAdapter } from 'epicenter-libs';
10675
+ * // Pass the git credential the config's git step will consume, keyed by operation type
10676
+ * const audit = await pipelineAdapter.execute('deploy', { git: 'my-git-token' });
10677
+ *
10678
+ * @param configName Name of the stored pipeline config to execute
10679
+ * @param [attributes] Step inputs keyed by operation type (e.g. `{ git: '<token>' }`)
10680
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10681
+ * @returns promise that resolves to the newly created audit record in its initial RUNNING state
10682
+ */
10683
+ async function execute(configName, attributes = {}, optionals = {}) {
10684
+ return await new Router().post(`/pipeline/${encodeURIComponent(configName)}`, {
10685
+ body: {
10686
+ attributes
10687
+ },
10688
+ ...optionals
10689
+ }).then(({
10690
+ body
10691
+ }) => body);
10692
+ }
10562
10693
 
10563
- const validateScope = scope => {
10564
- if (!scope) throw new EpicenterError('No scope found where one was required');
10694
+ /**
10695
+ * Retrieves a single pipeline audit record by its execution key.
10696
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/pipeline/{executionKey}`
10697
+ *
10698
+ * @example
10699
+ * import { pipelineAdapter } from 'epicenter-libs';
10700
+ * const audit = await pipelineAdapter.getExecution('<executionKey>');
10701
+ *
10702
+ * @param executionKey Execution key of the audit record to retrieve
10703
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10704
+ * @returns promise that resolves to the audit record
10705
+ */
10706
+ async function getExecution(executionKey, optionals = {}) {
10707
+ return await new Router().get(`/pipeline/${encodeURIComponent(executionKey)}`, optionals).then(({
10708
+ body
10709
+ }) => body);
10710
+ }
10711
+
10712
+ /**
10713
+ * Lists the audit history for a stored pipeline config.
10714
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/pipeline/with/{configName}`
10715
+ *
10716
+ * @example
10717
+ * import { pipelineAdapter } from 'epicenter-libs';
10718
+ * const page = await pipelineAdapter.listAudits('deploy', { first: 0, max: 20 });
10719
+ *
10720
+ * @param configName Name of the stored pipeline config
10721
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
10722
+ * @param [optionals.first] Index of the first record to return (for pagination)
10723
+ * @param [optionals.max] Maximum number of records to return (for pagination)
10724
+ * @returns promise that resolves to a page of audit records
10725
+ */
10726
+ async function listAudits(configName, optionals = {}) {
10565
10727
  const {
10566
- scopeBoundary,
10567
- scopeKey,
10568
- pushCategory
10569
- } = scope;
10570
- if (!scopeBoundary) throw new EpicenterError('Missing scope component: scopeBoundary');
10571
- if (!scopeKey) throw new EpicenterError('Missing scope component: scopeKey');
10572
- if (!pushCategory) throw new EpicenterError('Missing scope component: pushCategory');
10573
- if (!Object.prototype.hasOwnProperty.call(SCOPE_BOUNDARY, scopeBoundary)) throw new EpicenterError(`Invalid scope boundary: ${scopeBoundary}`);
10574
- if (!Object.prototype.hasOwnProperty.call(PUSH_CATEGORY, pushCategory)) throw new EpicenterError(`Invalid push category: ${pushCategory}`);
10575
- };
10728
+ first = 0,
10729
+ max,
10730
+ ...routingOptions
10731
+ } = optionals;
10732
+ return await new Router().withSearchParams({
10733
+ first,
10734
+ max
10735
+ }).get(`/pipeline/with/${encodeURIComponent(configName)}`, {
10736
+ paginated: true,
10737
+ ...routingOptions
10738
+ }).then(({
10739
+ body
10740
+ }) => body);
10741
+ }
10576
10742
 
10577
10743
  /**
10578
- * Used to subscribe to CometD channels. Pass in a channel scope to instantiate, if a subscription to that scope already exists it will use it.
10744
+ * Deletes a pipeline audit record by its execution key.
10745
+ * Requires `system` (admin) authorization.
10746
+ * Base URL: DELETE `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/pipeline/{executionKey}`
10579
10747
  *
10580
10748
  * @example
10581
- * import { Channel, authAdapter, SCOPE_BOUNDARY, PUSH_CATEGORY } from 'epicenter-libs';
10582
- * const session = authAdapter.getLocalSession();
10583
- * const channel = new Channel({
10584
- * scopeBoundary: SCOPE_BOUNDARY.GROUP,
10585
- * scopeKey: session.groupKey,
10586
- * pushCategory: PUSH_CATEGORY.CHAT,
10587
- * });
10588
- * await channel.subscribe((data) => {
10589
- * console.log('Received message:', data);
10590
- * });
10749
+ * import { pipelineAdapter } from 'epicenter-libs';
10750
+ * await pipelineAdapter.deleteAudit('<executionKey>');
10751
+ *
10752
+ * @param executionKey Execution key of the audit record to delete
10753
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10754
+ * @returns promise that resolves to `true` when the audit record was deleted
10591
10755
  */
10592
- class Channel {
10593
- /**
10594
- * Channel constructor
10595
- *
10596
- * @param scope Object with the scope boundary, scope key, and push category; defines the namespace for the channel
10597
- * @param scope.scopeBoundary Scope boundary, defines the type of scope; See [scope boundary](#SCOPE_BOUNDARY) for all types
10598
- * @param scope.scopeKey Scope key, a unique identifier tied to the scope. E.g., if your `scopeBoundary` is `GROUP`, your `scopeKey` will be your `groupKey`; for `EPISODE`, `episodeKey`, etc.
10599
- * @param scope.pushCategory Push category, defines the type of channel; See [push category](#PUSH_CATEGORY) for all types
10600
- */
10601
- constructor(scope) {
10602
- _defineProperty(this, "path", void 0);
10603
- _defineProperty(this, "update", void 0);
10604
- _defineProperty(this, "subscription", null);
10605
- const {
10606
- scopeBoundary,
10607
- scopeKey,
10608
- pushCategory
10609
- } = scope;
10610
- validateScope(scope);
10611
- this.path = `/${scopeBoundary.toLowerCase()}/${scopeKey}/${pushCategory.toLowerCase()}`;
10612
- if (cometdAdapter.subscriptions.has(this.path)) {
10613
- this.subscription = cometdAdapter.subscriptions.get(this.path) || null;
10614
- }
10615
- }
10756
+ async function deleteAudit(executionKey, optionals = {}) {
10757
+ return await new Router().delete(`/pipeline/${encodeURIComponent(executionKey)}`, optionals).then(({
10758
+ body
10759
+ }) => body);
10760
+ }
10616
10761
 
10617
- /**
10618
- * Publishes content to the CometD channel
10619
- *
10620
- * @example
10621
- * import { Channel, authAdapter, SCOPE_BOUNDARY, PUSH_CATEGORY } from 'epicenter-libs';
10622
- * const session = authAdapter.getLocalSession();
10623
- * const channel = new Channel({
10624
- * scopeBoundary: SCOPE_BOUNDARY.GROUP,
10625
- * scopeKey: session.groupKey,
10626
- * pushCategory: PUSH_CATEGORY.CHAT,
10627
- * });
10628
- * await channel.publish({ message: 'Hello!' });
10629
- *
10630
- * @param content Content to publish to the channel
10631
- * @returns promise that resolves to the CometD message response
10632
- */
10633
- publish(content) {
10634
- return cometdAdapter.publish(this, content);
10635
- }
10762
+ var pipeline = /*#__PURE__*/Object.freeze({
10763
+ __proto__: null,
10764
+ buildImages: buildImages,
10765
+ deleteAudit: deleteAudit,
10766
+ execute: execute,
10767
+ getExecution: getExecution,
10768
+ listAudits: listAudits
10769
+ });
10770
+
10771
+ /**
10772
+ * Lists the known API services available for the given encyclopedia version.
10773
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/encyclopedia/v{version}`
10774
+ *
10775
+ * @example
10776
+ * import { encyclopediaAdapter } from 'epicenter-libs';
10777
+ * const services = await encyclopediaAdapter.listServices(3);
10778
+ *
10779
+ * @param version Encyclopedia version number
10780
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10781
+ * @returns promise that resolves to an array of known service descriptors
10782
+ */
10783
+ async function listServices(version, optionals = {}) {
10784
+ return await new Router().get(`/encyclopedia/v${version}`, optionals).then(({
10785
+ body
10786
+ }) => body);
10787
+ }
10788
+
10789
+ /**
10790
+ * Retrieves the documented resource (API documentation) for a specific service and encyclopedia version.
10791
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/encyclopedia/v{version}/{api}`
10792
+ *
10793
+ * @example
10794
+ * import { encyclopediaAdapter } from 'epicenter-libs';
10795
+ * const resource = await encyclopediaAdapter.getResource(3, 'run');
10796
+ *
10797
+ * @param version Encyclopedia version number
10798
+ * @param api Name of the API service to retrieve documentation for
10799
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10800
+ * @returns promise that resolves to the documented resource containing endpoints and definitions
10801
+ */
10802
+ async function getResource(version, api, optionals = {}) {
10803
+ return await new Router().get(`/encyclopedia/v${version}/${api}`, optionals).then(({
10804
+ body
10805
+ }) => body);
10806
+ }
10807
+
10808
+ /**
10809
+ * Retrieves a translated representation of the API documentation for a specific service and encyclopedia version.
10810
+ * Supported translators are ASCIIDOC, ASCIIDOC_TO_HTML, and OPENAPI.
10811
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/encyclopedia/as/{translator}/v{version}/{api}`
10812
+ *
10813
+ * NOTE: The backend returns the translated content with a translator-specific content-type
10814
+ * (e.g. `text/asciidoc`, `text/html`, `application/json`). The shared Router throws when the
10815
+ * response content-type is not `application/json`, so only the OPENAPI translator works here.
10816
+ * For ASCIIDOC and ASCIIDOC_TO_HTML, use the underlying fetch API directly against the
10817
+ * constructed URL.
10818
+ *
10819
+ * @example
10820
+ * import { encyclopediaAdapter } from 'epicenter-libs';
10821
+ * const openApiDoc = await encyclopediaAdapter.translate('OPENAPI', 3, 'run');
10822
+ *
10823
+ * @param translator Output format for the documentation; one of 'ASCIIDOC', 'ASCIIDOC_TO_HTML', or 'OPENAPI'
10824
+ * @param version Encyclopedia version number
10825
+ * @param api Name of the API service to translate documentation for
10826
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10827
+ * @returns promise that resolves to the translated documentation (only when translator is 'OPENAPI')
10828
+ */
10829
+ async function translate(translator, version, api, optionals = {}) {
10830
+ return await new Router().get(`/encyclopedia/as/${translator}/v${version}/${api}`, optionals).then(({
10831
+ body
10832
+ }) => body);
10833
+ }
10834
+
10835
+ var encyclopedia = /*#__PURE__*/Object.freeze({
10836
+ __proto__: null,
10837
+ getResource: getResource,
10838
+ listServices: listServices,
10839
+ translate: translate
10840
+ });
10841
+
10842
+ /* File paths are free-form, user-authored strings that may contain spaces or URL-reserved
10843
+ * characters. Encode each segment while preserving the '/' separators that the backend's
10844
+ * `{filePath:.*}` routes expect. */
10845
+ const encodePath = filePath => filePath.split('/').map(encodeURIComponent).join('/');
10846
+
10847
+ /**
10848
+ * Lists files and directories at the project root or at a specific path.
10849
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file[/{filePath}]`
10850
+ *
10851
+ * @example
10852
+ * import { fileAdapter } from 'epicenter-libs';
10853
+ * // List all files at root
10854
+ * const entries = await fileAdapter.list();
10855
+ * // List contents of a specific directory up to 2 levels deep
10856
+ * const entries = await fileAdapter.list('src', { depth: 2 });
10857
+ *
10858
+ * @param [filePath] Path to a file or directory; omit to list the project root
10859
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
10860
+ * @param [optionals.depth] Maximum depth of directory traversal to include in the response
10861
+ * @returns promise that resolves to an array of file and directory entries
10862
+ */
10863
+ async function list(filePath, optionals = {}) {
10864
+ const {
10865
+ depth,
10866
+ ...routingOptions
10867
+ } = optionals;
10868
+ const uriComponent = filePath ? `/${encodePath(filePath)}` : '';
10869
+ return await new Router().withSearchParams({
10870
+ depth
10871
+ }).get(`/file${uriComponent}`, routingOptions).then(({
10872
+ body
10873
+ }) => body);
10874
+ }
10875
+
10876
+ /**
10877
+ * Uploads and replaces files at the project root or at a specific path using multipart/form-data (PUT).
10878
+ * Use this when you want to overwrite existing files. For creating new files, use `create`.
10879
+ * Base URL: PUT `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file[/{filePath}]`
10880
+ *
10881
+ * NOTE: This is browser-only. The `FormData` body is only serialized as multipart/form-data when
10882
+ * running in a browser environment; in Node it will not be sent correctly.
10883
+ *
10884
+ * @example
10885
+ * import { fileAdapter } from 'epicenter-libs';
10886
+ * const formData = new FormData();
10887
+ * formData.append('file', myFile);
10888
+ * const uploaded = await fileAdapter.upload(formData, 'models/model.py');
10889
+ *
10890
+ * @param formData Multipart form data containing the file(s) to upload
10891
+ * @param [filePath] Destination path for the file(s); omit to upload to the project root
10892
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10893
+ * @returns promise that resolves to an array of the uploaded file entries
10894
+ */
10895
+ async function upload(formData, filePath, optionals = {}) {
10896
+ const uriComponent = filePath ? `/${encodePath(filePath)}` : '';
10897
+ return await new Router().put(`/file${uriComponent}`, {
10898
+ body: formData,
10899
+ ...optionals
10900
+ }).then(({
10901
+ body
10902
+ }) => body);
10903
+ }
10904
+
10905
+ /**
10906
+ * Creates new files at the project root or at a specific path using multipart/form-data (POST).
10907
+ * Use this when creating new files. For overwriting existing files, use `upload`.
10908
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file[/{filePath}]`
10909
+ *
10910
+ * NOTE: This is browser-only. The `FormData` body is only serialized as multipart/form-data when
10911
+ * running in a browser environment; in Node it will not be sent correctly.
10912
+ *
10913
+ * @example
10914
+ * import { fileAdapter } from 'epicenter-libs';
10915
+ * const formData = new FormData();
10916
+ * formData.append('file', myFile);
10917
+ * const created = await fileAdapter.create(formData, 'models/model.py');
10918
+ *
10919
+ * @param formData Multipart form data containing the file(s) to create
10920
+ * @param [filePath] Destination path for the file(s); omit to create at the project root
10921
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10922
+ * @returns promise that resolves to an array of the created file entries
10923
+ */
10924
+ async function create$1(formData, filePath, optionals = {}) {
10925
+ const uriComponent = filePath ? `/${encodePath(filePath)}` : '';
10926
+ return await new Router().post(`/file${uriComponent}`, {
10927
+ body: formData,
10928
+ ...optionals
10929
+ }).then(({
10930
+ body
10931
+ }) => body);
10932
+ }
10933
+
10934
+ /**
10935
+ * Deletes a file or directory at the project root or at a specific path.
10936
+ * Base URL: DELETE `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file[/{filePath}]`
10937
+ *
10938
+ * @example
10939
+ * import { fileAdapter } from 'epicenter-libs';
10940
+ * // Delete a specific file
10941
+ * await fileAdapter.remove('models/old-model.py');
10942
+ * // Delete all files at the project root
10943
+ * await fileAdapter.remove();
10944
+ *
10945
+ * @param [filePath] Path of the file or directory to delete; omit to delete all files at the project root
10946
+ * @param [optionals] Optional arguments; pass network call options overrides here.
10947
+ * @returns promise that resolves when the deletion is complete
10948
+ */
10949
+ async function remove(filePath, optionals = {}) {
10950
+ const uriComponent = filePath ? `/${encodePath(filePath)}` : '';
10951
+ return await new Router().delete(`/file${uriComponent}`, optionals).then(({
10952
+ body
10953
+ }) => body);
10954
+ }
10955
+
10956
+ /**
10957
+ * Downloads the raw content of a file at the specified path.
10958
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file/download/{filePath}`
10959
+ *
10960
+ * NOTE: The backend streams the file with its detected content type (e.g. `application/zip`,
10961
+ * `text/plain`, `application/octet-stream`). The shared Router throws when the response
10962
+ * content-type is not `application/json`, so this call only succeeds for JSON files. To download
10963
+ * other file types, use the underlying fetch API directly against the constructed URL.
10964
+ *
10965
+ * @example
10966
+ * import { fileAdapter } from 'epicenter-libs';
10967
+ * const content = await fileAdapter.download('config.json');
10968
+ *
10969
+ * @param filePath Path to the file to download
10970
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
10971
+ * @param [optionals.depth] Currently unused on the backend; reserved for future expansion.
10972
+ * @returns promise that resolves to the raw file content
10973
+ */
10974
+ async function download(filePath, optionals = {}) {
10975
+ const {
10976
+ depth,
10977
+ ...routingOptions
10978
+ } = optionals;
10979
+ return await new Router().withSearchParams({
10980
+ depth
10981
+ }).get(`/file/download/${encodePath(filePath)}`, routingOptions).then(({
10982
+ body
10983
+ }) => body);
10984
+ }
10985
+
10986
+ /**
10987
+ * Lists files and directories matching a glob filter pattern, optionally scoped to a specific path.
10988
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file/filter/{filter}[/{filePath}]`
10989
+ *
10990
+ * @example
10991
+ * import { fileAdapter } from 'epicenter-libs';
10992
+ * // List all Python files in the project
10993
+ * const pyFiles = await fileAdapter.listByFilter('*.py');
10994
+ * // List all Python files within the 'models' directory
10995
+ * const pyFiles = await fileAdapter.listByFilter('*.py', 'models');
10996
+ *
10997
+ * @param filter Glob pattern to filter files by (e.g., '*.py', '*.json')
10998
+ * @param [filePath] Directory path to scope the filter to; omit to search the entire project
10999
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
11000
+ * @param [optionals.depth] Maximum depth of directory traversal to include in the response
11001
+ * @returns promise that resolves to an array of matching file and directory entries
11002
+ */
11003
+ async function listByFilter(filter, filePath, optionals = {}) {
11004
+ const {
11005
+ depth,
11006
+ ...routingOptions
11007
+ } = optionals;
11008
+ const uriComponent = filePath ? `/${encodePath(filePath)}` : '';
11009
+ return await new Router().withSearchParams({
11010
+ depth
11011
+ }).get(`/file/filter/${encodeURIComponent(filter)}${uriComponent}`, routingOptions).then(({
11012
+ body
11013
+ }) => body);
11014
+ }
11015
+
11016
+ /**
11017
+ * Compresses files into a ZIP archive at the project root or at a specific path.
11018
+ * Base URL: PATCH `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file/compress[/{filePath}]`
11019
+ *
11020
+ * NOTE: The backend streams the resulting archive with content-type `application/zip`. The
11021
+ * shared Router throws when the response content-type is not `application/json`, so this call
11022
+ * will not return the archive bytes through the normal flow. To retrieve the archive, use the
11023
+ * underlying fetch API directly against the constructed URL.
11024
+ *
11025
+ * @example
11026
+ * import { fileAdapter } from 'epicenter-libs';
11027
+ * // Compress a specific file or directory
11028
+ * await fileAdapter.compress('models');
11029
+ * // Compress at root
11030
+ * await fileAdapter.compress();
11031
+ *
11032
+ * @param [filePath] Path of the file or directory to compress; omit to compress at the project root
11033
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11034
+ * @returns promise that resolves to the compression result
11035
+ */
11036
+ async function compress(filePath, optionals = {}) {
11037
+ const uriComponent = filePath ? `/${encodePath(filePath)}` : '';
11038
+ return await new Router().patch(`/file/compress${uriComponent}`, optionals).then(({
11039
+ body
11040
+ }) => body);
11041
+ }
11042
+
11043
+ /**
11044
+ * Extracts (explodes) a ZIP archive at the project root or at a specific path in place,
11045
+ * deleting the archive after extraction.
11046
+ * Base URL: PATCH `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file/explode[/{filePath}]`
11047
+ *
11048
+ * @example
11049
+ * import { fileAdapter } from 'epicenter-libs';
11050
+ * // Extract a specific archive
11051
+ * await fileAdapter.explode('archive.zip');
11052
+ * // Explode at root
11053
+ * await fileAdapter.explode();
11054
+ *
11055
+ * @param [filePath] Path of the archive to extract; omit to extract at the project root
11056
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11057
+ * @returns promise that resolves when the extraction is complete
11058
+ */
11059
+ async function explode(filePath, optionals = {}) {
11060
+ const uriComponent = filePath ? `/${encodePath(filePath)}` : '';
11061
+ return await new Router().patch(`/file/explode${uriComponent}`, optionals).then(({
11062
+ body
11063
+ }) => body);
11064
+ }
11065
+
11066
+ /**
11067
+ * Moves a file or directory from one path to another within the project.
11068
+ * Base URL: PATCH `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file/move`
11069
+ *
11070
+ * @example
11071
+ * import { fileAdapter } from 'epicenter-libs';
11072
+ * await fileAdapter.move('models/old-name.py', 'models/new-name.py');
11073
+ * // Move and include the origin directory itself
11074
+ * await fileAdapter.move('old-dir', 'new-dir', { includeOrigin: true });
11075
+ *
11076
+ * @param origin Origin path of the file or directory to move
11077
+ * @param destination Destination path to move the file or directory to
11078
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
11079
+ * @param [optionals.includeOrigin] Whether to include the origin directory itself in the move
11080
+ * @returns promise that resolves when the move is complete
11081
+ */
11082
+ async function move(origin, destination, optionals = {}) {
11083
+ const {
11084
+ includeOrigin,
11085
+ ...routingOptions
11086
+ } = optionals;
11087
+ return await new Router().patch('/file/move', {
11088
+ body: {
11089
+ origin,
11090
+ destination,
11091
+ includeOrigin
11092
+ },
11093
+ ...routingOptions
11094
+ }).then(({
11095
+ body
11096
+ }) => body);
11097
+ }
11098
+
11099
+ /**
11100
+ * Creates a new directory at the specified path.
11101
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/file/directory/{filePath}`
11102
+ *
11103
+ * @example
11104
+ * import { fileAdapter } from 'epicenter-libs';
11105
+ * const dir = await fileAdapter.createDirectory('models/new-folder');
11106
+ *
11107
+ * @param filePath Path at which to create the new directory
11108
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11109
+ * @returns promise that resolves to the created directory entry
11110
+ */
11111
+ async function createDirectory(filePath, optionals = {}) {
11112
+ return await new Router().post(`/file/directory/${encodePath(filePath)}`, optionals).then(({
11113
+ body
11114
+ }) => body);
11115
+ }
11116
+
11117
+ var file = /*#__PURE__*/Object.freeze({
11118
+ __proto__: null,
11119
+ compress: compress,
11120
+ create: create$1,
11121
+ createDirectory: createDirectory,
11122
+ download: download,
11123
+ explode: explode,
11124
+ list: list,
11125
+ listByFilter: listByFilter,
11126
+ move: move,
11127
+ remove: remove,
11128
+ upload: upload
11129
+ });
11130
+
11131
+ /**
11132
+ * Currently the API only supports `SAML`. This type is intentionally narrow so that adding new
11133
+ * protocols on the backend requires an explicit type update here.
11134
+ */
11135
+
11136
+ /**
11137
+ * Gets registration info for a self-registration token.
11138
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/self/{token}`
11139
+ *
11140
+ * @example
11141
+ * import { registrationAdapter } from 'epicenter-libs';
11142
+ * const info = await registrationAdapter.getSelfRegistrationInfo('my-token');
11143
+ *
11144
+ * @param token Self-registration token
11145
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11146
+ * @returns promise that resolves to registration info
11147
+ */
11148
+ async function getSelfRegistrationInfo(token, optionals = {}) {
11149
+ return await new Router().get(`/registration/self/${token}`, optionals).then(({
11150
+ body
11151
+ }) => body);
11152
+ }
11153
+
11154
+ /**
11155
+ * Completes a self-registration using a token.
11156
+ * Base URL: PATCH `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/self/{token}`
11157
+ *
11158
+ * @example
11159
+ * import { registrationAdapter } from 'epicenter-libs';
11160
+ * const result = await registrationAdapter.completeSelfRegistration('my-token', 'secret123', {
11161
+ * displayName: 'John Doe',
11162
+ * handle: 'johnd',
11163
+ * });
11164
+ *
11165
+ * @param token Self-registration token
11166
+ * @param password Password for the new account
11167
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11168
+ * @param [optionals.displayName] Display name for the new user
11169
+ * @param [optionals.givenName] Given name for the new user
11170
+ * @param [optionals.familyName] Family name for the new user
11171
+ * @param [optionals.handle] Handle for the new user
11172
+ * @returns promise that resolves to the registration result including session info
11173
+ */
11174
+ async function completeSelfRegistration(token, password, optionals = {}) {
11175
+ const {
11176
+ displayName,
11177
+ givenName,
11178
+ familyName,
11179
+ handle,
11180
+ ...routingOptions
11181
+ } = optionals;
11182
+ return await new Router().patch(`/registration/self/${token}`, {
11183
+ body: {
11184
+ password,
11185
+ displayName,
11186
+ givenName,
11187
+ familyName,
11188
+ handle
11189
+ },
11190
+ ...routingOptions
11191
+ }).then(({
11192
+ body
11193
+ }) => body);
11194
+ }
11195
+
11196
+ /**
11197
+ * Sends a self-registration invite email to a user. Pass an `Accept-Language` header via
11198
+ * `optionals.headers` to localize the email.
11199
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/self/{groupKey}`
11200
+ *
11201
+ * @example
11202
+ * import { registrationAdapter } from 'epicenter-libs';
11203
+ * await registrationAdapter.sendSelfRegistrationInvite('group-key', 'user@example.com', {
11204
+ * linkDestination: 'DASHBOARD',
11205
+ * redirectUrl: 'https://app.example.com',
11206
+ * headers: { 'Accept-Language': 'fr-FR' },
11207
+ * });
11208
+ *
11209
+ * @param groupKey Group key to register the user into
11210
+ * @param email Email address of the user to invite
11211
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11212
+ * @param [optionals.linkDestination] Destination for the registration link ('DASHBOARD' or 'MANAGER')
11213
+ * @param [optionals.modality] Registration modality
11214
+ * @param [optionals.redirectUrl] URL to redirect to after registration
11215
+ * @param [optionals.subject] Subject line for the invite email
11216
+ * @param [optionals.givenName] Pre-populate given name in the registration form
11217
+ * @param [optionals.familyName] Pre-populate family name in the registration form
11218
+ * @param [optionals.linkUrl] Custom URL to use for the registration link
11219
+ * @param [optionals.confirmation] Whether to send a confirmation email
11220
+ * @returns promise that resolves to undefined if successful
11221
+ */
11222
+ async function sendSelfRegistrationInvite(groupKey, email, optionals = {}) {
11223
+ const {
11224
+ linkDestination,
11225
+ modality,
11226
+ redirectUrl,
11227
+ subject,
11228
+ givenName,
11229
+ familyName,
11230
+ linkUrl,
11231
+ confirmation,
11232
+ ...routingOptions
11233
+ } = optionals;
11234
+ return await new Router().post(`/registration/self/${groupKey}`, {
11235
+ body: {
11236
+ email,
11237
+ linkDestination,
11238
+ modality,
11239
+ redirectUrl,
11240
+ subject,
11241
+ givenName,
11242
+ familyName,
11243
+ linkUrl,
11244
+ confirmation
11245
+ },
11246
+ ...routingOptions
11247
+ }).then(({
11248
+ body
11249
+ }) => body);
11250
+ }
11251
+
11252
+ /**
11253
+ * Gets registration info for an invite token.
11254
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/invite/{token}`
11255
+ *
11256
+ * @example
11257
+ * import { registrationAdapter } from 'epicenter-libs';
11258
+ * const info = await registrationAdapter.getInviteRegistrationInfo('invite-token');
11259
+ *
11260
+ * @param token Invite registration token
11261
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11262
+ * @returns promise that resolves to registration info
11263
+ */
11264
+ async function getInviteRegistrationInfo(token, optionals = {}) {
11265
+ return await new Router().get(`/registration/invite/${token}`, optionals).then(({
11266
+ body
11267
+ }) => body);
11268
+ }
11269
+
11270
+ /**
11271
+ * Completes an invite registration using a token.
11272
+ * Base URL: PATCH `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/invite/{token}`
11273
+ *
11274
+ * @example
11275
+ * import { registrationAdapter } from 'epicenter-libs';
11276
+ * const result = await registrationAdapter.completeInviteRegistration('invite-token', 'pass456', {
11277
+ * displayName: 'Jane Doe',
11278
+ * });
11279
+ *
11280
+ * @param token Invite registration token
11281
+ * @param password Password for the new account
11282
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11283
+ * @param [optionals.displayName] Display name for the new user
11284
+ * @param [optionals.givenName] Given name for the new user
11285
+ * @param [optionals.familyName] Family name for the new user
11286
+ * @param [optionals.handle] Handle for the new user
11287
+ * @returns promise that resolves to the registration result including session info
11288
+ */
11289
+ async function completeInviteRegistration(token, password, optionals = {}) {
11290
+ const {
11291
+ displayName,
11292
+ givenName,
11293
+ familyName,
11294
+ handle,
11295
+ ...routingOptions
11296
+ } = optionals;
11297
+ return await new Router().patch(`/registration/invite/${token}`, {
11298
+ body: {
11299
+ password,
11300
+ displayName,
11301
+ givenName,
11302
+ familyName,
11303
+ handle
11304
+ },
11305
+ ...routingOptions
11306
+ }).then(({
11307
+ body
11308
+ }) => body);
11309
+ }
11310
+
11311
+ /**
11312
+ * Sends an invite registration email to a user. Pass an `Accept-Language` header via
11313
+ * `optionals.headers` to localize the email.
11314
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/invite/{groupKey}`
11315
+ *
11316
+ * @example
11317
+ * import { registrationAdapter } from 'epicenter-libs';
11318
+ * await registrationAdapter.sendInvite('group-key', 'invited@example.com', {
11319
+ * givenName: 'New',
11320
+ * familyName: 'User',
11321
+ * redirectUrl: 'https://app.example.com',
11322
+ * });
11323
+ *
11324
+ * @param groupKey Group key to invite the user into
11325
+ * @param email Email address of the user to invite
11326
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11327
+ * @param [optionals.linkDestination] Destination for the registration link ('DASHBOARD' or 'MANAGER')
11328
+ * @param [optionals.modality] Registration modality
11329
+ * @param [optionals.redirectUrl] URL to redirect to after registration
11330
+ * @param [optionals.subject] Subject line for the invite email
11331
+ * @param [optionals.givenName] Pre-populate given name in the registration form
11332
+ * @param [optionals.familyName] Pre-populate family name in the registration form
11333
+ * @param [optionals.linkUrl] Custom URL to use for the registration link
11334
+ * @param [optionals.confirmation] Whether to send a confirmation email
11335
+ * @returns promise that resolves to undefined if successful
11336
+ */
11337
+ async function sendInvite(groupKey, email, optionals = {}) {
11338
+ const {
11339
+ linkDestination,
11340
+ modality,
11341
+ redirectUrl,
11342
+ subject,
11343
+ givenName,
11344
+ familyName,
11345
+ linkUrl,
11346
+ confirmation,
11347
+ ...routingOptions
11348
+ } = optionals;
11349
+ return await new Router().post(`/registration/invite/${groupKey}`, {
11350
+ body: {
11351
+ email,
11352
+ linkDestination,
11353
+ modality,
11354
+ redirectUrl,
11355
+ subject,
11356
+ givenName,
11357
+ familyName,
11358
+ linkUrl,
11359
+ confirmation
11360
+ },
11361
+ ...routingOptions
11362
+ }).then(({
11363
+ body
11364
+ }) => body);
11365
+ }
11366
+
11367
+ /**
11368
+ * Gets registration info for a team invite token.
11369
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/team/{token}`
11370
+ *
11371
+ * @example
11372
+ * import { registrationAdapter } from 'epicenter-libs';
11373
+ * const info = await registrationAdapter.getTeamRegistrationInfo('team-token');
11374
+ *
11375
+ * @param token Team invite token
11376
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11377
+ * @returns promise that resolves to team registration info
11378
+ */
11379
+ async function getTeamRegistrationInfo(token, optionals = {}) {
11380
+ return await new Router().get(`/registration/team/${token}`, optionals).then(({
11381
+ body
11382
+ }) => body);
11383
+ }
11384
+
11385
+ /**
11386
+ * Sends a team invite email. Pass an `Accept-Language` header via `optionals.headers` to
11387
+ * localize the email.
11388
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/team`
11389
+ *
11390
+ * @example
11391
+ * import { registrationAdapter } from 'epicenter-libs';
11392
+ * await registrationAdapter.sendTeamInvite(
11393
+ * 'Jane Author',
11394
+ * 'AUTHOR',
11395
+ * 'https://app.example.com',
11396
+ * 'newteammate@example.com',
11397
+ * { subject: 'Welcome to the team!' },
11398
+ * );
11399
+ *
11400
+ * @param invitingAuthor Name or identifier of the person sending the invite
11401
+ * @param role Role to assign to the invited user
11402
+ * @param redirectUrl URL to redirect to after accepting the invite
11403
+ * @param email Email address of the user to invite
11404
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11405
+ * @param [optionals.subject] Subject line for the invite email
11406
+ * @param [optionals.givenName] Pre-populate given name for the invited user
11407
+ * @param [optionals.familyName] Pre-populate family name for the invited user
11408
+ * @returns promise that resolves to undefined if successful
11409
+ */
11410
+ async function sendTeamInvite(invitingAuthor, role, redirectUrl, email, optionals = {}) {
11411
+ const {
11412
+ subject,
11413
+ givenName,
11414
+ familyName,
11415
+ ...routingOptions
11416
+ } = optionals;
11417
+ return await new Router().post('/registration/team', {
11418
+ body: {
11419
+ invitingAuthor,
11420
+ role,
11421
+ redirectUrl,
11422
+ email,
11423
+ subject,
11424
+ givenName,
11425
+ familyName
11426
+ },
11427
+ ...routingOptions
11428
+ }).then(({
11429
+ body
11430
+ }) => body);
11431
+ }
11432
+
11433
+ /**
11434
+ * @deprecated Use getSsoAdminRegistration or getSsoUserRegistration instead.
11435
+ * Gets SSO registration info for a given SSO protocol.
11436
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/sso/{ssoProtocol}`
11437
+ *
11438
+ * @example
11439
+ * import { registrationAdapter } from 'epicenter-libs';
11440
+ * const info = await registrationAdapter.getSsoRegistration('SAML');
11441
+ *
11442
+ * @param ssoProtocol The SSO protocol (e.g. 'SAML')
11443
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11444
+ * @returns promise that resolves to SSO registration data
11445
+ */
11446
+ async function getSsoRegistration(ssoProtocol, optionals = {}) {
11447
+ console.warn('DEPRECATION WARNING: registrationAdapter.getSsoRegistration is deprecated and will be removed with the next release. Use registrationAdapter.getSsoAdminRegistration or registrationAdapter.getSsoUserRegistration instead.');
11448
+ return await new Router().get(`/registration/sso/${ssoProtocol}`, optionals).then(({
11449
+ body
11450
+ }) => body);
11451
+ }
11452
+
11453
+ /**
11454
+ * Gets admin SSO registration info for a given SSO protocol.
11455
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/sso/admin/{ssoProtocol}`
11456
+ *
11457
+ * @example
11458
+ * import { registrationAdapter } from 'epicenter-libs';
11459
+ * const info = await registrationAdapter.getSsoAdminRegistration('SAML');
11460
+ *
11461
+ * @param ssoProtocol The SSO protocol (e.g. 'SAML')
11462
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11463
+ * @returns promise that resolves to SSO admin registration data
11464
+ */
11465
+ async function getSsoAdminRegistration(ssoProtocol, optionals = {}) {
11466
+ return await new Router().get(`/registration/sso/admin/${ssoProtocol}`, optionals).then(({
11467
+ body
11468
+ }) => body);
11469
+ }
11470
+
11471
+ /**
11472
+ * Gets user SSO registration info for a given SSO protocol.
11473
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/registration/sso/user/{ssoProtocol}`
11474
+ *
11475
+ * @example
11476
+ * import { registrationAdapter } from 'epicenter-libs';
11477
+ * const info = await registrationAdapter.getSsoUserRegistration('SAML');
11478
+ *
11479
+ * @param ssoProtocol The SSO protocol (e.g. 'SAML')
11480
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11481
+ * @returns promise that resolves to SSO user registration data
11482
+ */
11483
+ async function getSsoUserRegistration(ssoProtocol, optionals = {}) {
11484
+ return await new Router().get(`/registration/sso/user/${ssoProtocol}`, optionals).then(({
11485
+ body
11486
+ }) => body);
11487
+ }
11488
+
11489
+ var registration = /*#__PURE__*/Object.freeze({
11490
+ __proto__: null,
11491
+ completeInviteRegistration: completeInviteRegistration,
11492
+ completeSelfRegistration: completeSelfRegistration,
11493
+ getInviteRegistrationInfo: getInviteRegistrationInfo,
11494
+ getSelfRegistrationInfo: getSelfRegistrationInfo,
11495
+ getSsoAdminRegistration: getSsoAdminRegistration,
11496
+ getSsoRegistration: getSsoRegistration,
11497
+ getSsoUserRegistration: getSsoUserRegistration,
11498
+ getTeamRegistrationInfo: getTeamRegistrationInfo,
11499
+ sendInvite: sendInvite,
11500
+ sendSelfRegistrationInvite: sendSelfRegistrationInvite,
11501
+ sendTeamInvite: sendTeamInvite
11502
+ });
11503
+
11504
+ /**
11505
+ * Creates a new docket entry, scheduling a deferred operation for later execution.
11506
+ * Requires `support` level authorization.
11507
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/docket`
11508
+ *
11509
+ * @example
11510
+ * import { docketAdapter } from 'epicenter-libs';
11511
+ * const docket = await docketAdapter.create(
11512
+ * {
11513
+ * objectType: 'scale',
11514
+ * operatingSystem: 'LINUX',
11515
+ * workerShape: 'GS',
11516
+ * scale: {
11517
+ * active: true,
11518
+ * initialWorkerCount: 1,
11519
+ * additionalWorkerLimit: 4,
11520
+ * flavors: ['DOCKER'],
11521
+ * },
11522
+ * },
11523
+ * { objectType: 'date', value: '2026-06-01T00:00:00Z' },
11524
+ * '2026-05-20T00:00:00Z',
11525
+ * { ttlMinutes: 60 },
11526
+ * );
11527
+ *
11528
+ * @param payload Docket payload describing the operation to schedule
11529
+ * @param trigger Trigger describing when the operation should fire
11530
+ * (cron, date, or offset)
11531
+ * @param date ISO-8601 date string indicating when the docket is scheduled
11532
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
11533
+ * @param [optionals.ttlMinutes] Time-to-live in minutes for the docket entry (minimum 2)
11534
+ * @returns promise that resolves to the newly created docket
11535
+ */
11536
+ async function create(payload, trigger, date, optionals = {}) {
11537
+ const {
11538
+ ttlMinutes,
11539
+ ...routingOptions
11540
+ } = optionals;
11541
+ return await new Router().post('/docket', {
11542
+ body: {
11543
+ payload,
11544
+ trigger,
11545
+ date,
11546
+ ttlMinutes
11547
+ },
11548
+ ...routingOptions
11549
+ }).then(({
11550
+ body
11551
+ }) => body);
11552
+ }
11553
+
11554
+ var docket = /*#__PURE__*/Object.freeze({
11555
+ __proto__: null,
11556
+ create: create
11557
+ });
11558
+
11559
+ // Generic type for push channel message custom data
11560
+
11561
+ // Base structure for channel push messages
11562
+
11563
+ const validateScope = scope => {
11564
+ if (!scope) throw new EpicenterError('No scope found where one was required');
11565
+ const {
11566
+ scopeBoundary,
11567
+ scopeKey,
11568
+ pushCategory
11569
+ } = scope;
11570
+ if (!scopeBoundary) throw new EpicenterError('Missing scope component: scopeBoundary');
11571
+ if (!scopeKey) throw new EpicenterError('Missing scope component: scopeKey');
11572
+ if (!pushCategory) throw new EpicenterError('Missing scope component: pushCategory');
11573
+ if (!Object.prototype.hasOwnProperty.call(SCOPE_BOUNDARY, scopeBoundary)) throw new EpicenterError(`Invalid scope boundary: ${scopeBoundary}`);
11574
+ if (!Object.prototype.hasOwnProperty.call(PUSH_CATEGORY, pushCategory)) throw new EpicenterError(`Invalid push category: ${pushCategory}`);
11575
+ };
11576
+
11577
+ /**
11578
+ * Used to subscribe to CometD channels. Pass in a channel scope to instantiate, if a subscription to that scope already exists it will use it.
11579
+ *
11580
+ * @example
11581
+ * import { Channel, authAdapter, SCOPE_BOUNDARY, PUSH_CATEGORY } from 'epicenter-libs';
11582
+ * const session = authAdapter.getLocalSession();
11583
+ * const channel = new Channel({
11584
+ * scopeBoundary: SCOPE_BOUNDARY.GROUP,
11585
+ * scopeKey: session.groupKey,
11586
+ * pushCategory: PUSH_CATEGORY.CHAT,
11587
+ * });
11588
+ * await channel.subscribe((data) => {
11589
+ * console.log('Received message:', data);
11590
+ * });
11591
+ */
11592
+ class Channel {
11593
+ /**
11594
+ * Channel constructor
11595
+ *
11596
+ * @param scope Object with the scope boundary, scope key, and push category; defines the namespace for the channel
11597
+ * @param scope.scopeBoundary Scope boundary, defines the type of scope; See [scope boundary](#SCOPE_BOUNDARY) for all types
11598
+ * @param scope.scopeKey Scope key, a unique identifier tied to the scope. E.g., if your `scopeBoundary` is `GROUP`, your `scopeKey` will be your `groupKey`; for `EPISODE`, `episodeKey`, etc.
11599
+ * @param scope.pushCategory Push category, defines the type of channel; See [push category](#PUSH_CATEGORY) for all types
11600
+ */
11601
+ constructor(scope) {
11602
+ _defineProperty(this, "path", void 0);
11603
+ _defineProperty(this, "update", void 0);
11604
+ _defineProperty(this, "subscription", null);
11605
+ const {
11606
+ scopeBoundary,
11607
+ scopeKey,
11608
+ pushCategory
11609
+ } = scope;
11610
+ validateScope(scope);
11611
+ this.path = `/${scopeBoundary.toLowerCase()}/${scopeKey}/${pushCategory.toLowerCase()}`;
11612
+ if (cometdAdapter.subscriptions.has(this.path)) {
11613
+ this.subscription = cometdAdapter.subscriptions.get(this.path) || null;
11614
+ }
11615
+ }
11616
+
11617
+ /**
11618
+ * Publishes content to the CometD channel
11619
+ *
11620
+ * @example
11621
+ * import { Channel, authAdapter, SCOPE_BOUNDARY, PUSH_CATEGORY } from 'epicenter-libs';
11622
+ * const session = authAdapter.getLocalSession();
11623
+ * const channel = new Channel({
11624
+ * scopeBoundary: SCOPE_BOUNDARY.GROUP,
11625
+ * scopeKey: session.groupKey,
11626
+ * pushCategory: PUSH_CATEGORY.CHAT,
11627
+ * });
11628
+ * await channel.publish({ message: 'Hello!' });
11629
+ *
11630
+ * @param content Content to publish to the channel
11631
+ * @returns promise that resolves to the CometD message response
11632
+ */
11633
+ publish(content) {
11634
+ return cometdAdapter.publish(this, content);
11635
+ }
10636
11636
 
10637
11637
  /**
10638
11638
  * Subscribes to the CometD channel, attaching a handler for any channel updates. If a subscription already exists it will first unsubscribe, ensuring that only one subscription is ever attached to the channel.
@@ -10746,6 +11746,367 @@
10746
11746
  }
10747
11747
  }
10748
11748
 
11749
+ // ──────────────────────────────────────────────
11750
+ // Types
11751
+ // ──────────────────────────────────────────────
11752
+
11753
+ // ──────────────────────────────────────────────
11754
+ // Functions
11755
+ // ──────────────────────────────────────────────
11756
+
11757
+ /**
11758
+ * Retrieves the git integration configuration for the project.
11759
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git`
11760
+ *
11761
+ * @example
11762
+ * import { gitAdapter } from 'epicenter-libs';
11763
+ * const integration = await gitAdapter.get();
11764
+ *
11765
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11766
+ * @returns promise that resolves to the git integration configuration
11767
+ */
11768
+ async function get(optionals = {}) {
11769
+ return new Router().get('/git', optionals).then(({
11770
+ body
11771
+ }) => body);
11772
+ }
11773
+
11774
+ /**
11775
+ * Retrieves the current git status for the project.
11776
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/status`
11777
+ *
11778
+ * @example
11779
+ * import { gitAdapter } from 'epicenter-libs';
11780
+ * const status = await gitAdapter.getStatus();
11781
+ * console.log(status.currentBranch);
11782
+ *
11783
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11784
+ * @returns promise that resolves to the git status, including the current branch
11785
+ */
11786
+ async function getStatus(optionals = {}) {
11787
+ return new Router().get('/git/status', optionals).then(({
11788
+ body
11789
+ }) => body);
11790
+ }
11791
+
11792
+ /**
11793
+ * Checks out a branch in the project's git repository.
11794
+ * Base URL: GET `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/checkout/{branch}`
11795
+ *
11796
+ * @example
11797
+ * import { gitAdapter } from 'epicenter-libs';
11798
+ * await gitAdapter.checkout('main');
11799
+ *
11800
+ * @param branch Name of the branch to check out
11801
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11802
+ * @returns promise that resolves when the checkout is complete
11803
+ */
11804
+ async function checkout(branch, optionals = {}) {
11805
+ return new Router().get(`/git/checkout/${branch}`, optionals).then(({
11806
+ body
11807
+ }) => body);
11808
+ }
11809
+
11810
+ /**
11811
+ * Resets the project's git repository, optionally to a specific branch.
11812
+ * Base URL: DELETE `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/reset[/{branch}]`
11813
+ *
11814
+ * @example
11815
+ * import { gitAdapter } from 'epicenter-libs';
11816
+ * await gitAdapter.reset(); // reset current branch
11817
+ * await gitAdapter.reset({ branch: 'main' }); // reset to 'main'
11818
+ *
11819
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
11820
+ * @param [optionals.branch] Branch to reset to; if omitted, resets the current branch
11821
+ * @returns promise that resolves when the reset is complete
11822
+ */
11823
+ async function reset(optionals = {}) {
11824
+ const {
11825
+ branch,
11826
+ ...routingOptions
11827
+ } = optionals;
11828
+ return new Router().delete(`/git/reset${branch ? `/${branch}` : ''}`, routingOptions).then(({
11829
+ body
11830
+ }) => body);
11831
+ }
11832
+
11833
+ /**
11834
+ * Creates a git integration for the project.
11835
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/integration`
11836
+ *
11837
+ * @example
11838
+ * import { gitAdapter } from 'epicenter-libs';
11839
+ * const integration = await gitAdapter.createIntegration({
11840
+ * uri: 'git@github.com:myorg/myrepo.git',
11841
+ * publicKey: '...',
11842
+ * privateKey: '...',
11843
+ * publicKeySpec: 'openssh',
11844
+ * privateKeySpec: 'pkcs8',
11845
+ * algorithm: 'ed25519',
11846
+ * });
11847
+ *
11848
+ * @param integration Git integration configuration to create
11849
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11850
+ * @returns promise that resolves to the created git integration
11851
+ */
11852
+ async function createIntegration(integration, optionals = {}) {
11853
+ return new Router().post('/git/integration', {
11854
+ body: integration,
11855
+ ...optionals
11856
+ }).then(({
11857
+ body
11858
+ }) => body);
11859
+ }
11860
+
11861
+ /**
11862
+ * Updates the git integration for the project.
11863
+ * Base URL: PATCH `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/integration`
11864
+ *
11865
+ * @example
11866
+ * import { gitAdapter } from 'epicenter-libs';
11867
+ * const integration = await gitAdapter.updateIntegration({
11868
+ * uri: 'git@github.com:myorg/newrepo.git',
11869
+ * publicKeySpec: 'openssh',
11870
+ * privateKeySpec: 'pkcs8',
11871
+ * algorithm: 'ed25519',
11872
+ * });
11873
+ *
11874
+ * @param integration Fields to update on the git integration
11875
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11876
+ * @returns promise that resolves to the updated git integration
11877
+ */
11878
+ async function updateIntegration(integration, optionals = {}) {
11879
+ return new Router().patch('/git/integration', {
11880
+ body: integration,
11881
+ ...optionals
11882
+ }).then(({
11883
+ body
11884
+ }) => body);
11885
+ }
11886
+
11887
+ /**
11888
+ * Removes the git integration for the project.
11889
+ * Base URL: DELETE `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/integration`
11890
+ *
11891
+ * @example
11892
+ * import { gitAdapter } from 'epicenter-libs';
11893
+ * await gitAdapter.removeIntegration();
11894
+ *
11895
+ * @param [optionals] Optional arguments; pass network call options overrides here.
11896
+ * @returns promise that resolves when the integration is removed
11897
+ */
11898
+ async function removeIntegration(optionals = {}) {
11899
+ return new Router().delete('/git/integration', optionals).then(({
11900
+ body
11901
+ }) => body);
11902
+ }
11903
+
11904
+ /**
11905
+ * Pushes local commits to the remote git repository.
11906
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/push`
11907
+ *
11908
+ * @example
11909
+ * import { gitAdapter } from 'epicenter-libs';
11910
+ * await gitAdapter.push({ message: 'Update simulation data' });
11911
+ *
11912
+ * @param optionals Arguments object; also accepts network call option overrides.
11913
+ * @param optionals.message Commit message (required)
11914
+ * @param [optionals.password] Password for authentication
11915
+ * @param [optionals.force] Force-push, bypassing non-fast-forward checks
11916
+ * @returns promise that resolves when the push is complete
11917
+ */
11918
+ async function push(optionals) {
11919
+ const {
11920
+ message,
11921
+ password,
11922
+ force,
11923
+ ...routingOptions
11924
+ } = optionals;
11925
+ return new Router().withSearchParams({
11926
+ force
11927
+ }).post('/git/push', {
11928
+ body: {
11929
+ message,
11930
+ password
11931
+ },
11932
+ ...routingOptions
11933
+ }).then(({
11934
+ body
11935
+ }) => body);
11936
+ }
11937
+
11938
+ /**
11939
+ * Pulls changes from the remote git repository into the project.
11940
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/git/pull`
11941
+ *
11942
+ * @example
11943
+ * import { gitAdapter } from 'epicenter-libs';
11944
+ * await gitAdapter.pull({ force: true, confirm: true });
11945
+ *
11946
+ * @param [optionals] Optional arguments; pass network call options overrides here. Special arguments specific to this method are listed below if they exist.
11947
+ * @param [optionals.password] Password for authentication
11948
+ * @param [optionals.force] Force the pull, overwriting local changes
11949
+ * @param [optionals.confirm] Set the `X-Forio-Confirmation` header to confirm an overwrite
11950
+ * @returns promise that resolves when the pull is complete
11951
+ */
11952
+ async function pull(optionals = {}) {
11953
+ const {
11954
+ password,
11955
+ force,
11956
+ confirm,
11957
+ headers: headersOverride,
11958
+ ...routingOptions
11959
+ } = optionals;
11960
+ const headers = Object.assign({}, headersOverride, confirm ? {
11961
+ 'X-Forio-Confirmation': true
11962
+ } : {});
11963
+ return new Router().withSearchParams({
11964
+ force
11965
+ }).post('/git/pull', {
11966
+ body: {
11967
+ password
11968
+ },
11969
+ headers,
11970
+ ...routingOptions
11971
+ }).then(({
11972
+ body
11973
+ }) => body);
11974
+ }
11975
+
11976
+ var git = /*#__PURE__*/Object.freeze({
11977
+ __proto__: null,
11978
+ checkout: checkout,
11979
+ createIntegration: createIntegration,
11980
+ get: get,
11981
+ getStatus: getStatus,
11982
+ pull: pull,
11983
+ push: push,
11984
+ removeIntegration: removeIntegration,
11985
+ reset: reset,
11986
+ updateIntegration: updateIntegration
11987
+ });
11988
+
11989
+ // ──────────────────────────────────────────────
11990
+ // Data Points
11991
+ // ──────────────────────────────────────────────
11992
+
11993
+ // ──────────────────────────────────────────────
11994
+ // Chart Series
11995
+ // ──────────────────────────────────────────────
11996
+
11997
+ // ──────────────────────────────────────────────
11998
+ // Chart, Table, Picture
11999
+ // ──────────────────────────────────────────────
12000
+
12001
+ // ──────────────────────────────────────────────
12002
+ // Binary Data
12003
+ // ──────────────────────────────────────────────
12004
+
12005
+ // ──────────────────────────────────────────────
12006
+ // Environment, Slide, Document
12007
+ // ──────────────────────────────────────────────
12008
+
12009
+ /**
12010
+ * Generates a PowerPoint file from a template and returns it as binary data (JSON-encoded)
12011
+ * Base URL: PUT `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/powerpoint/{TEMPLATE_DIRECTORY}/{TEMPLATE_PATH}`
12012
+ *
12013
+ * @example
12014
+ * import { powerpointAdapter } from 'epicenter-libs';
12015
+ * const binaryData = await powerpointAdapter.generate('MODEL', 'en-US-debrief-template.pptx', {
12016
+ * output: 'debrief-slides.pptx',
12017
+ * environment: {},
12018
+ * slides: [
12019
+ * {
12020
+ * number: 1,
12021
+ * environment: {
12022
+ * tables: [{ name: 'Leaderboard', data: [['Rank', 'Name', 'Score']] }],
12023
+ * },
12024
+ * },
12025
+ * ],
12026
+ * });
12027
+ *
12028
+ * @param templateDirectory Directory where the template is stored: 'DATA' or 'MODEL'
12029
+ * @param templatePath Path to the template file within the directory
12030
+ * @param document Document shadow defining the output filename, environment, and slides
12031
+ * @param [optionals] Optional arguments; pass network call options overrides here.
12032
+ * @returns promise that resolves to the generated PowerPoint as BinaryData
12033
+ */
12034
+ async function generate(templateDirectory, templatePath, document, optionals = {}) {
12035
+ return new Router().put(`/powerpoint/${templateDirectory}/${templatePath}`, {
12036
+ body: document,
12037
+ ...optionals
12038
+ }).then(({
12039
+ body
12040
+ }) => body);
12041
+ }
12042
+
12043
+ /**
12044
+ * Generates a PowerPoint file from a template and returns it as a streaming response.
12045
+ * Useful for downloading the generated file directly.
12046
+ * Base URL: POST `https://forio.com/api/v3/{ACCOUNT}/{PROJECT}/powerpoint/{TEMPLATE_DIRECTORY}/{TEMPLATE_PATH}`
12047
+ *
12048
+ * @example
12049
+ * import { powerpointAdapter } from 'epicenter-libs';
12050
+ * const response = await powerpointAdapter.stream('MODEL', 'en-US-debrief-template.pptx', {
12051
+ * output: 'debrief-slides.pptx',
12052
+ * environment: {},
12053
+ * slides: [],
12054
+ * });
12055
+ * const blob = await response.blob();
12056
+ *
12057
+ * @param templateDirectory Directory where the template is stored: 'DATA' or 'MODEL'
12058
+ * @param templatePath Path to the template file within the directory
12059
+ * @param document Document shadow defining the output filename, environment, and slides
12060
+ * @param [optionals] Optional arguments; pass network call options overrides here.
12061
+ * @returns promise that resolves to the raw Response for streaming/blob handling
12062
+ */
12063
+ async function stream(templateDirectory, templatePath, document, optionals = {}) {
12064
+ const {
12065
+ server,
12066
+ accountShortName,
12067
+ projectShortName,
12068
+ useProjectProxy,
12069
+ query,
12070
+ headers: headersOverride,
12071
+ authorization,
12072
+ includeAuthorization
12073
+ } = optionals;
12074
+ const url = new Router().getURL(`/powerpoint/${templateDirectory}/${templatePath}`, {
12075
+ server,
12076
+ accountShortName,
12077
+ projectShortName,
12078
+ useProjectProxy,
12079
+ query
12080
+ });
12081
+ const headers = {
12082
+ 'Content-type': 'application/json; charset=UTF-8',
12083
+ ...headersOverride
12084
+ };
12085
+ if (includeAuthorization !== false) {
12086
+ const {
12087
+ session
12088
+ } = identification;
12089
+ if (!headers.Authorization) {
12090
+ if (session) headers.Authorization = `Bearer ${session.token}`;
12091
+ if (authorization) headers.Authorization = authorization;
12092
+ if (config.authOverride) headers.Authorization = config.authOverride;
12093
+ }
12094
+ }
12095
+ return fetch(url.toString(), {
12096
+ method: 'POST',
12097
+ cache: 'no-cache',
12098
+ redirect: 'follow',
12099
+ headers,
12100
+ body: JSON.stringify(document)
12101
+ });
12102
+ }
12103
+
12104
+ var powerpoint = /*#__PURE__*/Object.freeze({
12105
+ __proto__: null,
12106
+ generate: generate,
12107
+ stream: stream
12108
+ });
12109
+
10749
12110
  const proxy = async (resource, options) => {
10750
12111
  const {
10751
12112
  accountShortName,
@@ -10763,9 +12124,9 @@
10763
12124
  proxy: proxy
10764
12125
  });
10765
12126
 
10766
- /* yes, this string template literal is weird;
10767
- * it's cause rollup does not recogize 3.34.2 as an individual token otherwise */
10768
- const version = `Epicenter (v${'3.34.2'}) for Browsers | Build Date: 2026-04-01T19:37:03.682Z`;
12127
+ /* "3.35.1", "Browsers" and "2026-09-24T20:47:51.952Z" are injected at build time — by
12128
+ * @rollup/plugin-replace for the shipped bundles and by Vite's `define` for tests */
12129
+ const version = `Epicenter (v${"3.35.1"}) for ${"Browsers"} | Build Date: ${"2026-09-24T20:47:51.952Z"}`;
10769
12130
  const UNAUTHORIZED = 401;
10770
12131
  const FORBIDDEN = 403;
10771
12132
  const DEFAULT_ERROR_HANDLERS = {};
@@ -14538,15 +15899,22 @@
14538
15899
  exports.config = config;
14539
15900
  exports.consensusAdapter = consensus;
14540
15901
  exports.dailyAdapter = daily;
15902
+ exports.docketAdapter = docket;
14541
15903
  exports.emailAdapter = email;
15904
+ exports.encyclopediaAdapter = encyclopedia;
14542
15905
  exports.episodeAdapter = episode;
14543
15906
  exports.errorManager = errorManager;
15907
+ exports.fileAdapter = file;
15908
+ exports.gitAdapter = git;
14544
15909
  exports.groupAdapter = group;
14545
15910
  exports.leaderboardAdapter = leaderboard;
14546
15911
  exports.matchmakerAdapter = matchmaker;
15912
+ exports.pipelineAdapter = pipeline;
15913
+ exports.powerpointAdapter = powerpoint;
14547
15914
  exports.presenceAdapter = presence;
14548
15915
  exports.projectAdapter = project;
14549
15916
  exports.recaptchaAdapter = recaptcha;
15917
+ exports.registrationAdapter = registration;
14550
15918
  exports.runAdapter = run;
14551
15919
  exports.somebodyAdapter = somebody;
14552
15920
  exports.taskAdapter = task;