{"id":17551581,"url":"https://github.com/mati365/librus-api","last_synced_at":"2025-04-09T16:01:54.685Z","repository":{"id":45424394,"uuid":"47748377","full_name":"Mati365/librus-api","owner":"Mati365","description":"Unofficial advanced node.js Librus scraping API(http://synergia.librus.pl/)","archived":false,"fork":false,"pushed_at":"2025-02-06T10:09:35.000Z","size":128,"stargazers_count":131,"open_issues_count":11,"forks_count":29,"subscribers_count":14,"default_branch":"master","last_synced_at":"2025-04-09T16:01:07.853Z","etag":null,"topics":["dziennik","librus","librus-api","librus-synergia","scrapping","szkola"],"latest_commit_sha":null,"homepage":"http://synergia.librus.pl/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Mati365.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-12-10T08:31:08.000Z","updated_at":"2025-04-03T05:25:27.000Z","dependencies_parsed_at":"2025-04-02T15:08:37.923Z","dependency_job_id":"c3a04b1f-b10c-4a1b-85ce-43da52f0390c","html_url":"https://github.com/Mati365/librus-api","commit_stats":{"total_commits":69,"total_committers":16,"mean_commits":4.3125,"dds":0.4492753623188406,"last_synced_commit":"0fdc25717eb2e0a0fa53c1d1a1d4188f0e08c18f"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Flibrus-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Flibrus-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Flibrus-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Mati365%2Flibrus-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Mati365","download_url":"https://codeload.github.com/Mati365/librus-api/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248065290,"owners_count":21041871,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dziennik","librus","librus-api","librus-synergia","scrapping","szkola"],"created_at":"2024-10-21T04:46:46.523Z","updated_at":"2025-04-09T16:01:54.651Z","avatar_url":"https://github.com/Mati365.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# librus-api\n\n[![npm](https://img.shields.io/npm/v/librus-api.svg?style=flat)](https://www.npmjs.com/package/librus-api)\n[![License](https://img.shields.io/badge/license-MIT-green.svg?style=flat)](http://opensource.org/licenses/MIT)\n\nOtwartoźródłowy klient HTTP parsujący odpowiedzi HTML serwera dziennika elektronicznego Librus / Synergia. Paczka nie jest oficjalnym produktem Synergia.  \n\n## Instalacja\n\n```\nnpm install librus-api\n```\n\n## Usage\n\n```javascript\n\"use strict\";\nconst Librus = require(\"librus-api\");\n\nlet client = new Librus();\nclient.authorize(\"login\", \"pass\").then(function () {\n  // Send message to User 648158\n  client.inbox.sendMessage(648158, \"title\", \"body\").then(\n    () =\u003e {\n      /** sucess */\n    },\n    () =\u003e {\n      /** fail **/\n    }\n  );\n\n  // Remove message with id 4534535\n  client.inbox.removeMessage(4534535).then(\n    () =\u003e {\n      /** sucess */\n    },\n    () =\u003e {\n      /** fail **/\n    }\n  );\n\n  // List receivers\n  client.inbox.listReceivers(\"nauczyciel\").then((data) =\u003e {});\n\n  // List announcements\n  client.inbox.listAnnouncements().then((data) =\u003e {});\n\n  // List all e-mails in folder(5) in page(2)\n  client.inbox.listInbox(5).then((data) =\u003e {});\n\n  // Get message with id 2133726 in folder 6\n  client.inbox.getMessage(6, 2133726).then((data) =\u003e {});\n\n  // Get attachments from message with id 181186 in folder 5\n  client.inbox.getMessage(5, 181186).then((data) =\u003e {\n    for (let f of data.files) {\n      client.inbox\n        .getFile(f.path)\n        .then((response) =\u003e response.pipe(fs.createWriteStream(f.name)));\n    }\n  });\n\n  // List all subjects\n  client.homework.listSubjects().then((data) =\u003e {});\n\n  // List subject homeworks, -1||undefined all\n  client.homework.listHomework(24374).then((list) =\u003e {});\n\n  // Download homework description\n  client.homework.getHomework(257478).then((data) =\u003e {});\n\n  // Get all absences\n  client.absence.getAbsences().then((data) =\u003e {});\n\n  // Get info about absence\n  client.absence.getAbsence(5068489).then((data) =\u003e {});\n\n  // Get timetable\n  client.calendar.getTimetable().then((data) =\u003e {});\n\n  // Get calendar\n  client.calendar.getCalendar().then((data) =\u003e {});\n\n  // Get event\n  client.calendar.getEvent(4242342).then((data) =\u003e {});\n\n  // Get grades\n  client.info.getGrades().then((data) =\u003e {});\n\n  // Get grade\n  client.info.getGrade(23424234).then((data) =\u003e {});\n\n  // Get scoring grade\n  client.info.getPointGrade(234242234).then((data) =\u003e {});\n\n  // Get name, surname and other account info\n  client.info.getAccountInfo();\n\n  // Get lucky number\n  client.info.getLuckyNumber().then((data) =\u003e {});\n\n  // Get notifications\n  client.info.getNotifications().then((data) =\u003e {});\n});\n```\n\n## Licencja\n\nThe MIT License (MIT)\n\nCopyright (c) 2025 Mateusz Bagiński\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmati365%2Flibrus-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmati365%2Flibrus-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmati365%2Flibrus-api/lists"}