diff --git a/__tests__/__snapshots__/index.test.js.snap b/__tests__/__snapshots__/index.test.js.snap index 5497374..5a043bd 100644 --- a/__tests__/__snapshots__/index.test.js.snap +++ b/__tests__/__snapshots__/index.test.js.snap @@ -36,4 +36,4 @@ exports[`should method login catch error with empty sessionId 1`] = `"Failed to exports[`should method login catch error with result has code 1`] = `"Login returned error code: 500"`; -exports[`should method login catch error with result null 1`] = `"Failed to login. {\\"result\\":null}"`; +exports[`should method login catch error with result null 1`] = `"Failed to login. {\"result\":null}"`; diff --git a/dist/webuntis.d.ts b/dist/webuntis.d.ts index 79e85fd..c51675b 100644 --- a/dist/webuntis.d.ts +++ b/dist/webuntis.d.ts @@ -676,4 +676,4 @@ declare class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin { login(): Promise; } -export { Absence, Absences, Authenticator, Base, CodesEntity, ColorEntity, Department, Exam, Excuse, Holiday, Homework, Inbox, Inboxmessage, InternalWebuntisSecretLogin, Klasse, Lesson, LsEntity, MessagesOfDay, Messagesender, NewsWidget, Room, SchoolYear, ShortData, StatusData, Student, Subject, Teacher, TimeUnit, Timegrid, URLClass, WebAPITimetable, WebElement, WebElementData, Base as WebUntis, WebUntisAnonymousAuth, WebUntisDay, WebUntisElementType, WebUntisQR, WebUntisSecretAuth }; +export { type Absence, type Absences, type Authenticator, Base, type CodesEntity, type ColorEntity, type Department, type Exam, type Excuse, type Holiday, type Homework, type Inbox, type Inboxmessage, InternalWebuntisSecretLogin, type Klasse, type Lesson, type LsEntity, type MessagesOfDay, type Messagesender, type NewsWidget, type Room, type SchoolYear, type ShortData, type StatusData, type Student, type Subject, type Teacher, type TimeUnit, type Timegrid, type URLClass, type WebAPITimetable, type WebElement, type WebElementData, Base as WebUntis, WebUntisAnonymousAuth, WebUntisDay, WebUntisElementType, WebUntisQR, WebUntisSecretAuth }; diff --git a/dist/webuntis.js b/dist/webuntis.js index 3185590..1d0928a 100644 --- a/dist/webuntis.js +++ b/dist/webuntis.js @@ -88,19 +88,34 @@ var WebUntisElementType = /* @__PURE__ */ ((WebUntisElementType2) => { return WebUntisElementType2; })(WebUntisElementType || {}); -class Base { - school; - schoolbase64; - username; - password; - baseurl; - cookies; - id; - sessionInformation; - anonymous; - axios; - static TYPES = WebUntisElementType; +var __defProp$1 = Object.defineProperty; +var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; +var __publicField$1 = (obj, key, value) => { + __defNormalProp$1(obj, typeof key !== "symbol" ? key + "" : key, value); + return value; +}; +const _Base = class _Base { + /** + * + * @constructor + * @param {string} school The school identifier + * @param {string} username + * @param {string} password + * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com) + * @param {string} [identity="Awesome"] A identity like: MyAwesomeApp + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(school, username, password, baseurl, identity = "Awesome", disableUserAgent = false) { + __publicField$1(this, "school"); + __publicField$1(this, "schoolbase64"); + __publicField$1(this, "username"); + __publicField$1(this, "password"); + __publicField$1(this, "baseurl"); + __publicField$1(this, "cookies"); + __publicField$1(this, "id"); + __publicField$1(this, "sessionInformation"); + __publicField$1(this, "anonymous"); + __publicField$1(this, "axios"); this.school = school; this.schoolbase64 = "_" + btoa(this.school); this.username = username; @@ -128,6 +143,9 @@ class Base { } }); } + /** + * Logout the current session + */ async logout() { await this.axios({ method: "POST", @@ -145,6 +163,14 @@ class Base { this.sessionInformation = null; return true; } + /** + * Login with your credentials + * + * **Notice: The server may revoke this session after less than 10min of idle.** + * + * *Untis says in the official docs:* + * > An application should always log out as soon as possible to free system resources on the server. + */ async login() { const response = await this.axios({ method: "POST", @@ -174,11 +200,15 @@ class Base { this.sessionInformation = response.data.result; return response.data.result; } + /** + * Get the latest WebUntis Schoolyear + * @param {Boolean} [validateSession=true] + */ async getLatestSchoolyear(validateSession = true) { const data = await this._request("getSchoolyears", {}, validateSession); data.sort((a, b) => { - const na = dateFns.parse(a.startDate, "yyyyMMdd", new Date()); - const nb = dateFns.parse(b.startDate, "yyyyMMdd", new Date()); + const na = dateFns.parse(a.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); + const nb = dateFns.parse(b.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); return nb.getTime() - na.getTime(); }); if (!data[0]) @@ -186,15 +216,19 @@ class Base { return { name: data[0].name, id: data[0].id, - startDate: dateFns.parse(data[0].startDate, "yyyyMMdd", new Date()), - endDate: dateFns.parse(data[0].endDate, "yyyyMMdd", new Date()) + startDate: dateFns.parse(data[0].startDate, "yyyyMMdd", /* @__PURE__ */ new Date()), + endDate: dateFns.parse(data[0].endDate, "yyyyMMdd", /* @__PURE__ */ new Date()) }; } + /** + * Get all WebUntis Schoolyears + * @param {Boolean} [validateSession=true] + */ async getSchoolyears(validateSession = true) { const data = await this._request("getSchoolyears", {}, validateSession); data.sort((a, b) => { - const na = dateFns.parse(a.startDate, "yyyyMMdd", new Date()); - const nb = dateFns.parse(b.startDate, "yyyyMMdd", new Date()); + const na = dateFns.parse(a.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); + const nb = dateFns.parse(b.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); return nb.getTime() - na.getTime(); }); if (!data[0]) @@ -203,11 +237,17 @@ class Base { return { name: year.name, id: year.id, - startDate: dateFns.parse(year.startDate, "yyyyMMdd", new Date()), - endDate: dateFns.parse(year.endDate, "yyyyMMdd", new Date()) + startDate: dateFns.parse(year.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()), + endDate: dateFns.parse(year.endDate, "yyyyMMdd", /* @__PURE__ */ new Date()) }; }); } + /** + * Get News Widget + * @param {Date} date + * @param {boolean} [validateSession=true] + * @returns {Promise} see index.d.ts NewsWidget + */ async getNewsWidget(date, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -215,7 +255,7 @@ class Base { method: "GET", url: `/WebUntis/api/public/news/newsWidgetData`, params: { - date: Base.convertDateToUntis(date) + date: _Base.convertDateToUntis(date) }, headers: { Cookie: this._buildCookies() @@ -225,6 +265,9 @@ class Base { throw new Error("Server returned invalid data."); return response.data.data; } + /** + * Get Inbox + */ async getInbox(validateSession = true) { this._checkAnonymous(); if (validateSession && !await this.validateSession()) @@ -248,12 +291,21 @@ class Base { throw new Error("This method is not supported with anonymous login"); } } + /** + * + * @returns {string} + * @private + */ _buildCookies() { let cookies = []; cookies.push(serialize("JSESSIONID", this.sessionInformation.sessionId)); cookies.push(serialize("schoolname", this.schoolbase64)); return cookies.join("; "); } + /** + * Get JWT Token + * @private + */ async _getJWT(validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -261,6 +313,7 @@ class Base { method: "GET", url: `/WebUntis/api/token/new`, headers: { + //Authorization: `Bearer ${this._getToken()}`, Cookie: this._buildCookies() } }); @@ -269,6 +322,9 @@ class Base { this.sessionInformation.jwt_token = response.data; return response.data; } + /** + * Checks if your current WebUntis Session is valid + */ async validateSession() { if (!this.sessionInformation) return false; @@ -290,22 +346,35 @@ class Base { }); return typeof response.data.result === "number"; } + /** + * Get the time when WebUntis last changed its data + * @param {Boolean} [validateSession=true] + */ async getLatestImportTime(validateSession = true) { return this._request("getLatestImportTime", {}, validateSession); } + /** + * + * @param id + * @param type + * @param startDate + * @param endDate + * @param validateSession + * @private + */ async _timetableRequest(id, type, startDate, endDate, validateSession = true) { const additionalOptions = {}; if (startDate) { - additionalOptions.startDate = Base.convertDateToUntis(startDate); + additionalOptions.startDate = _Base.convertDateToUntis(startDate); } if (endDate) { - additionalOptions.endDate = Base.convertDateToUntis(endDate); + additionalOptions.endDate = _Base.convertDateToUntis(endDate); } return this._request( "getTimetable", { options: { - id: new Date().getTime(), + id: (/* @__PURE__ */ new Date()).getTime(), element: { id, type @@ -326,6 +395,12 @@ class Base { validateSession ); } + /** + * Get your own Timetable for the current day + * Note: You can't use this with anonymous login + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getOwnTimetableForToday(validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -336,9 +411,22 @@ class Base { validateSession ); } + /** + * Get the timetable of today for a specific element. + * @param {number} id + * @param {WebUntisElementType} type + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getTimetableForToday(id, type, validateSession = true) { return await this._timetableRequest(id, type, null, null, validateSession); } + /** + * Get your own Timetable for the given day + * Note: You can't use this with anonymous login + * @param {Date} date + * @param {Boolean} [validateSession=true] + */ async getOwnTimetableFor(date, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -349,9 +437,24 @@ class Base { validateSession ); } + /** + * Get the timetable for a specific day for a specific element. + * @param {Date} date + * @param {number} id + * @param {WebUntisElementType} type + * @param {Boolean} [validateSession=true] + */ async getTimetableFor(date, id, type, validateSession = true) { return await this._timetableRequest(id, type, date, date, validateSession); } + /** + * Get your own timetable for a given Date range + * Note: You can't use this with anonymous login + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {Boolean} [validateSession=true] + * @returns {Promise.} + */ async getOwnTimetableForRange(rangeStart, rangeEnd, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -362,17 +465,45 @@ class Base { validateSession ); } + /** + * Get the timetable for a given Date range for specific element + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {number} id + * @param {WebUntisElementType} type + * @param {Boolean} [validateSession=true] + */ async getTimetableForRange(rangeStart, rangeEnd, id, type, validateSession = true) { return await this._timetableRequest(id, type, rangeStart, rangeEnd, validateSession); } + /** + * Get the Timetable of your class for today + * Note: You can't use this with anonymous login + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getOwnClassTimetableForToday(validateSession = true) { this._checkAnonymous(); return await this._timetableRequest(this.sessionInformation.klasseId, 1, null, null, validateSession); } + /** + * Get the Timetable of your class for the given day + * Note: You can't use this with anonymous login + * @param {Date} date + * @param {Boolean} [validateSession=true] + * @returns {Promise.} + */ async getOwnClassTimetableFor(date, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest(this.sessionInformation.klasseId, 1, date, date, validateSession); } + /** + * Get the Timetable of your class for a given Date range + * Note: You can't use this with anonymous login + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + */ async getOwnClassTimetableForRange(rangeStart, rangeEnd, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -383,6 +514,13 @@ class Base { validateSession ); } + /** + * + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getHomeWorksFor(rangeStart, rangeEnd, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -390,8 +528,8 @@ class Base { method: "GET", url: `/WebUntis/api/homeworks/lessons`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd) + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd) }, headers: { Cookie: this._buildCookies() @@ -403,22 +541,51 @@ class Base { throw new Error("Data object doesn't contains homeworks object."); return response.data.data; } - static convertUntisDate(date, baseDate = dateFns.startOfDay(new Date())) { + /** + * Converts the untis date string format to a normal JS Date object + * @param {string} date Untis date string + * @param {Date} [baseDate=new Date()] Base date. Default beginning of current day + * @static + */ + static convertUntisDate(date, baseDate = dateFns.startOfDay(/* @__PURE__ */ new Date())) { if (typeof date !== "string") date = `${date}`; return dateFns.parse(date, "yyyyMMdd", baseDate); } - static convertUntisTime(time, baseDate = new Date()) { + /** + * Convert a untis time string to a JS Date object + * @param {string|number} time Untis time string + * @param {Date} [baseDate=new Date()] Day used as base for the time. Default: Current date + * @static + */ + static convertUntisTime(time, baseDate = /* @__PURE__ */ new Date()) { if (typeof time !== "string") time = `${time}`; return dateFns.parse(time.padStart(4, "0"), "Hmm", baseDate); } + /** + * Get all known Subjects for the current logged-in user + * @param {boolean} [validateSession=true] + */ async getSubjects(validateSession = true) { return await this._request("getSubjects", {}, validateSession); } + /** + * Get the timegrid of current school + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getTimegrid(validateSession = true) { return await this._request("getTimegridUnits", {}, validateSession); } + /** + * + * TODO: Find out what type this function returns + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getHomeWorkAndLessons(rangeStart, rangeEnd, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -426,8 +593,8 @@ class Base { method: "GET", url: `/WebUntis/api/homeworks/lessons`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd) + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd) }, headers: { Cookie: this._buildCookies() @@ -439,6 +606,14 @@ class Base { throw new Error("Data object doesn't contains homeworks object."); return response.data.data; } + /** + * Get Exams for range + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {Number} klasseId + * @param {boolean} withGrades + * @param {boolean} [validateSession=true] + */ async getExamsForRange(rangeStart, rangeEnd, klasseId = -1, withGrades = false, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -446,8 +621,8 @@ class Base { method: "GET", url: `/WebUntis/api/exams`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd), + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd), klasseId, withGrades }, @@ -461,6 +636,14 @@ class Base { throw new Error("Data object doesn't contains exams object."); return response.data.data["exams"]; } + /** + * Get the timetable for the current week for a specific element from the web client API. + * @param {Date} date one date in the week to query + * @param {number} id element id + * @param {WebUntisElementType} type element type + * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response + * @param {Boolean} [validateSession=true] + */ async getTimetableForWeek(date, id, type, formatId = 1, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -498,14 +681,21 @@ class Base { }; const timetable = data.elementPeriods[id].map((lesson) => ({ ...lesson, - classes: formatElements(lesson.elements, { byType: Base.TYPES.CLASS }), - teachers: formatElements(lesson.elements, { byType: Base.TYPES.TEACHER }), - subjects: formatElements(lesson.elements, { byType: Base.TYPES.SUBJECT }), - rooms: formatElements(lesson.elements, { byType: Base.TYPES.ROOM }), - students: formatElements(lesson.elements, { byType: Base.TYPES.STUDENT }) + classes: formatElements(lesson.elements, { byType: _Base.TYPES.CLASS }), + teachers: formatElements(lesson.elements, { byType: _Base.TYPES.TEACHER }), + subjects: formatElements(lesson.elements, { byType: _Base.TYPES.SUBJECT }), + rooms: formatElements(lesson.elements, { byType: _Base.TYPES.ROOM }), + students: formatElements(lesson.elements, { byType: _Base.TYPES.STUDENT }) })); return timetable; } + /** + * Get the timetable for the current week for the current element from the web client API. + * @param {Date} date one date in the week to query + * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getOwnTimetableForWeek(date, formatId = 1, validateSession = true) { this._checkAnonymous(); return await this.getTimetableForWeek( @@ -516,31 +706,81 @@ class Base { validateSession ); } + /** + * Get all known teachers by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getTeachers(validateSession = true) { return await this._request("getTeachers", {}, validateSession); } + /** + * Get all known students by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getStudents(validateSession = true) { return await this._request("getStudents", {}, validateSession); } + /** + * Get all known rooms by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getRooms(validateSession = true) { return await this._request("getRooms", {}, validateSession); } + /** + * Get all classes known by WebUntis + * @param {boolean} [validateSession=true] + * @param {number} schoolyearId + * @returns {Promise.} + */ async getClasses(validateSession = true, schoolyearId) { const data = typeof schoolyearId !== "number" ? {} : { schoolyearId }; return await this._request("getKlassen", data, validateSession); } + /** + * Get all departments known by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getDepartments(validateSession = true) { return await this._request("getDepartments", {}, validateSession); } + /** + * Get all holidays known by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getHolidays(validateSession = true) { return await this._request("getHolidays", {}, validateSession); } + /** + * Get all status data known by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getStatusData(validateSession = true) { return await this._request("getStatusData", {}, validateSession); } + /** + * Convert a JS Date Object to a WebUntis date string + * @param {Date} date + * @returns {String} + */ static convertDateToUntis(date) { return date.getFullYear().toString() + (date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1).toString() + (date.getDate() < 10 ? "0" + date.getDate() : date.getDate()).toString(); } + /** + * Make a JSON RPC Request with the current session + * @param {string} method + * @param {Object} [parameter={}] + * @param {string} [url='/WebUntis/jsonrpc.do?school=SCHOOL'] + * @param {boolean} [validateSession=true] Whether the session should be checked first + * @returns {Promise.} + * @private + */ async _request(method, parameter = {}, validateSession = true, url = `/WebUntis/jsonrpc.do`) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -566,6 +806,14 @@ class Base { throw new Error("Server returned error code: " + response.data.result.code); return response.data.result; } + /** + * Returns all the Lessons where you were absent including the excused one! + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {Integer} [excuseStatusId=-1] + * @param {boolean} [validateSession=true] + * @returns {Promise} + */ async getAbsentLesson(rangeStart, rangeEnd, excuseStatusId = -1, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -574,8 +822,8 @@ class Base { method: "GET", url: `/WebUntis/api/classreg/absences/students`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd), + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd), studentId: this.sessionInformation.personId, excuseStatusId }, @@ -587,6 +835,16 @@ class Base { throw new Error("Server returned no data!"); return response.data.data; } + /** + * Returns a URL to a unique PDF of all the lessons you were absent + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + * @param {Integer} [excuseStatusId=-1] + * @param {boolean} [lateness=true] + * @param {boolean} [absences=true] + * @param {boolean} [excuseGroup=2] + */ async getPdfOfAbsentLesson(rangeStart, rangeEnd, validateSession = true, excuseStatusId = -1, lateness = true, absences = true, excuseGroup = 2) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -597,8 +855,8 @@ class Base { params: { name: "Excuse", format: "pdf", - rpt_sd: Base.convertDateToUntis(rangeStart), - rpt_ed: Base.convertDateToUntis(rangeEnd), + rpt_sd: _Base.convertDateToUntis(rangeStart), + rpt_ed: _Base.convertDateToUntis(rangeEnd), excuseStatusId, studentId: this.sessionInformation.personId, withLateness: lateness, @@ -615,7 +873,9 @@ class Base { const pdfDownloadURL = this.baseurl + "WebUntis/reports.do?msgId=" + res.messageId + "&" + res.reportParams; return pdfDownloadURL; } -} +}; +__publicField$1(_Base, "TYPES", WebUntisElementType); +let Base = _Base; class InternalWebuntisSecretLogin extends Base { constructor(school, username, password, baseurl, identity = "Awesome", disableUserAgent = false) { super(school, username, password, baseurl, identity, disableUserAgent); @@ -706,6 +966,13 @@ class InternalWebuntisSecretLogin extends Base { } return this.sessionInformation; } + /** + * + * @param {Array} setCookieArray + * @param {string} [cookieName="JSESSIONID"] + * @return {string|boolean} + * @private + */ _getCookieFromSetCookie(setCookieArray, cookieName = "JSESSIONID") { if (!setCookieArray) return; @@ -729,11 +996,29 @@ class InternalWebuntisSecretLogin extends Base { } } +var __defProp = Object.defineProperty; +var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; +var __publicField = (obj, key, value) => { + __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value); + return value; +}; class WebUntisSecretAuth extends InternalWebuntisSecretLogin { - secret; - authenticator; + /** + * + * @constructor + * @augments WebUntis + * @param {string} school The school identifier + * @param {string} user + * @param {string} secret + * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com) + * @param {string} [identity="Awesome"] A identity like: MyAwesomeApp + * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration. + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(school, user, secret, baseurl, identity = "Awesome", authenticator, disableUserAgent = false) { super(school, user, null, baseurl, identity, disableUserAgent); + __publicField(this, "secret"); + __publicField(this, "authenticator"); this.secret = secret; this.authenticator = authenticator; if (!authenticator) { @@ -746,14 +1031,24 @@ class WebUntisSecretAuth extends InternalWebuntisSecretLogin { this.authenticator = authenticator; } } + // @ts-ignore async login() { const token = this.authenticator.generate(this.secret); - const time = new Date().getTime(); + const time = (/* @__PURE__ */ new Date()).getTime(); return await this._otpLogin(token, this.username, time); } } class WebUntisQR extends WebUntisSecretAuth { + /** + * Use the data you get from a WebUntis QR code + * @constructor + * @param {string} QRCodeURI A WebUntis uri. This is the data you get from the QR Code from the webuntis webapp under profile->Data access->Display + * @param {string} [identity="Awesome"] A identity like: MyAwesomeApp + * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration. + * @param {Object} URL Custom whatwg url implementation. Default will use the nodejs implementation. + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(QRCodeURI, identity, authenticator, URL, disableUserAgent = false) { let URLImplementation = URL; if (!URL) { @@ -778,6 +1073,13 @@ class WebUntisQR extends WebUntisSecretAuth { } class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin { + /** + * + * @param {string} school + * @param {string} baseurl + * @param {string} [identity='Awesome'] + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(school, baseurl, identity = "Awesome", disableUserAgent = false) { super(school, null, null, baseurl, identity, disableUserAgent); this.username = "#anonymous#"; @@ -808,7 +1110,7 @@ class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin { if (response.data && response.data.error) throw new Error("Failed to login. " + (response.data.error.message || "")); const otp = 100170; - const time = new Date().getTime(); + const time = (/* @__PURE__ */ new Date()).getTime(); return await this._otpLogin(otp, this.username, time, true); } } diff --git a/dist/webuntis.js.map b/dist/webuntis.js.map index eda780e..38a6925 100644 --- a/dist/webuntis.js.map +++ b/dist/webuntis.js.map @@ -1 +1 @@ -{"version":3,"file":"webuntis.js","sources":["../src/cookie.ts","../src/base-64.ts","../src/types.ts","../src/base.ts","../src/secret.ts","../src/qr.ts","../src/anonymous.ts"],"sourcesContent":["/**\n * Shamelessly stolen from @tinyhttp/cookie.\n *\n * Because @tinyhttp/cookie doesn't provide a commonjs build, I just decided to include the source code.\n * We need a cjs build, because we generate both esm and cjs.\n */\n\nconst pairSplitRegExp = /; */;\n\n/**\n * RegExp to match field-content in RFC 7230 sec 3.2\n *\n * field-content = field-vchar [ 1*( SP / HTAB ) field-vchar ]\n * field-vchar = VCHAR / obs-text\n * obs-text = %x80-FF\n */\n\n// eslint-disable-next-line no-control-regex\nconst fieldContentRegExp = /^[\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+$/;\n\nfunction tryDecode(str: string, decode: (str: string) => string) {\n try {\n return decode(str);\n } catch (e) {\n return str;\n }\n}\n\n/**\n * Parse a cookie header.\n *\n * Parse the given cookie header string into an object\n * The object has the various cookies as keys(names) => values\n *\n */\nexport function parse(\n str: string,\n options: {\n decode: (str: string) => string;\n } = {\n decode: decodeURIComponent,\n }\n): Record {\n const obj: Record = {};\n const pairs = str.split(pairSplitRegExp);\n\n for (const pair of pairs) {\n let eqIdx = pair.indexOf('=');\n\n // skip things that don't look like key=value\n if (eqIdx < 0) continue;\n\n const key = pair.substr(0, eqIdx).trim();\n let val = pair.substr(++eqIdx, pair.length).trim();\n\n // quoted values\n if ('\"' == val[0]) val = val.slice(1, -1);\n\n // only assign once\n if (obj[key] == null) obj[key] = tryDecode(val, options.decode);\n }\n\n return obj;\n}\n\nexport type SerializeOptions = Partial<{\n encode: (str: string) => string;\n maxAge: number;\n domain: string;\n path: string;\n httpOnly: boolean;\n secure: boolean;\n sameSite: boolean | 'Strict' | 'strict' | 'Lax' | 'lax' | 'None' | 'none' | string;\n expires: Date;\n}>;\n\nexport function serialize(name: string, val: string, opt: SerializeOptions = {}): string {\n if (!opt.encode) opt.encode = encodeURIComponent;\n\n if (!fieldContentRegExp.test(name)) throw new TypeError('argument name is invalid');\n\n const value = opt.encode(val);\n\n if (value && !fieldContentRegExp.test(value)) throw new TypeError('argument val is invalid');\n\n let str = name + '=' + value;\n\n if (null != opt.maxAge) {\n const maxAge = opt.maxAge - 0;\n\n if (isNaN(maxAge) || !isFinite(maxAge)) throw new TypeError('option maxAge is invalid');\n\n str += '; Max-Age=' + Math.floor(maxAge);\n }\n\n if (opt.domain) {\n if (!fieldContentRegExp.test(opt.domain)) throw new TypeError('option domain is invalid');\n\n str += '; Domain=' + opt.domain;\n }\n\n if (opt.path) {\n if (!fieldContentRegExp.test(opt.path)) throw new TypeError('option path is invalid');\n\n str += '; Path=' + opt.path;\n }\n\n if (opt.expires) str += '; Expires=' + opt.expires.toUTCString();\n\n if (opt.httpOnly) str += '; HttpOnly';\n\n if (opt.secure) str += '; Secure';\n\n if (opt.sameSite) {\n const sameSite = typeof opt.sameSite === 'string' ? opt.sameSite.toLowerCase() : opt.sameSite;\n\n switch (sameSite) {\n case true:\n case 'strict':\n str += '; SameSite=Strict';\n break;\n case 'lax':\n str += '; SameSite=Lax';\n break;\n case 'none':\n str += '; SameSite=None';\n break;\n default:\n throw new TypeError('option sameSite is invalid');\n }\n }\n\n return str;\n}\n","const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\nexport function btoa(input = '') {\n let str = input;\n let output = '';\n\n for (\n let block = 0, charCode, i = 0, map = chars;\n str.charAt(i | 0) || ((map = '='), i % 1);\n output += map.charAt(63 & (block >> (8 - (i % 1) * 8)))\n ) {\n charCode = str.charCodeAt((i += 3 / 4));\n\n if (charCode > 0xff) {\n throw new Error(\"'btoa' failed: The string to be encoded contains characters outside of the Latin1 range.\");\n }\n\n block = (block << 8) | charCode;\n }\n\n return output;\n}\n","export interface SchoolYear {\n name: string;\n id: number;\n startDate: Date;\n endDate: Date;\n}\n\nexport interface MessagesOfDay {\n id: number;\n subject: string;\n text: string;\n isExpanded: boolean;\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: any[];\n}\n\nexport interface NewsWidget {\n /**\n * Unknown type. I have never seen this in use.\n */\n systemMessage: any;\n messagesOfDay: MessagesOfDay[];\n rssUrl: string;\n}\n\nexport interface Messagesender {\n userId: number;\n displayName: string;\n imageUrl: string;\n className: string;\n}\n\nexport interface Inboxmessage {\n allowMessageDeletion: boolean;\n contentPreview: string;\n hasAttachments: boolean;\n id: number;\n isMessageRead: boolean;\n isReply: boolean;\n isReplyAllowed: boolean;\n sender: Messagesender;\n sentDateTime: string;\n subject: string;\n}\n\nexport interface Inbox {\n incomingMessages: Inboxmessage[];\n}\n\nexport interface ShortData {\n id: number;\n name: string;\n longname: string;\n orgname?: string;\n orgid?: number;\n}\n\nexport interface Lesson {\n id: number;\n date: number;\n startTime: number;\n endTime: number;\n kl: ShortData[];\n te: ShortData[];\n su: ShortData[];\n ro: ShortData[];\n lstext?: string;\n lsnumber: number;\n activityType?: 'Unterricht' | string;\n code?: 'cancelled' | 'irregular';\n info?: string;\n substText?: string;\n statflags?: string;\n sg?: string;\n bkRemark?: string;\n bkText?: string;\n}\n\nexport interface Homework {\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: Array;\n completed: boolean;\n date: number;\n dueDate: number;\n id: number;\n lessonId: number;\n remark: string;\n text: string;\n}\n\nexport interface Subject {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport enum WebUntisDay {\n Sunday = 1,\n Monday = 2,\n Tuesday = 3,\n Wednesday = 4,\n Thursday = 5,\n Friday = 6,\n Saturday = 7,\n}\n\nexport interface TimeUnit {\n name: string;\n startTime: number;\n endTime: number;\n}\n\nexport interface Timegrid {\n day: WebUntisDay;\n timeUnits: TimeUnit[];\n}\n\nexport interface Exam {\n id: number;\n examType: string;\n name: string;\n studentClass: string[];\n assignedStudents: {\n klasse: { id: number; name: string };\n displayName: string;\n id: number;\n }[];\n examDate: number;\n startTime: number;\n endTime: number;\n subject: string;\n teachers: string[];\n rooms: string[];\n text: string;\n grade?: string;\n}\n\nexport enum WebUntisElementType {\n CLASS = 1,\n TEACHER = 2,\n SUBJECT = 3,\n ROOM = 4,\n STUDENT = 5,\n}\n\nexport interface WebElement {\n type: WebUntisElementType;\n id: number;\n orgId: number;\n missing: boolean;\n state: 'REGULAR' | 'ABSENT' | 'SUBSTITUTED';\n}\n\nexport interface WebElementData extends WebElement {\n element: {\n type: number;\n id: number;\n name: string;\n longName?: string;\n displayname?: string;\n alternatename?: string;\n canViewTimetable: boolean;\n externalKey?: string;\n roomCapacity: number;\n };\n}\n\nexport interface WebAPITimetable {\n id: number;\n lessonId: number;\n lessonNumber: number;\n lessonCode: string;\n lessonText: string;\n periodText: string;\n hasPeriodText: false;\n periodInfo: string;\n periodAttachments: [];\n substText: string;\n date: number;\n startTime: number;\n endTime: number;\n elements: WebElement[];\n studentGroup: string;\n hasInfo: boolean;\n code: number;\n cellState: 'STANDARD' | 'SUBSTITUTION' | 'ROOMSUBSTITUTION';\n priority: number;\n is: {\n roomSubstitution?: boolean;\n substitution?: boolean;\n standard?: boolean;\n event: boolean;\n };\n roomCapacity: number;\n studentCount: number;\n classes: WebElementData[];\n teachers: WebElementData[];\n subjects: WebElementData[];\n rooms: WebElementData[];\n students: WebElementData[];\n}\n\nexport interface Teacher {\n id: number;\n name: string;\n foreName: string;\n longName: string;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Student {\n id: number;\n key: number;\n name: string;\n foreName: string;\n longName: string;\n gender: string;\n}\n\nexport interface Room {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Klasse {\n id: number;\n name: string;\n longName: string;\n active: boolean;\n}\n\nexport interface Department {\n id: number;\n name: string;\n longName: string;\n}\n\nexport interface Holiday {\n name: string;\n longName: string;\n id: number;\n startDate: number;\n endDate: number;\n}\n\nexport interface ColorEntity {\n foreColor: string;\n backColor: string;\n}\n\nexport interface LsEntity {\n ls?: ColorEntity | null;\n oh?: ColorEntity | null;\n sb?: ColorEntity | null;\n bs?: ColorEntity | null;\n ex?: ColorEntity | null;\n}\n\nexport interface CodesEntity {\n cancelled?: ColorEntity | null;\n irregular?: ColorEntity | null;\n}\n\nexport interface StatusData {\n lstypes: LsEntity[];\n codes: CodesEntity[];\n}\n\nexport interface Absences {\n absences: Absence[];\n absenceReasons: [];\n excuseStatuses: boolean;\n showAbsenceReasonChange: boolean;\n showCreateAbsence: boolean;\n}\n\nexport interface Absence {\n id: number;\n startDate: number;\n endDate: number;\n startTime: number;\n endTime: number;\n createDate: number;\n lastUpdate: number;\n createdUser: string;\n updatedUser: string;\n reasonId: number;\n reason: string;\n text: string;\n interruptions: [];\n canEdit: boolean;\n studentName: string;\n excuseStatus: string;\n isExcused: boolean;\n excuse: Excuse;\n}\n\nexport interface Excuse {\n id: number;\n text: string;\n excuseDate: number;\n excuseStatus: string;\n isExcused: boolean;\n userId: number;\n username: string;\n}\n","import { serialize } from './cookie';\nimport axios from 'axios';\nimport { btoa } from './base-64';\nimport { parse, startOfDay, format } from 'date-fns';\nimport type { AxiosInstance } from 'axios';\nimport type {\n Absences,\n Department,\n Exam,\n Holiday,\n Homework,\n Inbox,\n Klasse,\n Lesson,\n NewsWidget,\n Room,\n SchoolYear,\n StatusData,\n Student,\n Subject,\n Teacher,\n Timegrid,\n WebAPITimetable,\n} from './types';\nimport type { InternalSchoolYear, SessionInformation } from './internal';\nimport { WebUntisElementType } from './types';\n\nexport class Base {\n school: string;\n schoolbase64: string;\n username: string;\n password: string;\n baseurl: string;\n cookies: string[];\n id: string;\n sessionInformation: SessionInformation | null;\n anonymous: boolean;\n\n axios: AxiosInstance;\n\n static TYPES = WebUntisElementType;\n\n /**\n *\n * @constructor\n * @param {string} school The school identifier\n * @param {string} username\n * @param {string} password\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false\n ) {\n this.school = school;\n this.schoolbase64 = '_' + btoa(this.school);\n this.username = username;\n this.password = password;\n this.baseurl = 'https://' + baseurl + '/';\n this.cookies = [];\n this.id = identity;\n this.sessionInformation = {};\n this.anonymous = false;\n\n const additionalHeaders: Record = {};\n\n if (!disableUserAgent) {\n additionalHeaders['User-Agent'] =\n 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.79 Safari/537.36';\n }\n\n this.axios = axios.create({\n baseURL: this.baseurl,\n maxRedirects: 0,\n headers: {\n 'Cache-Control': 'no-cache',\n Pragma: 'no-cache',\n 'X-Requested-With': 'XMLHttpRequest',\n ...additionalHeaders,\n },\n validateStatus: function (status) {\n return status >= 200 && status < 303; // default\n },\n });\n }\n\n /**\n * Logout the current session\n */\n async logout(): Promise {\n await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'logout',\n params: {},\n jsonrpc: '2.0',\n },\n });\n this.sessionInformation = null;\n return true;\n }\n\n /**\n * Login with your credentials\n *\n * **Notice: The server may revoke this session after less than 10min of idle.**\n *\n * *Untis says in the official docs:*\n * > An application should always log out as soon as possible to free system resources on the server.\n */\n async login(): Promise {\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'authenticate',\n params: {\n user: this.username,\n password: this.password,\n client: this.id,\n },\n jsonrpc: '2.0',\n },\n });\n if (typeof response.data !== 'object') throw new Error('Failed to parse server response.');\n if (!response.data.result) throw new Error('Failed to login. ' + JSON.stringify(response.data));\n if (response.data.result.code) throw new Error('Login returned error code: ' + response.data.result.code);\n if (!response.data.result.sessionId) throw new Error('Failed to login. No session id.');\n this.sessionInformation = response.data.result;\n return response.data.result;\n }\n\n /**\n * Get the latest WebUntis Schoolyear\n * @param {Boolean} [validateSession=true]\n */\n async getLatestSchoolyear(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return {\n name: data[0].name,\n id: data[0].id,\n startDate: parse(data[0].startDate, 'yyyyMMdd', new Date()),\n endDate: parse(data[0].endDate, 'yyyyMMdd', new Date()),\n };\n }\n\n /**\n * Get all WebUntis Schoolyears\n * @param {Boolean} [validateSession=true]\n */\n async getSchoolyears(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return data.map((year) => {\n return {\n name: year.name,\n id: year.id,\n startDate: parse(year.startDate, 'yyyyMMdd', new Date()),\n endDate: parse(year.endDate, 'yyyyMMdd', new Date()),\n };\n });\n }\n\n /**\n * Get News Widget\n * @param {Date} date\n * @param {boolean} [validateSession=true]\n * @returns {Promise} see index.d.ts NewsWidget\n */\n async getNewsWidget(date: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/news/newsWidgetData`,\n params: {\n date: Base.convertDateToUntis(date),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data.data;\n }\n\n /**\n * Get Inbox\n */\n async getInbox(validateSession = true): Promise {\n this._checkAnonymous();\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n //first get JWT Token\n if (typeof this.sessionInformation!.jwt_token != 'string') await this._getJWT();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/rest/view/v1/messages`,\n headers: {\n Authorization: `Bearer ${this.sessionInformation!.jwt_token}`,\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data;\n }\n\n private _checkAnonymous() {\n if (this.anonymous) {\n throw new Error('This method is not supported with anonymous login');\n }\n }\n\n /**\n *\n * @returns {string}\n * @private\n */\n _buildCookies() {\n let cookies = [];\n cookies.push(serialize('JSESSIONID', this.sessionInformation!.sessionId!));\n cookies.push(serialize('schoolname', this.schoolbase64));\n return cookies.join('; ');\n }\n\n /**\n * Get JWT Token\n * @private\n */\n async _getJWT(validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/token/new`,\n headers: {\n //Authorization: `Bearer ${this._getToken()}`,\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data !== 'string') throw new Error('Server returned invalid data.');\n this.sessionInformation!.jwt_token = response.data;\n return response.data;\n }\n\n /**\n * Checks if your current WebUntis Session is valid\n */\n async validateSession(): Promise {\n if (!this.sessionInformation) return false;\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: 'getLatestImportTime',\n params: {},\n jsonrpc: '2.0',\n },\n });\n return typeof response.data.result === 'number';\n }\n\n /**\n * Get the time when WebUntis last changed its data\n * @param {Boolean} [validateSession=true]\n */\n async getLatestImportTime(validateSession = true): Promise {\n return this._request('getLatestImportTime', {}, validateSession);\n }\n\n /**\n *\n * @param id\n * @param type\n * @param startDate\n * @param endDate\n * @param validateSession\n * @private\n */\n private async _timetableRequest(\n id: string | number,\n type: number,\n startDate?: Date | null,\n endDate?: Date | null,\n validateSession = true\n ): Promise {\n const additionalOptions: Record = {};\n if (startDate) {\n additionalOptions.startDate = Base.convertDateToUntis(startDate);\n }\n if (endDate) {\n additionalOptions.endDate = Base.convertDateToUntis(endDate);\n }\n\n return this._request(\n 'getTimetable',\n {\n options: {\n id: new Date().getTime(),\n element: {\n id,\n type,\n },\n ...additionalOptions,\n showLsText: true,\n showStudentgroup: true,\n showLsNumber: true,\n showSubstText: true,\n showInfo: true,\n showBooking: true,\n klasseFields: ['id', 'name', 'longname', 'externalkey'],\n roomFields: ['id', 'name', 'longname', 'externalkey'],\n subjectFields: ['id', 'name', 'longname', 'externalkey'],\n teacherFields: ['id', 'name', 'longname', 'externalkey'],\n },\n },\n validateSession\n );\n }\n\n /**\n * Get your own Timetable for the current day\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n null,\n null,\n validateSession\n );\n }\n\n /**\n * Get the timetable of today for a specific element.\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getTimetableForToday(id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, null, null, validateSession);\n }\n\n /**\n * Get your own Timetable for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n */\n async getOwnTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n date,\n date,\n validateSession\n );\n }\n\n /**\n * Get the timetable for a specific day for a specific element.\n * @param {Date} date\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableFor(date: Date, id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, date, date, validateSession);\n }\n\n /**\n * Get your own timetable for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n rangeStart,\n rangeEnd,\n validateSession\n );\n }\n\n /**\n * Get the timetable for a given Date range for specific element\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForRange(\n rangeStart: Date,\n rangeEnd: Date,\n id: number,\n type: number,\n validateSession = true\n ): Promise {\n return await this._timetableRequest(id, type, rangeStart, rangeEnd, validateSession);\n }\n\n /**\n * Get the Timetable of your class for today\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnClassTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, null, null, validateSession);\n }\n\n /**\n * Get the Timetable of your class for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnClassTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, date, date, validateSession);\n }\n\n /**\n * Get the Timetable of your class for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n */\n async getOwnClassTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.klasseId!,\n 1,\n rangeStart,\n rangeEnd,\n validateSession\n );\n }\n\n /**\n *\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorksFor(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Converts the untis date string format to a normal JS Date object\n * @param {string} date Untis date string\n * @param {Date} [baseDate=new Date()] Base date. Default beginning of current day\n * @static\n */\n static convertUntisDate(date: string, baseDate = startOfDay(new Date())): Date {\n if (typeof date !== 'string') date = `${date}`;\n return parse(date, 'yyyyMMdd', baseDate);\n }\n\n /**\n * Convert a untis time string to a JS Date object\n * @param {string|number} time Untis time string\n * @param {Date} [baseDate=new Date()] Day used as base for the time. Default: Current date\n * @static\n */\n static convertUntisTime(time: number | string, baseDate = new Date()): Date {\n if (typeof time !== 'string') time = `${time}`;\n return parse(time.padStart(4, '0'), 'Hmm', baseDate);\n }\n\n /**\n * Get all known Subjects for the current logged-in user\n * @param {boolean} [validateSession=true]\n */\n async getSubjects(validateSession = true): Promise {\n return await this._request('getSubjects', {}, validateSession);\n }\n\n /**\n * Get the timegrid of current school\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTimegrid(validateSession = true): Promise {\n return await this._request('getTimegridUnits', {}, validateSession);\n }\n\n /**\n *\n * TODO: Find out what type this function returns\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorkAndLessons(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Get Exams for range\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Number} klasseId\n * @param {boolean} withGrades\n * @param {boolean} [validateSession=true]\n */\n async getExamsForRange(\n rangeStart: Date,\n rangeEnd: Date,\n klasseId = -1,\n withGrades = false,\n validateSession = true\n ): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/exams`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n klasseId: klasseId,\n withGrades: withGrades,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['exams']) throw new Error(\"Data object doesn't contains exams object.\");\n return response.data.data['exams'];\n }\n\n /**\n * Get the timetable for the current week for a specific element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {number} id element id\n * @param {WebUntisElementType} type element type\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForWeek(\n date: Date,\n id: number,\n type: number,\n formatId = 1,\n validateSession = true\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/timetable/weekly/data`,\n params: {\n elementType: type,\n elementId: id,\n date: format(date, 'yyyy-MM-dd'),\n formatId: formatId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n\n if (response.data.data.error) {\n /* known codes:\n * - ERR_TTVIEW_NOTALLOWED_ONDATE\n */\n const err = new Error('Server responded with error');\n // TODO: Make this better lol\n // @ts-ignore\n err.code = response.data.data.error?.data?.messageKey;\n throw err;\n }\n\n if (!response.data.data.result?.data?.elementPeriods?.[id]) throw new Error('Invalid response');\n\n const data = response.data.data.result.data;\n\n // TODO: improve typings\n\n const formatElements = (elements: Array>, { byType }: { byType: number }) => {\n const filteredElements = elements.filter((element) => element.type === byType);\n\n return filteredElements.map((element) => ({\n ...element,\n element: data.elements.find(\n (dataElement: Record) =>\n dataElement.type === byType && dataElement.id === element.id\n ),\n }));\n };\n\n const timetable = data.elementPeriods[id].map((lesson: any) => ({\n ...lesson,\n classes: formatElements(lesson.elements, { byType: Base.TYPES.CLASS }),\n teachers: formatElements(lesson.elements, { byType: Base.TYPES.TEACHER }),\n subjects: formatElements(lesson.elements, { byType: Base.TYPES.SUBJECT }),\n rooms: formatElements(lesson.elements, { byType: Base.TYPES.ROOM }),\n students: formatElements(lesson.elements, { byType: Base.TYPES.STUDENT }),\n }));\n\n return timetable;\n }\n\n /**\n * Get the timetable for the current week for the current element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForWeek(date: Date, formatId = 1, validateSession = true): Promise {\n this._checkAnonymous();\n return await this.getTimetableForWeek(\n date,\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n formatId,\n validateSession\n );\n }\n\n /**\n * Get all known teachers by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTeachers(validateSession = true): Promise {\n return await this._request('getTeachers', {}, validateSession);\n }\n\n /**\n * Get all known students by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStudents(validateSession = true): Promise {\n return await this._request('getStudents', {}, validateSession);\n }\n\n /**\n * Get all known rooms by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getRooms(validateSession = true): Promise {\n return await this._request('getRooms', {}, validateSession);\n }\n\n /**\n * Get all classes known by WebUntis\n * @param {boolean} [validateSession=true]\n * @param {number} schoolyearId\n * @returns {Promise.}\n */\n async getClasses(validateSession = true, schoolyearId: number): Promise {\n const data = typeof schoolyearId !== 'number' ? {} : { schoolyearId };\n return await this._request('getKlassen', data, validateSession);\n }\n\n /**\n * Get all departments known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getDepartments(validateSession = true): Promise {\n return await this._request('getDepartments', {}, validateSession);\n }\n\n /**\n * Get all holidays known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHolidays(validateSession = true): Promise {\n return await this._request('getHolidays', {}, validateSession);\n }\n\n /**\n * Get all status data known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStatusData(validateSession = true): Promise {\n return await this._request('getStatusData', {}, validateSession);\n }\n\n /**\n * Convert a JS Date Object to a WebUntis date string\n * @param {Date} date\n * @returns {String}\n */\n static convertDateToUntis(date: Date): string {\n return (\n date.getFullYear().toString() +\n (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1).toString() +\n (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()).toString()\n );\n }\n\n /**\n * Make a JSON RPC Request with the current session\n * @param {string} method\n * @param {Object} [parameter={}]\n * @param {string} [url='/WebUntis/jsonrpc.do?school=SCHOOL']\n * @param {boolean} [validateSession=true] Whether the session should be checked first\n * @returns {Promise.}\n * @private\n */\n async _request>(\n method: string,\n parameter: Record = {},\n validateSession = true,\n url = `/WebUntis/jsonrpc.do`\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'POST',\n url: url,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: method,\n params: parameter,\n jsonrpc: '2.0',\n },\n });\n if (!response.data.result) throw new Error(\"Server didn't return any result.\");\n if (response.data.result.code) throw new Error('Server returned error code: ' + response.data.result.code);\n return response.data.result;\n }\n\n /**\n * Returns all the Lessons where you were absent including the excused one!\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n excuseStatusId = -1,\n validateSession = true\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/classreg/absences/students`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n studentId: this.sessionInformation!.personId!,\n excuseStatusId: excuseStatusId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (response.data.data == null) throw new Error('Server returned no data!');\n return response.data.data;\n }\n\n /**\n * Returns a URL to a unique PDF of all the lessons you were absent\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [lateness=true]\n * @param {boolean} [absences=true]\n * @param {boolean} [excuseGroup=2]\n */\n async getPdfOfAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n validateSession = true,\n excuseStatusId = -1,\n lateness = true,\n absences = true,\n excuseGroup = 2\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/reports.do`,\n params: {\n name: 'Excuse',\n format: 'pdf',\n rpt_sd: Base.convertDateToUntis(rangeStart),\n rpt_ed: Base.convertDateToUntis(rangeEnd),\n excuseStatusId: excuseStatusId,\n studentId: this.sessionInformation!.personId!,\n withLateness: lateness,\n withAbsences: absences,\n execuseGroup: excuseGroup,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n const res = response.data.data;\n if (response.status != 200 || res.error) throw new Error('Server returned no data!');\n const pdfDownloadURL =\n this.baseurl + 'WebUntis/reports.do?' + 'msgId=' + res.messageId + '&' + res.reportParams;\n return pdfDownloadURL;\n }\n}\n\n/**\n * @private\n */\nexport class InternalWebuntisSecretLogin extends Base {\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false\n ) {\n super(school, username, password, baseurl, identity, disableUserAgent);\n }\n\n async _otpLogin(token: number | string, username: string, time: number, skipSessionInfo = false) {\n const response = await this.axios({\n method: 'POST',\n url: '/WebUntis/jsonrpc_intern.do',\n params: {\n m: 'getUserData2017',\n school: this.school,\n v: 'i2.2',\n },\n data: {\n id: this.id,\n method: 'getUserData2017',\n params: [\n {\n auth: {\n clientTime: time,\n user: username,\n otp: token,\n },\n },\n ],\n jsonrpc: '2.0',\n },\n });\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n if (!response.headers['set-cookie']) throw new Error(`Failed to login. Server didn't return a set-cookie`);\n if (!this._getCookieFromSetCookie(response.headers['set-cookie']))\n throw new Error(\"Failed to login. Server didn't return a session id.\");\n const sessionId = this._getCookieFromSetCookie(response.headers['set-cookie']);\n // Set session temporary\n this.sessionInformation = {\n sessionId: sessionId,\n };\n if (skipSessionInfo) return this.sessionInformation;\n\n // Get personId & personType\n const appConfigUrl = `/WebUntis/api/app/config`;\n const configResponse = await this.axios({\n method: 'GET',\n url: appConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof configResponse.data !== 'object' || typeof configResponse.data.data !== 'object')\n throw new Error('Failed to fetch app config while login. data (type): ' + typeof response.data);\n // Path -> data.loginServiceConfig.user.persons -> find person with id\n if (\n configResponse.data.data &&\n configResponse.data.data.loginServiceConfig &&\n configResponse.data.data.loginServiceConfig.user &&\n !Number.isInteger(configResponse.data.data.loginServiceConfig.user.personId)\n )\n throw new Error('Invalid personId. personId: ' + configResponse.data.data.loginServiceConfig.user.personId);\n const webUntisLoginServiceUser = configResponse.data.data.loginServiceConfig.user;\n if (!Array.isArray(webUntisLoginServiceUser.persons))\n throw new Error('Invalid person array. persons (type): ' + typeof webUntisLoginServiceUser.persons);\n const person = webUntisLoginServiceUser.persons.find(\n (value: Record) => value.id === configResponse.data.data.loginServiceConfig.user.personId\n );\n if (!person) throw new Error('Can not find person in person array.');\n if (!Number.isInteger(person.type)) throw new Error('Invalid person type. type (type): ' + person.type);\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n };\n // Get klasseId\n try {\n const dayConfigUrl = `/WebUntis/api/daytimetable/config`;\n const dayConfigResponse = await this.axios({\n method: 'GET',\n url: dayConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof dayConfigResponse.data !== 'object' || typeof dayConfigResponse.data.data !== 'object')\n throw new Error();\n if (!Number.isInteger(dayConfigResponse.data.data.klasseId)) throw new Error();\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n klasseId: dayConfigResponse.data.data.klasseId,\n };\n } catch (e) {\n // klasseId is not important. This request can fail\n }\n return this.sessionInformation;\n }\n\n /**\n *\n * @param {Array} setCookieArray\n * @param {string} [cookieName=\"JSESSIONID\"]\n * @return {string|boolean}\n * @private\n */\n _getCookieFromSetCookie(setCookieArray?: string[], cookieName = 'JSESSIONID') {\n if (!setCookieArray) return;\n for (let i = 0; i < setCookieArray.length; i++) {\n const setCookie = setCookieArray[i];\n if (!setCookie) continue;\n let cookieParts = setCookie.split(';');\n if (!cookieParts || !Array.isArray(cookieParts)) continue;\n for (let cookie of cookieParts) {\n cookie = cookie.trim();\n cookie = cookie.replace(/;/gm, '');\n const [Key, Value] = cookie.split('=');\n if (!Key || !Value) continue;\n if (Key === cookieName) return Value;\n }\n }\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\nimport type { authenticator } from 'otplib';\n\nexport type Authenticator = typeof authenticator;\n\nexport class WebUntisSecretAuth extends InternalWebuntisSecretLogin {\n private readonly secret: string;\n private authenticator: Authenticator;\n\n /**\n *\n * @constructor\n * @augments WebUntis\n * @param {string} school The school identifier\n * @param {string} user\n * @param {string} secret\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n user: string,\n secret: string,\n baseurl: string,\n identity = 'Awesome',\n authenticator: Authenticator,\n disableUserAgent = false\n ) {\n super(school, user, null as unknown as string, baseurl, identity, disableUserAgent);\n this.secret = secret;\n this.authenticator = authenticator;\n if (!authenticator) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the otplib object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n const { authenticator } = eval(\"require('otplib')\");\n this.authenticator = authenticator;\n }\n }\n\n // @ts-ignore\n async login() {\n // Get JSESSION\n const token = this.authenticator.generate(this.secret);\n const time = new Date().getTime();\n return await this._otpLogin(token, this.username, time);\n }\n}\n","import { WebUntisSecretAuth } from './secret';\nimport type { Authenticator } from './secret';\nimport type { URL } from 'url';\n\n/**\n * @private\n */\nexport type URLClass = typeof URL;\n\nexport class WebUntisQR extends WebUntisSecretAuth {\n /**\n * Use the data you get from a WebUntis QR code\n * @constructor\n * @param {string} QRCodeURI A WebUntis uri. This is the data you get from the QR Code from the webuntis webapp under profile->Data access->Display\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {Object} URL Custom whatwg url implementation. Default will use the nodejs implementation.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n QRCodeURI: string,\n identity: string,\n authenticator: Authenticator,\n URL?: URLClass,\n disableUserAgent = false\n ) {\n let URLImplementation = URL;\n if (!URL) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the URL object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n URLImplementation = eval(\"require('url').URL\") as URLClass;\n }\n const uri = new URLImplementation!(QRCodeURI);\n super(\n uri.searchParams.get('school')!,\n uri.searchParams.get('user')!,\n uri.searchParams.get('key')!,\n uri.searchParams.get('url')!,\n identity,\n authenticator,\n disableUserAgent\n );\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\n\nexport class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin {\n /**\n *\n * @param {string} school\n * @param {string} baseurl\n * @param {string} [identity='Awesome']\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(school: string, baseurl: string, identity = 'Awesome', disableUserAgent = false) {\n // TODO: Make this a bit more beautiful and more type safe\n super(school, null as unknown as string, null as unknown as string, baseurl, identity, disableUserAgent);\n this.username = '#anonymous#';\n this.anonymous = true;\n }\n\n override async login() {\n // Check whether the school has public access or not\n const url = `/WebUntis/jsonrpc_intern.do`;\n\n const response = await this.axios({\n method: 'POST',\n url,\n params: {\n m: 'getAppSharedSecret',\n school: this.school,\n v: 'i3.5',\n },\n data: {\n id: this.id,\n method: 'getAppSharedSecret',\n params: [\n {\n userName: '#anonymous#',\n password: '',\n },\n ],\n jsonrpc: '2.0',\n },\n });\n\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n\n // OTP never changes when using anonymous login\n const otp = 100170;\n const time = new Date().getTime();\n return await this._otpLogin(otp, this.username, time, true);\n }\n}\n"],"names":["WebUntisDay","WebUntisElementType","parse","startOfDay","format"],"mappings":";;;;;AAkBA,MAAM,kBAAqB,GAAA,uCAAA,CAAA;AA0DpB,SAAS,SAAU,CAAA,IAAA,EAAc,GAAa,EAAA,GAAA,GAAwB,EAAY,EAAA;AACrF,EAAA,IAAI,CAAC,GAAI,CAAA,MAAA;AAAQ,IAAA,GAAA,CAAI,MAAS,GAAA,kBAAA,CAAA;AAE9B,EAAI,IAAA,CAAC,kBAAmB,CAAA,IAAA,CAAK,IAAI,CAAA;AAAG,IAAM,MAAA,IAAI,UAAU,0BAA0B,CAAA,CAAA;AAElF,EAAM,MAAA,KAAA,GAAQ,GAAI,CAAA,MAAA,CAAO,GAAG,CAAA,CAAA;AAE5B,EAAA,IAAI,KAAS,IAAA,CAAC,kBAAmB,CAAA,IAAA,CAAK,KAAK,CAAA;AAAG,IAAM,MAAA,IAAI,UAAU,yBAAyB,CAAA,CAAA;AAE3F,EAAI,IAAA,GAAA,GAAM,OAAO,GAAM,GAAA,KAAA,CAAA;AAEvB,EAAI,IAAA,IAAA,IAAQ,IAAI,MAAQ,EAAA;AACpB,IAAM,MAAA,MAAA,GAAS,IAAI,MAAS,GAAA,CAAA,CAAA;AAE5B,IAAA,IAAI,KAAM,CAAA,MAAM,CAAK,IAAA,CAAC,SAAS,MAAM,CAAA;AAAG,MAAM,MAAA,IAAI,UAAU,0BAA0B,CAAA,CAAA;AAEtF,IAAO,GAAA,IAAA,YAAA,GAAe,IAAK,CAAA,KAAA,CAAM,MAAM,CAAA,CAAA;AAAA,GAC3C;AAEA,EAAA,IAAI,IAAI,MAAQ,EAAA;AACZ,IAAA,IAAI,CAAC,kBAAA,CAAmB,IAAK,CAAA,GAAA,CAAI,MAAM,CAAA;AAAG,MAAM,MAAA,IAAI,UAAU,0BAA0B,CAAA,CAAA;AAExF,IAAA,GAAA,IAAO,cAAc,GA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CAAA,CAAA;AAAA,GAC9D;AACJ;;;;;;;;;;;"} \ No newline at end of file +{"version":3,"file":"webuntis.js","sources":["../src/cookie.ts","../src/base-64.ts","../src/types.ts","../src/base.ts","../src/secret.ts","../src/qr.ts","../src/anonymous.ts"],"sourcesContent":["/**\n * Shamelessly stolen from @tinyhttp/cookie.\n *\n * Because @tinyhttp/cookie doesn't provide a commonjs build, I just decided to include the source code.\n * We need a cjs build, because we generate both esm and cjs.\n */\n\nconst pairSplitRegExp = /; */;\n\n/**\n * RegExp to match field-content in RFC 7230 sec 3.2\n *\n * field-content = field-vchar [ 1*( SP / HTAB ) field-vchar ]\n * field-vchar = VCHAR / obs-text\n * obs-text = %x80-FF\n */\n\n// eslint-disable-next-line no-control-regex\nconst fieldContentRegExp = /^[\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+$/;\n\nfunction tryDecode(str: string, decode: (str: string) => string) {\n try {\n return decode(str);\n } catch (e) {\n return str;\n }\n}\n\n/**\n * Parse a cookie header.\n *\n * Parse the given cookie header string into an object\n * The object has the various cookies as keys(names) => values\n *\n */\nexport function parse(\n str: string,\n options: {\n decode: (str: string) => string;\n } = {\n decode: decodeURIComponent,\n }\n): Record {\n const obj: Record = {};\n const pairs = str.split(pairSplitRegExp);\n\n for (const pair of pairs) {\n let eqIdx = pair.indexOf('=');\n\n // skip things that don't look like key=value\n if (eqIdx < 0) continue;\n\n const key = pair.substr(0, eqIdx).trim();\n let val = pair.substr(++eqIdx, pair.length).trim();\n\n // quoted values\n if ('\"' == val[0]) val = val.slice(1, -1);\n\n // only assign once\n if (obj[key] == null) obj[key] = tryDecode(val, options.decode);\n }\n\n return obj;\n}\n\nexport type SerializeOptions = Partial<{\n encode: (str: string) => string;\n maxAge: number;\n domain: string;\n path: string;\n httpOnly: boolean;\n secure: boolean;\n sameSite: boolean | 'Strict' | 'strict' | 'Lax' | 'lax' | 'None' | 'none' | string;\n expires: Date;\n}>;\n\nexport function serialize(name: string, val: string, opt: SerializeOptions = {}): string {\n if (!opt.encode) opt.encode = encodeURIComponent;\n\n if (!fieldContentRegExp.test(name)) throw new TypeError('argument name is invalid');\n\n const value = opt.encode(val);\n\n if (value && !fieldContentRegExp.test(value)) throw new TypeError('argument val is invalid');\n\n let str = name + '=' + value;\n\n if (null != opt.maxAge) {\n const maxAge = opt.maxAge - 0;\n\n if (isNaN(maxAge) || !isFinite(maxAge)) throw new TypeError('option maxAge is invalid');\n\n str += '; Max-Age=' + Math.floor(maxAge);\n }\n\n if (opt.domain) {\n if (!fieldContentRegExp.test(opt.domain)) throw new TypeError('option domain is invalid');\n\n str += '; Domain=' + opt.domain;\n }\n\n if (opt.path) {\n if (!fieldContentRegExp.test(opt.path)) throw new TypeError('option path is invalid');\n\n str += '; Path=' + opt.path;\n }\n\n if (opt.expires) str += '; Expires=' + opt.expires.toUTCString();\n\n if (opt.httpOnly) str += '; HttpOnly';\n\n if (opt.secure) str += '; Secure';\n\n if (opt.sameSite) {\n const sameSite = typeof opt.sameSite === 'string' ? opt.sameSite.toLowerCase() : opt.sameSite;\n\n switch (sameSite) {\n case true:\n case 'strict':\n str += '; SameSite=Strict';\n break;\n case 'lax':\n str += '; SameSite=Lax';\n break;\n case 'none':\n str += '; SameSite=None';\n break;\n default:\n throw new TypeError('option sameSite is invalid');\n }\n }\n\n return str;\n}\n","const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\nexport function btoa(input = '') {\n let str = input;\n let output = '';\n\n for (\n let block = 0, charCode, i = 0, map = chars;\n str.charAt(i | 0) || ((map = '='), i % 1);\n output += map.charAt(63 & (block >> (8 - (i % 1) * 8)))\n ) {\n charCode = str.charCodeAt((i += 3 / 4));\n\n if (charCode > 0xff) {\n throw new Error(\"'btoa' failed: The string to be encoded contains characters outside of the Latin1 range.\");\n }\n\n block = (block << 8) | charCode;\n }\n\n return output;\n}\n","export interface SchoolYear {\n name: string;\n id: number;\n startDate: Date;\n endDate: Date;\n}\n\nexport interface MessagesOfDay {\n id: number;\n subject: string;\n text: string;\n isExpanded: boolean;\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: any[];\n}\n\nexport interface NewsWidget {\n /**\n * Unknown type. I have never seen this in use.\n */\n systemMessage: any;\n messagesOfDay: MessagesOfDay[];\n rssUrl: string;\n}\n\nexport interface Messagesender {\n userId: number;\n displayName: string;\n imageUrl: string;\n className: string;\n}\n\nexport interface Inboxmessage {\n allowMessageDeletion: boolean;\n contentPreview: string;\n hasAttachments: boolean;\n id: number;\n isMessageRead: boolean;\n isReply: boolean;\n isReplyAllowed: boolean;\n sender: Messagesender;\n sentDateTime: string;\n subject: string;\n}\n\nexport interface Inbox {\n incomingMessages: Inboxmessage[];\n}\n\nexport interface ShortData {\n id: number;\n name: string;\n longname: string;\n orgname?: string;\n orgid?: number;\n}\n\nexport interface Lesson {\n id: number;\n date: number;\n startTime: number;\n endTime: number;\n kl: ShortData[];\n te: ShortData[];\n su: ShortData[];\n ro: ShortData[];\n lstext?: string;\n lsnumber: number;\n activityType?: 'Unterricht' | string;\n code?: 'cancelled' | 'irregular';\n info?: string;\n substText?: string;\n statflags?: string;\n sg?: string;\n bkRemark?: string;\n bkText?: string;\n}\n\nexport interface Homework {\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: Array;\n completed: boolean;\n date: number;\n dueDate: number;\n id: number;\n lessonId: number;\n remark: string;\n text: string;\n}\n\nexport interface Subject {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport enum WebUntisDay {\n Sunday = 1,\n Monday = 2,\n Tuesday = 3,\n Wednesday = 4,\n Thursday = 5,\n Friday = 6,\n Saturday = 7,\n}\n\nexport interface TimeUnit {\n name: string;\n startTime: number;\n endTime: number;\n}\n\nexport interface Timegrid {\n day: WebUntisDay;\n timeUnits: TimeUnit[];\n}\n\nexport interface Exam {\n id: number;\n examType: string;\n name: string;\n studentClass: string[];\n assignedStudents: {\n klasse: { id: number; name: string };\n displayName: string;\n id: number;\n }[];\n examDate: number;\n startTime: number;\n endTime: number;\n subject: string;\n teachers: string[];\n rooms: string[];\n text: string;\n grade?: string;\n}\n\nexport enum WebUntisElementType {\n CLASS = 1,\n TEACHER = 2,\n SUBJECT = 3,\n ROOM = 4,\n STUDENT = 5,\n}\n\nexport interface WebElement {\n type: WebUntisElementType;\n id: number;\n orgId: number;\n missing: boolean;\n state: 'REGULAR' | 'ABSENT' | 'SUBSTITUTED';\n}\n\nexport interface WebElementData extends WebElement {\n element: {\n type: number;\n id: number;\n name: string;\n longName?: string;\n displayname?: string;\n alternatename?: string;\n canViewTimetable: boolean;\n externalKey?: string;\n roomCapacity: number;\n };\n}\n\nexport interface WebAPITimetable {\n id: number;\n lessonId: number;\n lessonNumber: number;\n lessonCode: string;\n lessonText: string;\n periodText: string;\n hasPeriodText: false;\n periodInfo: string;\n periodAttachments: [];\n substText: string;\n date: number;\n startTime: number;\n endTime: number;\n elements: WebElement[];\n studentGroup: string;\n hasInfo: boolean;\n code: number;\n cellState: 'STANDARD' | 'SUBSTITUTION' | 'ROOMSUBSTITUTION';\n priority: number;\n is: {\n roomSubstitution?: boolean;\n substitution?: boolean;\n standard?: boolean;\n event: boolean;\n };\n roomCapacity: number;\n studentCount: number;\n classes: WebElementData[];\n teachers: WebElementData[];\n subjects: WebElementData[];\n rooms: WebElementData[];\n students: WebElementData[];\n}\n\nexport interface Teacher {\n id: number;\n name: string;\n foreName: string;\n longName: string;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Student {\n id: number;\n key: number;\n name: string;\n foreName: string;\n longName: string;\n gender: string;\n}\n\nexport interface Room {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Klasse {\n id: number;\n name: string;\n longName: string;\n active: boolean;\n}\n\nexport interface Department {\n id: number;\n name: string;\n longName: string;\n}\n\nexport interface Holiday {\n name: string;\n longName: string;\n id: number;\n startDate: number;\n endDate: number;\n}\n\nexport interface ColorEntity {\n foreColor: string;\n backColor: string;\n}\n\nexport interface LsEntity {\n ls?: ColorEntity | null;\n oh?: ColorEntity | null;\n sb?: ColorEntity | null;\n bs?: ColorEntity | null;\n ex?: ColorEntity | null;\n}\n\nexport interface CodesEntity {\n cancelled?: ColorEntity | null;\n irregular?: ColorEntity | null;\n}\n\nexport interface StatusData {\n lstypes: LsEntity[];\n codes: CodesEntity[];\n}\n\nexport interface Absences {\n absences: Absence[];\n absenceReasons: [];\n excuseStatuses: boolean;\n showAbsenceReasonChange: boolean;\n showCreateAbsence: boolean;\n}\n\nexport interface Absence {\n id: number;\n startDate: number;\n endDate: number;\n startTime: number;\n endTime: number;\n createDate: number;\n lastUpdate: number;\n createdUser: string;\n updatedUser: string;\n reasonId: number;\n reason: string;\n text: string;\n interruptions: [];\n canEdit: boolean;\n studentName: string;\n excuseStatus: string;\n isExcused: boolean;\n excuse: Excuse;\n}\n\nexport interface Excuse {\n id: number;\n text: string;\n excuseDate: number;\n excuseStatus: string;\n isExcused: boolean;\n userId: number;\n username: string;\n}\n","import { serialize } from './cookie';\nimport axios from 'axios';\nimport { btoa } from './base-64';\nimport { parse, startOfDay, format } from 'date-fns';\nimport type { AxiosInstance } from 'axios';\nimport type {\n Absences,\n Department,\n Exam,\n Holiday,\n Homework,\n Inbox,\n Klasse,\n Lesson,\n NewsWidget,\n Room,\n SchoolYear,\n StatusData,\n Student,\n Subject,\n Teacher,\n Timegrid,\n WebAPITimetable,\n} from './types';\nimport type { InternalSchoolYear, SessionInformation } from './internal';\nimport { WebUntisElementType } from './types';\n\nexport class Base {\n school: string;\n schoolbase64: string;\n username: string;\n password: string;\n baseurl: string;\n cookies: string[];\n id: string;\n sessionInformation: SessionInformation | null;\n anonymous: boolean;\n\n axios: AxiosInstance;\n\n static TYPES = WebUntisElementType;\n\n /**\n *\n * @constructor\n * @param {string} school The school identifier\n * @param {string} username\n * @param {string} password\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false,\n ) {\n this.school = school;\n this.schoolbase64 = '_' + btoa(this.school);\n this.username = username;\n this.password = password;\n this.baseurl = 'https://' + baseurl + '/';\n this.cookies = [];\n this.id = identity;\n this.sessionInformation = {};\n this.anonymous = false;\n\n const additionalHeaders: Record = {};\n\n if (!disableUserAgent) {\n additionalHeaders['User-Agent'] =\n 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.79 Safari/537.36';\n }\n\n this.axios = axios.create({\n baseURL: this.baseurl,\n maxRedirects: 0,\n headers: {\n 'Cache-Control': 'no-cache',\n Pragma: 'no-cache',\n 'X-Requested-With': 'XMLHttpRequest',\n ...additionalHeaders,\n },\n validateStatus: function (status) {\n return status >= 200 && status < 303; // default\n },\n });\n }\n\n /**\n * Logout the current session\n */\n async logout(): Promise {\n await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'logout',\n params: {},\n jsonrpc: '2.0',\n },\n });\n this.sessionInformation = null;\n return true;\n }\n\n /**\n * Login with your credentials\n *\n * **Notice: The server may revoke this session after less than 10min of idle.**\n *\n * *Untis says in the official docs:*\n * > An application should always log out as soon as possible to free system resources on the server.\n */\n async login(): Promise {\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'authenticate',\n params: {\n user: this.username,\n password: this.password,\n client: this.id,\n },\n jsonrpc: '2.0',\n },\n });\n if (typeof response.data !== 'object') throw new Error('Failed to parse server response.');\n if (!response.data.result) throw new Error('Failed to login. ' + JSON.stringify(response.data));\n if (response.data.result.code) throw new Error('Login returned error code: ' + response.data.result.code);\n if (!response.data.result.sessionId) throw new Error('Failed to login. No session id.');\n this.sessionInformation = response.data.result;\n return response.data.result;\n }\n\n /**\n * Get the latest WebUntis Schoolyear\n * @param {Boolean} [validateSession=true]\n */\n async getLatestSchoolyear(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return {\n name: data[0].name,\n id: data[0].id,\n startDate: parse(data[0].startDate, 'yyyyMMdd', new Date()),\n endDate: parse(data[0].endDate, 'yyyyMMdd', new Date()),\n };\n }\n\n /**\n * Get all WebUntis Schoolyears\n * @param {Boolean} [validateSession=true]\n */\n async getSchoolyears(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return data.map((year) => {\n return {\n name: year.name,\n id: year.id,\n startDate: parse(year.startDate, 'yyyyMMdd', new Date()),\n endDate: parse(year.endDate, 'yyyyMMdd', new Date()),\n };\n });\n }\n\n /**\n * Get News Widget\n * @param {Date} date\n * @param {boolean} [validateSession=true]\n * @returns {Promise} see index.d.ts NewsWidget\n */\n async getNewsWidget(date: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/news/newsWidgetData`,\n params: {\n date: Base.convertDateToUntis(date),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data.data;\n }\n\n /**\n * Get Inbox\n */\n async getInbox(validateSession = true): Promise {\n this._checkAnonymous();\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n //first get JWT Token\n if (typeof this.sessionInformation!.jwt_token != 'string') await this._getJWT();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/rest/view/v1/messages`,\n headers: {\n Authorization: `Bearer ${this.sessionInformation!.jwt_token}`,\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data;\n }\n\n private _checkAnonymous() {\n if (this.anonymous) {\n throw new Error('This method is not supported with anonymous login');\n }\n }\n\n /**\n *\n * @returns {string}\n * @private\n */\n _buildCookies() {\n let cookies = [];\n cookies.push(serialize('JSESSIONID', this.sessionInformation!.sessionId!));\n cookies.push(serialize('schoolname', this.schoolbase64));\n return cookies.join('; ');\n }\n\n /**\n * Get JWT Token\n * @private\n */\n async _getJWT(validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/token/new`,\n headers: {\n //Authorization: `Bearer ${this._getToken()}`,\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data !== 'string') throw new Error('Server returned invalid data.');\n this.sessionInformation!.jwt_token = response.data;\n return response.data;\n }\n\n /**\n * Checks if your current WebUntis Session is valid\n */\n async validateSession(): Promise {\n if (!this.sessionInformation) return false;\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: 'getLatestImportTime',\n params: {},\n jsonrpc: '2.0',\n },\n });\n return typeof response.data.result === 'number';\n }\n\n /**\n * Get the time when WebUntis last changed its data\n * @param {Boolean} [validateSession=true]\n */\n async getLatestImportTime(validateSession = true): Promise {\n return this._request('getLatestImportTime', {}, validateSession);\n }\n\n /**\n *\n * @param id\n * @param type\n * @param startDate\n * @param endDate\n * @param validateSession\n * @private\n */\n private async _timetableRequest(\n id: string | number,\n type: number,\n startDate?: Date | null,\n endDate?: Date | null,\n validateSession = true,\n ): Promise {\n const additionalOptions: Record = {};\n if (startDate) {\n additionalOptions.startDate = Base.convertDateToUntis(startDate);\n }\n if (endDate) {\n additionalOptions.endDate = Base.convertDateToUntis(endDate);\n }\n\n return this._request(\n 'getTimetable',\n {\n options: {\n id: new Date().getTime(),\n element: {\n id,\n type,\n },\n ...additionalOptions,\n showLsText: true,\n showStudentgroup: true,\n showLsNumber: true,\n showSubstText: true,\n showInfo: true,\n showBooking: true,\n klasseFields: ['id', 'name', 'longname', 'externalkey'],\n roomFields: ['id', 'name', 'longname', 'externalkey'],\n subjectFields: ['id', 'name', 'longname', 'externalkey'],\n teacherFields: ['id', 'name', 'longname', 'externalkey'],\n },\n },\n validateSession,\n );\n }\n\n /**\n * Get your own Timetable for the current day\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n null,\n null,\n validateSession,\n );\n }\n\n /**\n * Get the timetable of today for a specific element.\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getTimetableForToday(id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, null, null, validateSession);\n }\n\n /**\n * Get your own Timetable for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n */\n async getOwnTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n date,\n date,\n validateSession,\n );\n }\n\n /**\n * Get the timetable for a specific day for a specific element.\n * @param {Date} date\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableFor(date: Date, id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, date, date, validateSession);\n }\n\n /**\n * Get your own timetable for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n rangeStart,\n rangeEnd,\n validateSession,\n );\n }\n\n /**\n * Get the timetable for a given Date range for specific element\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForRange(\n rangeStart: Date,\n rangeEnd: Date,\n id: number,\n type: number,\n validateSession = true,\n ): Promise {\n return await this._timetableRequest(id, type, rangeStart, rangeEnd, validateSession);\n }\n\n /**\n * Get the Timetable of your class for today\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnClassTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, null, null, validateSession);\n }\n\n /**\n * Get the Timetable of your class for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnClassTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, date, date, validateSession);\n }\n\n /**\n * Get the Timetable of your class for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n */\n async getOwnClassTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.klasseId!,\n 1,\n rangeStart,\n rangeEnd,\n validateSession,\n );\n }\n\n /**\n *\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorksFor(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Converts the untis date string format to a normal JS Date object\n * @param {string} date Untis date string\n * @param {Date} [baseDate=new Date()] Base date. Default beginning of current day\n * @static\n */\n static convertUntisDate(date: string, baseDate = startOfDay(new Date())): Date {\n if (typeof date !== 'string') date = `${date}`;\n return parse(date, 'yyyyMMdd', baseDate);\n }\n\n /**\n * Convert a untis time string to a JS Date object\n * @param {string|number} time Untis time string\n * @param {Date} [baseDate=new Date()] Day used as base for the time. Default: Current date\n * @static\n */\n static convertUntisTime(time: number | string, baseDate = new Date()): Date {\n if (typeof time !== 'string') time = `${time}`;\n return parse(time.padStart(4, '0'), 'Hmm', baseDate);\n }\n\n /**\n * Get all known Subjects for the current logged-in user\n * @param {boolean} [validateSession=true]\n */\n async getSubjects(validateSession = true): Promise {\n return await this._request('getSubjects', {}, validateSession);\n }\n\n /**\n * Get the timegrid of current school\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTimegrid(validateSession = true): Promise {\n return await this._request('getTimegridUnits', {}, validateSession);\n }\n\n /**\n *\n * TODO: Find out what type this function returns\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorkAndLessons(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Get Exams for range\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Number} klasseId\n * @param {boolean} withGrades\n * @param {boolean} [validateSession=true]\n */\n async getExamsForRange(\n rangeStart: Date,\n rangeEnd: Date,\n klasseId = -1,\n withGrades = false,\n validateSession = true,\n ): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/exams`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n klasseId: klasseId,\n withGrades: withGrades,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['exams']) throw new Error(\"Data object doesn't contains exams object.\");\n return response.data.data['exams'];\n }\n\n /**\n * Get the timetable for the current week for a specific element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {number} id element id\n * @param {WebUntisElementType} type element type\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForWeek(\n date: Date,\n id: number,\n type: number,\n formatId = 1,\n validateSession = true,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/timetable/weekly/data`,\n params: {\n elementType: type,\n elementId: id,\n date: format(date, 'yyyy-MM-dd'),\n formatId: formatId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n\n if (response.data.data.error) {\n /* known codes:\n * - ERR_TTVIEW_NOTALLOWED_ONDATE\n */\n const err = new Error('Server responded with error');\n // TODO: Make this better lol\n // @ts-ignore\n err.code = response.data.data.error?.data?.messageKey;\n throw err;\n }\n\n if (!response.data.data.result?.data?.elementPeriods?.[id]) throw new Error('Invalid response');\n\n const data = response.data.data.result.data;\n\n // TODO: improve typings\n\n const formatElements = (elements: Array>, { byType }: { byType: number }) => {\n const filteredElements = elements.filter((element) => element.type === byType);\n\n return filteredElements.map((element) => ({\n ...element,\n element: data.elements.find(\n (dataElement: Record) =>\n dataElement.type === byType && dataElement.id === element.id,\n ),\n }));\n };\n\n const timetable = data.elementPeriods[id].map((lesson: any) => ({\n ...lesson,\n classes: formatElements(lesson.elements, { byType: Base.TYPES.CLASS }),\n teachers: formatElements(lesson.elements, { byType: Base.TYPES.TEACHER }),\n subjects: formatElements(lesson.elements, { byType: Base.TYPES.SUBJECT }),\n rooms: formatElements(lesson.elements, { byType: Base.TYPES.ROOM }),\n students: formatElements(lesson.elements, { byType: Base.TYPES.STUDENT }),\n }));\n\n return timetable;\n }\n\n /**\n * Get the timetable for the current week for the current element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForWeek(date: Date, formatId = 1, validateSession = true): Promise {\n this._checkAnonymous();\n return await this.getTimetableForWeek(\n date,\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n formatId,\n validateSession,\n );\n }\n\n /**\n * Get all known teachers by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTeachers(validateSession = true): Promise {\n return await this._request('getTeachers', {}, validateSession);\n }\n\n /**\n * Get all known students by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStudents(validateSession = true): Promise {\n return await this._request('getStudents', {}, validateSession);\n }\n\n /**\n * Get all known rooms by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getRooms(validateSession = true): Promise {\n return await this._request('getRooms', {}, validateSession);\n }\n\n /**\n * Get all classes known by WebUntis\n * @param {boolean} [validateSession=true]\n * @param {number} schoolyearId\n * @returns {Promise.}\n */\n async getClasses(validateSession = true, schoolyearId: number): Promise {\n const data = typeof schoolyearId !== 'number' ? {} : { schoolyearId };\n return await this._request('getKlassen', data, validateSession);\n }\n\n /**\n * Get all departments known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getDepartments(validateSession = true): Promise {\n return await this._request('getDepartments', {}, validateSession);\n }\n\n /**\n * Get all holidays known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHolidays(validateSession = true): Promise {\n return await this._request('getHolidays', {}, validateSession);\n }\n\n /**\n * Get all status data known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStatusData(validateSession = true): Promise {\n return await this._request('getStatusData', {}, validateSession);\n }\n\n /**\n * Convert a JS Date Object to a WebUntis date string\n * @param {Date} date\n * @returns {String}\n */\n static convertDateToUntis(date: Date): string {\n return (\n date.getFullYear().toString() +\n (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1).toString() +\n (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()).toString()\n );\n }\n\n /**\n * Make a JSON RPC Request with the current session\n * @param {string} method\n * @param {Object} [parameter={}]\n * @param {string} [url='/WebUntis/jsonrpc.do?school=SCHOOL']\n * @param {boolean} [validateSession=true] Whether the session should be checked first\n * @returns {Promise.}\n * @private\n */\n async _request>(\n method: string,\n parameter: Record = {},\n validateSession = true,\n url = `/WebUntis/jsonrpc.do`,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'POST',\n url: url,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: method,\n params: parameter,\n jsonrpc: '2.0',\n },\n });\n if (!response.data.result) throw new Error(\"Server didn't return any result.\");\n if (response.data.result.code) throw new Error('Server returned error code: ' + response.data.result.code);\n return response.data.result;\n }\n\n /**\n * Returns all the Lessons where you were absent including the excused one!\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n excuseStatusId = -1,\n validateSession = true,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/classreg/absences/students`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n studentId: this.sessionInformation!.personId!,\n excuseStatusId: excuseStatusId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (response.data.data == null) throw new Error('Server returned no data!');\n return response.data.data;\n }\n\n /**\n * Returns a URL to a unique PDF of all the lessons you were absent\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [lateness=true]\n * @param {boolean} [absences=true]\n * @param {boolean} [excuseGroup=2]\n */\n async getPdfOfAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n validateSession = true,\n excuseStatusId = -1,\n lateness = true,\n absences = true,\n excuseGroup = 2,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/reports.do`,\n params: {\n name: 'Excuse',\n format: 'pdf',\n rpt_sd: Base.convertDateToUntis(rangeStart),\n rpt_ed: Base.convertDateToUntis(rangeEnd),\n excuseStatusId: excuseStatusId,\n studentId: this.sessionInformation!.personId!,\n withLateness: lateness,\n withAbsences: absences,\n execuseGroup: excuseGroup,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n const res = response.data.data;\n if (response.status != 200 || res.error) throw new Error('Server returned no data!');\n const pdfDownloadURL =\n this.baseurl + 'WebUntis/reports.do?' + 'msgId=' + res.messageId + '&' + res.reportParams;\n return pdfDownloadURL;\n }\n}\n\n/**\n * @private\n */\nexport class InternalWebuntisSecretLogin extends Base {\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false,\n ) {\n super(school, username, password, baseurl, identity, disableUserAgent);\n }\n\n async _otpLogin(token: number | string, username: string, time: number, skipSessionInfo = false) {\n const response = await this.axios({\n method: 'POST',\n url: '/WebUntis/jsonrpc_intern.do',\n params: {\n m: 'getUserData2017',\n school: this.school,\n v: 'i2.2',\n },\n data: {\n id: this.id,\n method: 'getUserData2017',\n params: [\n {\n auth: {\n clientTime: time,\n user: username,\n otp: token,\n },\n },\n ],\n jsonrpc: '2.0',\n },\n });\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n if (!response.headers['set-cookie']) throw new Error(`Failed to login. Server didn't return a set-cookie`);\n if (!this._getCookieFromSetCookie(response.headers['set-cookie']))\n throw new Error(\"Failed to login. Server didn't return a session id.\");\n const sessionId = this._getCookieFromSetCookie(response.headers['set-cookie']);\n // Set session temporary\n this.sessionInformation = {\n sessionId: sessionId,\n };\n if (skipSessionInfo) return this.sessionInformation;\n\n // Get personId & personType\n const appConfigUrl = `/WebUntis/api/app/config`;\n const configResponse = await this.axios({\n method: 'GET',\n url: appConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof configResponse.data !== 'object' || typeof configResponse.data.data !== 'object')\n throw new Error('Failed to fetch app config while login. data (type): ' + typeof response.data);\n // Path -> data.loginServiceConfig.user.persons -> find person with id\n if (\n configResponse.data.data &&\n configResponse.data.data.loginServiceConfig &&\n configResponse.data.data.loginServiceConfig.user &&\n !Number.isInteger(configResponse.data.data.loginServiceConfig.user.personId)\n )\n throw new Error('Invalid personId. personId: ' + configResponse.data.data.loginServiceConfig.user.personId);\n const webUntisLoginServiceUser = configResponse.data.data.loginServiceConfig.user;\n if (!Array.isArray(webUntisLoginServiceUser.persons))\n throw new Error('Invalid person array. persons (type): ' + typeof webUntisLoginServiceUser.persons);\n const person = webUntisLoginServiceUser.persons.find(\n (value: Record) => value.id === configResponse.data.data.loginServiceConfig.user.personId,\n );\n if (!person) throw new Error('Can not find person in person array.');\n if (!Number.isInteger(person.type)) throw new Error('Invalid person type. type (type): ' + person.type);\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n };\n // Get klasseId\n try {\n const dayConfigUrl = `/WebUntis/api/daytimetable/config`;\n const dayConfigResponse = await this.axios({\n method: 'GET',\n url: dayConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof dayConfigResponse.data !== 'object' || typeof dayConfigResponse.data.data !== 'object')\n throw new Error();\n if (!Number.isInteger(dayConfigResponse.data.data.klasseId)) throw new Error();\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n klasseId: dayConfigResponse.data.data.klasseId,\n };\n } catch (e) {\n // klasseId is not important. This request can fail\n }\n return this.sessionInformation;\n }\n\n /**\n *\n * @param {Array} setCookieArray\n * @param {string} [cookieName=\"JSESSIONID\"]\n * @return {string|boolean}\n * @private\n */\n _getCookieFromSetCookie(setCookieArray?: string[], cookieName = 'JSESSIONID') {\n if (!setCookieArray) return;\n for (let i = 0; i < setCookieArray.length; i++) {\n const setCookie = setCookieArray[i];\n if (!setCookie) continue;\n let cookieParts = setCookie.split(';');\n if (!cookieParts || !Array.isArray(cookieParts)) continue;\n for (let cookie of cookieParts) {\n cookie = cookie.trim();\n cookie = cookie.replace(/;/gm, '');\n const [Key, Value] = cookie.split('=');\n if (!Key || !Value) continue;\n if (Key === cookieName) return Value;\n }\n }\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\nimport type { authenticator } from 'otplib';\n\nexport type Authenticator = typeof authenticator;\n\nexport class WebUntisSecretAuth extends InternalWebuntisSecretLogin {\n private readonly secret: string;\n private authenticator: Authenticator;\n\n /**\n *\n * @constructor\n * @augments WebUntis\n * @param {string} school The school identifier\n * @param {string} user\n * @param {string} secret\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n user: string,\n secret: string,\n baseurl: string,\n identity = 'Awesome',\n authenticator: Authenticator,\n disableUserAgent = false\n ) {\n super(school, user, null as unknown as string, baseurl, identity, disableUserAgent);\n this.secret = secret;\n this.authenticator = authenticator;\n if (!authenticator) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the otplib object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n const { authenticator } = eval(\"require('otplib')\");\n this.authenticator = authenticator;\n }\n }\n\n // @ts-ignore\n async login() {\n // Get JSESSION\n const token = this.authenticator.generate(this.secret);\n const time = new Date().getTime();\n return await this._otpLogin(token, this.username, time);\n }\n}\n","import { WebUntisSecretAuth } from './secret';\nimport type { Authenticator } from './secret';\nimport type { URL } from 'url';\n\n/**\n * @private\n */\nexport type URLClass = typeof URL;\n\nexport class WebUntisQR extends WebUntisSecretAuth {\n /**\n * Use the data you get from a WebUntis QR code\n * @constructor\n * @param {string} QRCodeURI A WebUntis uri. This is the data you get from the QR Code from the webuntis webapp under profile->Data access->Display\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {Object} URL Custom whatwg url implementation. Default will use the nodejs implementation.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n QRCodeURI: string,\n identity: string,\n authenticator: Authenticator,\n URL?: URLClass,\n disableUserAgent = false\n ) {\n let URLImplementation = URL;\n if (!URL) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the URL object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n URLImplementation = eval(\"require('url').URL\") as URLClass;\n }\n const uri = new URLImplementation!(QRCodeURI);\n super(\n uri.searchParams.get('school')!,\n uri.searchParams.get('user')!,\n uri.searchParams.get('key')!,\n uri.searchParams.get('url')!,\n identity,\n authenticator,\n disableUserAgent\n );\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\n\nexport class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin {\n /**\n *\n * @param {string} school\n * @param {string} baseurl\n * @param {string} [identity='Awesome']\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(school: string, baseurl: string, identity = 'Awesome', disableUserAgent = false) {\n // TODO: Make this a bit more beautiful and more type safe\n super(school, null as unknown as string, null as unknown as string, baseurl, identity, disableUserAgent);\n this.username = '#anonymous#';\n this.anonymous = true;\n }\n\n override async login() {\n // Check whether the school has public access or not\n const url = `/WebUntis/jsonrpc_intern.do`;\n\n const response = await this.axios({\n method: 'POST',\n url,\n params: {\n m: 'getAppSharedSecret',\n school: this.school,\n v: 'i3.5',\n },\n data: {\n id: this.id,\n method: 'getAppSharedSecret',\n params: [\n {\n userName: '#anonymous#',\n password: '',\n },\n ],\n jsonrpc: '2.0',\n },\n });\n\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n\n // OTP never changes when using anonymous login\n const otp = 100170;\n const time = new Date().getTime();\n return await this._otpLogin(otp, this.username, time, true);\n }\n}\n"],"names":["WebUntisDay","WebUntisElementType","__publicField","parse","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A,CAAA,2BAAA,CAAA,CAAA;AAEZ,IAAM,MAAA,QAAA,GAAW,MAAM,IAAA,CAAK,KAAM,CAAA;AAAA,MAC9B,MAAQ,EAAA,MAAA;AAAA,MACR,GAAA;AAAA,MACA,MAAQ,EAAA;AAAA,QACJ,CAAG,EAAA,oBAAA;AAAA,QACH,QAAQ,IAAK,CAAA,MAAA;AAAA,QACb,CAAG,EAAA,MAAA;AAAA,OACP;AAAA,MACA,IAAM,EAAA;AAAA,QACF,IAAI,IAAK,CAAA,EAAA;AAAA,QACT,MAAQ,EAAA,oBAAA;AAAA,QACR,MAAQ,EAAA;AAAA,UACJ;AAAA,YACI,QAAU,EAAA,aAAA;AAAA,YACV,QAAU,EAAA,EAAA;AAAA,WACd;AAAA,SACJ;AAAA,QACA,OAAS,EAAA,KAAA;AAAA,OACb;AAAA,KACH,CAAA,CAAA;AAED,IAAI,IAAA,QAAA,CAAS,IAAQ,IAAA,QAAA,CAAS,IAAK,CAAA,KAAA;AAC/B,MAAA,MAAM,IAAI,KAAM,CAAA,mBAAA,IAAuB,SAAS,IAAK,CAAA,KAAA,CAAM,WAAW,EAAG,CAAA,CAAA,CAAA;AAG7E,IAAA,MAAM,GAAM,GAAA,MAAA,CAAA;AACZ,IAAA,MAAM,IAAO,GAAA,iBAAA,IAAI,IAAK,EAAA,EAAE,OAAQ,EAAA,CAAA;AAChC,IAAA,OAAO,MAAM,IAAK,CAAA,SAAA,CAAU,KAAK,IAAK,CAAA,QAAA,EAAU,MAAM,IAAI,CAAA,CAAA;AAAA,GAC9D;AACJ;;;;;;;;;;;"} \ No newline at end of file diff --git a/dist/webuntis.mjs b/dist/webuntis.mjs index e1f11b0..acf470b 100644 --- a/dist/webuntis.mjs +++ b/dist/webuntis.mjs @@ -86,19 +86,34 @@ var WebUntisElementType = /* @__PURE__ */ ((WebUntisElementType2) => { return WebUntisElementType2; })(WebUntisElementType || {}); -class Base { - school; - schoolbase64; - username; - password; - baseurl; - cookies; - id; - sessionInformation; - anonymous; - axios; - static TYPES = WebUntisElementType; +var __defProp$1 = Object.defineProperty; +var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; +var __publicField$1 = (obj, key, value) => { + __defNormalProp$1(obj, typeof key !== "symbol" ? key + "" : key, value); + return value; +}; +const _Base = class _Base { + /** + * + * @constructor + * @param {string} school The school identifier + * @param {string} username + * @param {string} password + * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com) + * @param {string} [identity="Awesome"] A identity like: MyAwesomeApp + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(school, username, password, baseurl, identity = "Awesome", disableUserAgent = false) { + __publicField$1(this, "school"); + __publicField$1(this, "schoolbase64"); + __publicField$1(this, "username"); + __publicField$1(this, "password"); + __publicField$1(this, "baseurl"); + __publicField$1(this, "cookies"); + __publicField$1(this, "id"); + __publicField$1(this, "sessionInformation"); + __publicField$1(this, "anonymous"); + __publicField$1(this, "axios"); this.school = school; this.schoolbase64 = "_" + btoa(this.school); this.username = username; @@ -126,6 +141,9 @@ class Base { } }); } + /** + * Logout the current session + */ async logout() { await this.axios({ method: "POST", @@ -143,6 +161,14 @@ class Base { this.sessionInformation = null; return true; } + /** + * Login with your credentials + * + * **Notice: The server may revoke this session after less than 10min of idle.** + * + * *Untis says in the official docs:* + * > An application should always log out as soon as possible to free system resources on the server. + */ async login() { const response = await this.axios({ method: "POST", @@ -172,11 +198,15 @@ class Base { this.sessionInformation = response.data.result; return response.data.result; } + /** + * Get the latest WebUntis Schoolyear + * @param {Boolean} [validateSession=true] + */ async getLatestSchoolyear(validateSession = true) { const data = await this._request("getSchoolyears", {}, validateSession); data.sort((a, b) => { - const na = parse(a.startDate, "yyyyMMdd", new Date()); - const nb = parse(b.startDate, "yyyyMMdd", new Date()); + const na = parse(a.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); + const nb = parse(b.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); return nb.getTime() - na.getTime(); }); if (!data[0]) @@ -184,15 +214,19 @@ class Base { return { name: data[0].name, id: data[0].id, - startDate: parse(data[0].startDate, "yyyyMMdd", new Date()), - endDate: parse(data[0].endDate, "yyyyMMdd", new Date()) + startDate: parse(data[0].startDate, "yyyyMMdd", /* @__PURE__ */ new Date()), + endDate: parse(data[0].endDate, "yyyyMMdd", /* @__PURE__ */ new Date()) }; } + /** + * Get all WebUntis Schoolyears + * @param {Boolean} [validateSession=true] + */ async getSchoolyears(validateSession = true) { const data = await this._request("getSchoolyears", {}, validateSession); data.sort((a, b) => { - const na = parse(a.startDate, "yyyyMMdd", new Date()); - const nb = parse(b.startDate, "yyyyMMdd", new Date()); + const na = parse(a.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); + const nb = parse(b.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()); return nb.getTime() - na.getTime(); }); if (!data[0]) @@ -201,11 +235,17 @@ class Base { return { name: year.name, id: year.id, - startDate: parse(year.startDate, "yyyyMMdd", new Date()), - endDate: parse(year.endDate, "yyyyMMdd", new Date()) + startDate: parse(year.startDate, "yyyyMMdd", /* @__PURE__ */ new Date()), + endDate: parse(year.endDate, "yyyyMMdd", /* @__PURE__ */ new Date()) }; }); } + /** + * Get News Widget + * @param {Date} date + * @param {boolean} [validateSession=true] + * @returns {Promise} see index.d.ts NewsWidget + */ async getNewsWidget(date, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -213,7 +253,7 @@ class Base { method: "GET", url: `/WebUntis/api/public/news/newsWidgetData`, params: { - date: Base.convertDateToUntis(date) + date: _Base.convertDateToUntis(date) }, headers: { Cookie: this._buildCookies() @@ -223,6 +263,9 @@ class Base { throw new Error("Server returned invalid data."); return response.data.data; } + /** + * Get Inbox + */ async getInbox(validateSession = true) { this._checkAnonymous(); if (validateSession && !await this.validateSession()) @@ -246,12 +289,21 @@ class Base { throw new Error("This method is not supported with anonymous login"); } } + /** + * + * @returns {string} + * @private + */ _buildCookies() { let cookies = []; cookies.push(serialize("JSESSIONID", this.sessionInformation.sessionId)); cookies.push(serialize("schoolname", this.schoolbase64)); return cookies.join("; "); } + /** + * Get JWT Token + * @private + */ async _getJWT(validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -259,6 +311,7 @@ class Base { method: "GET", url: `/WebUntis/api/token/new`, headers: { + //Authorization: `Bearer ${this._getToken()}`, Cookie: this._buildCookies() } }); @@ -267,6 +320,9 @@ class Base { this.sessionInformation.jwt_token = response.data; return response.data; } + /** + * Checks if your current WebUntis Session is valid + */ async validateSession() { if (!this.sessionInformation) return false; @@ -288,22 +344,35 @@ class Base { }); return typeof response.data.result === "number"; } + /** + * Get the time when WebUntis last changed its data + * @param {Boolean} [validateSession=true] + */ async getLatestImportTime(validateSession = true) { return this._request("getLatestImportTime", {}, validateSession); } + /** + * + * @param id + * @param type + * @param startDate + * @param endDate + * @param validateSession + * @private + */ async _timetableRequest(id, type, startDate, endDate, validateSession = true) { const additionalOptions = {}; if (startDate) { - additionalOptions.startDate = Base.convertDateToUntis(startDate); + additionalOptions.startDate = _Base.convertDateToUntis(startDate); } if (endDate) { - additionalOptions.endDate = Base.convertDateToUntis(endDate); + additionalOptions.endDate = _Base.convertDateToUntis(endDate); } return this._request( "getTimetable", { options: { - id: new Date().getTime(), + id: (/* @__PURE__ */ new Date()).getTime(), element: { id, type @@ -324,6 +393,12 @@ class Base { validateSession ); } + /** + * Get your own Timetable for the current day + * Note: You can't use this with anonymous login + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getOwnTimetableForToday(validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -334,9 +409,22 @@ class Base { validateSession ); } + /** + * Get the timetable of today for a specific element. + * @param {number} id + * @param {WebUntisElementType} type + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getTimetableForToday(id, type, validateSession = true) { return await this._timetableRequest(id, type, null, null, validateSession); } + /** + * Get your own Timetable for the given day + * Note: You can't use this with anonymous login + * @param {Date} date + * @param {Boolean} [validateSession=true] + */ async getOwnTimetableFor(date, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -347,9 +435,24 @@ class Base { validateSession ); } + /** + * Get the timetable for a specific day for a specific element. + * @param {Date} date + * @param {number} id + * @param {WebUntisElementType} type + * @param {Boolean} [validateSession=true] + */ async getTimetableFor(date, id, type, validateSession = true) { return await this._timetableRequest(id, type, date, date, validateSession); } + /** + * Get your own timetable for a given Date range + * Note: You can't use this with anonymous login + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {Boolean} [validateSession=true] + * @returns {Promise.} + */ async getOwnTimetableForRange(rangeStart, rangeEnd, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -360,17 +463,45 @@ class Base { validateSession ); } + /** + * Get the timetable for a given Date range for specific element + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {number} id + * @param {WebUntisElementType} type + * @param {Boolean} [validateSession=true] + */ async getTimetableForRange(rangeStart, rangeEnd, id, type, validateSession = true) { return await this._timetableRequest(id, type, rangeStart, rangeEnd, validateSession); } + /** + * Get the Timetable of your class for today + * Note: You can't use this with anonymous login + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getOwnClassTimetableForToday(validateSession = true) { this._checkAnonymous(); return await this._timetableRequest(this.sessionInformation.klasseId, 1, null, null, validateSession); } + /** + * Get the Timetable of your class for the given day + * Note: You can't use this with anonymous login + * @param {Date} date + * @param {Boolean} [validateSession=true] + * @returns {Promise.} + */ async getOwnClassTimetableFor(date, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest(this.sessionInformation.klasseId, 1, date, date, validateSession); } + /** + * Get the Timetable of your class for a given Date range + * Note: You can't use this with anonymous login + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + */ async getOwnClassTimetableForRange(rangeStart, rangeEnd, validateSession = true) { this._checkAnonymous(); return await this._timetableRequest( @@ -381,6 +512,13 @@ class Base { validateSession ); } + /** + * + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getHomeWorksFor(rangeStart, rangeEnd, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -388,8 +526,8 @@ class Base { method: "GET", url: `/WebUntis/api/homeworks/lessons`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd) + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd) }, headers: { Cookie: this._buildCookies() @@ -401,22 +539,51 @@ class Base { throw new Error("Data object doesn't contains homeworks object."); return response.data.data; } - static convertUntisDate(date, baseDate = startOfDay(new Date())) { + /** + * Converts the untis date string format to a normal JS Date object + * @param {string} date Untis date string + * @param {Date} [baseDate=new Date()] Base date. Default beginning of current day + * @static + */ + static convertUntisDate(date, baseDate = startOfDay(/* @__PURE__ */ new Date())) { if (typeof date !== "string") date = `${date}`; return parse(date, "yyyyMMdd", baseDate); } - static convertUntisTime(time, baseDate = new Date()) { + /** + * Convert a untis time string to a JS Date object + * @param {string|number} time Untis time string + * @param {Date} [baseDate=new Date()] Day used as base for the time. Default: Current date + * @static + */ + static convertUntisTime(time, baseDate = /* @__PURE__ */ new Date()) { if (typeof time !== "string") time = `${time}`; return parse(time.padStart(4, "0"), "Hmm", baseDate); } + /** + * Get all known Subjects for the current logged-in user + * @param {boolean} [validateSession=true] + */ async getSubjects(validateSession = true) { return await this._request("getSubjects", {}, validateSession); } + /** + * Get the timegrid of current school + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getTimegrid(validateSession = true) { return await this._request("getTimegridUnits", {}, validateSession); } + /** + * + * TODO: Find out what type this function returns + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getHomeWorkAndLessons(rangeStart, rangeEnd, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -424,8 +591,8 @@ class Base { method: "GET", url: `/WebUntis/api/homeworks/lessons`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd) + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd) }, headers: { Cookie: this._buildCookies() @@ -437,6 +604,14 @@ class Base { throw new Error("Data object doesn't contains homeworks object."); return response.data.data; } + /** + * Get Exams for range + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {Number} klasseId + * @param {boolean} withGrades + * @param {boolean} [validateSession=true] + */ async getExamsForRange(rangeStart, rangeEnd, klasseId = -1, withGrades = false, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -444,8 +619,8 @@ class Base { method: "GET", url: `/WebUntis/api/exams`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd), + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd), klasseId, withGrades }, @@ -459,6 +634,14 @@ class Base { throw new Error("Data object doesn't contains exams object."); return response.data.data["exams"]; } + /** + * Get the timetable for the current week for a specific element from the web client API. + * @param {Date} date one date in the week to query + * @param {number} id element id + * @param {WebUntisElementType} type element type + * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response + * @param {Boolean} [validateSession=true] + */ async getTimetableForWeek(date, id, type, formatId = 1, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -496,14 +679,21 @@ class Base { }; const timetable = data.elementPeriods[id].map((lesson) => ({ ...lesson, - classes: formatElements(lesson.elements, { byType: Base.TYPES.CLASS }), - teachers: formatElements(lesson.elements, { byType: Base.TYPES.TEACHER }), - subjects: formatElements(lesson.elements, { byType: Base.TYPES.SUBJECT }), - rooms: formatElements(lesson.elements, { byType: Base.TYPES.ROOM }), - students: formatElements(lesson.elements, { byType: Base.TYPES.STUDENT }) + classes: formatElements(lesson.elements, { byType: _Base.TYPES.CLASS }), + teachers: formatElements(lesson.elements, { byType: _Base.TYPES.TEACHER }), + subjects: formatElements(lesson.elements, { byType: _Base.TYPES.SUBJECT }), + rooms: formatElements(lesson.elements, { byType: _Base.TYPES.ROOM }), + students: formatElements(lesson.elements, { byType: _Base.TYPES.STUDENT }) })); return timetable; } + /** + * Get the timetable for the current week for the current element from the web client API. + * @param {Date} date one date in the week to query + * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response + * @param {Boolean} [validateSession=true] + * @returns {Promise} + */ async getOwnTimetableForWeek(date, formatId = 1, validateSession = true) { this._checkAnonymous(); return await this.getTimetableForWeek( @@ -514,31 +704,81 @@ class Base { validateSession ); } + /** + * Get all known teachers by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getTeachers(validateSession = true) { return await this._request("getTeachers", {}, validateSession); } + /** + * Get all known students by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getStudents(validateSession = true) { return await this._request("getStudents", {}, validateSession); } + /** + * Get all known rooms by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getRooms(validateSession = true) { return await this._request("getRooms", {}, validateSession); } + /** + * Get all classes known by WebUntis + * @param {boolean} [validateSession=true] + * @param {number} schoolyearId + * @returns {Promise.} + */ async getClasses(validateSession = true, schoolyearId) { const data = typeof schoolyearId !== "number" ? {} : { schoolyearId }; return await this._request("getKlassen", data, validateSession); } + /** + * Get all departments known by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getDepartments(validateSession = true) { return await this._request("getDepartments", {}, validateSession); } + /** + * Get all holidays known by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getHolidays(validateSession = true) { return await this._request("getHolidays", {}, validateSession); } + /** + * Get all status data known by WebUntis + * @param {boolean} [validateSession=true] + * @returns {Promise.} + */ async getStatusData(validateSession = true) { return await this._request("getStatusData", {}, validateSession); } + /** + * Convert a JS Date Object to a WebUntis date string + * @param {Date} date + * @returns {String} + */ static convertDateToUntis(date) { return date.getFullYear().toString() + (date.getMonth() + 1 < 10 ? "0" + (date.getMonth() + 1) : date.getMonth() + 1).toString() + (date.getDate() < 10 ? "0" + date.getDate() : date.getDate()).toString(); } + /** + * Make a JSON RPC Request with the current session + * @param {string} method + * @param {Object} [parameter={}] + * @param {string} [url='/WebUntis/jsonrpc.do?school=SCHOOL'] + * @param {boolean} [validateSession=true] Whether the session should be checked first + * @returns {Promise.} + * @private + */ async _request(method, parameter = {}, validateSession = true, url = `/WebUntis/jsonrpc.do`) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -564,6 +804,14 @@ class Base { throw new Error("Server returned error code: " + response.data.result.code); return response.data.result; } + /** + * Returns all the Lessons where you were absent including the excused one! + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {Integer} [excuseStatusId=-1] + * @param {boolean} [validateSession=true] + * @returns {Promise} + */ async getAbsentLesson(rangeStart, rangeEnd, excuseStatusId = -1, validateSession = true) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -572,8 +820,8 @@ class Base { method: "GET", url: `/WebUntis/api/classreg/absences/students`, params: { - startDate: Base.convertDateToUntis(rangeStart), - endDate: Base.convertDateToUntis(rangeEnd), + startDate: _Base.convertDateToUntis(rangeStart), + endDate: _Base.convertDateToUntis(rangeEnd), studentId: this.sessionInformation.personId, excuseStatusId }, @@ -585,6 +833,16 @@ class Base { throw new Error("Server returned no data!"); return response.data.data; } + /** + * Returns a URL to a unique PDF of all the lessons you were absent + * @param {Date} rangeStart + * @param {Date} rangeEnd + * @param {boolean} [validateSession=true] + * @param {Integer} [excuseStatusId=-1] + * @param {boolean} [lateness=true] + * @param {boolean} [absences=true] + * @param {boolean} [excuseGroup=2] + */ async getPdfOfAbsentLesson(rangeStart, rangeEnd, validateSession = true, excuseStatusId = -1, lateness = true, absences = true, excuseGroup = 2) { if (validateSession && !await this.validateSession()) throw new Error("Current Session is not valid"); @@ -595,8 +853,8 @@ class Base { params: { name: "Excuse", format: "pdf", - rpt_sd: Base.convertDateToUntis(rangeStart), - rpt_ed: Base.convertDateToUntis(rangeEnd), + rpt_sd: _Base.convertDateToUntis(rangeStart), + rpt_ed: _Base.convertDateToUntis(rangeEnd), excuseStatusId, studentId: this.sessionInformation.personId, withLateness: lateness, @@ -613,7 +871,9 @@ class Base { const pdfDownloadURL = this.baseurl + "WebUntis/reports.do?msgId=" + res.messageId + "&" + res.reportParams; return pdfDownloadURL; } -} +}; +__publicField$1(_Base, "TYPES", WebUntisElementType); +let Base = _Base; class InternalWebuntisSecretLogin extends Base { constructor(school, username, password, baseurl, identity = "Awesome", disableUserAgent = false) { super(school, username, password, baseurl, identity, disableUserAgent); @@ -704,6 +964,13 @@ class InternalWebuntisSecretLogin extends Base { } return this.sessionInformation; } + /** + * + * @param {Array} setCookieArray + * @param {string} [cookieName="JSESSIONID"] + * @return {string|boolean} + * @private + */ _getCookieFromSetCookie(setCookieArray, cookieName = "JSESSIONID") { if (!setCookieArray) return; @@ -727,11 +994,29 @@ class InternalWebuntisSecretLogin extends Base { } } +var __defProp = Object.defineProperty; +var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value; +var __publicField = (obj, key, value) => { + __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value); + return value; +}; class WebUntisSecretAuth extends InternalWebuntisSecretLogin { - secret; - authenticator; + /** + * + * @constructor + * @augments WebUntis + * @param {string} school The school identifier + * @param {string} user + * @param {string} secret + * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com) + * @param {string} [identity="Awesome"] A identity like: MyAwesomeApp + * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration. + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(school, user, secret, baseurl, identity = "Awesome", authenticator, disableUserAgent = false) { super(school, user, null, baseurl, identity, disableUserAgent); + __publicField(this, "secret"); + __publicField(this, "authenticator"); this.secret = secret; this.authenticator = authenticator; if (!authenticator) { @@ -744,14 +1029,24 @@ class WebUntisSecretAuth extends InternalWebuntisSecretLogin { this.authenticator = authenticator; } } + // @ts-ignore async login() { const token = this.authenticator.generate(this.secret); - const time = new Date().getTime(); + const time = (/* @__PURE__ */ new Date()).getTime(); return await this._otpLogin(token, this.username, time); } } class WebUntisQR extends WebUntisSecretAuth { + /** + * Use the data you get from a WebUntis QR code + * @constructor + * @param {string} QRCodeURI A WebUntis uri. This is the data you get from the QR Code from the webuntis webapp under profile->Data access->Display + * @param {string} [identity="Awesome"] A identity like: MyAwesomeApp + * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration. + * @param {Object} URL Custom whatwg url implementation. Default will use the nodejs implementation. + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(QRCodeURI, identity, authenticator, URL, disableUserAgent = false) { let URLImplementation = URL; if (!URL) { @@ -776,6 +1071,13 @@ class WebUntisQR extends WebUntisSecretAuth { } class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin { + /** + * + * @param {string} school + * @param {string} baseurl + * @param {string} [identity='Awesome'] + * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent + */ constructor(school, baseurl, identity = "Awesome", disableUserAgent = false) { super(school, null, null, baseurl, identity, disableUserAgent); this.username = "#anonymous#"; @@ -806,7 +1108,7 @@ class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin { if (response.data && response.data.error) throw new Error("Failed to login. " + (response.data.error.message || "")); const otp = 100170; - const time = new Date().getTime(); + const time = (/* @__PURE__ */ new Date()).getTime(); return await this._otpLogin(otp, this.username, time, true); } } diff --git a/dist/webuntis.mjs.map b/dist/webuntis.mjs.map index a0cadeb..0f0c98e 100644 --- a/dist/webuntis.mjs.map +++ b/dist/webuntis.mjs.map @@ -1 +1 @@ -{"version":3,"file":"webuntis.mjs","sources":["../src/cookie.ts","../src/base-64.ts","../src/types.ts","../src/base.ts","../src/secret.ts","../src/qr.ts","../src/anonymous.ts"],"sourcesContent":["/**\n * Shamelessly stolen from @tinyhttp/cookie.\n *\n * Because @tinyhttp/cookie doesn't provide a commonjs build, I just decided to include the source code.\n * We need a cjs build, because we generate both esm and cjs.\n */\n\nconst pairSplitRegExp = /; */;\n\n/**\n * RegExp to match field-content in RFC 7230 sec 3.2\n *\n * field-content = field-vchar [ 1*( SP / HTAB ) field-vchar ]\n * field-vchar = VCHAR / obs-text\n * obs-text = %x80-FF\n */\n\n// eslint-disable-next-line no-control-regex\nconst fieldContentRegExp = /^[\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+$/;\n\nfunction tryDecode(str: string, decode: (str: string) => string) {\n try {\n return decode(str);\n } catch (e) {\n return str;\n }\n}\n\n/**\n * Parse a cookie header.\n *\n * Parse the given cookie header string into an object\n * The object has the various cookies as keys(names) => values\n *\n */\nexport function parse(\n str: string,\n options: {\n decode: (str: string) => string;\n } = {\n decode: decodeURIComponent,\n }\n): Record {\n const obj: Record = {};\n const pairs = str.split(pairSplitRegExp);\n\n for (const pair of pairs) {\n let eqIdx = pair.indexOf('=');\n\n // skip things that don't look like key=value\n if (eqIdx < 0) continue;\n\n const key = pair.substr(0, eqIdx).trim();\n let val = pair.substr(++eqIdx, pair.length).trim();\n\n // quoted values\n if ('\"' == val[0]) val = val.slice(1, -1);\n\n // only assign once\n if (obj[key] == null) obj[key] = tryDecode(val, options.decode);\n }\n\n return obj;\n}\n\nexport type SerializeOptions = Partial<{\n encode: (str: string) => string;\n maxAge: number;\n domain: string;\n path: string;\n httpOnly: boolean;\n secure: boolean;\n sameSite: boolean | 'Strict' | 'strict' | 'Lax' | 'lax' | 'None' | 'none' | string;\n expires: Date;\n}>;\n\nexport function serialize(name: string, val: string, opt: SerializeOptions = {}): string {\n if (!opt.encode) opt.encode = encodeURIComponent;\n\n if (!fieldContentRegExp.test(name)) throw new TypeError('argument name is invalid');\n\n const value = opt.encode(val);\n\n if (value && !fieldContentRegExp.test(value)) throw new TypeError('argument val is invalid');\n\n let str = name + '=' + value;\n\n if (null != opt.maxAge) {\n const maxAge = opt.maxAge - 0;\n\n if (isNaN(maxAge) || !isFinite(maxAge)) throw new TypeError('option maxAge is invalid');\n\n str += '; Max-Age=' + Math.floor(maxAge);\n }\n\n if (opt.domain) {\n if (!fieldContentRegExp.test(opt.domain)) throw new TypeError('option domain is invalid');\n\n str += '; Domain=' + opt.domain;\n }\n\n if (opt.path) {\n if (!fieldContentRegExp.test(opt.path)) throw new TypeError('option path is invalid');\n\n str += '; Path=' + opt.path;\n }\n\n if (opt.expires) str += '; Expires=' + opt.expires.toUTCString();\n\n if (opt.httpOnly) str += '; HttpOnly';\n\n if (opt.secure) str += '; Secure';\n\n if (opt.sameSite) {\n const sameSite = typeof opt.sameSite === 'string' ? opt.sameSite.toLowerCase() : opt.sameSite;\n\n switch (sameSite) {\n case true:\n case 'strict':\n str += '; SameSite=Strict';\n break;\n case 'lax':\n str += '; SameSite=Lax';\n break;\n case 'none':\n str += '; SameSite=None';\n break;\n default:\n throw new TypeError('option sameSite is invalid');\n }\n }\n\n return str;\n}\n","const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\nexport function btoa(input = '') {\n let str = input;\n let output = '';\n\n for (\n let block = 0, charCode, i = 0, map = chars;\n str.charAt(i | 0) || ((map = '='), i % 1);\n output += map.charAt(63 & (block >> (8 - (i % 1) * 8)))\n ) {\n charCode = str.charCodeAt((i += 3 / 4));\n\n if (charCode > 0xff) {\n throw new Error(\"'btoa' failed: The string to be encoded contains characters outside of the Latin1 range.\");\n }\n\n block = (block << 8) | charCode;\n }\n\n return output;\n}\n","export interface SchoolYear {\n name: string;\n id: number;\n startDate: Date;\n endDate: Date;\n}\n\nexport interface MessagesOfDay {\n id: number;\n subject: string;\n text: string;\n isExpanded: boolean;\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: any[];\n}\n\nexport interface NewsWidget {\n /**\n * Unknown type. I have never seen this in use.\n */\n systemMessage: any;\n messagesOfDay: MessagesOfDay[];\n rssUrl: string;\n}\n\nexport interface Messagesender {\n userId: number;\n displayName: string;\n imageUrl: string;\n className: string;\n}\n\nexport interface Inboxmessage {\n allowMessageDeletion: boolean;\n contentPreview: string;\n hasAttachments: boolean;\n id: number;\n isMessageRead: boolean;\n isReply: boolean;\n isReplyAllowed: boolean;\n sender: Messagesender;\n sentDateTime: string;\n subject: string;\n}\n\nexport interface Inbox {\n incomingMessages: Inboxmessage[];\n}\n\nexport interface ShortData {\n id: number;\n name: string;\n longname: string;\n orgname?: string;\n orgid?: number;\n}\n\nexport interface Lesson {\n id: number;\n date: number;\n startTime: number;\n endTime: number;\n kl: ShortData[];\n te: ShortData[];\n su: ShortData[];\n ro: ShortData[];\n lstext?: string;\n lsnumber: number;\n activityType?: 'Unterricht' | string;\n code?: 'cancelled' | 'irregular';\n info?: string;\n substText?: string;\n statflags?: string;\n sg?: string;\n bkRemark?: string;\n bkText?: string;\n}\n\nexport interface Homework {\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: Array;\n completed: boolean;\n date: number;\n dueDate: number;\n id: number;\n lessonId: number;\n remark: string;\n text: string;\n}\n\nexport interface Subject {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport enum WebUntisDay {\n Sunday = 1,\n Monday = 2,\n Tuesday = 3,\n Wednesday = 4,\n Thursday = 5,\n Friday = 6,\n Saturday = 7,\n}\n\nexport interface TimeUnit {\n name: string;\n startTime: number;\n endTime: number;\n}\n\nexport interface Timegrid {\n day: WebUntisDay;\n timeUnits: TimeUnit[];\n}\n\nexport interface Exam {\n id: number;\n examType: string;\n name: string;\n studentClass: string[];\n assignedStudents: {\n klasse: { id: number; name: string };\n displayName: string;\n id: number;\n }[];\n examDate: number;\n startTime: number;\n endTime: number;\n subject: string;\n teachers: string[];\n rooms: string[];\n text: string;\n grade?: string;\n}\n\nexport enum WebUntisElementType {\n CLASS = 1,\n TEACHER = 2,\n SUBJECT = 3,\n ROOM = 4,\n STUDENT = 5,\n}\n\nexport interface WebElement {\n type: WebUntisElementType;\n id: number;\n orgId: number;\n missing: boolean;\n state: 'REGULAR' | 'ABSENT' | 'SUBSTITUTED';\n}\n\nexport interface WebElementData extends WebElement {\n element: {\n type: number;\n id: number;\n name: string;\n longName?: string;\n displayname?: string;\n alternatename?: string;\n canViewTimetable: boolean;\n externalKey?: string;\n roomCapacity: number;\n };\n}\n\nexport interface WebAPITimetable {\n id: number;\n lessonId: number;\n lessonNumber: number;\n lessonCode: string;\n lessonText: string;\n periodText: string;\n hasPeriodText: false;\n periodInfo: string;\n periodAttachments: [];\n substText: string;\n date: number;\n startTime: number;\n endTime: number;\n elements: WebElement[];\n studentGroup: string;\n hasInfo: boolean;\n code: number;\n cellState: 'STANDARD' | 'SUBSTITUTION' | 'ROOMSUBSTITUTION';\n priority: number;\n is: {\n roomSubstitution?: boolean;\n substitution?: boolean;\n standard?: boolean;\n event: boolean;\n };\n roomCapacity: number;\n studentCount: number;\n classes: WebElementData[];\n teachers: WebElementData[];\n subjects: WebElementData[];\n rooms: WebElementData[];\n students: WebElementData[];\n}\n\nexport interface Teacher {\n id: number;\n name: string;\n foreName: string;\n longName: string;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Student {\n id: number;\n key: number;\n name: string;\n foreName: string;\n longName: string;\n gender: string;\n}\n\nexport interface Room {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Klasse {\n id: number;\n name: string;\n longName: string;\n active: boolean;\n}\n\nexport interface Department {\n id: number;\n name: string;\n longName: string;\n}\n\nexport interface Holiday {\n name: string;\n longName: string;\n id: number;\n startDate: number;\n endDate: number;\n}\n\nexport interface ColorEntity {\n foreColor: string;\n backColor: string;\n}\n\nexport interface LsEntity {\n ls?: ColorEntity | null;\n oh?: ColorEntity | null;\n sb?: ColorEntity | null;\n bs?: ColorEntity | null;\n ex?: ColorEntity | null;\n}\n\nexport interface CodesEntity {\n cancelled?: ColorEntity | null;\n irregular?: ColorEntity | null;\n}\n\nexport interface StatusData {\n lstypes: LsEntity[];\n codes: CodesEntity[];\n}\n\nexport interface Absences {\n absences: Absence[];\n absenceReasons: [];\n excuseStatuses: boolean;\n showAbsenceReasonChange: boolean;\n showCreateAbsence: boolean;\n}\n\nexport interface Absence {\n id: number;\n startDate: number;\n endDate: number;\n startTime: number;\n endTime: number;\n createDate: number;\n lastUpdate: number;\n createdUser: string;\n updatedUser: string;\n reasonId: number;\n reason: string;\n text: string;\n interruptions: [];\n canEdit: boolean;\n studentName: string;\n excuseStatus: string;\n isExcused: boolean;\n excuse: Excuse;\n}\n\nexport interface Excuse {\n id: number;\n text: string;\n excuseDate: number;\n excuseStatus: string;\n isExcused: boolean;\n userId: number;\n username: string;\n}\n","import { serialize } from './cookie';\nimport axios from 'axios';\nimport { btoa } from './base-64';\nimport { parse, startOfDay, format } from 'date-fns';\nimport type { AxiosInstance } from 'axios';\nimport type {\n Absences,\n Department,\n Exam,\n Holiday,\n Homework,\n Inbox,\n Klasse,\n Lesson,\n NewsWidget,\n Room,\n SchoolYear,\n StatusData,\n Student,\n Subject,\n Teacher,\n Timegrid,\n WebAPITimetable,\n} from './types';\nimport type { InternalSchoolYear, SessionInformation } from './internal';\nimport { WebUntisElementType } from './types';\n\nexport class Base {\n school: string;\n schoolbase64: string;\n username: string;\n password: string;\n baseurl: string;\n cookies: string[];\n id: string;\n sessionInformation: SessionInformation | null;\n anonymous: boolean;\n\n axios: AxiosInstance;\n\n static TYPES = WebUntisElementType;\n\n /**\n *\n * @constructor\n * @param {string} school The school identifier\n * @param {string} username\n * @param {string} password\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false\n ) {\n this.school = school;\n this.schoolbase64 = '_' + btoa(this.school);\n this.username = username;\n this.password = password;\n this.baseurl = 'https://' + baseurl + '/';\n this.cookies = [];\n this.id = identity;\n this.sessionInformation = {};\n this.anonymous = false;\n\n const additionalHeaders: Record = {};\n\n if (!disableUserAgent) {\n additionalHeaders['User-Agent'] =\n 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.79 Safari/537.36';\n }\n\n this.axios = axios.create({\n baseURL: this.baseurl,\n maxRedirects: 0,\n headers: {\n 'Cache-Control': 'no-cache',\n Pragma: 'no-cache',\n 'X-Requested-With': 'XMLHttpRequest',\n ...additionalHeaders,\n },\n validateStatus: function (status) {\n return status >= 200 && status < 303; // default\n },\n });\n }\n\n /**\n * Logout the current session\n */\n async logout(): Promise {\n await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'logout',\n params: {},\n jsonrpc: '2.0',\n },\n });\n this.sessionInformation = null;\n return true;\n }\n\n /**\n * Login with your credentials\n *\n * **Notice: The server may revoke this session after less than 10min of idle.**\n *\n * *Untis says in the official docs:*\n * > An application should always log out as soon as possible to free system resources on the server.\n */\n async login(): Promise {\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'authenticate',\n params: {\n user: this.username,\n password: this.password,\n client: this.id,\n },\n jsonrpc: '2.0',\n },\n });\n if (typeof response.data !== 'object') throw new Error('Failed to parse server response.');\n if (!response.data.result) throw new Error('Failed to login. ' + JSON.stringify(response.data));\n if (response.data.result.code) throw new Error('Login returned error code: ' + response.data.result.code);\n if (!response.data.result.sessionId) throw new Error('Failed to login. No session id.');\n this.sessionInformation = response.data.result;\n return response.data.result;\n }\n\n /**\n * Get the latest WebUntis Schoolyear\n * @param {Boolean} [validateSession=true]\n */\n async getLatestSchoolyear(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return {\n name: data[0].name,\n id: data[0].id,\n startDate: parse(data[0].startDate, 'yyyyMMdd', new Date()),\n endDate: parse(data[0].endDate, 'yyyyMMdd', new Date()),\n };\n }\n\n /**\n * Get all WebUntis Schoolyears\n * @param {Boolean} [validateSession=true]\n */\n async getSchoolyears(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return data.map((year) => {\n return {\n name: year.name,\n id: year.id,\n startDate: parse(year.startDate, 'yyyyMMdd', new Date()),\n endDate: parse(year.endDate, 'yyyyMMdd', new Date()),\n };\n });\n }\n\n /**\n * Get News Widget\n * @param {Date} date\n * @param {boolean} [validateSession=true]\n * @returns {Promise} see index.d.ts NewsWidget\n */\n async getNewsWidget(date: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/news/newsWidgetData`,\n params: {\n date: Base.convertDateToUntis(date),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data.data;\n }\n\n /**\n * Get Inbox\n */\n async getInbox(validateSession = true): Promise {\n this._checkAnonymous();\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n //first get JWT Token\n if (typeof this.sessionInformation!.jwt_token != 'string') await this._getJWT();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/rest/view/v1/messages`,\n headers: {\n Authorization: `Bearer ${this.sessionInformation!.jwt_token}`,\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data;\n }\n\n private _checkAnonymous() {\n if (this.anonymous) {\n throw new Error('This method is not supported with anonymous login');\n }\n }\n\n /**\n *\n * @returns {string}\n * @private\n */\n _buildCookies() {\n let cookies = [];\n cookies.push(serialize('JSESSIONID', this.sessionInformation!.sessionId!));\n cookies.push(serialize('schoolname', this.schoolbase64));\n return cookies.join('; ');\n }\n\n /**\n * Get JWT Token\n * @private\n */\n async _getJWT(validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/token/new`,\n headers: {\n //Authorization: `Bearer ${this._getToken()}`,\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data !== 'string') throw new Error('Server returned invalid data.');\n this.sessionInformation!.jwt_token = response.data;\n return response.data;\n }\n\n /**\n * Checks if your current WebUntis Session is valid\n */\n async validateSession(): Promise {\n if (!this.sessionInformation) return false;\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: 'getLatestImportTime',\n params: {},\n jsonrpc: '2.0',\n },\n });\n return typeof response.data.result === 'number';\n }\n\n /**\n * Get the time when WebUntis last changed its data\n * @param {Boolean} [validateSession=true]\n */\n async getLatestImportTime(validateSession = true): Promise {\n return this._request('getLatestImportTime', {}, validateSession);\n }\n\n /**\n *\n * @param id\n * @param type\n * @param startDate\n * @param endDate\n * @param validateSession\n * @private\n */\n private async _timetableRequest(\n id: string | number,\n type: number,\n startDate?: Date | null,\n endDate?: Date | null,\n validateSession = true\n ): Promise {\n const additionalOptions: Record = {};\n if (startDate) {\n additionalOptions.startDate = Base.convertDateToUntis(startDate);\n }\n if (endDate) {\n additionalOptions.endDate = Base.convertDateToUntis(endDate);\n }\n\n return this._request(\n 'getTimetable',\n {\n options: {\n id: new Date().getTime(),\n element: {\n id,\n type,\n },\n ...additionalOptions,\n showLsText: true,\n showStudentgroup: true,\n showLsNumber: true,\n showSubstText: true,\n showInfo: true,\n showBooking: true,\n klasseFields: ['id', 'name', 'longname', 'externalkey'],\n roomFields: ['id', 'name', 'longname', 'externalkey'],\n subjectFields: ['id', 'name', 'longname', 'externalkey'],\n teacherFields: ['id', 'name', 'longname', 'externalkey'],\n },\n },\n validateSession\n );\n }\n\n /**\n * Get your own Timetable for the current day\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n null,\n null,\n validateSession\n );\n }\n\n /**\n * Get the timetable of today for a specific element.\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getTimetableForToday(id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, null, null, validateSession);\n }\n\n /**\n * Get your own Timetable for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n */\n async getOwnTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n date,\n date,\n validateSession\n );\n }\n\n /**\n * Get the timetable for a specific day for a specific element.\n * @param {Date} date\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableFor(date: Date, id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, date, date, validateSession);\n }\n\n /**\n * Get your own timetable for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n rangeStart,\n rangeEnd,\n validateSession\n );\n }\n\n /**\n * Get the timetable for a given Date range for specific element\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForRange(\n rangeStart: Date,\n rangeEnd: Date,\n id: number,\n type: number,\n validateSession = true\n ): Promise {\n return await this._timetableRequest(id, type, rangeStart, rangeEnd, validateSession);\n }\n\n /**\n * Get the Timetable of your class for today\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnClassTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, null, null, validateSession);\n }\n\n /**\n * Get the Timetable of your class for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnClassTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, date, date, validateSession);\n }\n\n /**\n * Get the Timetable of your class for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n */\n async getOwnClassTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.klasseId!,\n 1,\n rangeStart,\n rangeEnd,\n validateSession\n );\n }\n\n /**\n *\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorksFor(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Converts the untis date string format to a normal JS Date object\n * @param {string} date Untis date string\n * @param {Date} [baseDate=new Date()] Base date. Default beginning of current day\n * @static\n */\n static convertUntisDate(date: string, baseDate = startOfDay(new Date())): Date {\n if (typeof date !== 'string') date = `${date}`;\n return parse(date, 'yyyyMMdd', baseDate);\n }\n\n /**\n * Convert a untis time string to a JS Date object\n * @param {string|number} time Untis time string\n * @param {Date} [baseDate=new Date()] Day used as base for the time. Default: Current date\n * @static\n */\n static convertUntisTime(time: number | string, baseDate = new Date()): Date {\n if (typeof time !== 'string') time = `${time}`;\n return parse(time.padStart(4, '0'), 'Hmm', baseDate);\n }\n\n /**\n * Get all known Subjects for the current logged-in user\n * @param {boolean} [validateSession=true]\n */\n async getSubjects(validateSession = true): Promise {\n return await this._request('getSubjects', {}, validateSession);\n }\n\n /**\n * Get the timegrid of current school\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTimegrid(validateSession = true): Promise {\n return await this._request('getTimegridUnits', {}, validateSession);\n }\n\n /**\n *\n * TODO: Find out what type this function returns\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorkAndLessons(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Get Exams for range\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Number} klasseId\n * @param {boolean} withGrades\n * @param {boolean} [validateSession=true]\n */\n async getExamsForRange(\n rangeStart: Date,\n rangeEnd: Date,\n klasseId = -1,\n withGrades = false,\n validateSession = true\n ): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/exams`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n klasseId: klasseId,\n withGrades: withGrades,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['exams']) throw new Error(\"Data object doesn't contains exams object.\");\n return response.data.data['exams'];\n }\n\n /**\n * Get the timetable for the current week for a specific element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {number} id element id\n * @param {WebUntisElementType} type element type\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForWeek(\n date: Date,\n id: number,\n type: number,\n formatId = 1,\n validateSession = true\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/timetable/weekly/data`,\n params: {\n elementType: type,\n elementId: id,\n date: format(date, 'yyyy-MM-dd'),\n formatId: formatId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n\n if (response.data.data.error) {\n /* known codes:\n * - ERR_TTVIEW_NOTALLOWED_ONDATE\n */\n const err = new Error('Server responded with error');\n // TODO: Make this better lol\n // @ts-ignore\n err.code = response.data.data.error?.data?.messageKey;\n throw err;\n }\n\n if (!response.data.data.result?.data?.elementPeriods?.[id]) throw new Error('Invalid response');\n\n const data = response.data.data.result.data;\n\n // TODO: improve typings\n\n const formatElements = (elements: Array>, { byType }: { byType: number }) => {\n const filteredElements = elements.filter((element) => element.type === byType);\n\n return filteredElements.map((element) => ({\n ...element,\n element: data.elements.find(\n (dataElement: Record) =>\n dataElement.type === byType && dataElement.id === element.id\n ),\n }));\n };\n\n const timetable = data.elementPeriods[id].map((lesson: any) => ({\n ...lesson,\n classes: formatElements(lesson.elements, { byType: Base.TYPES.CLASS }),\n teachers: formatElements(lesson.elements, { byType: Base.TYPES.TEACHER }),\n subjects: formatElements(lesson.elements, { byType: Base.TYPES.SUBJECT }),\n rooms: formatElements(lesson.elements, { byType: Base.TYPES.ROOM }),\n students: formatElements(lesson.elements, { byType: Base.TYPES.STUDENT }),\n }));\n\n return timetable;\n }\n\n /**\n * Get the timetable for the current week for the current element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForWeek(date: Date, formatId = 1, validateSession = true): Promise {\n this._checkAnonymous();\n return await this.getTimetableForWeek(\n date,\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n formatId,\n validateSession\n );\n }\n\n /**\n * Get all known teachers by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTeachers(validateSession = true): Promise {\n return await this._request('getTeachers', {}, validateSession);\n }\n\n /**\n * Get all known students by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStudents(validateSession = true): Promise {\n return await this._request('getStudents', {}, validateSession);\n }\n\n /**\n * Get all known rooms by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getRooms(validateSession = true): Promise {\n return await this._request('getRooms', {}, validateSession);\n }\n\n /**\n * Get all classes known by WebUntis\n * @param {boolean} [validateSession=true]\n * @param {number} schoolyearId\n * @returns {Promise.}\n */\n async getClasses(validateSession = true, schoolyearId: number): Promise {\n const data = typeof schoolyearId !== 'number' ? {} : { schoolyearId };\n return await this._request('getKlassen', data, validateSession);\n }\n\n /**\n * Get all departments known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getDepartments(validateSession = true): Promise {\n return await this._request('getDepartments', {}, validateSession);\n }\n\n /**\n * Get all holidays known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHolidays(validateSession = true): Promise {\n return await this._request('getHolidays', {}, validateSession);\n }\n\n /**\n * Get all status data known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStatusData(validateSession = true): Promise {\n return await this._request('getStatusData', {}, validateSession);\n }\n\n /**\n * Convert a JS Date Object to a WebUntis date string\n * @param {Date} date\n * @returns {String}\n */\n static convertDateToUntis(date: Date): string {\n return (\n date.getFullYear().toString() +\n (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1).toString() +\n (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()).toString()\n );\n }\n\n /**\n * Make a JSON RPC Request with the current session\n * @param {string} method\n * @param {Object} [parameter={}]\n * @param {string} [url='/WebUntis/jsonrpc.do?school=SCHOOL']\n * @param {boolean} [validateSession=true] Whether the session should be checked first\n * @returns {Promise.}\n * @private\n */\n async _request>(\n method: string,\n parameter: Record = {},\n validateSession = true,\n url = `/WebUntis/jsonrpc.do`\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'POST',\n url: url,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: method,\n params: parameter,\n jsonrpc: '2.0',\n },\n });\n if (!response.data.result) throw new Error(\"Server didn't return any result.\");\n if (response.data.result.code) throw new Error('Server returned error code: ' + response.data.result.code);\n return response.data.result;\n }\n\n /**\n * Returns all the Lessons where you were absent including the excused one!\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n excuseStatusId = -1,\n validateSession = true\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/classreg/absences/students`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n studentId: this.sessionInformation!.personId!,\n excuseStatusId: excuseStatusId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (response.data.data == null) throw new Error('Server returned no data!');\n return response.data.data;\n }\n\n /**\n * Returns a URL to a unique PDF of all the lessons you were absent\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [lateness=true]\n * @param {boolean} [absences=true]\n * @param {boolean} [excuseGroup=2]\n */\n async getPdfOfAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n validateSession = true,\n excuseStatusId = -1,\n lateness = true,\n absences = true,\n excuseGroup = 2\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/reports.do`,\n params: {\n name: 'Excuse',\n format: 'pdf',\n rpt_sd: Base.convertDateToUntis(rangeStart),\n rpt_ed: Base.convertDateToUntis(rangeEnd),\n excuseStatusId: excuseStatusId,\n studentId: this.sessionInformation!.personId!,\n withLateness: lateness,\n withAbsences: absences,\n execuseGroup: excuseGroup,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n const res = response.data.data;\n if (response.status != 200 || res.error) throw new Error('Server returned no data!');\n const pdfDownloadURL =\n this.baseurl + 'WebUntis/reports.do?' + 'msgId=' + res.messageId + '&' + res.reportParams;\n return pdfDownloadURL;\n }\n}\n\n/**\n * @private\n */\nexport class InternalWebuntisSecretLogin extends Base {\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false\n ) {\n super(school, username, password, baseurl, identity, disableUserAgent);\n }\n\n async _otpLogin(token: number | string, username: string, time: number, skipSessionInfo = false) {\n const response = await this.axios({\n method: 'POST',\n url: '/WebUntis/jsonrpc_intern.do',\n params: {\n m: 'getUserData2017',\n school: this.school,\n v: 'i2.2',\n },\n data: {\n id: this.id,\n method: 'getUserData2017',\n params: [\n {\n auth: {\n clientTime: time,\n user: username,\n otp: token,\n },\n },\n ],\n jsonrpc: '2.0',\n },\n });\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n if (!response.headers['set-cookie']) throw new Error(`Failed to login. Server didn't return a set-cookie`);\n if (!this._getCookieFromSetCookie(response.headers['set-cookie']))\n throw new Error(\"Failed to login. Server didn't return a session id.\");\n const sessionId = this._getCookieFromSetCookie(response.headers['set-cookie']);\n // Set session temporary\n this.sessionInformation = {\n sessionId: sessionId,\n };\n if (skipSessionInfo) return this.sessionInformation;\n\n // Get personId & personType\n const appConfigUrl = `/WebUntis/api/app/config`;\n const configResponse = await this.axios({\n method: 'GET',\n url: appConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof configResponse.data !== 'object' || typeof configResponse.data.data !== 'object')\n throw new Error('Failed to fetch app config while login. data (type): ' + typeof response.data);\n // Path -> data.loginServiceConfig.user.persons -> find person with id\n if (\n configResponse.data.data &&\n configResponse.data.data.loginServiceConfig &&\n configResponse.data.data.loginServiceConfig.user &&\n !Number.isInteger(configResponse.data.data.loginServiceConfig.user.personId)\n )\n throw new Error('Invalid personId. personId: ' + configResponse.data.data.loginServiceConfig.user.personId);\n const webUntisLoginServiceUser = configResponse.data.data.loginServiceConfig.user;\n if (!Array.isArray(webUntisLoginServiceUser.persons))\n throw new Error('Invalid person array. persons (type): ' + typeof webUntisLoginServiceUser.persons);\n const person = webUntisLoginServiceUser.persons.find(\n (value: Record) => value.id === configResponse.data.data.loginServiceConfig.user.personId\n );\n if (!person) throw new Error('Can not find person in person array.');\n if (!Number.isInteger(person.type)) throw new Error('Invalid person type. type (type): ' + person.type);\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n };\n // Get klasseId\n try {\n const dayConfigUrl = `/WebUntis/api/daytimetable/config`;\n const dayConfigResponse = await this.axios({\n method: 'GET',\n url: dayConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof dayConfigResponse.data !== 'object' || typeof dayConfigResponse.data.data !== 'object')\n throw new Error();\n if (!Number.isInteger(dayConfigResponse.data.data.klasseId)) throw new Error();\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n klasseId: dayConfigResponse.data.data.klasseId,\n };\n } catch (e) {\n // klasseId is not important. This request can fail\n }\n return this.sessionInformation;\n }\n\n /**\n *\n * @param {Array} setCookieArray\n * @param {string} [cookieName=\"JSESSIONID\"]\n * @return {string|boolean}\n * @private\n */\n _getCookieFromSetCookie(setCookieArray?: string[], cookieName = 'JSESSIONID') {\n if (!setCookieArray) return;\n for (let i = 0; i < setCookieArray.length; i++) {\n const setCookie = setCookieArray[i];\n if (!setCookie) continue;\n let cookieParts = setCookie.split(';');\n if (!cookieParts || !Array.isArray(cookieParts)) continue;\n for (let cookie of cookieParts) {\n cookie = cookie.trim();\n cookie = cookie.replace(/;/gm, '');\n const [Key, Value] = cookie.split('=');\n if (!Key || !Value) continue;\n if (Key === cookieName) return Value;\n }\n }\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\nimport type { authenticator } from 'otplib';\n\nexport type Authenticator = typeof authenticator;\n\nexport class WebUntisSecretAuth extends InternalWebuntisSecretLogin {\n private readonly secret: string;\n private authenticator: Authenticator;\n\n /**\n *\n * @constructor\n * @augments WebUntis\n * @param {string} school The school identifier\n * @param {string} user\n * @param {string} secret\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n user: string,\n secret: string,\n baseurl: string,\n identity = 'Awesome',\n authenticator: Authenticator,\n disableUserAgent = false\n ) {\n super(school, user, null as unknown as string, baseurl, identity, disableUserAgent);\n this.secret = secret;\n this.authenticator = authenticator;\n if (!authenticator) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the otplib object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n const { authenticator } = eval(\"require('otplib')\");\n this.authenticator = authenticator;\n }\n }\n\n // @ts-ignore\n async login() {\n // Get JSESSION\n const token = this.authenticator.generate(this.secret);\n const time = new Date().getTime();\n return await this._otpLogin(token, this.username, time);\n }\n}\n","import { WebUntisSecretAuth } from './secret';\nimport type { Authenticator } from './secret';\nimport type { URL } from 'url';\n\n/**\n * @private\n */\nexport type URLClass = typeof URL;\n\nexport class WebUntisQR extends WebUntisSecretAuth {\n /**\n * Use the data you get from a WebUntis QR code\n * @constructor\n * @param {string} QRCodeURI A WebUntis uri. This is the data you get from the QR Code from the webuntis webapp under profile->Data access->Display\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {Object} URL Custom whatwg url implementation. Default will use the nodejs implementation.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n QRCodeURI: string,\n identity: string,\n authenticator: Authenticator,\n URL?: URLClass,\n disableUserAgent = false\n ) {\n let URLImplementation = URL;\n if (!URL) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the URL object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n URLImplementation = eval(\"require('url').URL\") as URLClass;\n }\n const uri = new URLImplementation!(QRCodeURI);\n super(\n uri.searchParams.get('school')!,\n uri.searchParams.get('user')!,\n uri.searchParams.get('key')!,\n uri.searchParams.get('url')!,\n identity,\n authenticator,\n disableUserAgent\n );\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\n\nexport class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin {\n /**\n *\n * @param {string} school\n * @param {string} baseurl\n * @param {string} [identity='Awesome']\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(school: string, baseurl: string, identity = 'Awesome', disableUserAgent = false) {\n // TODO: Make this a bit more beautiful and more type safe\n super(school, null as unknown as string, null as unknown as string, baseurl, identity, disableUserAgent);\n this.username = '#anonymous#';\n this.anonymous = true;\n }\n\n override async login() {\n // Check whether the school has public access or not\n const url = `/WebUntis/jsonrpc_intern.do`;\n\n const response = await this.axios({\n method: 'POST',\n url,\n params: {\n m: 'getAppSharedSecret',\n school: this.school,\n v: 'i3.5',\n },\n data: {\n id: this.id,\n method: 'getAppSharedSecret',\n params: [\n {\n userName: '#anonymous#',\n password: '',\n },\n ],\n jsonrpc: '2.0',\n },\n });\n\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n\n // OTP never changes when using anonymous login\n const otp = 100170;\n const time = new Date().getTime();\n return await this._otpLogin(otp, this.username, time, true);\n }\n}\n"],"names":["WebUntisDay","WebUntisElementType"],"mappings":";;;AAkBA,MAAM,kBAAqB,GAAA,uCAAA,CAAA;AA0DpB,SAAS,SAAU,CAAA,IAAA,EAAc,GAAa,EAAA,GAAA,GAAwB,EAAY,EAAA;AACrF,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e,KAAQ,GAAA;AAEnB,IAAA,MAAM,GAAM,GAAA,CAAA,2BAAA,CAAA,CAAA;AAEZ,IAAM,MAAA,QAAA,GAAW,MAAM,IAAA,CAAK,KAAM,CAAA;AAAA,MAC9B,MAAQ,EAAA,MAAA;AAAA,MACR,GAAA;AAAA,MACA,MAAQ,EAAA;AAAA,QACJ,CAAG,EAAA,oBAAA;AAAA,QACH,QAAQ,IAAK,CAAA,MAAA;AAAA,QACb,CAAG,EAAA,MAAA;AAAA,OACP;AAAA,MACA,IAAM,EAAA;AAAA,QACF,IAAI,IAAK,CAAA,EAAA;AAAA,QACT,MAAQ,EAAA,oBAAA;AAAA,QACR,MAAQ,EAAA;AAAA,UACJ;AAAA,YACI,QAAU,EAAA,aAAA;AAAA,YACV,QAAU,EAAA,EAAA;AAAA,WACd;AAAA,SACJ;AAAA,QACA,OAAS,EAAA,KAAA;AAAA,OACb;AAAA,KACH,CAAA,CAAA;AAED,IAAI,IAAA,QAAA,CAAS,IAAQ,IAAA,QAAA,CAAS,IAAK,CAAA,KAAA;AAC/B,MAAA,MAAM,IAAI,KAAM,CAAA,mBAAA,IAAuB,SAAS,IAAK,CAAA,KAAA,CAAM,WAAW,EAAG,CAAA,CAAA,CAAA;AAG7E,IAAA,MAAM,GAAM,GAAA,MAAA,CAAA;AACZ,IAAA,MAAM,IAAO,GAAA,IAAI,IAAK,EAAA,CAAE,OAAQ,EAAA,CAAA;AAChC,IAAA,OAAO,MAAM,IAAK,CAAA,SAAA,CAAU,KAAK,IAAK,CAAA,QAAA,EAAU,MAAM,IAAI,CAAA,CAAA;AAAA,GAC9D;AACJ;;;;"} \ No newline at end of file +{"version":3,"file":"webuntis.mjs","sources":["../src/cookie.ts","../src/base-64.ts","../src/types.ts","../src/base.ts","../src/secret.ts","../src/qr.ts","../src/anonymous.ts"],"sourcesContent":["/**\n * Shamelessly stolen from @tinyhttp/cookie.\n *\n * Because @tinyhttp/cookie doesn't provide a commonjs build, I just decided to include the source code.\n * We need a cjs build, because we generate both esm and cjs.\n */\n\nconst pairSplitRegExp = /; */;\n\n/**\n * RegExp to match field-content in RFC 7230 sec 3.2\n *\n * field-content = field-vchar [ 1*( SP / HTAB ) field-vchar ]\n * field-vchar = VCHAR / obs-text\n * obs-text = %x80-FF\n */\n\n// eslint-disable-next-line no-control-regex\nconst fieldContentRegExp = /^[\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+$/;\n\nfunction tryDecode(str: string, decode: (str: string) => string) {\n try {\n return decode(str);\n } catch (e) {\n return str;\n }\n}\n\n/**\n * Parse a cookie header.\n *\n * Parse the given cookie header string into an object\n * The object has the various cookies as keys(names) => values\n *\n */\nexport function parse(\n str: string,\n options: {\n decode: (str: string) => string;\n } = {\n decode: decodeURIComponent,\n }\n): Record {\n const obj: Record = {};\n const pairs = str.split(pairSplitRegExp);\n\n for (const pair of pairs) {\n let eqIdx = pair.indexOf('=');\n\n // skip things that don't look like key=value\n if (eqIdx < 0) continue;\n\n const key = pair.substr(0, eqIdx).trim();\n let val = pair.substr(++eqIdx, pair.length).trim();\n\n // quoted values\n if ('\"' == val[0]) val = val.slice(1, -1);\n\n // only assign once\n if (obj[key] == null) obj[key] = tryDecode(val, options.decode);\n }\n\n return obj;\n}\n\nexport type SerializeOptions = Partial<{\n encode: (str: string) => string;\n maxAge: number;\n domain: string;\n path: string;\n httpOnly: boolean;\n secure: boolean;\n sameSite: boolean | 'Strict' | 'strict' | 'Lax' | 'lax' | 'None' | 'none' | string;\n expires: Date;\n}>;\n\nexport function serialize(name: string, val: string, opt: SerializeOptions = {}): string {\n if (!opt.encode) opt.encode = encodeURIComponent;\n\n if (!fieldContentRegExp.test(name)) throw new TypeError('argument name is invalid');\n\n const value = opt.encode(val);\n\n if (value && !fieldContentRegExp.test(value)) throw new TypeError('argument val is invalid');\n\n let str = name + '=' + value;\n\n if (null != opt.maxAge) {\n const maxAge = opt.maxAge - 0;\n\n if (isNaN(maxAge) || !isFinite(maxAge)) throw new TypeError('option maxAge is invalid');\n\n str += '; Max-Age=' + Math.floor(maxAge);\n }\n\n if (opt.domain) {\n if (!fieldContentRegExp.test(opt.domain)) throw new TypeError('option domain is invalid');\n\n str += '; Domain=' + opt.domain;\n }\n\n if (opt.path) {\n if (!fieldContentRegExp.test(opt.path)) throw new TypeError('option path is invalid');\n\n str += '; Path=' + opt.path;\n }\n\n if (opt.expires) str += '; Expires=' + opt.expires.toUTCString();\n\n if (opt.httpOnly) str += '; HttpOnly';\n\n if (opt.secure) str += '; Secure';\n\n if (opt.sameSite) {\n const sameSite = typeof opt.sameSite === 'string' ? opt.sameSite.toLowerCase() : opt.sameSite;\n\n switch (sameSite) {\n case true:\n case 'strict':\n str += '; SameSite=Strict';\n break;\n case 'lax':\n str += '; SameSite=Lax';\n break;\n case 'none':\n str += '; SameSite=None';\n break;\n default:\n throw new TypeError('option sameSite is invalid');\n }\n }\n\n return str;\n}\n","const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\nexport function btoa(input = '') {\n let str = input;\n let output = '';\n\n for (\n let block = 0, charCode, i = 0, map = chars;\n str.charAt(i | 0) || ((map = '='), i % 1);\n output += map.charAt(63 & (block >> (8 - (i % 1) * 8)))\n ) {\n charCode = str.charCodeAt((i += 3 / 4));\n\n if (charCode > 0xff) {\n throw new Error(\"'btoa' failed: The string to be encoded contains characters outside of the Latin1 range.\");\n }\n\n block = (block << 8) | charCode;\n }\n\n return output;\n}\n","export interface SchoolYear {\n name: string;\n id: number;\n startDate: Date;\n endDate: Date;\n}\n\nexport interface MessagesOfDay {\n id: number;\n subject: string;\n text: string;\n isExpanded: boolean;\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: any[];\n}\n\nexport interface NewsWidget {\n /**\n * Unknown type. I have never seen this in use.\n */\n systemMessage: any;\n messagesOfDay: MessagesOfDay[];\n rssUrl: string;\n}\n\nexport interface Messagesender {\n userId: number;\n displayName: string;\n imageUrl: string;\n className: string;\n}\n\nexport interface Inboxmessage {\n allowMessageDeletion: boolean;\n contentPreview: string;\n hasAttachments: boolean;\n id: number;\n isMessageRead: boolean;\n isReply: boolean;\n isReplyAllowed: boolean;\n sender: Messagesender;\n sentDateTime: string;\n subject: string;\n}\n\nexport interface Inbox {\n incomingMessages: Inboxmessage[];\n}\n\nexport interface ShortData {\n id: number;\n name: string;\n longname: string;\n orgname?: string;\n orgid?: number;\n}\n\nexport interface Lesson {\n id: number;\n date: number;\n startTime: number;\n endTime: number;\n kl: ShortData[];\n te: ShortData[];\n su: ShortData[];\n ro: ShortData[];\n lstext?: string;\n lsnumber: number;\n activityType?: 'Unterricht' | string;\n code?: 'cancelled' | 'irregular';\n info?: string;\n substText?: string;\n statflags?: string;\n sg?: string;\n bkRemark?: string;\n bkText?: string;\n}\n\nexport interface Homework {\n /**\n * Unknown type. I have never seen this in use.\n */\n attachments: Array;\n completed: boolean;\n date: number;\n dueDate: number;\n id: number;\n lessonId: number;\n remark: string;\n text: string;\n}\n\nexport interface Subject {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport enum WebUntisDay {\n Sunday = 1,\n Monday = 2,\n Tuesday = 3,\n Wednesday = 4,\n Thursday = 5,\n Friday = 6,\n Saturday = 7,\n}\n\nexport interface TimeUnit {\n name: string;\n startTime: number;\n endTime: number;\n}\n\nexport interface Timegrid {\n day: WebUntisDay;\n timeUnits: TimeUnit[];\n}\n\nexport interface Exam {\n id: number;\n examType: string;\n name: string;\n studentClass: string[];\n assignedStudents: {\n klasse: { id: number; name: string };\n displayName: string;\n id: number;\n }[];\n examDate: number;\n startTime: number;\n endTime: number;\n subject: string;\n teachers: string[];\n rooms: string[];\n text: string;\n grade?: string;\n}\n\nexport enum WebUntisElementType {\n CLASS = 1,\n TEACHER = 2,\n SUBJECT = 3,\n ROOM = 4,\n STUDENT = 5,\n}\n\nexport interface WebElement {\n type: WebUntisElementType;\n id: number;\n orgId: number;\n missing: boolean;\n state: 'REGULAR' | 'ABSENT' | 'SUBSTITUTED';\n}\n\nexport interface WebElementData extends WebElement {\n element: {\n type: number;\n id: number;\n name: string;\n longName?: string;\n displayname?: string;\n alternatename?: string;\n canViewTimetable: boolean;\n externalKey?: string;\n roomCapacity: number;\n };\n}\n\nexport interface WebAPITimetable {\n id: number;\n lessonId: number;\n lessonNumber: number;\n lessonCode: string;\n lessonText: string;\n periodText: string;\n hasPeriodText: false;\n periodInfo: string;\n periodAttachments: [];\n substText: string;\n date: number;\n startTime: number;\n endTime: number;\n elements: WebElement[];\n studentGroup: string;\n hasInfo: boolean;\n code: number;\n cellState: 'STANDARD' | 'SUBSTITUTION' | 'ROOMSUBSTITUTION';\n priority: number;\n is: {\n roomSubstitution?: boolean;\n substitution?: boolean;\n standard?: boolean;\n event: boolean;\n };\n roomCapacity: number;\n studentCount: number;\n classes: WebElementData[];\n teachers: WebElementData[];\n subjects: WebElementData[];\n rooms: WebElementData[];\n students: WebElementData[];\n}\n\nexport interface Teacher {\n id: number;\n name: string;\n foreName: string;\n longName: string;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Student {\n id: number;\n key: number;\n name: string;\n foreName: string;\n longName: string;\n gender: string;\n}\n\nexport interface Room {\n id: number;\n name: string;\n longName: string;\n alternateName: string | '';\n active: boolean;\n foreColor: string;\n backColor: string;\n}\n\nexport interface Klasse {\n id: number;\n name: string;\n longName: string;\n active: boolean;\n}\n\nexport interface Department {\n id: number;\n name: string;\n longName: string;\n}\n\nexport interface Holiday {\n name: string;\n longName: string;\n id: number;\n startDate: number;\n endDate: number;\n}\n\nexport interface ColorEntity {\n foreColor: string;\n backColor: string;\n}\n\nexport interface LsEntity {\n ls?: ColorEntity | null;\n oh?: ColorEntity | null;\n sb?: ColorEntity | null;\n bs?: ColorEntity | null;\n ex?: ColorEntity | null;\n}\n\nexport interface CodesEntity {\n cancelled?: ColorEntity | null;\n irregular?: ColorEntity | null;\n}\n\nexport interface StatusData {\n lstypes: LsEntity[];\n codes: CodesEntity[];\n}\n\nexport interface Absences {\n absences: Absence[];\n absenceReasons: [];\n excuseStatuses: boolean;\n showAbsenceReasonChange: boolean;\n showCreateAbsence: boolean;\n}\n\nexport interface Absence {\n id: number;\n startDate: number;\n endDate: number;\n startTime: number;\n endTime: number;\n createDate: number;\n lastUpdate: number;\n createdUser: string;\n updatedUser: string;\n reasonId: number;\n reason: string;\n text: string;\n interruptions: [];\n canEdit: boolean;\n studentName: string;\n excuseStatus: string;\n isExcused: boolean;\n excuse: Excuse;\n}\n\nexport interface Excuse {\n id: number;\n text: string;\n excuseDate: number;\n excuseStatus: string;\n isExcused: boolean;\n userId: number;\n username: string;\n}\n","import { serialize } from './cookie';\nimport axios from 'axios';\nimport { btoa } from './base-64';\nimport { parse, startOfDay, format } from 'date-fns';\nimport type { AxiosInstance } from 'axios';\nimport type {\n Absences,\n Department,\n Exam,\n Holiday,\n Homework,\n Inbox,\n Klasse,\n Lesson,\n NewsWidget,\n Room,\n SchoolYear,\n StatusData,\n Student,\n Subject,\n Teacher,\n Timegrid,\n WebAPITimetable,\n} from './types';\nimport type { InternalSchoolYear, SessionInformation } from './internal';\nimport { WebUntisElementType } from './types';\n\nexport class Base {\n school: string;\n schoolbase64: string;\n username: string;\n password: string;\n baseurl: string;\n cookies: string[];\n id: string;\n sessionInformation: SessionInformation | null;\n anonymous: boolean;\n\n axios: AxiosInstance;\n\n static TYPES = WebUntisElementType;\n\n /**\n *\n * @constructor\n * @param {string} school The school identifier\n * @param {string} username\n * @param {string} password\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false,\n ) {\n this.school = school;\n this.schoolbase64 = '_' + btoa(this.school);\n this.username = username;\n this.password = password;\n this.baseurl = 'https://' + baseurl + '/';\n this.cookies = [];\n this.id = identity;\n this.sessionInformation = {};\n this.anonymous = false;\n\n const additionalHeaders: Record = {};\n\n if (!disableUserAgent) {\n additionalHeaders['User-Agent'] =\n 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.79 Safari/537.36';\n }\n\n this.axios = axios.create({\n baseURL: this.baseurl,\n maxRedirects: 0,\n headers: {\n 'Cache-Control': 'no-cache',\n Pragma: 'no-cache',\n 'X-Requested-With': 'XMLHttpRequest',\n ...additionalHeaders,\n },\n validateStatus: function (status) {\n return status >= 200 && status < 303; // default\n },\n });\n }\n\n /**\n * Logout the current session\n */\n async logout(): Promise {\n await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'logout',\n params: {},\n jsonrpc: '2.0',\n },\n });\n this.sessionInformation = null;\n return true;\n }\n\n /**\n * Login with your credentials\n *\n * **Notice: The server may revoke this session after less than 10min of idle.**\n *\n * *Untis says in the official docs:*\n * > An application should always log out as soon as possible to free system resources on the server.\n */\n async login(): Promise {\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n data: {\n id: this.id,\n method: 'authenticate',\n params: {\n user: this.username,\n password: this.password,\n client: this.id,\n },\n jsonrpc: '2.0',\n },\n });\n if (typeof response.data !== 'object') throw new Error('Failed to parse server response.');\n if (!response.data.result) throw new Error('Failed to login. ' + JSON.stringify(response.data));\n if (response.data.result.code) throw new Error('Login returned error code: ' + response.data.result.code);\n if (!response.data.result.sessionId) throw new Error('Failed to login. No session id.');\n this.sessionInformation = response.data.result;\n return response.data.result;\n }\n\n /**\n * Get the latest WebUntis Schoolyear\n * @param {Boolean} [validateSession=true]\n */\n async getLatestSchoolyear(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return {\n name: data[0].name,\n id: data[0].id,\n startDate: parse(data[0].startDate, 'yyyyMMdd', new Date()),\n endDate: parse(data[0].endDate, 'yyyyMMdd', new Date()),\n };\n }\n\n /**\n * Get all WebUntis Schoolyears\n * @param {Boolean} [validateSession=true]\n */\n async getSchoolyears(validateSession = true): Promise {\n const data = await this._request('getSchoolyears', {}, validateSession);\n data.sort((a, b) => {\n const na = parse(a.startDate, 'yyyyMMdd', new Date());\n const nb = parse(b.startDate, 'yyyyMMdd', new Date());\n return nb.getTime() - na.getTime();\n });\n if (!data[0]) throw new Error('Failed to receive school year');\n return data.map((year) => {\n return {\n name: year.name,\n id: year.id,\n startDate: parse(year.startDate, 'yyyyMMdd', new Date()),\n endDate: parse(year.endDate, 'yyyyMMdd', new Date()),\n };\n });\n }\n\n /**\n * Get News Widget\n * @param {Date} date\n * @param {boolean} [validateSession=true]\n * @returns {Promise} see index.d.ts NewsWidget\n */\n async getNewsWidget(date: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/news/newsWidgetData`,\n params: {\n date: Base.convertDateToUntis(date),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data.data;\n }\n\n /**\n * Get Inbox\n */\n async getInbox(validateSession = true): Promise {\n this._checkAnonymous();\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n //first get JWT Token\n if (typeof this.sessionInformation!.jwt_token != 'string') await this._getJWT();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/rest/view/v1/messages`,\n headers: {\n Authorization: `Bearer ${this.sessionInformation!.jwt_token}`,\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data !== 'object') throw new Error('Server returned invalid data.');\n return response.data;\n }\n\n private _checkAnonymous() {\n if (this.anonymous) {\n throw new Error('This method is not supported with anonymous login');\n }\n }\n\n /**\n *\n * @returns {string}\n * @private\n */\n _buildCookies() {\n let cookies = [];\n cookies.push(serialize('JSESSIONID', this.sessionInformation!.sessionId!));\n cookies.push(serialize('schoolname', this.schoolbase64));\n return cookies.join('; ');\n }\n\n /**\n * Get JWT Token\n * @private\n */\n async _getJWT(validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/token/new`,\n headers: {\n //Authorization: `Bearer ${this._getToken()}`,\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data !== 'string') throw new Error('Server returned invalid data.');\n this.sessionInformation!.jwt_token = response.data;\n return response.data;\n }\n\n /**\n * Checks if your current WebUntis Session is valid\n */\n async validateSession(): Promise {\n if (!this.sessionInformation) return false;\n const response = await this.axios({\n method: 'POST',\n url: `/WebUntis/jsonrpc.do`,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: 'getLatestImportTime',\n params: {},\n jsonrpc: '2.0',\n },\n });\n return typeof response.data.result === 'number';\n }\n\n /**\n * Get the time when WebUntis last changed its data\n * @param {Boolean} [validateSession=true]\n */\n async getLatestImportTime(validateSession = true): Promise {\n return this._request('getLatestImportTime', {}, validateSession);\n }\n\n /**\n *\n * @param id\n * @param type\n * @param startDate\n * @param endDate\n * @param validateSession\n * @private\n */\n private async _timetableRequest(\n id: string | number,\n type: number,\n startDate?: Date | null,\n endDate?: Date | null,\n validateSession = true,\n ): Promise {\n const additionalOptions: Record = {};\n if (startDate) {\n additionalOptions.startDate = Base.convertDateToUntis(startDate);\n }\n if (endDate) {\n additionalOptions.endDate = Base.convertDateToUntis(endDate);\n }\n\n return this._request(\n 'getTimetable',\n {\n options: {\n id: new Date().getTime(),\n element: {\n id,\n type,\n },\n ...additionalOptions,\n showLsText: true,\n showStudentgroup: true,\n showLsNumber: true,\n showSubstText: true,\n showInfo: true,\n showBooking: true,\n klasseFields: ['id', 'name', 'longname', 'externalkey'],\n roomFields: ['id', 'name', 'longname', 'externalkey'],\n subjectFields: ['id', 'name', 'longname', 'externalkey'],\n teacherFields: ['id', 'name', 'longname', 'externalkey'],\n },\n },\n validateSession,\n );\n }\n\n /**\n * Get your own Timetable for the current day\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n null,\n null,\n validateSession,\n );\n }\n\n /**\n * Get the timetable of today for a specific element.\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getTimetableForToday(id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, null, null, validateSession);\n }\n\n /**\n * Get your own Timetable for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n */\n async getOwnTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n date,\n date,\n validateSession,\n );\n }\n\n /**\n * Get the timetable for a specific day for a specific element.\n * @param {Date} date\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableFor(date: Date, id: number, type: number, validateSession = true): Promise {\n return await this._timetableRequest(id, type, date, date, validateSession);\n }\n\n /**\n * Get your own timetable for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n rangeStart,\n rangeEnd,\n validateSession,\n );\n }\n\n /**\n * Get the timetable for a given Date range for specific element\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {number} id\n * @param {WebUntisElementType} type\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForRange(\n rangeStart: Date,\n rangeEnd: Date,\n id: number,\n type: number,\n validateSession = true,\n ): Promise {\n return await this._timetableRequest(id, type, rangeStart, rangeEnd, validateSession);\n }\n\n /**\n * Get the Timetable of your class for today\n * Note: You can't use this with anonymous login\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnClassTimetableForToday(validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, null, null, validateSession);\n }\n\n /**\n * Get the Timetable of your class for the given day\n * Note: You can't use this with anonymous login\n * @param {Date} date\n * @param {Boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getOwnClassTimetableFor(date: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(this.sessionInformation!.klasseId!, 1, date, date, validateSession);\n }\n\n /**\n * Get the Timetable of your class for a given Date range\n * Note: You can't use this with anonymous login\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n */\n async getOwnClassTimetableForRange(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n this._checkAnonymous();\n return await this._timetableRequest(\n this.sessionInformation!.klasseId!,\n 1,\n rangeStart,\n rangeEnd,\n validateSession,\n );\n }\n\n /**\n *\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorksFor(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Converts the untis date string format to a normal JS Date object\n * @param {string} date Untis date string\n * @param {Date} [baseDate=new Date()] Base date. Default beginning of current day\n * @static\n */\n static convertUntisDate(date: string, baseDate = startOfDay(new Date())): Date {\n if (typeof date !== 'string') date = `${date}`;\n return parse(date, 'yyyyMMdd', baseDate);\n }\n\n /**\n * Convert a untis time string to a JS Date object\n * @param {string|number} time Untis time string\n * @param {Date} [baseDate=new Date()] Day used as base for the time. Default: Current date\n * @static\n */\n static convertUntisTime(time: number | string, baseDate = new Date()): Date {\n if (typeof time !== 'string') time = `${time}`;\n return parse(time.padStart(4, '0'), 'Hmm', baseDate);\n }\n\n /**\n * Get all known Subjects for the current logged-in user\n * @param {boolean} [validateSession=true]\n */\n async getSubjects(validateSession = true): Promise {\n return await this._request('getSubjects', {}, validateSession);\n }\n\n /**\n * Get the timegrid of current school\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTimegrid(validateSession = true): Promise {\n return await this._request('getTimegridUnits', {}, validateSession);\n }\n\n /**\n *\n * TODO: Find out what type this function returns\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHomeWorkAndLessons(rangeStart: Date, rangeEnd: Date, validateSession = true): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/homeworks/lessons`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['homeworks']) throw new Error(\"Data object doesn't contains homeworks object.\");\n return response.data.data;\n }\n\n /**\n * Get Exams for range\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Number} klasseId\n * @param {boolean} withGrades\n * @param {boolean} [validateSession=true]\n */\n async getExamsForRange(\n rangeStart: Date,\n rangeEnd: Date,\n klasseId = -1,\n withGrades = false,\n validateSession = true,\n ): Promise> {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/exams`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n klasseId: klasseId,\n withGrades: withGrades,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n if (!response.data.data['exams']) throw new Error(\"Data object doesn't contains exams object.\");\n return response.data.data['exams'];\n }\n\n /**\n * Get the timetable for the current week for a specific element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {number} id element id\n * @param {WebUntisElementType} type element type\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n */\n async getTimetableForWeek(\n date: Date,\n id: number,\n type: number,\n formatId = 1,\n validateSession = true,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/public/timetable/weekly/data`,\n params: {\n elementType: type,\n elementId: id,\n date: format(date, 'yyyy-MM-dd'),\n formatId: formatId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n\n if (typeof response.data.data !== 'object') throw new Error('Server returned invalid data.');\n\n if (response.data.data.error) {\n /* known codes:\n * - ERR_TTVIEW_NOTALLOWED_ONDATE\n */\n const err = new Error('Server responded with error');\n // TODO: Make this better lol\n // @ts-ignore\n err.code = response.data.data.error?.data?.messageKey;\n throw err;\n }\n\n if (!response.data.data.result?.data?.elementPeriods?.[id]) throw new Error('Invalid response');\n\n const data = response.data.data.result.data;\n\n // TODO: improve typings\n\n const formatElements = (elements: Array>, { byType }: { byType: number }) => {\n const filteredElements = elements.filter((element) => element.type === byType);\n\n return filteredElements.map((element) => ({\n ...element,\n element: data.elements.find(\n (dataElement: Record) =>\n dataElement.type === byType && dataElement.id === element.id,\n ),\n }));\n };\n\n const timetable = data.elementPeriods[id].map((lesson: any) => ({\n ...lesson,\n classes: formatElements(lesson.elements, { byType: Base.TYPES.CLASS }),\n teachers: formatElements(lesson.elements, { byType: Base.TYPES.TEACHER }),\n subjects: formatElements(lesson.elements, { byType: Base.TYPES.SUBJECT }),\n rooms: formatElements(lesson.elements, { byType: Base.TYPES.ROOM }),\n students: formatElements(lesson.elements, { byType: Base.TYPES.STUDENT }),\n }));\n\n return timetable;\n }\n\n /**\n * Get the timetable for the current week for the current element from the web client API.\n * @param {Date} date one date in the week to query\n * @param {Number} [formatId=1] set to 1 to include teachers, 2 omits the teachers in elements response\n * @param {Boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getOwnTimetableForWeek(date: Date, formatId = 1, validateSession = true): Promise {\n this._checkAnonymous();\n return await this.getTimetableForWeek(\n date,\n this.sessionInformation!.personId!,\n this.sessionInformation!.personType!,\n formatId,\n validateSession,\n );\n }\n\n /**\n * Get all known teachers by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getTeachers(validateSession = true): Promise {\n return await this._request('getTeachers', {}, validateSession);\n }\n\n /**\n * Get all known students by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStudents(validateSession = true): Promise {\n return await this._request('getStudents', {}, validateSession);\n }\n\n /**\n * Get all known rooms by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getRooms(validateSession = true): Promise {\n return await this._request('getRooms', {}, validateSession);\n }\n\n /**\n * Get all classes known by WebUntis\n * @param {boolean} [validateSession=true]\n * @param {number} schoolyearId\n * @returns {Promise.}\n */\n async getClasses(validateSession = true, schoolyearId: number): Promise {\n const data = typeof schoolyearId !== 'number' ? {} : { schoolyearId };\n return await this._request('getKlassen', data, validateSession);\n }\n\n /**\n * Get all departments known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getDepartments(validateSession = true): Promise {\n return await this._request('getDepartments', {}, validateSession);\n }\n\n /**\n * Get all holidays known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getHolidays(validateSession = true): Promise {\n return await this._request('getHolidays', {}, validateSession);\n }\n\n /**\n * Get all status data known by WebUntis\n * @param {boolean} [validateSession=true]\n * @returns {Promise.}\n */\n async getStatusData(validateSession = true): Promise {\n return await this._request('getStatusData', {}, validateSession);\n }\n\n /**\n * Convert a JS Date Object to a WebUntis date string\n * @param {Date} date\n * @returns {String}\n */\n static convertDateToUntis(date: Date): string {\n return (\n date.getFullYear().toString() +\n (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1).toString() +\n (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()).toString()\n );\n }\n\n /**\n * Make a JSON RPC Request with the current session\n * @param {string} method\n * @param {Object} [parameter={}]\n * @param {string} [url='/WebUntis/jsonrpc.do?school=SCHOOL']\n * @param {boolean} [validateSession=true] Whether the session should be checked first\n * @returns {Promise.}\n * @private\n */\n async _request>(\n method: string,\n parameter: Record = {},\n validateSession = true,\n url = `/WebUntis/jsonrpc.do`,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n const response = await this.axios({\n method: 'POST',\n url: url,\n params: {\n school: this.school,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n data: {\n id: this.id,\n method: method,\n params: parameter,\n jsonrpc: '2.0',\n },\n });\n if (!response.data.result) throw new Error(\"Server didn't return any result.\");\n if (response.data.result.code) throw new Error('Server returned error code: ' + response.data.result.code);\n return response.data.result;\n }\n\n /**\n * Returns all the Lessons where you were absent including the excused one!\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [validateSession=true]\n * @returns {Promise}\n */\n async getAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n excuseStatusId = -1,\n validateSession = true,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/api/classreg/absences/students`,\n params: {\n startDate: Base.convertDateToUntis(rangeStart),\n endDate: Base.convertDateToUntis(rangeEnd),\n studentId: this.sessionInformation!.personId!,\n excuseStatusId: excuseStatusId,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (response.data.data == null) throw new Error('Server returned no data!');\n return response.data.data;\n }\n\n /**\n * Returns a URL to a unique PDF of all the lessons you were absent\n * @param {Date} rangeStart\n * @param {Date} rangeEnd\n * @param {boolean} [validateSession=true]\n * @param {Integer} [excuseStatusId=-1]\n * @param {boolean} [lateness=true]\n * @param {boolean} [absences=true]\n * @param {boolean} [excuseGroup=2]\n */\n async getPdfOfAbsentLesson(\n rangeStart: Date,\n rangeEnd: Date,\n validateSession = true,\n excuseStatusId = -1,\n lateness = true,\n absences = true,\n excuseGroup = 2,\n ): Promise {\n if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid');\n this._checkAnonymous();\n const response = await this.axios({\n method: 'GET',\n url: `/WebUntis/reports.do`,\n params: {\n name: 'Excuse',\n format: 'pdf',\n rpt_sd: Base.convertDateToUntis(rangeStart),\n rpt_ed: Base.convertDateToUntis(rangeEnd),\n excuseStatusId: excuseStatusId,\n studentId: this.sessionInformation!.personId!,\n withLateness: lateness,\n withAbsences: absences,\n execuseGroup: excuseGroup,\n },\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n const res = response.data.data;\n if (response.status != 200 || res.error) throw new Error('Server returned no data!');\n const pdfDownloadURL =\n this.baseurl + 'WebUntis/reports.do?' + 'msgId=' + res.messageId + '&' + res.reportParams;\n return pdfDownloadURL;\n }\n}\n\n/**\n * @private\n */\nexport class InternalWebuntisSecretLogin extends Base {\n constructor(\n school: string,\n username: string,\n password: string,\n baseurl: string,\n identity = 'Awesome',\n disableUserAgent = false,\n ) {\n super(school, username, password, baseurl, identity, disableUserAgent);\n }\n\n async _otpLogin(token: number | string, username: string, time: number, skipSessionInfo = false) {\n const response = await this.axios({\n method: 'POST',\n url: '/WebUntis/jsonrpc_intern.do',\n params: {\n m: 'getUserData2017',\n school: this.school,\n v: 'i2.2',\n },\n data: {\n id: this.id,\n method: 'getUserData2017',\n params: [\n {\n auth: {\n clientTime: time,\n user: username,\n otp: token,\n },\n },\n ],\n jsonrpc: '2.0',\n },\n });\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n if (!response.headers['set-cookie']) throw new Error(`Failed to login. Server didn't return a set-cookie`);\n if (!this._getCookieFromSetCookie(response.headers['set-cookie']))\n throw new Error(\"Failed to login. Server didn't return a session id.\");\n const sessionId = this._getCookieFromSetCookie(response.headers['set-cookie']);\n // Set session temporary\n this.sessionInformation = {\n sessionId: sessionId,\n };\n if (skipSessionInfo) return this.sessionInformation;\n\n // Get personId & personType\n const appConfigUrl = `/WebUntis/api/app/config`;\n const configResponse = await this.axios({\n method: 'GET',\n url: appConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof configResponse.data !== 'object' || typeof configResponse.data.data !== 'object')\n throw new Error('Failed to fetch app config while login. data (type): ' + typeof response.data);\n // Path -> data.loginServiceConfig.user.persons -> find person with id\n if (\n configResponse.data.data &&\n configResponse.data.data.loginServiceConfig &&\n configResponse.data.data.loginServiceConfig.user &&\n !Number.isInteger(configResponse.data.data.loginServiceConfig.user.personId)\n )\n throw new Error('Invalid personId. personId: ' + configResponse.data.data.loginServiceConfig.user.personId);\n const webUntisLoginServiceUser = configResponse.data.data.loginServiceConfig.user;\n if (!Array.isArray(webUntisLoginServiceUser.persons))\n throw new Error('Invalid person array. persons (type): ' + typeof webUntisLoginServiceUser.persons);\n const person = webUntisLoginServiceUser.persons.find(\n (value: Record) => value.id === configResponse.data.data.loginServiceConfig.user.personId,\n );\n if (!person) throw new Error('Can not find person in person array.');\n if (!Number.isInteger(person.type)) throw new Error('Invalid person type. type (type): ' + person.type);\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n };\n // Get klasseId\n try {\n const dayConfigUrl = `/WebUntis/api/daytimetable/config`;\n const dayConfigResponse = await this.axios({\n method: 'GET',\n url: dayConfigUrl,\n headers: {\n Cookie: this._buildCookies(),\n },\n });\n if (typeof dayConfigResponse.data !== 'object' || typeof dayConfigResponse.data.data !== 'object')\n throw new Error();\n if (!Number.isInteger(dayConfigResponse.data.data.klasseId)) throw new Error();\n this.sessionInformation = {\n sessionId: sessionId,\n personType: person.type,\n personId: configResponse.data.data.loginServiceConfig.user.personId,\n klasseId: dayConfigResponse.data.data.klasseId,\n };\n } catch (e) {\n // klasseId is not important. This request can fail\n }\n return this.sessionInformation;\n }\n\n /**\n *\n * @param {Array} setCookieArray\n * @param {string} [cookieName=\"JSESSIONID\"]\n * @return {string|boolean}\n * @private\n */\n _getCookieFromSetCookie(setCookieArray?: string[], cookieName = 'JSESSIONID') {\n if (!setCookieArray) return;\n for (let i = 0; i < setCookieArray.length; i++) {\n const setCookie = setCookieArray[i];\n if (!setCookie) continue;\n let cookieParts = setCookie.split(';');\n if (!cookieParts || !Array.isArray(cookieParts)) continue;\n for (let cookie of cookieParts) {\n cookie = cookie.trim();\n cookie = cookie.replace(/;/gm, '');\n const [Key, Value] = cookie.split('=');\n if (!Key || !Value) continue;\n if (Key === cookieName) return Value;\n }\n }\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\nimport type { authenticator } from 'otplib';\n\nexport type Authenticator = typeof authenticator;\n\nexport class WebUntisSecretAuth extends InternalWebuntisSecretLogin {\n private readonly secret: string;\n private authenticator: Authenticator;\n\n /**\n *\n * @constructor\n * @augments WebUntis\n * @param {string} school The school identifier\n * @param {string} user\n * @param {string} secret\n * @param {string} baseurl Just the host name of your WebUntis (Example: mese.webuntis.com)\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n school: string,\n user: string,\n secret: string,\n baseurl: string,\n identity = 'Awesome',\n authenticator: Authenticator,\n disableUserAgent = false\n ) {\n super(school, user, null as unknown as string, baseurl, identity, disableUserAgent);\n this.secret = secret;\n this.authenticator = authenticator;\n if (!authenticator) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the otplib object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n const { authenticator } = eval(\"require('otplib')\");\n this.authenticator = authenticator;\n }\n }\n\n // @ts-ignore\n async login() {\n // Get JSESSION\n const token = this.authenticator.generate(this.secret);\n const time = new Date().getTime();\n return await this._otpLogin(token, this.username, time);\n }\n}\n","import { WebUntisSecretAuth } from './secret';\nimport type { Authenticator } from './secret';\nimport type { URL } from 'url';\n\n/**\n * @private\n */\nexport type URLClass = typeof URL;\n\nexport class WebUntisQR extends WebUntisSecretAuth {\n /**\n * Use the data you get from a WebUntis QR code\n * @constructor\n * @param {string} QRCodeURI A WebUntis uri. This is the data you get from the QR Code from the webuntis webapp under profile->Data access->Display\n * @param {string} [identity=\"Awesome\"] A identity like: MyAwesomeApp\n * @param {Object} authenticator Custom otplib v12 instance. Default will use the default otplib configuration.\n * @param {Object} URL Custom whatwg url implementation. Default will use the nodejs implementation.\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(\n QRCodeURI: string,\n identity: string,\n authenticator: Authenticator,\n URL?: URLClass,\n disableUserAgent = false\n ) {\n let URLImplementation = URL;\n if (!URL) {\n if ('import' in globalThis) {\n throw new Error(\n 'You need to provide the URL object by yourself. We can not eval the require in ESM mode.'\n );\n }\n // React-Native will not eval this expression\n URLImplementation = eval(\"require('url').URL\") as URLClass;\n }\n const uri = new URLImplementation!(QRCodeURI);\n super(\n uri.searchParams.get('school')!,\n uri.searchParams.get('user')!,\n uri.searchParams.get('key')!,\n uri.searchParams.get('url')!,\n identity,\n authenticator,\n disableUserAgent\n );\n }\n}\n","import { InternalWebuntisSecretLogin } from './base';\n\nexport class WebUntisAnonymousAuth extends InternalWebuntisSecretLogin {\n /**\n *\n * @param {string} school\n * @param {string} baseurl\n * @param {string} [identity='Awesome']\n * @param {boolean} [disableUserAgent=false] If this is true, axios will not send a custom User-Agent\n */\n constructor(school: string, baseurl: string, identity = 'Awesome', disableUserAgent = false) {\n // TODO: Make this a bit more beautiful and more type safe\n super(school, null as unknown as string, null as unknown as string, baseurl, identity, disableUserAgent);\n this.username = '#anonymous#';\n this.anonymous = true;\n }\n\n override async login() {\n // Check whether the school has public access or not\n const url = `/WebUntis/jsonrpc_intern.do`;\n\n const response = await this.axios({\n method: 'POST',\n url,\n params: {\n m: 'getAppSharedSecret',\n school: this.school,\n v: 'i3.5',\n },\n data: {\n id: this.id,\n method: 'getAppSharedSecret',\n params: [\n {\n userName: '#anonymous#',\n password: '',\n },\n ],\n jsonrpc: '2.0',\n },\n });\n\n if (response.data && response.data.error)\n throw new Error('Failed to login. ' + (response.data.error.message || ''));\n\n // OTP never changes when using anonymous login\n const otp = 100170;\n const time = new Date().getTime();\n return await this._otpLogin(otp, this.username, time, true);\n }\n}\n"],"names":["WebUntisDay","WebUntisElementType","__publicField"],"mappings":";;;AAkBA,MAAM,kBAAqB,GAAA,uCAAA,CAAA;AA0DpB,SAAS,SAAU,CAAA,IAAA,EAAc,GAAa,EAAA,GAAA,GAAwB,EAAY,EAAA;AACrF,EAAA,IAAI,CAAC,GAAI,CAAA,MAAA;AAAQ,IAAA,GAAA,CAAI,MAAS,GAAA,kBAAA,CAAA;AAE9B,EAAI,IAAA,CAAC,kBAAmB,CAAA,IAAA,CA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;AAAA,QACF,IAAI,IAAK,CAAA,EAAA;AAAA,QACT,MAAQ,EAAA,oBAAA;AAAA,QACR,MAAQ,EAAA;AAAA,UACJ;AAAA,YACI,QAAU,EAAA,aAAA;AAAA,YACV,QAAU,EAAA,EAAA;AAAA,WACd;AAAA,SACJ;AAAA,QACA,OAAS,EAAA,KAAA;AAAA,OACb;AAAA,KACH,CAAA,CAAA;AAED,IAAI,IAAA,QAAA,CAAS,IAAQ,IAAA,QAAA,CAAS,IAAK,CAAA,KAAA;AAC/B,MAAA,MAAM,IAAI,KAAM,CAAA,mBAAA,IAAuB,SAAS,IAAK,CAAA,KAAA,CAAM,WAAW,EAAG,CAAA,CAAA,CAAA;AAG7E,IAAA,MAAM,GAAM,GAAA,MAAA,CAAA;AACZ,IAAA,MAAM,IAAO,GAAA,iBAAA,IAAI,IAAK,EAAA,EAAE,OAAQ,EAAA,CAAA;AAChC,IAAA,OAAO,MAAM,IAAK,CAAA,SAAA,CAAU,KAAK,IAAK,CAAA,QAAA,EAAU,MAAM,IAAI,CAAA,CAAA;AAAA,GAC9D;AACJ;;;;"} \ No newline at end of file diff --git a/package.json b/package.json index e12ecbe..4b81454 100644 --- a/package.json +++ b/package.json @@ -17,25 +17,25 @@ "docs" ], "dependencies": { - "axios": "^0.27.2", - "date-fns": "^2.28.0" + "axios": "^1.6.7", + "date-fns": "^3.3.1" }, "optionalDependencies": { "otplib": "^12" }, "devDependencies": { - "axios-mock-adapter": "^1.20.0", - "dotenv": "^16.0.1", - "esbuild": "^0.15.12", - "jest": "^28.1.0", + "axios-mock-adapter": "^1.22.0", + "dotenv": "^16.4.1", + "esbuild": "^0.20.0", + "jest": "^29.7.0", "jest-in-case": "^1.0.2", "otplib": "^12", - "prettier": "^2.6.2", - "rollup": "^3.2.2", - "rollup-plugin-dts": "^5.0.0", - "rollup-plugin-esbuild": "^4.10.1", - "typedoc": "^0.23.17", - "typescript": "^4.8.4" + "prettier": "^3.2.5", + "rollup": "^4.9.6", + "rollup-plugin-dts": "^6.1.0", + "rollup-plugin-esbuild": "^6.1.1", + "typedoc": "^0.25.7", + "typescript": "^5.3.3" }, "scripts": { "prepublish": "rollup -c && typedoc", diff --git a/src/base.ts b/src/base.ts index d2ba2d1..0bf2299 100644 --- a/src/base.ts +++ b/src/base.ts @@ -56,7 +56,7 @@ export class Base { password: string, baseurl: string, identity = 'Awesome', - disableUserAgent = false + disableUserAgent = false, ) { this.school = school; this.schoolbase64 = '_' + btoa(this.school); @@ -313,7 +313,7 @@ export class Base { type: number, startDate?: Date | null, endDate?: Date | null, - validateSession = true + validateSession = true, ): Promise { const additionalOptions: Record = {}; if (startDate) { @@ -345,7 +345,7 @@ export class Base { teacherFields: ['id', 'name', 'longname', 'externalkey'], }, }, - validateSession + validateSession, ); } @@ -362,7 +362,7 @@ export class Base { this.sessionInformation!.personType!, null, null, - validateSession + validateSession, ); } @@ -390,7 +390,7 @@ export class Base { this.sessionInformation!.personType!, date, date, - validateSession + validateSession, ); } @@ -420,7 +420,7 @@ export class Base { this.sessionInformation!.personType!, rangeStart, rangeEnd, - validateSession + validateSession, ); } @@ -437,7 +437,7 @@ export class Base { rangeEnd: Date, id: number, type: number, - validateSession = true + validateSession = true, ): Promise { return await this._timetableRequest(id, type, rangeStart, rangeEnd, validateSession); } @@ -479,7 +479,7 @@ export class Base { 1, rangeStart, rangeEnd, - validateSession + validateSession, ); } @@ -586,7 +586,7 @@ export class Base { rangeEnd: Date, klasseId = -1, withGrades = false, - validateSession = true + validateSession = true, ): Promise> { if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid'); const response = await this.axios({ @@ -620,7 +620,7 @@ export class Base { id: number, type: number, formatId = 1, - validateSession = true + validateSession = true, ): Promise { if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid'); @@ -664,7 +664,7 @@ export class Base { ...element, element: data.elements.find( (dataElement: Record) => - dataElement.type === byType && dataElement.id === element.id + dataElement.type === byType && dataElement.id === element.id, ), })); }; @@ -695,7 +695,7 @@ export class Base { this.sessionInformation!.personId!, this.sessionInformation!.personType!, formatId, - validateSession + validateSession, ); } @@ -790,7 +790,7 @@ export class Base { method: string, parameter: Record = {}, validateSession = true, - url = `/WebUntis/jsonrpc.do` + url = `/WebUntis/jsonrpc.do`, ): Promise { if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid'); const response = await this.axios({ @@ -826,7 +826,7 @@ export class Base { rangeStart: Date, rangeEnd: Date, excuseStatusId = -1, - validateSession = true + validateSession = true, ): Promise { if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid'); this._checkAnonymous(); @@ -864,7 +864,7 @@ export class Base { excuseStatusId = -1, lateness = true, absences = true, - excuseGroup = 2 + excuseGroup = 2, ): Promise { if (validateSession && !(await this.validateSession())) throw new Error('Current Session is not valid'); this._checkAnonymous(); @@ -904,7 +904,7 @@ export class InternalWebuntisSecretLogin extends Base { password: string, baseurl: string, identity = 'Awesome', - disableUserAgent = false + disableUserAgent = false, ) { super(school, username, password, baseurl, identity, disableUserAgent); } @@ -968,7 +968,7 @@ export class InternalWebuntisSecretLogin extends Base { if (!Array.isArray(webUntisLoginServiceUser.persons)) throw new Error('Invalid person array. persons (type): ' + typeof webUntisLoginServiceUser.persons); const person = webUntisLoginServiceUser.persons.find( - (value: Record) => value.id === configResponse.data.data.loginServiceConfig.user.personId + (value: Record) => value.id === configResponse.data.data.loginServiceConfig.user.personId, ); if (!person) throw new Error('Can not find person in person array.'); if (!Number.isInteger(person.type)) throw new Error('Invalid person type. type (type): ' + person.type); diff --git a/yarn.lock b/yarn.lock index 7527a18..7a2ed40 100644 --- a/yarn.lock +++ b/yarn.lock @@ -17,6 +17,14 @@ dependencies: "@babel/highlight" "^7.18.6" +"@babel/code-frame@^7.22.13": + version "7.23.5" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.23.5.tgz#9009b69a8c602293476ad598ff53e4562e15c244" + integrity sha512-CgH3s1a96LipHCmSUmYFPwY7MNx8C3avkq7i4Wl3cfa662ldtUe4VM1TPXX70pfmrlWTb6jLqTYrZyT2ZTJBgA== + dependencies: + "@babel/highlight" "^7.23.4" + chalk "^2.4.2" + "@babel/compat-data@^7.20.5": version "7.20.10" resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.20.10.tgz#9d92fa81b87542fff50e848ed585b4212c1d34ec" @@ -109,6 +117,11 @@ resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.20.2.tgz#d1b9000752b18d0877cff85a5c376ce5c3121629" integrity sha512-8RvlJG2mj4huQ4pZ+rU9lqKi9ZKiRmuvGuM2HlWmkmgOhbs6zEAw6IEiJ5cQqGbDzGZOhwuOQNtZMi/ENLjZoQ== +"@babel/helper-plugin-utils@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.22.5.tgz#dd7ee3735e8a313b9f7b05a773d892e88e6d7295" + integrity sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg== + "@babel/helper-simple-access@^7.20.2": version "7.20.2" resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.20.2.tgz#0ab452687fe0c2cfb1e2b9e0015de07fc2d62dd9" @@ -133,6 +146,11 @@ resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz#7eea834cf32901ffdc1a7ee555e2f9c27e249ca2" integrity sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w== +"@babel/helper-validator-identifier@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz#c4ae002c61d2879e724581d96665583dbc1dc0e0" + integrity sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A== + "@babel/helper-validator-option@^7.18.6": version "7.18.6" resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.18.6.tgz#bf0d2b5a509b1f336099e4ff36e1a63aa5db4db8" @@ -156,6 +174,15 @@ chalk "^2.0.0" js-tokens "^4.0.0" +"@babel/highlight@^7.23.4": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.23.4.tgz#edaadf4d8232e1a961432db785091207ead0621b" + integrity sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A== + dependencies: + "@babel/helper-validator-identifier" "^7.22.20" + chalk "^2.4.2" + js-tokens "^4.0.0" + "@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7": version "7.20.7" resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.20.7.tgz#66fe23b3c8569220817d5feb8b9dcdc95bb4f71b" @@ -196,6 +223,13 @@ dependencies: "@babel/helper-plugin-utils" "^7.8.0" +"@babel/plugin-syntax-jsx@^7.7.2": + version "7.23.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.23.3.tgz#8f2e4f8a9b5f9aa16067e142c1ac9cd9f810f473" + integrity sha512-EB2MELswq55OHUoRZLGg/zC7QWUKfNLpE57m/S2yr1uEneIgsTgrSzXP3NXEsMkVn76OlaVVnzN+ugObuYGwhg== + dependencies: + "@babel/helper-plugin-utils" "^7.22.5" + "@babel/plugin-syntax-logical-assignment-operators@^7.8.3": version "7.10.4" resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" @@ -261,7 +295,7 @@ "@babel/parser" "^7.20.7" "@babel/types" "^7.20.7" -"@babel/traverse@^7.20.10", "@babel/traverse@^7.20.12", "@babel/traverse@^7.20.7", "@babel/traverse@^7.7.2": +"@babel/traverse@^7.20.10", "@babel/traverse@^7.20.12", "@babel/traverse@^7.20.7": version "7.20.12" resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.20.12.tgz#7f0f787b3a67ca4475adef1f56cb94f6abd4a4b5" integrity sha512-MsIbFN0u+raeja38qboyF8TIT7K0BFzz/Yd/77ta4MsUsmP2RAnidIlwq7d5HFQrH/OZJecGV6B71C4zAgpoSQ== @@ -291,15 +325,120 @@ resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== -"@esbuild/android-arm@0.15.18": - version "0.15.18" - resolved "https://registry.yarnpkg.com/@esbuild/android-arm/-/android-arm-0.15.18.tgz#266d40b8fdcf87962df8af05b76219bc786b4f80" - integrity sha512-5GT+kcs2WVGjVs7+boataCkO5Fg0y4kCjzkB5bAip7H4jfnOS3dA6KPiww9W1OEKTKeAcUVhdZGvgI65OXmUnw== - -"@esbuild/linux-loong64@0.15.18": - version "0.15.18" - resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.15.18.tgz#128b76ecb9be48b60cf5cfc1c63a4f00691a3239" - integrity sha512-L4jVKS82XVhw2nvzLg/19ClLWg0y27ulRwuP7lcyL6AbUWB5aPglXY3M21mauDQMDfRLs8cQmeT03r/+X3cZYQ== +"@esbuild/aix-ppc64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/aix-ppc64/-/aix-ppc64-0.20.0.tgz#509621cca4e67caf0d18561a0c56f8b70237472f" + integrity sha512-fGFDEctNh0CcSwsiRPxiaqX0P5rq+AqE0SRhYGZ4PX46Lg1FNR6oCxJghf8YgY0WQEgQuh3lErUFE4KxLeRmmw== + +"@esbuild/android-arm64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.20.0.tgz#109a6fdc4a2783fc26193d2687827045d8fef5ab" + integrity sha512-aVpnM4lURNkp0D3qPoAzSG92VXStYmoVPOgXveAUoQBWRSuQzt51yvSju29J6AHPmwY1BjH49uR29oyfH1ra8Q== + +"@esbuild/android-arm@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm/-/android-arm-0.20.0.tgz#1397a2c54c476c4799f9b9073550ede496c94ba5" + integrity sha512-3bMAfInvByLHfJwYPJRlpTeaQA75n8C/QKpEaiS4HrFWFiJlNI0vzq/zCjBrhAYcPyVPG7Eo9dMrcQXuqmNk5g== + +"@esbuild/android-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/android-x64/-/android-x64-0.20.0.tgz#2b615abefb50dc0a70ac313971102f4ce2fdb3ca" + integrity sha512-uK7wAnlRvjkCPzh8jJ+QejFyrP8ObKuR5cBIsQZ+qbMunwR8sbd8krmMbxTLSrDhiPZaJYKQAU5Y3iMDcZPhyQ== + +"@esbuild/darwin-arm64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-arm64/-/darwin-arm64-0.20.0.tgz#5c122ed799eb0c35b9d571097f77254964c276a2" + integrity sha512-AjEcivGAlPs3UAcJedMa9qYg9eSfU6FnGHJjT8s346HSKkrcWlYezGE8VaO2xKfvvlZkgAhyvl06OJOxiMgOYQ== + +"@esbuild/darwin-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-x64/-/darwin-x64-0.20.0.tgz#9561d277002ba8caf1524f209de2b22e93d170c1" + integrity sha512-bsgTPoyYDnPv8ER0HqnJggXK6RyFy4PH4rtsId0V7Efa90u2+EifxytE9pZnsDgExgkARy24WUQGv9irVbTvIw== + +"@esbuild/freebsd-arm64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-arm64/-/freebsd-arm64-0.20.0.tgz#84178986a3138e8500d17cc380044868176dd821" + integrity sha512-kQ7jYdlKS335mpGbMW5tEe3IrQFIok9r84EM3PXB8qBFJPSc6dpWfrtsC/y1pyrz82xfUIn5ZrnSHQQsd6jebQ== + +"@esbuild/freebsd-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-x64/-/freebsd-x64-0.20.0.tgz#3f9ce53344af2f08d178551cd475629147324a83" + integrity sha512-uG8B0WSepMRsBNVXAQcHf9+Ko/Tr+XqmK7Ptel9HVmnykupXdS4J7ovSQUIi0tQGIndhbqWLaIL/qO/cWhXKyQ== + +"@esbuild/linux-arm64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm64/-/linux-arm64-0.20.0.tgz#24efa685515689df4ecbc13031fa0a9dda910a11" + integrity sha512-uTtyYAP5veqi2z9b6Gr0NUoNv9F/rOzI8tOD5jKcCvRUn7T60Bb+42NDBCWNhMjkQzI0qqwXkQGo1SY41G52nw== + +"@esbuild/linux-arm@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm/-/linux-arm-0.20.0.tgz#6b586a488e02e9b073a75a957f2952b3b6e87b4c" + integrity sha512-2ezuhdiZw8vuHf1HKSf4TIk80naTbP9At7sOqZmdVwvvMyuoDiZB49YZKLsLOfKIr77+I40dWpHVeY5JHpIEIg== + +"@esbuild/linux-ia32@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ia32/-/linux-ia32-0.20.0.tgz#84ce7864f762708dcebc1b123898a397dea13624" + integrity sha512-c88wwtfs8tTffPaoJ+SQn3y+lKtgTzyjkD8NgsyCtCmtoIC8RDL7PrJU05an/e9VuAke6eJqGkoMhJK1RY6z4w== + +"@esbuild/linux-loong64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.20.0.tgz#1922f571f4cae1958e3ad29439c563f7d4fd9037" + integrity sha512-lR2rr/128/6svngnVta6JN4gxSXle/yZEZL3o4XZ6esOqhyR4wsKyfu6qXAL04S4S5CgGfG+GYZnjFd4YiG3Aw== + +"@esbuild/linux-mips64el@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-mips64el/-/linux-mips64el-0.20.0.tgz#7ca1bd9df3f874d18dbf46af009aebdb881188fe" + integrity sha512-9Sycc+1uUsDnJCelDf6ZNqgZQoK1mJvFtqf2MUz4ujTxGhvCWw+4chYfDLPepMEvVL9PDwn6HrXad5yOrNzIsQ== + +"@esbuild/linux-ppc64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ppc64/-/linux-ppc64-0.20.0.tgz#8f95baf05f9486343bceeb683703875d698708a4" + integrity sha512-CoWSaaAXOZd+CjbUTdXIJE/t7Oz+4g90A3VBCHLbfuc5yUQU/nFDLOzQsN0cdxgXd97lYW/psIIBdjzQIwTBGw== + +"@esbuild/linux-riscv64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-riscv64/-/linux-riscv64-0.20.0.tgz#ca63b921d5fe315e28610deb0c195e79b1a262ca" + integrity sha512-mlb1hg/eYRJUpv8h/x+4ShgoNLL8wgZ64SUr26KwglTYnwAWjkhR2GpoKftDbPOCnodA9t4Y/b68H4J9XmmPzA== + +"@esbuild/linux-s390x@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-s390x/-/linux-s390x-0.20.0.tgz#cb3d069f47dc202f785c997175f2307531371ef8" + integrity sha512-fgf9ubb53xSnOBqyvWEY6ukBNRl1mVX1srPNu06B6mNsNK20JfH6xV6jECzrQ69/VMiTLvHMicQR/PgTOgqJUQ== + +"@esbuild/linux-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/linux-x64/-/linux-x64-0.20.0.tgz#ac617e0dc14e9758d3d7efd70288c14122557dc7" + integrity sha512-H9Eu6MGse++204XZcYsse1yFHmRXEWgadk2N58O/xd50P9EvFMLJTQLg+lB4E1cF2xhLZU5luSWtGTb0l9UeSg== + +"@esbuild/netbsd-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/netbsd-x64/-/netbsd-x64-0.20.0.tgz#6cc778567f1513da6e08060e0aeb41f82eb0f53c" + integrity sha512-lCT675rTN1v8Fo+RGrE5KjSnfY0x9Og4RN7t7lVrN3vMSjy34/+3na0q7RIfWDAj0e0rCh0OL+P88lu3Rt21MQ== + +"@esbuild/openbsd-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/openbsd-x64/-/openbsd-x64-0.20.0.tgz#76848bcf76b4372574fb4d06cd0ed1fb29ec0fbe" + integrity sha512-HKoUGXz/TOVXKQ+67NhxyHv+aDSZf44QpWLa3I1lLvAwGq8x1k0T+e2HHSRvxWhfJrFxaaqre1+YyzQ99KixoA== + +"@esbuild/sunos-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/sunos-x64/-/sunos-x64-0.20.0.tgz#ea4cd0639bf294ad51bc08ffbb2dac297e9b4706" + integrity sha512-GDwAqgHQm1mVoPppGsoq4WJwT3vhnz/2N62CzhvApFD1eJyTroob30FPpOZabN+FgCjhG+AgcZyOPIkR8dfD7g== + +"@esbuild/win32-arm64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/win32-arm64/-/win32-arm64-0.20.0.tgz#a5c171e4a7f7e4e8be0e9947a65812c1535a7cf0" + integrity sha512-0vYsP8aC4TvMlOQYozoksiaxjlvUcQrac+muDqj1Fxy6jh9l9CZJzj7zmh8JGfiV49cYLTorFLxg7593pGldwQ== + +"@esbuild/win32-ia32@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/win32-ia32/-/win32-ia32-0.20.0.tgz#f8ac5650c412d33ea62d7551e0caf82da52b7f85" + integrity sha512-p98u4rIgfh4gdpV00IqknBD5pC84LCub+4a3MO+zjqvU5MVXOc3hqR2UgT2jI2nh3h8s9EQxmOsVI3tyzv1iFg== + +"@esbuild/win32-x64@0.20.0": + version "0.20.0" + resolved "https://registry.yarnpkg.com/@esbuild/win32-x64/-/win32-x64-0.20.0.tgz#2efddf82828aac85e64cef62482af61c29561bee" + integrity sha512-NgJnesu1RtWihtTtXGFMU5YSE6JyyHPMxCwBZK7a6/8d31GuSo9l0Ss7w1Jw5QnKUawG6UEehs883kcXf5fYwg== "@istanbuljs/load-nyc-config@^1.0.0": version "1.1.0" @@ -317,110 +456,110 @@ resolved "https://registry.yarnpkg.com/@istanbuljs/schema/-/schema-0.1.3.tgz#e45e384e4b8ec16bce2fd903af78450f6bf7ec98" integrity sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA== -"@jest/console@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/console/-/console-28.1.3.tgz#2030606ec03a18c31803b8a36382762e447655df" - integrity sha512-QPAkP5EwKdK/bxIr6C1I4Vs0rm2nHiANzj/Z5X2JQkrZo6IqvC4ldZ9K95tF0HdidhA8Bo6egxSzUFPYKcEXLw== +"@jest/console@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/console/-/console-29.7.0.tgz#cd4822dbdb84529265c5a2bdb529a3c9cc950ffc" + integrity sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg== dependencies: - "@jest/types" "^28.1.3" + "@jest/types" "^29.6.3" "@types/node" "*" chalk "^4.0.0" - jest-message-util "^28.1.3" - jest-util "^28.1.3" + jest-message-util "^29.7.0" + jest-util "^29.7.0" slash "^3.0.0" -"@jest/core@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/core/-/core-28.1.3.tgz#0ebf2bd39840f1233cd5f2d1e6fc8b71bd5a1ac7" - integrity sha512-CIKBrlaKOzA7YG19BEqCw3SLIsEwjZkeJzf5bdooVnW4bH5cktqe3JX+G2YV1aK5vP8N9na1IGWFzYaTp6k6NA== +"@jest/core@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/core/-/core-29.7.0.tgz#b6cccc239f30ff36609658c5a5e2291757ce448f" + integrity sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg== dependencies: - "@jest/console" "^28.1.3" - "@jest/reporters" "^28.1.3" - "@jest/test-result" "^28.1.3" - "@jest/transform" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/console" "^29.7.0" + "@jest/reporters" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" ansi-escapes "^4.2.1" chalk "^4.0.0" ci-info "^3.2.0" exit "^0.1.2" graceful-fs "^4.2.9" - jest-changed-files "^28.1.3" - jest-config "^28.1.3" - jest-haste-map "^28.1.3" - jest-message-util "^28.1.3" - jest-regex-util "^28.0.2" - jest-resolve "^28.1.3" - jest-resolve-dependencies "^28.1.3" - jest-runner "^28.1.3" - jest-runtime "^28.1.3" - jest-snapshot "^28.1.3" - jest-util "^28.1.3" - jest-validate "^28.1.3" - jest-watcher "^28.1.3" + jest-changed-files "^29.7.0" + jest-config "^29.7.0" + jest-haste-map "^29.7.0" + jest-message-util "^29.7.0" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-resolve-dependencies "^29.7.0" + jest-runner "^29.7.0" + jest-runtime "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" + jest-watcher "^29.7.0" micromatch "^4.0.4" - pretty-format "^28.1.3" - rimraf "^3.0.0" + pretty-format "^29.7.0" slash "^3.0.0" strip-ansi "^6.0.0" -"@jest/environment@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-28.1.3.tgz#abed43a6b040a4c24fdcb69eab1f97589b2d663e" - integrity sha512-1bf40cMFTEkKyEf585R9Iz1WayDjHoHqvts0XFYEqyKM3cFWDpeMoqKKTAF9LSYQModPUlh8FKptoM2YcMWAXA== +"@jest/environment@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-29.7.0.tgz#24d61f54ff1f786f3cd4073b4b94416383baf2a7" + integrity sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw== dependencies: - "@jest/fake-timers" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/fake-timers" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" - jest-mock "^28.1.3" + jest-mock "^29.7.0" -"@jest/expect-utils@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/expect-utils/-/expect-utils-28.1.3.tgz#58561ce5db7cd253a7edddbc051fb39dda50f525" - integrity sha512-wvbi9LUrHJLn3NlDW6wF2hvIMtd4JUl2QNVrjq+IBSHirgfrR3o9RnVtxzdEGO2n9JyIWwHnLfby5KzqBGg2YA== +"@jest/expect-utils@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/expect-utils/-/expect-utils-29.7.0.tgz#023efe5d26a8a70f21677d0a1afc0f0a44e3a1c6" + integrity sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA== dependencies: - jest-get-type "^28.0.2" + jest-get-type "^29.6.3" -"@jest/expect@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/expect/-/expect-28.1.3.tgz#9ac57e1d4491baca550f6bdbd232487177ad6a72" - integrity sha512-lzc8CpUbSoE4dqT0U+g1qODQjBRHPpCPXissXD4mS9+sWQdmmpeJ9zSH1rS1HEkrsMN0fb7nKrJ9giAR1d3wBw== +"@jest/expect@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/expect/-/expect-29.7.0.tgz#76a3edb0cb753b70dfbfe23283510d3d45432bf2" + integrity sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ== dependencies: - expect "^28.1.3" - jest-snapshot "^28.1.3" + expect "^29.7.0" + jest-snapshot "^29.7.0" -"@jest/fake-timers@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-28.1.3.tgz#230255b3ad0a3d4978f1d06f70685baea91c640e" - integrity sha512-D/wOkL2POHv52h+ok5Oj/1gOG9HSywdoPtFsRCUmlCILXNn5eIWmcnd3DIiWlJnpGvQtmajqBP95Ei0EimxfLw== +"@jest/fake-timers@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-29.7.0.tgz#fd91bf1fffb16d7d0d24a426ab1a47a49881a565" + integrity sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ== dependencies: - "@jest/types" "^28.1.3" - "@sinonjs/fake-timers" "^9.1.2" + "@jest/types" "^29.6.3" + "@sinonjs/fake-timers" "^10.0.2" "@types/node" "*" - jest-message-util "^28.1.3" - jest-mock "^28.1.3" - jest-util "^28.1.3" + jest-message-util "^29.7.0" + jest-mock "^29.7.0" + jest-util "^29.7.0" -"@jest/globals@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-28.1.3.tgz#a601d78ddc5fdef542728309894895b4a42dc333" - integrity sha512-XFU4P4phyryCXu1pbcqMO0GSQcYe1IsalYCDzRNyhetyeyxMcIxa11qPNDpVNLeretItNqEmYYQn1UYz/5x1NA== +"@jest/globals@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-29.7.0.tgz#8d9290f9ec47ff772607fa864ca1d5a2efae1d4d" + integrity sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ== dependencies: - "@jest/environment" "^28.1.3" - "@jest/expect" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/environment" "^29.7.0" + "@jest/expect" "^29.7.0" + "@jest/types" "^29.6.3" + jest-mock "^29.7.0" -"@jest/reporters@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-28.1.3.tgz#9adf6d265edafc5fc4a434cfb31e2df5a67a369a" - integrity sha512-JuAy7wkxQZVNU/V6g9xKzCGC5LVXx9FDcABKsSXp5MiKPEE2144a/vXTEDoyzjUpZKfVwp08Wqg5A4WfTMAzjg== +"@jest/reporters@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-29.7.0.tgz#04b262ecb3b8faa83b0b3d321623972393e8f4c7" + integrity sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg== dependencies: "@bcoe/v8-coverage" "^0.2.3" - "@jest/console" "^28.1.3" - "@jest/test-result" "^28.1.3" - "@jest/transform" "^28.1.3" - "@jest/types" "^28.1.3" - "@jridgewell/trace-mapping" "^0.3.13" + "@jest/console" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@jridgewell/trace-mapping" "^0.3.18" "@types/node" "*" chalk "^4.0.0" collect-v8-coverage "^1.0.0" @@ -428,82 +567,81 @@ glob "^7.1.3" graceful-fs "^4.2.9" istanbul-lib-coverage "^3.0.0" - istanbul-lib-instrument "^5.1.0" + istanbul-lib-instrument "^6.0.0" istanbul-lib-report "^3.0.0" istanbul-lib-source-maps "^4.0.0" istanbul-reports "^3.1.3" - jest-message-util "^28.1.3" - jest-util "^28.1.3" - jest-worker "^28.1.3" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + jest-worker "^29.7.0" slash "^3.0.0" string-length "^4.0.1" strip-ansi "^6.0.0" - terminal-link "^2.0.0" v8-to-istanbul "^9.0.1" -"@jest/schemas@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/schemas/-/schemas-28.1.3.tgz#ad8b86a66f11f33619e3d7e1dcddd7f2d40ff905" - integrity sha512-/l/VWsdt/aBXgjshLWOFyFt3IVdYypu5y2Wn2rOO1un6nkqIn8SLXzgIMYXFyYsRWDyF5EthmKJMIdJvk08grg== +"@jest/schemas@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/schemas/-/schemas-29.6.3.tgz#430b5ce8a4e0044a7e3819663305a7b3091c8e03" + integrity sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA== dependencies: - "@sinclair/typebox" "^0.24.1" + "@sinclair/typebox" "^0.27.8" -"@jest/source-map@^28.1.2": - version "28.1.2" - resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-28.1.2.tgz#7fe832b172b497d6663cdff6c13b0a920e139e24" - integrity sha512-cV8Lx3BeStJb8ipPHnqVw/IM2VCMWO3crWZzYodSIkxXnRcXJipCdx1JCK0K5MsJJouZQTH73mzf4vgxRaH9ww== +"@jest/source-map@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-29.6.3.tgz#d90ba772095cf37a34a5eb9413f1b562a08554c4" + integrity sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw== dependencies: - "@jridgewell/trace-mapping" "^0.3.13" + "@jridgewell/trace-mapping" "^0.3.18" callsites "^3.0.0" graceful-fs "^4.2.9" -"@jest/test-result@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-28.1.3.tgz#5eae945fd9f4b8fcfce74d239e6f725b6bf076c5" - integrity sha512-kZAkxnSE+FqE8YjW8gNuoVkkC9I7S1qmenl8sGcDOLropASP+BkcGKwhXoyqQuGOGeYY0y/ixjrd/iERpEXHNg== +"@jest/test-result@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-29.7.0.tgz#8db9a80aa1a097bb2262572686734baed9b1657c" + integrity sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA== dependencies: - "@jest/console" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/console" "^29.7.0" + "@jest/types" "^29.6.3" "@types/istanbul-lib-coverage" "^2.0.0" collect-v8-coverage "^1.0.0" -"@jest/test-sequencer@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-28.1.3.tgz#9d0c283d906ac599c74bde464bc0d7e6a82886c3" - integrity sha512-NIMPEqqa59MWnDi1kvXXpYbqsfQmSJsIbnd85mdVGkiDfQ9WQQTXOLsvISUfonmnBT+w85WEgneCigEEdHDFxw== +"@jest/test-sequencer@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz#6cef977ce1d39834a3aea887a1726628a6f072ce" + integrity sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw== dependencies: - "@jest/test-result" "^28.1.3" + "@jest/test-result" "^29.7.0" graceful-fs "^4.2.9" - jest-haste-map "^28.1.3" + jest-haste-map "^29.7.0" slash "^3.0.0" -"@jest/transform@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-28.1.3.tgz#59d8098e50ab07950e0f2fc0fc7ec462371281b0" - integrity sha512-u5dT5di+oFI6hfcLOHGTAfmUxFRrjK+vnaP0kkVow9Md/M7V/MxqQMOz/VV25UZO8pzeA9PjfTpOu6BDuwSPQA== +"@jest/transform@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-29.7.0.tgz#df2dd9c346c7d7768b8a06639994640c642e284c" + integrity sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw== dependencies: "@babel/core" "^7.11.6" - "@jest/types" "^28.1.3" - "@jridgewell/trace-mapping" "^0.3.13" + "@jest/types" "^29.6.3" + "@jridgewell/trace-mapping" "^0.3.18" babel-plugin-istanbul "^6.1.1" chalk "^4.0.0" - convert-source-map "^1.4.0" - fast-json-stable-stringify "^2.0.0" + convert-source-map "^2.0.0" + fast-json-stable-stringify "^2.1.0" graceful-fs "^4.2.9" - jest-haste-map "^28.1.3" - jest-regex-util "^28.0.2" - jest-util "^28.1.3" + jest-haste-map "^29.7.0" + jest-regex-util "^29.6.3" + jest-util "^29.7.0" micromatch "^4.0.4" pirates "^4.0.4" slash "^3.0.0" - write-file-atomic "^4.0.1" + write-file-atomic "^4.0.2" -"@jest/types@^28.1.3": - version "28.1.3" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-28.1.3.tgz#b05de80996ff12512bc5ceb1d208285a7d11748b" - integrity sha512-RyjiyMUZrKz/c+zlMFO1pm70DcIlST8AeWTkoUdZevew44wcNZQHsEVOiCVtgVnlFFD82FPaXycys58cf2muVQ== +"@jest/types@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-29.6.3.tgz#1131f8cf634e7e84c5e77bab12f052af585fba59" + integrity sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw== dependencies: - "@jest/schemas" "^28.1.3" + "@jest/schemas" "^29.6.3" "@types/istanbul-lib-coverage" "^2.0.0" "@types/istanbul-reports" "^3.0.0" "@types/node" "*" @@ -532,17 +670,27 @@ resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz#2203b118c157721addfe69d47b70465463066d78" integrity sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w== +"@jridgewell/resolve-uri@^3.1.0": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz#c08679063f279615a3326583ba3a90d1d82cc721" + integrity sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA== + "@jridgewell/set-array@^1.0.0", "@jridgewell/set-array@^1.0.1": version "1.1.2" resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.2.tgz#7c6cf998d6d20b914c0a55a91ae928ff25965e72" integrity sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw== -"@jridgewell/sourcemap-codec@1.4.14", "@jridgewell/sourcemap-codec@^1.4.10", "@jridgewell/sourcemap-codec@^1.4.13": +"@jridgewell/sourcemap-codec@1.4.14", "@jridgewell/sourcemap-codec@^1.4.10": version "1.4.14" resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz#add4c98d341472a289190b424efbdb096991bb24" integrity sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw== -"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.13", "@jridgewell/trace-mapping@^0.3.9": +"@jridgewell/sourcemap-codec@^1.4.14", "@jridgewell/sourcemap-codec@^1.4.15": + version "1.4.15" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz#d7c6e6755c78567a951e04ab52ef0fd26de59f32" + integrity sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg== + +"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.9": version "0.3.17" resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.17.tgz#793041277af9073b0951a7fe0f0d8c4c98c36985" integrity sha512-MCNzAp77qzKca9+W/+I0+sEpaUnZoeasnghNeVc41VZCEKaCH73Vq3BZZ/SzWIgrqE4H4ceI+p+b6C0mHf9T4g== @@ -550,6 +698,14 @@ "@jridgewell/resolve-uri" "3.1.0" "@jridgewell/sourcemap-codec" "1.4.14" +"@jridgewell/trace-mapping@^0.3.18": + version "0.3.22" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.22.tgz#72a621e5de59f5f1ef792d0793a82ee20f645e4c" + integrity sha512-Wf963MzWtA2sjrNt+g18IAln9lKnlRp+K2eH4jjIoF1wYeq3aMREpG09xhlhdzS0EjwU7qmUJYangWa+151vZw== + dependencies: + "@jridgewell/resolve-uri" "^3.1.0" + "@jridgewell/sourcemap-codec" "^1.4.14" + "@otplib/core@^12.0.1": version "12.0.1" resolved "https://registry.yarnpkg.com/@otplib/core/-/core-12.0.1.tgz#73720a8cedce211fe5b3f683cd5a9c098eaf0f8d" @@ -588,32 +744,98 @@ "@otplib/plugin-crypto" "^12.0.1" "@otplib/plugin-thirty-two" "^12.0.1" -"@rollup/pluginutils@^4.1.1": - version "4.2.1" - resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-4.2.1.tgz#e6c6c3aba0744edce3fb2074922d3776c0af2a6d" - integrity sha512-iKnFXr7NkdZAIHiIWE+BX5ULi/ucVFYWD6TbAV+rZctiRTY2PL6tsIKhoIOaoskiWAkgu+VsbXgUVDNLHf+InQ== +"@rollup/pluginutils@^5.0.5": + version "5.1.0" + resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-5.1.0.tgz#7e53eddc8c7f483a4ad0b94afb1f7f5fd3c771e0" + integrity sha512-XTIWOPPcpvyKI6L1NHo0lFlCyznUEyPmPY1mc3KpPVDYulHSTvyeLNVW00QTLIAFNhR3kYnJTQHeGqU4M3n09g== dependencies: - estree-walker "^2.0.1" - picomatch "^2.2.2" - -"@sinclair/typebox@^0.24.1": - version "0.24.51" - resolved "https://registry.yarnpkg.com/@sinclair/typebox/-/typebox-0.24.51.tgz#645f33fe4e02defe26f2f5c0410e1c094eac7f5f" - integrity sha512-1P1OROm/rdubP5aFDSZQILU0vrLCJ4fvHt6EoqHEM+2D/G5MK3bIaymUKLit8Js9gbns5UyJnkP/TZROLw4tUA== + "@types/estree" "^1.0.0" + estree-walker "^2.0.2" + picomatch "^2.3.1" -"@sinonjs/commons@^1.7.0": - version "1.8.6" - resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-1.8.6.tgz#80c516a4dc264c2a69115e7578d62581ff455ed9" - integrity sha512-Ky+XkAkqPZSm3NLBeUng77EBQl3cmeJhITaGHdYH8kjVB+aun3S4XBRti2zt17mtt0mIUDiNxYeoJm6drVvBJQ== +"@rollup/rollup-android-arm-eabi@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-android-arm-eabi/-/rollup-android-arm-eabi-4.9.6.tgz#66b8d9cb2b3a474d115500f9ebaf43e2126fe496" + integrity sha512-MVNXSSYN6QXOulbHpLMKYi60ppyO13W9my1qogeiAqtjb2yR4LSmfU2+POvDkLzhjYLXz9Rf9+9a3zFHW1Lecg== + +"@rollup/rollup-android-arm64@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-android-arm64/-/rollup-android-arm64-4.9.6.tgz#46327d5b86420d2307946bec1535fdf00356e47d" + integrity sha512-T14aNLpqJ5wzKNf5jEDpv5zgyIqcpn1MlwCrUXLrwoADr2RkWA0vOWP4XxbO9aiO3dvMCQICZdKeDrFl7UMClw== + +"@rollup/rollup-darwin-arm64@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-darwin-arm64/-/rollup-darwin-arm64-4.9.6.tgz#166987224d2f8b1e2fd28ee90c447d52271d5e90" + integrity sha512-CqNNAyhRkTbo8VVZ5R85X73H3R5NX9ONnKbXuHisGWC0qRbTTxnF1U4V9NafzJbgGM0sHZpdO83pLPzq8uOZFw== + +"@rollup/rollup-darwin-x64@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-darwin-x64/-/rollup-darwin-x64-4.9.6.tgz#a2e6e096f74ccea6e2f174454c26aef6bcdd1274" + integrity sha512-zRDtdJuRvA1dc9Mp6BWYqAsU5oeLixdfUvkTHuiYOHwqYuQ4YgSmi6+/lPvSsqc/I0Omw3DdICx4Tfacdzmhog== + +"@rollup/rollup-linux-arm-gnueabihf@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm-gnueabihf/-/rollup-linux-arm-gnueabihf-4.9.6.tgz#09fcd4c55a2d6160c5865fec708a8e5287f30515" + integrity sha512-oNk8YXDDnNyG4qlNb6is1ojTOGL/tRhbbKeE/YuccItzerEZT68Z9gHrY3ROh7axDc974+zYAPxK5SH0j/G+QQ== + +"@rollup/rollup-linux-arm64-gnu@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm64-gnu/-/rollup-linux-arm64-gnu-4.9.6.tgz#19a3c0b6315c747ca9acf86e9b710cc2440f83c9" + integrity sha512-Z3O60yxPtuCYobrtzjo0wlmvDdx2qZfeAWTyfOjEDqd08kthDKexLpV97KfAeUXPosENKd8uyJMRDfFMxcYkDQ== + +"@rollup/rollup-linux-arm64-musl@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-arm64-musl/-/rollup-linux-arm64-musl-4.9.6.tgz#94aaf95fdaf2ad9335983a4552759f98e6b2e850" + integrity sha512-gpiG0qQJNdYEVad+1iAsGAbgAnZ8j07FapmnIAQgODKcOTjLEWM9sRb+MbQyVsYCnA0Im6M6QIq6ax7liws6eQ== + +"@rollup/rollup-linux-riscv64-gnu@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-riscv64-gnu/-/rollup-linux-riscv64-gnu-4.9.6.tgz#160510e63f4b12618af4013bddf1761cf9fc9880" + integrity sha512-+uCOcvVmFUYvVDr27aiyun9WgZk0tXe7ThuzoUTAukZJOwS5MrGbmSlNOhx1j80GdpqbOty05XqSl5w4dQvcOA== + +"@rollup/rollup-linux-x64-gnu@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-x64-gnu/-/rollup-linux-x64-gnu-4.9.6.tgz#5ac5d068ce0726bd0a96ca260d5bd93721c0cb98" + integrity sha512-HUNqM32dGzfBKuaDUBqFB7tP6VMN74eLZ33Q9Y1TBqRDn+qDonkAUyKWwF9BR9unV7QUzffLnz9GrnKvMqC/fw== + +"@rollup/rollup-linux-x64-musl@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-linux-x64-musl/-/rollup-linux-x64-musl-4.9.6.tgz#bafa759ab43e8eab9edf242a8259ffb4f2a57a5d" + integrity sha512-ch7M+9Tr5R4FK40FHQk8VnML0Szi2KRujUgHXd/HjuH9ifH72GUmw6lStZBo3c3GB82vHa0ZoUfjfcM7JiiMrQ== + +"@rollup/rollup-win32-arm64-msvc@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-arm64-msvc/-/rollup-win32-arm64-msvc-4.9.6.tgz#1cc3416682e5a20d8f088f26657e6e47f8db468e" + integrity sha512-VD6qnR99dhmTQ1mJhIzXsRcTBvTjbfbGGwKAHcu+52cVl15AC/kplkhxzW/uT0Xl62Y/meBKDZvoJSJN+vTeGA== + +"@rollup/rollup-win32-ia32-msvc@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-ia32-msvc/-/rollup-win32-ia32-msvc-4.9.6.tgz#7d2251e1aa5e8a1e47c86891fe4547a939503461" + integrity sha512-J9AFDq/xiRI58eR2NIDfyVmTYGyIZmRcvcAoJ48oDld/NTR8wyiPUu2X/v1navJ+N/FGg68LEbX3Ejd6l8B7MQ== + +"@rollup/rollup-win32-x64-msvc@4.9.6": + version "4.9.6" + resolved "https://registry.yarnpkg.com/@rollup/rollup-win32-x64-msvc/-/rollup-win32-x64-msvc-4.9.6.tgz#2c1fb69e02a3f1506f52698cfdc3a8b6386df9a6" + integrity sha512-jqzNLhNDvIZOrt69Ce4UjGRpXJBzhUBzawMwnaDAwyHriki3XollsewxWzOzz+4yOFDkuJHtTsZFwMxhYJWmLQ== + +"@sinclair/typebox@^0.27.8": + version "0.27.8" + resolved "https://registry.yarnpkg.com/@sinclair/typebox/-/typebox-0.27.8.tgz#6667fac16c436b5434a387a34dedb013198f6e6e" + integrity sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA== + +"@sinonjs/commons@^3.0.0": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-3.0.1.tgz#1029357e44ca901a615585f6d27738dbc89084cd" + integrity sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ== dependencies: type-detect "4.0.8" -"@sinonjs/fake-timers@^9.1.2": - version "9.1.2" - resolved "https://registry.yarnpkg.com/@sinonjs/fake-timers/-/fake-timers-9.1.2.tgz#4eaab737fab77332ab132d396a3c0d364bd0ea8c" - integrity sha512-BPS4ynJW/o92PUR4wgriz2Ud5gpST5vz6GQfMixEDK0Z8ZCUv2M7SkBLykH56T++Xs+8ln9zTGbOvNGIe02/jw== +"@sinonjs/fake-timers@^10.0.2": + version "10.3.0" + resolved "https://registry.yarnpkg.com/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz#55fdff1ecab9f354019129daf4df0dd4d923ea66" + integrity sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA== dependencies: - "@sinonjs/commons" "^1.7.0" + "@sinonjs/commons" "^3.0.0" "@types/babel__core@^7.1.14": version "7.1.20" @@ -648,6 +870,11 @@ dependencies: "@babel/types" "^7.3.0" +"@types/estree@1.0.5", "@types/estree@^1.0.0": + version "1.0.5" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.5.tgz#a6ce3e556e00fd9895dd872dd172ad0d4bd687f4" + integrity sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw== + "@types/graceful-fs@^4.1.3": version "4.1.6" resolved "https://registry.yarnpkg.com/@types/graceful-fs/-/graceful-fs-4.1.6.tgz#e14b2576a1c25026b7f02ede1de3b84c3a1efeae" @@ -679,11 +906,6 @@ resolved "https://registry.yarnpkg.com/@types/node/-/node-18.11.18.tgz#8dfb97f0da23c2293e554c5a50d61ef134d7697f" integrity sha512-DHQpWGjyQKSHj3ebjFI/wRKcqQcdR+MoFBygntYOZytCqNfkd2ZC4ARDJ2DQqhjH5p85Nnd3jhUJIXrszFX/JA== -"@types/prettier@^2.1.5": - version "2.7.2" - resolved "https://registry.yarnpkg.com/@types/prettier/-/prettier-2.7.2.tgz#6c2324641cc4ba050a8c710b2b251b377581fbf0" - integrity sha512-KufADq8uQqo1pYKVIYzfKbJfBAc0sOeXqGbFaSpv8MRmC/zXgowNZmFcbngndGk922QDmOASEXUZCaY48gs4cg== - "@types/stack-utils@^2.0.0": version "2.0.1" resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-2.0.1.tgz#20f18294f797f2209b5f65c8e3b5c8e8261d127c" @@ -713,6 +935,11 @@ ansi-regex@^5.0.1: resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== +ansi-sequence-parser@^1.1.0: + version "1.1.1" + resolved "https://registry.yarnpkg.com/ansi-sequence-parser/-/ansi-sequence-parser-1.1.1.tgz#e0aa1cdcbc8f8bb0b5bca625aac41f5f056973cf" + integrity sha512-vJXt3yiaUL4UU546s3rPXlsry/RnM730G1+HkpKE012AN0sx1eOrxSu95oKDIonskeLTijMgqWZ3uDEe3NFvyg== + ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" @@ -752,31 +979,32 @@ asynckit@^0.4.0: resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= -axios-mock-adapter@^1.20.0: - version "1.21.2" - resolved "https://registry.yarnpkg.com/axios-mock-adapter/-/axios-mock-adapter-1.21.2.tgz#87a48f80aa89bb1ab1ad630fa467975e30aa4721" - integrity sha512-jzyNxU3JzB2XVhplZboUcF0YDs7xuExzoRSHXPHr+UQajaGmcTqvkkUADgkVI2WkGlpZ1zZlMVdcTMU0ejV8zQ== +axios-mock-adapter@^1.22.0: + version "1.22.0" + resolved "https://registry.yarnpkg.com/axios-mock-adapter/-/axios-mock-adapter-1.22.0.tgz#0f3e6be0fc9b55baab06f2d49c0b71157e7c053d" + integrity sha512-dmI0KbkyAhntUR05YY96qg2H6gg0XMl2+qTW0xmYg6Up+BFBAJYRLROMXRdDEL06/Wqwa0TJThAYvFtSFdRCZw== dependencies: fast-deep-equal "^3.1.3" is-buffer "^2.0.5" -axios@^0.27.2: - version "0.27.2" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.27.2.tgz#207658cc8621606e586c85db4b41a750e756d972" - integrity sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ== +axios@^1.6.7: + version "1.6.7" + resolved "https://registry.yarnpkg.com/axios/-/axios-1.6.7.tgz#7b48c2e27c96f9c68a2f8f31e2ab19f59b06b0a7" + integrity sha512-/hDJGff6/c7u0hDkvkGxR/oy6CbCs8ziCsC7SqmhjfozqiJGc8Z11wrv9z9lYfY4K8l+H9TpjcMDX0xOZmx+RA== dependencies: - follow-redirects "^1.14.9" + follow-redirects "^1.15.4" form-data "^4.0.0" + proxy-from-env "^1.1.0" -babel-jest@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-28.1.3.tgz#c1187258197c099072156a0a121c11ee1e3917d5" - integrity sha512-epUaPOEWMk3cWX0M/sPvCHHCe9fMFAa/9hXEgKP8nFfNl/jlGkE9ucq9NqkZGXLDduCJYS0UvSlPUwC0S+rH6Q== +babel-jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-29.7.0.tgz#f4369919225b684c56085998ac63dbd05be020d5" + integrity sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg== dependencies: - "@jest/transform" "^28.1.3" + "@jest/transform" "^29.7.0" "@types/babel__core" "^7.1.14" babel-plugin-istanbul "^6.1.1" - babel-preset-jest "^28.1.3" + babel-preset-jest "^29.6.3" chalk "^4.0.0" graceful-fs "^4.2.9" slash "^3.0.0" @@ -792,10 +1020,10 @@ babel-plugin-istanbul@^6.1.1: istanbul-lib-instrument "^5.0.4" test-exclude "^6.0.0" -babel-plugin-jest-hoist@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-28.1.3.tgz#1952c4d0ea50f2d6d794353762278d1d8cca3fbe" - integrity sha512-Ys3tUKAmfnkRUpPdpa98eYrAR0nV+sSFUZZEGuQ2EbFd1y4SOLtD5QDNHAq+bb9a+bbXvYQC4b+ID/THIMcU6Q== +babel-plugin-jest-hoist@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz#aadbe943464182a8922c3c927c3067ff40d24626" + integrity sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg== dependencies: "@babel/template" "^7.3.3" "@babel/types" "^7.3.3" @@ -820,12 +1048,12 @@ babel-preset-current-node-syntax@^1.0.0: "@babel/plugin-syntax-optional-chaining" "^7.8.3" "@babel/plugin-syntax-top-level-await" "^7.8.3" -babel-preset-jest@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-28.1.3.tgz#5dfc20b99abed5db994406c2b9ab94c73aaa419d" - integrity sha512-L+fupJvlWAHbQfn74coNX3zf60LXMJsezNvvx8eIh7iOR1luJ1poxYgQk1F8PYtNq/6QODDHCqsSnTFSWC491A== +babel-preset-jest@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz#fa05fa510e7d493896d7b0dd2033601c840f171c" + integrity sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA== dependencies: - babel-plugin-jest-hoist "^28.1.3" + babel-plugin-jest-hoist "^29.6.3" babel-preset-current-node-syntax "^1.0.0" balanced-match@^1.0.0: @@ -897,7 +1125,7 @@ caniuse-lite@^1.0.30001400: resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001442.tgz#40337f1cf3be7c637b061e2f78582dc1daec0614" integrity sha512-239m03Pqy0hwxYPYR5JwOIxRJfLTWtle9FV8zosfV5pHg+/51uD4nxcUlM8+mWWGfwKtt8lJNHnD3cWw9VZ6ow== -chalk@^2.0.0: +chalk@^2.0.0, chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== @@ -984,11 +1212,29 @@ concat-map@0.0.1: resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== -convert-source-map@^1.4.0, convert-source-map@^1.6.0, convert-source-map@^1.7.0: +convert-source-map@^1.6.0, convert-source-map@^1.7.0: version "1.9.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.9.0.tgz#7faae62353fb4213366d0ca98358d22e8368b05f" integrity sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A== +convert-source-map@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-2.0.0.tgz#4b560f649fc4e918dd0ab75cf4961e8bc882d82a" + integrity sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg== + +create-jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/create-jest/-/create-jest-29.7.0.tgz#a355c5b3cb1e1af02ba177fe7afd7feee49a5320" + integrity sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q== + dependencies: + "@jest/types" "^29.6.3" + chalk "^4.0.0" + exit "^0.1.2" + graceful-fs "^4.2.9" + jest-config "^29.7.0" + jest-util "^29.7.0" + prompts "^2.0.1" + cross-spawn@^7.0.3: version "7.0.3" resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" @@ -998,22 +1244,22 @@ cross-spawn@^7.0.3: shebang-command "^2.0.0" which "^2.0.1" -date-fns@^2.28.0: - version "2.29.3" - resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-2.29.3.tgz#27402d2fc67eb442b511b70bbdf98e6411cd68a8" - integrity sha512-dDCnyH2WnnKusqvZZ6+jA1O51Ibt8ZMRNkDZdyAyK4YfbDwa/cEmuztzG5pk6hqlp9aSBPYcjOlktquahGwGeA== +date-fns@^3.3.1: + version "3.3.1" + resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-3.3.1.tgz#7581daca0892d139736697717a168afbb908cfed" + integrity sha512-y8e109LYGgoQDveiEBD3DYXKba1jWf5BA8YU1FL5Tvm0BTdEfy54WLCwnuYWZNnzzvALy/QQ4Hov+Q9RVRv+Zw== -debug@^4.1.0, debug@^4.1.1, debug@^4.3.3: +debug@^4.1.0, debug@^4.1.1, debug@^4.3.4: version "4.3.4" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== dependencies: ms "2.1.2" -dedent@^0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/dedent/-/dedent-0.7.0.tgz#2495ddbaf6eb874abb0e1be9df22d2e5a544326c" - integrity sha512-Q6fKUPqnAHAyhiUgFU7BUzLiv0kd8saH9al7tnu5Q/okj6dnupxyTgFIBjVzJATdfIAm9NAsvXNzjaKa+bxVyA== +dedent@^1.0.0: + version "1.5.1" + resolved "https://registry.yarnpkg.com/dedent/-/dedent-1.5.1.tgz#4f3fc94c8b711e9bb2800d185cd6ad20f2a90aff" + integrity sha512-+LxW+KLWxu3HW3M2w2ympwtqPrqYRzU8fqi6Fhd18fBALe15blJPI/I4+UHveMVG6lJqB4JNd4UG0S5cnVHwIg== deepmerge@^4.2.2: version "4.2.2" @@ -1030,25 +1276,25 @@ detect-newline@^3.0.0: resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-3.1.0.tgz#576f5dfc63ae1a192ff192d8ad3af6308991b651" integrity sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA== -diff-sequences@^28.1.1: - version "28.1.1" - resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-28.1.1.tgz#9989dc731266dc2903457a70e996f3a041913ac6" - integrity sha512-FU0iFaH/E23a+a718l8Qa/19bF9p06kgE0KipMOMadwa3SjnaElKzPaUC0vnibs6/B/9ni97s61mcejk8W1fQw== +diff-sequences@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-29.6.3.tgz#4deaf894d11407c51efc8418012f9e70b84ea921" + integrity sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q== -dotenv@^16.0.1: - version "16.0.3" - resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.0.3.tgz#115aec42bac5053db3c456db30cc243a5a836a07" - integrity sha512-7GO6HghkA5fYG9TYnNxi14/7K9f5occMlp3zXAuSxn7CKCxt9xbNWG7yF8hTCSUchlfWSe3uLmlPfigevRItzQ== +dotenv@^16.4.1: + version "16.4.1" + resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.4.1.tgz#1d9931f1d3e5d2959350d1250efab299561f7f11" + integrity sha512-CjA3y+Dr3FyFDOAMnxZEGtnW9KBR2M0JvvUtXNW+dYJL5ROWxP9DUHCwgFqpMk0OXCc0ljhaNTr2w/kutYIcHQ== electron-to-chromium@^1.4.251: version "1.4.284" resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.284.tgz#61046d1e4cab3a25238f6bf7413795270f125592" integrity sha512-M8WEXFuKXMYMVr45fo8mq0wUrrJHheiKZf6BArTKk9ZBYCKJEOU5H8cdWgDT+qCVZf7Na4lVUaZsA+h6uA9+PA== -emittery@^0.10.2: - version "0.10.2" - resolved "https://registry.yarnpkg.com/emittery/-/emittery-0.10.2.tgz#902eec8aedb8c41938c46e9385e9db7e03182933" - integrity sha512-aITqOwnLanpHLNXZJENbOgjUBeHocD+xsSJmNrjovKBW5HbSpW3d1pEls7GFQPUWXiwG9+0P4GtHfEqC/4M0Iw== +emittery@^0.13.1: + version "0.13.1" + resolved "https://registry.yarnpkg.com/emittery/-/emittery-0.13.1.tgz#c04b8c3457490e0847ae51fced3af52d338e3dad" + integrity sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ== emoji-regex@^8.0.0: version "8.0.0" @@ -1062,138 +1308,39 @@ error-ex@^1.3.1: dependencies: is-arrayish "^0.2.1" -es-module-lexer@^0.9.3: - version "0.9.3" - resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-0.9.3.tgz#6f13db00cc38417137daf74366f535c8eb438f19" - integrity sha512-1HQ2M2sPtxwnvOvT1ZClHyQDiggdNjURWpY2we6aMKCQiUVxTmVs2UYPLIrD84sS+kMdUwfBSylbJPwNnBrnHQ== - -esbuild-android-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.15.18.tgz#20a7ae1416c8eaade917fb2453c1259302c637a5" - integrity sha512-wnpt3OXRhcjfIDSZu9bnzT4/TNTDsOUvip0foZOUBG7QbSt//w3QV4FInVJxNhKc/ErhUxc5z4QjHtMi7/TbgA== - -esbuild-android-arm64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.15.18.tgz#9cc0ec60581d6ad267568f29cf4895ffdd9f2f04" - integrity sha512-G4xu89B8FCzav9XU8EjsXacCKSG2FT7wW9J6hOc18soEHJdtWu03L3TQDGf0geNxfLTtxENKBzMSq9LlbjS8OQ== - -esbuild-darwin-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.15.18.tgz#428e1730ea819d500808f220fbc5207aea6d4410" - integrity sha512-2WAvs95uPnVJPuYKP0Eqx+Dl/jaYseZEUUT1sjg97TJa4oBtbAKnPnl3b5M9l51/nbx7+QAEtuummJZW0sBEmg== - -esbuild-darwin-arm64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.15.18.tgz#b6dfc7799115a2917f35970bfbc93ae50256b337" - integrity sha512-tKPSxcTJ5OmNb1btVikATJ8NftlyNlc8BVNtyT/UAr62JFOhwHlnoPrhYWz09akBLHI9nElFVfWSTSRsrZiDUA== - -esbuild-freebsd-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-64/-/esbuild-freebsd-64-0.15.18.tgz#4e190d9c2d1e67164619ae30a438be87d5eedaf2" - integrity sha512-TT3uBUxkteAjR1QbsmvSsjpKjOX6UkCstr8nMr+q7zi3NuZ1oIpa8U41Y8I8dJH2fJgdC3Dj3CXO5biLQpfdZA== - -esbuild-freebsd-arm64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-freebsd-arm64/-/esbuild-freebsd-arm64-0.15.18.tgz#18a4c0344ee23bd5a6d06d18c76e2fd6d3f91635" - integrity sha512-R/oVr+X3Tkh+S0+tL41wRMbdWtpWB8hEAMsOXDumSSa6qJR89U0S/PpLXrGF7Wk/JykfpWNokERUpCeHDl47wA== - -esbuild-linux-32@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-32/-/esbuild-linux-32-0.15.18.tgz#9a329731ee079b12262b793fb84eea762e82e0ce" - integrity sha512-lphF3HiCSYtaa9p1DtXndiQEeQDKPl9eN/XNoBf2amEghugNuqXNZA/ZovthNE2aa4EN43WroO0B85xVSjYkbg== - -esbuild-linux-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-64/-/esbuild-linux-64-0.15.18.tgz#532738075397b994467b514e524aeb520c191b6c" - integrity sha512-hNSeP97IviD7oxLKFuii5sDPJ+QHeiFTFLoLm7NZQligur8poNOWGIgpQ7Qf8Balb69hptMZzyOBIPtY09GZYw== - -esbuild-linux-arm64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm64/-/esbuild-linux-arm64-0.15.18.tgz#5372e7993ac2da8f06b2ba313710d722b7a86e5d" - integrity sha512-54qr8kg/6ilcxd+0V3h9rjT4qmjc0CccMVWrjOEM/pEcUzt8X62HfBSeZfT2ECpM7104mk4yfQXkosY8Quptug== - -esbuild-linux-arm@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-arm/-/esbuild-linux-arm-0.15.18.tgz#e734aaf259a2e3d109d4886c9e81ec0f2fd9a9cc" - integrity sha512-UH779gstRblS4aoS2qpMl3wjg7U0j+ygu3GjIeTonCcN79ZvpPee12Qun3vcdxX+37O5LFxz39XeW2I9bybMVA== - -esbuild-linux-mips64le@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-mips64le/-/esbuild-linux-mips64le-0.15.18.tgz#c0487c14a9371a84eb08fab0e1d7b045a77105eb" - integrity sha512-Mk6Ppwzzz3YbMl/ZZL2P0q1tnYqh/trYZ1VfNP47C31yT0K8t9s7Z077QrDA/guU60tGNp2GOwCQnp+DYv7bxQ== - -esbuild-linux-ppc64le@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-ppc64le/-/esbuild-linux-ppc64le-0.15.18.tgz#af048ad94eed0ce32f6d5a873f7abe9115012507" - integrity sha512-b0XkN4pL9WUulPTa/VKHx2wLCgvIAbgwABGnKMY19WhKZPT+8BxhZdqz6EgkqCLld7X5qiCY2F/bfpUUlnFZ9w== - -esbuild-linux-riscv64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-riscv64/-/esbuild-linux-riscv64-0.15.18.tgz#423ed4e5927bd77f842bd566972178f424d455e6" - integrity sha512-ba2COaoF5wL6VLZWn04k+ACZjZ6NYniMSQStodFKH/Pu6RxzQqzsmjR1t9QC89VYJxBeyVPTaHuBMCejl3O/xg== - -esbuild-linux-s390x@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-linux-s390x/-/esbuild-linux-s390x-0.15.18.tgz#21d21eaa962a183bfb76312e5a01cc5ae48ce8eb" - integrity sha512-VbpGuXEl5FCs1wDVp93O8UIzl3ZrglgnSQ+Hu79g7hZu6te6/YHgVJxCM2SqfIila0J3k0csfnf8VD2W7u2kzQ== - -esbuild-netbsd-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-netbsd-64/-/esbuild-netbsd-64-0.15.18.tgz#ae75682f60d08560b1fe9482bfe0173e5110b998" - integrity sha512-98ukeCdvdX7wr1vUYQzKo4kQ0N2p27H7I11maINv73fVEXt2kyh4K4m9f35U1K43Xc2QGXlzAw0K9yoU7JUjOg== - -esbuild-openbsd-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-openbsd-64/-/esbuild-openbsd-64-0.15.18.tgz#79591a90aa3b03e4863f93beec0d2bab2853d0a8" - integrity sha512-yK5NCcH31Uae076AyQAXeJzt/vxIo9+omZRKj1pauhk3ITuADzuOx5N2fdHrAKPxN+zH3w96uFKlY7yIn490xQ== - -esbuild-sunos-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-sunos-64/-/esbuild-sunos-64-0.15.18.tgz#fd528aa5da5374b7e1e93d36ef9b07c3dfed2971" - integrity sha512-On22LLFlBeLNj/YF3FT+cXcyKPEI263nflYlAhz5crxtp3yRG1Ugfr7ITyxmCmjm4vbN/dGrb/B7w7U8yJR9yw== - -esbuild-windows-32@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-windows-32/-/esbuild-windows-32-0.15.18.tgz#0e92b66ecdf5435a76813c4bc5ccda0696f4efc3" - integrity sha512-o+eyLu2MjVny/nt+E0uPnBxYuJHBvho8vWsC2lV61A7wwTWC3jkN2w36jtA+yv1UgYkHRihPuQsL23hsCYGcOQ== - -esbuild-windows-64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-windows-64/-/esbuild-windows-64-0.15.18.tgz#0fc761d785414284fc408e7914226d33f82420d0" - integrity sha512-qinug1iTTaIIrCorAUjR0fcBk24fjzEedFYhhispP8Oc7SFvs+XeW3YpAKiKp8dRpizl4YYAhxMjlftAMJiaUw== - -esbuild-windows-arm64@0.15.18: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild-windows-arm64/-/esbuild-windows-arm64-0.15.18.tgz#5b5bdc56d341d0922ee94965c89ee120a6a86eb7" - integrity sha512-q9bsYzegpZcLziq0zgUi5KqGVtfhjxGbnksaBFYmWLxeV/S1fK4OLdq2DFYnXcLMjlZw2L0jLsk1eGoB522WXQ== - -esbuild@^0.15.12: - version "0.15.18" - resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.15.18.tgz#ea894adaf3fbc036d32320a00d4d6e4978a2f36d" - integrity sha512-x/R72SmW3sSFRm5zrrIjAhCeQSAWoni3CmHEqfQrZIQTM3lVCdehdwuIqaOtfC2slvpdlLa62GYoN8SxT23m6Q== +es-module-lexer@^1.3.1: + version "1.4.1" + resolved "https://registry.yarnpkg.com/es-module-lexer/-/es-module-lexer-1.4.1.tgz#41ea21b43908fe6a287ffcbe4300f790555331f5" + integrity sha512-cXLGjP0c4T3flZJKQSuziYoq7MlT+rnvfZjfp7h+I7K9BNX54kP9nyWvdbwjQ4u1iWbOL4u96fgeZLToQlZC7w== + +esbuild@^0.20.0: + version "0.20.0" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.20.0.tgz#a7170b63447286cd2ff1f01579f09970e6965da4" + integrity sha512-6iwE3Y2RVYCME1jLpBqq7LQWK3MW6vjV2bZy6gt/WrqkY+WE74Spyc0ThAOYpMtITvnjX09CrC6ym7A/m9mebA== optionalDependencies: - "@esbuild/android-arm" "0.15.18" - "@esbuild/linux-loong64" "0.15.18" - esbuild-android-64 "0.15.18" - esbuild-android-arm64 "0.15.18" - esbuild-darwin-64 "0.15.18" - esbuild-darwin-arm64 "0.15.18" - esbuild-freebsd-64 "0.15.18" - esbuild-freebsd-arm64 "0.15.18" - esbuild-linux-32 "0.15.18" - esbuild-linux-64 "0.15.18" - esbuild-linux-arm "0.15.18" - esbuild-linux-arm64 "0.15.18" - esbuild-linux-mips64le "0.15.18" - esbuild-linux-ppc64le "0.15.18" - esbuild-linux-riscv64 "0.15.18" - esbuild-linux-s390x "0.15.18" - esbuild-netbsd-64 "0.15.18" - esbuild-openbsd-64 "0.15.18" - esbuild-sunos-64 "0.15.18" - esbuild-windows-32 "0.15.18" - esbuild-windows-64 "0.15.18" - esbuild-windows-arm64 "0.15.18" + "@esbuild/aix-ppc64" "0.20.0" + "@esbuild/android-arm" "0.20.0" + "@esbuild/android-arm64" "0.20.0" + "@esbuild/android-x64" "0.20.0" + "@esbuild/darwin-arm64" "0.20.0" + "@esbuild/darwin-x64" "0.20.0" + "@esbuild/freebsd-arm64" "0.20.0" + "@esbuild/freebsd-x64" "0.20.0" + "@esbuild/linux-arm" "0.20.0" + "@esbuild/linux-arm64" "0.20.0" + "@esbuild/linux-ia32" "0.20.0" + "@esbuild/linux-loong64" "0.20.0" + "@esbuild/linux-mips64el" "0.20.0" + "@esbuild/linux-ppc64" "0.20.0" + "@esbuild/linux-riscv64" "0.20.0" + "@esbuild/linux-s390x" "0.20.0" + "@esbuild/linux-x64" "0.20.0" + "@esbuild/netbsd-x64" "0.20.0" + "@esbuild/openbsd-x64" "0.20.0" + "@esbuild/sunos-x64" "0.20.0" + "@esbuild/win32-arm64" "0.20.0" + "@esbuild/win32-ia32" "0.20.0" + "@esbuild/win32-x64" "0.20.0" escalade@^3.1.1: version "3.1.1" @@ -1215,7 +1362,7 @@ esprima@^4.0.0: resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== -estree-walker@^2.0.1: +estree-walker@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== @@ -1240,23 +1387,23 @@ exit@^0.1.2: resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" integrity sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ== -expect@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/expect/-/expect-28.1.3.tgz#90a7c1a124f1824133dd4533cce2d2bdcb6603ec" - integrity sha512-eEh0xn8HlsuOBxFgIss+2mX85VAS4Qy3OSkjV7rlBWljtA4oWH37glVGyOZSZvErDT/yBywZdPGwCXuTvSG85g== +expect@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-29.7.0.tgz#578874590dcb3214514084c08115d8aee61e11bc" + integrity sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw== dependencies: - "@jest/expect-utils" "^28.1.3" - jest-get-type "^28.0.2" - jest-matcher-utils "^28.1.3" - jest-message-util "^28.1.3" - jest-util "^28.1.3" + "@jest/expect-utils" "^29.7.0" + jest-get-type "^29.6.3" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" fast-deep-equal@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== -fast-json-stable-stringify@^2.0.0: +fast-json-stable-stringify@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== @@ -1283,10 +1430,10 @@ find-up@^4.0.0, find-up@^4.1.0: locate-path "^5.0.0" path-exists "^4.0.0" -follow-redirects@^1.14.9: - version "1.15.0" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.0.tgz#06441868281c86d0dda4ad8bdaead2d02dca89d4" - integrity sha512-aExlJShTV4qOUOL7yF1U5tvLCB0xQuudbf6toyYA0E/acBNw71mvjFTnLaRp50aQaYocMR0a/RMMBIHeZnGyjQ== +follow-redirects@^1.15.4: + version "1.15.5" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.5.tgz#54d4d6d062c0fa7d9d17feb008461550e3ba8020" + integrity sha512-vSFWUON1B+yAw1VN4xMfxgn5fTUiaOzAJCKBwIIgT/+7CuGy9+r+5gITvP62j3RmaD5Ph65UaERdOSRGUzZtgw== form-data@^4.0.0: version "4.0.0" @@ -1332,6 +1479,13 @@ get-stream@^6.0.0: resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== +get-tsconfig@^4.7.2: + version "4.7.2" + resolved "https://registry.yarnpkg.com/get-tsconfig/-/get-tsconfig-4.7.2.tgz#0dcd6fb330391d46332f4c6c1bf89a6514c2ddce" + integrity sha512-wuMsz4leaj5hbGgg4IvDU0bqJagpftG5l5cXIAvo8uZrqn0NJqwtfupTN00VnkQJPcIRrxYrm1Ue24btpCha2A== + dependencies: + resolve-pkg-maps "^1.0.0" + glob@^7.1.3, glob@^7.1.4: version "7.2.3" resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" @@ -1454,7 +1608,7 @@ istanbul-lib-coverage@^3.0.0, istanbul-lib-coverage@^3.2.0: resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz#189e7909d0a39fa5a3dfad5b03f71947770191d3" integrity sha512-eOeJ5BHCmHYvQK7xt9GkdHuzuCGS1Y6g9Gvnx3Ym33fz/HpLRYxiS0wHNr+m/MBC8B647Xt608vCDEvhl9c6Mw== -istanbul-lib-instrument@^5.0.4, istanbul-lib-instrument@^5.1.0: +istanbul-lib-instrument@^5.0.4: version "5.2.1" resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz#d10c8885c2125574e1c231cacadf955675e1ce3d" integrity sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg== @@ -1465,6 +1619,17 @@ istanbul-lib-instrument@^5.0.4, istanbul-lib-instrument@^5.1.0: istanbul-lib-coverage "^3.2.0" semver "^6.3.0" +istanbul-lib-instrument@^6.0.0: + version "6.0.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.1.tgz#71e87707e8041428732518c6fb5211761753fbdf" + integrity sha512-EAMEJBsYuyyztxMxW3g7ugGPkrZsV57v0Hmv3mm1uQsmB+QnZuepg731CRaIgeUVSdmsTngOkSnauNF8p7FIhA== + dependencies: + "@babel/core" "^7.12.3" + "@babel/parser" "^7.14.7" + "@istanbuljs/schema" "^0.1.2" + istanbul-lib-coverage "^3.2.0" + semver "^7.5.4" + istanbul-lib-report@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz#7518fe52ea44de372f460a76b5ecda9ffb73d8a6" @@ -1491,144 +1656,145 @@ istanbul-reports@^3.1.3: html-escaper "^2.0.0" istanbul-lib-report "^3.0.0" -jest-changed-files@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-28.1.3.tgz#d9aeee6792be3686c47cb988a8eaf82ff4238831" - integrity sha512-esaOfUWJXk2nfZt9SPyC8gA1kNfdKLkQWyzsMlqq8msYSlNKfmZxfRgZn4Cd4MGVUF+7v6dBs0d5TOAKa7iIiA== +jest-changed-files@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-29.7.0.tgz#1c06d07e77c78e1585d020424dedc10d6e17ac3a" + integrity sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w== dependencies: execa "^5.0.0" + jest-util "^29.7.0" p-limit "^3.1.0" -jest-circus@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-28.1.3.tgz#d14bd11cf8ee1a03d69902dc47b6bd4634ee00e4" - integrity sha512-cZ+eS5zc79MBwt+IhQhiEp0OeBddpc1n8MBo1nMB8A7oPMKEO+Sre+wHaLJexQUj9Ya/8NOBY0RESUgYjB6fow== +jest-circus@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-29.7.0.tgz#b6817a45fcc835d8b16d5962d0c026473ee3668a" + integrity sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw== dependencies: - "@jest/environment" "^28.1.3" - "@jest/expect" "^28.1.3" - "@jest/test-result" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/environment" "^29.7.0" + "@jest/expect" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" chalk "^4.0.0" co "^4.6.0" - dedent "^0.7.0" + dedent "^1.0.0" is-generator-fn "^2.0.0" - jest-each "^28.1.3" - jest-matcher-utils "^28.1.3" - jest-message-util "^28.1.3" - jest-runtime "^28.1.3" - jest-snapshot "^28.1.3" - jest-util "^28.1.3" + jest-each "^29.7.0" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-runtime "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" p-limit "^3.1.0" - pretty-format "^28.1.3" + pretty-format "^29.7.0" + pure-rand "^6.0.0" slash "^3.0.0" stack-utils "^2.0.3" -jest-cli@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-28.1.3.tgz#558b33c577d06de55087b8448d373b9f654e46b2" - integrity sha512-roY3kvrv57Azn1yPgdTebPAXvdR2xfezaKKYzVxZ6It/5NCxzJym6tUI5P1zkdWhfUYkxEI9uZWcQdaFLo8mJQ== +jest-cli@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-29.7.0.tgz#5592c940798e0cae677eec169264f2d839a37995" + integrity sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg== dependencies: - "@jest/core" "^28.1.3" - "@jest/test-result" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/core" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" chalk "^4.0.0" + create-jest "^29.7.0" exit "^0.1.2" - graceful-fs "^4.2.9" import-local "^3.0.2" - jest-config "^28.1.3" - jest-util "^28.1.3" - jest-validate "^28.1.3" - prompts "^2.0.1" + jest-config "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" yargs "^17.3.1" -jest-config@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-28.1.3.tgz#e315e1f73df3cac31447eed8b8740a477392ec60" - integrity sha512-MG3INjByJ0J4AsNBm7T3hsuxKQqFIiRo/AUqb1q9LRKI5UU6Aar9JHbr9Ivn1TVwfUD9KirRoM/T6u8XlcQPHQ== +jest-config@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-29.7.0.tgz#bcbda8806dbcc01b1e316a46bb74085a84b0245f" + integrity sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ== dependencies: "@babel/core" "^7.11.6" - "@jest/test-sequencer" "^28.1.3" - "@jest/types" "^28.1.3" - babel-jest "^28.1.3" + "@jest/test-sequencer" "^29.7.0" + "@jest/types" "^29.6.3" + babel-jest "^29.7.0" chalk "^4.0.0" ci-info "^3.2.0" deepmerge "^4.2.2" glob "^7.1.3" graceful-fs "^4.2.9" - jest-circus "^28.1.3" - jest-environment-node "^28.1.3" - jest-get-type "^28.0.2" - jest-regex-util "^28.0.2" - jest-resolve "^28.1.3" - jest-runner "^28.1.3" - jest-util "^28.1.3" - jest-validate "^28.1.3" + jest-circus "^29.7.0" + jest-environment-node "^29.7.0" + jest-get-type "^29.6.3" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-runner "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" micromatch "^4.0.4" parse-json "^5.2.0" - pretty-format "^28.1.3" + pretty-format "^29.7.0" slash "^3.0.0" strip-json-comments "^3.1.1" -jest-diff@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-28.1.3.tgz#948a192d86f4e7a64c5264ad4da4877133d8792f" - integrity sha512-8RqP1B/OXzjjTWkqMX67iqgwBVJRgCyKD3L9nq+6ZqJMdvjE8RgHktqZ6jNrkdMT+dJuYNI3rhQpxaz7drJHfw== +jest-diff@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-29.7.0.tgz#017934a66ebb7ecf6f205e84699be10afd70458a" + integrity sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw== dependencies: chalk "^4.0.0" - diff-sequences "^28.1.1" - jest-get-type "^28.0.2" - pretty-format "^28.1.3" + diff-sequences "^29.6.3" + jest-get-type "^29.6.3" + pretty-format "^29.7.0" -jest-docblock@^28.1.1: - version "28.1.1" - resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-28.1.1.tgz#6f515c3bf841516d82ecd57a62eed9204c2f42a8" - integrity sha512-3wayBVNiOYx0cwAbl9rwm5kKFP8yHH3d/fkEaL02NPTkDojPtheGB7HZSFY4wzX+DxyrvhXz0KSCVksmCknCuA== +jest-docblock@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-29.7.0.tgz#8fddb6adc3cdc955c93e2a87f61cfd350d5d119a" + integrity sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g== dependencies: detect-newline "^3.0.0" -jest-each@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-28.1.3.tgz#bdd1516edbe2b1f3569cfdad9acd543040028f81" - integrity sha512-arT1z4sg2yABU5uogObVPvSlSMQlDA48owx07BDPAiasW0yYpYHYOo4HHLz9q0BVzDVU4hILFjzJw0So9aCL/g== +jest-each@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-29.7.0.tgz#162a9b3f2328bdd991beaabffbb74745e56577d1" + integrity sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ== dependencies: - "@jest/types" "^28.1.3" + "@jest/types" "^29.6.3" chalk "^4.0.0" - jest-get-type "^28.0.2" - jest-util "^28.1.3" - pretty-format "^28.1.3" - -jest-environment-node@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-28.1.3.tgz#7e74fe40eb645b9d56c0c4b70ca4357faa349be5" - integrity sha512-ugP6XOhEpjAEhGYvp5Xj989ns5cB1K6ZdjBYuS30umT4CQEETaxSiPcZ/E1kFktX4GkrcM4qu07IIlDYX1gp+A== - dependencies: - "@jest/environment" "^28.1.3" - "@jest/fake-timers" "^28.1.3" - "@jest/types" "^28.1.3" + jest-get-type "^29.6.3" + jest-util "^29.7.0" + pretty-format "^29.7.0" + +jest-environment-node@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-29.7.0.tgz#0b93e111dda8ec120bc8300e6d1fb9576e164376" + integrity sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/fake-timers" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" - jest-mock "^28.1.3" - jest-util "^28.1.3" + jest-mock "^29.7.0" + jest-util "^29.7.0" -jest-get-type@^28.0.2: - version "28.0.2" - resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-28.0.2.tgz#34622e628e4fdcd793d46db8a242227901fcf203" - integrity sha512-ioj2w9/DxSYHfOm5lJKCdcAmPJzQXmbM/Url3rhlghrPvT3tt+7a/+oXc9azkKmLvoiXjtV83bEWqi+vs5nlPA== +jest-get-type@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-29.6.3.tgz#36f499fdcea197c1045a127319c0481723908fd1" + integrity sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw== -jest-haste-map@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-28.1.3.tgz#abd5451129a38d9841049644f34b034308944e2b" - integrity sha512-3S+RQWDXccXDKSWnkHa/dPwt+2qwA8CJzR61w3FoYCvoo3Pn8tvGcysmMF0Bj0EX5RYvAI2EIvC57OmotfdtKA== +jest-haste-map@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-29.7.0.tgz#3c2396524482f5a0506376e6c858c3bbcc17b104" + integrity sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA== dependencies: - "@jest/types" "^28.1.3" + "@jest/types" "^29.6.3" "@types/graceful-fs" "^4.1.3" "@types/node" "*" anymatch "^3.0.3" fb-watchman "^2.0.0" graceful-fs "^4.2.9" - jest-regex-util "^28.0.2" - jest-util "^28.1.3" - jest-worker "^28.1.3" + jest-regex-util "^29.6.3" + jest-util "^29.7.0" + jest-worker "^29.7.0" micromatch "^4.0.4" walker "^1.0.8" optionalDependencies: @@ -1639,225 +1805,219 @@ jest-in-case@^1.0.2: resolved "https://registry.yarnpkg.com/jest-in-case/-/jest-in-case-1.0.2.tgz#56744b5af33222bd0abab70cf919f1d170ab75cc" integrity sha1-VnRLWvMyIr0KurcM+Rnx0XCrdcw= -jest-leak-detector@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-28.1.3.tgz#a6685d9b074be99e3adee816ce84fd30795e654d" - integrity sha512-WFVJhnQsiKtDEo5lG2mM0v40QWnBM+zMdHHyJs8AWZ7J0QZJS59MsyKeJHWhpBZBH32S48FOVvGyOFT1h0DlqA== +jest-leak-detector@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz#5b7ec0dadfdfec0ca383dc9aa016d36b5ea4c728" + integrity sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw== dependencies: - jest-get-type "^28.0.2" - pretty-format "^28.1.3" + jest-get-type "^29.6.3" + pretty-format "^29.7.0" -jest-matcher-utils@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-28.1.3.tgz#5a77f1c129dd5ba3b4d7fc20728806c78893146e" - integrity sha512-kQeJ7qHemKfbzKoGjHHrRKH6atgxMk8Enkk2iPQ3XwO6oE/KYD8lMYOziCkeSB9G4adPM4nR1DE8Tf5JeWH6Bw== +jest-matcher-utils@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz#ae8fec79ff249fd592ce80e3ee474e83a6c44f12" + integrity sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g== dependencies: chalk "^4.0.0" - jest-diff "^28.1.3" - jest-get-type "^28.0.2" - pretty-format "^28.1.3" + jest-diff "^29.7.0" + jest-get-type "^29.6.3" + pretty-format "^29.7.0" -jest-message-util@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-28.1.3.tgz#232def7f2e333f1eecc90649b5b94b0055e7c43d" - integrity sha512-PFdn9Iewbt575zKPf1286Ht9EPoJmYT7P0kY+RibeYZ2XtOr53pDLEFoTWXbd1h4JiGiWpTBC84fc8xMXQMb7g== +jest-message-util@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-29.7.0.tgz#8bc392e204e95dfe7564abbe72a404e28e51f7f3" + integrity sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w== dependencies: "@babel/code-frame" "^7.12.13" - "@jest/types" "^28.1.3" + "@jest/types" "^29.6.3" "@types/stack-utils" "^2.0.0" chalk "^4.0.0" graceful-fs "^4.2.9" micromatch "^4.0.4" - pretty-format "^28.1.3" + pretty-format "^29.7.0" slash "^3.0.0" stack-utils "^2.0.3" -jest-mock@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-28.1.3.tgz#d4e9b1fc838bea595c77ab73672ebf513ab249da" - integrity sha512-o3J2jr6dMMWYVH4Lh/NKmDXdosrsJgi4AviS8oXLujcjpCMBb1FMsblDnOXKZKfSiHLxYub1eS0IHuRXsio9eA== +jest-mock@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-29.7.0.tgz#4e836cf60e99c6fcfabe9f99d017f3fdd50a6347" + integrity sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw== dependencies: - "@jest/types" "^28.1.3" + "@jest/types" "^29.6.3" "@types/node" "*" + jest-util "^29.7.0" jest-pnp-resolver@^1.2.2: version "1.2.3" resolved "https://registry.yarnpkg.com/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz#930b1546164d4ad5937d5540e711d4d38d4cad2e" integrity sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w== -jest-regex-util@^28.0.2: - version "28.0.2" - resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-28.0.2.tgz#afdc377a3b25fb6e80825adcf76c854e5bf47ead" - integrity sha512-4s0IgyNIy0y9FK+cjoVYoxamT7Zeo7MhzqRGx7YDYmaQn1wucY9rotiGkBzzcMXTtjrCAP/f7f+E0F7+fxPNdw== +jest-regex-util@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-29.6.3.tgz#4a556d9c776af68e1c5f48194f4d0327d24e8a52" + integrity sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg== -jest-resolve-dependencies@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-28.1.3.tgz#8c65d7583460df7275c6ea2791901fa975c1fe66" - integrity sha512-qa0QO2Q0XzQoNPouMbCc7Bvtsem8eQgVPNkwn9LnS+R2n8DaVDPL/U1gngC0LTl1RYXJU0uJa2BMC2DbTfFrHA== +jest-resolve-dependencies@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz#1b04f2c095f37fc776ff40803dc92921b1e88428" + integrity sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA== dependencies: - jest-regex-util "^28.0.2" - jest-snapshot "^28.1.3" + jest-regex-util "^29.6.3" + jest-snapshot "^29.7.0" -jest-resolve@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-28.1.3.tgz#cfb36100341ddbb061ec781426b3c31eb51aa0a8" - integrity sha512-Z1W3tTjE6QaNI90qo/BJpfnvpxtaFTFw5CDgwpyE/Kz8U/06N1Hjf4ia9quUhCh39qIGWF1ZuxFiBiJQwSEYKQ== +jest-resolve@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-29.7.0.tgz#64d6a8992dd26f635ab0c01e5eef4399c6bcbc30" + integrity sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA== dependencies: chalk "^4.0.0" graceful-fs "^4.2.9" - jest-haste-map "^28.1.3" + jest-haste-map "^29.7.0" jest-pnp-resolver "^1.2.2" - jest-util "^28.1.3" - jest-validate "^28.1.3" + jest-util "^29.7.0" + jest-validate "^29.7.0" resolve "^1.20.0" - resolve.exports "^1.1.0" + resolve.exports "^2.0.0" slash "^3.0.0" -jest-runner@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-28.1.3.tgz#5eee25febd730b4713a2cdfd76bdd5557840f9a1" - integrity sha512-GkMw4D/0USd62OVO0oEgjn23TM+YJa2U2Wu5zz9xsQB1MxWKDOlrnykPxnMsN0tnJllfLPinHTka61u0QhaxBA== +jest-runner@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-29.7.0.tgz#809af072d408a53dcfd2e849a4c976d3132f718e" + integrity sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ== dependencies: - "@jest/console" "^28.1.3" - "@jest/environment" "^28.1.3" - "@jest/test-result" "^28.1.3" - "@jest/transform" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/console" "^29.7.0" + "@jest/environment" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" chalk "^4.0.0" - emittery "^0.10.2" + emittery "^0.13.1" graceful-fs "^4.2.9" - jest-docblock "^28.1.1" - jest-environment-node "^28.1.3" - jest-haste-map "^28.1.3" - jest-leak-detector "^28.1.3" - jest-message-util "^28.1.3" - jest-resolve "^28.1.3" - jest-runtime "^28.1.3" - jest-util "^28.1.3" - jest-watcher "^28.1.3" - jest-worker "^28.1.3" + jest-docblock "^29.7.0" + jest-environment-node "^29.7.0" + jest-haste-map "^29.7.0" + jest-leak-detector "^29.7.0" + jest-message-util "^29.7.0" + jest-resolve "^29.7.0" + jest-runtime "^29.7.0" + jest-util "^29.7.0" + jest-watcher "^29.7.0" + jest-worker "^29.7.0" p-limit "^3.1.0" source-map-support "0.5.13" -jest-runtime@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-28.1.3.tgz#a57643458235aa53e8ec7821949e728960d0605f" - integrity sha512-NU+881ScBQQLc1JHG5eJGU7Ui3kLKrmwCPPtYsJtBykixrM2OhVQlpMmFWJjMyDfdkGgBMNjXCGB/ebzsgNGQw== - dependencies: - "@jest/environment" "^28.1.3" - "@jest/fake-timers" "^28.1.3" - "@jest/globals" "^28.1.3" - "@jest/source-map" "^28.1.2" - "@jest/test-result" "^28.1.3" - "@jest/transform" "^28.1.3" - "@jest/types" "^28.1.3" +jest-runtime@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-29.7.0.tgz#efecb3141cf7d3767a3a0cc8f7c9990587d3d817" + integrity sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/fake-timers" "^29.7.0" + "@jest/globals" "^29.7.0" + "@jest/source-map" "^29.6.3" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" chalk "^4.0.0" cjs-module-lexer "^1.0.0" collect-v8-coverage "^1.0.0" - execa "^5.0.0" glob "^7.1.3" graceful-fs "^4.2.9" - jest-haste-map "^28.1.3" - jest-message-util "^28.1.3" - jest-mock "^28.1.3" - jest-regex-util "^28.0.2" - jest-resolve "^28.1.3" - jest-snapshot "^28.1.3" - jest-util "^28.1.3" + jest-haste-map "^29.7.0" + jest-message-util "^29.7.0" + jest-mock "^29.7.0" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" slash "^3.0.0" strip-bom "^4.0.0" -jest-snapshot@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-28.1.3.tgz#17467b3ab8ddb81e2f605db05583d69388fc0668" - integrity sha512-4lzMgtiNlc3DU/8lZfmqxN3AYD6GGLbl+72rdBpXvcV+whX7mDrREzkPdp2RnmfIiWBg1YbuFSkXduF2JcafJg== +jest-snapshot@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-29.7.0.tgz#c2c574c3f51865da1bb329036778a69bf88a6be5" + integrity sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw== dependencies: "@babel/core" "^7.11.6" "@babel/generator" "^7.7.2" + "@babel/plugin-syntax-jsx" "^7.7.2" "@babel/plugin-syntax-typescript" "^7.7.2" - "@babel/traverse" "^7.7.2" "@babel/types" "^7.3.3" - "@jest/expect-utils" "^28.1.3" - "@jest/transform" "^28.1.3" - "@jest/types" "^28.1.3" - "@types/babel__traverse" "^7.0.6" - "@types/prettier" "^2.1.5" + "@jest/expect-utils" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" babel-preset-current-node-syntax "^1.0.0" chalk "^4.0.0" - expect "^28.1.3" + expect "^29.7.0" graceful-fs "^4.2.9" - jest-diff "^28.1.3" - jest-get-type "^28.0.2" - jest-haste-map "^28.1.3" - jest-matcher-utils "^28.1.3" - jest-message-util "^28.1.3" - jest-util "^28.1.3" + jest-diff "^29.7.0" + jest-get-type "^29.6.3" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" natural-compare "^1.4.0" - pretty-format "^28.1.3" - semver "^7.3.5" + pretty-format "^29.7.0" + semver "^7.5.3" -jest-util@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-28.1.3.tgz#f4f932aa0074f0679943220ff9cbba7e497028b0" - integrity sha512-XdqfpHwpcSRko/C35uLYFM2emRAltIIKZiJ9eAmhjsj0CqZMa0p1ib0R5fWIqGhn1a103DebTbpqIaP1qCQ6tQ== +jest-util@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-29.7.0.tgz#23c2b62bfb22be82b44de98055802ff3710fc0bc" + integrity sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA== dependencies: - "@jest/types" "^28.1.3" + "@jest/types" "^29.6.3" "@types/node" "*" chalk "^4.0.0" ci-info "^3.2.0" graceful-fs "^4.2.9" picomatch "^2.2.3" -jest-validate@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-28.1.3.tgz#e322267fd5e7c64cea4629612c357bbda96229df" - integrity sha512-SZbOGBWEsaTxBGCOpsRWlXlvNkvTkY0XxRfh7zYmvd8uL5Qzyg0CHAXiXKROflh801quA6+/DsT4ODDthOC/OA== +jest-validate@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-29.7.0.tgz#7bf705511c64da591d46b15fce41400d52147d9c" + integrity sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw== dependencies: - "@jest/types" "^28.1.3" + "@jest/types" "^29.6.3" camelcase "^6.2.0" chalk "^4.0.0" - jest-get-type "^28.0.2" + jest-get-type "^29.6.3" leven "^3.1.0" - pretty-format "^28.1.3" + pretty-format "^29.7.0" -jest-watcher@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-28.1.3.tgz#c6023a59ba2255e3b4c57179fc94164b3e73abd4" - integrity sha512-t4qcqj9hze+jviFPUN3YAtAEeFnr/azITXQEMARf5cMwKY2SMBRnCQTXLixTl20OR6mLh9KLMrgVJgJISym+1g== +jest-watcher@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-29.7.0.tgz#7810d30d619c3a62093223ce6bb359ca1b28a2f2" + integrity sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g== dependencies: - "@jest/test-result" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" ansi-escapes "^4.2.1" chalk "^4.0.0" - emittery "^0.10.2" - jest-util "^28.1.3" + emittery "^0.13.1" + jest-util "^29.7.0" string-length "^4.0.1" -jest-worker@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-28.1.3.tgz#7e3c4ce3fa23d1bb6accb169e7f396f98ed4bb98" - integrity sha512-CqRA220YV/6jCo8VWvAt1KKx6eek1VIHMPeLEbpcfSfkEeWyBNppynM/o6q+Wmw+sOhos2ml34wZbSX3G13//g== +jest-worker@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-29.7.0.tgz#acad073acbbaeb7262bd5389e1bcf43e10058d4a" + integrity sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw== dependencies: "@types/node" "*" + jest-util "^29.7.0" merge-stream "^2.0.0" supports-color "^8.0.0" -jest@^28.1.0: - version "28.1.3" - resolved "https://registry.yarnpkg.com/jest/-/jest-28.1.3.tgz#e9c6a7eecdebe3548ca2b18894a50f45b36dfc6b" - integrity sha512-N4GT5on8UkZgH0O5LUavMRV1EDEhNTL0KEfRmDIeZHSV7p2XgLoY9t9VDUgL6o+yfdgYHVxuz81G8oB9VG5uyA== +jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest/-/jest-29.7.0.tgz#994676fc24177f088f1c5e3737f5697204ff2613" + integrity sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw== dependencies: - "@jest/core" "^28.1.3" - "@jest/types" "^28.1.3" + "@jest/core" "^29.7.0" + "@jest/types" "^29.6.3" import-local "^3.0.2" - jest-cli "^28.1.3" - -joycon@^3.0.1: - version "3.1.1" - resolved "https://registry.yarnpkg.com/joycon/-/joycon-3.1.1.tgz#bce8596d6ae808f8b68168f5fc69280996894f03" - integrity sha512-34wB/Y7MW7bzjKRjUKTa46I2Z7eV62Rkhva+KkopW7Qvv/OSWBqvkSY7vusOPrNuZcUG3tApvdVgNB8POj3SPw== + jest-cli "^29.7.0" js-tokens@^4.0.0: version "4.0.0" @@ -1887,7 +2047,7 @@ json5@^2.2.2: resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== -jsonc-parser@^3.0.0, jsonc-parser@^3.2.0: +jsonc-parser@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/jsonc-parser/-/jsonc-parser-3.2.0.tgz#31ff3f4c2b9793f89c67212627c51c6394f88e76" integrity sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w== @@ -1933,12 +2093,12 @@ lunr@^2.3.9: resolved "https://registry.yarnpkg.com/lunr/-/lunr-2.3.9.tgz#18b123142832337dd6e964df1a5a7707b25d35e1" integrity sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow== -magic-string@^0.27.0: - version "0.27.0" - resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.27.0.tgz#e4a3413b4bab6d98d2becffd48b4a257effdbbf3" - integrity sha512-8UnnX2PeRAPZuN12svgR9j7M1uWMovg/CEnIwIG0LFkXSJJe4PdfUGiTGl8V9bsBHFUtfVINcSyYxd7q+kx9fA== +magic-string@^0.30.4: + version "0.30.6" + resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.30.6.tgz#996e21b42f944e45591a68f0905d6a740a12506c" + integrity sha512-n62qCLbPjNjyo+owKtveQxZFZTBm+Ms6YoGD23Wew6Vw337PElFNifQpknPruVRQV57kVShPnLGo9vWxVhpPvA== dependencies: - "@jridgewell/sourcemap-codec" "^1.4.13" + "@jridgewell/sourcemap-codec" "^1.4.15" make-dir@^3.0.0: version "3.1.0" @@ -1954,10 +2114,10 @@ makeerror@1.0.12: dependencies: tmpl "1.0.5" -marked@^4.2.5: - version "4.2.5" - resolved "https://registry.yarnpkg.com/marked/-/marked-4.2.5.tgz#979813dfc1252cc123a79b71b095759a32f42a5d" - integrity sha512-jPueVhumq7idETHkb203WDD4fMA3yV9emQ5vLwop58lu8bTclMghBWcYAavlDqIEMaisADinV1TooIFCfqOsYQ== +marked@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/marked/-/marked-4.3.0.tgz#796362821b019f734054582038b116481b456cf3" + integrity sha512-PRsaiG84bK+AMvxziE/lCFss8juXjNaWzVbN5tXAm4XjeaS9NAHhop+PjQxz2A9h8Q4M/xGmzP8vqNwy6JeK0A== merge-stream@^2.0.0: version "2.0.0" @@ -1996,10 +2156,10 @@ minimatch@^3.0.4, minimatch@^3.1.1: dependencies: brace-expansion "^1.1.7" -minimatch@^5.1.2: - version "5.1.2" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-5.1.2.tgz#0939d7d6f0898acbd1508abe534d1929368a8fff" - integrity sha512-bNH9mmM9qsJ2X4r2Nat1B//1dJVcn3+iBLa3IgqJ7EbGaDNepL9QSHOxN4ng33s52VMMhhIfgCYDk3C4ZmlDAg== +minimatch@^9.0.3: + version "9.0.3" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" + integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== dependencies: brace-expansion "^2.0.1" @@ -2119,7 +2279,7 @@ picocolors@^1.0.0: resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== -picomatch@^2.0.4, picomatch@^2.2.2, picomatch@^2.2.3, picomatch@^2.3.1: +picomatch@^2.0.4, picomatch@^2.2.3, picomatch@^2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== @@ -2136,18 +2296,17 @@ pkg-dir@^4.2.0: dependencies: find-up "^4.0.0" -prettier@^2.6.2: - version "2.8.2" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.2.tgz#c4ea1b5b454d7c4b59966db2e06ed7eec5dfd160" - integrity sha512-BtRV9BcncDyI2tsuS19zzhzoxD8Dh8LiCx7j7tHzrkz8GFXAexeWFdi22mjE1d16dftH2qNaytVxqiRTGlMfpw== +prettier@^3.2.5: + version "3.2.5" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.2.5.tgz#e52bc3090586e824964a8813b09aba6233b28368" + integrity sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A== -pretty-format@^28.1.3: - version "28.1.3" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-28.1.3.tgz#c9fba8cedf99ce50963a11b27d982a9ae90970d5" - integrity sha512-8gFb/To0OmxHR9+ZTb14Df2vNxdGCX8g1xWGUTqUw5TiZvcQf5sHKObd5UcPyLLyowNwDAMTF3XWOG1B6mxl1Q== +pretty-format@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-29.7.0.tgz#ca42c758310f365bfa71a0bda0a807160b776812" + integrity sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ== dependencies: - "@jest/schemas" "^28.1.3" - ansi-regex "^5.0.1" + "@jest/schemas" "^29.6.3" ansi-styles "^5.0.0" react-is "^18.0.0" @@ -2159,6 +2318,16 @@ prompts@^2.0.1: kleur "^3.0.3" sisteransi "^1.0.5" +proxy-from-env@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2" + integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== + +pure-rand@^6.0.0: + version "6.0.4" + resolved "https://registry.yarnpkg.com/pure-rand/-/pure-rand-6.0.4.tgz#50b737f6a925468679bff00ad20eade53f37d5c7" + integrity sha512-LA0Y9kxMYv47GIPJy6MI84fqTd2HmYZI83W/kM/SkKfDlajnZYfmXFTxkbY+xSBPkLJxltMa9hIkmdc29eguMA== + react-is@^18.0.0: version "18.2.0" resolved "https://registry.yarnpkg.com/react-is/-/react-is-18.2.0.tgz#199431eeaaa2e09f86427efbb4f1473edb47609b" @@ -2181,10 +2350,15 @@ resolve-from@^5.0.0: resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" integrity sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw== -resolve.exports@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/resolve.exports/-/resolve.exports-1.1.0.tgz#5ce842b94b05146c0e03076985d1d0e7e48c90c9" - integrity sha512-J1l+Zxxp4XK3LUDZ9m60LRJF/mAe4z6a4xyabPHk7pvK5t35dACV32iIjJDFeWZFfZlO29w6SZ67knR0tHzJtQ== +resolve-pkg-maps@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz#616b3dc2c57056b5588c31cdf4b3d64db133720f" + integrity sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw== + +resolve.exports@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/resolve.exports/-/resolve.exports-2.0.2.tgz#f8c934b8e6a13f539e38b7098e2e36134f01e800" + integrity sha512-X2UW6Nw3n/aMgDVy+0rSqgHlv39WZAlZrXCdnbyEiKm17DSqHX4MmQMaST3FbeWR5FTuRcUwYAziZajji0Y7mg== resolve@^1.20.0: version "1.22.1" @@ -2195,38 +2369,45 @@ resolve@^1.20.0: path-parse "^1.0.7" supports-preserve-symlinks-flag "^1.0.0" -rimraf@^3.0.0: - version "3.0.2" - resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-3.0.2.tgz#f1a5402ba6220ad52cc1282bac1ae3aa49fd061a" - integrity sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA== +rollup-plugin-dts@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/rollup-plugin-dts/-/rollup-plugin-dts-6.1.0.tgz#56e9c5548dac717213c6a4aa9df523faf04f75ae" + integrity sha512-ijSCPICkRMDKDLBK9torss07+8dl9UpY9z1N/zTeA1cIqdzMlpkV3MOOC7zukyvQfDyxa1s3Dl2+DeiP/G6DOw== dependencies: - glob "^7.1.3" + magic-string "^0.30.4" + optionalDependencies: + "@babel/code-frame" "^7.22.13" -rollup-plugin-dts@^5.0.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/rollup-plugin-dts/-/rollup-plugin-dts-5.1.1.tgz#8cc36ab13135b77ef0cfd6107e4af561c5dffd04" - integrity sha512-zpgo52XmnLg8w4k3MScinFHZK1+ro6r7uVe34fJ0Ee8AM45FvgvTuvfWWaRgIpA4pQ1BHJuu2ospncZhkcJVeA== +rollup-plugin-esbuild@^6.1.1: + version "6.1.1" + resolved "https://registry.yarnpkg.com/rollup-plugin-esbuild/-/rollup-plugin-esbuild-6.1.1.tgz#ec1dba647dbe1974f76192c75e907aa6eb636399" + integrity sha512-CehMY9FAqJD5OUaE/Mi1r5z0kNeYxItmRO2zG4Qnv2qWKF09J2lTy5GUzjJR354ZPrLkCj4fiBN41lo8PzBUhw== dependencies: - magic-string "^0.27.0" - optionalDependencies: - "@babel/code-frame" "^7.18.6" + "@rollup/pluginutils" "^5.0.5" + debug "^4.3.4" + es-module-lexer "^1.3.1" + get-tsconfig "^4.7.2" -rollup-plugin-esbuild@^4.10.1: - version "4.10.3" - resolved "https://registry.yarnpkg.com/rollup-plugin-esbuild/-/rollup-plugin-esbuild-4.10.3.tgz#caa66a99b53b21d4939beffc611d76f57191c4cb" - integrity sha512-RILwUCgnCL5vo8vyZ/ZpwcqRuE5KmLizEv6BujBQfgXFZ6ggcS0FiYvQN+gsTJfWCMaU37l0Fosh4eEufyO97Q== - dependencies: - "@rollup/pluginutils" "^4.1.1" - debug "^4.3.3" - es-module-lexer "^0.9.3" - joycon "^3.0.1" - jsonc-parser "^3.0.0" - -rollup@^3.2.2: - version "3.9.1" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-3.9.1.tgz#27501d3d026418765fe379d5620d25954ff2a011" - integrity sha512-GswCYHXftN8ZKGVgQhTFUJB/NBXxrRGgO2NCy6E8s1rwEJ4Q9/VttNqcYfEvx4dTo4j58YqdC3OVztPzlKSX8w== +rollup@^4.9.6: + version "4.9.6" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-4.9.6.tgz#4515facb0318ecca254a2ee1315e22e09efc50a0" + integrity sha512-05lzkCS2uASX0CiLFybYfVkwNbKZG5NFQ6Go0VWyogFTXXbR039UVsegViTntkk4OglHBdF54ccApXRRuXRbsg== + dependencies: + "@types/estree" "1.0.5" optionalDependencies: + "@rollup/rollup-android-arm-eabi" "4.9.6" + "@rollup/rollup-android-arm64" "4.9.6" + "@rollup/rollup-darwin-arm64" "4.9.6" + "@rollup/rollup-darwin-x64" "4.9.6" + "@rollup/rollup-linux-arm-gnueabihf" "4.9.6" + "@rollup/rollup-linux-arm64-gnu" "4.9.6" + "@rollup/rollup-linux-arm64-musl" "4.9.6" + "@rollup/rollup-linux-riscv64-gnu" "4.9.6" + "@rollup/rollup-linux-x64-gnu" "4.9.6" + "@rollup/rollup-linux-x64-musl" "4.9.6" + "@rollup/rollup-win32-arm64-msvc" "4.9.6" + "@rollup/rollup-win32-ia32-msvc" "4.9.6" + "@rollup/rollup-win32-x64-msvc" "4.9.6" fsevents "~2.3.2" semver@^6.0.0, semver@^6.3.0: @@ -2234,10 +2415,10 @@ semver@^6.0.0, semver@^6.3.0: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== -semver@^7.3.5: - version "7.3.8" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.8.tgz#07a78feafb3f7b32347d725e33de7e2a2df67798" - integrity sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A== +semver@^7.5.3, semver@^7.5.4: + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: lru-cache "^6.0.0" @@ -2253,11 +2434,12 @@ shebang-regex@^3.0.0: resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== -shiki@^0.12.1: - version "0.12.1" - resolved "https://registry.yarnpkg.com/shiki/-/shiki-0.12.1.tgz#26fce51da12d055f479a091a5307470786f300cd" - integrity sha512-aieaV1m349rZINEBkjxh2QbBvFFQOlgqYTNtCal82hHj4dDZ76oMlQIX+C7ryerBTDiga3e5NfH6smjdJ02BbQ== +shiki@^0.14.7: + version "0.14.7" + resolved "https://registry.yarnpkg.com/shiki/-/shiki-0.14.7.tgz#c3c9e1853e9737845f1d2ef81b31bcfb07056d4e" + integrity sha512-dNPAPrxSc87ua2sKJ3H5dQ/6ZaY8RNnaAqK+t0eG7p0Soi2ydiqbGOTaZCqaYvA/uZYfS1LJnemt3Q+mSfcPCg== dependencies: + ansi-sequence-parser "^1.1.0" jsonc-parser "^3.2.0" vscode-oniguruma "^1.7.0" vscode-textmate "^8.0.0" @@ -2348,7 +2530,7 @@ supports-color@^5.3.0: dependencies: has-flag "^3.0.0" -supports-color@^7.0.0, supports-color@^7.1.0: +supports-color@^7.1.0: version "7.2.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== @@ -2362,27 +2544,11 @@ supports-color@^8.0.0: dependencies: has-flag "^4.0.0" -supports-hyperlinks@^2.0.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/supports-hyperlinks/-/supports-hyperlinks-2.3.0.tgz#3943544347c1ff90b15effb03fc14ae45ec10624" - integrity sha512-RpsAZlpWcDwOPQA22aCH4J0t7L8JmAvsCxfOSEwm7cQs3LshN36QaTkwd70DnBOXDWGssw2eUoc8CaRWT0XunA== - dependencies: - has-flag "^4.0.0" - supports-color "^7.0.0" - supports-preserve-symlinks-flag@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== -terminal-link@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/terminal-link/-/terminal-link-2.1.1.tgz#14a64a27ab3c0df933ea546fba55f2d078edc994" - integrity sha512-un0FmiRUQNr5PJqy9kP7c40F5BOfpGlYTrxonDChEZB7pzZxRNp/bt+ymiy9/npwXya9KH99nJ/GXFIiUkYGFQ== - dependencies: - ansi-escapes "^4.2.1" - supports-hyperlinks "^2.0.0" - test-exclude@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-6.0.0.tgz#04a8698661d805ea6fa293b6cb9e63ac044ef15e" @@ -2424,20 +2590,20 @@ type-fest@^0.21.3: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== -typedoc@^0.23.17: - version "0.23.24" - resolved "https://registry.yarnpkg.com/typedoc/-/typedoc-0.23.24.tgz#01cf32c09f2c19362e72a9ce1552d6e5b48c4fef" - integrity sha512-bfmy8lNQh+WrPYcJbtjQ6JEEsVl/ce1ZIXyXhyW+a1vFrjO39t6J8sL/d6FfAGrJTc7McCXgk9AanYBSNvLdIA== +typedoc@^0.25.7: + version "0.25.7" + resolved "https://registry.yarnpkg.com/typedoc/-/typedoc-0.25.7.tgz#11e3f527ca80ca3c029cb8e15f362e6d9f715e25" + integrity sha512-m6A6JjQRg39p2ZVRIN3NKXgrN8vzlHhOS+r9ymUYtcUP/TIQPvWSq7YgE5ZjASfv5Vd5BW5xrir6Gm2XNNcOow== dependencies: lunr "^2.3.9" - marked "^4.2.5" - minimatch "^5.1.2" - shiki "^0.12.1" + marked "^4.3.0" + minimatch "^9.0.3" + shiki "^0.14.7" -typescript@^4.8.4: - version "4.9.4" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.9.4.tgz#a2a3d2756c079abda241d75f149df9d561091e78" - integrity sha512-Uz+dTXYzxXXbsFpM86Wh3dKCxrQqUcVMxwU54orwlJjOpO3ao8L7j5lH+dWfTwgCwIuM9GQ2kvVotzYJMXTBZg== +typescript@^5.3.3: + version "5.3.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.3.3.tgz#b3ce6ba258e72e6305ba66f5c9b452aaee3ffe37" + integrity sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw== update-browserslist-db@^1.0.9: version "1.0.10" @@ -2494,7 +2660,7 @@ wrappy@1: resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== -write-file-atomic@^4.0.1: +write-file-atomic@^4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-4.0.2.tgz#a9df01ae5b77858a027fd2e80768ee433555fcfd" integrity sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg==