@timeback/oneroster 0.1.5 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client.d.ts +12 -6
- package/dist/client.d.ts.map +1 -1
- package/dist/client.type-test.d.ts +2 -0
- package/dist/client.type-test.d.ts.map +1 -0
- package/dist/errors.js +433 -39
- package/dist/factory.d.ts +4 -2
- package/dist/factory.d.ts.map +1 -1
- package/dist/index.d.ts +4 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +539 -141
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -1,20 +1,4 @@
|
|
|
1
|
-
import { createRequire } from "node:module";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
4
1
|
var __defProp = Object.defineProperty;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
-
var __toESM = (mod, isNodeMode, target) => {
|
|
8
|
-
target = mod != null ? __create(__getProtoOf(mod)) : {};
|
|
9
|
-
const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
10
|
-
for (let key of __getOwnPropNames(mod))
|
|
11
|
-
if (!__hasOwnProp.call(to, key))
|
|
12
|
-
__defProp(to, key, {
|
|
13
|
-
get: () => mod[key],
|
|
14
|
-
enumerable: true
|
|
15
|
-
});
|
|
16
|
-
return to;
|
|
17
|
-
};
|
|
18
2
|
var __export = (target, all) => {
|
|
19
3
|
for (var name in all)
|
|
20
4
|
__defProp(target, name, {
|
|
@@ -24,7 +8,417 @@ var __export = (target, all) => {
|
|
|
24
8
|
set: (newValue) => all[name] = () => newValue
|
|
25
9
|
});
|
|
26
10
|
};
|
|
27
|
-
var
|
|
11
|
+
var __esm = (fn, res) => () => (fn && (res = fn(fn = 0)), res);
|
|
12
|
+
|
|
13
|
+
// node:util
|
|
14
|
+
var exports_util = {};
|
|
15
|
+
__export(exports_util, {
|
|
16
|
+
types: () => types,
|
|
17
|
+
promisify: () => promisify,
|
|
18
|
+
log: () => log,
|
|
19
|
+
isUndefined: () => isUndefined,
|
|
20
|
+
isSymbol: () => isSymbol,
|
|
21
|
+
isString: () => isString,
|
|
22
|
+
isRegExp: () => isRegExp,
|
|
23
|
+
isPrimitive: () => isPrimitive,
|
|
24
|
+
isObject: () => isObject,
|
|
25
|
+
isNumber: () => isNumber,
|
|
26
|
+
isNullOrUndefined: () => isNullOrUndefined,
|
|
27
|
+
isNull: () => isNull,
|
|
28
|
+
isFunction: () => isFunction,
|
|
29
|
+
isError: () => isError,
|
|
30
|
+
isDate: () => isDate,
|
|
31
|
+
isBuffer: () => isBuffer,
|
|
32
|
+
isBoolean: () => isBoolean,
|
|
33
|
+
isArray: () => isArray,
|
|
34
|
+
inspect: () => inspect,
|
|
35
|
+
inherits: () => inherits,
|
|
36
|
+
format: () => format,
|
|
37
|
+
deprecate: () => deprecate,
|
|
38
|
+
default: () => util_default,
|
|
39
|
+
debuglog: () => debuglog,
|
|
40
|
+
callbackifyOnRejected: () => callbackifyOnRejected,
|
|
41
|
+
callbackify: () => callbackify,
|
|
42
|
+
_extend: () => _extend,
|
|
43
|
+
TextEncoder: () => TextEncoder,
|
|
44
|
+
TextDecoder: () => TextDecoder
|
|
45
|
+
});
|
|
46
|
+
function format(f, ...args) {
|
|
47
|
+
if (!isString(f)) {
|
|
48
|
+
var objects = [f];
|
|
49
|
+
for (var i = 0;i < args.length; i++)
|
|
50
|
+
objects.push(inspect(args[i]));
|
|
51
|
+
return objects.join(" ");
|
|
52
|
+
}
|
|
53
|
+
var i = 0, len = args.length, str = String(f).replace(formatRegExp, function(x2) {
|
|
54
|
+
if (x2 === "%%")
|
|
55
|
+
return "%";
|
|
56
|
+
if (i >= len)
|
|
57
|
+
return x2;
|
|
58
|
+
switch (x2) {
|
|
59
|
+
case "%s":
|
|
60
|
+
return String(args[i++]);
|
|
61
|
+
case "%d":
|
|
62
|
+
return Number(args[i++]);
|
|
63
|
+
case "%j":
|
|
64
|
+
try {
|
|
65
|
+
return JSON.stringify(args[i++]);
|
|
66
|
+
} catch (_) {
|
|
67
|
+
return "[Circular]";
|
|
68
|
+
}
|
|
69
|
+
default:
|
|
70
|
+
return x2;
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
for (var x = args[i];i < len; x = args[++i])
|
|
74
|
+
if (isNull(x) || !isObject(x))
|
|
75
|
+
str += " " + x;
|
|
76
|
+
else
|
|
77
|
+
str += " " + inspect(x);
|
|
78
|
+
return str;
|
|
79
|
+
}
|
|
80
|
+
function deprecate(fn, msg) {
|
|
81
|
+
if (typeof process > "u" || process?.noDeprecation === true)
|
|
82
|
+
return fn;
|
|
83
|
+
var warned = false;
|
|
84
|
+
function deprecated(...args) {
|
|
85
|
+
if (!warned) {
|
|
86
|
+
if (process.throwDeprecation)
|
|
87
|
+
throw Error(msg);
|
|
88
|
+
else if (process.traceDeprecation)
|
|
89
|
+
console.trace(msg);
|
|
90
|
+
else
|
|
91
|
+
console.error(msg);
|
|
92
|
+
warned = true;
|
|
93
|
+
}
|
|
94
|
+
return fn.apply(this, ...args);
|
|
95
|
+
}
|
|
96
|
+
return deprecated;
|
|
97
|
+
}
|
|
98
|
+
function stylizeWithColor(str, styleType) {
|
|
99
|
+
var style = inspect.styles[styleType];
|
|
100
|
+
if (style)
|
|
101
|
+
return "\x1B[" + inspect.colors[style][0] + "m" + str + "\x1B[" + inspect.colors[style][1] + "m";
|
|
102
|
+
else
|
|
103
|
+
return str;
|
|
104
|
+
}
|
|
105
|
+
function stylizeNoColor(str, styleType) {
|
|
106
|
+
return str;
|
|
107
|
+
}
|
|
108
|
+
function arrayToHash(array) {
|
|
109
|
+
var hash = {};
|
|
110
|
+
return array.forEach(function(val, idx) {
|
|
111
|
+
hash[val] = true;
|
|
112
|
+
}), hash;
|
|
113
|
+
}
|
|
114
|
+
function formatValue(ctx, value, recurseTimes) {
|
|
115
|
+
if (ctx.customInspect && value && isFunction(value.inspect) && value.inspect !== inspect && !(value.constructor && value.constructor.prototype === value)) {
|
|
116
|
+
var ret = value.inspect(recurseTimes, ctx);
|
|
117
|
+
if (!isString(ret))
|
|
118
|
+
ret = formatValue(ctx, ret, recurseTimes);
|
|
119
|
+
return ret;
|
|
120
|
+
}
|
|
121
|
+
var primitive = formatPrimitive(ctx, value);
|
|
122
|
+
if (primitive)
|
|
123
|
+
return primitive;
|
|
124
|
+
var keys = Object.keys(value), visibleKeys = arrayToHash(keys);
|
|
125
|
+
if (ctx.showHidden)
|
|
126
|
+
keys = Object.getOwnPropertyNames(value);
|
|
127
|
+
if (isError(value) && (keys.indexOf("message") >= 0 || keys.indexOf("description") >= 0))
|
|
128
|
+
return formatError(value);
|
|
129
|
+
if (keys.length === 0) {
|
|
130
|
+
if (isFunction(value)) {
|
|
131
|
+
var name = value.name ? ": " + value.name : "";
|
|
132
|
+
return ctx.stylize("[Function" + name + "]", "special");
|
|
133
|
+
}
|
|
134
|
+
if (isRegExp(value))
|
|
135
|
+
return ctx.stylize(RegExp.prototype.toString.call(value), "regexp");
|
|
136
|
+
if (isDate(value))
|
|
137
|
+
return ctx.stylize(Date.prototype.toString.call(value), "date");
|
|
138
|
+
if (isError(value))
|
|
139
|
+
return formatError(value);
|
|
140
|
+
}
|
|
141
|
+
var base = "", array = false, braces = ["{", "}"];
|
|
142
|
+
if (isArray(value))
|
|
143
|
+
array = true, braces = ["[", "]"];
|
|
144
|
+
if (isFunction(value)) {
|
|
145
|
+
var n = value.name ? ": " + value.name : "";
|
|
146
|
+
base = " [Function" + n + "]";
|
|
147
|
+
}
|
|
148
|
+
if (isRegExp(value))
|
|
149
|
+
base = " " + RegExp.prototype.toString.call(value);
|
|
150
|
+
if (isDate(value))
|
|
151
|
+
base = " " + Date.prototype.toUTCString.call(value);
|
|
152
|
+
if (isError(value))
|
|
153
|
+
base = " " + formatError(value);
|
|
154
|
+
if (keys.length === 0 && (!array || value.length == 0))
|
|
155
|
+
return braces[0] + base + braces[1];
|
|
156
|
+
if (recurseTimes < 0)
|
|
157
|
+
if (isRegExp(value))
|
|
158
|
+
return ctx.stylize(RegExp.prototype.toString.call(value), "regexp");
|
|
159
|
+
else
|
|
160
|
+
return ctx.stylize("[Object]", "special");
|
|
161
|
+
ctx.seen.push(value);
|
|
162
|
+
var output;
|
|
163
|
+
if (array)
|
|
164
|
+
output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);
|
|
165
|
+
else
|
|
166
|
+
output = keys.map(function(key) {
|
|
167
|
+
return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);
|
|
168
|
+
});
|
|
169
|
+
return ctx.seen.pop(), reduceToSingleString(output, base, braces);
|
|
170
|
+
}
|
|
171
|
+
function formatPrimitive(ctx, value) {
|
|
172
|
+
if (isUndefined(value))
|
|
173
|
+
return ctx.stylize("undefined", "undefined");
|
|
174
|
+
if (isString(value)) {
|
|
175
|
+
var simple = "'" + JSON.stringify(value).replace(/^"|"$/g, "").replace(/'/g, "\\'").replace(/\\"/g, '"') + "'";
|
|
176
|
+
return ctx.stylize(simple, "string");
|
|
177
|
+
}
|
|
178
|
+
if (isNumber(value))
|
|
179
|
+
return ctx.stylize("" + value, "number");
|
|
180
|
+
if (isBoolean(value))
|
|
181
|
+
return ctx.stylize("" + value, "boolean");
|
|
182
|
+
if (isNull(value))
|
|
183
|
+
return ctx.stylize("null", "null");
|
|
184
|
+
}
|
|
185
|
+
function formatError(value) {
|
|
186
|
+
return "[" + Error.prototype.toString.call(value) + "]";
|
|
187
|
+
}
|
|
188
|
+
function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {
|
|
189
|
+
var output = [];
|
|
190
|
+
for (var i = 0, l = value.length;i < l; ++i)
|
|
191
|
+
if (hasOwnProperty(value, String(i)))
|
|
192
|
+
output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, String(i), true));
|
|
193
|
+
else
|
|
194
|
+
output.push("");
|
|
195
|
+
return keys.forEach(function(key) {
|
|
196
|
+
if (!key.match(/^\d+$/))
|
|
197
|
+
output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, key, true));
|
|
198
|
+
}), output;
|
|
199
|
+
}
|
|
200
|
+
function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
|
|
201
|
+
var name, str, desc;
|
|
202
|
+
if (desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] }, desc.get)
|
|
203
|
+
if (desc.set)
|
|
204
|
+
str = ctx.stylize("[Getter/Setter]", "special");
|
|
205
|
+
else
|
|
206
|
+
str = ctx.stylize("[Getter]", "special");
|
|
207
|
+
else if (desc.set)
|
|
208
|
+
str = ctx.stylize("[Setter]", "special");
|
|
209
|
+
if (!hasOwnProperty(visibleKeys, key))
|
|
210
|
+
name = "[" + key + "]";
|
|
211
|
+
if (!str)
|
|
212
|
+
if (ctx.seen.indexOf(desc.value) < 0) {
|
|
213
|
+
if (isNull(recurseTimes))
|
|
214
|
+
str = formatValue(ctx, desc.value, null);
|
|
215
|
+
else
|
|
216
|
+
str = formatValue(ctx, desc.value, recurseTimes - 1);
|
|
217
|
+
if (str.indexOf(`
|
|
218
|
+
`) > -1)
|
|
219
|
+
if (array)
|
|
220
|
+
str = str.split(`
|
|
221
|
+
`).map(function(line) {
|
|
222
|
+
return " " + line;
|
|
223
|
+
}).join(`
|
|
224
|
+
`).slice(2);
|
|
225
|
+
else
|
|
226
|
+
str = `
|
|
227
|
+
` + str.split(`
|
|
228
|
+
`).map(function(line) {
|
|
229
|
+
return " " + line;
|
|
230
|
+
}).join(`
|
|
231
|
+
`);
|
|
232
|
+
} else
|
|
233
|
+
str = ctx.stylize("[Circular]", "special");
|
|
234
|
+
if (isUndefined(name)) {
|
|
235
|
+
if (array && key.match(/^\d+$/))
|
|
236
|
+
return str;
|
|
237
|
+
if (name = JSON.stringify("" + key), name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/))
|
|
238
|
+
name = name.slice(1, -1), name = ctx.stylize(name, "name");
|
|
239
|
+
else
|
|
240
|
+
name = name.replace(/'/g, "\\'").replace(/\\"/g, '"').replace(/(^"|"$)/g, "'"), name = ctx.stylize(name, "string");
|
|
241
|
+
}
|
|
242
|
+
return name + ": " + str;
|
|
243
|
+
}
|
|
244
|
+
function reduceToSingleString(output, base, braces) {
|
|
245
|
+
var numLinesEst = 0, length = output.reduce(function(prev, cur) {
|
|
246
|
+
if (numLinesEst++, cur.indexOf(`
|
|
247
|
+
`) >= 0)
|
|
248
|
+
numLinesEst++;
|
|
249
|
+
return prev + cur.replace(/\u001b\[\d\d?m/g, "").length + 1;
|
|
250
|
+
}, 0);
|
|
251
|
+
if (length > 60)
|
|
252
|
+
return braces[0] + (base === "" ? "" : base + `
|
|
253
|
+
`) + " " + output.join(`,
|
|
254
|
+
`) + " " + braces[1];
|
|
255
|
+
return braces[0] + base + " " + output.join(", ") + " " + braces[1];
|
|
256
|
+
}
|
|
257
|
+
function isArray(ar) {
|
|
258
|
+
return Array.isArray(ar);
|
|
259
|
+
}
|
|
260
|
+
function isBoolean(arg) {
|
|
261
|
+
return typeof arg === "boolean";
|
|
262
|
+
}
|
|
263
|
+
function isNull(arg) {
|
|
264
|
+
return arg === null;
|
|
265
|
+
}
|
|
266
|
+
function isNullOrUndefined(arg) {
|
|
267
|
+
return arg == null;
|
|
268
|
+
}
|
|
269
|
+
function isNumber(arg) {
|
|
270
|
+
return typeof arg === "number";
|
|
271
|
+
}
|
|
272
|
+
function isString(arg) {
|
|
273
|
+
return typeof arg === "string";
|
|
274
|
+
}
|
|
275
|
+
function isSymbol(arg) {
|
|
276
|
+
return typeof arg === "symbol";
|
|
277
|
+
}
|
|
278
|
+
function isUndefined(arg) {
|
|
279
|
+
return arg === undefined;
|
|
280
|
+
}
|
|
281
|
+
function isRegExp(re) {
|
|
282
|
+
return isObject(re) && objectToString(re) === "[object RegExp]";
|
|
283
|
+
}
|
|
284
|
+
function isObject(arg) {
|
|
285
|
+
return typeof arg === "object" && arg !== null;
|
|
286
|
+
}
|
|
287
|
+
function isDate(d) {
|
|
288
|
+
return isObject(d) && objectToString(d) === "[object Date]";
|
|
289
|
+
}
|
|
290
|
+
function isError(e) {
|
|
291
|
+
return isObject(e) && (objectToString(e) === "[object Error]" || e instanceof Error);
|
|
292
|
+
}
|
|
293
|
+
function isFunction(arg) {
|
|
294
|
+
return typeof arg === "function";
|
|
295
|
+
}
|
|
296
|
+
function isPrimitive(arg) {
|
|
297
|
+
return arg === null || typeof arg === "boolean" || typeof arg === "number" || typeof arg === "string" || typeof arg === "symbol" || typeof arg > "u";
|
|
298
|
+
}
|
|
299
|
+
function isBuffer(arg) {
|
|
300
|
+
return arg instanceof Buffer;
|
|
301
|
+
}
|
|
302
|
+
function objectToString(o) {
|
|
303
|
+
return Object.prototype.toString.call(o);
|
|
304
|
+
}
|
|
305
|
+
function pad(n) {
|
|
306
|
+
return n < 10 ? "0" + n.toString(10) : n.toString(10);
|
|
307
|
+
}
|
|
308
|
+
function timestamp() {
|
|
309
|
+
var d = new Date, time = [pad(d.getHours()), pad(d.getMinutes()), pad(d.getSeconds())].join(":");
|
|
310
|
+
return [d.getDate(), months[d.getMonth()], time].join(" ");
|
|
311
|
+
}
|
|
312
|
+
function log(...args) {
|
|
313
|
+
console.log("%s - %s", timestamp(), format.apply(null, args));
|
|
314
|
+
}
|
|
315
|
+
function inherits(ctor, superCtor) {
|
|
316
|
+
if (superCtor)
|
|
317
|
+
ctor.super_ = superCtor, ctor.prototype = Object.create(superCtor.prototype, { constructor: { value: ctor, enumerable: false, writable: true, configurable: true } });
|
|
318
|
+
}
|
|
319
|
+
function _extend(origin, add) {
|
|
320
|
+
if (!add || !isObject(add))
|
|
321
|
+
return origin;
|
|
322
|
+
var keys = Object.keys(add), i = keys.length;
|
|
323
|
+
while (i--)
|
|
324
|
+
origin[keys[i]] = add[keys[i]];
|
|
325
|
+
return origin;
|
|
326
|
+
}
|
|
327
|
+
function hasOwnProperty(obj, prop) {
|
|
328
|
+
return Object.prototype.hasOwnProperty.call(obj, prop);
|
|
329
|
+
}
|
|
330
|
+
function callbackifyOnRejected(reason, cb) {
|
|
331
|
+
if (!reason) {
|
|
332
|
+
var newReason = Error("Promise was rejected with a falsy value");
|
|
333
|
+
newReason.reason = reason, reason = newReason;
|
|
334
|
+
}
|
|
335
|
+
return cb(reason);
|
|
336
|
+
}
|
|
337
|
+
function callbackify(original) {
|
|
338
|
+
if (typeof original !== "function")
|
|
339
|
+
throw TypeError('The "original" argument must be of type Function');
|
|
340
|
+
function callbackified(...args) {
|
|
341
|
+
var maybeCb = args.pop();
|
|
342
|
+
if (typeof maybeCb !== "function")
|
|
343
|
+
throw TypeError("The last argument must be of type Function");
|
|
344
|
+
var self = this, cb = function(...args2) {
|
|
345
|
+
return maybeCb.apply(self, ...args2);
|
|
346
|
+
};
|
|
347
|
+
original.apply(this, args).then(function(ret) {
|
|
348
|
+
process.nextTick(cb.bind(null, null, ret));
|
|
349
|
+
}, function(rej) {
|
|
350
|
+
process.nextTick(callbackifyOnRejected.bind(null, rej, cb));
|
|
351
|
+
});
|
|
352
|
+
}
|
|
353
|
+
return Object.setPrototypeOf(callbackified, Object.getPrototypeOf(original)), Object.defineProperties(callbackified, Object.getOwnPropertyDescriptors(original)), callbackified;
|
|
354
|
+
}
|
|
355
|
+
var formatRegExp, debuglog, inspect, types = () => {}, months, promisify, TextEncoder, TextDecoder, util_default;
|
|
356
|
+
var init_util = __esm(() => {
|
|
357
|
+
formatRegExp = /%[sdj%]/g;
|
|
358
|
+
debuglog = ((debugs = {}, debugEnvRegex = {}, debugEnv) => ((debugEnv = typeof process < "u" && false) && (debugEnv = debugEnv.replace(/[|\\{}()[\]^$+?.]/g, "\\$&").replace(/\*/g, ".*").replace(/,/g, "$|^").toUpperCase()), debugEnvRegex = new RegExp("^" + debugEnv + "$", "i"), (set) => {
|
|
359
|
+
if (set = set.toUpperCase(), !debugs[set])
|
|
360
|
+
if (debugEnvRegex.test(set))
|
|
361
|
+
debugs[set] = function(...args) {
|
|
362
|
+
console.error("%s: %s", set, pid, format.apply(null, ...args));
|
|
363
|
+
};
|
|
364
|
+
else
|
|
365
|
+
debugs[set] = function() {};
|
|
366
|
+
return debugs[set];
|
|
367
|
+
}))();
|
|
368
|
+
inspect = ((i) => (i.colors = { bold: [1, 22], italic: [3, 23], underline: [4, 24], inverse: [7, 27], white: [37, 39], grey: [90, 39], black: [30, 39], blue: [34, 39], cyan: [36, 39], green: [32, 39], magenta: [35, 39], red: [31, 39], yellow: [33, 39] }, i.styles = { special: "cyan", number: "yellow", boolean: "yellow", undefined: "grey", null: "bold", string: "green", date: "magenta", regexp: "red" }, i.custom = Symbol.for("nodejs.util.inspect.custom"), i))(function(obj, opts, ...rest) {
|
|
369
|
+
var ctx = { seen: [], stylize: stylizeNoColor };
|
|
370
|
+
if (rest.length >= 1)
|
|
371
|
+
ctx.depth = rest[0];
|
|
372
|
+
if (rest.length >= 2)
|
|
373
|
+
ctx.colors = rest[1];
|
|
374
|
+
if (isBoolean(opts))
|
|
375
|
+
ctx.showHidden = opts;
|
|
376
|
+
else if (opts)
|
|
377
|
+
_extend(ctx, opts);
|
|
378
|
+
if (isUndefined(ctx.showHidden))
|
|
379
|
+
ctx.showHidden = false;
|
|
380
|
+
if (isUndefined(ctx.depth))
|
|
381
|
+
ctx.depth = 2;
|
|
382
|
+
if (isUndefined(ctx.colors))
|
|
383
|
+
ctx.colors = false;
|
|
384
|
+
if (ctx.colors)
|
|
385
|
+
ctx.stylize = stylizeWithColor;
|
|
386
|
+
return formatValue(ctx, obj, ctx.depth);
|
|
387
|
+
});
|
|
388
|
+
months = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
|
|
389
|
+
promisify = ((x) => (x.custom = Symbol.for("nodejs.util.promisify.custom"), x))(function(original) {
|
|
390
|
+
if (typeof original !== "function")
|
|
391
|
+
throw TypeError('The "original" argument must be of type Function');
|
|
392
|
+
if (kCustomPromisifiedSymbol && original[kCustomPromisifiedSymbol]) {
|
|
393
|
+
var fn = original[kCustomPromisifiedSymbol];
|
|
394
|
+
if (typeof fn !== "function")
|
|
395
|
+
throw TypeError('The "nodejs.util.promisify.custom" argument must be of type Function');
|
|
396
|
+
return Object.defineProperty(fn, kCustomPromisifiedSymbol, { value: fn, enumerable: false, writable: false, configurable: true }), fn;
|
|
397
|
+
}
|
|
398
|
+
function fn(...args) {
|
|
399
|
+
var promiseResolve, promiseReject, promise = new Promise(function(resolve, reject) {
|
|
400
|
+
promiseResolve = resolve, promiseReject = reject;
|
|
401
|
+
});
|
|
402
|
+
args.push(function(err, value) {
|
|
403
|
+
if (err)
|
|
404
|
+
promiseReject(err);
|
|
405
|
+
else
|
|
406
|
+
promiseResolve(value);
|
|
407
|
+
});
|
|
408
|
+
try {
|
|
409
|
+
original.apply(this, args);
|
|
410
|
+
} catch (err) {
|
|
411
|
+
promiseReject(err);
|
|
412
|
+
}
|
|
413
|
+
return promise;
|
|
414
|
+
}
|
|
415
|
+
if (Object.setPrototypeOf(fn, Object.getPrototypeOf(original)), kCustomPromisifiedSymbol)
|
|
416
|
+
Object.defineProperty(fn, kCustomPromisifiedSymbol, { value: fn, enumerable: false, writable: false, configurable: true });
|
|
417
|
+
return Object.defineProperties(fn, Object.getOwnPropertyDescriptors(original));
|
|
418
|
+
});
|
|
419
|
+
({ TextEncoder, TextDecoder } = globalThis);
|
|
420
|
+
util_default = { TextEncoder, TextDecoder, promisify, log, inherits, _extend, callbackifyOnRejected, callbackify };
|
|
421
|
+
});
|
|
28
422
|
|
|
29
423
|
// ../../internal/constants/src/endpoints.ts
|
|
30
424
|
var DEFAULT_PLATFORM = "BEYOND_AI";
|
|
@@ -180,7 +574,7 @@ function detectEnvironment() {
|
|
|
180
574
|
var nodeInspect;
|
|
181
575
|
if (!isBrowser()) {
|
|
182
576
|
try {
|
|
183
|
-
const util = await
|
|
577
|
+
const util = await Promise.resolve().then(() => (init_util(), exports_util));
|
|
184
578
|
nodeInspect = util.inspect;
|
|
185
579
|
} catch {}
|
|
186
580
|
}
|
|
@@ -233,10 +627,10 @@ var terminalFormatter = (entry) => {
|
|
|
233
627
|
const consoleMethod = getConsoleMethod(entry.level);
|
|
234
628
|
const levelUpper = entry.level.toUpperCase().padEnd(5);
|
|
235
629
|
const isoString = entry.timestamp.toISOString().replace(/\.\d{3}Z$/, "");
|
|
236
|
-
const
|
|
630
|
+
const timestamp2 = `${colors.dim}[${isoString}]${colors.reset}`;
|
|
237
631
|
const level = `${levelColor}${levelUpper}${colors.reset}`;
|
|
238
632
|
const scope = entry.scope ? `${colors.bold}[${entry.scope}]${colors.reset} ` : "";
|
|
239
|
-
const prefix = `${
|
|
633
|
+
const prefix = `${timestamp2} ${level} ${scope}${entry.message}`;
|
|
240
634
|
if (entry.context && Object.keys(entry.context).length > 0) {
|
|
241
635
|
consoleMethod(prefix, formatContext(entry.context));
|
|
242
636
|
} else {
|
|
@@ -251,9 +645,9 @@ var LEVEL_PREFIX = {
|
|
|
251
645
|
error: "[ERROR]"
|
|
252
646
|
};
|
|
253
647
|
function formatContext2(context) {
|
|
254
|
-
return Object.entries(context).map(([key, value]) => `${key}=${
|
|
648
|
+
return Object.entries(context).map(([key, value]) => `${key}=${formatValue2(value)}`).join(" ");
|
|
255
649
|
}
|
|
256
|
-
function
|
|
650
|
+
function formatValue2(value) {
|
|
257
651
|
if (typeof value === "string")
|
|
258
652
|
return value;
|
|
259
653
|
if (typeof value === "number")
|
|
@@ -413,7 +807,7 @@ function isDebug() {
|
|
|
413
807
|
return false;
|
|
414
808
|
}
|
|
415
809
|
}
|
|
416
|
-
var
|
|
810
|
+
var log2 = createLogger({ scope: "auth", minLevel: isDebug() ? "debug" : "warn" });
|
|
417
811
|
|
|
418
812
|
class TokenManager {
|
|
419
813
|
config;
|
|
@@ -427,11 +821,11 @@ class TokenManager {
|
|
|
427
821
|
}
|
|
428
822
|
async getToken() {
|
|
429
823
|
if (this.accessToken && Date.now() < this.tokenExpiry) {
|
|
430
|
-
|
|
824
|
+
log2.debug("Using cached token");
|
|
431
825
|
return this.accessToken;
|
|
432
826
|
}
|
|
433
827
|
if (this.pendingRequest) {
|
|
434
|
-
|
|
828
|
+
log2.debug("Waiting for in-flight token request");
|
|
435
829
|
return this.pendingRequest;
|
|
436
830
|
}
|
|
437
831
|
this.pendingRequest = this.fetchToken();
|
|
@@ -442,7 +836,7 @@ class TokenManager {
|
|
|
442
836
|
}
|
|
443
837
|
}
|
|
444
838
|
async fetchToken() {
|
|
445
|
-
|
|
839
|
+
log2.debug("Fetching new access token...");
|
|
446
840
|
const { clientId, clientSecret } = this.config.credentials;
|
|
447
841
|
const credentials = btoa(`${clientId}:${clientSecret}`);
|
|
448
842
|
const start = performance.now();
|
|
@@ -456,17 +850,17 @@ class TokenManager {
|
|
|
456
850
|
});
|
|
457
851
|
const duration = Math.round(performance.now() - start);
|
|
458
852
|
if (!response.ok) {
|
|
459
|
-
|
|
853
|
+
log2.error(`Token request failed: ${response.status} ${response.statusText}`);
|
|
460
854
|
throw new Error(`Failed to obtain access token: ${response.status} ${response.statusText}`);
|
|
461
855
|
}
|
|
462
856
|
const data = await response.json();
|
|
463
857
|
this.accessToken = data.access_token;
|
|
464
858
|
this.tokenExpiry = Date.now() + (data.expires_in - 60) * 1000;
|
|
465
|
-
|
|
859
|
+
log2.debug(`Token acquired (${duration}ms, expires in ${data.expires_in}s)`);
|
|
466
860
|
return this.accessToken;
|
|
467
861
|
}
|
|
468
862
|
invalidate() {
|
|
469
|
-
|
|
863
|
+
log2.debug("Token invalidated");
|
|
470
864
|
this.accessToken = null;
|
|
471
865
|
this.tokenExpiry = 0;
|
|
472
866
|
}
|
|
@@ -1279,43 +1673,43 @@ function escapeValue(value) {
|
|
|
1279
1673
|
}
|
|
1280
1674
|
return value.replaceAll("'", "''");
|
|
1281
1675
|
}
|
|
1282
|
-
function
|
|
1676
|
+
function formatValue3(value) {
|
|
1283
1677
|
const escaped = escapeValue(value);
|
|
1284
1678
|
const needsQuotes = typeof value === "string" || value instanceof Date;
|
|
1285
1679
|
return needsQuotes ? `'${escaped}'` : escaped;
|
|
1286
1680
|
}
|
|
1287
1681
|
function fieldToConditions(field, condition) {
|
|
1288
1682
|
if (typeof condition === "string" || typeof condition === "number" || typeof condition === "boolean" || condition instanceof Date) {
|
|
1289
|
-
return [`${field}=${
|
|
1683
|
+
return [`${field}=${formatValue3(condition)}`];
|
|
1290
1684
|
}
|
|
1291
1685
|
if (typeof condition === "object" && condition !== null) {
|
|
1292
1686
|
const ops = condition;
|
|
1293
1687
|
const conditions = [];
|
|
1294
1688
|
if (ops.ne !== undefined) {
|
|
1295
|
-
conditions.push(`${field}!=${
|
|
1689
|
+
conditions.push(`${field}!=${formatValue3(ops.ne)}`);
|
|
1296
1690
|
}
|
|
1297
1691
|
if (ops.gt !== undefined) {
|
|
1298
|
-
conditions.push(`${field}>${
|
|
1692
|
+
conditions.push(`${field}>${formatValue3(ops.gt)}`);
|
|
1299
1693
|
}
|
|
1300
1694
|
if (ops.gte !== undefined) {
|
|
1301
|
-
conditions.push(`${field}>=${
|
|
1695
|
+
conditions.push(`${field}>=${formatValue3(ops.gte)}`);
|
|
1302
1696
|
}
|
|
1303
1697
|
if (ops.lt !== undefined) {
|
|
1304
|
-
conditions.push(`${field}<${
|
|
1698
|
+
conditions.push(`${field}<${formatValue3(ops.lt)}`);
|
|
1305
1699
|
}
|
|
1306
1700
|
if (ops.lte !== undefined) {
|
|
1307
|
-
conditions.push(`${field}<=${
|
|
1701
|
+
conditions.push(`${field}<=${formatValue3(ops.lte)}`);
|
|
1308
1702
|
}
|
|
1309
1703
|
if (ops.contains !== undefined) {
|
|
1310
|
-
conditions.push(`${field}~${
|
|
1704
|
+
conditions.push(`${field}~${formatValue3(ops.contains)}`);
|
|
1311
1705
|
}
|
|
1312
1706
|
if (ops.in !== undefined && ops.in.length > 0) {
|
|
1313
|
-
const inConditions = ops.in.map((v) => `${field}=${
|
|
1707
|
+
const inConditions = ops.in.map((v) => `${field}=${formatValue3(v)}`);
|
|
1314
1708
|
const joined = inConditions.join(" OR ");
|
|
1315
1709
|
conditions.push(inConditions.length > 1 ? `(${joined})` : joined);
|
|
1316
1710
|
}
|
|
1317
1711
|
if (ops.notIn !== undefined && ops.notIn.length > 0) {
|
|
1318
|
-
const notInConditions = ops.notIn.map((v) => `${field}!=${
|
|
1712
|
+
const notInConditions = ops.notIn.map((v) => `${field}!=${formatValue3(v)}`);
|
|
1319
1713
|
conditions.push(notInConditions.join(" AND "));
|
|
1320
1714
|
}
|
|
1321
1715
|
return conditions;
|
|
@@ -1538,7 +1932,7 @@ function resolveToProvider2(config, registry = DEFAULT_PROVIDER_REGISTRY) {
|
|
|
1538
1932
|
}
|
|
1539
1933
|
|
|
1540
1934
|
// src/utils.ts
|
|
1541
|
-
var
|
|
1935
|
+
var log3 = createScopedLogger("oneroster");
|
|
1542
1936
|
function parseGrades(grades) {
|
|
1543
1937
|
if (!grades)
|
|
1544
1938
|
return;
|
|
@@ -1557,7 +1951,7 @@ function normalizeBoolean(value) {
|
|
|
1557
1951
|
class Transport extends BaseTransport {
|
|
1558
1952
|
paths;
|
|
1559
1953
|
constructor(config) {
|
|
1560
|
-
super({ config, logger:
|
|
1954
|
+
super({ config, logger: log3 });
|
|
1561
1955
|
this.paths = config.paths;
|
|
1562
1956
|
}
|
|
1563
1957
|
async requestPaginated(path, options = {}) {
|
|
@@ -1577,7 +1971,7 @@ __export(exports_external, {
|
|
|
1577
1971
|
uuidv6: () => uuidv6,
|
|
1578
1972
|
uuidv4: () => uuidv4,
|
|
1579
1973
|
uuid: () => uuid2,
|
|
1580
|
-
util: () =>
|
|
1974
|
+
util: () => exports_util2,
|
|
1581
1975
|
url: () => url,
|
|
1582
1976
|
uppercase: () => _uppercase,
|
|
1583
1977
|
unknown: () => unknown,
|
|
@@ -1686,7 +2080,7 @@ __export(exports_external, {
|
|
|
1686
2080
|
getErrorMap: () => getErrorMap,
|
|
1687
2081
|
function: () => _function,
|
|
1688
2082
|
fromJSONSchema: () => fromJSONSchema,
|
|
1689
|
-
formatError: () =>
|
|
2083
|
+
formatError: () => formatError2,
|
|
1690
2084
|
float64: () => float64,
|
|
1691
2085
|
float32: () => float32,
|
|
1692
2086
|
flattenError: () => flattenError,
|
|
@@ -1812,7 +2206,7 @@ __export(exports_external, {
|
|
|
1812
2206
|
var exports_core2 = {};
|
|
1813
2207
|
__export(exports_core2, {
|
|
1814
2208
|
version: () => version,
|
|
1815
|
-
util: () =>
|
|
2209
|
+
util: () => exports_util2,
|
|
1816
2210
|
treeifyError: () => treeifyError,
|
|
1817
2211
|
toJSONSchema: () => toJSONSchema,
|
|
1818
2212
|
toDotPath: () => toDotPath,
|
|
@@ -1836,7 +2230,7 @@ __export(exports_core2, {
|
|
|
1836
2230
|
initializeContext: () => initializeContext,
|
|
1837
2231
|
globalRegistry: () => globalRegistry,
|
|
1838
2232
|
globalConfig: () => globalConfig,
|
|
1839
|
-
formatError: () =>
|
|
2233
|
+
formatError: () => formatError2,
|
|
1840
2234
|
flattenError: () => flattenError,
|
|
1841
2235
|
finalize: () => finalize,
|
|
1842
2236
|
extractDefs: () => extractDefs,
|
|
@@ -2163,8 +2557,8 @@ function config(newConfig) {
|
|
|
2163
2557
|
return globalConfig;
|
|
2164
2558
|
}
|
|
2165
2559
|
// ../../../node_modules/.bun/zod@4.3.6/node_modules/zod/v4/core/util.js
|
|
2166
|
-
var
|
|
2167
|
-
__export(
|
|
2560
|
+
var exports_util2 = {};
|
|
2561
|
+
__export(exports_util2, {
|
|
2168
2562
|
unwrapMessage: () => unwrapMessage,
|
|
2169
2563
|
uint8ArrayToHex: () => uint8ArrayToHex,
|
|
2170
2564
|
uint8ArrayToBase64url: () => uint8ArrayToBase64url,
|
|
@@ -2194,7 +2588,7 @@ __export(exports_util, {
|
|
|
2194
2588
|
joinValues: () => joinValues,
|
|
2195
2589
|
issue: () => issue2,
|
|
2196
2590
|
isPlainObject: () => isPlainObject,
|
|
2197
|
-
isObject: () =>
|
|
2591
|
+
isObject: () => isObject2,
|
|
2198
2592
|
hexToUint8Array: () => hexToUint8Array,
|
|
2199
2593
|
getSizableOrigin: () => getSizableOrigin,
|
|
2200
2594
|
getParsedType: () => getParsedType,
|
|
@@ -2363,7 +2757,7 @@ function slugify(input) {
|
|
|
2363
2757
|
return input.toLowerCase().trim().replace(/[^\w\s-]/g, "").replace(/[\s_-]+/g, "-").replace(/^-+|-+$/g, "");
|
|
2364
2758
|
}
|
|
2365
2759
|
var captureStackTrace = "captureStackTrace" in Error ? Error.captureStackTrace : (..._args) => {};
|
|
2366
|
-
function
|
|
2760
|
+
function isObject2(data) {
|
|
2367
2761
|
return typeof data === "object" && data !== null && !Array.isArray(data);
|
|
2368
2762
|
}
|
|
2369
2763
|
var allowsEval = cached(() => {
|
|
@@ -2379,7 +2773,7 @@ var allowsEval = cached(() => {
|
|
|
2379
2773
|
}
|
|
2380
2774
|
});
|
|
2381
2775
|
function isPlainObject(o) {
|
|
2382
|
-
if (
|
|
2776
|
+
if (isObject2(o) === false)
|
|
2383
2777
|
return false;
|
|
2384
2778
|
const ctor = o.constructor;
|
|
2385
2779
|
if (ctor === undefined)
|
|
@@ -2387,7 +2781,7 @@ function isPlainObject(o) {
|
|
|
2387
2781
|
if (typeof ctor !== "function")
|
|
2388
2782
|
return true;
|
|
2389
2783
|
const prot = ctor.prototype;
|
|
2390
|
-
if (
|
|
2784
|
+
if (isObject2(prot) === false)
|
|
2391
2785
|
return false;
|
|
2392
2786
|
if (Object.prototype.hasOwnProperty.call(prot, "isPrototypeOf") === false) {
|
|
2393
2787
|
return false;
|
|
@@ -2868,7 +3262,7 @@ function flattenError(error, mapper = (issue3) => issue3.message) {
|
|
|
2868
3262
|
}
|
|
2869
3263
|
return { formErrors, fieldErrors };
|
|
2870
3264
|
}
|
|
2871
|
-
function
|
|
3265
|
+
function formatError2(error, mapper = (issue3) => issue3.message) {
|
|
2872
3266
|
const fieldErrors = { _errors: [] };
|
|
2873
3267
|
const processError = (error2) => {
|
|
2874
3268
|
for (const issue3 of error2.issues) {
|
|
@@ -4393,15 +4787,15 @@ var $ZodDate = /* @__PURE__ */ $constructor("$ZodDate", (inst, def) => {
|
|
|
4393
4787
|
} catch (_err) {}
|
|
4394
4788
|
}
|
|
4395
4789
|
const input = payload.value;
|
|
4396
|
-
const
|
|
4397
|
-
const isValidDate =
|
|
4790
|
+
const isDate2 = input instanceof Date;
|
|
4791
|
+
const isValidDate = isDate2 && !Number.isNaN(input.getTime());
|
|
4398
4792
|
if (isValidDate)
|
|
4399
4793
|
return payload;
|
|
4400
4794
|
payload.issues.push({
|
|
4401
4795
|
expected: "date",
|
|
4402
4796
|
code: "invalid_type",
|
|
4403
4797
|
input,
|
|
4404
|
-
...
|
|
4798
|
+
...isDate2 ? { received: "Invalid Date" } : {},
|
|
4405
4799
|
inst
|
|
4406
4800
|
});
|
|
4407
4801
|
return payload;
|
|
@@ -4540,13 +4934,13 @@ var $ZodObject = /* @__PURE__ */ $constructor("$ZodObject", (inst, def) => {
|
|
|
4540
4934
|
}
|
|
4541
4935
|
return propValues;
|
|
4542
4936
|
});
|
|
4543
|
-
const
|
|
4937
|
+
const isObject3 = isObject2;
|
|
4544
4938
|
const catchall = def.catchall;
|
|
4545
4939
|
let value;
|
|
4546
4940
|
inst._zod.parse = (payload, ctx) => {
|
|
4547
4941
|
value ?? (value = _normalized.value);
|
|
4548
4942
|
const input = payload.value;
|
|
4549
|
-
if (!
|
|
4943
|
+
if (!isObject3(input)) {
|
|
4550
4944
|
payload.issues.push({
|
|
4551
4945
|
expected: "object",
|
|
4552
4946
|
code: "invalid_type",
|
|
@@ -4644,7 +5038,7 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
|
|
|
4644
5038
|
return (payload, ctx) => fn(shape, payload, ctx);
|
|
4645
5039
|
};
|
|
4646
5040
|
let fastpass;
|
|
4647
|
-
const
|
|
5041
|
+
const isObject3 = isObject2;
|
|
4648
5042
|
const jit = !globalConfig.jitless;
|
|
4649
5043
|
const allowsEval2 = allowsEval;
|
|
4650
5044
|
const fastEnabled = jit && allowsEval2.value;
|
|
@@ -4653,7 +5047,7 @@ var $ZodObjectJIT = /* @__PURE__ */ $constructor("$ZodObjectJIT", (inst, def) =>
|
|
|
4653
5047
|
inst._zod.parse = (payload, ctx) => {
|
|
4654
5048
|
value ?? (value = _normalized.value);
|
|
4655
5049
|
const input = payload.value;
|
|
4656
|
-
if (!
|
|
5050
|
+
if (!isObject3(input)) {
|
|
4657
5051
|
payload.issues.push({
|
|
4658
5052
|
expected: "object",
|
|
4659
5053
|
code: "invalid_type",
|
|
@@ -4831,7 +5225,7 @@ var $ZodDiscriminatedUnion = /* @__PURE__ */ $constructor("$ZodDiscriminatedUnio
|
|
|
4831
5225
|
});
|
|
4832
5226
|
inst._zod.parse = (payload, ctx) => {
|
|
4833
5227
|
const input = payload.value;
|
|
4834
|
-
if (!
|
|
5228
|
+
if (!isObject2(input)) {
|
|
4835
5229
|
payload.issues.push({
|
|
4836
5230
|
code: "invalid_type",
|
|
4837
5231
|
expected: "object",
|
|
@@ -11925,10 +12319,10 @@ function _property(property, schema, params) {
|
|
|
11925
12319
|
...normalizeParams(params)
|
|
11926
12320
|
});
|
|
11927
12321
|
}
|
|
11928
|
-
function _mime(
|
|
12322
|
+
function _mime(types2, params) {
|
|
11929
12323
|
return new $ZodCheckMimeType({
|
|
11930
12324
|
check: "mime_type",
|
|
11931
|
-
mime:
|
|
12325
|
+
mime: types2,
|
|
11932
12326
|
...normalizeParams(params)
|
|
11933
12327
|
});
|
|
11934
12328
|
}
|
|
@@ -12251,13 +12645,13 @@ function _stringbool(Classes, _params) {
|
|
|
12251
12645
|
});
|
|
12252
12646
|
return codec;
|
|
12253
12647
|
}
|
|
12254
|
-
function _stringFormat(Class2,
|
|
12648
|
+
function _stringFormat(Class2, format2, fnOrRegex, _params = {}) {
|
|
12255
12649
|
const params = normalizeParams(_params);
|
|
12256
12650
|
const def = {
|
|
12257
12651
|
...normalizeParams(_params),
|
|
12258
12652
|
check: "string_format",
|
|
12259
12653
|
type: "string",
|
|
12260
|
-
format,
|
|
12654
|
+
format: format2,
|
|
12261
12655
|
fn: typeof fnOrRegex === "function" ? fnOrRegex : (val) => fnOrRegex.test(val),
|
|
12262
12656
|
...params
|
|
12263
12657
|
};
|
|
@@ -12623,16 +13017,16 @@ var formatMap = {
|
|
|
12623
13017
|
var stringProcessor = (schema, ctx, _json, _params) => {
|
|
12624
13018
|
const json = _json;
|
|
12625
13019
|
json.type = "string";
|
|
12626
|
-
const { minimum, maximum, format, patterns: patterns2, contentEncoding } = schema._zod.bag;
|
|
13020
|
+
const { minimum, maximum, format: format2, patterns: patterns2, contentEncoding } = schema._zod.bag;
|
|
12627
13021
|
if (typeof minimum === "number")
|
|
12628
13022
|
json.minLength = minimum;
|
|
12629
13023
|
if (typeof maximum === "number")
|
|
12630
13024
|
json.maxLength = maximum;
|
|
12631
|
-
if (
|
|
12632
|
-
json.format = formatMap[
|
|
13025
|
+
if (format2) {
|
|
13026
|
+
json.format = formatMap[format2] ?? format2;
|
|
12633
13027
|
if (json.format === "")
|
|
12634
13028
|
delete json.format;
|
|
12635
|
-
if (
|
|
13029
|
+
if (format2 === "time") {
|
|
12636
13030
|
delete json.format;
|
|
12637
13031
|
}
|
|
12638
13032
|
}
|
|
@@ -12654,8 +13048,8 @@ var stringProcessor = (schema, ctx, _json, _params) => {
|
|
|
12654
13048
|
};
|
|
12655
13049
|
var numberProcessor = (schema, ctx, _json, _params) => {
|
|
12656
13050
|
const json = _json;
|
|
12657
|
-
const { minimum, maximum, format, multipleOf, exclusiveMaximum, exclusiveMinimum } = schema._zod.bag;
|
|
12658
|
-
if (typeof
|
|
13051
|
+
const { minimum, maximum, format: format2, multipleOf, exclusiveMaximum, exclusiveMinimum } = schema._zod.bag;
|
|
13052
|
+
if (typeof format2 === "string" && format2.includes("int"))
|
|
12659
13053
|
json.type = "integer";
|
|
12660
13054
|
else
|
|
12661
13055
|
json.type = "number";
|
|
@@ -13468,7 +13862,7 @@ var initializer2 = (inst, issues) => {
|
|
|
13468
13862
|
inst.name = "ZodError";
|
|
13469
13863
|
Object.defineProperties(inst, {
|
|
13470
13864
|
format: {
|
|
13471
|
-
value: (mapper) =>
|
|
13865
|
+
value: (mapper) => formatError2(inst, mapper)
|
|
13472
13866
|
},
|
|
13473
13867
|
flatten: {
|
|
13474
13868
|
value: (mapper) => flattenError(inst, mapper)
|
|
@@ -13525,7 +13919,7 @@ var ZodType = /* @__PURE__ */ $constructor("ZodType", (inst, def) => {
|
|
|
13525
13919
|
inst.type = def.type;
|
|
13526
13920
|
Object.defineProperty(inst, "_def", { value: def });
|
|
13527
13921
|
inst.check = (...checks2) => {
|
|
13528
|
-
return inst.clone(
|
|
13922
|
+
return inst.clone(exports_util2.mergeDefs(def, {
|
|
13529
13923
|
checks: [
|
|
13530
13924
|
...def.checks ?? [],
|
|
13531
13925
|
...checks2.map((ch) => typeof ch === "function" ? { _zod: { check: ch, def: { check: "custom" }, onattach: [] } } : ch)
|
|
@@ -13698,7 +14092,7 @@ function httpUrl(params) {
|
|
|
13698
14092
|
return _url(ZodURL, {
|
|
13699
14093
|
protocol: /^https?$/,
|
|
13700
14094
|
hostname: exports_regexes.domain,
|
|
13701
|
-
...
|
|
14095
|
+
...exports_util2.normalizeParams(params)
|
|
13702
14096
|
});
|
|
13703
14097
|
}
|
|
13704
14098
|
var ZodEmoji = /* @__PURE__ */ $constructor("ZodEmoji", (inst, def) => {
|
|
@@ -13817,8 +14211,8 @@ var ZodCustomStringFormat = /* @__PURE__ */ $constructor("ZodCustomStringFormat"
|
|
|
13817
14211
|
$ZodCustomStringFormat.init(inst, def);
|
|
13818
14212
|
ZodStringFormat.init(inst, def);
|
|
13819
14213
|
});
|
|
13820
|
-
function stringFormat(
|
|
13821
|
-
return _stringFormat(ZodCustomStringFormat,
|
|
14214
|
+
function stringFormat(format2, fnOrRegex, _params = {}) {
|
|
14215
|
+
return _stringFormat(ZodCustomStringFormat, format2, fnOrRegex, _params);
|
|
13822
14216
|
}
|
|
13823
14217
|
function hostname2(_params) {
|
|
13824
14218
|
return _stringFormat(ZodCustomStringFormat, "hostname", exports_regexes.hostname, _params);
|
|
@@ -13828,11 +14222,11 @@ function hex2(_params) {
|
|
|
13828
14222
|
}
|
|
13829
14223
|
function hash(alg, params) {
|
|
13830
14224
|
const enc = params?.enc ?? "hex";
|
|
13831
|
-
const
|
|
13832
|
-
const regex = exports_regexes[
|
|
14225
|
+
const format2 = `${alg}_${enc}`;
|
|
14226
|
+
const regex = exports_regexes[format2];
|
|
13833
14227
|
if (!regex)
|
|
13834
|
-
throw new Error(`Unrecognized hash format: ${
|
|
13835
|
-
return _stringFormat(ZodCustomStringFormat,
|
|
14228
|
+
throw new Error(`Unrecognized hash format: ${format2}`);
|
|
14229
|
+
return _stringFormat(ZodCustomStringFormat, format2, regex, params);
|
|
13836
14230
|
}
|
|
13837
14231
|
var ZodNumber = /* @__PURE__ */ $constructor("ZodNumber", (inst, def) => {
|
|
13838
14232
|
$ZodNumber.init(inst, def);
|
|
@@ -14016,7 +14410,7 @@ var ZodObject = /* @__PURE__ */ $constructor("ZodObject", (inst, def) => {
|
|
|
14016
14410
|
$ZodObjectJIT.init(inst, def);
|
|
14017
14411
|
ZodType.init(inst, def);
|
|
14018
14412
|
inst._zod.processJSONSchema = (ctx, json, params) => objectProcessor(inst, ctx, json, params);
|
|
14019
|
-
|
|
14413
|
+
exports_util2.defineLazy(inst, "shape", () => {
|
|
14020
14414
|
return def.shape;
|
|
14021
14415
|
});
|
|
14022
14416
|
inst.keyof = () => _enum2(Object.keys(inst._zod.def.shape));
|
|
@@ -14026,22 +14420,22 @@ var ZodObject = /* @__PURE__ */ $constructor("ZodObject", (inst, def) => {
|
|
|
14026
14420
|
inst.strict = () => inst.clone({ ...inst._zod.def, catchall: never() });
|
|
14027
14421
|
inst.strip = () => inst.clone({ ...inst._zod.def, catchall: undefined });
|
|
14028
14422
|
inst.extend = (incoming) => {
|
|
14029
|
-
return
|
|
14423
|
+
return exports_util2.extend(inst, incoming);
|
|
14030
14424
|
};
|
|
14031
14425
|
inst.safeExtend = (incoming) => {
|
|
14032
|
-
return
|
|
14426
|
+
return exports_util2.safeExtend(inst, incoming);
|
|
14033
14427
|
};
|
|
14034
|
-
inst.merge = (other) =>
|
|
14035
|
-
inst.pick = (mask) =>
|
|
14036
|
-
inst.omit = (mask) =>
|
|
14037
|
-
inst.partial = (...args) =>
|
|
14038
|
-
inst.required = (...args) =>
|
|
14428
|
+
inst.merge = (other) => exports_util2.merge(inst, other);
|
|
14429
|
+
inst.pick = (mask) => exports_util2.pick(inst, mask);
|
|
14430
|
+
inst.omit = (mask) => exports_util2.omit(inst, mask);
|
|
14431
|
+
inst.partial = (...args) => exports_util2.partial(ZodOptional, inst, args[0]);
|
|
14432
|
+
inst.required = (...args) => exports_util2.required(ZodNonOptional, inst, args[0]);
|
|
14039
14433
|
});
|
|
14040
14434
|
function object(shape, params) {
|
|
14041
14435
|
const def = {
|
|
14042
14436
|
type: "object",
|
|
14043
14437
|
shape: shape ?? {},
|
|
14044
|
-
...
|
|
14438
|
+
...exports_util2.normalizeParams(params)
|
|
14045
14439
|
};
|
|
14046
14440
|
return new ZodObject(def);
|
|
14047
14441
|
}
|
|
@@ -14050,7 +14444,7 @@ function strictObject(shape, params) {
|
|
|
14050
14444
|
type: "object",
|
|
14051
14445
|
shape,
|
|
14052
14446
|
catchall: never(),
|
|
14053
|
-
...
|
|
14447
|
+
...exports_util2.normalizeParams(params)
|
|
14054
14448
|
});
|
|
14055
14449
|
}
|
|
14056
14450
|
function looseObject(shape, params) {
|
|
@@ -14058,7 +14452,7 @@ function looseObject(shape, params) {
|
|
|
14058
14452
|
type: "object",
|
|
14059
14453
|
shape,
|
|
14060
14454
|
catchall: unknown(),
|
|
14061
|
-
...
|
|
14455
|
+
...exports_util2.normalizeParams(params)
|
|
14062
14456
|
});
|
|
14063
14457
|
}
|
|
14064
14458
|
var ZodUnion = /* @__PURE__ */ $constructor("ZodUnion", (inst, def) => {
|
|
@@ -14071,7 +14465,7 @@ function union(options, params) {
|
|
|
14071
14465
|
return new ZodUnion({
|
|
14072
14466
|
type: "union",
|
|
14073
14467
|
options,
|
|
14074
|
-
...
|
|
14468
|
+
...exports_util2.normalizeParams(params)
|
|
14075
14469
|
});
|
|
14076
14470
|
}
|
|
14077
14471
|
var ZodXor = /* @__PURE__ */ $constructor("ZodXor", (inst, def) => {
|
|
@@ -14085,7 +14479,7 @@ function xor(options, params) {
|
|
|
14085
14479
|
type: "union",
|
|
14086
14480
|
options,
|
|
14087
14481
|
inclusive: false,
|
|
14088
|
-
...
|
|
14482
|
+
...exports_util2.normalizeParams(params)
|
|
14089
14483
|
});
|
|
14090
14484
|
}
|
|
14091
14485
|
var ZodDiscriminatedUnion = /* @__PURE__ */ $constructor("ZodDiscriminatedUnion", (inst, def) => {
|
|
@@ -14097,7 +14491,7 @@ function discriminatedUnion(discriminator, options, params) {
|
|
|
14097
14491
|
type: "union",
|
|
14098
14492
|
options,
|
|
14099
14493
|
discriminator,
|
|
14100
|
-
...
|
|
14494
|
+
...exports_util2.normalizeParams(params)
|
|
14101
14495
|
});
|
|
14102
14496
|
}
|
|
14103
14497
|
var ZodIntersection = /* @__PURE__ */ $constructor("ZodIntersection", (inst, def) => {
|
|
@@ -14129,7 +14523,7 @@ function tuple(items, _paramsOrRest, _params) {
|
|
|
14129
14523
|
type: "tuple",
|
|
14130
14524
|
items,
|
|
14131
14525
|
rest,
|
|
14132
|
-
...
|
|
14526
|
+
...exports_util2.normalizeParams(params)
|
|
14133
14527
|
});
|
|
14134
14528
|
}
|
|
14135
14529
|
var ZodRecord = /* @__PURE__ */ $constructor("ZodRecord", (inst, def) => {
|
|
@@ -14144,7 +14538,7 @@ function record(keyType, valueType, params) {
|
|
|
14144
14538
|
type: "record",
|
|
14145
14539
|
keyType,
|
|
14146
14540
|
valueType,
|
|
14147
|
-
...
|
|
14541
|
+
...exports_util2.normalizeParams(params)
|
|
14148
14542
|
});
|
|
14149
14543
|
}
|
|
14150
14544
|
function partialRecord(keyType, valueType, params) {
|
|
@@ -14154,7 +14548,7 @@ function partialRecord(keyType, valueType, params) {
|
|
|
14154
14548
|
type: "record",
|
|
14155
14549
|
keyType: k,
|
|
14156
14550
|
valueType,
|
|
14157
|
-
...
|
|
14551
|
+
...exports_util2.normalizeParams(params)
|
|
14158
14552
|
});
|
|
14159
14553
|
}
|
|
14160
14554
|
function looseRecord(keyType, valueType, params) {
|
|
@@ -14163,7 +14557,7 @@ function looseRecord(keyType, valueType, params) {
|
|
|
14163
14557
|
keyType,
|
|
14164
14558
|
valueType,
|
|
14165
14559
|
mode: "loose",
|
|
14166
|
-
...
|
|
14560
|
+
...exports_util2.normalizeParams(params)
|
|
14167
14561
|
});
|
|
14168
14562
|
}
|
|
14169
14563
|
var ZodMap = /* @__PURE__ */ $constructor("ZodMap", (inst, def) => {
|
|
@@ -14182,7 +14576,7 @@ function map(keyType, valueType, params) {
|
|
|
14182
14576
|
type: "map",
|
|
14183
14577
|
keyType,
|
|
14184
14578
|
valueType,
|
|
14185
|
-
...
|
|
14579
|
+
...exports_util2.normalizeParams(params)
|
|
14186
14580
|
});
|
|
14187
14581
|
}
|
|
14188
14582
|
var ZodSet = /* @__PURE__ */ $constructor("ZodSet", (inst, def) => {
|
|
@@ -14198,7 +14592,7 @@ function set(valueType, params) {
|
|
|
14198
14592
|
return new ZodSet({
|
|
14199
14593
|
type: "set",
|
|
14200
14594
|
valueType,
|
|
14201
|
-
...
|
|
14595
|
+
...exports_util2.normalizeParams(params)
|
|
14202
14596
|
});
|
|
14203
14597
|
}
|
|
14204
14598
|
var ZodEnum = /* @__PURE__ */ $constructor("ZodEnum", (inst, def) => {
|
|
@@ -14219,7 +14613,7 @@ var ZodEnum = /* @__PURE__ */ $constructor("ZodEnum", (inst, def) => {
|
|
|
14219
14613
|
return new ZodEnum({
|
|
14220
14614
|
...def,
|
|
14221
14615
|
checks: [],
|
|
14222
|
-
...
|
|
14616
|
+
...exports_util2.normalizeParams(params),
|
|
14223
14617
|
entries: newEntries
|
|
14224
14618
|
});
|
|
14225
14619
|
};
|
|
@@ -14234,7 +14628,7 @@ var ZodEnum = /* @__PURE__ */ $constructor("ZodEnum", (inst, def) => {
|
|
|
14234
14628
|
return new ZodEnum({
|
|
14235
14629
|
...def,
|
|
14236
14630
|
checks: [],
|
|
14237
|
-
...
|
|
14631
|
+
...exports_util2.normalizeParams(params),
|
|
14238
14632
|
entries: newEntries
|
|
14239
14633
|
});
|
|
14240
14634
|
};
|
|
@@ -14244,14 +14638,14 @@ function _enum2(values, params) {
|
|
|
14244
14638
|
return new ZodEnum({
|
|
14245
14639
|
type: "enum",
|
|
14246
14640
|
entries,
|
|
14247
|
-
...
|
|
14641
|
+
...exports_util2.normalizeParams(params)
|
|
14248
14642
|
});
|
|
14249
14643
|
}
|
|
14250
14644
|
function nativeEnum(entries, params) {
|
|
14251
14645
|
return new ZodEnum({
|
|
14252
14646
|
type: "enum",
|
|
14253
14647
|
entries,
|
|
14254
|
-
...
|
|
14648
|
+
...exports_util2.normalizeParams(params)
|
|
14255
14649
|
});
|
|
14256
14650
|
}
|
|
14257
14651
|
var ZodLiteral = /* @__PURE__ */ $constructor("ZodLiteral", (inst, def) => {
|
|
@@ -14272,7 +14666,7 @@ function literal(value, params) {
|
|
|
14272
14666
|
return new ZodLiteral({
|
|
14273
14667
|
type: "literal",
|
|
14274
14668
|
values: Array.isArray(value) ? value : [value],
|
|
14275
|
-
...
|
|
14669
|
+
...exports_util2.normalizeParams(params)
|
|
14276
14670
|
});
|
|
14277
14671
|
}
|
|
14278
14672
|
var ZodFile = /* @__PURE__ */ $constructor("ZodFile", (inst, def) => {
|
|
@@ -14281,7 +14675,7 @@ var ZodFile = /* @__PURE__ */ $constructor("ZodFile", (inst, def) => {
|
|
|
14281
14675
|
inst._zod.processJSONSchema = (ctx, json, params) => fileProcessor(inst, ctx, json, params);
|
|
14282
14676
|
inst.min = (size, params) => inst.check(_minSize(size, params));
|
|
14283
14677
|
inst.max = (size, params) => inst.check(_maxSize(size, params));
|
|
14284
|
-
inst.mime = (
|
|
14678
|
+
inst.mime = (types2, params) => inst.check(_mime(Array.isArray(types2) ? types2 : [types2], params));
|
|
14285
14679
|
});
|
|
14286
14680
|
function file(params) {
|
|
14287
14681
|
return _file(ZodFile, params);
|
|
@@ -14296,7 +14690,7 @@ var ZodTransform = /* @__PURE__ */ $constructor("ZodTransform", (inst, def) => {
|
|
|
14296
14690
|
}
|
|
14297
14691
|
payload.addIssue = (issue3) => {
|
|
14298
14692
|
if (typeof issue3 === "string") {
|
|
14299
|
-
payload.issues.push(
|
|
14693
|
+
payload.issues.push(exports_util2.issue(issue3, payload.value, def));
|
|
14300
14694
|
} else {
|
|
14301
14695
|
const _issue = issue3;
|
|
14302
14696
|
if (_issue.fatal)
|
|
@@ -14304,7 +14698,7 @@ var ZodTransform = /* @__PURE__ */ $constructor("ZodTransform", (inst, def) => {
|
|
|
14304
14698
|
_issue.code ?? (_issue.code = "custom");
|
|
14305
14699
|
_issue.input ?? (_issue.input = payload.value);
|
|
14306
14700
|
_issue.inst ?? (_issue.inst = inst);
|
|
14307
|
-
payload.issues.push(
|
|
14701
|
+
payload.issues.push(exports_util2.issue(_issue));
|
|
14308
14702
|
}
|
|
14309
14703
|
};
|
|
14310
14704
|
const output = def.transform(payload.value, payload);
|
|
@@ -14375,7 +14769,7 @@ function _default2(innerType, defaultValue) {
|
|
|
14375
14769
|
type: "default",
|
|
14376
14770
|
innerType,
|
|
14377
14771
|
get defaultValue() {
|
|
14378
|
-
return typeof defaultValue === "function" ? defaultValue() :
|
|
14772
|
+
return typeof defaultValue === "function" ? defaultValue() : exports_util2.shallowClone(defaultValue);
|
|
14379
14773
|
}
|
|
14380
14774
|
});
|
|
14381
14775
|
}
|
|
@@ -14390,7 +14784,7 @@ function prefault(innerType, defaultValue) {
|
|
|
14390
14784
|
type: "prefault",
|
|
14391
14785
|
innerType,
|
|
14392
14786
|
get defaultValue() {
|
|
14393
|
-
return typeof defaultValue === "function" ? defaultValue() :
|
|
14787
|
+
return typeof defaultValue === "function" ? defaultValue() : exports_util2.shallowClone(defaultValue);
|
|
14394
14788
|
}
|
|
14395
14789
|
});
|
|
14396
14790
|
}
|
|
@@ -14404,7 +14798,7 @@ function nonoptional(innerType, params) {
|
|
|
14404
14798
|
return new ZodNonOptional({
|
|
14405
14799
|
type: "nonoptional",
|
|
14406
14800
|
innerType,
|
|
14407
|
-
...
|
|
14801
|
+
...exports_util2.normalizeParams(params)
|
|
14408
14802
|
});
|
|
14409
14803
|
}
|
|
14410
14804
|
var ZodSuccess = /* @__PURE__ */ $constructor("ZodSuccess", (inst, def) => {
|
|
@@ -14489,7 +14883,7 @@ function templateLiteral(parts, params) {
|
|
|
14489
14883
|
return new ZodTemplateLiteral({
|
|
14490
14884
|
type: "template_literal",
|
|
14491
14885
|
parts,
|
|
14492
|
-
...
|
|
14886
|
+
...exports_util2.normalizeParams(params)
|
|
14493
14887
|
});
|
|
14494
14888
|
}
|
|
14495
14889
|
var ZodLazy = /* @__PURE__ */ $constructor("ZodLazy", (inst, def) => {
|
|
@@ -14557,7 +14951,7 @@ function _instanceof(cls, params = {}) {
|
|
|
14557
14951
|
check: "custom",
|
|
14558
14952
|
fn: (data) => data instanceof cls,
|
|
14559
14953
|
abort: true,
|
|
14560
|
-
...
|
|
14954
|
+
...exports_util2.normalizeParams(params)
|
|
14561
14955
|
});
|
|
14562
14956
|
inst._zod.bag.Class = cls;
|
|
14563
14957
|
inst._zod.check = (payload) => {
|
|
@@ -14791,52 +15185,52 @@ function convertBaseSchema(schema, ctx) {
|
|
|
14791
15185
|
case "string": {
|
|
14792
15186
|
let stringSchema = z.string();
|
|
14793
15187
|
if (schema.format) {
|
|
14794
|
-
const
|
|
14795
|
-
if (
|
|
15188
|
+
const format2 = schema.format;
|
|
15189
|
+
if (format2 === "email") {
|
|
14796
15190
|
stringSchema = stringSchema.check(z.email());
|
|
14797
|
-
} else if (
|
|
15191
|
+
} else if (format2 === "uri" || format2 === "uri-reference") {
|
|
14798
15192
|
stringSchema = stringSchema.check(z.url());
|
|
14799
|
-
} else if (
|
|
15193
|
+
} else if (format2 === "uuid" || format2 === "guid") {
|
|
14800
15194
|
stringSchema = stringSchema.check(z.uuid());
|
|
14801
|
-
} else if (
|
|
15195
|
+
} else if (format2 === "date-time") {
|
|
14802
15196
|
stringSchema = stringSchema.check(z.iso.datetime());
|
|
14803
|
-
} else if (
|
|
15197
|
+
} else if (format2 === "date") {
|
|
14804
15198
|
stringSchema = stringSchema.check(z.iso.date());
|
|
14805
|
-
} else if (
|
|
15199
|
+
} else if (format2 === "time") {
|
|
14806
15200
|
stringSchema = stringSchema.check(z.iso.time());
|
|
14807
|
-
} else if (
|
|
15201
|
+
} else if (format2 === "duration") {
|
|
14808
15202
|
stringSchema = stringSchema.check(z.iso.duration());
|
|
14809
|
-
} else if (
|
|
15203
|
+
} else if (format2 === "ipv4") {
|
|
14810
15204
|
stringSchema = stringSchema.check(z.ipv4());
|
|
14811
|
-
} else if (
|
|
15205
|
+
} else if (format2 === "ipv6") {
|
|
14812
15206
|
stringSchema = stringSchema.check(z.ipv6());
|
|
14813
|
-
} else if (
|
|
15207
|
+
} else if (format2 === "mac") {
|
|
14814
15208
|
stringSchema = stringSchema.check(z.mac());
|
|
14815
|
-
} else if (
|
|
15209
|
+
} else if (format2 === "cidr") {
|
|
14816
15210
|
stringSchema = stringSchema.check(z.cidrv4());
|
|
14817
|
-
} else if (
|
|
15211
|
+
} else if (format2 === "cidr-v6") {
|
|
14818
15212
|
stringSchema = stringSchema.check(z.cidrv6());
|
|
14819
|
-
} else if (
|
|
15213
|
+
} else if (format2 === "base64") {
|
|
14820
15214
|
stringSchema = stringSchema.check(z.base64());
|
|
14821
|
-
} else if (
|
|
15215
|
+
} else if (format2 === "base64url") {
|
|
14822
15216
|
stringSchema = stringSchema.check(z.base64url());
|
|
14823
|
-
} else if (
|
|
15217
|
+
} else if (format2 === "e164") {
|
|
14824
15218
|
stringSchema = stringSchema.check(z.e164());
|
|
14825
|
-
} else if (
|
|
15219
|
+
} else if (format2 === "jwt") {
|
|
14826
15220
|
stringSchema = stringSchema.check(z.jwt());
|
|
14827
|
-
} else if (
|
|
15221
|
+
} else if (format2 === "emoji") {
|
|
14828
15222
|
stringSchema = stringSchema.check(z.emoji());
|
|
14829
|
-
} else if (
|
|
15223
|
+
} else if (format2 === "nanoid") {
|
|
14830
15224
|
stringSchema = stringSchema.check(z.nanoid());
|
|
14831
|
-
} else if (
|
|
15225
|
+
} else if (format2 === "cuid") {
|
|
14832
15226
|
stringSchema = stringSchema.check(z.cuid());
|
|
14833
|
-
} else if (
|
|
15227
|
+
} else if (format2 === "cuid2") {
|
|
14834
15228
|
stringSchema = stringSchema.check(z.cuid2());
|
|
14835
|
-
} else if (
|
|
15229
|
+
} else if (format2 === "ulid") {
|
|
14836
15230
|
stringSchema = stringSchema.check(z.ulid());
|
|
14837
|
-
} else if (
|
|
15231
|
+
} else if (format2 === "xid") {
|
|
14838
15232
|
stringSchema = stringSchema.check(z.xid());
|
|
14839
|
-
} else if (
|
|
15233
|
+
} else if (format2 === "ksuid") {
|
|
14840
15234
|
stringSchema = stringSchema.check(z.ksuid());
|
|
14841
15235
|
}
|
|
14842
15236
|
}
|
|
@@ -15279,6 +15673,8 @@ var ActivityCompletedInput = exports_external.object({
|
|
|
15279
15673
|
metricsId: exports_external.string().optional(),
|
|
15280
15674
|
id: exports_external.string().optional(),
|
|
15281
15675
|
extensions: exports_external.record(exports_external.string(), exports_external.unknown()).optional(),
|
|
15676
|
+
edApp: exports_external.union([exports_external.string(), exports_external.record(exports_external.string(), exports_external.unknown())]).optional(),
|
|
15677
|
+
session: exports_external.union([exports_external.string(), exports_external.record(exports_external.string(), exports_external.unknown())]).optional(),
|
|
15282
15678
|
attempt: exports_external.number().int().min(1).optional(),
|
|
15283
15679
|
generatedExtensions: exports_external.object({
|
|
15284
15680
|
pctCompleteApp: exports_external.number().optional()
|
|
@@ -15291,7 +15687,9 @@ var TimeSpentInput = exports_external.object({
|
|
|
15291
15687
|
eventTime: IsoDateTimeString.optional(),
|
|
15292
15688
|
metricsId: exports_external.string().optional(),
|
|
15293
15689
|
id: exports_external.string().optional(),
|
|
15294
|
-
extensions: exports_external.record(exports_external.string(), exports_external.unknown()).optional()
|
|
15690
|
+
extensions: exports_external.record(exports_external.string(), exports_external.unknown()).optional(),
|
|
15691
|
+
edApp: exports_external.union([exports_external.string(), exports_external.record(exports_external.string(), exports_external.unknown())]).optional(),
|
|
15692
|
+
session: exports_external.union([exports_external.string(), exports_external.record(exports_external.string(), exports_external.unknown())]).optional()
|
|
15295
15693
|
}).strict();
|
|
15296
15694
|
var TimebackEvent = exports_external.union([TimebackActivityEvent, TimebackTimeSpentEvent]);
|
|
15297
15695
|
var CaliperEnvelope = exports_external.object({
|
|
@@ -15481,7 +15879,7 @@ var TimebackConfig = exports_external.object({
|
|
|
15481
15879
|
path: ["courses"]
|
|
15482
15880
|
});
|
|
15483
15881
|
// ../../types/src/zod/edubridge.ts
|
|
15484
|
-
var EdubridgeDateString = IsoDateTimeString;
|
|
15882
|
+
var EdubridgeDateString = exports_external.union([IsoDateTimeString, IsoDateString]);
|
|
15485
15883
|
var EduBridgeEnrollment = exports_external.object({
|
|
15486
15884
|
id: exports_external.string(),
|
|
15487
15885
|
role: exports_external.string(),
|
|
@@ -16500,7 +16898,7 @@ class Paginator2 extends Paginator {
|
|
|
16500
16898
|
params: requestParams,
|
|
16501
16899
|
max,
|
|
16502
16900
|
unwrapKey,
|
|
16503
|
-
logger:
|
|
16901
|
+
logger: log3,
|
|
16504
16902
|
transform: transform2
|
|
16505
16903
|
});
|
|
16506
16904
|
}
|
|
@@ -17800,7 +18198,7 @@ function createOneRosterClient(registry2 = DEFAULT_PROVIDER_REGISTRY) {
|
|
|
17800
18198
|
const resolved = resolveToProvider2(config3, registry2);
|
|
17801
18199
|
if (resolved.mode === "transport") {
|
|
17802
18200
|
this.transport = resolved.transport;
|
|
17803
|
-
|
|
18201
|
+
log3.info("Client initialized with custom transport");
|
|
17804
18202
|
} else {
|
|
17805
18203
|
const { provider } = resolved;
|
|
17806
18204
|
const { baseUrl, paths } = provider.getEndpointWithPaths("oneroster");
|
|
@@ -17815,7 +18213,7 @@ function createOneRosterClient(registry2 = DEFAULT_PROVIDER_REGISTRY) {
|
|
|
17815
18213
|
timeout: provider.timeout,
|
|
17816
18214
|
paths
|
|
17817
18215
|
});
|
|
17818
|
-
|
|
18216
|
+
log3.info("Client initialized", {
|
|
17819
18217
|
platform: provider.platform,
|
|
17820
18218
|
env: provider.env,
|
|
17821
18219
|
baseUrl
|