$ npm install avesis-api
const { getDocuments } = require("avesis-api");
// Example URL: https://avesis.aaa.edu.tr/bbb
const options = {
university: "aaa", // required, University name in URL
teacher: "bbb", // required, Teacher name in URL required
limit: 1, // optional, Number of documents to return from last. default = Infinity
html: false, // optional, return description as HTML string. default = false
};
getDocuments(options).then(function (response) {
console.log(response);
});
{
teacher: {
name: 'Asst. Prof. Aaa',
img: 'https://avesis.aaa.edu.tr/user/image/123123'
},
list: [
{
title: "Last Announcement",
type: "Duyuru",
date: "23.02.2022",
description: 'Description',
},
{
title: "Announcement with File",
type: "Ders Notu",
date: "20.02.2022",
description: "Description\nwith\nmultiline",
link: "https://avesis.aaa.edu.tr/resume/downloadfile/bbb?key=1231231-1231-1231-1231-123123123123",
filename: "slide.pdf",
fileExt: "pdf",
locked: true,
},
]
}
Copyright (c) 2022 Code a Man