} runToLastAsync
* @property {function(): void} reset
* @property {function(number | Date): void} setSystemTime
+ * @property {function(number): void} jump
* @property {Performance} performance
* @property {function(number[]): number[]} hrtime - process.hrtime (legacy)
* @property {function(): void} uninstall Uninstall the clock.
* @property {Function[]} methods - the methods that are faked
* @property {boolean} [shouldClearNativeTimers] inherited from config
+ * @property {{methodName:string, original:any}[] | undefined} timersModuleMethods
*/
/* eslint-enable jsdoc/require-property-description */
@@ -2200,8 +2231,6 @@ const globalObject = require("@sinonjs/commons").global;
* @returns {FakeTimers}
*/
function withGlobal(_global) {
- const userAgent = _global.navigator && _global.navigator.userAgent;
- const isRunningInIE = userAgent && userAgent.indexOf("MSIE ") > -1;
const maxTimeout = Math.pow(2, 31) - 1; //see https://heycam.github.io/webidl/#abstract-opdef-converttoint
const idCounterStart = 1e12; // arbitrarily large number to avoid collisions with native timer IDs
const NOOP = function () {
@@ -2243,29 +2272,12 @@ function withGlobal(_global) {
typeof _global.cancelIdleCallback === "function";
const setImmediatePresent =
_global.setImmediate && typeof _global.setImmediate === "function";
-
- // Make properties writable in IE, as per
- // https://www.adequatelygood.com/Replacing-setTimeout-Globally.html
- /* eslint-disable no-self-assign */
- if (isRunningInIE) {
- _global.setTimeout = _global.setTimeout;
- _global.clearTimeout = _global.clearTimeout;
- _global.setInterval = _global.setInterval;
- _global.clearInterval = _global.clearInterval;
- _global.Date = _global.Date;
- }
-
- // setImmediate is not a standard function
- // avoid adding the prop to the window object if not present
- if (setImmediatePresent) {
- _global.setImmediate = _global.setImmediate;
- _global.clearImmediate = _global.clearImmediate;
- }
- /* eslint-enable no-self-assign */
+ const intlPresent = _global.Intl && typeof _global.Intl === "object";
_global.clearTimeout(timeoutResult);
const NativeDate = _global.Date;
+ const NativeIntl = _global.Intl;
let uniqueTimerId = idCounterStart;
/**
@@ -2320,7 +2332,7 @@ function withGlobal(_global) {
if (l > 3 || !/^(\d\d:){0,2}\d\d?$/.test(str)) {
throw new Error(
- "tick only understands numbers, 'm:s' and 'h:m:s'. Each part must be two digits"
+ "tick only understands numbers, 'm:s' and 'h:m:s'. Each part must be two digits",
);
}
@@ -2389,7 +2401,7 @@ function withGlobal(_global) {
*/
function getInfiniteLoopError(clock, job) {
const infiniteLoopError = new Error(
- `Aborting after running ${clock.loopLimit} timers, assuming an infinite loop!`
+ `Aborting after running ${clock.loopLimit} timers, assuming an infinite loop!`,
);
if (!job.error) {
@@ -2399,13 +2411,13 @@ function withGlobal(_global) {
// pattern never matched in Node
const computedTargetPattern = /target\.*[<|(|[].*?[>|\]|)]\s*/;
let clockMethodPattern = new RegExp(
- String(Object.keys(clock).join("|"))
+ String(Object.keys(clock).join("|")),
);
if (addTimerReturnsObject) {
// node.js environment
clockMethodPattern = new RegExp(
- `\\s+at (Object\\.)?(?:${Object.keys(clock).join("|")})\\s+`
+ `\\s+at (Object\\.)?(?:${Object.keys(clock).join("|")})\\s+`,
);
}
@@ -2539,7 +2551,7 @@ function withGlobal(_global) {
date,
hour,
minute,
- second
+ second,
);
default:
return new NativeDate(
@@ -2549,7 +2561,7 @@ function withGlobal(_global) {
hour,
minute,
second,
- ms
+ ms,
);
}
}
@@ -2557,6 +2569,55 @@ function withGlobal(_global) {
return mirrorDateProperties(ClockDate, NativeDate);
}
+ /**
+ * Mirror Intl by default on our fake implementation
+ *
+ * Most of the properties are the original native ones,
+ * but we need to take control of those that have a
+ * dependency on the current clock.
+ *
+ * @returns {object} the partly fake Intl implementation
+ */
+ function createIntl() {
+ const ClockIntl = {};
+ /*
+ * All properties of Intl are non-enumerable, so we need
+ * to do a bit of work to get them out.
+ */
+ Object.getOwnPropertyNames(NativeIntl).forEach(
+ (property) => (ClockIntl[property] = NativeIntl[property]),
+ );
+
+ ClockIntl.DateTimeFormat = function (...args) {
+ const realFormatter = new NativeIntl.DateTimeFormat(...args);
+ const formatter = {};
+
+ ["formatRange", "formatRangeToParts", "resolvedOptions"].forEach(
+ (method) => {
+ formatter[method] =
+ realFormatter[method].bind(realFormatter);
+ },
+ );
+
+ ["format", "formatToParts"].forEach((method) => {
+ formatter[method] = function (date) {
+ return realFormatter[method](date || ClockIntl.clock.now);
+ };
+ });
+
+ return formatter;
+ };
+
+ ClockIntl.DateTimeFormat.prototype = Object.create(
+ NativeIntl.DateTimeFormat.prototype,
+ );
+
+ ClockIntl.DateTimeFormat.supportedLocalesOf =
+ NativeIntl.DateTimeFormat.supportedLocalesOf;
+
+ return ClockIntl;
+ }
+
//eslint-disable-next-line jsdoc/require-jsdoc
function enqueueJob(clock, job) {
// enqueues a microtick-deferred task - ecma262/#sec-enqueuejob
@@ -2601,7 +2662,7 @@ function withGlobal(_global) {
throw new TypeError(
`[ERR_INVALID_CALLBACK]: Callback must be a function. Received ${
timer.func
- } of type ${typeof timer.func}`
+ } of type ${typeof timer.func}`,
);
}
}
@@ -2884,7 +2945,7 @@ function withGlobal(_global) {
}
warnOnce(
`FakeTimers: ${handlerName} was invoked to clear a native timer instead of one created by this library.` +
- "\nTo automatically clean-up native timers, use `shouldClearNativeTimers`."
+ "\nTo automatically clean-up native timers, use `shouldClearNativeTimers`.",
);
}
@@ -2901,7 +2962,7 @@ function withGlobal(_global) {
const clear = getClearHandler(ttype);
const schedule = getScheduleHandler(timer.type);
throw new Error(
- `Cannot clear timer: timer created with ${schedule}() but cleared with ${clear}()`
+ `Cannot clear timer: timer created with ${schedule}() but cleared with ${clear}()`,
);
}
}
@@ -2926,7 +2987,7 @@ function withGlobal(_global) {
} else if (method === "performance") {
const originalPerfDescriptor = Object.getOwnPropertyDescriptor(
clock,
- `_${method}`
+ `_${method}`,
);
if (
originalPerfDescriptor &&
@@ -2936,7 +2997,7 @@ function withGlobal(_global) {
Object.defineProperty(
_global,
method,
- originalPerfDescriptor
+ originalPerfDescriptor,
);
} else if (originalPerfDescriptor.configurable) {
_global[method] = clock[`_${method}`];
@@ -2952,6 +3013,12 @@ function withGlobal(_global) {
}
}
}
+ if (clock.timersModuleMethods !== undefined) {
+ for (let j = 0; j < clock.timersModuleMethods.length; j++) {
+ const entry = clock.timersModuleMethods[j];
+ timersModule[entry.methodName] = entry.original;
+ }
+ }
}
if (config.shouldAdvanceTime === true) {
@@ -2978,17 +3045,19 @@ function withGlobal(_global) {
function hijackMethod(target, method, clock) {
clock[method].hadOwnProperty = Object.prototype.hasOwnProperty.call(
target,
- method
+ method,
);
clock[`_${method}`] = target[method];
if (method === "Date") {
const date = mirrorDateProperties(clock[method], target[method]);
target[method] = date;
+ } else if (method === "Intl") {
+ target[method] = clock[method];
} else if (method === "performance") {
const originalPerfDescriptor = Object.getOwnPropertyDescriptor(
target,
- method
+ method,
);
// JSDOM has a read only performance field so we have to save/copy it differently
if (
@@ -2999,12 +3068,12 @@ function withGlobal(_global) {
Object.defineProperty(
clock,
`_${method}`,
- originalPerfDescriptor
+ originalPerfDescriptor,
);
const perfDescriptor = Object.getOwnPropertyDescriptor(
clock,
- method
+ method,
);
Object.defineProperty(target, method, perfDescriptor);
} else {
@@ -3017,7 +3086,7 @@ function withGlobal(_global) {
Object.defineProperties(
target[method],
- Object.getOwnPropertyDescriptors(clock[method])
+ Object.getOwnPropertyDescriptors(clock[method]),
);
}
@@ -3039,6 +3108,7 @@ function withGlobal(_global) {
* @property {setInterval} setInterval
* @property {clearInterval} clearInterval
* @property {Date} Date
+ * @property {Intl} Intl
* @property {SetImmediate=} setImmediate
* @property {function(NodeImmediate): void=} clearImmediate
* @property {function(number[]):number[]=} hrtime
@@ -3097,6 +3167,10 @@ function withGlobal(_global) {
timers.cancelIdleCallback = _global.cancelIdleCallback;
}
+ if (intlPresent) {
+ timers.Intl = _global.Intl;
+ }
+
const originalSetTimeout = _global.setImmediate || _global.setTimeout;
/**
@@ -3115,7 +3189,7 @@ function withGlobal(_global) {
if (NativeDate === undefined) {
throw new Error(
"The global scope doesn't have a `Date` object" +
- " (see https://github.com/sinonjs/sinon/issues/1852#issuecomment-419622780)"
+ " (see https://github.com/sinonjs/sinon/issues/1852#issuecomment-419622780)",
);
}
@@ -3144,7 +3218,7 @@ function withGlobal(_global) {
if (Array.isArray(prev)) {
if (prev[1] > 1e9) {
throw new TypeError(
- "Number of nanoseconds can't exceed a billion"
+ "Number of nanoseconds can't exceed a billion",
);
}
@@ -3162,6 +3236,17 @@ function withGlobal(_global) {
return [secsSinceStart, remainderInNanos];
}
+ /**
+ * A high resolution timestamp in milliseconds.
+ *
+ * @typedef {number} DOMHighResTimeStamp
+ */
+
+ /**
+ * performance.now()
+ *
+ * @returns {DOMHighResTimeStamp}
+ */
function fakePerformanceNow() {
const hrt = hrtime();
const millis = hrt[0] * 1000 + hrt[1] / 1e6;
@@ -3175,9 +3260,14 @@ function withGlobal(_global) {
};
}
+ if (intlPresent) {
+ clock.Intl = createIntl();
+ clock.Intl.clock = clock;
+ }
+
clock.requestIdleCallback = function requestIdleCallback(
func,
- timeout
+ timeout,
) {
let timeToNextIdlePeriod = 0;
@@ -3213,7 +3303,7 @@ function withGlobal(_global) {
clock.setTimeout[utilPromisify.custom] =
function promisifiedSetTimeout(timeout, arg) {
return new _global.Promise(function setTimeoutExecutor(
- resolve
+ resolve,
) {
addTimer(clock, {
func: resolve,
@@ -3274,7 +3364,7 @@ function withGlobal(_global) {
args: [arg],
immediate: true,
});
- }
+ },
);
};
}
@@ -3576,6 +3666,8 @@ function withGlobal(_global) {
function doRun() {
originalSetTimeout(function () {
try {
+ runJobs(clock);
+
let numTimers;
if (i < clock.loopLimit) {
if (!clock.timers) {
@@ -3585,7 +3677,7 @@ function withGlobal(_global) {
}
numTimers = Object.keys(
- clock.timers
+ clock.timers,
).length;
if (numTimers === 0) {
resetIsNearInfiniteLimit();
@@ -3631,6 +3723,7 @@ function withGlobal(_global) {
try {
const timer = lastTimer(clock);
if (!timer) {
+ runJobs(clock);
resolve(clock.now);
}
@@ -3672,6 +3765,25 @@ function withGlobal(_global) {
}
};
+ /**
+ * @param {string|number} tickValue number of milliseconds or a human-readable value like "01:11:15"
+ * @returns {number} will return the new `now` value
+ */
+ clock.jump = function jump(tickValue) {
+ const msFloat =
+ typeof tickValue === "number"
+ ? tickValue
+ : parseTime(tickValue);
+ const ms = Math.floor(msFloat);
+
+ for (const timer of Object.values(clock.timers)) {
+ if (clock.now + ms > timer.callAt) {
+ timer.callAt = clock.now + ms;
+ }
+ }
+ clock.tick(ms);
+ };
+
if (performancePresent) {
clock.performance = Object.create(null);
clock.performance.now = fakePerformanceNow;
@@ -3699,8 +3811,8 @@ function withGlobal(_global) {
) {
throw new TypeError(
`FakeTimers.install called with ${String(
- config
- )} install requires an object parameter`
+ config,
+ )} install requires an object parameter`,
);
}
@@ -3708,7 +3820,7 @@ function withGlobal(_global) {
// Timers are already faked; this is a problem.
// Make the user reset timers before continuing.
throw new TypeError(
- "Can't install fake timers twice on the same global object."
+ "Can't install fake timers twice on the same global object.",
);
}
@@ -3721,7 +3833,7 @@ function withGlobal(_global) {
if (config.target) {
throw new TypeError(
- "config.target is no longer supported. Use `withGlobal(target)` instead."
+ "config.target is no longer supported. Use `withGlobal(target)` instead.",
);
}
@@ -3746,23 +3858,23 @@ function withGlobal(_global) {
const intervalTick = doIntervalTick.bind(
null,
clock,
- config.advanceTimeDelta
+ config.advanceTimeDelta,
);
const intervalId = _global.setInterval(
intervalTick,
- config.advanceTimeDelta
+ config.advanceTimeDelta,
);
clock.attachedInterval = intervalId;
}
if (clock.methods.includes("performance")) {
const proto = (() => {
- if (hasPerformancePrototype) {
- return _global.Performance.prototype;
- }
if (hasPerformanceConstructorPrototype) {
return _global.performance.constructor.prototype;
}
+ if (hasPerformancePrototype) {
+ return _global.Performance.prototype;
+ }
})();
if (proto) {
Object.getOwnPropertyNames(proto).forEach(function (name) {
@@ -3776,11 +3888,13 @@ function withGlobal(_global) {
} else if ((config.toFake || []).includes("performance")) {
// user explicitly tried to fake performance when not present
throw new ReferenceError(
- "non-existent performance object cannot be faked"
+ "non-existent performance object cannot be faked",
);
}
}
-
+ if (_global === globalObject && timersModule) {
+ clock.timersModuleMethods = [];
+ }
for (i = 0, l = clock.methods.length; i < l; i++) {
const nameOfMethodToReplace = clock.methods[i];
if (nameOfMethodToReplace === "hrtime") {
@@ -3800,6 +3914,18 @@ function withGlobal(_global) {
} else {
hijackMethod(_global, nameOfMethodToReplace, clock);
}
+ if (
+ clock.timersModuleMethods !== undefined &&
+ timersModule[nameOfMethodToReplace]
+ ) {
+ const original = timersModule[nameOfMethodToReplace];
+ clock.timersModuleMethods.push({
+ methodName: nameOfMethodToReplace,
+ original: original,
+ });
+ timersModule[nameOfMethodToReplace] =
+ _global[nameOfMethodToReplace];
+ }
}
return clock;
@@ -3833,7 +3959,7 @@ exports.createClock = defaultImplementation.createClock;
exports.install = defaultImplementation.install;
exports.withGlobal = withGlobal;
-},{"@sinonjs/commons":19,"util":42}],33:[function(require,module,exports){
+},{"@sinonjs/commons":19,"timers":56,"util":60}],33:[function(require,module,exports){
// This is free and unencumbered software released into the public domain.
// See LICENSE.md for more information.
@@ -7207,11 +7333,897 @@ module.exports = {
// is `undefined`, take a pure object instead
}(this || {}));
},{"./encoding-indexes.js":34}],36:[function(require,module,exports){
-module.exports = Array.isArray || function (arr) {
- return Object.prototype.toString.call(arr) == '[object Array]';
+'use strict';
+
+var possibleNames = [
+ 'BigInt64Array',
+ 'BigUint64Array',
+ 'Float32Array',
+ 'Float64Array',
+ 'Int16Array',
+ 'Int32Array',
+ 'Int8Array',
+ 'Uint16Array',
+ 'Uint32Array',
+ 'Uint8Array',
+ 'Uint8ClampedArray'
+];
+
+var g = typeof globalThis === 'undefined' ? global : globalThis;
+
+module.exports = function availableTypedArrays() {
+ var out = [];
+ for (var i = 0; i < possibleNames.length; i++) {
+ if (typeof g[possibleNames[i]] === 'function') {
+ out[out.length] = possibleNames[i];
+ }
+ }
+ return out;
};
},{}],37:[function(require,module,exports){
+'use strict';
+
+var GetIntrinsic = require('get-intrinsic');
+
+var callBind = require('./');
+
+var $indexOf = callBind(GetIntrinsic('String.prototype.indexOf'));
+
+module.exports = function callBoundIntrinsic(name, allowMissing) {
+ var intrinsic = GetIntrinsic(name, !!allowMissing);
+ if (typeof intrinsic === 'function' && $indexOf(name, '.prototype.') > -1) {
+ return callBind(intrinsic);
+ }
+ return intrinsic;
+};
+
+},{"./":38,"get-intrinsic":42}],38:[function(require,module,exports){
+'use strict';
+
+var bind = require('function-bind');
+var GetIntrinsic = require('get-intrinsic');
+
+var $apply = GetIntrinsic('%Function.prototype.apply%');
+var $call = GetIntrinsic('%Function.prototype.call%');
+var $reflectApply = GetIntrinsic('%Reflect.apply%', true) || bind.call($call, $apply);
+
+var $gOPD = GetIntrinsic('%Object.getOwnPropertyDescriptor%', true);
+var $defineProperty = GetIntrinsic('%Object.defineProperty%', true);
+var $max = GetIntrinsic('%Math.max%');
+
+if ($defineProperty) {
+ try {
+ $defineProperty({}, 'a', { value: 1 });
+ } catch (e) {
+ // IE 8 has a broken defineProperty
+ $defineProperty = null;
+ }
+}
+
+module.exports = function callBind(originalFunction) {
+ var func = $reflectApply(bind, $call, arguments);
+ if ($gOPD && $defineProperty) {
+ var desc = $gOPD(func, 'length');
+ if (desc.configurable) {
+ // original length, plus the receiver, minus any additional arguments (after the receiver)
+ $defineProperty(
+ func,
+ 'length',
+ { value: 1 + $max(0, originalFunction.length - (arguments.length - 1)) }
+ );
+ }
+ }
+ return func;
+};
+
+var applyBind = function applyBind() {
+ return $reflectApply(bind, $apply, arguments);
+};
+
+if ($defineProperty) {
+ $defineProperty(module.exports, 'apply', { value: applyBind });
+} else {
+ module.exports.apply = applyBind;
+}
+
+},{"function-bind":41,"get-intrinsic":42}],39:[function(require,module,exports){
+'use strict';
+
+var isCallable = require('is-callable');
+
+var toStr = Object.prototype.toString;
+var hasOwnProperty = Object.prototype.hasOwnProperty;
+
+var forEachArray = function forEachArray(array, iterator, receiver) {
+ for (var i = 0, len = array.length; i < len; i++) {
+ if (hasOwnProperty.call(array, i)) {
+ if (receiver == null) {
+ iterator(array[i], i, array);
+ } else {
+ iterator.call(receiver, array[i], i, array);
+ }
+ }
+ }
+};
+
+var forEachString = function forEachString(string, iterator, receiver) {
+ for (var i = 0, len = string.length; i < len; i++) {
+ // no such thing as a sparse string.
+ if (receiver == null) {
+ iterator(string.charAt(i), i, string);
+ } else {
+ iterator.call(receiver, string.charAt(i), i, string);
+ }
+ }
+};
+
+var forEachObject = function forEachObject(object, iterator, receiver) {
+ for (var k in object) {
+ if (hasOwnProperty.call(object, k)) {
+ if (receiver == null) {
+ iterator(object[k], k, object);
+ } else {
+ iterator.call(receiver, object[k], k, object);
+ }
+ }
+ }
+};
+
+var forEach = function forEach(list, iterator, thisArg) {
+ if (!isCallable(iterator)) {
+ throw new TypeError('iterator must be a function');
+ }
+
+ var receiver;
+ if (arguments.length >= 3) {
+ receiver = thisArg;
+ }
+
+ if (toStr.call(list) === '[object Array]') {
+ forEachArray(list, iterator, receiver);
+ } else if (typeof list === 'string') {
+ forEachString(list, iterator, receiver);
+ } else {
+ forEachObject(list, iterator, receiver);
+ }
+};
+
+module.exports = forEach;
+
+},{"is-callable":50}],40:[function(require,module,exports){
+'use strict';
+
+/* eslint no-invalid-this: 1 */
+
+var ERROR_MESSAGE = 'Function.prototype.bind called on incompatible ';
+var slice = Array.prototype.slice;
+var toStr = Object.prototype.toString;
+var funcType = '[object Function]';
+
+module.exports = function bind(that) {
+ var target = this;
+ if (typeof target !== 'function' || toStr.call(target) !== funcType) {
+ throw new TypeError(ERROR_MESSAGE + target);
+ }
+ var args = slice.call(arguments, 1);
+
+ var bound;
+ var binder = function () {
+ if (this instanceof bound) {
+ var result = target.apply(
+ this,
+ args.concat(slice.call(arguments))
+ );
+ if (Object(result) === result) {
+ return result;
+ }
+ return this;
+ } else {
+ return target.apply(
+ that,
+ args.concat(slice.call(arguments))
+ );
+ }
+ };
+
+ var boundLength = Math.max(0, target.length - args.length);
+ var boundArgs = [];
+ for (var i = 0; i < boundLength; i++) {
+ boundArgs.push('$' + i);
+ }
+
+ bound = Function('binder', 'return function (' + boundArgs.join(',') + '){ return binder.apply(this,arguments); }')(binder);
+
+ if (target.prototype) {
+ var Empty = function Empty() {};
+ Empty.prototype = target.prototype;
+ bound.prototype = new Empty();
+ Empty.prototype = null;
+ }
+
+ return bound;
+};
+
+},{}],41:[function(require,module,exports){
+'use strict';
+
+var implementation = require('./implementation');
+
+module.exports = Function.prototype.bind || implementation;
+
+},{"./implementation":40}],42:[function(require,module,exports){
+'use strict';
+
+var undefined;
+
+var $SyntaxError = SyntaxError;
+var $Function = Function;
+var $TypeError = TypeError;
+
+// eslint-disable-next-line consistent-return
+var getEvalledConstructor = function (expressionSyntax) {
+ try {
+ return $Function('"use strict"; return (' + expressionSyntax + ').constructor;')();
+ } catch (e) {}
+};
+
+var $gOPD = Object.getOwnPropertyDescriptor;
+if ($gOPD) {
+ try {
+ $gOPD({}, '');
+ } catch (e) {
+ $gOPD = null; // this is IE 8, which has a broken gOPD
+ }
+}
+
+var throwTypeError = function () {
+ throw new $TypeError();
+};
+var ThrowTypeError = $gOPD
+ ? (function () {
+ try {
+ // eslint-disable-next-line no-unused-expressions, no-caller, no-restricted-properties
+ arguments.callee; // IE 8 does not throw here
+ return throwTypeError;
+ } catch (calleeThrows) {
+ try {
+ // IE 8 throws on Object.getOwnPropertyDescriptor(arguments, '')
+ return $gOPD(arguments, 'callee').get;
+ } catch (gOPDthrows) {
+ return throwTypeError;
+ }
+ }
+ }())
+ : throwTypeError;
+
+var hasSymbols = require('has-symbols')();
+
+var getProto = Object.getPrototypeOf || function (x) { return x.__proto__; }; // eslint-disable-line no-proto
+
+var needsEval = {};
+
+var TypedArray = typeof Uint8Array === 'undefined' ? undefined : getProto(Uint8Array);
+
+var INTRINSICS = {
+ '%AggregateError%': typeof AggregateError === 'undefined' ? undefined : AggregateError,
+ '%Array%': Array,
+ '%ArrayBuffer%': typeof ArrayBuffer === 'undefined' ? undefined : ArrayBuffer,
+ '%ArrayIteratorPrototype%': hasSymbols ? getProto([][Symbol.iterator]()) : undefined,
+ '%AsyncFromSyncIteratorPrototype%': undefined,
+ '%AsyncFunction%': needsEval,
+ '%AsyncGenerator%': needsEval,
+ '%AsyncGeneratorFunction%': needsEval,
+ '%AsyncIteratorPrototype%': needsEval,
+ '%Atomics%': typeof Atomics === 'undefined' ? undefined : Atomics,
+ '%BigInt%': typeof BigInt === 'undefined' ? undefined : BigInt,
+ '%Boolean%': Boolean,
+ '%DataView%': typeof DataView === 'undefined' ? undefined : DataView,
+ '%Date%': Date,
+ '%decodeURI%': decodeURI,
+ '%decodeURIComponent%': decodeURIComponent,
+ '%encodeURI%': encodeURI,
+ '%encodeURIComponent%': encodeURIComponent,
+ '%Error%': Error,
+ '%eval%': eval, // eslint-disable-line no-eval
+ '%EvalError%': EvalError,
+ '%Float32Array%': typeof Float32Array === 'undefined' ? undefined : Float32Array,
+ '%Float64Array%': typeof Float64Array === 'undefined' ? undefined : Float64Array,
+ '%FinalizationRegistry%': typeof FinalizationRegistry === 'undefined' ? undefined : FinalizationRegistry,
+ '%Function%': $Function,
+ '%GeneratorFunction%': needsEval,
+ '%Int8Array%': typeof Int8Array === 'undefined' ? undefined : Int8Array,
+ '%Int16Array%': typeof Int16Array === 'undefined' ? undefined : Int16Array,
+ '%Int32Array%': typeof Int32Array === 'undefined' ? undefined : Int32Array,
+ '%isFinite%': isFinite,
+ '%isNaN%': isNaN,
+ '%IteratorPrototype%': hasSymbols ? getProto(getProto([][Symbol.iterator]())) : undefined,
+ '%JSON%': typeof JSON === 'object' ? JSON : undefined,
+ '%Map%': typeof Map === 'undefined' ? undefined : Map,
+ '%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols ? undefined : getProto(new Map()[Symbol.iterator]()),
+ '%Math%': Math,
+ '%Number%': Number,
+ '%Object%': Object,
+ '%parseFloat%': parseFloat,
+ '%parseInt%': parseInt,
+ '%Promise%': typeof Promise === 'undefined' ? undefined : Promise,
+ '%Proxy%': typeof Proxy === 'undefined' ? undefined : Proxy,
+ '%RangeError%': RangeError,
+ '%ReferenceError%': ReferenceError,
+ '%Reflect%': typeof Reflect === 'undefined' ? undefined : Reflect,
+ '%RegExp%': RegExp,
+ '%Set%': typeof Set === 'undefined' ? undefined : Set,
+ '%SetIteratorPrototype%': typeof Set === 'undefined' || !hasSymbols ? undefined : getProto(new Set()[Symbol.iterator]()),
+ '%SharedArrayBuffer%': typeof SharedArrayBuffer === 'undefined' ? undefined : SharedArrayBuffer,
+ '%String%': String,
+ '%StringIteratorPrototype%': hasSymbols ? getProto(''[Symbol.iterator]()) : undefined,
+ '%Symbol%': hasSymbols ? Symbol : undefined,
+ '%SyntaxError%': $SyntaxError,
+ '%ThrowTypeError%': ThrowTypeError,
+ '%TypedArray%': TypedArray,
+ '%TypeError%': $TypeError,
+ '%Uint8Array%': typeof Uint8Array === 'undefined' ? undefined : Uint8Array,
+ '%Uint8ClampedArray%': typeof Uint8ClampedArray === 'undefined' ? undefined : Uint8ClampedArray,
+ '%Uint16Array%': typeof Uint16Array === 'undefined' ? undefined : Uint16Array,
+ '%Uint32Array%': typeof Uint32Array === 'undefined' ? undefined : Uint32Array,
+ '%URIError%': URIError,
+ '%WeakMap%': typeof WeakMap === 'undefined' ? undefined : WeakMap,
+ '%WeakRef%': typeof WeakRef === 'undefined' ? undefined : WeakRef,
+ '%WeakSet%': typeof WeakSet === 'undefined' ? undefined : WeakSet
+};
+
+var doEval = function doEval(name) {
+ var value;
+ if (name === '%AsyncFunction%') {
+ value = getEvalledConstructor('async function () {}');
+ } else if (name === '%GeneratorFunction%') {
+ value = getEvalledConstructor('function* () {}');
+ } else if (name === '%AsyncGeneratorFunction%') {
+ value = getEvalledConstructor('async function* () {}');
+ } else if (name === '%AsyncGenerator%') {
+ var fn = doEval('%AsyncGeneratorFunction%');
+ if (fn) {
+ value = fn.prototype;
+ }
+ } else if (name === '%AsyncIteratorPrototype%') {
+ var gen = doEval('%AsyncGenerator%');
+ if (gen) {
+ value = getProto(gen.prototype);
+ }
+ }
+
+ INTRINSICS[name] = value;
+
+ return value;
+};
+
+var LEGACY_ALIASES = {
+ '%ArrayBufferPrototype%': ['ArrayBuffer', 'prototype'],
+ '%ArrayPrototype%': ['Array', 'prototype'],
+ '%ArrayProto_entries%': ['Array', 'prototype', 'entries'],
+ '%ArrayProto_forEach%': ['Array', 'prototype', 'forEach'],
+ '%ArrayProto_keys%': ['Array', 'prototype', 'keys'],
+ '%ArrayProto_values%': ['Array', 'prototype', 'values'],
+ '%AsyncFunctionPrototype%': ['AsyncFunction', 'prototype'],
+ '%AsyncGenerator%': ['AsyncGeneratorFunction', 'prototype'],
+ '%AsyncGeneratorPrototype%': ['AsyncGeneratorFunction', 'prototype', 'prototype'],
+ '%BooleanPrototype%': ['Boolean', 'prototype'],
+ '%DataViewPrototype%': ['DataView', 'prototype'],
+ '%DatePrototype%': ['Date', 'prototype'],
+ '%ErrorPrototype%': ['Error', 'prototype'],
+ '%EvalErrorPrototype%': ['EvalError', 'prototype'],
+ '%Float32ArrayPrototype%': ['Float32Array', 'prototype'],
+ '%Float64ArrayPrototype%': ['Float64Array', 'prototype'],
+ '%FunctionPrototype%': ['Function', 'prototype'],
+ '%Generator%': ['GeneratorFunction', 'prototype'],
+ '%GeneratorPrototype%': ['GeneratorFunction', 'prototype', 'prototype'],
+ '%Int8ArrayPrototype%': ['Int8Array', 'prototype'],
+ '%Int16ArrayPrototype%': ['Int16Array', 'prototype'],
+ '%Int32ArrayPrototype%': ['Int32Array', 'prototype'],
+ '%JSONParse%': ['JSON', 'parse'],
+ '%JSONStringify%': ['JSON', 'stringify'],
+ '%MapPrototype%': ['Map', 'prototype'],
+ '%NumberPrototype%': ['Number', 'prototype'],
+ '%ObjectPrototype%': ['Object', 'prototype'],
+ '%ObjProto_toString%': ['Object', 'prototype', 'toString'],
+ '%ObjProto_valueOf%': ['Object', 'prototype', 'valueOf'],
+ '%PromisePrototype%': ['Promise', 'prototype'],
+ '%PromiseProto_then%': ['Promise', 'prototype', 'then'],
+ '%Promise_all%': ['Promise', 'all'],
+ '%Promise_reject%': ['Promise', 'reject'],
+ '%Promise_resolve%': ['Promise', 'resolve'],
+ '%RangeErrorPrototype%': ['RangeError', 'prototype'],
+ '%ReferenceErrorPrototype%': ['ReferenceError', 'prototype'],
+ '%RegExpPrototype%': ['RegExp', 'prototype'],
+ '%SetPrototype%': ['Set', 'prototype'],
+ '%SharedArrayBufferPrototype%': ['SharedArrayBuffer', 'prototype'],
+ '%StringPrototype%': ['String', 'prototype'],
+ '%SymbolPrototype%': ['Symbol', 'prototype'],
+ '%SyntaxErrorPrototype%': ['SyntaxError', 'prototype'],
+ '%TypedArrayPrototype%': ['TypedArray', 'prototype'],
+ '%TypeErrorPrototype%': ['TypeError', 'prototype'],
+ '%Uint8ArrayPrototype%': ['Uint8Array', 'prototype'],
+ '%Uint8ClampedArrayPrototype%': ['Uint8ClampedArray', 'prototype'],
+ '%Uint16ArrayPrototype%': ['Uint16Array', 'prototype'],
+ '%Uint32ArrayPrototype%': ['Uint32Array', 'prototype'],
+ '%URIErrorPrototype%': ['URIError', 'prototype'],
+ '%WeakMapPrototype%': ['WeakMap', 'prototype'],
+ '%WeakSetPrototype%': ['WeakSet', 'prototype']
+};
+
+var bind = require('function-bind');
+var hasOwn = require('has');
+var $concat = bind.call(Function.call, Array.prototype.concat);
+var $spliceApply = bind.call(Function.apply, Array.prototype.splice);
+var $replace = bind.call(Function.call, String.prototype.replace);
+var $strSlice = bind.call(Function.call, String.prototype.slice);
+var $exec = bind.call(Function.call, RegExp.prototype.exec);
+
+/* adapted from https://github.com/lodash/lodash/blob/4.17.15/dist/lodash.js#L6735-L6744 */
+var rePropName = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g;
+var reEscapeChar = /\\(\\)?/g; /** Used to match backslashes in property paths. */
+var stringToPath = function stringToPath(string) {
+ var first = $strSlice(string, 0, 1);
+ var last = $strSlice(string, -1);
+ if (first === '%' && last !== '%') {
+ throw new $SyntaxError('invalid intrinsic syntax, expected closing `%`');
+ } else if (last === '%' && first !== '%') {
+ throw new $SyntaxError('invalid intrinsic syntax, expected opening `%`');
+ }
+ var result = [];
+ $replace(string, rePropName, function (match, number, quote, subString) {
+ result[result.length] = quote ? $replace(subString, reEscapeChar, '$1') : number || match;
+ });
+ return result;
+};
+/* end adaptation */
+
+var getBaseIntrinsic = function getBaseIntrinsic(name, allowMissing) {
+ var intrinsicName = name;
+ var alias;
+ if (hasOwn(LEGACY_ALIASES, intrinsicName)) {
+ alias = LEGACY_ALIASES[intrinsicName];
+ intrinsicName = '%' + alias[0] + '%';
+ }
+
+ if (hasOwn(INTRINSICS, intrinsicName)) {
+ var value = INTRINSICS[intrinsicName];
+ if (value === needsEval) {
+ value = doEval(intrinsicName);
+ }
+ if (typeof value === 'undefined' && !allowMissing) {
+ throw new $TypeError('intrinsic ' + name + ' exists, but is not available. Please file an issue!');
+ }
+
+ return {
+ alias: alias,
+ name: intrinsicName,
+ value: value
+ };
+ }
+
+ throw new $SyntaxError('intrinsic ' + name + ' does not exist!');
+};
+
+module.exports = function GetIntrinsic(name, allowMissing) {
+ if (typeof name !== 'string' || name.length === 0) {
+ throw new $TypeError('intrinsic name must be a non-empty string');
+ }
+ if (arguments.length > 1 && typeof allowMissing !== 'boolean') {
+ throw new $TypeError('"allowMissing" argument must be a boolean');
+ }
+
+ if ($exec(/^%?[^%]*%?$/, name) === null) {
+ throw new $SyntaxError('`%` may not be present anywhere but at the beginning and end of the intrinsic name');
+ }
+ var parts = stringToPath(name);
+ var intrinsicBaseName = parts.length > 0 ? parts[0] : '';
+
+ var intrinsic = getBaseIntrinsic('%' + intrinsicBaseName + '%', allowMissing);
+ var intrinsicRealName = intrinsic.name;
+ var value = intrinsic.value;
+ var skipFurtherCaching = false;
+
+ var alias = intrinsic.alias;
+ if (alias) {
+ intrinsicBaseName = alias[0];
+ $spliceApply(parts, $concat([0, 1], alias));
+ }
+
+ for (var i = 1, isOwn = true; i < parts.length; i += 1) {
+ var part = parts[i];
+ var first = $strSlice(part, 0, 1);
+ var last = $strSlice(part, -1);
+ if (
+ (
+ (first === '"' || first === "'" || first === '`')
+ || (last === '"' || last === "'" || last === '`')
+ )
+ && first !== last
+ ) {
+ throw new $SyntaxError('property names with quotes must have matching quotes');
+ }
+ if (part === 'constructor' || !isOwn) {
+ skipFurtherCaching = true;
+ }
+
+ intrinsicBaseName += '.' + part;
+ intrinsicRealName = '%' + intrinsicBaseName + '%';
+
+ if (hasOwn(INTRINSICS, intrinsicRealName)) {
+ value = INTRINSICS[intrinsicRealName];
+ } else if (value != null) {
+ if (!(part in value)) {
+ if (!allowMissing) {
+ throw new $TypeError('base intrinsic for ' + name + ' exists, but the property is not available.');
+ }
+ return void undefined;
+ }
+ if ($gOPD && (i + 1) >= parts.length) {
+ var desc = $gOPD(value, part);
+ isOwn = !!desc;
+
+ // By convention, when a data property is converted to an accessor
+ // property to emulate a data property that does not suffer from
+ // the override mistake, that accessor's getter is marked with
+ // an `originalValue` property. Here, when we detect this, we
+ // uphold the illusion by pretending to see that original data
+ // property, i.e., returning the value rather than the getter
+ // itself.
+ if (isOwn && 'get' in desc && !('originalValue' in desc.get)) {
+ value = desc.get;
+ } else {
+ value = value[part];
+ }
+ } else {
+ isOwn = hasOwn(value, part);
+ value = value[part];
+ }
+
+ if (isOwn && !skipFurtherCaching) {
+ INTRINSICS[intrinsicRealName] = value;
+ }
+ }
+ }
+ return value;
+};
+
+},{"function-bind":41,"has":47,"has-symbols":44}],43:[function(require,module,exports){
+'use strict';
+
+var GetIntrinsic = require('get-intrinsic');
+
+var $gOPD = GetIntrinsic('%Object.getOwnPropertyDescriptor%', true);
+
+if ($gOPD) {
+ try {
+ $gOPD([], 'length');
+ } catch (e) {
+ // IE 8 has a broken gOPD
+ $gOPD = null;
+ }
+}
+
+module.exports = $gOPD;
+
+},{"get-intrinsic":42}],44:[function(require,module,exports){
+'use strict';
+
+var origSymbol = typeof Symbol !== 'undefined' && Symbol;
+var hasSymbolSham = require('./shams');
+
+module.exports = function hasNativeSymbols() {
+ if (typeof origSymbol !== 'function') { return false; }
+ if (typeof Symbol !== 'function') { return false; }
+ if (typeof origSymbol('foo') !== 'symbol') { return false; }
+ if (typeof Symbol('bar') !== 'symbol') { return false; }
+
+ return hasSymbolSham();
+};
+
+},{"./shams":45}],45:[function(require,module,exports){
+'use strict';
+
+/* eslint complexity: [2, 18], max-statements: [2, 33] */
+module.exports = function hasSymbols() {
+ if (typeof Symbol !== 'function' || typeof Object.getOwnPropertySymbols !== 'function') { return false; }
+ if (typeof Symbol.iterator === 'symbol') { return true; }
+
+ var obj = {};
+ var sym = Symbol('test');
+ var symObj = Object(sym);
+ if (typeof sym === 'string') { return false; }
+
+ if (Object.prototype.toString.call(sym) !== '[object Symbol]') { return false; }
+ if (Object.prototype.toString.call(symObj) !== '[object Symbol]') { return false; }
+
+ // temp disabled per https://github.com/ljharb/object.assign/issues/17
+ // if (sym instanceof Symbol) { return false; }
+ // temp disabled per https://github.com/WebReflection/get-own-property-symbols/issues/4
+ // if (!(symObj instanceof Symbol)) { return false; }
+
+ // if (typeof Symbol.prototype.toString !== 'function') { return false; }
+ // if (String(sym) !== Symbol.prototype.toString.call(sym)) { return false; }
+
+ var symVal = 42;
+ obj[sym] = symVal;
+ for (sym in obj) { return false; } // eslint-disable-line no-restricted-syntax, no-unreachable-loop
+ if (typeof Object.keys === 'function' && Object.keys(obj).length !== 0) { return false; }
+
+ if (typeof Object.getOwnPropertyNames === 'function' && Object.getOwnPropertyNames(obj).length !== 0) { return false; }
+
+ var syms = Object.getOwnPropertySymbols(obj);
+ if (syms.length !== 1 || syms[0] !== sym) { return false; }
+
+ if (!Object.prototype.propertyIsEnumerable.call(obj, sym)) { return false; }
+
+ if (typeof Object.getOwnPropertyDescriptor === 'function') {
+ var descriptor = Object.getOwnPropertyDescriptor(obj, sym);
+ if (descriptor.value !== symVal || descriptor.enumerable !== true) { return false; }
+ }
+
+ return true;
+};
+
+},{}],46:[function(require,module,exports){
+'use strict';
+
+var hasSymbols = require('has-symbols/shams');
+
+module.exports = function hasToStringTagShams() {
+ return hasSymbols() && !!Symbol.toStringTag;
+};
+
+},{"has-symbols/shams":45}],47:[function(require,module,exports){
+'use strict';
+
+var bind = require('function-bind');
+
+module.exports = bind.call(Function.call, Object.prototype.hasOwnProperty);
+
+},{"function-bind":41}],48:[function(require,module,exports){
+if (typeof Object.create === 'function') {
+ // implementation from standard node.js 'util' module
+ module.exports = function inherits(ctor, superCtor) {
+ if (superCtor) {
+ ctor.super_ = superCtor
+ ctor.prototype = Object.create(superCtor.prototype, {
+ constructor: {
+ value: ctor,
+ enumerable: false,
+ writable: true,
+ configurable: true
+ }
+ })
+ }
+ };
+} else {
+ // old school shim for old browsers
+ module.exports = function inherits(ctor, superCtor) {
+ if (superCtor) {
+ ctor.super_ = superCtor
+ var TempCtor = function () {}
+ TempCtor.prototype = superCtor.prototype
+ ctor.prototype = new TempCtor()
+ ctor.prototype.constructor = ctor
+ }
+ }
+}
+
+},{}],49:[function(require,module,exports){
+'use strict';
+
+var hasToStringTag = require('has-tostringtag/shams')();
+var callBound = require('call-bind/callBound');
+
+var $toString = callBound('Object.prototype.toString');
+
+var isStandardArguments = function isArguments(value) {
+ if (hasToStringTag && value && typeof value === 'object' && Symbol.toStringTag in value) {
+ return false;
+ }
+ return $toString(value) === '[object Arguments]';
+};
+
+var isLegacyArguments = function isArguments(value) {
+ if (isStandardArguments(value)) {
+ return true;
+ }
+ return value !== null &&
+ typeof value === 'object' &&
+ typeof value.length === 'number' &&
+ value.length >= 0 &&
+ $toString(value) !== '[object Array]' &&
+ $toString(value.callee) === '[object Function]';
+};
+
+var supportsStandardArguments = (function () {
+ return isStandardArguments(arguments);
+}());
+
+isStandardArguments.isLegacyArguments = isLegacyArguments; // for tests
+
+module.exports = supportsStandardArguments ? isStandardArguments : isLegacyArguments;
+
+},{"call-bind/callBound":37,"has-tostringtag/shams":46}],50:[function(require,module,exports){
+'use strict';
+
+var fnToStr = Function.prototype.toString;
+var reflectApply = typeof Reflect === 'object' && Reflect !== null && Reflect.apply;
+var badArrayLike;
+var isCallableMarker;
+if (typeof reflectApply === 'function' && typeof Object.defineProperty === 'function') {
+ try {
+ badArrayLike = Object.defineProperty({}, 'length', {
+ get: function () {
+ throw isCallableMarker;
+ }
+ });
+ isCallableMarker = {};
+ // eslint-disable-next-line no-throw-literal
+ reflectApply(function () { throw 42; }, null, badArrayLike);
+ } catch (_) {
+ if (_ !== isCallableMarker) {
+ reflectApply = null;
+ }
+ }
+} else {
+ reflectApply = null;
+}
+
+var constructorRegex = /^\s*class\b/;
+var isES6ClassFn = function isES6ClassFunction(value) {
+ try {
+ var fnStr = fnToStr.call(value);
+ return constructorRegex.test(fnStr);
+ } catch (e) {
+ return false; // not a function
+ }
+};
+
+var tryFunctionObject = function tryFunctionToStr(value) {
+ try {
+ if (isES6ClassFn(value)) { return false; }
+ fnToStr.call(value);
+ return true;
+ } catch (e) {
+ return false;
+ }
+};
+var toStr = Object.prototype.toString;
+var fnClass = '[object Function]';
+var genClass = '[object GeneratorFunction]';
+var hasToStringTag = typeof Symbol === 'function' && typeof Symbol.toStringTag === 'symbol';
+/* globals document: false */
+var documentDotAll = typeof document === 'object' && typeof document.all === 'undefined' && document.all !== undefined ? document.all : {};
+
+module.exports = reflectApply
+ ? function isCallable(value) {
+ if (value === documentDotAll) { return true; }
+ if (!value) { return false; }
+ if (typeof value !== 'function' && typeof value !== 'object') { return false; }
+ if (typeof value === 'function' && !value.prototype) { return true; }
+ try {
+ reflectApply(value, null, badArrayLike);
+ } catch (e) {
+ if (e !== isCallableMarker) { return false; }
+ }
+ return !isES6ClassFn(value);
+ }
+ : function isCallable(value) {
+ if (value === documentDotAll) { return true; }
+ if (!value) { return false; }
+ if (typeof value !== 'function' && typeof value !== 'object') { return false; }
+ if (typeof value === 'function' && !value.prototype) { return true; }
+ if (hasToStringTag) { return tryFunctionObject(value); }
+ if (isES6ClassFn(value)) { return false; }
+ var strClass = toStr.call(value);
+ return strClass === fnClass || strClass === genClass;
+ };
+
+},{}],51:[function(require,module,exports){
+'use strict';
+
+var toStr = Object.prototype.toString;
+var fnToStr = Function.prototype.toString;
+var isFnRegex = /^\s*(?:function)?\*/;
+var hasToStringTag = require('has-tostringtag/shams')();
+var getProto = Object.getPrototypeOf;
+var getGeneratorFunc = function () { // eslint-disable-line consistent-return
+ if (!hasToStringTag) {
+ return false;
+ }
+ try {
+ return Function('return function*() {}')();
+ } catch (e) {
+ }
+};
+var GeneratorFunction;
+
+module.exports = function isGeneratorFunction(fn) {
+ if (typeof fn !== 'function') {
+ return false;
+ }
+ if (isFnRegex.test(fnToStr.call(fn))) {
+ return true;
+ }
+ if (!hasToStringTag) {
+ var str = toStr.call(fn);
+ return str === '[object GeneratorFunction]';
+ }
+ if (!getProto) {
+ return false;
+ }
+ if (typeof GeneratorFunction === 'undefined') {
+ var generatorFunc = getGeneratorFunc();
+ GeneratorFunction = generatorFunc ? getProto(generatorFunc) : false;
+ }
+ return getProto(fn) === GeneratorFunction;
+};
+
+},{"has-tostringtag/shams":46}],52:[function(require,module,exports){
+'use strict';
+
+var forEach = require('for-each');
+var availableTypedArrays = require('available-typed-arrays');
+var callBound = require('call-bind/callBound');
+
+var $toString = callBound('Object.prototype.toString');
+var hasToStringTag = require('has-tostringtag/shams')();
+var gOPD = require('gopd');
+
+var g = typeof globalThis === 'undefined' ? global : globalThis;
+var typedArrays = availableTypedArrays();
+
+var $indexOf = callBound('Array.prototype.indexOf', true) || function indexOf(array, value) {
+ for (var i = 0; i < array.length; i += 1) {
+ if (array[i] === value) {
+ return i;
+ }
+ }
+ return -1;
+};
+var $slice = callBound('String.prototype.slice');
+var toStrTags = {};
+var getPrototypeOf = Object.getPrototypeOf; // require('getprototypeof');
+if (hasToStringTag && gOPD && getPrototypeOf) {
+ forEach(typedArrays, function (typedArray) {
+ var arr = new g[typedArray]();
+ if (Symbol.toStringTag in arr) {
+ var proto = getPrototypeOf(arr);
+ var descriptor = gOPD(proto, Symbol.toStringTag);
+ if (!descriptor) {
+ var superProto = getPrototypeOf(proto);
+ descriptor = gOPD(superProto, Symbol.toStringTag);
+ }
+ toStrTags[typedArray] = descriptor.get;
+ }
+ });
+}
+
+var tryTypedArrays = function tryAllTypedArrays(value) {
+ var anyTrue = false;
+ forEach(toStrTags, function (getter, typedArray) {
+ if (!anyTrue) {
+ try {
+ anyTrue = getter.call(value) === typedArray;
+ } catch (e) { /**/ }
+ }
+ });
+ return anyTrue;
+};
+
+module.exports = function isTypedArray(value) {
+ if (!value || typeof value !== 'object') { return false; }
+ if (!hasToStringTag || !(Symbol.toStringTag in value)) {
+ var tag = $slice($toString(value), 8, -1);
+ return $indexOf(typedArrays, tag) > -1;
+ }
+ if (!gOPD) { return false; }
+ return tryTypedArrays(value);
+};
+
+},{"available-typed-arrays":36,"call-bind/callBound":37,"for-each":39,"gopd":43,"has-tostringtag/shams":46}],53:[function(require,module,exports){
module.exports = extend;
/*
@@ -7285,435 +8297,681 @@ function isUnextendable(val) {
return !val || (typeof val != 'object' && typeof val != 'function');
}
-},{}],38:[function(require,module,exports){
-var isarray = require('isarray')
-
-/**
- * Expose `pathToRegexp`.
- */
-module.exports = pathToRegexp
-module.exports.parse = parse
-module.exports.compile = compile
-module.exports.tokensToFunction = tokensToFunction
-module.exports.tokensToRegExp = tokensToRegExp
-
+},{}],54:[function(require,module,exports){
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.pathToRegexp = exports.tokensToRegexp = exports.regexpToFunction = exports.match = exports.tokensToFunction = exports.compile = exports.parse = void 0;
/**
- * The main path matching regexp utility.
- *
- * @type {RegExp}
+ * Tokenize input string.
*/
-var PATH_REGEXP = new RegExp([
- // Match escaped characters that would otherwise appear in future matches.
- // This allows the user to escape special characters that won't transform.
- '(\\\\.)',
- // Match Express-style parameters and un-named parameters with a prefix
- // and optional suffixes. Matches appear as:
- //
- // "/:test(\\d+)?" => ["/", "test", "\d+", undefined, "?", undefined]
- // "/route(\\d+)" => [undefined, undefined, undefined, "\d+", undefined, undefined]
- // "/*" => ["/", undefined, undefined, undefined, undefined, "*"]
- '([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))'
-].join('|'), 'g')
-
+function lexer(str) {
+ var tokens = [];
+ var i = 0;
+ while (i < str.length) {
+ var char = str[i];
+ if (char === "*" || char === "+" || char === "?") {
+ tokens.push({ type: "MODIFIER", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === "\\") {
+ tokens.push({ type: "ESCAPED_CHAR", index: i++, value: str[i++] });
+ continue;
+ }
+ if (char === "{") {
+ tokens.push({ type: "OPEN", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === "}") {
+ tokens.push({ type: "CLOSE", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === ":") {
+ var name = "";
+ var j = i + 1;
+ while (j < str.length) {
+ var code = str.charCodeAt(j);
+ if (
+ // `0-9`
+ (code >= 48 && code <= 57) ||
+ // `A-Z`
+ (code >= 65 && code <= 90) ||
+ // `a-z`
+ (code >= 97 && code <= 122) ||
+ // `_`
+ code === 95) {
+ name += str[j++];
+ continue;
+ }
+ break;
+ }
+ if (!name)
+ throw new TypeError("Missing parameter name at ".concat(i));
+ tokens.push({ type: "NAME", index: i, value: name });
+ i = j;
+ continue;
+ }
+ if (char === "(") {
+ var count = 1;
+ var pattern = "";
+ var j = i + 1;
+ if (str[j] === "?") {
+ throw new TypeError("Pattern cannot start with \"?\" at ".concat(j));
+ }
+ while (j < str.length) {
+ if (str[j] === "\\") {
+ pattern += str[j++] + str[j++];
+ continue;
+ }
+ if (str[j] === ")") {
+ count--;
+ if (count === 0) {
+ j++;
+ break;
+ }
+ }
+ else if (str[j] === "(") {
+ count++;
+ if (str[j + 1] !== "?") {
+ throw new TypeError("Capturing groups are not allowed at ".concat(j));
+ }
+ }
+ pattern += str[j++];
+ }
+ if (count)
+ throw new TypeError("Unbalanced pattern at ".concat(i));
+ if (!pattern)
+ throw new TypeError("Missing pattern at ".concat(i));
+ tokens.push({ type: "PATTERN", index: i, value: pattern });
+ i = j;
+ continue;
+ }
+ tokens.push({ type: "CHAR", index: i, value: str[i++] });
+ }
+ tokens.push({ type: "END", index: i, value: "" });
+ return tokens;
+}
/**
* Parse a string for the raw tokens.
- *
- * @param {string} str
- * @param {Object=} options
- * @return {!Array}
*/
-function parse (str, options) {
- var tokens = []
- var key = 0
- var index = 0
- var path = ''
- var defaultDelimiter = options && options.delimiter || '/'
- var res
-
- while ((res = PATH_REGEXP.exec(str)) != null) {
- var m = res[0]
- var escaped = res[1]
- var offset = res.index
- path += str.slice(index, offset)
- index = offset + m.length
-
- // Ignore already escaped sequences.
- if (escaped) {
- path += escaped[1]
- continue
- }
-
- var next = str[index]
- var prefix = res[2]
- var name = res[3]
- var capture = res[4]
- var group = res[5]
- var modifier = res[6]
- var asterisk = res[7]
-
- // Push the current path onto the tokens.
- if (path) {
- tokens.push(path)
- path = ''
- }
-
- var partial = prefix != null && next != null && next !== prefix
- var repeat = modifier === '+' || modifier === '*'
- var optional = modifier === '?' || modifier === '*'
- var delimiter = res[2] || defaultDelimiter
- var pattern = capture || group
-
- tokens.push({
- name: name || key++,
- prefix: prefix || '',
- delimiter: delimiter,
- optional: optional,
- repeat: repeat,
- partial: partial,
- asterisk: !!asterisk,
- pattern: pattern ? escapeGroup(pattern) : (asterisk ? '.*' : '[^' + escapeString(delimiter) + ']+?')
- })
- }
-
- // Match any characters still remaining.
- if (index < str.length) {
- path += str.substr(index)
- }
-
- // If the path exists, push it onto the end.
- if (path) {
- tokens.push(path)
- }
-
- return tokens
+function parse(str, options) {
+ if (options === void 0) { options = {}; }
+ var tokens = lexer(str);
+ var _a = options.prefixes, prefixes = _a === void 0 ? "./" : _a;
+ var defaultPattern = "[^".concat(escapeString(options.delimiter || "/#?"), "]+?");
+ var result = [];
+ var key = 0;
+ var i = 0;
+ var path = "";
+ var tryConsume = function (type) {
+ if (i < tokens.length && tokens[i].type === type)
+ return tokens[i++].value;
+ };
+ var mustConsume = function (type) {
+ var value = tryConsume(type);
+ if (value !== undefined)
+ return value;
+ var _a = tokens[i], nextType = _a.type, index = _a.index;
+ throw new TypeError("Unexpected ".concat(nextType, " at ").concat(index, ", expected ").concat(type));
+ };
+ var consumeText = function () {
+ var result = "";
+ var value;
+ while ((value = tryConsume("CHAR") || tryConsume("ESCAPED_CHAR"))) {
+ result += value;
+ }
+ return result;
+ };
+ while (i < tokens.length) {
+ var char = tryConsume("CHAR");
+ var name = tryConsume("NAME");
+ var pattern = tryConsume("PATTERN");
+ if (name || pattern) {
+ var prefix = char || "";
+ if (prefixes.indexOf(prefix) === -1) {
+ path += prefix;
+ prefix = "";
+ }
+ if (path) {
+ result.push(path);
+ path = "";
+ }
+ result.push({
+ name: name || key++,
+ prefix: prefix,
+ suffix: "",
+ pattern: pattern || defaultPattern,
+ modifier: tryConsume("MODIFIER") || "",
+ });
+ continue;
+ }
+ var value = char || tryConsume("ESCAPED_CHAR");
+ if (value) {
+ path += value;
+ continue;
+ }
+ if (path) {
+ result.push(path);
+ path = "";
+ }
+ var open = tryConsume("OPEN");
+ if (open) {
+ var prefix = consumeText();
+ var name_1 = tryConsume("NAME") || "";
+ var pattern_1 = tryConsume("PATTERN") || "";
+ var suffix = consumeText();
+ mustConsume("CLOSE");
+ result.push({
+ name: name_1 || (pattern_1 ? key++ : ""),
+ pattern: name_1 && !pattern_1 ? defaultPattern : pattern_1,
+ prefix: prefix,
+ suffix: suffix,
+ modifier: tryConsume("MODIFIER") || "",
+ });
+ continue;
+ }
+ mustConsume("END");
+ }
+ return result;
}
-
+exports.parse = parse;
/**
* Compile a string to a template function for the path.
- *
- * @param {string} str
- * @param {Object=} options
- * @return {!function(Object=, Object=)}
- */
-function compile (str, options) {
- return tokensToFunction(parse(str, options), options)
-}
-
-/**
- * Prettier encoding of URI path segments.
- *
- * @param {string}
- * @return {string}
*/
-function encodeURIComponentPretty (str) {
- return encodeURI(str).replace(/[\/?#]/g, function (c) {
- return '%' + c.charCodeAt(0).toString(16).toUpperCase()
- })
+function compile(str, options) {
+ return tokensToFunction(parse(str, options), options);
}
-
-/**
- * Encode the asterisk parameter. Similar to `pretty`, but allows slashes.
- *
- * @param {string}
- * @return {string}
- */
-function encodeAsterisk (str) {
- return encodeURI(str).replace(/[?#]/g, function (c) {
- return '%' + c.charCodeAt(0).toString(16).toUpperCase()
- })
-}
-
+exports.compile = compile;
/**
* Expose a method for transforming tokens into the path function.
*/
-function tokensToFunction (tokens, options) {
- // Compile all the tokens into regexps.
- var matches = new Array(tokens.length)
-
- // Compile all the patterns before compilation.
- for (var i = 0; i < tokens.length; i++) {
- if (typeof tokens[i] === 'object') {
- matches[i] = new RegExp('^(?:' + tokens[i].pattern + ')$', flags(options))
- }
- }
-
- return function (obj, opts) {
- var path = ''
- var data = obj || {}
- var options = opts || {}
- var encode = options.pretty ? encodeURIComponentPretty : encodeURIComponent
-
- for (var i = 0; i < tokens.length; i++) {
- var token = tokens[i]
-
- if (typeof token === 'string') {
- path += token
-
- continue
- }
-
- var value = data[token.name]
- var segment
-
- if (value == null) {
- if (token.optional) {
- // Prepend partial segment prefixes.
- if (token.partial) {
- path += token.prefix
- }
-
- continue
- } else {
- throw new TypeError('Expected "' + token.name + '" to be defined')
- }
- }
-
- if (isarray(value)) {
- if (!token.repeat) {
- throw new TypeError('Expected "' + token.name + '" to not repeat, but received `' + JSON.stringify(value) + '`')
- }
-
- if (value.length === 0) {
- if (token.optional) {
- continue
- } else {
- throw new TypeError('Expected "' + token.name + '" to not be empty')
- }
+function tokensToFunction(tokens, options) {
+ if (options === void 0) { options = {}; }
+ var reFlags = flags(options);
+ var _a = options.encode, encode = _a === void 0 ? function (x) { return x; } : _a, _b = options.validate, validate = _b === void 0 ? true : _b;
+ // Compile all the tokens into regexps.
+ var matches = tokens.map(function (token) {
+ if (typeof token === "object") {
+ return new RegExp("^(?:".concat(token.pattern, ")$"), reFlags);
}
-
- for (var j = 0; j < value.length; j++) {
- segment = encode(value[j])
-
- if (!matches[i].test(segment)) {
- throw new TypeError('Expected all "' + token.name + '" to match "' + token.pattern + '", but received `' + JSON.stringify(segment) + '`')
- }
-
- path += (j === 0 ? token.prefix : token.delimiter) + segment
+ });
+ return function (data) {
+ var path = "";
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (typeof token === "string") {
+ path += token;
+ continue;
+ }
+ var value = data ? data[token.name] : undefined;
+ var optional = token.modifier === "?" || token.modifier === "*";
+ var repeat = token.modifier === "*" || token.modifier === "+";
+ if (Array.isArray(value)) {
+ if (!repeat) {
+ throw new TypeError("Expected \"".concat(token.name, "\" to not repeat, but got an array"));
+ }
+ if (value.length === 0) {
+ if (optional)
+ continue;
+ throw new TypeError("Expected \"".concat(token.name, "\" to not be empty"));
+ }
+ for (var j = 0; j < value.length; j++) {
+ var segment = encode(value[j], token);
+ if (validate && !matches[i].test(segment)) {
+ throw new TypeError("Expected all \"".concat(token.name, "\" to match \"").concat(token.pattern, "\", but got \"").concat(segment, "\""));
+ }
+ path += token.prefix + segment + token.suffix;
+ }
+ continue;
+ }
+ if (typeof value === "string" || typeof value === "number") {
+ var segment = encode(String(value), token);
+ if (validate && !matches[i].test(segment)) {
+ throw new TypeError("Expected \"".concat(token.name, "\" to match \"").concat(token.pattern, "\", but got \"").concat(segment, "\""));
+ }
+ path += token.prefix + segment + token.suffix;
+ continue;
+ }
+ if (optional)
+ continue;
+ var typeOfMessage = repeat ? "an array" : "a string";
+ throw new TypeError("Expected \"".concat(token.name, "\" to be ").concat(typeOfMessage));
}
-
- continue
- }
-
- segment = token.asterisk ? encodeAsterisk(value) : encode(value)
-
- if (!matches[i].test(segment)) {
- throw new TypeError('Expected "' + token.name + '" to match "' + token.pattern + '", but received "' + segment + '"')
- }
-
- path += token.prefix + segment
- }
-
- return path
- }
+ return path;
+ };
}
-
+exports.tokensToFunction = tokensToFunction;
/**
- * Escape a regular expression string.
- *
- * @param {string} str
- * @return {string}
+ * Create path match function from `path-to-regexp` spec.
*/
-function escapeString (str) {
- return str.replace(/([.+*?=^!:${}()[\]|\/\\])/g, '\\$1')
+function match(str, options) {
+ var keys = [];
+ var re = pathToRegexp(str, keys, options);
+ return regexpToFunction(re, keys, options);
}
-
+exports.match = match;
/**
- * Escape the capturing group by escaping special characters and meaning.
- *
- * @param {string} group
- * @return {string}
+ * Create a path match function from `path-to-regexp` output.
*/
-function escapeGroup (group) {
- return group.replace(/([=!:$\/()])/g, '\\$1')
+function regexpToFunction(re, keys, options) {
+ if (options === void 0) { options = {}; }
+ var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;
+ return function (pathname) {
+ var m = re.exec(pathname);
+ if (!m)
+ return false;
+ var path = m[0], index = m.index;
+ var params = Object.create(null);
+ var _loop_1 = function (i) {
+ if (m[i] === undefined)
+ return "continue";
+ var key = keys[i - 1];
+ if (key.modifier === "*" || key.modifier === "+") {
+ params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {
+ return decode(value, key);
+ });
+ }
+ else {
+ params[key.name] = decode(m[i], key);
+ }
+ };
+ for (var i = 1; i < m.length; i++) {
+ _loop_1(i);
+ }
+ return { path: path, index: index, params: params };
+ };
}
-
+exports.regexpToFunction = regexpToFunction;
/**
- * Attach the keys as a property of the regexp.
- *
- * @param {!RegExp} re
- * @param {Array} keys
- * @return {!RegExp}
+ * Escape a regular expression string.
*/
-function attachKeys (re, keys) {
- re.keys = keys
- return re
+function escapeString(str) {
+ return str.replace(/([.+*?=^!:${}()[\]|/\\])/g, "\\$1");
}
-
/**
* Get the flags for a regexp from the options.
- *
- * @param {Object} options
- * @return {string}
*/
-function flags (options) {
- return options && options.sensitive ? '' : 'i'
+function flags(options) {
+ return options && options.sensitive ? "" : "i";
}
-
/**
* Pull out keys from a regexp.
- *
- * @param {!RegExp} path
- * @param {!Array} keys
- * @return {!RegExp}
*/
-function regexpToRegexp (path, keys) {
- // Use a negative lookahead to match only capturing groups.
- var groups = path.source.match(/\((?!\?)/g)
-
- if (groups) {
- for (var i = 0; i < groups.length; i++) {
- keys.push({
- name: i,
- prefix: null,
- delimiter: null,
- optional: false,
- repeat: false,
- partial: false,
- asterisk: false,
- pattern: null
- })
+function regexpToRegexp(path, keys) {
+ if (!keys)
+ return path;
+ var groupsRegex = /\((?:\?<(.*?)>)?(?!\?)/g;
+ var index = 0;
+ var execResult = groupsRegex.exec(path.source);
+ while (execResult) {
+ keys.push({
+ // Use parenthesized substring match if available, index otherwise
+ name: execResult[1] || index++,
+ prefix: "",
+ suffix: "",
+ modifier: "",
+ pattern: "",
+ });
+ execResult = groupsRegex.exec(path.source);
}
- }
-
- return attachKeys(path, keys)
+ return path;
}
-
/**
* Transform an array into a regexp.
- *
- * @param {!Array} path
- * @param {Array} keys
- * @param {!Object} options
- * @return {!RegExp}
*/
-function arrayToRegexp (path, keys, options) {
- var parts = []
-
- for (var i = 0; i < path.length; i++) {
- parts.push(pathToRegexp(path[i], keys, options).source)
- }
-
- var regexp = new RegExp('(?:' + parts.join('|') + ')', flags(options))
-
- return attachKeys(regexp, keys)
+function arrayToRegexp(paths, keys, options) {
+ var parts = paths.map(function (path) { return pathToRegexp(path, keys, options).source; });
+ return new RegExp("(?:".concat(parts.join("|"), ")"), flags(options));
}
-
/**
* Create a path regexp from string input.
- *
- * @param {string} path
- * @param {!Array} keys
- * @param {!Object} options
- * @return {!RegExp}
*/
-function stringToRegexp (path, keys, options) {
- return tokensToRegExp(parse(path, options), keys, options)
+function stringToRegexp(path, keys, options) {
+ return tokensToRegexp(parse(path, options), keys, options);
}
-
/**
* Expose a function for taking tokens and returning a RegExp.
+ */
+function tokensToRegexp(tokens, keys, options) {
+ if (options === void 0) { options = {}; }
+ var _a = options.strict, strict = _a === void 0 ? false : _a, _b = options.start, start = _b === void 0 ? true : _b, _c = options.end, end = _c === void 0 ? true : _c, _d = options.encode, encode = _d === void 0 ? function (x) { return x; } : _d, _e = options.delimiter, delimiter = _e === void 0 ? "/#?" : _e, _f = options.endsWith, endsWith = _f === void 0 ? "" : _f;
+ var endsWithRe = "[".concat(escapeString(endsWith), "]|$");
+ var delimiterRe = "[".concat(escapeString(delimiter), "]");
+ var route = start ? "^" : "";
+ // Iterate over the tokens and create our regexp string.
+ for (var _i = 0, tokens_1 = tokens; _i < tokens_1.length; _i++) {
+ var token = tokens_1[_i];
+ if (typeof token === "string") {
+ route += escapeString(encode(token));
+ }
+ else {
+ var prefix = escapeString(encode(token.prefix));
+ var suffix = escapeString(encode(token.suffix));
+ if (token.pattern) {
+ if (keys)
+ keys.push(token);
+ if (prefix || suffix) {
+ if (token.modifier === "+" || token.modifier === "*") {
+ var mod = token.modifier === "*" ? "?" : "";
+ route += "(?:".concat(prefix, "((?:").concat(token.pattern, ")(?:").concat(suffix).concat(prefix, "(?:").concat(token.pattern, "))*)").concat(suffix, ")").concat(mod);
+ }
+ else {
+ route += "(?:".concat(prefix, "(").concat(token.pattern, ")").concat(suffix, ")").concat(token.modifier);
+ }
+ }
+ else {
+ if (token.modifier === "+" || token.modifier === "*") {
+ route += "((?:".concat(token.pattern, ")").concat(token.modifier, ")");
+ }
+ else {
+ route += "(".concat(token.pattern, ")").concat(token.modifier);
+ }
+ }
+ }
+ else {
+ route += "(?:".concat(prefix).concat(suffix, ")").concat(token.modifier);
+ }
+ }
+ }
+ if (end) {
+ if (!strict)
+ route += "".concat(delimiterRe, "?");
+ route += !options.endsWith ? "$" : "(?=".concat(endsWithRe, ")");
+ }
+ else {
+ var endToken = tokens[tokens.length - 1];
+ var isEndDelimited = typeof endToken === "string"
+ ? delimiterRe.indexOf(endToken[endToken.length - 1]) > -1
+ : endToken === undefined;
+ if (!strict) {
+ route += "(?:".concat(delimiterRe, "(?=").concat(endsWithRe, "))?");
+ }
+ if (!isEndDelimited) {
+ route += "(?=".concat(delimiterRe, "|").concat(endsWithRe, ")");
+ }
+ }
+ return new RegExp(route, flags(options));
+}
+exports.tokensToRegexp = tokensToRegexp;
+/**
+ * Normalize the given path string, returning a regular expression.
*
- * @param {!Array} tokens
- * @param {(Array|Object)=} keys
- * @param {Object=} options
- * @return {!RegExp}
+ * An empty array can be passed in for the keys, which will hold the
+ * placeholder key descriptions. For example, using `/user/:id`, `keys` will
+ * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
*/
-function tokensToRegExp (tokens, keys, options) {
- if (!isarray(keys)) {
- options = /** @type {!Object} */ (keys || options)
- keys = []
- }
+function pathToRegexp(path, keys, options) {
+ if (path instanceof RegExp)
+ return regexpToRegexp(path, keys);
+ if (Array.isArray(path))
+ return arrayToRegexp(path, keys, options);
+ return stringToRegexp(path, keys, options);
+}
+exports.pathToRegexp = pathToRegexp;
- options = options || {}
+},{}],55:[function(require,module,exports){
+// shim for using process in browser
+var process = module.exports = {};
- var strict = options.strict
- var end = options.end !== false
- var route = ''
+// cached from whatever global is present so that test runners that stub it
+// don't break things. But we need to wrap it in a try catch in case it is
+// wrapped in strict mode code which doesn't define any globals. It's inside a
+// function because try/catches deoptimize in certain engines.
- // Iterate over the tokens and create our regexp string.
- for (var i = 0; i < tokens.length; i++) {
- var token = tokens[i]
+var cachedSetTimeout;
+var cachedClearTimeout;
- if (typeof token === 'string') {
- route += escapeString(token)
- } else {
- var prefix = escapeString(token.prefix)
- var capture = '(?:' + token.pattern + ')'
+function defaultSetTimout() {
+ throw new Error('setTimeout has not been defined');
+}
+function defaultClearTimeout () {
+ throw new Error('clearTimeout has not been defined');
+}
+(function () {
+ try {
+ if (typeof setTimeout === 'function') {
+ cachedSetTimeout = setTimeout;
+ } else {
+ cachedSetTimeout = defaultSetTimout;
+ }
+ } catch (e) {
+ cachedSetTimeout = defaultSetTimout;
+ }
+ try {
+ if (typeof clearTimeout === 'function') {
+ cachedClearTimeout = clearTimeout;
+ } else {
+ cachedClearTimeout = defaultClearTimeout;
+ }
+ } catch (e) {
+ cachedClearTimeout = defaultClearTimeout;
+ }
+} ())
+function runTimeout(fun) {
+ if (cachedSetTimeout === setTimeout) {
+ //normal enviroments in sane situations
+ return setTimeout(fun, 0);
+ }
+ // if setTimeout wasn't available but was latter defined
+ if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
+ cachedSetTimeout = setTimeout;
+ return setTimeout(fun, 0);
+ }
+ try {
+ // when when somebody has screwed with setTimeout but no I.E. maddness
+ return cachedSetTimeout(fun, 0);
+ } catch(e){
+ try {
+ // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
+ return cachedSetTimeout.call(null, fun, 0);
+ } catch(e){
+ // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
+ return cachedSetTimeout.call(this, fun, 0);
+ }
+ }
- keys.push(token)
- if (token.repeat) {
- capture += '(?:' + prefix + capture + ')*'
- }
+}
+function runClearTimeout(marker) {
+ if (cachedClearTimeout === clearTimeout) {
+ //normal enviroments in sane situations
+ return clearTimeout(marker);
+ }
+ // if clearTimeout wasn't available but was latter defined
+ if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
+ cachedClearTimeout = clearTimeout;
+ return clearTimeout(marker);
+ }
+ try {
+ // when when somebody has screwed with setTimeout but no I.E. maddness
+ return cachedClearTimeout(marker);
+ } catch (e){
+ try {
+ // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
+ return cachedClearTimeout.call(null, marker);
+ } catch (e){
+ // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
+ // Some versions of I.E. have different rules for clearTimeout vs setTimeout
+ return cachedClearTimeout.call(this, marker);
+ }
+ }
- if (token.optional) {
- if (!token.partial) {
- capture = '(?:' + prefix + '(' + capture + '))?'
- } else {
- capture = prefix + '(' + capture + ')?'
+
+
+}
+var queue = [];
+var draining = false;
+var currentQueue;
+var queueIndex = -1;
+
+function cleanUpNextTick() {
+ if (!draining || !currentQueue) {
+ return;
+ }
+ draining = false;
+ if (currentQueue.length) {
+ queue = currentQueue.concat(queue);
+ } else {
+ queueIndex = -1;
+ }
+ if (queue.length) {
+ drainQueue();
+ }
+}
+
+function drainQueue() {
+ if (draining) {
+ return;
+ }
+ var timeout = runTimeout(cleanUpNextTick);
+ draining = true;
+
+ var len = queue.length;
+ while(len) {
+ currentQueue = queue;
+ queue = [];
+ while (++queueIndex < len) {
+ if (currentQueue) {
+ currentQueue[queueIndex].run();
+ }
}
- } else {
- capture = prefix + '(' + capture + ')'
- }
+ queueIndex = -1;
+ len = queue.length;
+ }
+ currentQueue = null;
+ draining = false;
+ runClearTimeout(timeout);
+}
- route += capture
+process.nextTick = function (fun) {
+ var args = new Array(arguments.length - 1);
+ if (arguments.length > 1) {
+ for (var i = 1; i < arguments.length; i++) {
+ args[i - 1] = arguments[i];
+ }
}
- }
+ queue.push(new Item(fun, args));
+ if (queue.length === 1 && !draining) {
+ runTimeout(drainQueue);
+ }
+};
- var delimiter = escapeString(options.delimiter || '/')
- var endsWithDelimiter = route.slice(-delimiter.length) === delimiter
+// v8 likes predictible objects
+function Item(fun, array) {
+ this.fun = fun;
+ this.array = array;
+}
+Item.prototype.run = function () {
+ this.fun.apply(null, this.array);
+};
+process.title = 'browser';
+process.browser = true;
+process.env = {};
+process.argv = [];
+process.version = ''; // empty string to avoid regexp issues
+process.versions = {};
+
+function noop() {}
+
+process.on = noop;
+process.addListener = noop;
+process.once = noop;
+process.off = noop;
+process.removeListener = noop;
+process.removeAllListeners = noop;
+process.emit = noop;
+process.prependListener = noop;
+process.prependOnceListener = noop;
+
+process.listeners = function (name) { return [] }
+
+process.binding = function (name) {
+ throw new Error('process.binding is not supported');
+};
- // In non-strict mode we allow a slash at the end of match. If the path to
- // match already ends with a slash, we remove it for consistency. The slash
- // is valid at the end of a path match, not in the middle. This is important
- // in non-ending mode, where "/test/" shouldn't match "/test//route".
- if (!strict) {
- route = (endsWithDelimiter ? route.slice(0, -delimiter.length) : route) + '(?:' + delimiter + '(?=$))?'
- }
+process.cwd = function () { return '/' };
+process.chdir = function (dir) {
+ throw new Error('process.chdir is not supported');
+};
+process.umask = function() { return 0; };
- if (end) {
- route += '$'
- } else {
- // In non-ending mode, we need the capturing groups to match as much as
- // possible by using a positive lookahead to the end or next path segment.
- route += strict && endsWithDelimiter ? '' : '(?=' + delimiter + '|$)'
- }
+},{}],56:[function(require,module,exports){
+var nextTick = require('process/browser.js').nextTick;
+var apply = Function.prototype.apply;
+var slice = Array.prototype.slice;
+var immediateIds = {};
+var nextImmediateId = 0;
+
+// DOM APIs, for completeness
+
+exports.setTimeout = function() {
+ return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout);
+};
+exports.setInterval = function() {
+ return new Timeout(apply.call(setInterval, window, arguments), clearInterval);
+};
+exports.clearTimeout =
+exports.clearInterval = function(timeout) { timeout.close(); };
- return attachKeys(new RegExp('^' + route, flags(options)), keys)
+function Timeout(id, clearFn) {
+ this._id = id;
+ this._clearFn = clearFn;
}
+Timeout.prototype.unref = Timeout.prototype.ref = function() {};
+Timeout.prototype.close = function() {
+ this._clearFn.call(window, this._id);
+};
-/**
- * Normalize the given path string, returning a regular expression.
- *
- * An empty array can be passed in for the keys, which will hold the
- * placeholder key descriptions. For example, using `/user/:id`, `keys` will
- * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
- *
- * @param {(string|RegExp|Array)} path
- * @param {(Array|Object)=} keys
- * @param {Object=} options
- * @return {!RegExp}
- */
-function pathToRegexp (path, keys, options) {
- if (!isarray(keys)) {
- options = /** @type {!Object} */ (keys || options)
- keys = []
- }
+// Does not start the time, just sets up the members needed.
+exports.enroll = function(item, msecs) {
+ clearTimeout(item._idleTimeoutId);
+ item._idleTimeout = msecs;
+};
- options = options || {}
+exports.unenroll = function(item) {
+ clearTimeout(item._idleTimeoutId);
+ item._idleTimeout = -1;
+};
- if (path instanceof RegExp) {
- return regexpToRegexp(path, /** @type {!Array} */ (keys))
- }
+exports._unrefActive = exports.active = function(item) {
+ clearTimeout(item._idleTimeoutId);
- if (isarray(path)) {
- return arrayToRegexp(/** @type {!Array} */ (path), /** @type {!Array} */ (keys), options)
+ var msecs = item._idleTimeout;
+ if (msecs >= 0) {
+ item._idleTimeoutId = setTimeout(function onTimeout() {
+ if (item._onTimeout)
+ item._onTimeout();
+ }, msecs);
}
+};
- return stringToRegexp(/** @type {string} */ (path), /** @type {!Array} */ (keys), options)
-}
+// That's not how node.js implements it but the exposed api is the same.
+exports.setImmediate = typeof setImmediate === "function" ? setImmediate : function(fn) {
+ var id = nextImmediateId++;
+ var args = arguments.length < 2 ? false : slice.call(arguments, 1);
+
+ immediateIds[id] = true;
+
+ nextTick(function onNextTick() {
+ if (immediateIds[id]) {
+ // fn.call() is faster so we optimize for the common use-case
+ // @see http://jsperf.com/call-apply-segu
+ if (args) {
+ fn.apply(null, args);
+ } else {
+ fn.call(null);
+ }
+ // Prevent ids from leaking
+ exports.clearImmediate(id);
+ }
+ });
-},{"isarray":36}],39:[function(require,module,exports){
+ return id;
+};
+
+exports.clearImmediate = typeof clearImmediate === "function" ? clearImmediate : function(id) {
+ delete immediateIds[id];
+};
+},{"process/browser.js":55}],57:[function(require,module,exports){
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
@@ -8103,39 +9361,350 @@ return typeDetect;
})));
-},{}],40:[function(require,module,exports){
-if (typeof Object.create === 'function') {
- // implementation from standard node.js 'util' module
- module.exports = function inherits(ctor, superCtor) {
- ctor.super_ = superCtor
- ctor.prototype = Object.create(superCtor.prototype, {
- constructor: {
- value: ctor,
- enumerable: false,
- writable: true,
- configurable: true
- }
- });
- };
-} else {
- // old school shim for old browsers
- module.exports = function inherits(ctor, superCtor) {
- ctor.super_ = superCtor
- var TempCtor = function () {}
- TempCtor.prototype = superCtor.prototype
- ctor.prototype = new TempCtor()
- ctor.prototype.constructor = ctor
- }
-}
-
-},{}],41:[function(require,module,exports){
+},{}],58:[function(require,module,exports){
module.exports = function isBuffer(arg) {
return arg && typeof arg === 'object'
&& typeof arg.copy === 'function'
&& typeof arg.fill === 'function'
&& typeof arg.readUInt8 === 'function';
}
-},{}],42:[function(require,module,exports){
+},{}],59:[function(require,module,exports){
+// Currently in sync with Node.js lib/internal/util/types.js
+// https://github.com/nodejs/node/commit/112cc7c27551254aa2b17098fb774867f05ed0d9
+
+'use strict';
+
+var isArgumentsObject = require('is-arguments');
+var isGeneratorFunction = require('is-generator-function');
+var whichTypedArray = require('which-typed-array');
+var isTypedArray = require('is-typed-array');
+
+function uncurryThis(f) {
+ return f.call.bind(f);
+}
+
+var BigIntSupported = typeof BigInt !== 'undefined';
+var SymbolSupported = typeof Symbol !== 'undefined';
+
+var ObjectToString = uncurryThis(Object.prototype.toString);
+
+var numberValue = uncurryThis(Number.prototype.valueOf);
+var stringValue = uncurryThis(String.prototype.valueOf);
+var booleanValue = uncurryThis(Boolean.prototype.valueOf);
+
+if (BigIntSupported) {
+ var bigIntValue = uncurryThis(BigInt.prototype.valueOf);
+}
+
+if (SymbolSupported) {
+ var symbolValue = uncurryThis(Symbol.prototype.valueOf);
+}
+
+function checkBoxedPrimitive(value, prototypeValueOf) {
+ if (typeof value !== 'object') {
+ return false;
+ }
+ try {
+ prototypeValueOf(value);
+ return true;
+ } catch(e) {
+ return false;
+ }
+}
+
+exports.isArgumentsObject = isArgumentsObject;
+exports.isGeneratorFunction = isGeneratorFunction;
+exports.isTypedArray = isTypedArray;
+
+// Taken from here and modified for better browser support
+// https://github.com/sindresorhus/p-is-promise/blob/cda35a513bda03f977ad5cde3a079d237e82d7ef/index.js
+function isPromise(input) {
+ return (
+ (
+ typeof Promise !== 'undefined' &&
+ input instanceof Promise
+ ) ||
+ (
+ input !== null &&
+ typeof input === 'object' &&
+ typeof input.then === 'function' &&
+ typeof input.catch === 'function'
+ )
+ );
+}
+exports.isPromise = isPromise;
+
+function isArrayBufferView(value) {
+ if (typeof ArrayBuffer !== 'undefined' && ArrayBuffer.isView) {
+ return ArrayBuffer.isView(value);
+ }
+
+ return (
+ isTypedArray(value) ||
+ isDataView(value)
+ );
+}
+exports.isArrayBufferView = isArrayBufferView;
+
+
+function isUint8Array(value) {
+ return whichTypedArray(value) === 'Uint8Array';
+}
+exports.isUint8Array = isUint8Array;
+
+function isUint8ClampedArray(value) {
+ return whichTypedArray(value) === 'Uint8ClampedArray';
+}
+exports.isUint8ClampedArray = isUint8ClampedArray;
+
+function isUint16Array(value) {
+ return whichTypedArray(value) === 'Uint16Array';
+}
+exports.isUint16Array = isUint16Array;
+
+function isUint32Array(value) {
+ return whichTypedArray(value) === 'Uint32Array';
+}
+exports.isUint32Array = isUint32Array;
+
+function isInt8Array(value) {
+ return whichTypedArray(value) === 'Int8Array';
+}
+exports.isInt8Array = isInt8Array;
+
+function isInt16Array(value) {
+ return whichTypedArray(value) === 'Int16Array';
+}
+exports.isInt16Array = isInt16Array;
+
+function isInt32Array(value) {
+ return whichTypedArray(value) === 'Int32Array';
+}
+exports.isInt32Array = isInt32Array;
+
+function isFloat32Array(value) {
+ return whichTypedArray(value) === 'Float32Array';
+}
+exports.isFloat32Array = isFloat32Array;
+
+function isFloat64Array(value) {
+ return whichTypedArray(value) === 'Float64Array';
+}
+exports.isFloat64Array = isFloat64Array;
+
+function isBigInt64Array(value) {
+ return whichTypedArray(value) === 'BigInt64Array';
+}
+exports.isBigInt64Array = isBigInt64Array;
+
+function isBigUint64Array(value) {
+ return whichTypedArray(value) === 'BigUint64Array';
+}
+exports.isBigUint64Array = isBigUint64Array;
+
+function isMapToString(value) {
+ return ObjectToString(value) === '[object Map]';
+}
+isMapToString.working = (
+ typeof Map !== 'undefined' &&
+ isMapToString(new Map())
+);
+
+function isMap(value) {
+ if (typeof Map === 'undefined') {
+ return false;
+ }
+
+ return isMapToString.working
+ ? isMapToString(value)
+ : value instanceof Map;
+}
+exports.isMap = isMap;
+
+function isSetToString(value) {
+ return ObjectToString(value) === '[object Set]';
+}
+isSetToString.working = (
+ typeof Set !== 'undefined' &&
+ isSetToString(new Set())
+);
+function isSet(value) {
+ if (typeof Set === 'undefined') {
+ return false;
+ }
+
+ return isSetToString.working
+ ? isSetToString(value)
+ : value instanceof Set;
+}
+exports.isSet = isSet;
+
+function isWeakMapToString(value) {
+ return ObjectToString(value) === '[object WeakMap]';
+}
+isWeakMapToString.working = (
+ typeof WeakMap !== 'undefined' &&
+ isWeakMapToString(new WeakMap())
+);
+function isWeakMap(value) {
+ if (typeof WeakMap === 'undefined') {
+ return false;
+ }
+
+ return isWeakMapToString.working
+ ? isWeakMapToString(value)
+ : value instanceof WeakMap;
+}
+exports.isWeakMap = isWeakMap;
+
+function isWeakSetToString(value) {
+ return ObjectToString(value) === '[object WeakSet]';
+}
+isWeakSetToString.working = (
+ typeof WeakSet !== 'undefined' &&
+ isWeakSetToString(new WeakSet())
+);
+function isWeakSet(value) {
+ return isWeakSetToString(value);
+}
+exports.isWeakSet = isWeakSet;
+
+function isArrayBufferToString(value) {
+ return ObjectToString(value) === '[object ArrayBuffer]';
+}
+isArrayBufferToString.working = (
+ typeof ArrayBuffer !== 'undefined' &&
+ isArrayBufferToString(new ArrayBuffer())
+);
+function isArrayBuffer(value) {
+ if (typeof ArrayBuffer === 'undefined') {
+ return false;
+ }
+
+ return isArrayBufferToString.working
+ ? isArrayBufferToString(value)
+ : value instanceof ArrayBuffer;
+}
+exports.isArrayBuffer = isArrayBuffer;
+
+function isDataViewToString(value) {
+ return ObjectToString(value) === '[object DataView]';
+}
+isDataViewToString.working = (
+ typeof ArrayBuffer !== 'undefined' &&
+ typeof DataView !== 'undefined' &&
+ isDataViewToString(new DataView(new ArrayBuffer(1), 0, 1))
+);
+function isDataView(value) {
+ if (typeof DataView === 'undefined') {
+ return false;
+ }
+
+ return isDataViewToString.working
+ ? isDataViewToString(value)
+ : value instanceof DataView;
+}
+exports.isDataView = isDataView;
+
+// Store a copy of SharedArrayBuffer in case it's deleted elsewhere
+var SharedArrayBufferCopy = typeof SharedArrayBuffer !== 'undefined' ? SharedArrayBuffer : undefined;
+function isSharedArrayBufferToString(value) {
+ return ObjectToString(value) === '[object SharedArrayBuffer]';
+}
+function isSharedArrayBuffer(value) {
+ if (typeof SharedArrayBufferCopy === 'undefined') {
+ return false;
+ }
+
+ if (typeof isSharedArrayBufferToString.working === 'undefined') {
+ isSharedArrayBufferToString.working = isSharedArrayBufferToString(new SharedArrayBufferCopy());
+ }
+
+ return isSharedArrayBufferToString.working
+ ? isSharedArrayBufferToString(value)
+ : value instanceof SharedArrayBufferCopy;
+}
+exports.isSharedArrayBuffer = isSharedArrayBuffer;
+
+function isAsyncFunction(value) {
+ return ObjectToString(value) === '[object AsyncFunction]';
+}
+exports.isAsyncFunction = isAsyncFunction;
+
+function isMapIterator(value) {
+ return ObjectToString(value) === '[object Map Iterator]';
+}
+exports.isMapIterator = isMapIterator;
+
+function isSetIterator(value) {
+ return ObjectToString(value) === '[object Set Iterator]';
+}
+exports.isSetIterator = isSetIterator;
+
+function isGeneratorObject(value) {
+ return ObjectToString(value) === '[object Generator]';
+}
+exports.isGeneratorObject = isGeneratorObject;
+
+function isWebAssemblyCompiledModule(value) {
+ return ObjectToString(value) === '[object WebAssembly.Module]';
+}
+exports.isWebAssemblyCompiledModule = isWebAssemblyCompiledModule;
+
+function isNumberObject(value) {
+ return checkBoxedPrimitive(value, numberValue);
+}
+exports.isNumberObject = isNumberObject;
+
+function isStringObject(value) {
+ return checkBoxedPrimitive(value, stringValue);
+}
+exports.isStringObject = isStringObject;
+
+function isBooleanObject(value) {
+ return checkBoxedPrimitive(value, booleanValue);
+}
+exports.isBooleanObject = isBooleanObject;
+
+function isBigIntObject(value) {
+ return BigIntSupported && checkBoxedPrimitive(value, bigIntValue);
+}
+exports.isBigIntObject = isBigIntObject;
+
+function isSymbolObject(value) {
+ return SymbolSupported && checkBoxedPrimitive(value, symbolValue);
+}
+exports.isSymbolObject = isSymbolObject;
+
+function isBoxedPrimitive(value) {
+ return (
+ isNumberObject(value) ||
+ isStringObject(value) ||
+ isBooleanObject(value) ||
+ isBigIntObject(value) ||
+ isSymbolObject(value)
+ );
+}
+exports.isBoxedPrimitive = isBoxedPrimitive;
+
+function isAnyArrayBuffer(value) {
+ return typeof Uint8Array !== 'undefined' && (
+ isArrayBuffer(value) ||
+ isSharedArrayBuffer(value)
+ );
+}
+exports.isAnyArrayBuffer = isAnyArrayBuffer;
+
+['isProxy', 'isExternal', 'isModuleNamespaceObject'].forEach(function(method) {
+ Object.defineProperty(exports, method, {
+ enumerable: false,
+ value: function() {
+ throw new Error(method + ' is not supported in userland');
+ }
+ });
+});
+
+},{"is-arguments":49,"is-generator-function":51,"is-typed-array":52,"which-typed-array":61}],60:[function(require,module,exports){
// Copyright Joyent, Inc. and other Node contributors.
//
// Permission is hereby granted, free of charge, to any person obtaining a
@@ -8157,6 +9726,16 @@ module.exports = function isBuffer(arg) {
// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
// USE OR OTHER DEALINGS IN THE SOFTWARE.
+var getOwnPropertyDescriptors = Object.getOwnPropertyDescriptors ||
+ function getOwnPropertyDescriptors(obj) {
+ var keys = Object.keys(obj);
+ var descriptors = {};
+ for (var i = 0; i < keys.length; i++) {
+ descriptors[keys[i]] = Object.getOwnPropertyDescriptor(obj, keys[i]);
+ }
+ return descriptors;
+ };
+
var formatRegExp = /%[sdj%]/g;
exports.format = function(f) {
if (!isString(f)) {
@@ -8201,17 +9780,17 @@ exports.format = function(f) {
// Returns a modified function which warns once by default.
// If --no-deprecation is set, then it is a no-op.
exports.deprecate = function(fn, msg) {
+ if (typeof process !== 'undefined' && process.noDeprecation === true) {
+ return fn;
+ }
+
// Allow for deprecating things in the process of starting up.
- if (isUndefined(global.process)) {
+ if (typeof process === 'undefined') {
return function() {
return exports.deprecate(fn, msg).apply(this, arguments);
};
}
- if (process.noDeprecation === true) {
- return fn;
- }
-
var warned = false;
function deprecated() {
if (!warned) {
@@ -8232,13 +9811,20 @@ exports.deprecate = function(fn, msg) {
var debugs = {};
-var debugEnviron;
+var debugEnvRegex = /^$/;
+
+if (process.env.NODE_DEBUG) {
+ var debugEnv = process.env.NODE_DEBUG;
+ debugEnv = debugEnv.replace(/[|\\{}()[\]^$+?.]/g, '\\$&')
+ .replace(/\*/g, '.*')
+ .replace(/,/g, '$|^')
+ .toUpperCase();
+ debugEnvRegex = new RegExp('^' + debugEnv + '$', 'i');
+}
exports.debuglog = function(set) {
- if (isUndefined(debugEnviron))
- debugEnviron = process.env.NODE_DEBUG || '';
set = set.toUpperCase();
if (!debugs[set]) {
- if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {
+ if (debugEnvRegex.test(set)) {
var pid = process.pid;
debugs[set] = function() {
var msg = exports.format.apply(exports, arguments);
@@ -8531,7 +10117,7 @@ function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
if (array) {
str = str.split('\n').map(function(line) {
return ' ' + line;
- }).join('\n').substr(2);
+ }).join('\n').slice(2);
} else {
str = '\n' + str.split('\n').map(function(line) {
return ' ' + line;
@@ -8548,7 +10134,7 @@ function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
}
name = JSON.stringify('' + key);
if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {
- name = name.substr(1, name.length - 2);
+ name = name.slice(1, -1);
name = ctx.stylize(name, 'name');
} else {
name = name.replace(/'/g, "\\'")
@@ -8585,6 +10171,8 @@ function reduceToSingleString(output, base, braces) {
// NOTE: These type checking functions intentionally don't use `instanceof`
// because it is fragile and can be easily faked with `Object.create()`.
+exports.types = require('./support/types');
+
function isArray(ar) {
return Array.isArray(ar);
}
@@ -8629,6 +10217,7 @@ function isRegExp(re) {
return isObject(re) && objectToString(re) === '[object RegExp]';
}
exports.isRegExp = isRegExp;
+exports.types.isRegExp = isRegExp;
function isObject(arg) {
return typeof arg === 'object' && arg !== null;
@@ -8639,12 +10228,14 @@ function isDate(d) {
return isObject(d) && objectToString(d) === '[object Date]';
}
exports.isDate = isDate;
+exports.types.isDate = isDate;
function isError(e) {
return isObject(e) &&
(objectToString(e) === '[object Error]' || e instanceof Error);
}
exports.isError = isError;
+exports.types.isNativeError = isError;
function isFunction(arg) {
return typeof arg === 'function';
@@ -8723,5 +10314,169 @@ function hasOwnProperty(obj, prop) {
return Object.prototype.hasOwnProperty.call(obj, prop);
}
-},{"./support/isBuffer":41,"inherits":40}]},{},[12])(12)
+var kCustomPromisifiedSymbol = typeof Symbol !== 'undefined' ? Symbol('util.promisify.custom') : undefined;
+
+exports.promisify = function promisify(original) {
+ if (typeof original !== 'function')
+ throw new TypeError('The "original" argument must be of type Function');
+
+ if (kCustomPromisifiedSymbol && original[kCustomPromisifiedSymbol]) {
+ var fn = original[kCustomPromisifiedSymbol];
+ if (typeof fn !== 'function') {
+ throw new TypeError('The "util.promisify.custom" argument must be of type Function');
+ }
+ Object.defineProperty(fn, kCustomPromisifiedSymbol, {
+ value: fn, enumerable: false, writable: false, configurable: true
+ });
+ return fn;
+ }
+
+ function fn() {
+ var promiseResolve, promiseReject;
+ var promise = new Promise(function (resolve, reject) {
+ promiseResolve = resolve;
+ promiseReject = reject;
+ });
+
+ var args = [];
+ for (var i = 0; i < arguments.length; i++) {
+ args.push(arguments[i]);
+ }
+ args.push(function (err, value) {
+ if (err) {
+ promiseReject(err);
+ } else {
+ promiseResolve(value);
+ }
+ });
+
+ try {
+ original.apply(this, args);
+ } catch (err) {
+ promiseReject(err);
+ }
+
+ return promise;
+ }
+
+ Object.setPrototypeOf(fn, Object.getPrototypeOf(original));
+
+ if (kCustomPromisifiedSymbol) Object.defineProperty(fn, kCustomPromisifiedSymbol, {
+ value: fn, enumerable: false, writable: false, configurable: true
+ });
+ return Object.defineProperties(
+ fn,
+ getOwnPropertyDescriptors(original)
+ );
+}
+
+exports.promisify.custom = kCustomPromisifiedSymbol
+
+function callbackifyOnRejected(reason, cb) {
+ // `!reason` guard inspired by bluebird (Ref: https://goo.gl/t5IS6M).
+ // Because `null` is a special error value in callbacks which means "no error
+ // occurred", we error-wrap so the callback consumer can distinguish between
+ // "the promise rejected with null" or "the promise fulfilled with undefined".
+ if (!reason) {
+ var newReason = new Error('Promise was rejected with a falsy value');
+ newReason.reason = reason;
+ reason = newReason;
+ }
+ return cb(reason);
+}
+
+function callbackify(original) {
+ if (typeof original !== 'function') {
+ throw new TypeError('The "original" argument must be of type Function');
+ }
+
+ // We DO NOT return the promise as it gives the user a false sense that
+ // the promise is actually somehow related to the callback's execution
+ // and that the callback throwing will reject the promise.
+ function callbackified() {
+ var args = [];
+ for (var i = 0; i < arguments.length; i++) {
+ args.push(arguments[i]);
+ }
+
+ var maybeCb = args.pop();
+ if (typeof maybeCb !== 'function') {
+ throw new TypeError('The last argument must be of type Function');
+ }
+ var self = this;
+ var cb = function() {
+ return maybeCb.apply(self, arguments);
+ };
+ // In true node style we process the callback on `nextTick` with all the
+ // implications (stack, `uncaughtException`, `async_hooks`)
+ original.apply(this, args)
+ .then(function(ret) { process.nextTick(cb.bind(null, null, ret)) },
+ function(rej) { process.nextTick(callbackifyOnRejected.bind(null, rej, cb)) });
+ }
+
+ Object.setPrototypeOf(callbackified, Object.getPrototypeOf(original));
+ Object.defineProperties(callbackified,
+ getOwnPropertyDescriptors(original));
+ return callbackified;
+}
+exports.callbackify = callbackify;
+
+},{"./support/isBuffer":58,"./support/types":59,"inherits":48}],61:[function(require,module,exports){
+'use strict';
+
+var forEach = require('for-each');
+var availableTypedArrays = require('available-typed-arrays');
+var callBound = require('call-bind/callBound');
+var gOPD = require('gopd');
+
+var $toString = callBound('Object.prototype.toString');
+var hasToStringTag = require('has-tostringtag/shams')();
+
+var g = typeof globalThis === 'undefined' ? global : globalThis;
+var typedArrays = availableTypedArrays();
+
+var $slice = callBound('String.prototype.slice');
+var toStrTags = {};
+var getPrototypeOf = Object.getPrototypeOf; // require('getprototypeof');
+if (hasToStringTag && gOPD && getPrototypeOf) {
+ forEach(typedArrays, function (typedArray) {
+ if (typeof g[typedArray] === 'function') {
+ var arr = new g[typedArray]();
+ if (Symbol.toStringTag in arr) {
+ var proto = getPrototypeOf(arr);
+ var descriptor = gOPD(proto, Symbol.toStringTag);
+ if (!descriptor) {
+ var superProto = getPrototypeOf(proto);
+ descriptor = gOPD(superProto, Symbol.toStringTag);
+ }
+ toStrTags[typedArray] = descriptor.get;
+ }
+ }
+ });
+}
+
+var tryTypedArrays = function tryAllTypedArrays(value) {
+ var foundName = false;
+ forEach(toStrTags, function (getter, typedArray) {
+ if (!foundName) {
+ try {
+ var name = getter.call(value);
+ if (name === typedArray) {
+ foundName = name;
+ }
+ } catch (e) {}
+ }
+ });
+ return foundName;
+};
+
+var isTypedArray = require('is-typed-array');
+
+module.exports = function whichTypedArray(value) {
+ if (!isTypedArray(value)) { return false; }
+ if (!hasToStringTag || !(Symbol.toStringTag in value)) { return $slice($toString(value), 8, -1); }
+ return tryTypedArrays(value);
+};
+
+},{"available-typed-arrays":36,"call-bind/callBound":37,"for-each":39,"gopd":43,"has-tostringtag/shams":46,"is-typed-array":52}]},{},[12])(12)
});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/called-in-order.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/called-in-order.js
index 4edb67fa..cdbbb3f2 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/called-in-order.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/called-in-order.js
@@ -33,7 +33,6 @@ function checkAdjacentCalls(callMap, spy, index, spies) {
/**
* A Sinon proxy object (fake, spy, stub)
- *
* @typedef {object} SinonProxy
* @property {Function} calledBefore - A method that determines if this proxy was called before another one
* @property {string} id - Some id
@@ -42,7 +41,6 @@ function checkAdjacentCalls(callMap, spy, index, spies) {
/**
* Returns true when the spies have been called in the order they were supplied in
- *
* @param {SinonProxy[] | SinonProxy} spies An array of proxies, or several proxies as arguments
* @returns {boolean} true when spies are called in order, false otherwise
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/class-name.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/class-name.js
index bcd26bae..a125e53d 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/class-name.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/class-name.js
@@ -1,27 +1,13 @@
"use strict";
-var functionName = require("./function-name");
-
/**
* Returns a display name for a value from a constructor
- *
* @param {object} value A value to examine
* @returns {(string|null)} A string or null
*/
function className(value) {
- return (
- (value.constructor && value.constructor.name) ||
- // The next branch is for IE11 support only:
- // Because the name property is not set on the prototype
- // of the Function object, we finally try to grab the
- // name from its definition. This will never be reached
- // in node, so we are not able to test this properly.
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/name
- (typeof value.constructor === "function" &&
- /* istanbul ignore next */
- functionName(value.constructor)) ||
- null
- );
+ const name = value.constructor && value.constructor.name;
+ return name || null;
}
module.exports = className;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/deprecated.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/deprecated.js
index 42227254..9957f79c 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/deprecated.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/deprecated.js
@@ -4,7 +4,6 @@
/**
* Returns a function that will invoke the supplied function and print a
* deprecation warning to the console each time it is called.
- *
* @param {Function} func
* @param {string} msg
* @returns {Function}
@@ -23,7 +22,6 @@ exports.wrap = function (func, msg) {
/**
* Returns a string which can be supplied to `wrap()` to notify the user that a
* particular part of the sinon API has been deprecated.
- *
* @param {string} packageName
* @param {string} funcName
* @returns {string}
@@ -34,7 +32,6 @@ exports.defaultMsg = function (packageName, funcName) {
/**
* Prints a warning on the console, when it exists
- *
* @param {string} msg
* @returns {undefined}
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/every.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/every.js
index 00bf304e..91b8419a 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/every.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/every.js
@@ -3,7 +3,6 @@
/**
* Returns true when fn returns true for all members of obj.
* This is an every implementation that works for all iterables
- *
* @param {object} obj
* @param {Function} fn
* @returns {boolean}
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/function-name.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/function-name.js
index 199b04e0..2ecf981d 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/function-name.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/function-name.js
@@ -2,7 +2,6 @@
/**
* Returns a display name for a function
- *
* @param {Function} func
* @returns {string}
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/global.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/global.js
index 51715a27..ac5edb3f 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/global.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/global.js
@@ -2,7 +2,6 @@
/**
* A reference to the global object
- *
* @type {object} globalObject
*/
var globalObject;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/order-by-first-call.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/order-by-first-call.js
index c3d47edf..26826cbd 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/order-by-first-call.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/order-by-first-call.js
@@ -18,14 +18,12 @@ function comparator(a, b) {
/**
* A Sinon proxy object (fake, spy, stub)
- *
* @typedef {object} SinonProxy
* @property {Function} getCall - A method that can return the first call
*/
/**
* Sorts an array of SinonProxy instances (fake, spy, stub) by their first call
- *
* @param {SinonProxy[] | SinonProxy} spies
* @returns {SinonProxy[]}
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/prototypes/throws-on-proto.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/prototypes/throws-on-proto.js
index eb7a189b..d77ab4a6 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/prototypes/throws-on-proto.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/prototypes/throws-on-proto.js
@@ -3,11 +3,9 @@
/**
* Is true when the environment causes an error to be thrown for accessing the
* __proto__ property.
- *
* This is necessary in order to support `node --disable-proto=throw`.
*
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/proto
- *
* @type {boolean}
*/
let throwsOnProto;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/type-of.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/type-of.js
index 97a0bb9c..40b92151 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/type-of.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/type-of.js
@@ -4,7 +4,6 @@ var type = require("type-detect");
/**
* Returns the lower-case result of running type from type-detect on the value
- *
* @param {*} value
* @returns {string}
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/value-to-string.js b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/value-to-string.js
index fb14782b..303f6571 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/lib/value-to-string.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/lib/value-to-string.js
@@ -2,7 +2,6 @@
/**
* Returns a string representation of the value
- *
* @param {*} value
* @returns {string}
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/package.json b/build/node_modules/nise/node_modules/@sinonjs/commons/package.json
index 9b68bf26..97610454 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/package.json
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/package.json
@@ -1,6 +1,6 @@
{
"name": "@sinonjs/commons",
- "version": "2.0.0",
+ "version": "3.0.1",
"description": "Simple functions shared among the sinon end user libraries",
"main": "lib/index.js",
"types": "./types/index.d.ts",
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/types/called-in-order.d.ts b/build/node_modules/nise/node_modules/@sinonjs/commons/types/called-in-order.d.ts
index 1a4508be..ad528871 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/types/called-in-order.d.ts
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/types/called-in-order.d.ts
@@ -1,7 +1,6 @@
export = calledInOrder;
/**
* A Sinon proxy object (fake, spy, stub)
- *
* @typedef {object} SinonProxy
* @property {Function} calledBefore - A method that determines if this proxy was called before another one
* @property {string} id - Some id
@@ -9,7 +8,6 @@ export = calledInOrder;
*/
/**
* Returns true when the spies have been called in the order they were supplied in
- *
* @param {SinonProxy[] | SinonProxy} spies An array of proxies, or several proxies as arguments
* @returns {boolean} true when spies are called in order, false otherwise
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/types/class-name.d.ts b/build/node_modules/nise/node_modules/@sinonjs/commons/types/class-name.d.ts
index df3687b9..58d8284b 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/types/class-name.d.ts
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/types/class-name.d.ts
@@ -1,7 +1,6 @@
export = className;
/**
* Returns a display name for a value from a constructor
- *
* @param {object} value A value to examine
* @returns {(string|null)} A string or null
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/types/global.d.ts b/build/node_modules/nise/node_modules/@sinonjs/commons/types/global.d.ts
index 0f54a635..20c67841 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/types/global.d.ts
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/types/global.d.ts
@@ -1,7 +1,6 @@
export = globalObject;
/**
* A reference to the global object
- *
* @type {object} globalObject
*/
declare var globalObject: object;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/types/order-by-first-call.d.ts b/build/node_modules/nise/node_modules/@sinonjs/commons/types/order-by-first-call.d.ts
index a9a6037d..834c7a52 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/types/order-by-first-call.d.ts
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/types/order-by-first-call.d.ts
@@ -1,13 +1,11 @@
export = orderByFirstCall;
/**
* A Sinon proxy object (fake, spy, stub)
- *
* @typedef {object} SinonProxy
* @property {Function} getCall - A method that can return the first call
*/
/**
* Sorts an array of SinonProxy instances (fake, spy, stub) by their first call
- *
* @param {SinonProxy[] | SinonProxy} spies
* @returns {SinonProxy[]}
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/types/prototypes/throws-on-proto.d.ts b/build/node_modules/nise/node_modules/@sinonjs/commons/types/prototypes/throws-on-proto.d.ts
index 6cc97f4a..2ec7145c 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/types/prototypes/throws-on-proto.d.ts
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/types/prototypes/throws-on-proto.d.ts
@@ -2,11 +2,9 @@ export = throwsOnProto;
/**
* Is true when the environment causes an error to be thrown for accessing the
* __proto__ property.
- *
* This is necessary in order to support `node --disable-proto=throw`.
*
* See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/proto
- *
* @type {boolean}
*/
declare let throwsOnProto: boolean;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/commons/types/value-to-string.d.ts b/build/node_modules/nise/node_modules/@sinonjs/commons/types/value-to-string.d.ts
index 19b086cd..827caf81 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/commons/types/value-to-string.d.ts
+++ b/build/node_modules/nise/node_modules/@sinonjs/commons/types/value-to-string.d.ts
@@ -1,7 +1,6 @@
export = valueToString;
/**
* Returns a string representation of the value
- *
* @param {*} value
* @returns {string}
*/
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/README.md b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/README.md
index 049f0672..6bdcb920 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/README.md
+++ b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/README.md
@@ -43,7 +43,7 @@ var clock = FakeTimers.createClock();
clock.setTimeout(function () {
console.log(
- "The poblano is a mild chili pepper originating in the state of Puebla, Mexico."
+ "The poblano is a mild chili pepper originating in the state of Puebla, Mexico.",
);
}, 15);
@@ -67,6 +67,7 @@ clock instance, not the browser's internals.
Calling `install` with no arguments achieves this. You can call `uninstall`
later to restore things as they were again.
+Note that in NodeJS also the [timers](https://nodejs.org/api/timers.html) module will receive fake timers when using global scope.
```js
// In the browser distribution, a global `FakeTimers` is already available
@@ -146,7 +147,9 @@ The `loopLimit` argument sets the maximum number of timers that will be run when
### `var clock = FakeTimers.install([config])`
-Installs FakeTimers using the specified config (otherwise with epoch `0` on the global scope). The following configuration options are available
+Installs FakeTimers using the specified config (otherwise with epoch `0` on the global scope).
+Note that in NodeJS also the [timers](https://nodejs.org/api/timers.html) module will receive fake timers when using global scope.
+The following configuration options are available
| Parameter | Type | Default | Description |
| -------------------------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/LICENSE b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/LICENSE
deleted file mode 100644
index 5a77f0a2..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/LICENSE
+++ /dev/null
@@ -1,29 +0,0 @@
-BSD 3-Clause License
-
-Copyright (c) 2018, Sinon.JS
-All rights reserved.
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions are met:
-
-* Redistributions of source code must retain the above copyright notice, this
- list of conditions and the following disclaimer.
-
-* Redistributions in binary form must reproduce the above copyright notice,
- this list of conditions and the following disclaimer in the documentation
- and/or other materials provided with the distribution.
-
-* Neither the name of the copyright holder nor the names of its
- contributors may be used to endorse or promote products derived from
- this software without specific prior written permission.
-
-THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
-FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
-SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
-CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
-OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
-OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/README.md b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/README.md
deleted file mode 100644
index 9c420ba5..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/README.md
+++ /dev/null
@@ -1,16 +0,0 @@
-# commons
-
-[![CircleCI](https://circleci.com/gh/sinonjs/commons.svg?style=svg)](https://circleci.com/gh/sinonjs/commons)
-[![codecov](https://codecov.io/gh/sinonjs/commons/branch/master/graph/badge.svg)](https://codecov.io/gh/sinonjs/commons)
-
-
-Simple functions shared among the sinon end user libraries
-
-## Rules
-
-- Follows the [Sinon.JS compatibility](https://github.com/sinonjs/sinon/blob/master/CONTRIBUTING.md#compatibility)
-- 100% test coverage
-- Code formatted using [Prettier](https://prettier.io)
-- No side effects welcome! (only pure functions)
-- No platform specific functions
-- One export per file (any bundler can do tree shaking)
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/called-in-order.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/called-in-order.js
deleted file mode 100644
index 4edb67fa..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/called-in-order.js
+++ /dev/null
@@ -1,57 +0,0 @@
-"use strict";
-
-var every = require("./prototypes/array").every;
-
-/**
- * @private
- */
-function hasCallsLeft(callMap, spy) {
- if (callMap[spy.id] === undefined) {
- callMap[spy.id] = 0;
- }
-
- return callMap[spy.id] < spy.callCount;
-}
-
-/**
- * @private
- */
-function checkAdjacentCalls(callMap, spy, index, spies) {
- var calledBeforeNext = true;
-
- if (index !== spies.length - 1) {
- calledBeforeNext = spy.calledBefore(spies[index + 1]);
- }
-
- if (hasCallsLeft(callMap, spy) && calledBeforeNext) {
- callMap[spy.id] += 1;
- return true;
- }
-
- return false;
-}
-
-/**
- * A Sinon proxy object (fake, spy, stub)
- *
- * @typedef {object} SinonProxy
- * @property {Function} calledBefore - A method that determines if this proxy was called before another one
- * @property {string} id - Some id
- * @property {number} callCount - Number of times this proxy has been called
- */
-
-/**
- * Returns true when the spies have been called in the order they were supplied in
- *
- * @param {SinonProxy[] | SinonProxy} spies An array of proxies, or several proxies as arguments
- * @returns {boolean} true when spies are called in order, false otherwise
- */
-function calledInOrder(spies) {
- var callMap = {};
- // eslint-disable-next-line no-underscore-dangle
- var _spies = arguments.length > 1 ? arguments : spies;
-
- return every(_spies, checkAdjacentCalls.bind(null, callMap));
-}
-
-module.exports = calledInOrder;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/called-in-order.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/called-in-order.test.js
deleted file mode 100644
index 5fe66118..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/called-in-order.test.js
+++ /dev/null
@@ -1,121 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var calledInOrder = require("./called-in-order");
-var sinon = require("@sinonjs/referee-sinon").sinon;
-
-var testObject1 = {
- someFunction: function () {
- return;
- },
-};
-var testObject2 = {
- otherFunction: function () {
- return;
- },
-};
-var testObject3 = {
- thirdFunction: function () {
- return;
- },
-};
-
-function testMethod() {
- testObject1.someFunction();
- testObject2.otherFunction();
- testObject2.otherFunction();
- testObject2.otherFunction();
- testObject3.thirdFunction();
-}
-
-describe("calledInOrder", function () {
- beforeEach(function () {
- sinon.stub(testObject1, "someFunction");
- sinon.stub(testObject2, "otherFunction");
- sinon.stub(testObject3, "thirdFunction");
- testMethod();
- });
- afterEach(function () {
- testObject1.someFunction.restore();
- testObject2.otherFunction.restore();
- testObject3.thirdFunction.restore();
- });
-
- describe("given single array argument", function () {
- describe("when stubs were called in expected order", function () {
- it("returns true", function () {
- assert.isTrue(
- calledInOrder([
- testObject1.someFunction,
- testObject2.otherFunction,
- ])
- );
- assert.isTrue(
- calledInOrder([
- testObject1.someFunction,
- testObject2.otherFunction,
- testObject2.otherFunction,
- testObject3.thirdFunction,
- ])
- );
- });
- });
-
- describe("when stubs were called in unexpected order", function () {
- it("returns false", function () {
- assert.isFalse(
- calledInOrder([
- testObject2.otherFunction,
- testObject1.someFunction,
- ])
- );
- assert.isFalse(
- calledInOrder([
- testObject2.otherFunction,
- testObject1.someFunction,
- testObject1.someFunction,
- testObject3.thirdFunction,
- ])
- );
- });
- });
- });
-
- describe("given multiple arguments", function () {
- describe("when stubs were called in expected order", function () {
- it("returns true", function () {
- assert.isTrue(
- calledInOrder(
- testObject1.someFunction,
- testObject2.otherFunction
- )
- );
- assert.isTrue(
- calledInOrder(
- testObject1.someFunction,
- testObject2.otherFunction,
- testObject3.thirdFunction
- )
- );
- });
- });
-
- describe("when stubs were called in unexpected order", function () {
- it("returns false", function () {
- assert.isFalse(
- calledInOrder(
- testObject2.otherFunction,
- testObject1.someFunction
- )
- );
- assert.isFalse(
- calledInOrder(
- testObject2.otherFunction,
- testObject1.someFunction,
- testObject3.thirdFunction
- )
- );
- });
- });
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/class-name.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/class-name.js
deleted file mode 100644
index bcd26bae..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/class-name.js
+++ /dev/null
@@ -1,27 +0,0 @@
-"use strict";
-
-var functionName = require("./function-name");
-
-/**
- * Returns a display name for a value from a constructor
- *
- * @param {object} value A value to examine
- * @returns {(string|null)} A string or null
- */
-function className(value) {
- return (
- (value.constructor && value.constructor.name) ||
- // The next branch is for IE11 support only:
- // Because the name property is not set on the prototype
- // of the Function object, we finally try to grab the
- // name from its definition. This will never be reached
- // in node, so we are not able to test this properly.
- // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function/name
- (typeof value.constructor === "function" &&
- /* istanbul ignore next */
- functionName(value.constructor)) ||
- null
- );
-}
-
-module.exports = className;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/class-name.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/class-name.test.js
deleted file mode 100644
index 994f21b8..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/class-name.test.js
+++ /dev/null
@@ -1,37 +0,0 @@
-"use strict";
-/* eslint-disable no-empty-function */
-
-var assert = require("@sinonjs/referee").assert;
-var className = require("./class-name");
-
-describe("className", function () {
- it("returns the class name of an instance", function () {
- // Because eslint-config-sinon disables es6, we can't
- // use a class definition here
- // https://github.com/sinonjs/eslint-config-sinon/blob/master/index.js
- // var instance = new (class TestClass {})();
- var instance = new (function TestClass() {})();
- var name = className(instance);
- assert.equals(name, "TestClass");
- });
-
- it("returns 'Object' for {}", function () {
- var name = className({});
- assert.equals(name, "Object");
- });
-
- it("returns null for an object that has no prototype", function () {
- var obj = Object.create(null);
- var name = className(obj);
- assert.equals(name, null);
- });
-
- it("returns null for an object whose prototype was mangled", function () {
- // This is what Node v6 and v7 do for objects returned by querystring.parse()
- function MangledObject() {}
- MangledObject.prototype = Object.create(null);
- var obj = new MangledObject();
- var name = className(obj);
- assert.equals(name, null);
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/deprecated.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/deprecated.js
deleted file mode 100644
index 42227254..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/deprecated.js
+++ /dev/null
@@ -1,51 +0,0 @@
-/* eslint-disable no-console */
-"use strict";
-
-/**
- * Returns a function that will invoke the supplied function and print a
- * deprecation warning to the console each time it is called.
- *
- * @param {Function} func
- * @param {string} msg
- * @returns {Function}
- */
-exports.wrap = function (func, msg) {
- var wrapped = function () {
- exports.printWarning(msg);
- return func.apply(this, arguments);
- };
- if (func.prototype) {
- wrapped.prototype = func.prototype;
- }
- return wrapped;
-};
-
-/**
- * Returns a string which can be supplied to `wrap()` to notify the user that a
- * particular part of the sinon API has been deprecated.
- *
- * @param {string} packageName
- * @param {string} funcName
- * @returns {string}
- */
-exports.defaultMsg = function (packageName, funcName) {
- return `${packageName}.${funcName} is deprecated and will be removed from the public API in a future version of ${packageName}.`;
-};
-
-/**
- * Prints a warning on the console, when it exists
- *
- * @param {string} msg
- * @returns {undefined}
- */
-exports.printWarning = function (msg) {
- /* istanbul ignore next */
- if (typeof process === "object" && process.emitWarning) {
- // Emit Warnings in Node
- process.emitWarning(msg);
- } else if (console.info) {
- console.info(msg);
- } else {
- console.log(msg);
- }
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/deprecated.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/deprecated.test.js
deleted file mode 100644
index 275d8b1c..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/deprecated.test.js
+++ /dev/null
@@ -1,101 +0,0 @@
-/* eslint-disable no-console */
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var sinon = require("@sinonjs/referee-sinon").sinon;
-
-var deprecated = require("./deprecated");
-
-var msg = "test";
-
-describe("deprecated", function () {
- describe("defaultMsg", function () {
- it("should return a string", function () {
- assert.equals(
- deprecated.defaultMsg("sinon", "someFunc"),
- "sinon.someFunc is deprecated and will be removed from the public API in a future version of sinon."
- );
- });
- });
-
- describe("printWarning", function () {
- beforeEach(function () {
- sinon.replace(process, "emitWarning", sinon.fake());
- });
-
- afterEach(sinon.restore);
-
- describe("when `process.emitWarning` is defined", function () {
- it("should call process.emitWarning with a msg", function () {
- deprecated.printWarning(msg);
- assert.calledOnceWith(process.emitWarning, msg);
- });
- });
-
- describe("when `process.emitWarning` is undefined", function () {
- beforeEach(function () {
- sinon.replace(console, "info", sinon.fake());
- sinon.replace(console, "log", sinon.fake());
- process.emitWarning = undefined;
- });
-
- afterEach(sinon.restore);
-
- describe("when `console.info` is defined", function () {
- it("should call `console.info` with a message", function () {
- deprecated.printWarning(msg);
- assert.calledOnceWith(console.info, msg);
- });
- });
-
- describe("when `console.info` is undefined", function () {
- it("should call `console.log` with a message", function () {
- console.info = undefined;
- deprecated.printWarning(msg);
- assert.calledOnceWith(console.log, msg);
- });
- });
- });
- });
-
- describe("wrap", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- var method = sinon.fake();
- var wrapped;
-
- beforeEach(function () {
- wrapped = deprecated.wrap(method, msg);
- });
-
- it("should return a wrapper function", function () {
- assert.match(wrapped, sinon.match.func);
- });
-
- it("should assign the prototype of the passed method", function () {
- assert.equals(method.prototype, wrapped.prototype);
- });
-
- context("when the passed method has falsy prototype", function () {
- it("should not be assigned to the wrapped method", function () {
- method.prototype = null;
- wrapped = deprecated.wrap(method, msg);
- assert.match(wrapped.prototype, sinon.match.object);
- });
- });
-
- context("when invoking the wrapped function", function () {
- before(function () {
- sinon.replace(deprecated, "printWarning", sinon.fake());
- wrapped({});
- });
-
- it("should call `printWarning` before invoking", function () {
- assert.calledOnceWith(deprecated.printWarning, msg);
- });
-
- it("should invoke the passed method with the given arguments", function () {
- assert.calledOnceWith(method, {});
- });
- });
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/every.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/every.js
deleted file mode 100644
index 00bf304e..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/every.js
+++ /dev/null
@@ -1,27 +0,0 @@
-"use strict";
-
-/**
- * Returns true when fn returns true for all members of obj.
- * This is an every implementation that works for all iterables
- *
- * @param {object} obj
- * @param {Function} fn
- * @returns {boolean}
- */
-module.exports = function every(obj, fn) {
- var pass = true;
-
- try {
- // eslint-disable-next-line @sinonjs/no-prototype-methods/no-prototype-methods
- obj.forEach(function () {
- if (!fn.apply(this, arguments)) {
- // Throwing an error is the only way to break `forEach`
- throw new Error();
- }
- });
- } catch (e) {
- pass = false;
- }
-
- return pass;
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/every.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/every.test.js
deleted file mode 100644
index e054a14d..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/every.test.js
+++ /dev/null
@@ -1,41 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var sinon = require("@sinonjs/referee-sinon").sinon;
-var every = require("./every");
-
-describe("util/core/every", function () {
- it("returns true when the callback function returns true for every element in an iterable", function () {
- var obj = [true, true, true, true];
- var allTrue = every(obj, function (val) {
- return val;
- });
-
- assert(allTrue);
- });
-
- it("returns false when the callback function returns false for any element in an iterable", function () {
- var obj = [true, true, true, false];
- var result = every(obj, function (val) {
- return val;
- });
-
- assert.isFalse(result);
- });
-
- it("calls the given callback once for each item in an iterable until it returns false", function () {
- var iterableOne = [true, true, true, true];
- var iterableTwo = [true, true, false, true];
- var callback = sinon.spy(function (val) {
- return val;
- });
-
- every(iterableOne, callback);
- assert.equals(callback.callCount, 4);
-
- callback.resetHistory();
-
- every(iterableTwo, callback);
- assert.equals(callback.callCount, 3);
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/function-name.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/function-name.js
deleted file mode 100644
index 199b04e0..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/function-name.js
+++ /dev/null
@@ -1,29 +0,0 @@
-"use strict";
-
-/**
- * Returns a display name for a function
- *
- * @param {Function} func
- * @returns {string}
- */
-module.exports = function functionName(func) {
- if (!func) {
- return "";
- }
-
- try {
- return (
- func.displayName ||
- func.name ||
- // Use function decomposition as a last resort to get function
- // name. Does not rely on function decomposition to work - if it
- // doesn't debugging will be slightly less informative
- // (i.e. toString will say 'spy' rather than 'myFunc').
- (String(func).match(/function ([^\s(]+)/) || [])[1]
- );
- } catch (e) {
- // Stringify may fail and we might get an exception, as a last-last
- // resort fall back to empty string.
- return "";
- }
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/function-name.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/function-name.test.js
deleted file mode 100644
index 0798b4e7..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/function-name.test.js
+++ /dev/null
@@ -1,76 +0,0 @@
-"use strict";
-
-var jsc = require("jsverify");
-var refute = require("@sinonjs/referee-sinon").refute;
-
-var functionName = require("./function-name");
-
-describe("function-name", function () {
- it("should return empty string if func is falsy", function () {
- jsc.assertForall("falsy", function (fn) {
- return functionName(fn) === "";
- });
- });
-
- it("should use displayName by default", function () {
- jsc.assertForall("nestring", function (displayName) {
- var fn = { displayName: displayName };
-
- return functionName(fn) === fn.displayName;
- });
- });
-
- it("should use name if displayName is not available", function () {
- jsc.assertForall("nestring", function (name) {
- var fn = { name: name };
-
- return functionName(fn) === fn.name;
- });
- });
-
- it("should fallback to string parsing", function () {
- jsc.assertForall("nat", function (naturalNumber) {
- var name = `fn${naturalNumber}`;
- var fn = {
- toString: function () {
- return `\nfunction ${name}`;
- },
- };
-
- return functionName(fn) === name;
- });
- });
-
- it("should not fail when a name cannot be found", function () {
- refute.exception(function () {
- var fn = {
- toString: function () {
- return "\nfunction (";
- },
- };
-
- functionName(fn);
- });
- });
-
- it("should not fail when toString is undefined", function () {
- refute.exception(function () {
- functionName(Object.create(null));
- });
- });
-
- it("should not fail when toString throws", function () {
- refute.exception(function () {
- var fn;
- try {
- // eslint-disable-next-line no-eval
- fn = eval("(function*() {})")().constructor;
- } catch (e) {
- // env doesn't support generators
- return;
- }
-
- functionName(fn);
- });
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/global.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/global.js
deleted file mode 100644
index 51715a27..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/global.js
+++ /dev/null
@@ -1,22 +0,0 @@
-"use strict";
-
-/**
- * A reference to the global object
- *
- * @type {object} globalObject
- */
-var globalObject;
-
-/* istanbul ignore else */
-if (typeof global !== "undefined") {
- // Node
- globalObject = global;
-} else if (typeof window !== "undefined") {
- // Browser
- globalObject = window;
-} else {
- // WebWorker
- globalObject = self;
-}
-
-module.exports = globalObject;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/global.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/global.test.js
deleted file mode 100644
index 4fa73ebc..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/global.test.js
+++ /dev/null
@@ -1,16 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var globalObject = require("./global");
-
-describe("global", function () {
- before(function () {
- if (typeof global === "undefined") {
- this.skip();
- }
- });
-
- it("is same as global", function () {
- assert.same(globalObject, global);
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/index.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/index.js
deleted file mode 100644
index 870df32c..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/index.js
+++ /dev/null
@@ -1,14 +0,0 @@
-"use strict";
-
-module.exports = {
- global: require("./global"),
- calledInOrder: require("./called-in-order"),
- className: require("./class-name"),
- deprecated: require("./deprecated"),
- every: require("./every"),
- functionName: require("./function-name"),
- orderByFirstCall: require("./order-by-first-call"),
- prototypes: require("./prototypes"),
- typeOf: require("./type-of"),
- valueToString: require("./value-to-string"),
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/index.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/index.test.js
deleted file mode 100644
index e79aa7ee..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/index.test.js
+++ /dev/null
@@ -1,31 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var index = require("./index");
-
-var expectedMethods = [
- "calledInOrder",
- "className",
- "every",
- "functionName",
- "orderByFirstCall",
- "typeOf",
- "valueToString",
-];
-var expectedObjectProperties = ["deprecated", "prototypes"];
-
-describe("package", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- expectedMethods.forEach(function (name) {
- it(`should export a method named ${name}`, function () {
- assert.isFunction(index[name]);
- });
- });
-
- // eslint-disable-next-line mocha/no-setup-in-describe
- expectedObjectProperties.forEach(function (name) {
- it(`should export an object property named ${name}`, function () {
- assert.isObject(index[name]);
- });
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/order-by-first-call.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/order-by-first-call.js
deleted file mode 100644
index c3d47edf..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/order-by-first-call.js
+++ /dev/null
@@ -1,36 +0,0 @@
-"use strict";
-
-var sort = require("./prototypes/array").sort;
-var slice = require("./prototypes/array").slice;
-
-/**
- * @private
- */
-function comparator(a, b) {
- // uuid, won't ever be equal
- var aCall = a.getCall(0);
- var bCall = b.getCall(0);
- var aId = (aCall && aCall.callId) || -1;
- var bId = (bCall && bCall.callId) || -1;
-
- return aId < bId ? -1 : 1;
-}
-
-/**
- * A Sinon proxy object (fake, spy, stub)
- *
- * @typedef {object} SinonProxy
- * @property {Function} getCall - A method that can return the first call
- */
-
-/**
- * Sorts an array of SinonProxy instances (fake, spy, stub) by their first call
- *
- * @param {SinonProxy[] | SinonProxy} spies
- * @returns {SinonProxy[]}
- */
-function orderByFirstCall(spies) {
- return sort(slice(spies), comparator);
-}
-
-module.exports = orderByFirstCall;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/order-by-first-call.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/order-by-first-call.test.js
deleted file mode 100644
index cbc71beb..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/order-by-first-call.test.js
+++ /dev/null
@@ -1,52 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var knuthShuffle = require("knuth-shuffle").knuthShuffle;
-var sinon = require("@sinonjs/referee-sinon").sinon;
-var orderByFirstCall = require("./order-by-first-call");
-
-describe("orderByFirstCall", function () {
- it("should order an Array of spies by the callId of the first call, ascending", function () {
- // create an array of spies
- var spies = [
- sinon.spy(),
- sinon.spy(),
- sinon.spy(),
- sinon.spy(),
- sinon.spy(),
- sinon.spy(),
- ];
-
- // call all the spies
- spies.forEach(function (spy) {
- spy();
- });
-
- // add a few uncalled spies
- spies.push(sinon.spy());
- spies.push(sinon.spy());
-
- // randomise the order of the spies
- knuthShuffle(spies);
-
- var sortedSpies = orderByFirstCall(spies);
-
- assert.equals(sortedSpies.length, spies.length);
-
- var orderedByFirstCall = sortedSpies.every(function (spy, index) {
- if (index + 1 === sortedSpies.length) {
- return true;
- }
- var nextSpy = sortedSpies[index + 1];
-
- // uncalled spies should be ordered first
- if (!spy.called) {
- return true;
- }
-
- return spy.calledImmediatelyBefore(nextSpy);
- });
-
- assert.isTrue(orderedByFirstCall);
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/README.md b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/README.md
deleted file mode 100644
index c3d92fe8..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/README.md
+++ /dev/null
@@ -1,43 +0,0 @@
-# Prototypes
-
-The functions in this folder are to be use for keeping cached references to the built-in prototypes, so that people can't inadvertently break the library by making mistakes in userland.
-
-See https://github.com/sinonjs/sinon/pull/1523
-
-## Without cached references
-
-```js
-// in userland, the library user needs to replace the filter method on
-// Array.prototype
-var array = [1, 2, 3];
-sinon.replace(array, "filter", sinon.fake.returns(2));
-
-// in a sinon module, the library author needs to use the filter method
-var someArray = ["a", "b", 42, "c"];
-var answer = filter(someArray, function (v) {
- return v === 42;
-});
-
-console.log(answer);
-// => 2
-```
-
-## With cached references
-
-```js
-// in userland, the library user needs to replace the filter method on
-// Array.prototype
-var array = [1, 2, 3];
-sinon.replace(array, "filter", sinon.fake.returns(2));
-
-// in a sinon module, the library author needs to use the filter method
-// get a reference to the original Array.prototype.filter
-var filter = require("@sinonjs/commons").prototypes.array.filter;
-var someArray = ["a", "b", 42, "c"];
-var answer = filter(someArray, function (v) {
- return v === 42;
-});
-
-console.log(answer);
-// => 42
-```
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/array.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/array.js
deleted file mode 100644
index 381a032a..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/array.js
+++ /dev/null
@@ -1,5 +0,0 @@
-"use strict";
-
-var copyPrototype = require("./copy-prototype-methods");
-
-module.exports = copyPrototype(Array.prototype);
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/copy-prototype-methods.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/copy-prototype-methods.js
deleted file mode 100644
index 38549c19..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/copy-prototype-methods.js
+++ /dev/null
@@ -1,40 +0,0 @@
-"use strict";
-
-var call = Function.call;
-var throwsOnProto = require("./throws-on-proto");
-
-var disallowedProperties = [
- // ignore size because it throws from Map
- "size",
- "caller",
- "callee",
- "arguments",
-];
-
-// This branch is covered when tests are run with `--disable-proto=throw`,
-// however we can test both branches at the same time, so this is ignored
-/* istanbul ignore next */
-if (throwsOnProto) {
- disallowedProperties.push("__proto__");
-}
-
-module.exports = function copyPrototypeMethods(prototype) {
- // eslint-disable-next-line @sinonjs/no-prototype-methods/no-prototype-methods
- return Object.getOwnPropertyNames(prototype).reduce(function (
- result,
- name
- ) {
- if (disallowedProperties.includes(name)) {
- return result;
- }
-
- if (typeof prototype[name] !== "function") {
- return result;
- }
-
- result[name] = call.bind(prototype[name]);
-
- return result;
- },
- Object.create(null));
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/copy-prototype-methods.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/copy-prototype-methods.test.js
deleted file mode 100644
index 31de7cd3..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/copy-prototype-methods.test.js
+++ /dev/null
@@ -1,12 +0,0 @@
-"use strict";
-
-var refute = require("@sinonjs/referee-sinon").refute;
-var copyPrototypeMethods = require("./copy-prototype-methods");
-
-describe("copyPrototypeMethods", function () {
- it("does not throw for Map", function () {
- refute.exception(function () {
- copyPrototypeMethods(Map.prototype);
- });
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/function.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/function.js
deleted file mode 100644
index a75c25d8..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/function.js
+++ /dev/null
@@ -1,5 +0,0 @@
-"use strict";
-
-var copyPrototype = require("./copy-prototype-methods");
-
-module.exports = copyPrototype(Function.prototype);
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/index.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/index.js
deleted file mode 100644
index ab766bf8..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/index.js
+++ /dev/null
@@ -1,10 +0,0 @@
-"use strict";
-
-module.exports = {
- array: require("./array"),
- function: require("./function"),
- map: require("./map"),
- object: require("./object"),
- set: require("./set"),
- string: require("./string"),
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/index.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/index.test.js
deleted file mode 100644
index 2b3c2625..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/index.test.js
+++ /dev/null
@@ -1,61 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-
-var arrayProto = require("./index").array;
-var functionProto = require("./index").function;
-var mapProto = require("./index").map;
-var objectProto = require("./index").object;
-var setProto = require("./index").set;
-var stringProto = require("./index").string;
-var throwsOnProto = require("./throws-on-proto");
-
-describe("prototypes", function () {
- describe(".array", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- verifyProperties(arrayProto, Array);
- });
- describe(".function", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- verifyProperties(functionProto, Function);
- });
- describe(".map", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- verifyProperties(mapProto, Map);
- });
- describe(".object", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- verifyProperties(objectProto, Object);
- });
- describe(".set", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- verifyProperties(setProto, Set);
- });
- describe(".string", function () {
- // eslint-disable-next-line mocha/no-setup-in-describe
- verifyProperties(stringProto, String);
- });
-});
-
-function verifyProperties(p, origin) {
- var disallowedProperties = ["size", "caller", "callee", "arguments"];
- if (throwsOnProto) {
- disallowedProperties.push("__proto__");
- }
-
- it("should have all the methods of the origin prototype", function () {
- var methodNames = Object.getOwnPropertyNames(origin.prototype).filter(
- function (name) {
- if (disallowedProperties.includes(name)) {
- return false;
- }
-
- return typeof origin.prototype[name] === "function";
- }
- );
-
- methodNames.forEach(function (name) {
- assert.isTrue(Object.prototype.hasOwnProperty.call(p, name), name);
- });
- });
-}
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/map.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/map.js
deleted file mode 100644
index 91ec65e2..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/map.js
+++ /dev/null
@@ -1,5 +0,0 @@
-"use strict";
-
-var copyPrototype = require("./copy-prototype-methods");
-
-module.exports = copyPrototype(Map.prototype);
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/object.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/object.js
deleted file mode 100644
index eab7faa8..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/object.js
+++ /dev/null
@@ -1,5 +0,0 @@
-"use strict";
-
-var copyPrototype = require("./copy-prototype-methods");
-
-module.exports = copyPrototype(Object.prototype);
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/set.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/set.js
deleted file mode 100644
index 7495c3b9..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/set.js
+++ /dev/null
@@ -1,5 +0,0 @@
-"use strict";
-
-var copyPrototype = require("./copy-prototype-methods");
-
-module.exports = copyPrototype(Set.prototype);
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/string.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/string.js
deleted file mode 100644
index 3917fe9b..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/string.js
+++ /dev/null
@@ -1,5 +0,0 @@
-"use strict";
-
-var copyPrototype = require("./copy-prototype-methods");
-
-module.exports = copyPrototype(String.prototype);
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/throws-on-proto.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/throws-on-proto.js
deleted file mode 100644
index eb7a189b..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/prototypes/throws-on-proto.js
+++ /dev/null
@@ -1,26 +0,0 @@
-"use strict";
-
-/**
- * Is true when the environment causes an error to be thrown for accessing the
- * __proto__ property.
- *
- * This is necessary in order to support `node --disable-proto=throw`.
- *
- * See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/proto
- *
- * @type {boolean}
- */
-let throwsOnProto;
-try {
- const object = {};
- // eslint-disable-next-line no-proto, no-unused-expressions
- object.__proto__;
- throwsOnProto = false;
-} catch (_) {
- // This branch is covered when tests are run with `--disable-proto=throw`,
- // however we can test both branches at the same time, so this is ignored
- /* istanbul ignore next */
- throwsOnProto = true;
-}
-
-module.exports = throwsOnProto;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/type-of.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/type-of.js
deleted file mode 100644
index 97a0bb9c..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/type-of.js
+++ /dev/null
@@ -1,13 +0,0 @@
-"use strict";
-
-var type = require("type-detect");
-
-/**
- * Returns the lower-case result of running type from type-detect on the value
- *
- * @param {*} value
- * @returns {string}
- */
-module.exports = function typeOf(value) {
- return type(value).toLowerCase();
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/type-of.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/type-of.test.js
deleted file mode 100644
index ba377b94..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/type-of.test.js
+++ /dev/null
@@ -1,51 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var typeOf = require("./type-of");
-
-describe("typeOf", function () {
- it("returns boolean", function () {
- assert.equals(typeOf(false), "boolean");
- });
-
- it("returns string", function () {
- assert.equals(typeOf("Sinon.JS"), "string");
- });
-
- it("returns number", function () {
- assert.equals(typeOf(123), "number");
- });
-
- it("returns object", function () {
- assert.equals(typeOf({}), "object");
- });
-
- it("returns function", function () {
- assert.equals(
- typeOf(function () {
- return undefined;
- }),
- "function"
- );
- });
-
- it("returns undefined", function () {
- assert.equals(typeOf(undefined), "undefined");
- });
-
- it("returns null", function () {
- assert.equals(typeOf(null), "null");
- });
-
- it("returns array", function () {
- assert.equals(typeOf([]), "array");
- });
-
- it("returns regexp", function () {
- assert.equals(typeOf(/.*/), "regexp");
- });
-
- it("returns date", function () {
- assert.equals(typeOf(new Date()), "date");
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/value-to-string.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/value-to-string.js
deleted file mode 100644
index fb14782b..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/value-to-string.js
+++ /dev/null
@@ -1,17 +0,0 @@
-"use strict";
-
-/**
- * Returns a string representation of the value
- *
- * @param {*} value
- * @returns {string}
- */
-function valueToString(value) {
- if (value && value.toString) {
- // eslint-disable-next-line @sinonjs/no-prototype-methods/no-prototype-methods
- return value.toString();
- }
- return String(value);
-}
-
-module.exports = valueToString;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/value-to-string.test.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/value-to-string.test.js
deleted file mode 100644
index 64564471..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/lib/value-to-string.test.js
+++ /dev/null
@@ -1,20 +0,0 @@
-"use strict";
-
-var assert = require("@sinonjs/referee-sinon").assert;
-var valueToString = require("./value-to-string");
-
-describe("util/core/valueToString", function () {
- it("returns string representation of an object", function () {
- var obj = {};
-
- assert.equals(valueToString(obj), obj.toString());
- });
-
- it("returns 'null' for literal null'", function () {
- assert.equals(valueToString(null), "null");
- });
-
- it("returns 'undefined' for literal undefined", function () {
- assert.equals(valueToString(undefined), "undefined");
- });
-});
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/package.json b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/package.json
deleted file mode 100644
index 2f80d025..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/package.json
+++ /dev/null
@@ -1,57 +0,0 @@
-{
- "name": "@sinonjs/commons",
- "version": "3.0.0",
- "description": "Simple functions shared among the sinon end user libraries",
- "main": "lib/index.js",
- "types": "./types/index.d.ts",
- "scripts": {
- "build": "rm -rf types && tsc",
- "lint": "eslint .",
- "precommit": "lint-staged",
- "test": "mocha --recursive -R dot \"lib/**/*.test.js\"",
- "test-check-coverage": "npm run test-coverage && nyc check-coverage --branches 100 --functions 100 --lines 100",
- "test-coverage": "nyc --reporter text --reporter html --reporter lcovonly npm run test",
- "prepublishOnly": "npm run build",
- "prettier:check": "prettier --check '**/*.{js,css,md}'",
- "prettier:write": "prettier --write '**/*.{js,css,md}'",
- "preversion": "npm run test-check-coverage",
- "version": "changes --commits --footer",
- "postversion": "git push --follow-tags && npm publish",
- "prepare": "husky install"
- },
- "repository": {
- "type": "git",
- "url": "git+https://github.com/sinonjs/commons.git"
- },
- "files": [
- "lib",
- "types"
- ],
- "author": "",
- "license": "BSD-3-Clause",
- "bugs": {
- "url": "https://github.com/sinonjs/commons/issues"
- },
- "homepage": "https://github.com/sinonjs/commons#readme",
- "lint-staged": {
- "*.{js,css,md}": "prettier --check",
- "*.js": "eslint"
- },
- "devDependencies": {
- "@sinonjs/eslint-config": "^4.0.6",
- "@sinonjs/eslint-plugin-no-prototype-methods": "^0.1.0",
- "@sinonjs/referee-sinon": "^10.1.0",
- "@studio/changes": "^2.2.0",
- "husky": "^6.0.0",
- "jsverify": "0.8.4",
- "knuth-shuffle": "^1.0.8",
- "lint-staged": "^13.0.3",
- "mocha": "^10.1.0",
- "nyc": "^15.1.0",
- "prettier": "^2.7.1",
- "typescript": "^4.8.4"
- },
- "dependencies": {
- "type-detect": "4.0.8"
- }
-}
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/called-in-order.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/called-in-order.d.ts
deleted file mode 100644
index 1a4508be..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/called-in-order.d.ts
+++ /dev/null
@@ -1,36 +0,0 @@
-export = calledInOrder;
-/**
- * A Sinon proxy object (fake, spy, stub)
- *
- * @typedef {object} SinonProxy
- * @property {Function} calledBefore - A method that determines if this proxy was called before another one
- * @property {string} id - Some id
- * @property {number} callCount - Number of times this proxy has been called
- */
-/**
- * Returns true when the spies have been called in the order they were supplied in
- *
- * @param {SinonProxy[] | SinonProxy} spies An array of proxies, or several proxies as arguments
- * @returns {boolean} true when spies are called in order, false otherwise
- */
-declare function calledInOrder(spies: SinonProxy[] | SinonProxy, ...args: any[]): boolean;
-declare namespace calledInOrder {
- export { SinonProxy };
-}
-/**
- * A Sinon proxy object (fake, spy, stub)
- */
-type SinonProxy = {
- /**
- * - A method that determines if this proxy was called before another one
- */
- calledBefore: Function;
- /**
- * - Some id
- */
- id: string;
- /**
- * - Number of times this proxy has been called
- */
- callCount: number;
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/class-name.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/class-name.d.ts
deleted file mode 100644
index df3687b9..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/class-name.d.ts
+++ /dev/null
@@ -1,8 +0,0 @@
-export = className;
-/**
- * Returns a display name for a value from a constructor
- *
- * @param {object} value A value to examine
- * @returns {(string|null)} A string or null
- */
-declare function className(value: object): (string | null);
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/deprecated.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/deprecated.d.ts
deleted file mode 100644
index 81a35bf8..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/deprecated.d.ts
+++ /dev/null
@@ -1,3 +0,0 @@
-export function wrap(func: Function, msg: string): Function;
-export function defaultMsg(packageName: string, funcName: string): string;
-export function printWarning(msg: string): undefined;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/every.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/every.d.ts
deleted file mode 100644
index bcfa64e0..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/every.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare function _exports(obj: object, fn: Function): boolean;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/function-name.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/function-name.d.ts
deleted file mode 100644
index f27d519a..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/function-name.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare function _exports(func: Function): string;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/global.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/global.d.ts
deleted file mode 100644
index 0f54a635..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/global.d.ts
+++ /dev/null
@@ -1,7 +0,0 @@
-export = globalObject;
-/**
- * A reference to the global object
- *
- * @type {object} globalObject
- */
-declare var globalObject: object;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/index.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/index.d.ts
deleted file mode 100644
index 7d675b18..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/index.d.ts
+++ /dev/null
@@ -1,17 +0,0 @@
-export const global: any;
-export const calledInOrder: typeof import("./called-in-order");
-export const className: typeof import("./class-name");
-export const deprecated: typeof import("./deprecated");
-export const every: (obj: any, fn: Function) => boolean;
-export const functionName: (func: Function) => string;
-export const orderByFirstCall: typeof import("./order-by-first-call");
-export const prototypes: {
- array: any;
- function: any;
- map: any;
- object: any;
- set: any;
- string: any;
-};
-export const typeOf: (value: any) => string;
-export const valueToString: typeof import("./value-to-string");
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/order-by-first-call.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/order-by-first-call.d.ts
deleted file mode 100644
index a9a6037d..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/order-by-first-call.d.ts
+++ /dev/null
@@ -1,26 +0,0 @@
-export = orderByFirstCall;
-/**
- * A Sinon proxy object (fake, spy, stub)
- *
- * @typedef {object} SinonProxy
- * @property {Function} getCall - A method that can return the first call
- */
-/**
- * Sorts an array of SinonProxy instances (fake, spy, stub) by their first call
- *
- * @param {SinonProxy[] | SinonProxy} spies
- * @returns {SinonProxy[]}
- */
-declare function orderByFirstCall(spies: SinonProxy[] | SinonProxy): SinonProxy[];
-declare namespace orderByFirstCall {
- export { SinonProxy };
-}
-/**
- * A Sinon proxy object (fake, spy, stub)
- */
-type SinonProxy = {
- /**
- * - A method that can return the first call
- */
- getCall: Function;
-};
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/array.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/array.d.ts
deleted file mode 100644
index 1cce6350..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/array.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare const _exports: any;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/copy-prototype-methods.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/copy-prototype-methods.d.ts
deleted file mode 100644
index 1479b93c..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/copy-prototype-methods.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare function _exports(prototype: any): any;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/function.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/function.d.ts
deleted file mode 100644
index 1cce6350..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/function.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare const _exports: any;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/index.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/index.d.ts
deleted file mode 100644
index 0026d6c2..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/index.d.ts
+++ /dev/null
@@ -1,7 +0,0 @@
-export declare const array: any;
-declare const _function: any;
-export { _function as function };
-export declare const map: any;
-export declare const object: any;
-export declare const set: any;
-export declare const string: any;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/map.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/map.d.ts
deleted file mode 100644
index 1cce6350..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/map.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare const _exports: any;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/object.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/object.d.ts
deleted file mode 100644
index 1cce6350..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/object.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare const _exports: any;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/set.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/set.d.ts
deleted file mode 100644
index 1cce6350..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/set.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare const _exports: any;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/string.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/string.d.ts
deleted file mode 100644
index 1cce6350..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/string.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare const _exports: any;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/throws-on-proto.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/throws-on-proto.d.ts
deleted file mode 100644
index 6cc97f4a..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/prototypes/throws-on-proto.d.ts
+++ /dev/null
@@ -1,12 +0,0 @@
-export = throwsOnProto;
-/**
- * Is true when the environment causes an error to be thrown for accessing the
- * __proto__ property.
- *
- * This is necessary in order to support `node --disable-proto=throw`.
- *
- * See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/proto
- *
- * @type {boolean}
- */
-declare let throwsOnProto: boolean;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/type-of.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/type-of.d.ts
deleted file mode 100644
index fc72887c..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/type-of.d.ts
+++ /dev/null
@@ -1,2 +0,0 @@
-declare function _exports(value: any): string;
-export = _exports;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/value-to-string.d.ts b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/value-to-string.d.ts
deleted file mode 100644
index 19b086cd..00000000
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons/types/value-to-string.d.ts
+++ /dev/null
@@ -1,8 +0,0 @@
-export = valueToString;
-/**
- * Returns a string representation of the value
- *
- * @param {*} value
- * @returns {string}
- */
-declare function valueToString(value: any): string;
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/package.json b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/package.json
index fdb18926..51b8565c 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/package.json
+++ b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/package.json
@@ -1,7 +1,7 @@
{
"name": "@sinonjs/fake-timers",
"description": "Fake JavaScript timers",
- "version": "10.3.0",
+ "version": "11.2.2",
"homepage": "https://github.com/sinonjs/fake-timers",
"author": "Christian Johansen",
"repository": {
@@ -39,12 +39,12 @@
"@sinonjs/eslint-config": "^4.1.0",
"@sinonjs/referee-sinon": "11.0.0",
"husky": "^8.0.3",
- "jsdom": "22.0.0",
- "lint-staged": "13.2.2",
+ "jsdom": "22.1.0",
+ "lint-staged": "15.0.1",
"mocha": "10.2.0",
"mochify": "9.2.0",
"nyc": "15.1.0",
- "prettier": "2.8.8"
+ "prettier": "3.0.3"
},
"main": "./src/fake-timers-src.js",
"dependencies": {
diff --git a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/src/fake-timers-src.js b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/src/fake-timers-src.js
index 607d91fb..0ce72178 100644
--- a/build/node_modules/nise/node_modules/@sinonjs/fake-timers/src/fake-timers-src.js
+++ b/build/node_modules/nise/node_modules/@sinonjs/fake-timers/src/fake-timers-src.js
@@ -1,6 +1,14 @@
"use strict";
const globalObject = require("@sinonjs/commons").global;
+let timersModule;
+if (typeof require === "function" && typeof module === "object") {
+ try {
+ timersModule = require("timers");
+ } catch (e) {
+ // ignored
+ }
+}
/**
* @typedef {object} IdleDeadline
@@ -20,14 +28,14 @@ const globalObject = require("@sinonjs/commons").global;
/**
* @callback NextTick
* @param {VoidVarArgsFunc} callback - the callback to run
- * @param {...*} arguments - optional arguments to call the callback with
+ * @param {...*} args - optional arguments to call the callback with
* @returns {void}
*/
/**
* @callback SetImmediate
* @param {VoidVarArgsFunc} callback - the callback to run
- * @param {...*} arguments - optional arguments to call the callback with
+ * @param {...*} args - optional arguments to call the callback with
* @returns {NodeImmediate}
*/
@@ -85,6 +93,7 @@ const globalObject = require("@sinonjs/commons").global;
* @property {function(): void} uninstall Uninstall the clock.
* @property {Function[]} methods - the methods that are faked
* @property {boolean} [shouldClearNativeTimers] inherited from config
+ * @property {{methodName:string, original:any}[] | undefined} timersModuleMethods
*/
/* eslint-enable jsdoc/require-property-description */
@@ -134,8 +143,6 @@ const globalObject = require("@sinonjs/commons").global;
* @returns {FakeTimers}
*/
function withGlobal(_global) {
- const userAgent = _global.navigator && _global.navigator.userAgent;
- const isRunningInIE = userAgent && userAgent.indexOf("MSIE ") > -1;
const maxTimeout = Math.pow(2, 31) - 1; //see https://heycam.github.io/webidl/#abstract-opdef-converttoint
const idCounterStart = 1e12; // arbitrarily large number to avoid collisions with native timer IDs
const NOOP = function () {
@@ -177,29 +184,12 @@ function withGlobal(_global) {
typeof _global.cancelIdleCallback === "function";
const setImmediatePresent =
_global.setImmediate && typeof _global.setImmediate === "function";
-
- // Make properties writable in IE, as per
- // https://www.adequatelygood.com/Replacing-setTimeout-Globally.html
- /* eslint-disable no-self-assign */
- if (isRunningInIE) {
- _global.setTimeout = _global.setTimeout;
- _global.clearTimeout = _global.clearTimeout;
- _global.setInterval = _global.setInterval;
- _global.clearInterval = _global.clearInterval;
- _global.Date = _global.Date;
- }
-
- // setImmediate is not a standard function
- // avoid adding the prop to the window object if not present
- if (setImmediatePresent) {
- _global.setImmediate = _global.setImmediate;
- _global.clearImmediate = _global.clearImmediate;
- }
- /* eslint-enable no-self-assign */
+ const intlPresent = _global.Intl && typeof _global.Intl === "object";
_global.clearTimeout(timeoutResult);
const NativeDate = _global.Date;
+ const NativeIntl = _global.Intl;
let uniqueTimerId = idCounterStart;
/**
@@ -254,7 +244,7 @@ function withGlobal(_global) {
if (l > 3 || !/^(\d\d:){0,2}\d\d?$/.test(str)) {
throw new Error(
- "tick only understands numbers, 'm:s' and 'h:m:s'. Each part must be two digits"
+ "tick only understands numbers, 'm:s' and 'h:m:s'. Each part must be two digits",
);
}
@@ -323,7 +313,7 @@ function withGlobal(_global) {
*/
function getInfiniteLoopError(clock, job) {
const infiniteLoopError = new Error(
- `Aborting after running ${clock.loopLimit} timers, assuming an infinite loop!`
+ `Aborting after running ${clock.loopLimit} timers, assuming an infinite loop!`,
);
if (!job.error) {
@@ -333,13 +323,13 @@ function withGlobal(_global) {
// pattern never matched in Node
const computedTargetPattern = /target\.*[<|(|[].*?[>|\]|)]\s*/;
let clockMethodPattern = new RegExp(
- String(Object.keys(clock).join("|"))
+ String(Object.keys(clock).join("|")),
);
if (addTimerReturnsObject) {
// node.js environment
clockMethodPattern = new RegExp(
- `\\s+at (Object\\.)?(?:${Object.keys(clock).join("|")})\\s+`
+ `\\s+at (Object\\.)?(?:${Object.keys(clock).join("|")})\\s+`,
);
}
@@ -473,7 +463,7 @@ function withGlobal(_global) {
date,
hour,
minute,
- second
+ second,
);
default:
return new NativeDate(
@@ -483,7 +473,7 @@ function withGlobal(_global) {
hour,
minute,
second,
- ms
+ ms,
);
}
}
@@ -491,6 +481,55 @@ function withGlobal(_global) {
return mirrorDateProperties(ClockDate, NativeDate);
}
+ /**
+ * Mirror Intl by default on our fake implementation
+ *
+ * Most of the properties are the original native ones,
+ * but we need to take control of those that have a
+ * dependency on the current clock.
+ *
+ * @returns {object} the partly fake Intl implementation
+ */
+ function createIntl() {
+ const ClockIntl = {};
+ /*
+ * All properties of Intl are non-enumerable, so we need
+ * to do a bit of work to get them out.
+ */
+ Object.getOwnPropertyNames(NativeIntl).forEach(
+ (property) => (ClockIntl[property] = NativeIntl[property]),
+ );
+
+ ClockIntl.DateTimeFormat = function (...args) {
+ const realFormatter = new NativeIntl.DateTimeFormat(...args);
+ const formatter = {};
+
+ ["formatRange", "formatRangeToParts", "resolvedOptions"].forEach(
+ (method) => {
+ formatter[method] =
+ realFormatter[method].bind(realFormatter);
+ },
+ );
+
+ ["format", "formatToParts"].forEach((method) => {
+ formatter[method] = function (date) {
+ return realFormatter[method](date || ClockIntl.clock.now);
+ };
+ });
+
+ return formatter;
+ };
+
+ ClockIntl.DateTimeFormat.prototype = Object.create(
+ NativeIntl.DateTimeFormat.prototype,
+ );
+
+ ClockIntl.DateTimeFormat.supportedLocalesOf =
+ NativeIntl.DateTimeFormat.supportedLocalesOf;
+
+ return ClockIntl;
+ }
+
//eslint-disable-next-line jsdoc/require-jsdoc
function enqueueJob(clock, job) {
// enqueues a microtick-deferred task - ecma262/#sec-enqueuejob
@@ -535,7 +574,7 @@ function withGlobal(_global) {
throw new TypeError(
`[ERR_INVALID_CALLBACK]: Callback must be a function. Received ${
timer.func
- } of type ${typeof timer.func}`
+ } of type ${typeof timer.func}`,
);
}
}
@@ -818,7 +857,7 @@ function withGlobal(_global) {
}
warnOnce(
`FakeTimers: ${handlerName} was invoked to clear a native timer instead of one created by this library.` +
- "\nTo automatically clean-up native timers, use `shouldClearNativeTimers`."
+ "\nTo automatically clean-up native timers, use `shouldClearNativeTimers`.",
);
}
@@ -835,7 +874,7 @@ function withGlobal(_global) {
const clear = getClearHandler(ttype);
const schedule = getScheduleHandler(timer.type);
throw new Error(
- `Cannot clear timer: timer created with ${schedule}() but cleared with ${clear}()`
+ `Cannot clear timer: timer created with ${schedule}() but cleared with ${clear}()`,
);
}
}
@@ -860,7 +899,7 @@ function withGlobal(_global) {
} else if (method === "performance") {
const originalPerfDescriptor = Object.getOwnPropertyDescriptor(
clock,
- `_${method}`
+ `_${method}`,
);
if (
originalPerfDescriptor &&
@@ -870,7 +909,7 @@ function withGlobal(_global) {
Object.defineProperty(
_global,
method,
- originalPerfDescriptor
+ originalPerfDescriptor,
);
} else if (originalPerfDescriptor.configurable) {
_global[method] = clock[`_${method}`];
@@ -886,6 +925,12 @@ function withGlobal(_global) {
}
}
}
+ if (clock.timersModuleMethods !== undefined) {
+ for (let j = 0; j < clock.timersModuleMethods.length; j++) {
+ const entry = clock.timersModuleMethods[j];
+ timersModule[entry.methodName] = entry.original;
+ }
+ }
}
if (config.shouldAdvanceTime === true) {
@@ -912,17 +957,19 @@ function withGlobal(_global) {
function hijackMethod(target, method, clock) {
clock[method].hadOwnProperty = Object.prototype.hasOwnProperty.call(
target,
- method
+ method,
);
clock[`_${method}`] = target[method];
if (method === "Date") {
const date = mirrorDateProperties(clock[method], target[method]);
target[method] = date;
+ } else if (method === "Intl") {
+ target[method] = clock[method];
} else if (method === "performance") {
const originalPerfDescriptor = Object.getOwnPropertyDescriptor(
target,
- method
+ method,
);
// JSDOM has a read only performance field so we have to save/copy it differently
if (
@@ -933,12 +980,12 @@ function withGlobal(_global) {
Object.defineProperty(
clock,
`_${method}`,
- originalPerfDescriptor
+ originalPerfDescriptor,
);
const perfDescriptor = Object.getOwnPropertyDescriptor(
clock,
- method
+ method,
);
Object.defineProperty(target, method, perfDescriptor);
} else {
@@ -951,7 +998,7 @@ function withGlobal(_global) {
Object.defineProperties(
target[method],
- Object.getOwnPropertyDescriptors(clock[method])
+ Object.getOwnPropertyDescriptors(clock[method]),
);
}
@@ -973,6 +1020,7 @@ function withGlobal(_global) {
* @property {setInterval} setInterval
* @property {clearInterval} clearInterval
* @property {Date} Date
+ * @property {Intl} Intl
* @property {SetImmediate=} setImmediate
* @property {function(NodeImmediate): void=} clearImmediate
* @property {function(number[]):number[]=} hrtime
@@ -1031,6 +1079,10 @@ function withGlobal(_global) {
timers.cancelIdleCallback = _global.cancelIdleCallback;
}
+ if (intlPresent) {
+ timers.Intl = _global.Intl;
+ }
+
const originalSetTimeout = _global.setImmediate || _global.setTimeout;
/**
@@ -1049,7 +1101,7 @@ function withGlobal(_global) {
if (NativeDate === undefined) {
throw new Error(
"The global scope doesn't have a `Date` object" +
- " (see https://github.com/sinonjs/sinon/issues/1852#issuecomment-419622780)"
+ " (see https://github.com/sinonjs/sinon/issues/1852#issuecomment-419622780)",
);
}
@@ -1078,7 +1130,7 @@ function withGlobal(_global) {
if (Array.isArray(prev)) {
if (prev[1] > 1e9) {
throw new TypeError(
- "Number of nanoseconds can't exceed a billion"
+ "Number of nanoseconds can't exceed a billion",
);
}
@@ -1096,6 +1148,17 @@ function withGlobal(_global) {
return [secsSinceStart, remainderInNanos];
}
+ /**
+ * A high resolution timestamp in milliseconds.
+ *
+ * @typedef {number} DOMHighResTimeStamp
+ */
+
+ /**
+ * performance.now()
+ *
+ * @returns {DOMHighResTimeStamp}
+ */
function fakePerformanceNow() {
const hrt = hrtime();
const millis = hrt[0] * 1000 + hrt[1] / 1e6;
@@ -1109,9 +1172,14 @@ function withGlobal(_global) {
};
}
+ if (intlPresent) {
+ clock.Intl = createIntl();
+ clock.Intl.clock = clock;
+ }
+
clock.requestIdleCallback = function requestIdleCallback(
func,
- timeout
+ timeout,
) {
let timeToNextIdlePeriod = 0;
@@ -1147,7 +1215,7 @@ function withGlobal(_global) {
clock.setTimeout[utilPromisify.custom] =
function promisifiedSetTimeout(timeout, arg) {
return new _global.Promise(function setTimeoutExecutor(
- resolve
+ resolve,
) {
addTimer(clock, {
func: resolve,
@@ -1208,7 +1276,7 @@ function withGlobal(_global) {
args: [arg],
immediate: true,
});
- }
+ },
);
};
}
@@ -1510,6 +1578,8 @@ function withGlobal(_global) {
function doRun() {
originalSetTimeout(function () {
try {
+ runJobs(clock);
+
let numTimers;
if (i < clock.loopLimit) {
if (!clock.timers) {
@@ -1519,7 +1589,7 @@ function withGlobal(_global) {
}
numTimers = Object.keys(
- clock.timers
+ clock.timers,
).length;
if (numTimers === 0) {
resetIsNearInfiniteLimit();
@@ -1565,6 +1635,7 @@ function withGlobal(_global) {
try {
const timer = lastTimer(clock);
if (!timer) {
+ runJobs(clock);
resolve(clock.now);
}
@@ -1652,8 +1723,8 @@ function withGlobal(_global) {
) {
throw new TypeError(
`FakeTimers.install called with ${String(
- config
- )} install requires an object parameter`
+ config,
+ )} install requires an object parameter`,
);
}
@@ -1661,7 +1732,7 @@ function withGlobal(_global) {
// Timers are already faked; this is a problem.
// Make the user reset timers before continuing.
throw new TypeError(
- "Can't install fake timers twice on the same global object."
+ "Can't install fake timers twice on the same global object.",
);
}
@@ -1674,7 +1745,7 @@ function withGlobal(_global) {
if (config.target) {
throw new TypeError(
- "config.target is no longer supported. Use `withGlobal(target)` instead."
+ "config.target is no longer supported. Use `withGlobal(target)` instead.",
);
}
@@ -1699,23 +1770,23 @@ function withGlobal(_global) {
const intervalTick = doIntervalTick.bind(
null,
clock,
- config.advanceTimeDelta
+ config.advanceTimeDelta,
);
const intervalId = _global.setInterval(
intervalTick,
- config.advanceTimeDelta
+ config.advanceTimeDelta,
);
clock.attachedInterval = intervalId;
}
if (clock.methods.includes("performance")) {
const proto = (() => {
- if (hasPerformancePrototype) {
- return _global.Performance.prototype;
- }
if (hasPerformanceConstructorPrototype) {
return _global.performance.constructor.prototype;
}
+ if (hasPerformancePrototype) {
+ return _global.Performance.prototype;
+ }
})();
if (proto) {
Object.getOwnPropertyNames(proto).forEach(function (name) {
@@ -1729,11 +1800,13 @@ function withGlobal(_global) {
} else if ((config.toFake || []).includes("performance")) {
// user explicitly tried to fake performance when not present
throw new ReferenceError(
- "non-existent performance object cannot be faked"
+ "non-existent performance object cannot be faked",
);
}
}
-
+ if (_global === globalObject && timersModule) {
+ clock.timersModuleMethods = [];
+ }
for (i = 0, l = clock.methods.length; i < l; i++) {
const nameOfMethodToReplace = clock.methods[i];
if (nameOfMethodToReplace === "hrtime") {
@@ -1753,6 +1826,18 @@ function withGlobal(_global) {
} else {
hijackMethod(_global, nameOfMethodToReplace, clock);
}
+ if (
+ clock.timersModuleMethods !== undefined &&
+ timersModule[nameOfMethodToReplace]
+ ) {
+ const original = timersModule[nameOfMethodToReplace];
+ clock.timersModuleMethods.push({
+ methodName: nameOfMethodToReplace,
+ original: original,
+ });
+ timersModule[nameOfMethodToReplace] =
+ _global[nameOfMethodToReplace];
+ }
}
return clock;
diff --git a/build/node_modules/nise/package.json b/build/node_modules/nise/package.json
index 6e018176..36ccf4aa 100644
--- a/build/node_modules/nise/package.json
+++ b/build/node_modules/nise/package.json
@@ -1,6 +1,6 @@
{
"name": "nise",
- "version": "5.1.5",
+ "version": "5.1.7",
"description": "Fake XHR and server",
"keywords": [
"test",
@@ -46,28 +46,28 @@
"!lib/**/*.test.js"
],
"devDependencies": {
- "@sinonjs/eslint-config": "^4.0.5",
- "@sinonjs/referee": "^9.1.1",
- "browserify": "^16.2.3",
- "husky": "^4.2.1",
- "jsdom": "^16.2.0",
+ "@sinonjs/eslint-config": "^5.0.2",
+ "@sinonjs/referee": "^11.0.0",
+ "browserify": "^17.0.0",
+ "husky": "^4.3.8",
+ "jsdom": "^23",
"jsdom-global": "3.0.2",
- "lint-staged": "^10.5.3",
- "mocha": "^10.1.0",
+ "lint-staged": "^15.2.0",
+ "mocha": "^10.2.0",
"mochify": "^9.2.0",
- "nyc": "^15.0.0",
- "prettier": "^1.19.1",
+ "nyc": "^15.1.0",
+ "prettier": "^3.1.1",
"proxyquire": "^2.1.3",
- "proxyquire-universal": "^2.1.0",
+ "proxyquire-universal": "^3.0.1",
"proxyquireify": "^3.2.1",
- "sinon": ">=9"
+ "sinon": ">=17"
},
"dependencies": {
- "@sinonjs/commons": "^2.0.0",
- "@sinonjs/fake-timers": "^10.0.2",
- "@sinonjs/text-encoding": "^0.7.1",
- "just-extend": "^4.0.2",
- "path-to-regexp": "^1.7.0"
+ "@sinonjs/commons": "^3.0.0",
+ "@sinonjs/fake-timers": "^11.2.2",
+ "@sinonjs/text-encoding": "^0.7.2",
+ "just-extend": "^6.2.0",
+ "path-to-regexp": "^6.2.1"
},
"lint-staged": {
"*.{js,css,md}": "prettier --check",
diff --git a/build/node_modules/path-to-regexp/History.md b/build/node_modules/path-to-regexp/History.md
deleted file mode 100644
index abe4a659..00000000
--- a/build/node_modules/path-to-regexp/History.md
+++ /dev/null
@@ -1,158 +0,0 @@
-1.7.0 / 2016-11-08
-==================
-
- * Allow a `delimiter` option to be passed in with `tokensToRegExp` which will be used for "non-ending" token match situations
-
-1.6.0 / 2016-10-03
-==================
-
- * Populate `RegExp.keys` when using the `tokensToRegExp` method (making it consistent with the main export)
- * Allow a `delimiter` option to be passed in with `parse`
- * Updated TypeScript definition with `Keys` and `Options` updated
-
-1.5.3 / 2016-06-15
-==================
-
- * Add `\\` to the ignore character group to avoid backtracking on mismatched parens
-
-1.5.2 / 2016-06-15
-==================
-
- * Escape `\\` in string segments of regexp
-
-1.5.1 / 2016-06-08
-==================
-
- * Add `index.d.ts` to NPM package
-
-1.5.0 / 2016-05-20
-==================
-
- * Handle partial token segments (better)
- * Allow compile to handle asterisk token segments
-
-1.4.0 / 2016-05-18
-==================
-
- * Handle RegExp unions in path matching groups
-
-1.3.0 / 2016-05-08
-==================
-
- * Clarify README language and named parameter token support
- * Support advanced Closure Compiler with type annotations
- * Add pretty paths options to compiled function output
- * Add TypeScript definition to project
- * Improved prefix handling with non-complete segment parameters (E.g. `/:foo?-bar`)
-
-1.2.1 / 2015-08-17
-==================
-
- * Encode values before validation with path compilation function
- * More examples of using compilation in README
-
-1.2.0 / 2015-05-20
-==================
-
- * Add support for matching an asterisk (`*`) as an unnamed match everything group (`(.*)`)
-
-1.1.1 / 2015-05-11
-==================
-
- * Expose methods for working with path tokens
-
-1.1.0 / 2015-05-09
-==================
-
- * Expose the parser implementation to consumers
- * Implement a compiler function to generate valid strings
- * Huge refactor of tests to be more DRY and cover new parse and compile functions
- * Use chai in tests
- * Add .editorconfig
-
-1.0.3 / 2015-01-17
-==================
-
- * Optimised function runtime
- * Added `files` to `package.json`
-
-1.0.2 / 2014-12-17
-==================
-
- * Use `Array.isArray` shim
- * Remove ES5 incompatible code
- * Fixed repository path
- * Added new readme badges
-
-1.0.1 / 2014-08-27
-==================
-
- * Ensure installation works correctly on 0.8
-
-1.0.0 / 2014-08-17
-==================
-
- * No more API changes
-
-0.2.5 / 2014-08-07
-==================
-
- * Allow keys parameter to be omitted
-
-0.2.4 / 2014-08-02
-==================
-
- * Code coverage badge
- * Updated readme
- * Attach keys to the generated regexp
-
-0.2.3 / 2014-07-09
-==================
-
- * Add MIT license
-
-0.2.2 / 2014-07-06
-==================
-
- * A passed in trailing slash in non-strict mode will become optional
- * In non-end mode, the optional trailing slash will only match at the end
-
-0.2.1 / 2014-06-11
-==================
-
- * Fixed a major capturing group regexp regression
-
-0.2.0 / 2014-06-09
-==================
-
- * Improved support for arrays
- * Improved support for regexps
- * Better support for non-ending strict mode matches with a trailing slash
- * Travis CI support
- * Block using regexp special characters in the path
- * Removed support for the asterisk to match all
- * New support for parameter suffixes - `*`, `+` and `?`
- * Updated readme
- * Provide delimiter information with keys array
-
-0.1.2 / 2014-03-10
-==================
-
- * Move testing dependencies to `devDependencies`
-
-0.1.1 / 2014-03-10
-==================
-
- * Match entire substring with `options.end`
- * Properly handle ending and non-ending matches
-
-0.1.0 / 2014-03-06
-==================
-
- * Add `options.end`
-
-0.0.2 / 2013-02-10
-==================
-
- * Update to match current express
- * Add .license property to component.json
diff --git a/build/node_modules/path-to-regexp/Readme.md b/build/node_modules/path-to-regexp/Readme.md
index 379ecf4b..b40f8cea 100644
--- a/build/node_modules/path-to-regexp/Readme.md
+++ b/build/node_modules/path-to-regexp/Readme.md
@@ -1,13 +1,12 @@
# Path-to-RegExp
-> Turn an Express-style path string such as `/user/:name` into a regular expression.
+> Turn a path string such as `/user/:name` into a regular expression.
[![NPM version][npm-image]][npm-url]
-[![Build status][travis-image]][travis-url]
-[![Test coverage][coveralls-image]][coveralls-url]
-[![Dependency Status][david-image]][david-url]
+[![NPM downloads][downloads-image]][downloads-url]
+[![Build status][build-image]][build-url]
+[![Build coverage][coverage-image]][coverage-url]
[![License][license-image]][license-url]
-[![Downloads][downloads-image]][downloads-url]
## Installation
@@ -18,240 +17,337 @@ npm install path-to-regexp --save
## Usage
```javascript
-var pathToRegexp = require('path-to-regexp')
+const { pathToRegexp, match, parse, compile } = require("path-to-regexp");
-// pathToRegexp(path, keys, options)
-// pathToRegexp.parse(path)
-// pathToRegexp.compile(path)
+// pathToRegexp(path, keys?, options?)
+// match(path)
+// parse(path)
+// compile(path)
```
-- **path** An Express-style string, an array of strings, or a regular expression.
-- **keys** An array to be populated with the keys found in the path.
-- **options**
- - **sensitive** When `true` the route will be case sensitive. (default: `false`)
- - **strict** When `false` the trailing slash is optional. (default: `false`)
- - **end** When `false` the path will match at the beginning. (default: `true`)
- - **delimiter** Set the default delimiter for repeat parameters. (default: `'/'`)
+### Path to regexp
+
+The `pathToRegexp` function will return a regular expression object based on the provided `path` argument. It accepts the following arguments:
+
+- **path** A string, array of strings, or a regular expression.
+- **keys** _(optional)_ An array to populate with keys found in the path.
+- **options** _(optional)_
+ - **sensitive** When `true` the regexp will be case sensitive. (default: `false`)
+ - **strict** When `true` the regexp won't allow an optional trailing delimiter to match. (default: `false`)
+ - **end** When `true` the regexp will match to the end of the string. (default: `true`)
+ - **start** When `true` the regexp will match from the beginning of the string. (default: `true`)
+ - **delimiter** The default delimiter for segments, e.g. `[^/#?]` for `:named` patterns. (default: `'/#?'`)
+ - **endsWith** Optional character, or list of characters, to treat as "end" characters.
+ - **encode** A function to encode strings before inserting into `RegExp`. (default: `x => x`)
+ - **prefixes** List of characters to automatically consider prefixes when parsing. (default: `./`)
```javascript
-var keys = []
-var re = pathToRegexp('/foo/:bar', keys)
-// re = /^\/foo\/([^\/]+?)\/?$/i
-// keys = [{ name: 'bar', prefix: '/', delimiter: '/', optional: false, repeat: false, pattern: '[^\\/]+?' }]
+const keys = [];
+const regexp = pathToRegexp("/foo/:bar", keys);
+// regexp = /^\/foo(?:\/([^\/#\?]+?))[\/#\?]?$/i
+// keys = [{ name: 'bar', prefix: '/', suffix: '', pattern: '[^\\/#\\?]+?', modifier: '' }]
```
-**Please note:** The `RegExp` returned by `path-to-regexp` is intended for use with pathnames or hostnames. It can not handle the query strings or fragments of a URL.
+**Please note:** The `RegExp` returned by `path-to-regexp` is intended for ordered data (e.g. pathnames, hostnames). It can not handle arbitrarily ordered data (e.g. query strings, URL fragments, JSON, etc). When using paths that contain query strings, you need to escape the question mark (`?`) to ensure it does not flag the parameter as [optional](#optional).
### Parameters
-The path string can be used to define parameters and populate the keys.
+The path argument is used to define parameters and populate keys.
#### Named Parameters
-Named parameters are defined by prefixing a colon to the parameter name (`:foo`). By default, the parameter will match until the following path segment.
+Named parameters are defined by prefixing a colon to the parameter name (`:foo`).
```js
-var re = pathToRegexp('/:foo/:bar', keys)
+const regexp = pathToRegexp("/:foo/:bar");
// keys = [{ name: 'foo', prefix: '/', ... }, { name: 'bar', prefix: '/', ... }]
-re.exec('/test/route')
-//=> ['/test/route', 'test', 'route']
+regexp.exec("/test/route");
+//=> [ '/test/route', 'test', 'route', index: 0, input: '/test/route', groups: undefined ]
+```
+
+**Please note:** Parameter names must use "word characters" (`[A-Za-z0-9_]`).
+
+##### Custom Matching Parameters
+
+Parameters can have a custom regexp, which overrides the default match (`[^/]+`). For example, you can match digits or names in a path:
+
+```js
+const regexpNumbers = pathToRegexp("/icon-:foo(\\d+).png");
+// keys = [{ name: 'foo', ... }]
+
+regexpNumbers.exec("/icon-123.png");
+//=> ['/icon-123.png', '123']
+
+regexpNumbers.exec("/icon-abc.png");
+//=> null
+
+const regexpWord = pathToRegexp("/(user|u)");
+// keys = [{ name: 0, ... }]
+
+regexpWord.exec("/u");
+//=> ['/u', 'u']
+
+regexpWord.exec("/users");
+//=> null
+```
+
+**Tip:** Backslashes need to be escaped with another backslash in JavaScript strings.
+
+##### Custom Prefix and Suffix
+
+Parameters can be wrapped in `{}` to create custom prefixes or suffixes for your segment:
+
+```js
+const regexp = pathToRegexp("/:attr1?{-:attr2}?{-:attr3}?");
+
+regexp.exec("/test");
+// => ['/test', 'test', undefined, undefined]
+
+regexp.exec("/test-test");
+// => ['/test', 'test', 'test', undefined]
```
-**Please note:** Named parameters must be made up of "word characters" (`[A-Za-z0-9_]`).
+#### Unnamed Parameters
+
+It is possible to write an unnamed parameter that only consists of a regexp. It works the same the named parameter, except it will be numerically indexed:
```js
-var re = pathToRegexp('/(apple-)?icon-:res(\\d+).png', keys)
-// keys = [{ name: 0, prefix: '/', ... }, { name: 'res', prefix: '', ... }]
+const regexp = pathToRegexp("/:foo/(.*)");
+// keys = [{ name: 'foo', ... }, { name: 0, ... }]
-re.exec('/icon-76.png')
-//=> ['/icon-76.png', undefined, '76']
+regexp.exec("/test/route");
+//=> [ '/test/route', 'test', 'route', index: 0, input: '/test/route', groups: undefined ]
```
-#### Modified Parameters
+#### Modifiers
+
+Modifiers must be placed after the parameter (e.g. `/:foo?`, `/(test)?`, `/:foo(test)?`, or `{-:foo(test)}?`).
##### Optional
-Parameters can be suffixed with a question mark (`?`) to make the parameter optional. This will also make the prefix optional.
+Parameters can be suffixed with a question mark (`?`) to make the parameter optional.
```js
-var re = pathToRegexp('/:foo/:bar?', keys)
-// keys = [{ name: 'foo', ... }, { name: 'bar', delimiter: '/', optional: true, repeat: false }]
+const regexp = pathToRegexp("/:foo/:bar?");
+// keys = [{ name: 'foo', ... }, { name: 'bar', prefix: '/', modifier: '?' }]
-re.exec('/test')
-//=> ['/test', 'test', undefined]
+regexp.exec("/test");
+//=> [ '/test', 'test', undefined, index: 0, input: '/test', groups: undefined ]
-re.exec('/test/route')
-//=> ['/test', 'test', 'route']
+regexp.exec("/test/route");
+//=> [ '/test/route', 'test', 'route', index: 0, input: '/test/route', groups: undefined ]
+```
+
+**Tip:** The prefix is also optional, escape the prefix `\/` to make it required.
+
+When dealing with query strings, escape the question mark (`?`) so it doesn't mark the parameter as optional. Handling unordered data is outside the scope of this library.
+
+```js
+const regexp = pathToRegexp("/search/:tableName\\?useIndex=true&term=amazing");
+
+regexp.exec("/search/people?useIndex=true&term=amazing");
+//=> [ '/search/people?useIndex=true&term=amazing', 'people', index: 0, input: '/search/people?useIndex=true&term=amazing', groups: undefined ]
+
+// This library does not handle query strings in different orders
+regexp.exec("/search/people?term=amazing&useIndex=true");
+//=> null
```
##### Zero or more
-Parameters can be suffixed with an asterisk (`*`) to denote a zero or more parameter matches. The prefix is taken into account for each match.
+Parameters can be suffixed with an asterisk (`*`) to denote a zero or more parameter matches.
```js
-var re = pathToRegexp('/:foo*', keys)
-// keys = [{ name: 'foo', delimiter: '/', optional: true, repeat: true }]
+const regexp = pathToRegexp("/:foo*");
+// keys = [{ name: 'foo', prefix: '/', modifier: '*' }]
-re.exec('/')
-//=> ['/', undefined]
+regexp.exec("/");
+//=> [ '/', undefined, index: 0, input: '/', groups: undefined ]
-re.exec('/bar/baz')
-//=> ['/bar/baz', 'bar/baz']
+regexp.exec("/bar/baz");
+//=> [ '/bar/baz', 'bar/baz', index: 0, input: '/bar/baz', groups: undefined ]
```
##### One or more
-Parameters can be suffixed with a plus sign (`+`) to denote a one or more parameter matches. The prefix is taken into account for each match.
+Parameters can be suffixed with a plus sign (`+`) to denote a one or more parameter matches.
```js
-var re = pathToRegexp('/:foo+', keys)
-// keys = [{ name: 'foo', delimiter: '/', optional: false, repeat: true }]
+const regexp = pathToRegexp("/:foo+");
+// keys = [{ name: 'foo', prefix: '/', modifier: '+' }]
-re.exec('/')
+regexp.exec("/");
//=> null
-re.exec('/bar/baz')
-//=> ['/bar/baz', 'bar/baz']
+regexp.exec("/bar/baz");
+//=> [ '/bar/baz','bar/baz', index: 0, input: '/bar/baz', groups: undefined ]
```
-#### Custom Match Parameters
+### Match
-All parameters can be provided a custom regexp, which overrides the default (`[^\/]+`).
+The `match` function will return a function for transforming paths into parameters:
```js
-var re = pathToRegexp('/:foo(\\d+)', keys)
-// keys = [{ name: 'foo', ... }]
+// Make sure you consistently `decode` segments.
+const fn = match("/user/:id", { decode: decodeURIComponent });
-re.exec('/123')
-//=> ['/123', '123']
-
-re.exec('/abc')
-//=> null
+fn("/user/123"); //=> { path: '/user/123', index: 0, params: { id: '123' } }
+fn("/invalid"); //=> false
+fn("/user/caf%C3%A9"); //=> { path: '/user/caf%C3%A9', index: 0, params: { id: 'café' } }
```
-**Please note:** Backslashes need to be escaped with another backslash in strings.
+The `match` function can be used to custom match named parameters. For example, this can be used to whitelist a small number of valid paths:
-#### Unnamed Parameters
+```js
+const urlMatch = match("/users/:id/:tab(home|photos|bio)", {
+ decode: decodeURIComponent,
+});
-It is possible to write an unnamed parameter that only consists of a matching group. It works the same as a named parameter, except it will be numerically indexed.
+urlMatch("/users/1234/photos");
+//=> { path: '/users/1234/photos', index: 0, params: { id: '1234', tab: 'photos' } }
-```js
-var re = pathToRegexp('/:foo/(.*)', keys)
-// keys = [{ name: 'foo', ... }, { name: 0, ... }]
+urlMatch("/users/1234/bio");
+//=> { path: '/users/1234/bio', index: 0, params: { id: '1234', tab: 'bio' } }
-re.exec('/test/route')
-//=> ['/test/route', 'test', 'route']
+urlMatch("/users/1234/otherstuff");
+//=> false
```
-#### Asterisk
+#### Process Pathname
-An asterisk can be used for matching everything. It is equivalent to an unnamed matching group of `(.*)`.
+You should make sure variations of the same path match the expected `path`. Here's one possible solution using `encode`:
```js
-var re = pathToRegexp('/foo/*', keys)
-// keys = [{ name: '0', ... }]
+const fn = match("/café", { encode: encodeURI });
+
+fn("/caf%C3%A9"); //=> { path: '/caf%C3%A9', index: 0, params: {} }
+```
+
+**Note:** [`URL`](https://developer.mozilla.org/en-US/docs/Web/API/URL) encodes paths, so `/café` would be normalized to `/caf%C3%A9` and match in the above example.
-re.exec('/foo/bar/baz')
-//=> ['/foo/bar/baz', 'bar/baz']
+##### Alternative Using Normalize
+
+Sometimes you won't have already normalized paths to use, so you could normalize it yourself before matching:
+
+```js
+/**
+ * Normalize a pathname for matching, replaces multiple slashes with a single
+ * slash and normalizes unicode characters to "NFC". When using this method,
+ * `decode` should be an identity function so you don't decode strings twice.
+ */
+function normalizePathname(pathname: string) {
+ return (
+ decodeURI(pathname)
+ // Replaces repeated slashes in the URL.
+ .replace(/\/+/g, "/")
+ // Reference: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/normalize
+ // Note: Missing native IE support, may want to skip this step.
+ .normalize()
+ );
+}
+
+// Two possible ways of writing `/café`:
+const re = pathToRegexp("/caf\u00E9");
+const input = encodeURI("/cafe\u0301");
+
+re.test(input); //=> false
+re.test(normalizePathname(input)); //=> true
```
### Parse
-The parse function is exposed via `pathToRegexp.parse`. This will return an array of strings and keys.
+The `parse` function will return a list of strings and keys from a path string:
```js
-var tokens = pathToRegexp.parse('/route/:foo/(.*)')
+const tokens = parse("/route/:foo/(.*)");
-console.log(tokens[0])
+console.log(tokens[0]);
//=> "/route"
-console.log(tokens[1])
-//=> { name: 'foo', prefix: '/', delimiter: '/', optional: false, repeat: false, pattern: '[^\\/]+?' }
+console.log(tokens[1]);
+//=> { name: 'foo', prefix: '/', suffix: '', pattern: '[^\\/#\\?]+?', modifier: '' }
-console.log(tokens[2])
-//=> { name: 0, prefix: '/', delimiter: '/', optional: false, repeat: false, pattern: '.*' }
+console.log(tokens[2]);
+//=> { name: 0, prefix: '/', suffix: '', pattern: '.*', modifier: '' }
```
-**Note:** This method only works with Express-style strings.
+**Note:** This method only works with strings.
### Compile ("Reverse" Path-To-RegExp)
-Path-To-RegExp exposes a compile function for transforming an Express-style path into a valid path.
+The `compile` function will return a function for transforming parameters into a valid path:
```js
-var toPath = pathToRegexp.compile('/user/:id')
+// Make sure you encode your path segments consistently.
+const toPath = compile("/user/:id", { encode: encodeURIComponent });
-toPath({ id: 123 }) //=> "/user/123"
-toPath({ id: 'café' }) //=> "/user/caf%C3%A9"
-toPath({ id: '/' }) //=> "/user/%2F"
+toPath({ id: 123 }); //=> "/user/123"
+toPath({ id: "café" }); //=> "/user/caf%C3%A9"
+toPath({ id: "/" }); //=> "/user/%2F"
-toPath({ id: ':' }) //=> "/user/%3A"
-toPath({ id: ':' }, { pretty: true }) //=> "/user/:"
+toPath({ id: ":/" }); //=> "/user/%3A%2F"
-var toPathRepeated = pathToRegexp.compile('/:segment+')
+// Without `encode`, you need to make sure inputs are encoded correctly.
+const toPathRaw = compile("/user/:id");
-toPathRepeated({ segment: 'foo' }) //=> "/foo"
-toPathRepeated({ segment: ['a', 'b', 'c'] }) //=> "/a/b/c"
+toPathRaw({ id: "%3A%2F" }); //=> "/user/%3A%2F"
+toPathRaw({ id: ":/" }, { validate: false }); //=> "/user/:/"
-var toPathRegexp = pathToRegexp.compile('/user/:id(\\d+)')
+const toPathRepeated = compile("/:segment+");
-toPathRegexp({ id: 123 }) //=> "/user/123"
-toPathRegexp({ id: '123' }) //=> "/user/123"
-toPathRegexp({ id: 'abc' }) //=> Throws `TypeError`.
+toPathRepeated({ segment: "foo" }); //=> "/foo"
+toPathRepeated({ segment: ["a", "b", "c"] }); //=> "/a/b/c"
+
+const toPathRegexp = compile("/user/:id(\\d+)");
+
+toPathRegexp({ id: 123 }); //=> "/user/123"
+toPathRegexp({ id: "123" }); //=> "/user/123"
+toPathRegexp({ id: "abc" }); //=> Throws `TypeError`.
+toPathRegexp({ id: "abc" }, { validate: false }); //=> "/user/abc"
```
-**Note:** The generated function will throw on invalid input. It will do all necessary checks to ensure the generated path is valid. This method only works with strings.
+**Note:** The generated function will throw on invalid input.
### Working with Tokens
-Path-To-RegExp exposes the two functions used internally that accept an array of tokens.
+Path-To-RegExp exposes the two functions used internally that accept an array of tokens:
-* `pathToRegexp.tokensToRegExp(tokens, options)` Transform an array of tokens into a matching regular expression.
-* `pathToRegexp.tokensToFunction(tokens)` Transform an array of tokens into a path generator function.
+- `tokensToRegexp(tokens, keys?, options?)` Transform an array of tokens into a matching regular expression.
+- `tokensToFunction(tokens)` Transform an array of tokens into a path generator function.
#### Token Information
-* `name` The name of the token (`string` for named or `number` for index)
-* `prefix` The prefix character for the segment (`/` or `.`)
-* `delimiter` The delimiter for the segment (same as prefix or `/`)
-* `optional` Indicates the token is optional (`boolean`)
-* `repeat` Indicates the token is repeated (`boolean`)
-* `partial` Indicates this token is a partial path segment (`boolean`)
-* `pattern` The RegExp used to match this token (`string`)
-* `asterisk` Indicates the token is an `*` match (`boolean`)
+- `name` The name of the token (`string` for named or `number` for unnamed index)
+- `prefix` The prefix string for the segment (e.g. `"/"`)
+- `suffix` The suffix string for the segment (e.g. `""`)
+- `pattern` The RegExp used to match this token (`string`)
+- `modifier` The modifier character used for the segment (e.g. `?`)
## Compatibility with Express <= 4.x
Path-To-RegExp breaks compatibility with Express <= `4.x`:
-* No longer a direct conversion to a RegExp with sugar on top - it's a path matcher with named and unnamed matching groups
- * It's unlikely you previously abused this feature, it's rare and you could always use a RegExp instead
-* All matching RegExp special characters can be used in a matching group. E.g. `/:user(.*)`
- * Other RegExp features are not support - no nested matching groups, non-capturing groups or look aheads
-* Parameters have suffixes that augment meaning - `*`, `+` and `?`. E.g. `/:user*`
-
-## TypeScript
-
-Includes a [`.d.ts`](index.d.ts) file for TypeScript users.
+- RegExp special characters can only be used in a parameter
+ - Express.js 4.x supported `RegExp` special characters regardless of position - this is considered a bug
+- Parameters have suffixes that augment meaning - `*`, `+` and `?`. E.g. `/:user*`
+- No wildcard asterisk (`*`) - use parameters instead (`(.*)` or `:splat*`)
## Live Demo
-You can see a live demo of this library in use at [express-route-tester](http://forbeslindesay.github.com/express-route-tester/).
+You can see a live demo of this library in use at [express-route-tester](http://forbeslindesay.github.io/express-route-tester/).
## License
MIT
-[npm-image]: https://img.shields.io/npm/v/path-to-regexp.svg?style=flat
+[npm-image]: https://img.shields.io/npm/v/path-to-regexp
[npm-url]: https://npmjs.org/package/path-to-regexp
-[travis-image]: https://img.shields.io/travis/pillarjs/path-to-regexp.svg?style=flat
-[travis-url]: https://travis-ci.org/pillarjs/path-to-regexp
-[coveralls-image]: https://img.shields.io/coveralls/pillarjs/path-to-regexp.svg?style=flat
-[coveralls-url]: https://coveralls.io/r/pillarjs/path-to-regexp?branch=master
-[david-image]: http://img.shields.io/david/pillarjs/path-to-regexp.svg?style=flat
-[david-url]: https://david-dm.org/pillarjs/path-to-regexp
+[downloads-image]: https://img.shields.io/npm/dm/path-to-regexp
+[downloads-url]: https://npmjs.org/package/path-to-regexp
+[build-image]: https://img.shields.io/github/workflow/status/pillarjs/path-to-regexp/CI/master
+[build-url]: https://github.com/pillarjs/path-to-regexp/actions/workflows/ci.yml?query=branch%3Amaster
+[coverage-image]: https://img.shields.io/codecov/c/gh/pillarjs/path-to-regexp
+[coverage-url]: https://codecov.io/gh/pillarjs/path-to-regexp
[license-image]: http://img.shields.io/npm/l/path-to-regexp.svg?style=flat
[license-url]: LICENSE.md
-[downloads-image]: http://img.shields.io/npm/dm/path-to-regexp.svg?style=flat
-[downloads-url]: https://npmjs.org/package/path-to-regexp
diff --git a/build/node_modules/path-to-regexp/dist.es2015/index.js b/build/node_modules/path-to-regexp/dist.es2015/index.js
new file mode 100644
index 00000000..f891c1b9
--- /dev/null
+++ b/build/node_modules/path-to-regexp/dist.es2015/index.js
@@ -0,0 +1,400 @@
+/**
+ * Tokenize input string.
+ */
+function lexer(str) {
+ var tokens = [];
+ var i = 0;
+ while (i < str.length) {
+ var char = str[i];
+ if (char === "*" || char === "+" || char === "?") {
+ tokens.push({ type: "MODIFIER", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === "\\") {
+ tokens.push({ type: "ESCAPED_CHAR", index: i++, value: str[i++] });
+ continue;
+ }
+ if (char === "{") {
+ tokens.push({ type: "OPEN", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === "}") {
+ tokens.push({ type: "CLOSE", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === ":") {
+ var name = "";
+ var j = i + 1;
+ while (j < str.length) {
+ var code = str.charCodeAt(j);
+ if (
+ // `0-9`
+ (code >= 48 && code <= 57) ||
+ // `A-Z`
+ (code >= 65 && code <= 90) ||
+ // `a-z`
+ (code >= 97 && code <= 122) ||
+ // `_`
+ code === 95) {
+ name += str[j++];
+ continue;
+ }
+ break;
+ }
+ if (!name)
+ throw new TypeError("Missing parameter name at ".concat(i));
+ tokens.push({ type: "NAME", index: i, value: name });
+ i = j;
+ continue;
+ }
+ if (char === "(") {
+ var count = 1;
+ var pattern = "";
+ var j = i + 1;
+ if (str[j] === "?") {
+ throw new TypeError("Pattern cannot start with \"?\" at ".concat(j));
+ }
+ while (j < str.length) {
+ if (str[j] === "\\") {
+ pattern += str[j++] + str[j++];
+ continue;
+ }
+ if (str[j] === ")") {
+ count--;
+ if (count === 0) {
+ j++;
+ break;
+ }
+ }
+ else if (str[j] === "(") {
+ count++;
+ if (str[j + 1] !== "?") {
+ throw new TypeError("Capturing groups are not allowed at ".concat(j));
+ }
+ }
+ pattern += str[j++];
+ }
+ if (count)
+ throw new TypeError("Unbalanced pattern at ".concat(i));
+ if (!pattern)
+ throw new TypeError("Missing pattern at ".concat(i));
+ tokens.push({ type: "PATTERN", index: i, value: pattern });
+ i = j;
+ continue;
+ }
+ tokens.push({ type: "CHAR", index: i, value: str[i++] });
+ }
+ tokens.push({ type: "END", index: i, value: "" });
+ return tokens;
+}
+/**
+ * Parse a string for the raw tokens.
+ */
+export function parse(str, options) {
+ if (options === void 0) { options = {}; }
+ var tokens = lexer(str);
+ var _a = options.prefixes, prefixes = _a === void 0 ? "./" : _a;
+ var defaultPattern = "[^".concat(escapeString(options.delimiter || "/#?"), "]+?");
+ var result = [];
+ var key = 0;
+ var i = 0;
+ var path = "";
+ var tryConsume = function (type) {
+ if (i < tokens.length && tokens[i].type === type)
+ return tokens[i++].value;
+ };
+ var mustConsume = function (type) {
+ var value = tryConsume(type);
+ if (value !== undefined)
+ return value;
+ var _a = tokens[i], nextType = _a.type, index = _a.index;
+ throw new TypeError("Unexpected ".concat(nextType, " at ").concat(index, ", expected ").concat(type));
+ };
+ var consumeText = function () {
+ var result = "";
+ var value;
+ while ((value = tryConsume("CHAR") || tryConsume("ESCAPED_CHAR"))) {
+ result += value;
+ }
+ return result;
+ };
+ while (i < tokens.length) {
+ var char = tryConsume("CHAR");
+ var name = tryConsume("NAME");
+ var pattern = tryConsume("PATTERN");
+ if (name || pattern) {
+ var prefix = char || "";
+ if (prefixes.indexOf(prefix) === -1) {
+ path += prefix;
+ prefix = "";
+ }
+ if (path) {
+ result.push(path);
+ path = "";
+ }
+ result.push({
+ name: name || key++,
+ prefix: prefix,
+ suffix: "",
+ pattern: pattern || defaultPattern,
+ modifier: tryConsume("MODIFIER") || "",
+ });
+ continue;
+ }
+ var value = char || tryConsume("ESCAPED_CHAR");
+ if (value) {
+ path += value;
+ continue;
+ }
+ if (path) {
+ result.push(path);
+ path = "";
+ }
+ var open = tryConsume("OPEN");
+ if (open) {
+ var prefix = consumeText();
+ var name_1 = tryConsume("NAME") || "";
+ var pattern_1 = tryConsume("PATTERN") || "";
+ var suffix = consumeText();
+ mustConsume("CLOSE");
+ result.push({
+ name: name_1 || (pattern_1 ? key++ : ""),
+ pattern: name_1 && !pattern_1 ? defaultPattern : pattern_1,
+ prefix: prefix,
+ suffix: suffix,
+ modifier: tryConsume("MODIFIER") || "",
+ });
+ continue;
+ }
+ mustConsume("END");
+ }
+ return result;
+}
+/**
+ * Compile a string to a template function for the path.
+ */
+export function compile(str, options) {
+ return tokensToFunction(parse(str, options), options);
+}
+/**
+ * Expose a method for transforming tokens into the path function.
+ */
+export function tokensToFunction(tokens, options) {
+ if (options === void 0) { options = {}; }
+ var reFlags = flags(options);
+ var _a = options.encode, encode = _a === void 0 ? function (x) { return x; } : _a, _b = options.validate, validate = _b === void 0 ? true : _b;
+ // Compile all the tokens into regexps.
+ var matches = tokens.map(function (token) {
+ if (typeof token === "object") {
+ return new RegExp("^(?:".concat(token.pattern, ")$"), reFlags);
+ }
+ });
+ return function (data) {
+ var path = "";
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (typeof token === "string") {
+ path += token;
+ continue;
+ }
+ var value = data ? data[token.name] : undefined;
+ var optional = token.modifier === "?" || token.modifier === "*";
+ var repeat = token.modifier === "*" || token.modifier === "+";
+ if (Array.isArray(value)) {
+ if (!repeat) {
+ throw new TypeError("Expected \"".concat(token.name, "\" to not repeat, but got an array"));
+ }
+ if (value.length === 0) {
+ if (optional)
+ continue;
+ throw new TypeError("Expected \"".concat(token.name, "\" to not be empty"));
+ }
+ for (var j = 0; j < value.length; j++) {
+ var segment = encode(value[j], token);
+ if (validate && !matches[i].test(segment)) {
+ throw new TypeError("Expected all \"".concat(token.name, "\" to match \"").concat(token.pattern, "\", but got \"").concat(segment, "\""));
+ }
+ path += token.prefix + segment + token.suffix;
+ }
+ continue;
+ }
+ if (typeof value === "string" || typeof value === "number") {
+ var segment = encode(String(value), token);
+ if (validate && !matches[i].test(segment)) {
+ throw new TypeError("Expected \"".concat(token.name, "\" to match \"").concat(token.pattern, "\", but got \"").concat(segment, "\""));
+ }
+ path += token.prefix + segment + token.suffix;
+ continue;
+ }
+ if (optional)
+ continue;
+ var typeOfMessage = repeat ? "an array" : "a string";
+ throw new TypeError("Expected \"".concat(token.name, "\" to be ").concat(typeOfMessage));
+ }
+ return path;
+ };
+}
+/**
+ * Create path match function from `path-to-regexp` spec.
+ */
+export function match(str, options) {
+ var keys = [];
+ var re = pathToRegexp(str, keys, options);
+ return regexpToFunction(re, keys, options);
+}
+/**
+ * Create a path match function from `path-to-regexp` output.
+ */
+export function regexpToFunction(re, keys, options) {
+ if (options === void 0) { options = {}; }
+ var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;
+ return function (pathname) {
+ var m = re.exec(pathname);
+ if (!m)
+ return false;
+ var path = m[0], index = m.index;
+ var params = Object.create(null);
+ var _loop_1 = function (i) {
+ if (m[i] === undefined)
+ return "continue";
+ var key = keys[i - 1];
+ if (key.modifier === "*" || key.modifier === "+") {
+ params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {
+ return decode(value, key);
+ });
+ }
+ else {
+ params[key.name] = decode(m[i], key);
+ }
+ };
+ for (var i = 1; i < m.length; i++) {
+ _loop_1(i);
+ }
+ return { path: path, index: index, params: params };
+ };
+}
+/**
+ * Escape a regular expression string.
+ */
+function escapeString(str) {
+ return str.replace(/([.+*?=^!:${}()[\]|/\\])/g, "\\$1");
+}
+/**
+ * Get the flags for a regexp from the options.
+ */
+function flags(options) {
+ return options && options.sensitive ? "" : "i";
+}
+/**
+ * Pull out keys from a regexp.
+ */
+function regexpToRegexp(path, keys) {
+ if (!keys)
+ return path;
+ var groupsRegex = /\((?:\?<(.*?)>)?(?!\?)/g;
+ var index = 0;
+ var execResult = groupsRegex.exec(path.source);
+ while (execResult) {
+ keys.push({
+ // Use parenthesized substring match if available, index otherwise
+ name: execResult[1] || index++,
+ prefix: "",
+ suffix: "",
+ modifier: "",
+ pattern: "",
+ });
+ execResult = groupsRegex.exec(path.source);
+ }
+ return path;
+}
+/**
+ * Transform an array into a regexp.
+ */
+function arrayToRegexp(paths, keys, options) {
+ var parts = paths.map(function (path) { return pathToRegexp(path, keys, options).source; });
+ return new RegExp("(?:".concat(parts.join("|"), ")"), flags(options));
+}
+/**
+ * Create a path regexp from string input.
+ */
+function stringToRegexp(path, keys, options) {
+ return tokensToRegexp(parse(path, options), keys, options);
+}
+/**
+ * Expose a function for taking tokens and returning a RegExp.
+ */
+export function tokensToRegexp(tokens, keys, options) {
+ if (options === void 0) { options = {}; }
+ var _a = options.strict, strict = _a === void 0 ? false : _a, _b = options.start, start = _b === void 0 ? true : _b, _c = options.end, end = _c === void 0 ? true : _c, _d = options.encode, encode = _d === void 0 ? function (x) { return x; } : _d, _e = options.delimiter, delimiter = _e === void 0 ? "/#?" : _e, _f = options.endsWith, endsWith = _f === void 0 ? "" : _f;
+ var endsWithRe = "[".concat(escapeString(endsWith), "]|$");
+ var delimiterRe = "[".concat(escapeString(delimiter), "]");
+ var route = start ? "^" : "";
+ // Iterate over the tokens and create our regexp string.
+ for (var _i = 0, tokens_1 = tokens; _i < tokens_1.length; _i++) {
+ var token = tokens_1[_i];
+ if (typeof token === "string") {
+ route += escapeString(encode(token));
+ }
+ else {
+ var prefix = escapeString(encode(token.prefix));
+ var suffix = escapeString(encode(token.suffix));
+ if (token.pattern) {
+ if (keys)
+ keys.push(token);
+ if (prefix || suffix) {
+ if (token.modifier === "+" || token.modifier === "*") {
+ var mod = token.modifier === "*" ? "?" : "";
+ route += "(?:".concat(prefix, "((?:").concat(token.pattern, ")(?:").concat(suffix).concat(prefix, "(?:").concat(token.pattern, "))*)").concat(suffix, ")").concat(mod);
+ }
+ else {
+ route += "(?:".concat(prefix, "(").concat(token.pattern, ")").concat(suffix, ")").concat(token.modifier);
+ }
+ }
+ else {
+ if (token.modifier === "+" || token.modifier === "*") {
+ route += "((?:".concat(token.pattern, ")").concat(token.modifier, ")");
+ }
+ else {
+ route += "(".concat(token.pattern, ")").concat(token.modifier);
+ }
+ }
+ }
+ else {
+ route += "(?:".concat(prefix).concat(suffix, ")").concat(token.modifier);
+ }
+ }
+ }
+ if (end) {
+ if (!strict)
+ route += "".concat(delimiterRe, "?");
+ route += !options.endsWith ? "$" : "(?=".concat(endsWithRe, ")");
+ }
+ else {
+ var endToken = tokens[tokens.length - 1];
+ var isEndDelimited = typeof endToken === "string"
+ ? delimiterRe.indexOf(endToken[endToken.length - 1]) > -1
+ : endToken === undefined;
+ if (!strict) {
+ route += "(?:".concat(delimiterRe, "(?=").concat(endsWithRe, "))?");
+ }
+ if (!isEndDelimited) {
+ route += "(?=".concat(delimiterRe, "|").concat(endsWithRe, ")");
+ }
+ }
+ return new RegExp(route, flags(options));
+}
+/**
+ * Normalize the given path string, returning a regular expression.
+ *
+ * An empty array can be passed in for the keys, which will hold the
+ * placeholder key descriptions. For example, using `/user/:id`, `keys` will
+ * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
+ */
+export function pathToRegexp(path, keys, options) {
+ if (path instanceof RegExp)
+ return regexpToRegexp(path, keys);
+ if (Array.isArray(path))
+ return arrayToRegexp(path, keys, options);
+ return stringToRegexp(path, keys, options);
+}
+//# sourceMappingURL=index.js.map
\ No newline at end of file
diff --git a/build/node_modules/path-to-regexp/dist.es2015/index.js.map b/build/node_modules/path-to-regexp/dist.es2015/index.js.map
new file mode 100644
index 00000000..7d2fc720
--- /dev/null
+++ b/build/node_modules/path-to-regexp/dist.es2015/index.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAiBA;;GAEG;AACH,SAAS,KAAK,CAAC,GAAW;IACxB,IAAM,MAAM,GAAe,EAAE,CAAC;IAC9B,IAAI,CAAC,GAAG,CAAC,CAAC;IAEV,OAAO,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE;QACrB,IAAM,IAAI,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC;QAEpB,IAAI,IAAI,KAAK,GAAG,IAAI,IAAI,KAAK,GAAG,IAAI,IAAI,KAAK,GAAG,EAAE;YAChD,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;YAC7D,SAAS;SACV;QAED,IAAI,IAAI,KAAK,IAAI,EAAE;YACjB,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;YACnE,SAAS;SACV;QAED,IAAI,IAAI,KAAK,GAAG,EAAE;YAChB,MAAM,CAAC,IAAI,CAAC,EAAE,I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AAC;QAAE,OAAO,aAAa,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IACnE,OAAO,cAAc,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;AAC7C,CAAC","sourcesContent":["/**\n * Tokenizer results.\n */\ninterface LexToken {\n type:\n | \"OPEN\"\n | \"CLOSE\"\n | \"PATTERN\"\n | \"NAME\"\n | \"CHAR\"\n | \"ESCAPED_CHAR\"\n | \"MODIFIER\"\n | \"END\";\n index: number;\n value: string;\n}\n\n/**\n * Tokenize input string.\n */\nfunction lexer(str: string): LexToken[] {\n const tokens: LexToken[] = [];\n let i = 0;\n\n while (i < str.length) {\n const char = str[i];\n\n if (char === \"*\" || char === \"+\" || char === \"?\") {\n tokens.push({ type: \"MODIFIER\", index: i, value: str[i++] });\n continue;\n }\n\n if (char === \"\\\\\") {\n tokens.push({ type: \"ESCAPED_CHAR\", index: i++, value: str[i++] });\n continue;\n }\n\n if (char === \"{\") {\n tokens.push({ type: \"OPEN\", index: i, value: str[i++] });\n continue;\n }\n\n if (char === \"}\") {\n tokens.push({ type: \"CLOSE\", index: i, value: str[i++] });\n continue;\n }\n\n if (char === \":\") {\n let name = \"\";\n let j = i + 1;\n\n while (j < str.length) {\n const code = str.charCodeAt(j);\n\n if (\n // `0-9`\n (code >= 48 && code <= 57) ||\n // `A-Z`\n (code >= 65 && code <= 90) ||\n // `a-z`\n (code >= 97 && code <= 122) ||\n // `_`\n code === 95\n ) {\n name += str[j++];\n continue;\n }\n\n break;\n }\n\n if (!name) throw new TypeError(`Missing parameter name at ${i}`);\n\n tokens.push({ type: \"NAME\", index: i, value: name });\n i = j;\n continue;\n }\n\n if (char === \"(\") {\n let count = 1;\n let pattern = \"\";\n let j = i + 1;\n\n if (str[j] === \"?\") {\n throw new TypeError(`Pattern cannot start with \"?\" at ${j}`);\n }\n\n while (j < str.length) {\n if (str[j] === \"\\\\\") {\n pattern += str[j++] + str[j++];\n continue;\n }\n\n if (str[j] === \")\") {\n count--;\n if (count === 0) {\n j++;\n break;\n }\n } else if (str[j] === \"(\") {\n count++;\n if (str[j + 1] !== \"?\") {\n throw new TypeError(`Capturing groups are not allowed at ${j}`);\n }\n }\n\n pattern += str[j++];\n }\n\n if (count) throw new TypeError(`Unbalanced pattern at ${i}`);\n if (!pattern) throw new TypeError(`Missing pattern at ${i}`);\n\n tokens.push({ type: \"PATTERN\", index: i, value: pattern });\n i = j;\n continue;\n }\n\n tokens.push({ type: \"CHAR\", index: i, value: str[i++] });\n }\n\n tokens.push({ type: \"END\", index: i, value: \"\" });\n\n return tokens;\n}\n\nexport interface ParseOptions {\n /**\n * Set the default delimiter for repeat parameters. (default: `'/'`)\n */\n delimiter?: string;\n /**\n * List of characters to automatically consider prefixes when parsing.\n */\n prefixes?: string;\n}\n\n/**\n * Parse a string for the raw tokens.\n */\nexport function parse(str: string, options: ParseOptions = {}): Token[] {\n const tokens = lexer(str);\n const { prefixes = \"./\" } = options;\n const defaultPattern = `[^${escapeString(options.delimiter || \"/#?\")}]+?`;\n const result: Token[] = [];\n let key = 0;\n let i = 0;\n let path = \"\";\n\n const tryConsume = (type: LexToken[\"type\"]): string | undefined => {\n if (i < tokens.length && tokens[i].type === type) return tokens[i++].value;\n };\n\n const mustConsume = (type: LexToken[\"type\"]): string => {\n const value = tryConsume(type);\n if (value !== undefined) return value;\n const { type: nextType, index } = tokens[i];\n throw new TypeError(`Unexpected ${nextType} at ${index}, expected ${type}`);\n };\n\n const consumeText = (): string => {\n let result = \"\";\n let value: string | undefined;\n while ((value = tryConsume(\"CHAR\") || tryConsume(\"ESCAPED_CHAR\"))) {\n result += value;\n }\n return result;\n };\n\n while (i < tokens.length) {\n const char = tryConsume(\"CHAR\");\n const name = tryConsume(\"NAME\");\n const pattern = tryConsume(\"PATTERN\");\n\n if (name || pattern) {\n let prefix = char || \"\";\n\n if (prefixes.indexOf(prefix) === -1) {\n path += prefix;\n prefix = \"\";\n }\n\n if (path) {\n result.push(path);\n path = \"\";\n }\n\n result.push({\n name: name || key++,\n prefix,\n suffix: \"\",\n pattern: pattern || defaultPattern,\n modifier: tryConsume(\"MODIFIER\") || \"\",\n });\n continue;\n }\n\n const value = char || tryConsume(\"ESCAPED_CHAR\");\n if (value) {\n path += value;\n continue;\n }\n\n if (path) {\n result.push(path);\n path = \"\";\n }\n\n const open = tryConsume(\"OPEN\");\n if (open) {\n const prefix = consumeText();\n const name = tryConsume(\"NAME\") || \"\";\n const pattern = tryConsume(\"PATTERN\") || \"\";\n const suffix = consumeText();\n\n mustConsume(\"CLOSE\");\n\n result.push({\n name: name || (pattern ? key++ : \"\"),\n pattern: name && !pattern ? defaultPattern : pattern,\n prefix,\n suffix,\n modifier: tryConsume(\"MODIFIER\") || \"\",\n });\n continue;\n }\n\n mustConsume(\"END\");\n }\n\n return result;\n}\n\nexport interface TokensToFunctionOptions {\n /**\n * When `true` the regexp will be case sensitive. (default: `false`)\n */\n sensitive?: boolean;\n /**\n * Function for encoding input strings for output.\n */\n encode?: (value: string, token: Key) => string;\n /**\n * When `false` the function can produce an invalid (unmatched) path. (default: `true`)\n */\n validate?: boolean;\n}\n\n/**\n * Compile a string to a template function for the path.\n */\nexport function compile(\n str: string,\n options?: ParseOptions & TokensToFunctionOptions\n) {\n return tokensToFunction
(parse(str, options), options);\n}\n\nexport type PathFunction
= (data?: P) => string;\n\n/**\n * Expose a method for transforming tokens into the path function.\n */\nexport function tokensToFunction
(\n tokens: Token[],\n options: TokensToFunctionOptions = {}\n): PathFunction
{\n const reFlags = flags(options);\n const { encode = (x: string) => x, validate = true } = options;\n\n // Compile all the tokens into regexps.\n const matches = tokens.map((token) => {\n if (typeof token === \"object\") {\n return new RegExp(`^(?:${token.pattern})$`, reFlags);\n }\n });\n\n return (data: Record | null | undefined) => {\n let path = \"\";\n\n for (let i = 0; i < tokens.length; i++) {\n const token = tokens[i];\n\n if (typeof token === \"string\") {\n path += token;\n continue;\n }\n\n const value = data ? data[token.name] : undefined;\n const optional = token.modifier === \"?\" || token.modifier === \"*\";\n const repeat = token.modifier === \"*\" || token.modifier === \"+\";\n\n if (Array.isArray(value)) {\n if (!repeat) {\n throw new TypeError(\n `Expected \"${token.name}\" to not repeat, but got an array`\n );\n }\n\n if (value.length === 0) {\n if (optional) continue;\n\n throw new TypeError(`Expected \"${token.name}\" to not be empty`);\n }\n\n for (let j = 0; j < value.length; j++) {\n const segment = encode(value[j], token);\n\n if (validate && !(matches[i] as RegExp).test(segment)) {\n throw new TypeError(\n `Expected all \"${token.name}\" to match \"${token.pattern}\", but got \"${segment}\"`\n );\n }\n\n path += token.prefix + segment + token.suffix;\n }\n\n continue;\n }\n\n if (typeof value === \"string\" || typeof value === \"number\") {\n const segment = encode(String(value), token);\n\n if (validate && !(matches[i] as RegExp).test(segment)) {\n throw new TypeError(\n `Expected \"${token.name}\" to match \"${token.pattern}\", but got \"${segment}\"`\n );\n }\n\n path += token.prefix + segment + token.suffix;\n continue;\n }\n\n if (optional) continue;\n\n const typeOfMessage = repeat ? \"an array\" : \"a string\";\n throw new TypeError(`Expected \"${token.name}\" to be ${typeOfMessage}`);\n }\n\n return path;\n };\n}\n\nexport interface RegexpToFunctionOptions {\n /**\n * Function for decoding strings for params.\n */\n decode?: (value: string, token: Key) => string;\n}\n\n/**\n * A match result contains data about the path match.\n */\nexport interface MatchResult {\n path: string;\n index: number;\n params: P;\n}\n\n/**\n * A match is either `false` (no match) or a match result.\n */\nexport type Match
= false | MatchResult
;\n\n/**\n * The match function takes a string and returns whether it matched the path.\n */\nexport type MatchFunction
= (\n path: string\n) => Match
;\n\n/**\n * Create path match function from `path-to-regexp` spec.\n */\nexport function match
(\n str: Path,\n options?: ParseOptions & TokensToRegexpOptions & RegexpToFunctionOptions\n) {\n const keys: Key[] = [];\n const re = pathToRegexp(str, keys, options);\n return regexpToFunction
(re, keys, options);\n}\n\n/**\n * Create a path match function from `path-to-regexp` output.\n */\nexport function regexpToFunction
(\n re: RegExp,\n keys: Key[],\n options: RegexpToFunctionOptions = {}\n): MatchFunction
{\n const { decode = (x: string) => x } = options;\n\n return function (pathname: string) {\n const m = re.exec(pathname);\n if (!m) return false;\n\n const { 0: path, index } = m;\n const params = Object.create(null);\n\n for (let i = 1; i < m.length; i++) {\n if (m[i] === undefined) continue;\n\n const key = keys[i - 1];\n\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map((value) => {\n return decode(value, key);\n });\n } else {\n params[key.name] = decode(m[i], key);\n }\n }\n\n return { path, index, params };\n };\n}\n\n/**\n * Escape a regular expression string.\n */\nfunction escapeString(str: string) {\n return str.replace(/([.+*?=^!:${}()[\\]|/\\\\])/g, \"\\\\$1\");\n}\n\n/**\n * Get the flags for a regexp from the options.\n */\nfunction flags(options?: { sensitive?: boolean }) {\n return options && options.sensitive ? \"\" : \"i\";\n}\n\n/**\n * Metadata about a key.\n */\nexport interface Key {\n name: string | number;\n prefix: string;\n suffix: string;\n pattern: string;\n modifier: string;\n}\n\n/**\n * A token is a string (nothing special) or key metadata (capture group).\n */\nexport type Token = string | Key;\n\n/**\n * Pull out keys from a regexp.\n */\nfunction regexpToRegexp(path: RegExp, keys?: Key[]): RegExp {\n if (!keys) return path;\n\n const groupsRegex = /\\((?:\\?<(.*?)>)?(?!\\?)/g;\n\n let index = 0;\n let execResult = groupsRegex.exec(path.source);\n while (execResult) {\n keys.push({\n // Use parenthesized substring match if available, index otherwise\n name: execResult[1] || index++,\n prefix: \"\",\n suffix: \"\",\n modifier: \"\",\n pattern: \"\",\n });\n execResult = groupsRegex.exec(path.source);\n }\n\n return path;\n}\n\n/**\n * Transform an array into a regexp.\n */\nfunction arrayToRegexp(\n paths: Array,\n keys?: Key[],\n options?: TokensToRegexpOptions & ParseOptions\n): RegExp {\n const parts = paths.map((path) => pathToRegexp(path, keys, options).source);\n return new RegExp(`(?:${parts.join(\"|\")})`, flags(options));\n}\n\n/**\n * Create a path regexp from string input.\n */\nfunction stringToRegexp(\n path: string,\n keys?: Key[],\n options?: TokensToRegexpOptions & ParseOptions\n) {\n return tokensToRegexp(parse(path, options), keys, options);\n}\n\nexport interface TokensToRegexpOptions {\n /**\n * When `true` the regexp will be case sensitive. (default: `false`)\n */\n sensitive?: boolean;\n /**\n * When `true` the regexp won't allow an optional trailing delimiter to match. (default: `false`)\n */\n strict?: boolean;\n /**\n * When `true` the regexp will match to the end of the string. (default: `true`)\n */\n end?: boolean;\n /**\n * When `true` the regexp will match from the beginning of the string. (default: `true`)\n */\n start?: boolean;\n /**\n * Sets the final character for non-ending optimistic matches. (default: `/`)\n */\n delimiter?: string;\n /**\n * List of characters that can also be \"end\" characters.\n */\n endsWith?: string;\n /**\n * Encode path tokens for use in the `RegExp`.\n */\n encode?: (value: string) => string;\n}\n\n/**\n * Expose a function for taking tokens and returning a RegExp.\n */\nexport function tokensToRegexp(\n tokens: Token[],\n keys?: Key[],\n options: TokensToRegexpOptions = {}\n) {\n const {\n strict = false,\n start = true,\n end = true,\n encode = (x: string) => x,\n delimiter = \"/#?\",\n endsWith = \"\",\n } = options;\n const endsWithRe = `[${escapeString(endsWith)}]|$`;\n const delimiterRe = `[${escapeString(delimiter)}]`;\n let route = start ? \"^\" : \"\";\n\n // Iterate over the tokens and create our regexp string.\n for (const token of tokens) {\n if (typeof token === \"string\") {\n route += escapeString(encode(token));\n } else {\n const prefix = escapeString(encode(token.prefix));\n const suffix = escapeString(encode(token.suffix));\n\n if (token.pattern) {\n if (keys) keys.push(token);\n\n if (prefix || suffix) {\n if (token.modifier === \"+\" || token.modifier === \"*\") {\n const mod = token.modifier === \"*\" ? \"?\" : \"\";\n route += `(?:${prefix}((?:${token.pattern})(?:${suffix}${prefix}(?:${token.pattern}))*)${suffix})${mod}`;\n } else {\n route += `(?:${prefix}(${token.pattern})${suffix})${token.modifier}`;\n }\n } else {\n if (token.modifier === \"+\" || token.modifier === \"*\") {\n route += `((?:${token.pattern})${token.modifier})`;\n } else {\n route += `(${token.pattern})${token.modifier}`;\n }\n }\n } else {\n route += `(?:${prefix}${suffix})${token.modifier}`;\n }\n }\n }\n\n if (end) {\n if (!strict) route += `${delimiterRe}?`;\n\n route += !options.endsWith ? \"$\" : `(?=${endsWithRe})`;\n } else {\n const endToken = tokens[tokens.length - 1];\n const isEndDelimited =\n typeof endToken === \"string\"\n ? delimiterRe.indexOf(endToken[endToken.length - 1]) > -1\n : endToken === undefined;\n\n if (!strict) {\n route += `(?:${delimiterRe}(?=${endsWithRe}))?`;\n }\n\n if (!isEndDelimited) {\n route += `(?=${delimiterRe}|${endsWithRe})`;\n }\n }\n\n return new RegExp(route, flags(options));\n}\n\n/**\n * Supported `path-to-regexp` input types.\n */\nexport type Path = string | RegExp | Array;\n\n/**\n * Normalize the given path string, returning a regular expression.\n *\n * An empty array can be passed in for the keys, which will hold the\n * placeholder key descriptions. For example, using `/user/:id`, `keys` will\n * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.\n */\nexport function pathToRegexp(\n path: Path,\n keys?: Key[],\n options?: TokensToRegexpOptions & ParseOptions\n) {\n if (path instanceof RegExp) return regexpToRegexp(path, keys);\n if (Array.isArray(path)) return arrayToRegexp(path, keys, options);\n return stringToRegexp(path, keys, options);\n}\n"]}
\ No newline at end of file
diff --git a/build/node_modules/path-to-regexp/dist/index.d.ts b/build/node_modules/path-to-regexp/dist/index.d.ts
new file mode 100644
index 00000000..77aa0047
--- /dev/null
+++ b/build/node_modules/path-to-regexp/dist/index.d.ts
@@ -0,0 +1,127 @@
+export interface ParseOptions {
+ /**
+ * Set the default delimiter for repeat parameters. (default: `'/'`)
+ */
+ delimiter?: string;
+ /**
+ * List of characters to automatically consider prefixes when parsing.
+ */
+ prefixes?: string;
+}
+/**
+ * Parse a string for the raw tokens.
+ */
+export declare function parse(str: string, options?: ParseOptions): Token[];
+export interface TokensToFunctionOptions {
+ /**
+ * When `true` the regexp will be case sensitive. (default: `false`)
+ */
+ sensitive?: boolean;
+ /**
+ * Function for encoding input strings for output.
+ */
+ encode?: (value: string, token: Key) => string;
+ /**
+ * When `false` the function can produce an invalid (unmatched) path. (default: `true`)
+ */
+ validate?: boolean;
+}
+/**
+ * Compile a string to a template function for the path.
+ */
+export declare function compile(str: string, options?: ParseOptions & TokensToFunctionOptions): PathFunction
;
+export declare type PathFunction
= (data?: P) => string;
+/**
+ * Expose a method for transforming tokens into the path function.
+ */
+export declare function tokensToFunction
(tokens: Token[], options?: TokensToFunctionOptions): PathFunction
;
+export interface RegexpToFunctionOptions {
+ /**
+ * Function for decoding strings for params.
+ */
+ decode?: (value: string, token: Key) => string;
+}
+/**
+ * A match result contains data about the path match.
+ */
+export interface MatchResult
{
+ path: string;
+ index: number;
+ params: P;
+}
+/**
+ * A match is either `false` (no match) or a match result.
+ */
+export declare type Match
= false | MatchResult
;
+/**
+ * The match function takes a string and returns whether it matched the path.
+ */
+export declare type MatchFunction
= (path: string) => Match
;
+/**
+ * Create path match function from `path-to-regexp` spec.
+ */
+export declare function match
(str: Path, options?: ParseOptions & TokensToRegexpOptions & RegexpToFunctionOptions): MatchFunction
;
+/**
+ * Create a path match function from `path-to-regexp` output.
+ */
+export declare function regexpToFunction
(re: RegExp, keys: Key[], options?: RegexpToFunctionOptions): MatchFunction
;
+/**
+ * Metadata about a key.
+ */
+export interface Key {
+ name: string | number;
+ prefix: string;
+ suffix: string;
+ pattern: string;
+ modifier: string;
+}
+/**
+ * A token is a string (nothing special) or key metadata (capture group).
+ */
+export declare type Token = string | Key;
+export interface TokensToRegexpOptions {
+ /**
+ * When `true` the regexp will be case sensitive. (default: `false`)
+ */
+ sensitive?: boolean;
+ /**
+ * When `true` the regexp won't allow an optional trailing delimiter to match. (default: `false`)
+ */
+ strict?: boolean;
+ /**
+ * When `true` the regexp will match to the end of the string. (default: `true`)
+ */
+ end?: boolean;
+ /**
+ * When `true` the regexp will match from the beginning of the string. (default: `true`)
+ */
+ start?: boolean;
+ /**
+ * Sets the final character for non-ending optimistic matches. (default: `/`)
+ */
+ delimiter?: string;
+ /**
+ * List of characters that can also be "end" characters.
+ */
+ endsWith?: string;
+ /**
+ * Encode path tokens for use in the `RegExp`.
+ */
+ encode?: (value: string) => string;
+}
+/**
+ * Expose a function for taking tokens and returning a RegExp.
+ */
+export declare function tokensToRegexp(tokens: Token[], keys?: Key[], options?: TokensToRegexpOptions): RegExp;
+/**
+ * Supported `path-to-regexp` input types.
+ */
+export declare type Path = string | RegExp | Array;
+/**
+ * Normalize the given path string, returning a regular expression.
+ *
+ * An empty array can be passed in for the keys, which will hold the
+ * placeholder key descriptions. For example, using `/user/:id`, `keys` will
+ * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
+ */
+export declare function pathToRegexp(path: Path, keys?: Key[], options?: TokensToRegexpOptions & ParseOptions): RegExp;
diff --git a/build/node_modules/path-to-regexp/dist/index.js b/build/node_modules/path-to-regexp/dist/index.js
new file mode 100644
index 00000000..a512e460
--- /dev/null
+++ b/build/node_modules/path-to-regexp/dist/index.js
@@ -0,0 +1,410 @@
+"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+exports.pathToRegexp = exports.tokensToRegexp = exports.regexpToFunction = exports.match = exports.tokensToFunction = exports.compile = exports.parse = void 0;
+/**
+ * Tokenize input string.
+ */
+function lexer(str) {
+ var tokens = [];
+ var i = 0;
+ while (i < str.length) {
+ var char = str[i];
+ if (char === "*" || char === "+" || char === "?") {
+ tokens.push({ type: "MODIFIER", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === "\\") {
+ tokens.push({ type: "ESCAPED_CHAR", index: i++, value: str[i++] });
+ continue;
+ }
+ if (char === "{") {
+ tokens.push({ type: "OPEN", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === "}") {
+ tokens.push({ type: "CLOSE", index: i, value: str[i++] });
+ continue;
+ }
+ if (char === ":") {
+ var name = "";
+ var j = i + 1;
+ while (j < str.length) {
+ var code = str.charCodeAt(j);
+ if (
+ // `0-9`
+ (code >= 48 && code <= 57) ||
+ // `A-Z`
+ (code >= 65 && code <= 90) ||
+ // `a-z`
+ (code >= 97 && code <= 122) ||
+ // `_`
+ code === 95) {
+ name += str[j++];
+ continue;
+ }
+ break;
+ }
+ if (!name)
+ throw new TypeError("Missing parameter name at ".concat(i));
+ tokens.push({ type: "NAME", index: i, value: name });
+ i = j;
+ continue;
+ }
+ if (char === "(") {
+ var count = 1;
+ var pattern = "";
+ var j = i + 1;
+ if (str[j] === "?") {
+ throw new TypeError("Pattern cannot start with \"?\" at ".concat(j));
+ }
+ while (j < str.length) {
+ if (str[j] === "\\") {
+ pattern += str[j++] + str[j++];
+ continue;
+ }
+ if (str[j] === ")") {
+ count--;
+ if (count === 0) {
+ j++;
+ break;
+ }
+ }
+ else if (str[j] === "(") {
+ count++;
+ if (str[j + 1] !== "?") {
+ throw new TypeError("Capturing groups are not allowed at ".concat(j));
+ }
+ }
+ pattern += str[j++];
+ }
+ if (count)
+ throw new TypeError("Unbalanced pattern at ".concat(i));
+ if (!pattern)
+ throw new TypeError("Missing pattern at ".concat(i));
+ tokens.push({ type: "PATTERN", index: i, value: pattern });
+ i = j;
+ continue;
+ }
+ tokens.push({ type: "CHAR", index: i, value: str[i++] });
+ }
+ tokens.push({ type: "END", index: i, value: "" });
+ return tokens;
+}
+/**
+ * Parse a string for the raw tokens.
+ */
+function parse(str, options) {
+ if (options === void 0) { options = {}; }
+ var tokens = lexer(str);
+ var _a = options.prefixes, prefixes = _a === void 0 ? "./" : _a;
+ var defaultPattern = "[^".concat(escapeString(options.delimiter || "/#?"), "]+?");
+ var result = [];
+ var key = 0;
+ var i = 0;
+ var path = "";
+ var tryConsume = function (type) {
+ if (i < tokens.length && tokens[i].type === type)
+ return tokens[i++].value;
+ };
+ var mustConsume = function (type) {
+ var value = tryConsume(type);
+ if (value !== undefined)
+ return value;
+ var _a = tokens[i], nextType = _a.type, index = _a.index;
+ throw new TypeError("Unexpected ".concat(nextType, " at ").concat(index, ", expected ").concat(type));
+ };
+ var consumeText = function () {
+ var result = "";
+ var value;
+ while ((value = tryConsume("CHAR") || tryConsume("ESCAPED_CHAR"))) {
+ result += value;
+ }
+ return result;
+ };
+ while (i < tokens.length) {
+ var char = tryConsume("CHAR");
+ var name = tryConsume("NAME");
+ var pattern = tryConsume("PATTERN");
+ if (name || pattern) {
+ var prefix = char || "";
+ if (prefixes.indexOf(prefix) === -1) {
+ path += prefix;
+ prefix = "";
+ }
+ if (path) {
+ result.push(path);
+ path = "";
+ }
+ result.push({
+ name: name || key++,
+ prefix: prefix,
+ suffix: "",
+ pattern: pattern || defaultPattern,
+ modifier: tryConsume("MODIFIER") || "",
+ });
+ continue;
+ }
+ var value = char || tryConsume("ESCAPED_CHAR");
+ if (value) {
+ path += value;
+ continue;
+ }
+ if (path) {
+ result.push(path);
+ path = "";
+ }
+ var open = tryConsume("OPEN");
+ if (open) {
+ var prefix = consumeText();
+ var name_1 = tryConsume("NAME") || "";
+ var pattern_1 = tryConsume("PATTERN") || "";
+ var suffix = consumeText();
+ mustConsume("CLOSE");
+ result.push({
+ name: name_1 || (pattern_1 ? key++ : ""),
+ pattern: name_1 && !pattern_1 ? defaultPattern : pattern_1,
+ prefix: prefix,
+ suffix: suffix,
+ modifier: tryConsume("MODIFIER") || "",
+ });
+ continue;
+ }
+ mustConsume("END");
+ }
+ return result;
+}
+exports.parse = parse;
+/**
+ * Compile a string to a template function for the path.
+ */
+function compile(str, options) {
+ return tokensToFunction(parse(str, options), options);
+}
+exports.compile = compile;
+/**
+ * Expose a method for transforming tokens into the path function.
+ */
+function tokensToFunction(tokens, options) {
+ if (options === void 0) { options = {}; }
+ var reFlags = flags(options);
+ var _a = options.encode, encode = _a === void 0 ? function (x) { return x; } : _a, _b = options.validate, validate = _b === void 0 ? true : _b;
+ // Compile all the tokens into regexps.
+ var matches = tokens.map(function (token) {
+ if (typeof token === "object") {
+ return new RegExp("^(?:".concat(token.pattern, ")$"), reFlags);
+ }
+ });
+ return function (data) {
+ var path = "";
+ for (var i = 0; i < tokens.length; i++) {
+ var token = tokens[i];
+ if (typeof token === "string") {
+ path += token;
+ continue;
+ }
+ var value = data ? data[token.name] : undefined;
+ var optional = token.modifier === "?" || token.modifier === "*";
+ var repeat = token.modifier === "*" || token.modifier === "+";
+ if (Array.isArray(value)) {
+ if (!repeat) {
+ throw new TypeError("Expected \"".concat(token.name, "\" to not repeat, but got an array"));
+ }
+ if (value.length === 0) {
+ if (optional)
+ continue;
+ throw new TypeError("Expected \"".concat(token.name, "\" to not be empty"));
+ }
+ for (var j = 0; j < value.length; j++) {
+ var segment = encode(value[j], token);
+ if (validate && !matches[i].test(segment)) {
+ throw new TypeError("Expected all \"".concat(token.name, "\" to match \"").concat(token.pattern, "\", but got \"").concat(segment, "\""));
+ }
+ path += token.prefix + segment + token.suffix;
+ }
+ continue;
+ }
+ if (typeof value === "string" || typeof value === "number") {
+ var segment = encode(String(value), token);
+ if (validate && !matches[i].test(segment)) {
+ throw new TypeError("Expected \"".concat(token.name, "\" to match \"").concat(token.pattern, "\", but got \"").concat(segment, "\""));
+ }
+ path += token.prefix + segment + token.suffix;
+ continue;
+ }
+ if (optional)
+ continue;
+ var typeOfMessage = repeat ? "an array" : "a string";
+ throw new TypeError("Expected \"".concat(token.name, "\" to be ").concat(typeOfMessage));
+ }
+ return path;
+ };
+}
+exports.tokensToFunction = tokensToFunction;
+/**
+ * Create path match function from `path-to-regexp` spec.
+ */
+function match(str, options) {
+ var keys = [];
+ var re = pathToRegexp(str, keys, options);
+ return regexpToFunction(re, keys, options);
+}
+exports.match = match;
+/**
+ * Create a path match function from `path-to-regexp` output.
+ */
+function regexpToFunction(re, keys, options) {
+ if (options === void 0) { options = {}; }
+ var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;
+ return function (pathname) {
+ var m = re.exec(pathname);
+ if (!m)
+ return false;
+ var path = m[0], index = m.index;
+ var params = Object.create(null);
+ var _loop_1 = function (i) {
+ if (m[i] === undefined)
+ return "continue";
+ var key = keys[i - 1];
+ if (key.modifier === "*" || key.modifier === "+") {
+ params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {
+ return decode(value, key);
+ });
+ }
+ else {
+ params[key.name] = decode(m[i], key);
+ }
+ };
+ for (var i = 1; i < m.length; i++) {
+ _loop_1(i);
+ }
+ return { path: path, index: index, params: params };
+ };
+}
+exports.regexpToFunction = regexpToFunction;
+/**
+ * Escape a regular expression string.
+ */
+function escapeString(str) {
+ return str.replace(/([.+*?=^!:${}()[\]|/\\])/g, "\\$1");
+}
+/**
+ * Get the flags for a regexp from the options.
+ */
+function flags(options) {
+ return options && options.sensitive ? "" : "i";
+}
+/**
+ * Pull out keys from a regexp.
+ */
+function regexpToRegexp(path, keys) {
+ if (!keys)
+ return path;
+ var groupsRegex = /\((?:\?<(.*?)>)?(?!\?)/g;
+ var index = 0;
+ var execResult = groupsRegex.exec(path.source);
+ while (execResult) {
+ keys.push({
+ // Use parenthesized substring match if available, index otherwise
+ name: execResult[1] || index++,
+ prefix: "",
+ suffix: "",
+ modifier: "",
+ pattern: "",
+ });
+ execResult = groupsRegex.exec(path.source);
+ }
+ return path;
+}
+/**
+ * Transform an array into a regexp.
+ */
+function arrayToRegexp(paths, keys, options) {
+ var parts = paths.map(function (path) { return pathToRegexp(path, keys, options).source; });
+ return new RegExp("(?:".concat(parts.join("|"), ")"), flags(options));
+}
+/**
+ * Create a path regexp from string input.
+ */
+function stringToRegexp(path, keys, options) {
+ return tokensToRegexp(parse(path, options), keys, options);
+}
+/**
+ * Expose a function for taking tokens and returning a RegExp.
+ */
+function tokensToRegexp(tokens, keys, options) {
+ if (options === void 0) { options = {}; }
+ var _a = options.strict, strict = _a === void 0 ? false : _a, _b = options.start, start = _b === void 0 ? true : _b, _c = options.end, end = _c === void 0 ? true : _c, _d = options.encode, encode = _d === void 0 ? function (x) { return x; } : _d, _e = options.delimiter, delimiter = _e === void 0 ? "/#?" : _e, _f = options.endsWith, endsWith = _f === void 0 ? "" : _f;
+ var endsWithRe = "[".concat(escapeString(endsWith), "]|$");
+ var delimiterRe = "[".concat(escapeString(delimiter), "]");
+ var route = start ? "^" : "";
+ // Iterate over the tokens and create our regexp string.
+ for (var _i = 0, tokens_1 = tokens; _i < tokens_1.length; _i++) {
+ var token = tokens_1[_i];
+ if (typeof token === "string") {
+ route += escapeString(encode(token));
+ }
+ else {
+ var prefix = escapeString(encode(token.prefix));
+ var suffix = escapeString(encode(token.suffix));
+ if (token.pattern) {
+ if (keys)
+ keys.push(token);
+ if (prefix || suffix) {
+ if (token.modifier === "+" || token.modifier === "*") {
+ var mod = token.modifier === "*" ? "?" : "";
+ route += "(?:".concat(prefix, "((?:").concat(token.pattern, ")(?:").concat(suffix).concat(prefix, "(?:").concat(token.pattern, "))*)").concat(suffix, ")").concat(mod);
+ }
+ else {
+ route += "(?:".concat(prefix, "(").concat(token.pattern, ")").concat(suffix, ")").concat(token.modifier);
+ }
+ }
+ else {
+ if (token.modifier === "+" || token.modifier === "*") {
+ route += "((?:".concat(token.pattern, ")").concat(token.modifier, ")");
+ }
+ else {
+ route += "(".concat(token.pattern, ")").concat(token.modifier);
+ }
+ }
+ }
+ else {
+ route += "(?:".concat(prefix).concat(suffix, ")").concat(token.modifier);
+ }
+ }
+ }
+ if (end) {
+ if (!strict)
+ route += "".concat(delimiterRe, "?");
+ route += !options.endsWith ? "$" : "(?=".concat(endsWithRe, ")");
+ }
+ else {
+ var endToken = tokens[tokens.length - 1];
+ var isEndDelimited = typeof endToken === "string"
+ ? delimiterRe.indexOf(endToken[endToken.length - 1]) > -1
+ : endToken === undefined;
+ if (!strict) {
+ route += "(?:".concat(delimiterRe, "(?=").concat(endsWithRe, "))?");
+ }
+ if (!isEndDelimited) {
+ route += "(?=".concat(delimiterRe, "|").concat(endsWithRe, ")");
+ }
+ }
+ return new RegExp(route, flags(options));
+}
+exports.tokensToRegexp = tokensToRegexp;
+/**
+ * Normalize the given path string, returning a regular expression.
+ *
+ * An empty array can be passed in for the keys, which will hold the
+ * placeholder key descriptions. For example, using `/user/:id`, `keys` will
+ * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
+ */
+function pathToRegexp(path, keys, options) {
+ if (path instanceof RegExp)
+ return regexpToRegexp(path, keys);
+ if (Array.isArray(path))
+ return arrayToRegexp(path, keys, options);
+ return stringToRegexp(path, keys, options);
+}
+exports.pathToRegexp = pathToRegexp;
+//# sourceMappingURL=index.js.map
\ No newline at end of file
diff --git a/build/node_modules/path-to-regexp/dist/index.js.map b/build/node_modules/path-to-regexp/dist/index.js.map
new file mode 100644
index 00000000..47694e1f
--- /dev/null
+++ b/build/node_modules/path-to-regexp/dist/index.js.map
@@ -0,0 +1 @@
+{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAiBA;;GAEG;AACH,SAAS,KAAK,CAAC,GAAW;IACxB,IAAM,MAAM,GAAe,EAAE,CAAC;IAC9B,IAAI,CAAC,GAAG,CAAC,CAAC;IAEV,OAAO,CAAC,GAAG,GAAG,CAAC,MAAM,EAAE;QACrB,IAAM,IAAI,GAAG,GAAG,CAAC,CAAC,CAAC,CAAC;QAEpB,IAAI,IAAI,KAAK,GAAG,IAAI,IAAI,KAAK,GAAG,IAAI,IAAI,KAAK,GAAG,EAAE;YAChD,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;YAC7D,SAAS;SACV;QAED,IAAI,IAAI,KAAK,IAAI,EAAE;YACjB,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,cAAc,EAAE,KAAK,EAAE,CAAC,EAAE,EAAE,KAAK,EAAE,GAAG,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,CAAC;YACnE,SAAS;SACV;QAED,IAAI,IAAI,KAAK,GAAG,EAAE;YAChB,MAAM,CAAC,IAAI,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,GAAG,CAAC,CA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,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IACnE,OAAO,cAAc,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;AAC7C,CAAC;AARD,oCAQC","sourcesContent":["/**\n * Tokenizer results.\n */\ninterface LexToken {\n type:\n | \"OPEN\"\n | \"CLOSE\"\n | \"PATTERN\"\n | \"NAME\"\n | \"CHAR\"\n | \"ESCAPED_CHAR\"\n | \"MODIFIER\"\n | \"END\";\n index: number;\n value: string;\n}\n\n/**\n * Tokenize input string.\n */\nfunction lexer(str: string): LexToken[] {\n const tokens: LexToken[] = [];\n let i = 0;\n\n while (i < str.length) {\n const char = str[i];\n\n if (char === \"*\" || char === \"+\" || char === \"?\") {\n tokens.push({ type: \"MODIFIER\", index: i, value: str[i++] });\n continue;\n }\n\n if (char === \"\\\\\") {\n tokens.push({ type: \"ESCAPED_CHAR\", index: i++, value: str[i++] });\n continue;\n }\n\n if (char === \"{\") {\n tokens.push({ type: \"OPEN\", index: i, value: str[i++] });\n continue;\n }\n\n if (char === \"}\") {\n tokens.push({ type: \"CLOSE\", index: i, value: str[i++] });\n continue;\n }\n\n if (char === \":\") {\n let name = \"\";\n let j = i + 1;\n\n while (j < str.length) {\n const code = str.charCodeAt(j);\n\n if (\n // `0-9`\n (code >= 48 && code <= 57) ||\n // `A-Z`\n (code >= 65 && code <= 90) ||\n // `a-z`\n (code >= 97 && code <= 122) ||\n // `_`\n code === 95\n ) {\n name += str[j++];\n continue;\n }\n\n break;\n }\n\n if (!name) throw new TypeError(`Missing parameter name at ${i}`);\n\n tokens.push({ type: \"NAME\", index: i, value: name });\n i = j;\n continue;\n }\n\n if (char === \"(\") {\n let count = 1;\n let pattern = \"\";\n let j = i + 1;\n\n if (str[j] === \"?\") {\n throw new TypeError(`Pattern cannot start with \"?\" at ${j}`);\n }\n\n while (j < str.length) {\n if (str[j] === \"\\\\\") {\n pattern += str[j++] + str[j++];\n continue;\n }\n\n if (str[j] === \")\") {\n count--;\n if (count === 0) {\n j++;\n break;\n }\n } else if (str[j] === \"(\") {\n count++;\n if (str[j + 1] !== \"?\") {\n throw new TypeError(`Capturing groups are not allowed at ${j}`);\n }\n }\n\n pattern += str[j++];\n }\n\n if (count) throw new TypeError(`Unbalanced pattern at ${i}`);\n if (!pattern) throw new TypeError(`Missing pattern at ${i}`);\n\n tokens.push({ type: \"PATTERN\", index: i, value: pattern });\n i = j;\n continue;\n }\n\n tokens.push({ type: \"CHAR\", index: i, value: str[i++] });\n }\n\n tokens.push({ type: \"END\", index: i, value: \"\" });\n\n return tokens;\n}\n\nexport interface ParseOptions {\n /**\n * Set the default delimiter for repeat parameters. (default: `'/'`)\n */\n delimiter?: string;\n /**\n * List of characters to automatically consider prefixes when parsing.\n */\n prefixes?: string;\n}\n\n/**\n * Parse a string for the raw tokens.\n */\nexport function parse(str: string, options: ParseOptions = {}): Token[] {\n const tokens = lexer(str);\n const { prefixes = \"./\" } = options;\n const defaultPattern = `[^${escapeString(options.delimiter || \"/#?\")}]+?`;\n const result: Token[] = [];\n let key = 0;\n let i = 0;\n let path = \"\";\n\n const tryConsume = (type: LexToken[\"type\"]): string | undefined => {\n if (i < tokens.length && tokens[i].type === type) return tokens[i++].value;\n };\n\n const mustConsume = (type: LexToken[\"type\"]): string => {\n const value = tryConsume(type);\n if (value !== undefined) return value;\n const { type: nextType, index } = tokens[i];\n throw new TypeError(`Unexpected ${nextType} at ${index}, expected ${type}`);\n };\n\n const consumeText = (): string => {\n let result = \"\";\n let value: string | undefined;\n while ((value = tryConsume(\"CHAR\") || tryConsume(\"ESCAPED_CHAR\"))) {\n result += value;\n }\n return result;\n };\n\n while (i < tokens.length) {\n const char = tryConsume(\"CHAR\");\n const name = tryConsume(\"NAME\");\n const pattern = tryConsume(\"PATTERN\");\n\n if (name || pattern) {\n let prefix = char || \"\";\n\n if (prefixes.indexOf(prefix) === -1) {\n path += prefix;\n prefix = \"\";\n }\n\n if (path) {\n result.push(path);\n path = \"\";\n }\n\n result.push({\n name: name || key++,\n prefix,\n suffix: \"\",\n pattern: pattern || defaultPattern,\n modifier: tryConsume(\"MODIFIER\") || \"\",\n });\n continue;\n }\n\n const value = char || tryConsume(\"ESCAPED_CHAR\");\n if (value) {\n path += value;\n continue;\n }\n\n if (path) {\n result.push(path);\n path = \"\";\n }\n\n const open = tryConsume(\"OPEN\");\n if (open) {\n const prefix = consumeText();\n const name = tryConsume(\"NAME\") || \"\";\n const pattern = tryConsume(\"PATTERN\") || \"\";\n const suffix = consumeText();\n\n mustConsume(\"CLOSE\");\n\n result.push({\n name: name || (pattern ? key++ : \"\"),\n pattern: name && !pattern ? defaultPattern : pattern,\n prefix,\n suffix,\n modifier: tryConsume(\"MODIFIER\") || \"\",\n });\n continue;\n }\n\n mustConsume(\"END\");\n }\n\n return result;\n}\n\nexport interface TokensToFunctionOptions {\n /**\n * When `true` the regexp will be case sensitive. (default: `false`)\n */\n sensitive?: boolean;\n /**\n * Function for encoding input strings for output.\n */\n encode?: (value: string, token: Key) => string;\n /**\n * When `false` the function can produce an invalid (unmatched) path. (default: `true`)\n */\n validate?: boolean;\n}\n\n/**\n * Compile a string to a template function for the path.\n */\nexport function compile(\n str: string,\n options?: ParseOptions & TokensToFunctionOptions\n) {\n return tokensToFunction
(parse(str, options), options);\n}\n\nexport type PathFunction
= (data?: P) => string;\n\n/**\n * Expose a method for transforming tokens into the path function.\n */\nexport function tokensToFunction
(\n tokens: Token[],\n options: TokensToFunctionOptions = {}\n): PathFunction
{\n const reFlags = flags(options);\n const { encode = (x: string) => x, validate = true } = options;\n\n // Compile all the tokens into regexps.\n const matches = tokens.map((token) => {\n if (typeof token === \"object\") {\n return new RegExp(`^(?:${token.pattern})$`, reFlags);\n }\n });\n\n return (data: Record | null | undefined) => {\n let path = \"\";\n\n for (let i = 0; i < tokens.length; i++) {\n const token = tokens[i];\n\n if (typeof token === \"string\") {\n path += token;\n continue;\n }\n\n const value = data ? data[token.name] : undefined;\n const optional = token.modifier === \"?\" || token.modifier === \"*\";\n const repeat = token.modifier === \"*\" || token.modifier === \"+\";\n\n if (Array.isArray(value)) {\n if (!repeat) {\n throw new TypeError(\n `Expected \"${token.name}\" to not repeat, but got an array`\n );\n }\n\n if (value.length === 0) {\n if (optional) continue;\n\n throw new TypeError(`Expected \"${token.name}\" to not be empty`);\n }\n\n for (let j = 0; j < value.length; j++) {\n const segment = encode(value[j], token);\n\n if (validate && !(matches[i] as RegExp).test(segment)) {\n throw new TypeError(\n `Expected all \"${token.name}\" to match \"${token.pattern}\", but got \"${segment}\"`\n );\n }\n\n path += token.prefix + segment + token.suffix;\n }\n\n continue;\n }\n\n if (typeof value === \"string\" || typeof value === \"number\") {\n const segment = encode(String(value), token);\n\n if (validate && !(matches[i] as RegExp).test(segment)) {\n throw new TypeError(\n `Expected \"${token.name}\" to match \"${token.pattern}\", but got \"${segment}\"`\n );\n }\n\n path += token.prefix + segment + token.suffix;\n continue;\n }\n\n if (optional) continue;\n\n const typeOfMessage = repeat ? \"an array\" : \"a string\";\n throw new TypeError(`Expected \"${token.name}\" to be ${typeOfMessage}`);\n }\n\n return path;\n };\n}\n\nexport interface RegexpToFunctionOptions {\n /**\n * Function for decoding strings for params.\n */\n decode?: (value: string, token: Key) => string;\n}\n\n/**\n * A match result contains data about the path match.\n */\nexport interface MatchResult {\n path: string;\n index: number;\n params: P;\n}\n\n/**\n * A match is either `false` (no match) or a match result.\n */\nexport type Match
= false | MatchResult
;\n\n/**\n * The match function takes a string and returns whether it matched the path.\n */\nexport type MatchFunction
= (\n path: string\n) => Match
;\n\n/**\n * Create path match function from `path-to-regexp` spec.\n */\nexport function match
(\n str: Path,\n options?: ParseOptions & TokensToRegexpOptions & RegexpToFunctionOptions\n) {\n const keys: Key[] = [];\n const re = pathToRegexp(str, keys, options);\n return regexpToFunction
(re, keys, options);\n}\n\n/**\n * Create a path match function from `path-to-regexp` output.\n */\nexport function regexpToFunction
(\n re: RegExp,\n keys: Key[],\n options: RegexpToFunctionOptions = {}\n): MatchFunction
{\n const { decode = (x: string) => x } = options;\n\n return function (pathname: string) {\n const m = re.exec(pathname);\n if (!m) return false;\n\n const { 0: path, index } = m;\n const params = Object.create(null);\n\n for (let i = 1; i < m.length; i++) {\n if (m[i] === undefined) continue;\n\n const key = keys[i - 1];\n\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map((value) => {\n return decode(value, key);\n });\n } else {\n params[key.name] = decode(m[i], key);\n }\n }\n\n return { path, index, params };\n };\n}\n\n/**\n * Escape a regular expression string.\n */\nfunction escapeString(str: string) {\n return str.replace(/([.+*?=^!:${}()[\\]|/\\\\])/g, \"\\\\$1\");\n}\n\n/**\n * Get the flags for a regexp from the options.\n */\nfunction flags(options?: { sensitive?: boolean }) {\n return options && options.sensitive ? \"\" : \"i\";\n}\n\n/**\n * Metadata about a key.\n */\nexport interface Key {\n name: string | number;\n prefix: string;\n suffix: string;\n pattern: string;\n modifier: string;\n}\n\n/**\n * A token is a string (nothing special) or key metadata (capture group).\n */\nexport type Token = string | Key;\n\n/**\n * Pull out keys from a regexp.\n */\nfunction regexpToRegexp(path: RegExp, keys?: Key[]): RegExp {\n if (!keys) return path;\n\n const groupsRegex = /\\((?:\\?<(.*?)>)?(?!\\?)/g;\n\n let index = 0;\n let execResult = groupsRegex.exec(path.source);\n while (execResult) {\n keys.push({\n // Use parenthesized substring match if available, index otherwise\n name: execResult[1] || index++,\n prefix: \"\",\n suffix: \"\",\n modifier: \"\",\n pattern: \"\",\n });\n execResult = groupsRegex.exec(path.source);\n }\n\n return path;\n}\n\n/**\n * Transform an array into a regexp.\n */\nfunction arrayToRegexp(\n paths: Array,\n keys?: Key[],\n options?: TokensToRegexpOptions & ParseOptions\n): RegExp {\n const parts = paths.map((path) => pathToRegexp(path, keys, options).source);\n return new RegExp(`(?:${parts.join(\"|\")})`, flags(options));\n}\n\n/**\n * Create a path regexp from string input.\n */\nfunction stringToRegexp(\n path: string,\n keys?: Key[],\n options?: TokensToRegexpOptions & ParseOptions\n) {\n return tokensToRegexp(parse(path, options), keys, options);\n}\n\nexport interface TokensToRegexpOptions {\n /**\n * When `true` the regexp will be case sensitive. (default: `false`)\n */\n sensitive?: boolean;\n /**\n * When `true` the regexp won't allow an optional trailing delimiter to match. (default: `false`)\n */\n strict?: boolean;\n /**\n * When `true` the regexp will match to the end of the string. (default: `true`)\n */\n end?: boolean;\n /**\n * When `true` the regexp will match from the beginning of the string. (default: `true`)\n */\n start?: boolean;\n /**\n * Sets the final character for non-ending optimistic matches. (default: `/`)\n */\n delimiter?: string;\n /**\n * List of characters that can also be \"end\" characters.\n */\n endsWith?: string;\n /**\n * Encode path tokens for use in the `RegExp`.\n */\n encode?: (value: string) => string;\n}\n\n/**\n * Expose a function for taking tokens and returning a RegExp.\n */\nexport function tokensToRegexp(\n tokens: Token[],\n keys?: Key[],\n options: TokensToRegexpOptions = {}\n) {\n const {\n strict = false,\n start = true,\n end = true,\n encode = (x: string) => x,\n delimiter = \"/#?\",\n endsWith = \"\",\n } = options;\n const endsWithRe = `[${escapeString(endsWith)}]|$`;\n const delimiterRe = `[${escapeString(delimiter)}]`;\n let route = start ? \"^\" : \"\";\n\n // Iterate over the tokens and create our regexp string.\n for (const token of tokens) {\n if (typeof token === \"string\") {\n route += escapeString(encode(token));\n } else {\n const prefix = escapeString(encode(token.prefix));\n const suffix = escapeString(encode(token.suffix));\n\n if (token.pattern) {\n if (keys) keys.push(token);\n\n if (prefix || suffix) {\n if (token.modifier === \"+\" || token.modifier === \"*\") {\n const mod = token.modifier === \"*\" ? \"?\" : \"\";\n route += `(?:${prefix}((?:${token.pattern})(?:${suffix}${prefix}(?:${token.pattern}))*)${suffix})${mod}`;\n } else {\n route += `(?:${prefix}(${token.pattern})${suffix})${token.modifier}`;\n }\n } else {\n if (token.modifier === \"+\" || token.modifier === \"*\") {\n route += `((?:${token.pattern})${token.modifier})`;\n } else {\n route += `(${token.pattern})${token.modifier}`;\n }\n }\n } else {\n route += `(?:${prefix}${suffix})${token.modifier}`;\n }\n }\n }\n\n if (end) {\n if (!strict) route += `${delimiterRe}?`;\n\n route += !options.endsWith ? \"$\" : `(?=${endsWithRe})`;\n } else {\n const endToken = tokens[tokens.length - 1];\n const isEndDelimited =\n typeof endToken === \"string\"\n ? delimiterRe.indexOf(endToken[endToken.length - 1]) > -1\n : endToken === undefined;\n\n if (!strict) {\n route += `(?:${delimiterRe}(?=${endsWithRe}))?`;\n }\n\n if (!isEndDelimited) {\n route += `(?=${delimiterRe}|${endsWithRe})`;\n }\n }\n\n return new RegExp(route, flags(options));\n}\n\n/**\n * Supported `path-to-regexp` input types.\n */\nexport type Path = string | RegExp | Array;\n\n/**\n * Normalize the given path string, returning a regular expression.\n *\n * An empty array can be passed in for the keys, which will hold the\n * placeholder key descriptions. For example, using `/user/:id`, `keys` will\n * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.\n */\nexport function pathToRegexp(\n path: Path,\n keys?: Key[],\n options?: TokensToRegexpOptions & ParseOptions\n) {\n if (path instanceof RegExp) return regexpToRegexp(path, keys);\n if (Array.isArray(path)) return arrayToRegexp(path, keys, options);\n return stringToRegexp(path, keys, options);\n}\n"]}
\ No newline at end of file
diff --git a/build/node_modules/path-to-regexp/index.d.ts b/build/node_modules/path-to-regexp/index.d.ts
deleted file mode 100644
index 4a1f65c5..00000000
--- a/build/node_modules/path-to-regexp/index.d.ts
+++ /dev/null
@@ -1,84 +0,0 @@
-declare function pathToRegexp (path: pathToRegexp.Path, options?: pathToRegexp.RegExpOptions & pathToRegexp.ParseOptions): pathToRegexp.PathRegExp;
-declare function pathToRegexp (path: pathToRegexp.Path, keys?: pathToRegexp.Key[], options?: pathToRegexp.RegExpOptions & pathToRegexp.ParseOptions): pathToRegexp.PathRegExp;
-
-declare namespace pathToRegexp {
- export interface PathRegExp extends RegExp {
- // An array to be populated with the keys found in the path.
- keys: Key[];
- }
-
- export interface RegExpOptions {
- /**
- * When `true` the route will be case sensitive. (default: `false`)
- */
- sensitive?: boolean;
- /**
- * When `false` the trailing slash is optional. (default: `false`)
- */
- strict?: boolean;
- /**
- * When `false` the path will match at the beginning. (default: `true`)
- */
- end?: boolean;
- /**
- * Sets the final character for non-ending optimistic matches. (default: `/`)
- */
- delimiter?: string;
- }
-
- export interface ParseOptions {
- /**
- * Set the default delimiter for repeat parameters. (default: `'/'`)
- */
- delimiter?: string;
- }
-
- export interface TokensToFunctionOptions {
- /**
- * When `true` the regexp will be case sensitive. (default: `false`)
- */
- sensitive?: boolean;
- }
-
- /**
- * Parse an Express-style path into an array of tokens.
- */
- export function parse (path: string, options?: ParseOptions): Token[];
-
- /**
- * Transforming an Express-style path into a valid path.
- */
- export function compile (path: string, options?: ParseOptions & TokensToFunctionOptions): PathFunction;
-
- /**
- * Transform an array of tokens into a path generator function.
- */
- export function tokensToFunction (tokens: Token[], options?: TokensToFunctionOptions): PathFunction;
-
- /**
- * Transform an array of tokens into a matching regular expression.
- */
- export function tokensToRegExp (tokens: Token[], options?: RegExpOptions): PathRegExp;
- export function tokensToRegExp (tokens: Token[], keys?: Key[], options?: RegExpOptions): PathRegExp;
-
- export interface Key {
- name: string | number;
- prefix: string;
- delimiter: string;
- optional: boolean;
- repeat: boolean;
- pattern: string;
- partial: boolean;
- asterisk: boolean;
- }
-
- interface PathFunctionOptions {
- pretty?: boolean;
- }
-
- export type Token = string | Key;
- export type Path = string | RegExp | Array;
- export type PathFunction = (data?: Object, options?: PathFunctionOptions) => string;
-}
-
-export = pathToRegexp;
diff --git a/build/node_modules/path-to-regexp/index.js b/build/node_modules/path-to-regexp/index.js
deleted file mode 100644
index e485afec..00000000
--- a/build/node_modules/path-to-regexp/index.js
+++ /dev/null
@@ -1,426 +0,0 @@
-var isarray = require('isarray')
-
-/**
- * Expose `pathToRegexp`.
- */
-module.exports = pathToRegexp
-module.exports.parse = parse
-module.exports.compile = compile
-module.exports.tokensToFunction = tokensToFunction
-module.exports.tokensToRegExp = tokensToRegExp
-
-/**
- * The main path matching regexp utility.
- *
- * @type {RegExp}
- */
-var PATH_REGEXP = new RegExp([
- // Match escaped characters that would otherwise appear in future matches.
- // This allows the user to escape special characters that won't transform.
- '(\\\\.)',
- // Match Express-style parameters and un-named parameters with a prefix
- // and optional suffixes. Matches appear as:
- //
- // "/:test(\\d+)?" => ["/", "test", "\d+", undefined, "?", undefined]
- // "/route(\\d+)" => [undefined, undefined, undefined, "\d+", undefined, undefined]
- // "/*" => ["/", undefined, undefined, undefined, undefined, "*"]
- '([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))'
-].join('|'), 'g')
-
-/**
- * Parse a string for the raw tokens.
- *
- * @param {string} str
- * @param {Object=} options
- * @return {!Array}
- */
-function parse (str, options) {
- var tokens = []
- var key = 0
- var index = 0
- var path = ''
- var defaultDelimiter = options && options.delimiter || '/'
- var res
-
- while ((res = PATH_REGEXP.exec(str)) != null) {
- var m = res[0]
- var escaped = res[1]
- var offset = res.index
- path += str.slice(index, offset)
- index = offset + m.length
-
- // Ignore already escaped sequences.
- if (escaped) {
- path += escaped[1]
- continue
- }
-
- var next = str[index]
- var prefix = res[2]
- var name = res[3]
- var capture = res[4]
- var group = res[5]
- var modifier = res[6]
- var asterisk = res[7]
-
- // Push the current path onto the tokens.
- if (path) {
- tokens.push(path)
- path = ''
- }
-
- var partial = prefix != null && next != null && next !== prefix
- var repeat = modifier === '+' || modifier === '*'
- var optional = modifier === '?' || modifier === '*'
- var delimiter = res[2] || defaultDelimiter
- var pattern = capture || group
-
- tokens.push({
- name: name || key++,
- prefix: prefix || '',
- delimiter: delimiter,
- optional: optional,
- repeat: repeat,
- partial: partial,
- asterisk: !!asterisk,
- pattern: pattern ? escapeGroup(pattern) : (asterisk ? '.*' : '[^' + escapeString(delimiter) + ']+?')
- })
- }
-
- // Match any characters still remaining.
- if (index < str.length) {
- path += str.substr(index)
- }
-
- // If the path exists, push it onto the end.
- if (path) {
- tokens.push(path)
- }
-
- return tokens
-}
-
-/**
- * Compile a string to a template function for the path.
- *
- * @param {string} str
- * @param {Object=} options
- * @return {!function(Object=, Object=)}
- */
-function compile (str, options) {
- return tokensToFunction(parse(str, options), options)
-}
-
-/**
- * Prettier encoding of URI path segments.
- *
- * @param {string}
- * @return {string}
- */
-function encodeURIComponentPretty (str) {
- return encodeURI(str).replace(/[\/?#]/g, function (c) {
- return '%' + c.charCodeAt(0).toString(16).toUpperCase()
- })
-}
-
-/**
- * Encode the asterisk parameter. Similar to `pretty`, but allows slashes.
- *
- * @param {string}
- * @return {string}
- */
-function encodeAsterisk (str) {
- return encodeURI(str).replace(/[?#]/g, function (c) {
- return '%' + c.charCodeAt(0).toString(16).toUpperCase()
- })
-}
-
-/**
- * Expose a method for transforming tokens into the path function.
- */
-function tokensToFunction (tokens, options) {
- // Compile all the tokens into regexps.
- var matches = new Array(tokens.length)
-
- // Compile all the patterns before compilation.
- for (var i = 0; i < tokens.length; i++) {
- if (typeof tokens[i] === 'object') {
- matches[i] = new RegExp('^(?:' + tokens[i].pattern + ')$', flags(options))
- }
- }
-
- return function (obj, opts) {
- var path = ''
- var data = obj || {}
- var options = opts || {}
- var encode = options.pretty ? encodeURIComponentPretty : encodeURIComponent
-
- for (var i = 0; i < tokens.length; i++) {
- var token = tokens[i]
-
- if (typeof token === 'string') {
- path += token
-
- continue
- }
-
- var value = data[token.name]
- var segment
-
- if (value == null) {
- if (token.optional) {
- // Prepend partial segment prefixes.
- if (token.partial) {
- path += token.prefix
- }
-
- continue
- } else {
- throw new TypeError('Expected "' + token.name + '" to be defined')
- }
- }
-
- if (isarray(value)) {
- if (!token.repeat) {
- throw new TypeError('Expected "' + token.name + '" to not repeat, but received `' + JSON.stringify(value) + '`')
- }
-
- if (value.length === 0) {
- if (token.optional) {
- continue
- } else {
- throw new TypeError('Expected "' + token.name + '" to not be empty')
- }
- }
-
- for (var j = 0; j < value.length; j++) {
- segment = encode(value[j])
-
- if (!matches[i].test(segment)) {
- throw new TypeError('Expected all "' + token.name + '" to match "' + token.pattern + '", but received `' + JSON.stringify(segment) + '`')
- }
-
- path += (j === 0 ? token.prefix : token.delimiter) + segment
- }
-
- continue
- }
-
- segment = token.asterisk ? encodeAsterisk(value) : encode(value)
-
- if (!matches[i].test(segment)) {
- throw new TypeError('Expected "' + token.name + '" to match "' + token.pattern + '", but received "' + segment + '"')
- }
-
- path += token.prefix + segment
- }
-
- return path
- }
-}
-
-/**
- * Escape a regular expression string.
- *
- * @param {string} str
- * @return {string}
- */
-function escapeString (str) {
- return str.replace(/([.+*?=^!:${}()[\]|\/\\])/g, '\\$1')
-}
-
-/**
- * Escape the capturing group by escaping special characters and meaning.
- *
- * @param {string} group
- * @return {string}
- */
-function escapeGroup (group) {
- return group.replace(/([=!:$\/()])/g, '\\$1')
-}
-
-/**
- * Attach the keys as a property of the regexp.
- *
- * @param {!RegExp} re
- * @param {Array} keys
- * @return {!RegExp}
- */
-function attachKeys (re, keys) {
- re.keys = keys
- return re
-}
-
-/**
- * Get the flags for a regexp from the options.
- *
- * @param {Object} options
- * @return {string}
- */
-function flags (options) {
- return options && options.sensitive ? '' : 'i'
-}
-
-/**
- * Pull out keys from a regexp.
- *
- * @param {!RegExp} path
- * @param {!Array} keys
- * @return {!RegExp}
- */
-function regexpToRegexp (path, keys) {
- // Use a negative lookahead to match only capturing groups.
- var groups = path.source.match(/\((?!\?)/g)
-
- if (groups) {
- for (var i = 0; i < groups.length; i++) {
- keys.push({
- name: i,
- prefix: null,
- delimiter: null,
- optional: false,
- repeat: false,
- partial: false,
- asterisk: false,
- pattern: null
- })
- }
- }
-
- return attachKeys(path, keys)
-}
-
-/**
- * Transform an array into a regexp.
- *
- * @param {!Array} path
- * @param {Array} keys
- * @param {!Object} options
- * @return {!RegExp}
- */
-function arrayToRegexp (path, keys, options) {
- var parts = []
-
- for (var i = 0; i < path.length; i++) {
- parts.push(pathToRegexp(path[i], keys, options).source)
- }
-
- var regexp = new RegExp('(?:' + parts.join('|') + ')', flags(options))
-
- return attachKeys(regexp, keys)
-}
-
-/**
- * Create a path regexp from string input.
- *
- * @param {string} path
- * @param {!Array} keys
- * @param {!Object} options
- * @return {!RegExp}
- */
-function stringToRegexp (path, keys, options) {
- return tokensToRegExp(parse(path, options), keys, options)
-}
-
-/**
- * Expose a function for taking tokens and returning a RegExp.
- *
- * @param {!Array} tokens
- * @param {(Array|Object)=} keys
- * @param {Object=} options
- * @return {!RegExp}
- */
-function tokensToRegExp (tokens, keys, options) {
- if (!isarray(keys)) {
- options = /** @type {!Object} */ (keys || options)
- keys = []
- }
-
- options = options || {}
-
- var strict = options.strict
- var end = options.end !== false
- var route = ''
-
- // Iterate over the tokens and create our regexp string.
- for (var i = 0; i < tokens.length; i++) {
- var token = tokens[i]
-
- if (typeof token === 'string') {
- route += escapeString(token)
- } else {
- var prefix = escapeString(token.prefix)
- var capture = '(?:' + token.pattern + ')'
-
- keys.push(token)
-
- if (token.repeat) {
- capture += '(?:' + prefix + capture + ')*'
- }
-
- if (token.optional) {
- if (!token.partial) {
- capture = '(?:' + prefix + '(' + capture + '))?'
- } else {
- capture = prefix + '(' + capture + ')?'
- }
- } else {
- capture = prefix + '(' + capture + ')'
- }
-
- route += capture
- }
- }
-
- var delimiter = escapeString(options.delimiter || '/')
- var endsWithDelimiter = route.slice(-delimiter.length) === delimiter
-
- // In non-strict mode we allow a slash at the end of match. If the path to
- // match already ends with a slash, we remove it for consistency. The slash
- // is valid at the end of a path match, not in the middle. This is important
- // in non-ending mode, where "/test/" shouldn't match "/test//route".
- if (!strict) {
- route = (endsWithDelimiter ? route.slice(0, -delimiter.length) : route) + '(?:' + delimiter + '(?=$))?'
- }
-
- if (end) {
- route += '$'
- } else {
- // In non-ending mode, we need the capturing groups to match as much as
- // possible by using a positive lookahead to the end or next path segment.
- route += strict && endsWithDelimiter ? '' : '(?=' + delimiter + '|$)'
- }
-
- return attachKeys(new RegExp('^' + route, flags(options)), keys)
-}
-
-/**
- * Normalize the given path string, returning a regular expression.
- *
- * An empty array can be passed in for the keys, which will hold the
- * placeholder key descriptions. For example, using `/user/:id`, `keys` will
- * contain `[{ name: 'id', delimiter: '/', optional: false, repeat: false }]`.
- *
- * @param {(string|RegExp|Array)} path
- * @param {(Array|Object)=} keys
- * @param {Object=} options
- * @return {!RegExp}
- */
-function pathToRegexp (path, keys, options) {
- if (!isarray(keys)) {
- options = /** @type {!Object} */ (keys || options)
- keys = []
- }
-
- options = options || {}
-
- if (path instanceof RegExp) {
- return regexpToRegexp(path, /** @type {!Array} */ (keys))
- }
-
- if (isarray(path)) {
- return arrayToRegexp(/** @type {!Array} */ (path), /** @type {!Array} */ (keys), options)
- }
-
- return stringToRegexp(/** @type {string} */ (path), /** @type {!Array} */ (keys), options)
-}
diff --git a/build/node_modules/path-to-regexp/package.json b/build/node_modules/path-to-regexp/package.json
index 4d1a36be..39d5bc90 100644
--- a/build/node_modules/path-to-regexp/package.json
+++ b/build/node_modules/path-to-regexp/package.json
@@ -1,47 +1,62 @@
{
"name": "path-to-regexp",
+ "version": "6.2.1",
+ "publishConfig": {
+ "access": "public"
+ },
"description": "Express style path to RegExp utility",
- "version": "1.8.0",
- "main": "index.js",
- "typings": "index.d.ts",
- "files": [
- "index.js",
- "index.d.ts",
- "LICENSE"
- ],
+ "license": "MIT",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/pillarjs/path-to-regexp.git"
+ },
+ "main": "dist/index.js",
+ "module": "dist.es2015/index.js",
"scripts": {
- "lint": "standard",
- "test-spec": "mocha --require ts-node/register -R spec --bail test.ts",
- "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require ts-node/register -R spec test.ts",
- "prepublish": "typings install",
- "test": "npm run lint && npm run test-cov"
+ "build": "ts-scripts build",
+ "format": "ts-scripts format",
+ "lint": "ts-scripts lint",
+ "prepare": "ts-scripts install && npm run build",
+ "size": "size-limit",
+ "specs": "ts-scripts specs",
+ "test": "ts-scripts test && npm run size"
},
+ "files": [
+ "dist.es2015/",
+ "dist/"
+ ],
"keywords": [
"express",
"regexp",
"route",
"routing"
],
- "component": {
- "scripts": {
- "path-to-regexp": "index.js"
- }
- },
- "license": "MIT",
- "repository": {
- "type": "git",
- "url": "https://github.com/pillarjs/path-to-regexp.git"
- },
"devDependencies": {
- "chai": "^2.3.0",
- "istanbul": "~0.3.0",
- "mocha": "~2.2.4",
- "standard": "~3.7.3",
- "ts-node": "^0.5.5",
- "typescript": "^1.8.7",
- "typings": "^1.0.4"
+ "@borderless/ts-scripts": "^0.8.0",
+ "@size-limit/preset-small-lib": "^7.0.8",
+ "@types/jest": "^27.4.0",
+ "@types/node": "^17.0.17",
+ "@types/semver": "^7.3.1",
+ "semver": "^7.3.5",
+ "size-limit": "^7.0.8",
+ "typescript": "^4.5.5"
},
- "dependencies": {
- "isarray": "0.0.1"
+ "typings": "dist/index.d.ts",
+ "sideEffects": false,
+ "size-limit": [
+ {
+ "path": "dist.es2015/index.js",
+ "limit": "2.1 kB"
+ }
+ ],
+ "ts-scripts": {
+ "dist": [
+ "dist",
+ "dist.es2015"
+ ],
+ "project": [
+ "tsconfig.build.json",
+ "tsconfig.es2015.json"
+ ]
}
}
diff --git a/build/package-lock.json b/build/package-lock.json
index bcf2fd9b..f9664db8 100644
--- a/build/package-lock.json
+++ b/build/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "purecloud-guest-chat-client",
- "version": "13.8.0",
+ "version": "13.8.1",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "purecloud-guest-chat-client",
- "version": "13.8.0",
+ "version": "13.8.1",
"license": "MIT",
"dependencies": {
"axios": "^0.27.2",
@@ -161,9 +161,9 @@
"dev": true
},
"node_modules/@types/node": {
- "version": "20.10.4",
- "resolved": "https://registry.npmjs.org/@types/node/-/node-20.10.4.tgz",
- "integrity": "sha512-D08YG6rr8X90YB56tSIuBaddy/UXAA9RKJoFvrsnogAum/0pmjkgi4+2nx96A330FmioegBWmEYQ+syqCFaveg==",
+ "version": "20.11.6",
+ "resolved": "https://registry.npmjs.org/@types/node/-/node-20.11.6.tgz",
+ "integrity": "sha512-+EOokTnksGVgip2PbYbr3xnR7kZigh4LbybAfBAw5BpnQ+FqBYUsvCEjYd70IXKlbohQ64mzEYmMtlWUY8q//Q==",
"dev": true,
"dependencies": {
"undici-types": "~5.26.4"
@@ -1037,9 +1037,9 @@
"integrity": "sha512-GRnmB5gPyJpAhTQdSZTSp9uaPSvl09KoYcMQtsB9rQoOmzs9dH6ffeccH+Z+cv6P68Hu5bC6JjRh4Ah/mHSNRw=="
},
"node_modules/follow-redirects": {
- "version": "1.15.3",
- "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.3.tgz",
- "integrity": "sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q==",
+ "version": "1.15.5",
+ "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.5.tgz",
+ "integrity": "sha512-vSFWUON1B+yAw1VN4xMfxgn5fTUiaOzAJCKBwIIgT/+7CuGy9+r+5gITvP62j3RmaD5Ph65UaERdOSRGUzZtgw==",
"funding": [
{
"type": "individual",
@@ -1448,9 +1448,9 @@
}
},
"node_modules/just-extend": {
- "version": "4.2.1",
- "resolved": "https://registry.npmjs.org/just-extend/-/just-extend-4.2.1.tgz",
- "integrity": "sha512-g3UB796vUFIY90VIv/WX3L2c8CS2MdWUww3CNrYmqza1Fg0DURc2K/O4YrnklBdQarSJ/y8JnJYDGc+1iumQjg==",
+ "version": "6.2.0",
+ "resolved": "https://registry.npmjs.org/just-extend/-/just-extend-6.2.0.tgz",
+ "integrity": "sha512-cYofQu2Xpom82S6qD778jBDpwvvy39s1l/hrYij2u9AMdQcGRpaBu6kY4mVhuno5kJVi1DAz4aiphA2WI1/OAw==",
"dev": true
},
"node_modules/kuler": {
@@ -1913,45 +1913,36 @@
}
},
"node_modules/nise": {
- "version": "5.1.5",
- "resolved": "https://registry.npmjs.org/nise/-/nise-5.1.5.tgz",
- "integrity": "sha512-VJuPIfUFaXNRzETTQEEItTOP8Y171ijr+JLq42wHes3DiryR8vT+1TXQW/Rx8JNUhyYYWyIvjXTU6dOhJcs9Nw==",
+ "version": "5.1.7",
+ "resolved": "https://registry.npmjs.org/nise/-/nise-5.1.7.tgz",
+ "integrity": "sha512-wWtNUhkT7k58uvWTB/Gy26eA/EJKtPZFVAhEilN5UYVmmGRYOURbejRUyKm0Uu9XVEW7K5nBOZfR8VMB4QR2RQ==",
"dev": true,
"dependencies": {
- "@sinonjs/commons": "^2.0.0",
- "@sinonjs/fake-timers": "^10.0.2",
- "@sinonjs/text-encoding": "^0.7.1",
- "just-extend": "^4.0.2",
- "path-to-regexp": "^1.7.0"
+ "@sinonjs/commons": "^3.0.0",
+ "@sinonjs/fake-timers": "^11.2.2",
+ "@sinonjs/text-encoding": "^0.7.2",
+ "just-extend": "^6.2.0",
+ "path-to-regexp": "^6.2.1"
}
},
"node_modules/nise/node_modules/@sinonjs/commons": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-2.0.0.tgz",
- "integrity": "sha512-uLa0j859mMrg2slwQYdO/AkrOfmH+X6LTVmNTS9CqexuE2IvVORIkSpJLqePAbEnKJ77aMmCwr1NUZ57120Xcg==",
+ "version": "3.0.1",
+ "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz",
+ "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==",
"dev": true,
"dependencies": {
"type-detect": "4.0.8"
}
},
"node_modules/nise/node_modules/@sinonjs/fake-timers": {
- "version": "10.3.0",
- "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz",
- "integrity": "sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA==",
+ "version": "11.2.2",
+ "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-11.2.2.tgz",
+ "integrity": "sha512-G2piCSxQ7oWOxwGSAyFHfPIsyeJGXYtc6mFbnFA+kRXkiEnTl8c/8jul2S329iFBnDI9HGoeWWAZvuvOkZccgw==",
"dev": true,
"dependencies": {
"@sinonjs/commons": "^3.0.0"
}
},
- "node_modules/nise/node_modules/@sinonjs/fake-timers/node_modules/@sinonjs/commons": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.0.tgz",
- "integrity": "sha512-jXBtWAF4vmdNmZgD5FoKsVLv3rPgDnLgPbU84LIJ3otV44vJlDRokVng5v8NFJdCf/da9legHcKaRuZs4L7faA==",
- "dev": true,
- "dependencies": {
- "type-detect": "4.0.8"
- }
- },
"node_modules/normalize-path": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz",
@@ -2058,13 +2049,10 @@
"dev": true
},
"node_modules/path-to-regexp": {
- "version": "1.8.0",
- "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-1.8.0.tgz",
- "integrity": "sha512-n43JRhlUKUAlibEJhPeir1ncUID16QnEjNpwzNdO3Lm4ywrBpBZ5oLD0I6br9evr1Y9JTqwRtAh7JLoOzAQdVA==",
- "dev": true,
- "dependencies": {
- "isarray": "0.0.1"
- }
+ "version": "6.2.1",
+ "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-6.2.1.tgz",
+ "integrity": "sha512-JLyh7xT1kizaEvcaXOQwOc2/Yhw6KZOvPf1S8401UyLk86CU79LN3vl7ztXGm/pZ+YjoyAJ4rxmHwbkBXJX+yw==",
+ "dev": true
},
"node_modules/pbkdf2": {
"version": "3.1.2",
diff --git a/build/package.json b/build/package.json
index 770f469e..1cff0b7d 100644
--- a/build/package.json
+++ b/build/package.json
@@ -1,6 +1,6 @@
{
"name": "purecloud-guest-chat-client",
- "version": "13.8.0",
+ "version": "13.8.1",
"description": "A JavaScript library to interface with the PureCloud Platform API",
"license": "MIT",
"main": "dist/node/purecloud-guest-chat-client.js",
diff --git a/build/src/purecloud-guest-chat-client/ApiClient.js b/build/src/purecloud-guest-chat-client/ApiClient.js
index 8027cf4e..87a6f2f6 100644
--- a/build/src/purecloud-guest-chat-client/ApiClient.js
+++ b/build/src/purecloud-guest-chat-client/ApiClient.js
@@ -3,7 +3,7 @@ import Configuration from './configuration.js';
/**
* @module purecloud-guest-chat-client/ApiClient
- * @version 13.8.0
+ * @version 13.8.1
*/
class ApiClient {
/**
diff --git a/build/src/purecloud-guest-chat-client/PureCloudRegionHosts.js b/build/src/purecloud-guest-chat-client/PureCloudRegionHosts.js
index c29d3a6a..77ba0ed8 100644
--- a/build/src/purecloud-guest-chat-client/PureCloudRegionHosts.js
+++ b/build/src/purecloud-guest-chat-client/PureCloudRegionHosts.js
@@ -11,4 +11,7 @@ export default {
ap_south_1: 'aps1.pure.cloud',
us_east_2: 'use2.us-gov-pure.cloud',
sa_east_1: 'sae1.pure.cloud',
+ me_central_1: 'mec1.pure.cloud',
+ ap_northeast_3: 'apne3.pure.cloud',
+ eu_central_2: 'euc2.pure.cloud',
};
diff --git a/build/src/purecloud-guest-chat-client/api/WebChatApi.js b/build/src/purecloud-guest-chat-client/api/WebChatApi.js
index 1f1b64a5..0ceb1cb8 100644
--- a/build/src/purecloud-guest-chat-client/api/WebChatApi.js
+++ b/build/src/purecloud-guest-chat-client/api/WebChatApi.js
@@ -5,7 +5,7 @@ class WebChatApi {
/**
* WebChat service.
* @module purecloud-guest-chat-client/api/WebChatApi
- * @version 13.8.0
+ * @version 13.8.1
*/
/**
diff --git a/build/src/purecloud-guest-chat-client/index.js b/build/src/purecloud-guest-chat-client/index.js
index 23b280f3..0586d72e 100644
--- a/build/src/purecloud-guest-chat-client/index.js
+++ b/build/src/purecloud-guest-chat-client/index.js
@@ -32,7 +32,7 @@ import WebChatApi from './api/WebChatApi.js';
*
*
* @module purecloud-guest-chat-client/index
- * @version 13.8.0
+ * @version 13.8.1
*/
class platformClient {
constructor() {
diff --git a/releaseNotes.md b/releaseNotes.md
index 98039436..e7739ec4 100644
--- a/releaseNotes.md
+++ b/releaseNotes.md
@@ -1,4 +1,4 @@
-Platform API version: 7567
+Platform API version: 7660
@@ -6,11 +6,7 @@ Platform API version: 7567
# Major Changes (0 changes)
-# Minor Changes (1 change)
-
-**Limit** (1 change)
-
-* Enum value employee.engagement was added to property namespace
+# Minor Changes (0 changes)
# Point Changes (0 changes)
diff --git a/swagger.json b/swagger.json
index 613b9533..03475b64 100644
--- a/swagger.json
+++ b/swagger.json
@@ -1 +1 @@
-{"swagger":"2.0","info":{"description":"With the PureCloud Platform API, you can control all aspects of your PureCloud environment. With the APIs you can access the system configuration, manage conversations and more.","version":"v2","title":"PureCloud Platform API","termsOfService":"https://help.mypurecloud.com/articles/terms-and-conditions/","contact":{"name":"PureCloud Developer Evangelists","url":"https://developer.genesys.cloud","email":"DeveloperEvangelists@genesys.com"},"license":{"name":"UNLICENSED","url":"https://help.mypurecloud.com/articles/terms-and-conditions/"}},"host":"api.mypurecloud.com","tags":[{"name":"Events","description":"Events","externalDocs":{"description":"Events Documentation","url":"https://developer.genesys.cloud/api/rest/v2/events/"}},{"name":"Authorization","description":"Roles and permissions","externalDocs":{"description":"Authorization Documentation","url":"https://developer.mypurecloud.com/api/rest/v2/authorization/"}},{"name":"OAuth","description":"OAuth clients, providers","externalDocs":{"description":"OAuth Documentation","url":"https://developer.mypurecloud.com/api/rest/v2/oauth/"}},{"name":"Objects","description":"Access-controlled objects in the platform","externalDocs":{"description":"authorization docs","url":"https://developer.mypurecloud.com/api/rest/v2/authorization/"}},{"name":"Tokens","description":"Authentication Tokens","externalDocs":{"description":"Tokens Documentation","url":"https://developer.mypurecloud.com/api/rest/v2/tokens/"}},{"name":"Agent UI","description":"Agent UI settings and configuration"},{"name":"Alerting","description":"Rules and alerts","externalDocs":{"description":"Alerting Documentation","url":"https://developer.genesys.cloud/notificationsalerts/alerting/alerting-apis"}},{"name":"Analytics","description":"Analytics querying and reporting.","externalDocs":{"description":"Analytics Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/analytics/analytics-apis"}},{"name":"Architect","description":"Flows, Prompts, IVR schedules, Dependency Tracking","externalDocs":{"description":"Architect Documentation","url":"https://developer.genesys.cloud/routing/architect/"}},{"name":"Agent Assistants","description":"Manage virtual agent assistants."},{"name":"Audit","description":"","externalDocs":{"description":"Audit Documentation","url":"https://developer.genesys.cloud/platform/audit/"}},{"name":"Badges","description":"Badges stats"},{"name":"Billing","description":"","externalDocs":{"description":"billing Documentation","url":"https://developer.genesys.cloud/billing/"}},{"name":"Bots","description":"Chatbot Interactions"},{"name":"Bridge","description":""},{"name":"Callbacks","description":""},{"name":"Calls","description":""},{"name":"Carrier Services","description":""},{"name":"Chat","description":""},{"name":"Coaching","description":"Schedule and manage coaching appointments","externalDocs":{"description":"Coaching","url":"https://developer.genesys.cloud/routing/conversations/coaching-apis"}},{"name":"Cobrowse","description":""},{"name":"Compliance","description":""},{"name":"Configuration","description":"","externalDocs":{"description":"Configuration Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Content Management","description":"","externalDocs":{"description":"Content Management Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/contentmanagement/contentmanagement-apis"}},{"name":"Conversations","description":"","externalDocs":{"description":"Conversations Documentation","url":"https://developer.genesys.cloud/routing/conversations/conversations-apis"}},{"name":"Data Extensions","description":"Data extensions","externalDocs":{"description":"Data Extensions","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Data Privacy","description":"Data privacy masking rules","externalDocs":{"description":"Data Privacy","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Dialog Engine","description":"Dialog Engine","externalDocs":{"description":"Dialog Engine documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Directory Proxy","description":"Search, Suggest, and people"},{"name":"Docs","description":"Swagger documentation definitions"},{"name":"Downloads","description":"Download file","externalDocs":{"description":"Downloads Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Emails","description":""},{"name":"External Contacts","description":"External Organizations, contacts, notes and relationships","externalDocs":{"description":"External Contacts","url":"https://developer.genesys.cloud/commdigital/externalcontacts/externalcontacts-apis"}},{"name":"Fax","description":"","externalDocs":{"description":"Fax Documentation","url":"https://developer.genesys.cloud/commdigital/fax/"}},{"name":"Flows","description":"IVR Flows","externalDocs":{"description":"Flow Aggregates Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/analytics/aggregate/flow-query"}},{"name":"Gamification","description":"Gamification, Scorecard, and leaderboard","externalDocs":{"description":"Gamification Documentation","url":"https://developer.genesys.cloud/useragentman/gamification/"}},{"name":"General Data Protection Regulation","description":"Working with General Data Protection Regulation (GDPR) requests","externalDocs":{"description":"GDPR Documentation","url":"https://developer.genesys.cloud/gdprprivacy/"}},{"name":"Geolocation","description":"","externalDocs":{"description":"Geolocation Documentation","url":"https://developer.genesys.cloud/platform/geolocation-apis"}},{"name":"Greetings","description":"","externalDocs":{"description":"Greetings Documentation","url":"https://developer.genesys.cloud/commdigital/greetings/"}},{"name":"Groups","description":"Groups, members","externalDocs":{"description":"Groups Documentation","url":"https://developer.genesys.cloud/useragentman/groups/"}},{"name":"Identity Provider","description":"Identity providers","externalDocs":{"description":"Identity Providers Documentation","url":"https://developer.genesys.cloud/authorization/oauth-apis/identityprovider/"}},{"name":"Infrastructure as Code","description":"Accelerated infrastructure configuration via reusable modules","externalDocs":{"description":"Infrastructure as Code Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Integrations","description":"","externalDocs":{"description":"Integrations Documentation","url":"https://developer.genesys.cloud/platform/integrations/"}},{"name":"Journey","description":"Predictive Engagement, Customer Journey","externalDocs":{"description":"Journey documentation","url":"https://developer.genesys.cloud/commdigital/digital/webmessaging/journey/journey-apis"}},{"name":"Languages","description":"Available languages","externalDocs":{"description":"Languages Documentation","url":"https://developer.genesys.cloud/organization/languages-apis"}},{"name":"Knowledge","description":"Knowledge administration and search"},{"name":"Language Understanding","description":"Language Understanding","externalDocs":{"description":"Language Understanding documentation","url":"https://developer.genesys.cloud/organization/languageunderstanding/languageunderstanding-apis"}},{"name":"Learning","description":"Manage learning modules"},{"name":"Licensing","description":""},{"name":"License","description":"Per-user platform license assignments","externalDocs":{"description":"License Documentation","url":"https://developer.genesys.cloud/organization/license-apis"}},{"name":"Locations","description":"Physical locations","externalDocs":{"description":"Locations Documentation","url":"https://developer.genesys.cloud/telephony/locations-apis"}},{"name":"Marketplace","description":"Marketplace listing management"},{"name":"Data Action Metrics","description":"Metrics about data actions"},{"name":"Log Capture","description":"Browser Log Capture"},{"name":"Meeting","description":"","externalDocs":{"description":"Meeting Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Messaging","description":"Messaging","externalDocs":{"description":"Messaging Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Mobile Devices","description":"Devices","externalDocs":{"description":"Devices Documentation","url":"https://developer.genesys.cloud/organization/mobiledevices-apis"}},{"name":"Notifications","description":"Channels, subscriptions, topics, mobile push registration","externalDocs":{"description":"Notifications Documentation","url":"https://developer.genesys.cloud/notificationsalerts/notifications/notifications-apis"}},{"name":"Onboarding","description":"Onboarding"},{"name":"Operational Events","description":"Operational events"},{"name":"Organization","description":"Organization","externalDocs":{"description":"Organization Documentation","url":"https://developer.genesys.cloud/organization/organization/"}},{"name":"Organization Authorization","description":"Organization Authorization","externalDocs":{"description":"Organization Authorization Documentation","url":"https://developer.genesys.cloud/authorization/oauth-apis/organizationauthorization-apis"}},{"name":"Outbound","description":"","externalDocs":{"description":"Outbound Documentation","url":"https://developer.genesys.cloud/routing/outbound/"}},{"name":"Presence","description":"User and organization presences","externalDocs":{"description":"Presence Documentation","url":"https://developer.genesys.cloud/useragentman/presence/"}},{"name":"Process Automation","description":"Work items, flows, triggers"},{"name":"Quality","description":"Evaluations, calibrations","externalDocs":{"description":"Quality Management Documentation","url":"https://developer.genesys.cloud/useragentman/quality/"}},{"name":"Recording","description":"Recordings, policies, annotations, orphans","externalDocs":{"description":"Recording Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/recording/"}},{"name":"Response Management","description":"Responses, library, Response Assets, query","externalDocs":{"description":"Response Management Documentation","url":"https://developer.genesys.cloud/organization/responsemanagement-apis"}},{"name":"Routing","description":"Queues, wrapup codes, skills, email & sms config, predictive routing","externalDocs":{"description":"Routing Documentation","url":"https://developer.genesys.cloud/routing/routing/"}},{"name":"SCIM","description":"System for Cross-domain Identity Management","externalDocs":{"description":"System for Cross-domain Identity Management: Definitions, Overview, Concepts, and Requirements","url":"https://developer.genesys.cloud/useragentman/scim/scim-apis"}},{"name":"Screen Recording","description":"Screen recording with background assistant"},{"name":"Scripts","description":"Agent-facing scripts for interactions","externalDocs":{"description":"Scripts Documentation","url":"https://developer.genesys.cloud/routing/scripts/"}},{"name":"Search","description":"Search aggregate, users, groups","externalDocs":{"description":"Search Documentation","url":"https://developer.genesys.cloud/organization/search/"}},{"name":"Settings","description":"Persist settings"},{"name":"SignedData","description":"Package data in signed JWTs"},{"name":"Socialize","description":"Gets, sets and updates entity data for the Socialize service"},{"name":"Speech & Text Analytics","description":""},{"name":"Stations","description":"Stations","externalDocs":{"description":"Stations Documentation","url":"https://developer.genesys.cloud/telephony/stations-apis"}},{"name":"Suggest","description":"Search suggest user, group, locations"},{"name":"Teams","description":"Teams, members","externalDocs":{"description":"Teams Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Telephony","description":"Telephony providers and configuration","externalDocs":{"description":"Telephony Documentation","url":"https://developer.genesys.cloud/telephony/telephony-apis"}},{"name":"Telephony Providers Edge","description":"Edge phones, trunks, lines.","externalDocs":{"description":"telephony provider edge","url":"https://developer.genesys.cloud/telephony/telephony-apis"}},{"name":"Test Automation","description":"Internal Testing Tool for managing Testing Data"},{"name":"Textbots","description":"Chatbot Interactions"},{"name":"Uploads","description":"Presigned url generator for uploading files","externalDocs":{"description":"Upload Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/uploads/uploads-apis"}},{"name":"User Recordings","description":"Summary, media","externalDocs":{"description":"User Recordings Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/recording/userrecordings-apis"}},{"name":"Users","description":"Me, routing, roles","externalDocs":{"description":"Users Documentation","url":"https://developer.genesys.cloud/useragentman/users/"}},{"name":"Utilities","description":"","externalDocs":{"description":"Utilities Documentation","url":"https://developer.genesys.cloud/organization/utilities-apis"}},{"name":"Videos","description":""},{"name":"Voicemail","description":"Mailbox, messages, policy","externalDocs":{"description":"Voicemail Documentation","url":"https://developer.genesys.cloud/commdigital/voicemail/"}},{"name":"WebChat","description":"WebChat deployments","externalDocs":{"description":"WebChat Deployment Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webchat/webchat-apis"}},{"name":"WebMessaging","description":"Web messaging","externalDocs":{"description":"Web Messaging Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webmessaging/webmessaging-apis"}},{"name":"Widgets","description":"Widget deployments","externalDocs":{"description":"Widget Deployment Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webchat/widgets-apis"}},{"name":"Usage","description":"View organizational level usage data","externalDocs":{"description":"Usage Documentation","url":"https://developer.genesys.cloud/platform/usage-apis"}},{"name":"Workforce Management","description":"Adherence, Schedules, Forecasts, Intraday Monitoring, Time Off Requests, Configuration","externalDocs":{"description":"Workforce Management Documentation","url":"https://developer.genesys.cloud/useragentman/workforcemanagement/"}},{"name":"Voicebots","description":"Voicebot Interactions"},{"name":"Web Deployments","description":"Web Deployments","externalDocs":{"description":"Web Deployments Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webchat/webdeployments-apis"}},{"name":"Task Management","description":"Task Management"}],"schemes":["https"],"consumes":["application/json"],"produces":["application/json"],"paths":{"/api/v2/webchat/guest/conversations":{"post":{"tags":["WebChat"],"summary":"Create an ACD chat conversation from an external customer.","description":"This endpoint will create a new ACD Chat conversation under the specified Chat Deployment.\n The conversation will begin with a guest member in it (with a role=CUSTOMER) according to the customer information that is supplied. If the guest member is authenticated, the 'memberAuthToken' field should include his JWT as generated by the 'POST /api/v2/signeddata' resource; if the guest member is anonymous (and the Deployment permits it) this field can be omitted.\n The returned data includes the IDs of the conversation created, along with a newly-create JWT token that you can supply to all future endpoints as authentication to perform operations against that conversation. After successfully creating a conversation, you should connect a websocket to the event stream named in the 'eventStreamUri' field of the response; the conversation is not routed until the event stream is attached.","operationId":"postWebchatGuestConversations","produces":["application/json"],"parameters":[{"in":"body","name":"body","description":"CreateConversationRequest","required":true,"schema":{"$ref":"#/definitions/CreateWebChatConversationRequest"}}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/CreateWebChatConversationResponse"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.notnull.createconversationrequest.journeycontext.customer":"The customer may not be null.","chat.error.notnull.createconversationrequest.journeycontext.triggeringaction.actionmapversion":"The actionmapversion property may not be null.","chat.error.invalid.queue":"The specified queue is not valid.","chat.error.notnull.createconversationrequest.journeycontext.triggeringaction.actionid":"The actionid property may not be null.","bad.request":"The request could not be understood by the server due to malformed syntax.","chat.error.notnull.createconversationrequest.journeycontext.customer.customerid":"The customerid property may not be null.","constraint.validation":"%s","chat.error.notnull.createconversationrequest.memberinfo.displayname":"The displayname property may not be null.","chat.error.notnull.createconversationrequest.routingtarget":"The routingtarget property may not be null.","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","chat.error.notnull.createconversationrequest.journeycontext.customer.customeridtype":"The customeridtype property may not be null.","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s","chat.deployment.require.auth":"The deployment requires the customer member to be authenticated.","chat.error.notnull.createconversationrequest.journeycontext.customersession.sessionid":"The sessionid property may not be null.","chat.error.notnull.createconversationrequest.journeycontext.customersession.sessionidtype":"The sessionidtype property may not be null.","chat.deployment.bad.auth":"The customer member authentication has failed.","chat.error.notnull.createconversationrequest.journeycontext.triggeringaction.actionmapid":"The actionmapid property may not be null.","chat.error.createconversationrequest.routingtarget":"The routing target is not valid.","invalid.property":"Value [%s] is not a valid property for object [%s]","chat.deployment.disabled":"The web chat deployment is currently disabled.","chat.error.pattern.createconversationrequest.deploymentid":"The deploymentid property may not be null.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.invalid.flow":"Invalid chat flow","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","chat.error.bad.request":"Error occurred due to invalid request."}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"origin.not.allowed":"Not allowed to create an ACD chat conversation from an external customer.","missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"caht.error":"Error performing chat conversation operation.","internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.service.timeout":"Chat service timeout error.","authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"x-purecloud-method-name":"postWebchatGuestConversations"}},"/api/v2/webchat/guest/conversations/{conversationId}/mediarequests/{mediaRequestId}":{"get":{"tags":["WebChat"],"summary":"Get a media request in the conversation","description":"","operationId":"getWebchatGuestConversationMediarequest","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"mediaRequestId","in":"path","description":"mediaRequestId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatGuestMediaRequest"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The media request was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMediarequest"},"patch":{"tags":["WebChat"],"summary":"Update a media request in the conversation, setting the state to ACCEPTED/DECLINED/ERRORED","description":"","operationId":"patchWebchatGuestConversationMediarequest","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"mediaRequestId","in":"path","description":"mediaRequestId","required":true,"type":"string"},{"in":"body","name":"body","description":"Request","required":true,"schema":{"$ref":"#/definitions/WebChatGuestMediaRequest"}}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatGuestMediaRequest"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The media request was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"patchWebchatGuestConversationMediarequest"}},"/api/v2/webchat/guest/conversations/{conversationId}/mediarequests":{"get":{"tags":["WebChat"],"summary":"Get all media requests to the guest in the conversation","description":"","operationId":"getWebchatGuestConversationMediarequests","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatGuestMediaRequestEntityList"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMediarequests"}},"/api/v2/webchat/guest/conversations/{conversationId}/members/{memberId}":{"get":{"tags":["WebChat"],"summary":"Get a web chat conversation member","description":"","operationId":"getWebchatGuestConversationMember","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMemberInfo"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The web chat conversation member was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation operation."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMember"},"delete":{"tags":["WebChat"],"summary":"Remove a member from a chat conversation","description":"","operationId":"deleteWebchatGuestConversationMember","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"}],"responses":{"204":{"description":"Operation was successful."},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","chat.error.member.state":"The conversation member is in a state which does not permit this action."}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation operation"}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"deleteWebchatGuestConversationMember"}},"/api/v2/webchat/guest/conversations/{conversationId}/members/{memberId}/messages":{"post":{"tags":["WebChat"],"summary":"Send a message in a chat conversation.","description":"","operationId":"postWebchatGuestConversationMemberMessages","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"},{"in":"body","name":"body","description":"Message","required":true,"schema":{"$ref":"#/definitions/CreateWebChatMessageRequest"}}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMessage"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.notnull.createconversationmessagerequest.body":"The request body may not be null.","bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","invalid.property":"Value [%s] is not a valid property for object [%s]","chat.error.member.state":"The conversation member is in a state which does not permit this action.","chat.error.bad.request":"Error occurred due to invalid request.","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation messages operation."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"postWebchatGuestConversationMemberMessages"}},"/api/v2/webchat/guest/conversations/{conversationId}/members/{memberId}/typing":{"post":{"tags":["WebChat"],"summary":"Send a typing-indicator in a chat conversation.","description":"","operationId":"postWebchatGuestConversationMemberTyping","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatTyping"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","invalid.property":"Value [%s] is not a valid property for object [%s]","chat.error.member.state":"The conversation member is in a state which does not permit this action.","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.internal":"Internal chat error","internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation typing operation."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"postWebchatGuestConversationMemberTyping"}},"/api/v2/webchat/guest/conversations/{conversationId}/members":{"get":{"tags":["WebChat"],"summary":"Get the members of a chat conversation.","description":"","operationId":"getWebchatGuestConversationMembers","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"pageSize","in":"query","description":"The number of entries to return per page, or omitted for the default.","required":false,"type":"integer","default":25,"format":"int32"},{"name":"pageNumber","in":"query","description":"The page number to return, or omitted for the first page.","required":false,"type":"integer","default":1,"format":"int32"},{"name":"excludeDisconnectedMembers","in":"query","description":"If true, the results will not contain members who have a DISCONNECTED state.","required":false,"type":"boolean","default":false}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMemberInfoEntityList"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMembers"}},"/api/v2/webchat/guest/conversations/{conversationId}/messages/{messageId}":{"get":{"tags":["WebChat"],"summary":"Get a web chat conversation message","description":"","operationId":"getWebchatGuestConversationMessage","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"messageId","in":"path","description":"messageId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMessage"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The web chat conversation message was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMessage"}},"/api/v2/webchat/guest/conversations/{conversationId}/messages":{"get":{"tags":["WebChat"],"summary":"Get the messages of a chat conversation.","description":"","operationId":"getWebchatGuestConversationMessages","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"after","in":"query","description":"If available, get the messages chronologically after the id of this message","required":false,"type":"string"},{"name":"before","in":"query","description":"If available, get the messages chronologically before the id of this message","required":false,"type":"string"},{"name":"sortOrder","in":"query","description":"Sort order","required":false,"type":"string","default":"ascending","enum":["ascending","descending"]},{"name":"maxResults","in":"query","description":"Limit the returned number of messages, up to a maximum of 100","required":false,"type":"integer","default":100,"format":"int32"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMessageEntityList"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMessages"}}},"securityDefinitions":{"PureCloud OAuth":{"type":"oauth2","authorizationUrl":"https://login.mypurecloud.com/authorize","flow":"implicit","scopes":{"all":"All the scopes"}},"Guest Chat JWT":{"type":"apiKey","name":"Authorization","in":"header"}},"definitions":{"CreateWebChatConversationRequest":{"type":"object","required":["deploymentId","memberInfo","organizationId","routingTarget"],"properties":{"organizationId":{"type":"string","description":"The organization identifier."},"deploymentId":{"type":"string","description":"The web chat Deployment ID which contains the appropriate settings for this chat conversation."},"routingTarget":{"description":"The routing information to use for the new chat conversation.","$ref":"#/definitions/WebChatRoutingTarget"},"memberInfo":{"description":"The guest member info to use for the new chat conversation.","$ref":"#/definitions/GuestMemberInfo"},"memberAuthToken":{"type":"string","description":"If the guest member is an authenticated member (ie, not anonymous) his JWT is provided here. The token will have been previously generated with the \"POST /api/v2/signeddata\" resource."},"journeyContext":{"description":"A subset of the Journey System's data relevant to this conversation/session request (for external linkage and internal usage/context).","$ref":"#/definitions/JourneyContext"}}},"WebChatRoutingTarget":{"type":"object","required":["targetAddress","targetType"],"properties":{"targetType":{"type":"string","description":"The target type of the routing target, such as 'QUEUE'.","enum":["QUEUE"]},"targetAddress":{"type":"string","description":"The target of the route, in the format appropriate given the 'targetType'."},"skills":{"type":"array","description":"The list of skill names to use for routing.","items":{"type":"string"}},"language":{"type":"string","description":"The language name to use for routing."},"priority":{"type":"integer","format":"int64","description":"The priority to assign to the conversation for routing."}}},"GuestMemberInfo":{"type":"object","required":["displayName"],"properties":{"displayName":{"type":"string","description":"The display name to use for the guest member in the conversation."},"firstName":{"type":"string","description":"The first name to use for the guest member in the conversation."},"lastName":{"type":"string","description":"The last name to use for the guest member in the conversation."},"email":{"type":"string","description":"The email address to use for the guest member in the conversation."},"phoneNumber":{"type":"string","description":"The phone number to use for the guest member in the conversation."},"avatarImageUrl":{"type":"string","format":"uri","description":"The URL to the avatar image to use for the guest member in the conversation, if any."},"customFields":{"type":"object","description":"Any custom fields of information, in key-value format, to attach to the guest member in the conversation.","additionalProperties":{"type":"string"}}}},"JourneyContext":{"type":"object","required":["customer"],"properties":{"customer":{"description":"A subset of the Journey System's customer data at a point-in-time (for external linkage and internal usage/context)","$ref":"#/definitions/JourneyCustomer"},"customerSession":{"description":"A subset of the Journey System's tracked customer session data at a point-in-time (for external linkage and internal usage/context)","$ref":"#/definitions/JourneyCustomerSession"},"triggeringAction":{"description":"A subset of the Journey System's action data relevant to a part of a conversation (for external linkage and internal usage/context)","$ref":"#/definitions/JourneyAction"}}},"JourneyCustomer":{"type":"object","required":["id","idType"],"properties":{"id":{"type":"string","description":"An ID of a customer within the Journey System at a point-in-time. Note that a customer entity can have multiple customerIds based on the stitching process. Depending on the context within the PureCloud conversation, this may or may not be mutable."},"idType":{"type":"string","description":"The type of the customerId within the Journey System (e.g. cookie)."}}},"JourneyCustomerSession":{"type":"object","required":["id","type"],"properties":{"id":{"type":"string","description":"An ID of a Customer/User's session within the Journey System at a point-in-time"},"type":{"type":"string","description":"The type of the Customer/User's session within the Journey System (e.g. web, app)"}}},"JourneyAction":{"type":"object","required":["actionMap","id"],"properties":{"id":{"type":"string","description":"The ID of an action from the Journey System (an action is spawned from an actionMap)"},"actionMap":{"description":"Details about the action map from the Journey System which triggered this action","$ref":"#/definitions/JourneyActionMap"}}},"JourneyActionMap":{"type":"object","required":["id","version"],"properties":{"id":{"type":"string","description":"The ID of the actionMap in the Journey System which triggered this action"},"version":{"type":"integer","format":"int32","description":"The version number of the actionMap in the Journey System at the time this action was triggered"}}},"CreateWebChatConversationResponse":{"type":"object","properties":{"id":{"type":"string","description":"Chat Conversation identifier"},"jwt":{"type":"string","description":"The JWT that you can use to identify subsequent calls on this conversation"},"eventStreamUri":{"type":"string","format":"uri","description":"The URI which provides the conversation event stream."},"member":{"description":"Chat Member","$ref":"#/definitions/WebChatMemberInfo"}}},"WebChatMemberInfo":{"type":"object","required":["role"],"properties":{"id":{"type":"string","description":"The communicationId of this member."},"displayName":{"type":"string","description":"The display name of the member."},"firstName":{"type":"string","description":"The first name of the member."},"lastName":{"type":"string","description":"The last name of the member."},"email":{"type":"string","description":"The email address of the member."},"phoneNumber":{"type":"string","description":"The phone number of the member."},"avatarImageUrl":{"type":"string","format":"uri","description":"The url to the avatar image of the member."},"role":{"type":"string","description":"The role of the member, one of [agent, customer, acd, workflow]","enum":["AGENT","CUSTOMER","WORKFLOW","ACD"]},"joinDate":{"type":"string","format":"date-time","description":"The time the member joined the conversation. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss[.mmm]Z"},"leaveDate":{"type":"string","format":"date-time","description":"The time the member left the conversation, or null if the member is still active in the conversation. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss[.mmm]Z"},"authenticatedGuest":{"type":"boolean","description":"If true, the guest member is an authenticated guest."},"customFields":{"type":"object","description":"Any custom fields of information pertaining to this member.","additionalProperties":{"type":"string"}},"state":{"type":"string","description":"The connection state of this member.","enum":["CONNECTED","DISCONNECTED","ALERTING"]}}},"ErrorBody":{"type":"object","properties":{"message":{"type":"string"},"code":{"type":"string"},"status":{"type":"integer","format":"int32"},"entityId":{"type":"string"},"entityName":{"type":"string"},"messageWithParams":{"type":"string"},"messageParams":{"type":"object","additionalProperties":{"type":"string"}},"contextId":{"type":"string"},"details":{"type":"array","items":{"$ref":"#/definitions/Detail"}},"errors":{"type":"array","items":{"$ref":"#/definitions/ErrorBody"}},"limit":{"$ref":"#/definitions/Limit"}}},"Detail":{"type":"object","properties":{"errorCode":{"type":"string"},"fieldName":{"type":"string"},"entityId":{"type":"string"},"entityName":{"type":"string"}}},"Limit":{"type":"object","properties":{"key":{"type":"string"},"namespace":{"type":"string","enum":["audit","auth.api","authorization","automation.testing","bots","bots.voice","callback","cobrowse","content.management","conversation","dataactions","datatables","directory","email","employee.engagement","event.orchestration","external.contacts","gcv","gdpr","groups","historical.adherence","infrastructureascode","integrations","intent.miner","journey","knowledge","language.understanding","learning","limit.registry","marketplace","media.communications","messaging","notifications","onboarding","outbound","platform.api","predictive.routing","presence","quality","recording","response.management","routing","scim","search","secondary.automation.testing","skills","speech.and.text.analytics","speech.integration","supportability","task.management","telephony.configuration","usage","users","web.deployments","web.messaging","webchat","webhooks","workforce.management","agent.assistant","analytics.alerting","analytics","analytics.realtime","analytics.reporting.settings","architect","audiohook"]},"value":{"type":"integer","format":"int64"}}},"WebChatGuestMediaRequest":{"type":"object","required":["state","types"],"properties":{"id":{"type":"string","description":"The globally unique identifier for the object.","readOnly":true},"name":{"type":"string"},"types":{"type":"array","description":"The types of media being requested.","items":{"type":"string","enum":["COBROWSE","SCREENSHARE"]}},"state":{"type":"string","description":"The state of the media request, one of PENDING|ACCEPTED|DECLINED|TIMEDOUT|CANCELLED|ERRORED.","enum":["PENDING","ACCEPTED","DECLINED","TIMEDOUT","CANCELLED","ERRORED"]},"communicationId":{"type":"string","description":"The ID of the new media communication, if applicable."},"securityKey":{"type":"string","description":"The security information related to a media request."},"selfUri":{"type":"string","format":"uri","description":"The URI for this object","readOnly":true}},"description":"Object representing the guest model of a media request of a chat conversation."},"WebChatGuestMediaRequestEntityList":{"type":"object","properties":{"entities":{"type":"array","items":{"$ref":"#/definitions/WebChatGuestMediaRequest"}}}},"CreateWebChatMessageRequest":{"type":"object","required":["body"],"properties":{"body":{"type":"string","description":"The message body. Note that message bodies are limited to 4,000 characters."},"bodyType":{"type":"string","description":"The purpose of the message within the conversation, such as a standard text entry versus a greeting.","enum":["standard","notice","member-join","member-leave","media-request"]}}},"WebChatMessage":{"type":"object","required":["body","bodyType","conversation","sender","timestamp"],"properties":{"id":{"type":"string","description":"The globally unique identifier for the object.","readOnly":true},"name":{"type":"string"},"conversation":{"description":"The identifier of the conversation","$ref":"#/definitions/WebChatConversation"},"sender":{"description":"The member who sent the message","$ref":"#/definitions/WebChatMemberInfo"},"body":{"type":"string","description":"The message body."},"bodyType":{"type":"string","description":"The purpose of the message within the conversation, such as a standard text entry versus a greeting.","enum":["standard","notice","member-join","member-leave","media-request"]},"timestamp":{"type":"string","format":"date-time","description":"The timestamp of the message, in ISO-8601 format"},"selfUri":{"type":"string","format":"uri","description":"The URI for this object","readOnly":true}}},"WebChatConversation":{"type":"object","properties":{"id":{"type":"string","description":"The globally unique identifier for the object.","readOnly":true},"name":{"type":"string"},"member":{"description":"Chat Member","$ref":"#/definitions/WebChatMemberInfo"},"selfUri":{"type":"string","format":"uri","description":"The URI for this object","readOnly":true}}},"WebChatTyping":{"type":"object","required":["conversation","id","sender","timestamp"],"properties":{"id":{"type":"string","description":"The event identifier of this typing indicator event (useful to guard against event re-delivery"},"conversation":{"description":"The identifier of the conversation","$ref":"#/definitions/WebChatConversation"},"sender":{"description":"The member who sent the message","$ref":"#/definitions/WebChatMemberInfo"},"timestamp":{"type":"string","format":"date-time","description":"The timestamp of the message, in ISO-8601 format"}}},"WebChatMemberInfoEntityList":{"type":"object","properties":{"entities":{"type":"array","items":{"$ref":"#/definitions/WebChatMemberInfo"}},"pageSize":{"type":"integer","format":"int32"},"pageNumber":{"type":"integer","format":"int32"},"total":{"type":"integer","format":"int64"},"firstUri":{"type":"string","format":"uri"},"nextUri":{"type":"string","format":"uri"},"previousUri":{"type":"string","format":"uri"},"lastUri":{"type":"string","format":"uri"},"selfUri":{"type":"string","format":"uri"},"pageCount":{"type":"integer","format":"int32"}}},"WebChatMessageEntityList":{"type":"object","properties":{"pageSize":{"type":"integer","format":"int32"},"entities":{"type":"array","items":{"$ref":"#/definitions/WebChatMessage"}},"previousPage":{"type":"string"},"next":{"type":"string"},"selfUri":{"type":"string","format":"uri"}}}},"responses":{"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"}}},"externalDocs":{"description":"PureCloud API Documentation","url":"https://developer.genesys.cloud"}}
\ No newline at end of file
+{"swagger":"2.0","info":{"description":"With the PureCloud Platform API, you can control all aspects of your PureCloud environment. With the APIs you can access the system configuration, manage conversations and more.","version":"v2","title":"PureCloud Platform API","termsOfService":"https://help.mypurecloud.com/articles/terms-and-conditions/","contact":{"name":"PureCloud Developer Evangelists","url":"https://developer.genesys.cloud","email":"DeveloperEvangelists@genesys.com"},"license":{"name":"UNLICENSED","url":"https://help.mypurecloud.com/articles/terms-and-conditions/"}},"host":"api.mypurecloud.com","tags":[{"name":"Events","description":"Events","externalDocs":{"description":"Events Documentation","url":"https://developer.genesys.cloud/api/rest/v2/events/"}},{"name":"Authorization","description":"Roles and permissions","externalDocs":{"description":"Authorization Documentation","url":"https://developer.mypurecloud.com/api/rest/v2/authorization/"}},{"name":"OAuth","description":"OAuth clients, providers","externalDocs":{"description":"OAuth Documentation","url":"https://developer.mypurecloud.com/api/rest/v2/oauth/"}},{"name":"Objects","description":"Access-controlled objects in the platform","externalDocs":{"description":"authorization docs","url":"https://developer.mypurecloud.com/api/rest/v2/authorization/"}},{"name":"Tokens","description":"Authentication Tokens","externalDocs":{"description":"Tokens Documentation","url":"https://developer.mypurecloud.com/api/rest/v2/tokens/"}},{"name":"Agent UI","description":"Agent UI settings and configuration"},{"name":"Alerting","description":"Rules and alerts","externalDocs":{"description":"Alerting Documentation","url":"https://developer.genesys.cloud/notificationsalerts/alerting/alerting-apis"}},{"name":"Analytics","description":"Analytics querying and reporting.","externalDocs":{"description":"Analytics Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/analytics/analytics-apis"}},{"name":"Architect","description":"Flows, Prompts, IVR schedules, Dependency Tracking","externalDocs":{"description":"Architect Documentation","url":"https://developer.genesys.cloud/routing/architect/"}},{"name":"Agent Assistants","description":"Manage virtual agent assistants."},{"name":"Audit","description":"","externalDocs":{"description":"Audit Documentation","url":"https://developer.genesys.cloud/platform/audit/"}},{"name":"Badges","description":"Badges stats"},{"name":"Billing","description":"","externalDocs":{"description":"billing Documentation","url":"https://developer.genesys.cloud/billing/"}},{"name":"Bots","description":"Chatbot Interactions"},{"name":"Bridge","description":""},{"name":"Callbacks","description":""},{"name":"Calls","description":""},{"name":"Carrier Services","description":""},{"name":"Chat","description":""},{"name":"Coaching","description":"Schedule and manage coaching appointments","externalDocs":{"description":"Coaching","url":"https://developer.genesys.cloud/routing/conversations/coaching-apis"}},{"name":"Cobrowse","description":""},{"name":"Compliance","description":""},{"name":"Configuration","description":"","externalDocs":{"description":"Configuration Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Content Management","description":"","externalDocs":{"description":"Content Management Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/contentmanagement/contentmanagement-apis"}},{"name":"Conversations","description":"","externalDocs":{"description":"Conversations Documentation","url":"https://developer.genesys.cloud/routing/conversations/conversations-apis"}},{"name":"Data Extensions","description":"Data extensions","externalDocs":{"description":"Data Extensions","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Data Privacy","description":"Data privacy masking rules","externalDocs":{"description":"Data Privacy","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Dialog Engine","description":"Dialog Engine","externalDocs":{"description":"Dialog Engine documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Directory Proxy","description":"Search, Suggest, and people"},{"name":"Docs","description":"Swagger documentation definitions"},{"name":"Downloads","description":"Download file","externalDocs":{"description":"Downloads Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Emails","description":""},{"name":"External Contacts","description":"External Organizations, contacts, notes and relationships","externalDocs":{"description":"External Contacts","url":"https://developer.genesys.cloud/commdigital/externalcontacts/externalcontacts-apis"}},{"name":"Fax","description":"","externalDocs":{"description":"Fax Documentation","url":"https://developer.genesys.cloud/commdigital/fax/"}},{"name":"Flows","description":"IVR Flows","externalDocs":{"description":"Flow Aggregates Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/analytics/aggregate/flow-query"}},{"name":"Gamification","description":"Gamification, Scorecard, and leaderboard","externalDocs":{"description":"Gamification Documentation","url":"https://developer.genesys.cloud/useragentman/gamification/"}},{"name":"General Data Protection Regulation","description":"Working with General Data Protection Regulation (GDPR) requests","externalDocs":{"description":"GDPR Documentation","url":"https://developer.genesys.cloud/gdprprivacy/"}},{"name":"Geolocation","description":"","externalDocs":{"description":"Geolocation Documentation","url":"https://developer.genesys.cloud/platform/geolocation-apis"}},{"name":"Greetings","description":"","externalDocs":{"description":"Greetings Documentation","url":"https://developer.genesys.cloud/commdigital/greetings/"}},{"name":"Groups","description":"Groups, members","externalDocs":{"description":"Groups Documentation","url":"https://developer.genesys.cloud/useragentman/groups/"}},{"name":"Identity Provider","description":"Identity providers","externalDocs":{"description":"Identity Providers Documentation","url":"https://developer.genesys.cloud/authorization/oauth-apis/identityprovider/"}},{"name":"Infrastructure as Code","description":"Accelerated infrastructure configuration via reusable modules","externalDocs":{"description":"Infrastructure as Code Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Integrations","description":"","externalDocs":{"description":"Integrations Documentation","url":"https://developer.genesys.cloud/platform/integrations/"}},{"name":"Journey","description":"Predictive Engagement, Customer Journey","externalDocs":{"description":"Journey documentation","url":"https://developer.genesys.cloud/commdigital/digital/webmessaging/journey/journey-apis"}},{"name":"Languages","description":"Available languages","externalDocs":{"description":"Languages Documentation","url":"https://developer.genesys.cloud/organization/languages-apis"}},{"name":"Knowledge","description":"Knowledge administration and search"},{"name":"Language Understanding","description":"Language Understanding","externalDocs":{"description":"Language Understanding documentation","url":"https://developer.genesys.cloud/organization/languageunderstanding/languageunderstanding-apis"}},{"name":"Learning","description":"Manage learning modules"},{"name":"Licensing","description":""},{"name":"License","description":"Per-user platform license assignments","externalDocs":{"description":"License Documentation","url":"https://developer.genesys.cloud/organization/license-apis"}},{"name":"Locations","description":"Physical locations","externalDocs":{"description":"Locations Documentation","url":"https://developer.genesys.cloud/telephony/locations-apis"}},{"name":"Marketplace","description":"Marketplace listing management"},{"name":"Data Action Metrics","description":"Metrics about data actions"},{"name":"Log Capture","description":"Browser Log Capture"},{"name":"Meeting","description":"","externalDocs":{"description":"Meeting Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Messaging","description":"Messaging","externalDocs":{"description":"Messaging Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Mobile Devices","description":"Devices","externalDocs":{"description":"Devices Documentation","url":"https://developer.genesys.cloud/organization/mobiledevices-apis"}},{"name":"Notifications","description":"Channels, subscriptions, topics, mobile push registration","externalDocs":{"description":"Notifications Documentation","url":"https://developer.genesys.cloud/notificationsalerts/notifications/notifications-apis"}},{"name":"Onboarding","description":"Onboarding"},{"name":"Operational Events","description":"Operational events"},{"name":"Organization","description":"Organization","externalDocs":{"description":"Organization Documentation","url":"https://developer.genesys.cloud/organization/organization/"}},{"name":"Organization Authorization","description":"Organization Authorization","externalDocs":{"description":"Organization Authorization Documentation","url":"https://developer.genesys.cloud/authorization/oauth-apis/organizationauthorization-apis"}},{"name":"Outbound","description":"","externalDocs":{"description":"Outbound Documentation","url":"https://developer.genesys.cloud/routing/outbound/"}},{"name":"Presence","description":"User and organization presences","externalDocs":{"description":"Presence Documentation","url":"https://developer.genesys.cloud/useragentman/presence/"}},{"name":"Process Automation","description":"Work items, flows, triggers"},{"name":"Quality","description":"Evaluations, calibrations","externalDocs":{"description":"Quality Management Documentation","url":"https://developer.genesys.cloud/useragentman/quality/"}},{"name":"Recording","description":"Recordings, policies, annotations, orphans","externalDocs":{"description":"Recording Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/recording/"}},{"name":"Response Management","description":"Responses, library, Response Assets, query","externalDocs":{"description":"Response Management Documentation","url":"https://developer.genesys.cloud/organization/responsemanagement-apis"}},{"name":"Routing","description":"Queues, wrapup codes, skills, email & sms config, predictive routing","externalDocs":{"description":"Routing Documentation","url":"https://developer.genesys.cloud/routing/routing/"}},{"name":"SCIM","description":"System for Cross-domain Identity Management","externalDocs":{"description":"System for Cross-domain Identity Management: Definitions, Overview, Concepts, and Requirements","url":"https://developer.genesys.cloud/useragentman/scim/scim-apis"}},{"name":"Screen Recording","description":"Screen recording with background assistant"},{"name":"Scripts","description":"Agent-facing scripts for interactions","externalDocs":{"description":"Scripts Documentation","url":"https://developer.genesys.cloud/routing/scripts/"}},{"name":"Search","description":"Search aggregate, users, groups","externalDocs":{"description":"Search Documentation","url":"https://developer.genesys.cloud/organization/search/"}},{"name":"Settings","description":"Persist settings"},{"name":"SignedData","description":"Package data in signed JWTs"},{"name":"Socialize","description":"Gets, sets and updates entity data for the Socialize service"},{"name":"Speech & Text Analytics","description":""},{"name":"Stations","description":"Stations","externalDocs":{"description":"Stations Documentation","url":"https://developer.genesys.cloud/telephony/stations-apis"}},{"name":"Suggest","description":"Search suggest user, group, locations"},{"name":"Teams","description":"Teams, members","externalDocs":{"description":"Teams Documentation","url":"https://developer.genesys.cloud/devapps/api-explorer"}},{"name":"Telephony","description":"Telephony providers and configuration","externalDocs":{"description":"Telephony Documentation","url":"https://developer.genesys.cloud/telephony/telephony-apis"}},{"name":"Telephony Providers Edge","description":"Edge phones, trunks, lines.","externalDocs":{"description":"telephony provider edge","url":"https://developer.genesys.cloud/telephony/telephony-apis"}},{"name":"Test Automation","description":"Internal Testing Tool for managing Testing Data"},{"name":"Textbots","description":"Chatbot Interactions"},{"name":"Uploads","description":"Presigned url generator for uploading files","externalDocs":{"description":"Upload Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/uploads/uploads-apis"}},{"name":"User Recordings","description":"Summary, media","externalDocs":{"description":"User Recordings Documentation","url":"https://developer.genesys.cloud/analyticsdatamanagement/recording/userrecordings-apis"}},{"name":"Users","description":"Me, routing, roles","externalDocs":{"description":"Users Documentation","url":"https://developer.genesys.cloud/useragentman/users/"}},{"name":"Utilities","description":"","externalDocs":{"description":"Utilities Documentation","url":"https://developer.genesys.cloud/organization/utilities-apis"}},{"name":"Videos","description":""},{"name":"Voicemail","description":"Mailbox, messages, policy","externalDocs":{"description":"Voicemail Documentation","url":"https://developer.genesys.cloud/commdigital/voicemail/"}},{"name":"WebChat","description":"WebChat deployments","externalDocs":{"description":"WebChat Deployment Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webchat/webchat-apis"}},{"name":"WebMessaging","description":"Web messaging","externalDocs":{"description":"Web Messaging Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webmessaging/webmessaging-apis"}},{"name":"Widgets","description":"Widget deployments","externalDocs":{"description":"Widget Deployment Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webchat/widgets-apis"}},{"name":"Usage","description":"View organizational level usage data","externalDocs":{"description":"Usage Documentation","url":"https://developer.genesys.cloud/platform/usage-apis"}},{"name":"Workforce Management","description":"Adherence, Schedules, Forecasts, Intraday Monitoring, Time Off Requests, Configuration","externalDocs":{"description":"Workforce Management Documentation","url":"https://developer.genesys.cloud/useragentman/workforcemanagement/"}},{"name":"Voicebots","description":"Voicebot Interactions"},{"name":"Web Deployments","description":"Web Deployments","externalDocs":{"description":"Web Deployments Documentation","url":"https://developer.genesys.cloud/commdigital/digital/webchat/webdeployments-apis"}},{"name":"Task Management","description":"Task Management"}],"schemes":["https"],"consumes":["application/json"],"produces":["application/json"],"paths":{"/api/v2/webchat/guest/conversations":{"post":{"tags":["WebChat"],"summary":"Create an ACD chat conversation from an external customer.","description":"This endpoint will create a new ACD Chat conversation under the specified Chat Deployment.\n The conversation will begin with a guest member in it (with a role=CUSTOMER) according to the customer information that is supplied. If the guest member is authenticated, the 'memberAuthToken' field should include his JWT as generated by the 'POST /api/v2/signeddata' resource; if the guest member is anonymous (and the Deployment permits it) this field can be omitted.\n The returned data includes the IDs of the conversation created, along with a newly-create JWT token that you can supply to all future endpoints as authentication to perform operations against that conversation. After successfully creating a conversation, you should connect a websocket to the event stream named in the 'eventStreamUri' field of the response; the conversation is not routed until the event stream is attached.","operationId":"postWebchatGuestConversations","produces":["application/json"],"parameters":[{"in":"body","name":"body","description":"CreateConversationRequest","required":true,"schema":{"$ref":"#/definitions/CreateWebChatConversationRequest"}}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/CreateWebChatConversationResponse"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.notnull.createconversationrequest.journeycontext.customer":"The customer may not be null.","chat.error.notnull.createconversationrequest.journeycontext.triggeringaction.actionmapversion":"The actionmapversion property may not be null.","chat.error.invalid.queue":"The specified queue is not valid.","chat.error.notnull.createconversationrequest.journeycontext.triggeringaction.actionid":"The actionid property may not be null.","bad.request":"The request could not be understood by the server due to malformed syntax.","chat.error.notnull.createconversationrequest.journeycontext.customer.customerid":"The customerid property may not be null.","constraint.validation":"%s","chat.error.notnull.createconversationrequest.memberinfo.displayname":"The displayname property may not be null.","chat.error.notnull.createconversationrequest.routingtarget":"The routingtarget property may not be null.","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","chat.error.notnull.createconversationrequest.journeycontext.customer.customeridtype":"The customeridtype property may not be null.","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s","chat.deployment.require.auth":"The deployment requires the customer member to be authenticated.","chat.error.notnull.createconversationrequest.journeycontext.customersession.sessionid":"The sessionid property may not be null.","chat.error.notnull.createconversationrequest.journeycontext.customersession.sessionidtype":"The sessionidtype property may not be null.","chat.deployment.bad.auth":"The customer member authentication has failed.","chat.error.notnull.createconversationrequest.journeycontext.triggeringaction.actionmapid":"The actionmapid property may not be null.","chat.error.createconversationrequest.routingtarget":"The routing target is not valid.","invalid.property":"Value [%s] is not a valid property for object [%s]","chat.deployment.disabled":"The web chat deployment is currently disabled.","chat.error.pattern.createconversationrequest.deploymentid":"The deploymentid property may not be null.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.invalid.flow":"Invalid chat flow","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","chat.error.bad.request":"Error occurred due to invalid request."}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"origin.not.allowed":"Not allowed to create an ACD chat conversation from an external customer.","missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"caht.error":"Error performing chat conversation operation.","internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.service.timeout":"Chat service timeout error.","authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"x-purecloud-method-name":"postWebchatGuestConversations"}},"/api/v2/webchat/guest/conversations/{conversationId}/mediarequests/{mediaRequestId}":{"get":{"tags":["WebChat"],"summary":"Get a media request in the conversation","description":"","operationId":"getWebchatGuestConversationMediarequest","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"mediaRequestId","in":"path","description":"mediaRequestId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatGuestMediaRequest"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The media request was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMediarequest"},"patch":{"tags":["WebChat"],"summary":"Update a media request in the conversation, setting the state to ACCEPTED/DECLINED/ERRORED","description":"","operationId":"patchWebchatGuestConversationMediarequest","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"mediaRequestId","in":"path","description":"mediaRequestId","required":true,"type":"string"},{"in":"body","name":"body","description":"Request","required":true,"schema":{"$ref":"#/definitions/WebChatGuestMediaRequest"}}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatGuestMediaRequest"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The media request was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"patchWebchatGuestConversationMediarequest"}},"/api/v2/webchat/guest/conversations/{conversationId}/mediarequests":{"get":{"tags":["WebChat"],"summary":"Get all media requests to the guest in the conversation","description":"","operationId":"getWebchatGuestConversationMediarequests","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatGuestMediaRequestEntityList"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMediarequests"}},"/api/v2/webchat/guest/conversations/{conversationId}/members/{memberId}":{"get":{"tags":["WebChat"],"summary":"Get a web chat conversation member","description":"","operationId":"getWebchatGuestConversationMember","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMemberInfo"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The web chat conversation member was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation operation."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMember"},"delete":{"tags":["WebChat"],"summary":"Remove a member from a chat conversation","description":"","operationId":"deleteWebchatGuestConversationMember","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"}],"responses":{"204":{"description":"Operation was successful."},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","chat.error.member.state":"The conversation member is in a state which does not permit this action."}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation operation"}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"deleteWebchatGuestConversationMember"}},"/api/v2/webchat/guest/conversations/{conversationId}/members/{memberId}/messages":{"post":{"tags":["WebChat"],"summary":"Send a message in a chat conversation.","description":"","operationId":"postWebchatGuestConversationMemberMessages","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"},{"in":"body","name":"body","description":"Message","required":true,"schema":{"$ref":"#/definitions/CreateWebChatMessageRequest"}}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMessage"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.notnull.createconversationmessagerequest.body":"The request body may not be null.","bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","invalid.property":"Value [%s] is not a valid property for object [%s]","chat.error.member.state":"The conversation member is in a state which does not permit this action.","chat.error.bad.request":"Error occurred due to invalid request.","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation messages operation."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"postWebchatGuestConversationMemberMessages"}},"/api/v2/webchat/guest/conversations/{conversationId}/members/{memberId}/typing":{"post":{"tags":["WebChat"],"summary":"Send a typing-indicator in a chat conversation.","description":"","operationId":"postWebchatGuestConversationMemberTyping","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"memberId","in":"path","description":"memberId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatTyping"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","chat.error.conversation.state":"The conversation is in a state which does not permit this action.","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","client.failed.request":"The client did not produce a request with valid end of stream signaling. This can be caused by poor network connection and/or client behavior.","invalid.property":"Value [%s] is not a valid property for object [%s]","chat.error.member.state":"The conversation member is in a state which does not permit this action.","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"credentials.expired":"The supplied credentials are expired and cannot be used.","authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.internal":"Internal chat error","internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request.","chat.error":"Error handing chat conversation typing operation."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"postWebchatGuestConversationMemberTyping"}},"/api/v2/webchat/guest/conversations/{conversationId}/members":{"get":{"tags":["WebChat"],"summary":"Get the members of a chat conversation.","description":"","operationId":"getWebchatGuestConversationMembers","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"pageSize","in":"query","description":"The number of entries to return per page, or omitted for the default.","required":false,"type":"integer","default":25,"format":"int32"},{"name":"pageNumber","in":"query","description":"The page number to return, or omitted for the first page.","required":false,"type":"integer","default":1,"format":"int32"},{"name":"excludeDisconnectedMembers","in":"query","description":"If true, the results will not contain members who have a DISCONNECTED state.","required":false,"type":"boolean","default":false}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMemberInfoEntityList"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMembers"}},"/api/v2/webchat/guest/conversations/{conversationId}/messages/{messageId}":{"get":{"tags":["WebChat"],"summary":"Get a web chat conversation message","description":"","operationId":"getWebchatGuestConversationMessage","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"messageId","in":"path","description":"messageId","required":true,"type":"string"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMessage"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"chat.error.not.found":"The web chat conversation message was not found.","not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMessage"}},"/api/v2/webchat/guest/conversations/{conversationId}/messages":{"get":{"tags":["WebChat"],"summary":"Get the messages of a chat conversation.","description":"","operationId":"getWebchatGuestConversationMessages","produces":["application/json"],"parameters":[{"name":"conversationId","in":"path","description":"conversationId","required":true,"type":"string"},{"name":"after","in":"query","description":"If available, get the messages chronologically after the id of this message","required":false,"type":"string"},{"name":"before","in":"query","description":"If available, get the messages chronologically before the id of this message","required":false,"type":"string"},{"name":"sortOrder","in":"query","description":"Sort order","required":false,"type":"string","default":"ascending","enum":["ascending","descending"]},{"name":"maxResults","in":"query","description":"Limit the returned number of messages, up to a maximum of 100","required":false,"type":"integer","default":100,"format":"int32"}],"responses":{"200":{"description":"successful operation","schema":{"$ref":"#/definitions/WebChatMessageEntityList"}},"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"bad.request":"The request could not be understood by the server due to malformed syntax.","response.entity.too.large":"The response is over the size limit. Reduce pageSize or expand list to reduce response size if applicable","invalid.date":"Dates must be specified as ISO-8601 strings. For example: yyyy-MM-ddTHH:mm:ss.SSSZ","invalid.query.param.value":"Value [%s] is not valid for parameter [%s]. Allowable values are: %s","invalid.property":"Value [%s] is not a valid property for object [%s]","constraint.validation":"%s","invalid.value":"Value [%s] is not valid for field type [%s]. Allowable values are: %s"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.required":"No authentication bearer token specified in authorization header.","ip.not.authorized":"Requests originating from this IP address are not authorized: [%s]","bad.credentials":"Invalid login credentials."}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"missing.division.permission":"Unable to perform the requested action. You are missing the following permission '%s' in the provided division(s).","app.not.authorized.for.scope":"App not authorized to use scope %s","missing.permissions":"Unable to perform the requested action. You are missing the following permission(s): %s","not.authorized":"You are not authorized to perform the requested action.","missing.any.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s","authz.policy.denied":"Unable to perform the requested action. Your organization's security policies have denied access. Policy ID(s): [%s]","missing.any.division.permissions":"Unable to perform the requested action. You must have at least one of the following permissions assigned: %s in at least one of the following division(s): %s"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"not.found":"The requested resource was not found."}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"client.timeout":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads."}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"request.entity.too.large":"The request is over the size limit. Maximum bytes: %s"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"unsupported.media.type":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header."}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"too.many.requests.retry.after":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","too.many.requests":"Rate limit exceeded the maximum [%s] requests within [%s] seconds"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"internal.server.error":"The server encountered an unexpected condition which prevented it from fulfilling the request."}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"service.unavailable":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance)."}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"},"x-inin-error-codes":{"authentication.request.timeout":"Authentication request timeout.","request.timeout":"The request timed out."}}},"security":[{"Guest Chat JWT":[]}],"x-purecloud-method-name":"getWebchatGuestConversationMessages"}}},"securityDefinitions":{"PureCloud OAuth":{"type":"oauth2","authorizationUrl":"https://login.mypurecloud.com/authorize","flow":"implicit","scopes":{"all":"All the scopes"}},"Guest Chat JWT":{"type":"apiKey","name":"Authorization","in":"header"}},"definitions":{"CreateWebChatConversationRequest":{"type":"object","required":["deploymentId","memberInfo","organizationId","routingTarget"],"properties":{"organizationId":{"type":"string","description":"The organization identifier."},"deploymentId":{"type":"string","description":"The web chat Deployment ID which contains the appropriate settings for this chat conversation."},"routingTarget":{"description":"The routing information to use for the new chat conversation.","$ref":"#/definitions/WebChatRoutingTarget"},"memberInfo":{"description":"The guest member info to use for the new chat conversation.","$ref":"#/definitions/GuestMemberInfo"},"memberAuthToken":{"type":"string","description":"If the guest member is an authenticated member (ie, not anonymous) his JWT is provided here. The token will have been previously generated with the \"POST /api/v2/signeddata\" resource."},"journeyContext":{"description":"A subset of the Journey System's data relevant to this conversation/session request (for external linkage and internal usage/context).","$ref":"#/definitions/JourneyContext"}}},"WebChatRoutingTarget":{"type":"object","required":["targetAddress","targetType"],"properties":{"targetType":{"type":"string","description":"The target type of the routing target, such as 'QUEUE'.","enum":["QUEUE"]},"targetAddress":{"type":"string","description":"The target of the route, in the format appropriate given the 'targetType'."},"skills":{"type":"array","description":"The list of skill names to use for routing.","items":{"type":"string"}},"language":{"type":"string","description":"The language name to use for routing."},"priority":{"type":"integer","format":"int64","description":"The priority to assign to the conversation for routing."}}},"GuestMemberInfo":{"type":"object","required":["displayName"],"properties":{"displayName":{"type":"string","description":"The display name to use for the guest member in the conversation."},"firstName":{"type":"string","description":"The first name to use for the guest member in the conversation."},"lastName":{"type":"string","description":"The last name to use for the guest member in the conversation."},"email":{"type":"string","description":"The email address to use for the guest member in the conversation."},"phoneNumber":{"type":"string","description":"The phone number to use for the guest member in the conversation."},"avatarImageUrl":{"type":"string","format":"uri","description":"The URL to the avatar image to use for the guest member in the conversation, if any."},"customFields":{"type":"object","description":"Any custom fields of information, in key-value format, to attach to the guest member in the conversation.","additionalProperties":{"type":"string"}}}},"JourneyContext":{"type":"object","required":["customer"],"properties":{"customer":{"description":"A subset of the Journey System's customer data at a point-in-time (for external linkage and internal usage/context)","$ref":"#/definitions/JourneyCustomer"},"customerSession":{"description":"A subset of the Journey System's tracked customer session data at a point-in-time (for external linkage and internal usage/context)","$ref":"#/definitions/JourneyCustomerSession"},"triggeringAction":{"description":"A subset of the Journey System's action data relevant to a part of a conversation (for external linkage and internal usage/context)","$ref":"#/definitions/JourneyAction"}}},"JourneyCustomer":{"type":"object","required":["id","idType"],"properties":{"id":{"type":"string","description":"An ID of a customer within the Journey System at a point-in-time. Note that a customer entity can have multiple customerIds based on the stitching process. Depending on the context within the PureCloud conversation, this may or may not be mutable."},"idType":{"type":"string","description":"The type of the customerId within the Journey System (e.g. cookie)."}}},"JourneyCustomerSession":{"type":"object","required":["id","type"],"properties":{"id":{"type":"string","description":"An ID of a Customer/User's session within the Journey System at a point-in-time"},"type":{"type":"string","description":"The type of the Customer/User's session within the Journey System (e.g. web, app)"}}},"JourneyAction":{"type":"object","required":["actionMap","id"],"properties":{"id":{"type":"string","description":"The ID of an action from the Journey System (an action is spawned from an actionMap)"},"actionMap":{"description":"Details about the action map from the Journey System which triggered this action","$ref":"#/definitions/JourneyActionMap"}}},"JourneyActionMap":{"type":"object","required":["id","version"],"properties":{"id":{"type":"string","description":"The ID of the actionMap in the Journey System which triggered this action"},"version":{"type":"integer","format":"int32","description":"The version number of the actionMap in the Journey System at the time this action was triggered"}}},"CreateWebChatConversationResponse":{"type":"object","properties":{"id":{"type":"string","description":"Chat Conversation identifier"},"jwt":{"type":"string","description":"The JWT that you can use to identify subsequent calls on this conversation"},"eventStreamUri":{"type":"string","format":"uri","description":"The URI which provides the conversation event stream."},"member":{"description":"Chat Member","$ref":"#/definitions/WebChatMemberInfo"}}},"WebChatMemberInfo":{"type":"object","required":["role"],"properties":{"id":{"type":"string","description":"The communicationId of this member."},"displayName":{"type":"string","description":"The display name of the member."},"firstName":{"type":"string","description":"The first name of the member."},"lastName":{"type":"string","description":"The last name of the member."},"email":{"type":"string","description":"The email address of the member."},"phoneNumber":{"type":"string","description":"The phone number of the member."},"avatarImageUrl":{"type":"string","format":"uri","description":"The url to the avatar image of the member."},"role":{"type":"string","description":"The role of the member, one of [agent, customer, acd, workflow]","enum":["AGENT","CUSTOMER","WORKFLOW","ACD"]},"joinDate":{"type":"string","format":"date-time","description":"The time the member joined the conversation. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss[.mmm]Z"},"leaveDate":{"type":"string","format":"date-time","description":"The time the member left the conversation, or null if the member is still active in the conversation. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss[.mmm]Z"},"authenticatedGuest":{"type":"boolean","description":"If true, the guest member is an authenticated guest."},"customFields":{"type":"object","description":"Any custom fields of information pertaining to this member.","additionalProperties":{"type":"string"}},"state":{"type":"string","description":"The connection state of this member.","enum":["CONNECTED","DISCONNECTED","ALERTING"]}}},"ErrorBody":{"type":"object","properties":{"message":{"type":"string"},"code":{"type":"string"},"status":{"type":"integer","format":"int32"},"entityId":{"type":"string"},"entityName":{"type":"string"},"messageWithParams":{"type":"string"},"messageParams":{"type":"object","additionalProperties":{"type":"string"}},"contextId":{"type":"string"},"details":{"type":"array","items":{"$ref":"#/definitions/Detail"}},"errors":{"type":"array","items":{"$ref":"#/definitions/ErrorBody"}},"limit":{"$ref":"#/definitions/Limit"}}},"Detail":{"type":"object","properties":{"errorCode":{"type":"string"},"fieldName":{"type":"string"},"entityId":{"type":"string"},"entityName":{"type":"string"}}},"Limit":{"type":"object","properties":{"key":{"type":"string"},"namespace":{"type":"string","enum":["agent.assistant","analytics.alerting","analytics","analytics.realtime","analytics.reporting.settings","architect","audiohook","audit","auth.api","authorization","automation.testing","bots","bots.voice","callback","cobrowse","content.management","conversation","dataactions","datatables","directory","email","employee.engagement","event.orchestration","external.contacts","gcv","gdpr","groups","historical.adherence","infrastructureascode","integrations","intent.miner","journey","knowledge","language.understanding","learning","limit.registry","marketplace","media.communications","messaging","notifications","onboarding","outbound","platform.api","predictive.routing","presence","quality","recording","response.management","routing","scim","search","secondary.automation.testing","skills","speech.and.text.analytics","speech.integration","supportability","task.management","telephony.configuration","usage","users","web.deployments","web.messaging","webchat","webhooks","workforce.management"]},"value":{"type":"integer","format":"int64"}}},"WebChatGuestMediaRequest":{"type":"object","required":["state","types"],"properties":{"id":{"type":"string","description":"The globally unique identifier for the object.","readOnly":true},"name":{"type":"string"},"types":{"type":"array","description":"The types of media being requested.","items":{"type":"string","enum":["COBROWSE","SCREENSHARE"]}},"state":{"type":"string","description":"The state of the media request, one of PENDING|ACCEPTED|DECLINED|TIMEDOUT|CANCELLED|ERRORED.","enum":["PENDING","ACCEPTED","DECLINED","TIMEDOUT","CANCELLED","ERRORED"]},"communicationId":{"type":"string","description":"The ID of the new media communication, if applicable."},"securityKey":{"type":"string","description":"The security information related to a media request."},"selfUri":{"type":"string","format":"uri","description":"The URI for this object","readOnly":true}},"description":"Object representing the guest model of a media request of a chat conversation."},"WebChatGuestMediaRequestEntityList":{"type":"object","properties":{"entities":{"type":"array","items":{"$ref":"#/definitions/WebChatGuestMediaRequest"}}}},"CreateWebChatMessageRequest":{"type":"object","required":["body"],"properties":{"body":{"type":"string","description":"The message body. Note that message bodies are limited to 4,000 characters."},"bodyType":{"type":"string","description":"The purpose of the message within the conversation, such as a standard text entry versus a greeting.","enum":["standard","notice","member-join","member-leave","media-request"]}}},"WebChatMessage":{"type":"object","required":["body","bodyType","conversation","sender","timestamp"],"properties":{"id":{"type":"string","description":"The globally unique identifier for the object.","readOnly":true},"name":{"type":"string"},"conversation":{"description":"The identifier of the conversation","$ref":"#/definitions/WebChatConversation"},"sender":{"description":"The member who sent the message","$ref":"#/definitions/WebChatMemberInfo"},"body":{"type":"string","description":"The message body."},"bodyType":{"type":"string","description":"The purpose of the message within the conversation, such as a standard text entry versus a greeting.","enum":["standard","notice","member-join","member-leave","media-request"]},"timestamp":{"type":"string","format":"date-time","description":"The timestamp of the message, in ISO-8601 format"},"selfUri":{"type":"string","format":"uri","description":"The URI for this object","readOnly":true}}},"WebChatConversation":{"type":"object","properties":{"id":{"type":"string","description":"The globally unique identifier for the object.","readOnly":true},"name":{"type":"string"},"member":{"description":"Chat Member","$ref":"#/definitions/WebChatMemberInfo"},"selfUri":{"type":"string","format":"uri","description":"The URI for this object","readOnly":true}}},"WebChatTyping":{"type":"object","required":["conversation","id","sender","timestamp"],"properties":{"id":{"type":"string","description":"The event identifier of this typing indicator event (useful to guard against event re-delivery"},"conversation":{"description":"The identifier of the conversation","$ref":"#/definitions/WebChatConversation"},"sender":{"description":"The member who sent the message","$ref":"#/definitions/WebChatMemberInfo"},"timestamp":{"type":"string","format":"date-time","description":"The timestamp of the message, in ISO-8601 format"}}},"WebChatMemberInfoEntityList":{"type":"object","properties":{"entities":{"type":"array","items":{"$ref":"#/definitions/WebChatMemberInfo"}},"pageSize":{"type":"integer","format":"int32"},"pageNumber":{"type":"integer","format":"int32"},"total":{"type":"integer","format":"int64"},"firstUri":{"type":"string","format":"uri"},"nextUri":{"type":"string","format":"uri"},"previousUri":{"type":"string","format":"uri"},"lastUri":{"type":"string","format":"uri"},"selfUri":{"type":"string","format":"uri"},"pageCount":{"type":"integer","format":"int32"}}},"WebChatMessageEntityList":{"type":"object","properties":{"pageSize":{"type":"integer","format":"int32"},"entities":{"type":"array","items":{"$ref":"#/definitions/WebChatMessage"}},"previousPage":{"type":"string"},"next":{"type":"string"},"selfUri":{"type":"string","format":"uri"}}}},"responses":{"400":{"description":"The request could not be understood by the server due to malformed syntax.","schema":{"$ref":"#/definitions/ErrorBody"}},"401":{"description":"No authentication bearer token specified in authorization header.","schema":{"$ref":"#/definitions/ErrorBody"}},"403":{"description":"You are not authorized to perform the requested action.","schema":{"$ref":"#/definitions/ErrorBody"}},"404":{"description":"The requested resource was not found.","schema":{"$ref":"#/definitions/ErrorBody"}},"408":{"description":"The client did not produce a request within the server timeout limit. This can be caused by a slow network connection and/or large payloads.","schema":{"$ref":"#/definitions/ErrorBody"}},"413":{"description":"The request is over the size limit. Maximum bytes: %s","schema":{"$ref":"#/definitions/ErrorBody"}},"415":{"description":"Unsupported Media Type - Unsupported or incorrect media type, such as an incorrect Content-Type value in the header.","schema":{"$ref":"#/definitions/ErrorBody"}},"429":{"description":"Rate limit exceeded the maximum. Retry the request in [%s] seconds","schema":{"$ref":"#/definitions/ErrorBody"}},"500":{"description":"The server encountered an unexpected condition which prevented it from fulfilling the request.","schema":{"$ref":"#/definitions/ErrorBody"}},"503":{"description":"Service Unavailable - The server is currently unavailable (because it is overloaded or down for maintenance).","schema":{"$ref":"#/definitions/ErrorBody"}},"504":{"description":"The request timed out.","schema":{"$ref":"#/definitions/ErrorBody"}}},"externalDocs":{"description":"PureCloud API Documentation","url":"https://developer.genesys.cloud"}}
\ No newline at end of file
diff --git a/version.json b/version.json
index 1a714ea5..e3309097 100644
--- a/version.json
+++ b/version.json
@@ -1,9 +1,9 @@
{
"major": 13,
"minor": 8,
- "point": 0,
+ "point": 1,
"prerelease": "",
"apiVersion": 0,
- "display": "13.8.0",
- "displayFull": "13.8.0"
+ "display": "13.8.1",
+ "displayFull": "13.8.1"
}
\ No newline at end of file