npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

icarus-sef-parser

v2.6.0

Published

[![GitHub version](https://badge.fury.io/gh/rambou%2Ficarus-sef-parser.svg)](https://badge.fury.io/gh/rambou%2Ficarus-sef-parser) [![npm version](https://badge.fury.io/js/icarus-sef-parser.svg)](https://badge.fury.io/js/icarus-sef-parser) [![npm](https://

Downloads

11

Readme

Icarus-Sef parser

GitHub version npm version npm npm GitHub issues Libraries.io for GitHub Known Vulnerabilities GitHub stars GitHub forks GitHub issues Build StatusCoverage Status codecov Code Climate Issue Count Twitter Dependency Status devDependency Status semantic-release

A simple module to parse https://icarus-icsd.aegean.gr and https://sef.math.aegean.gr websites to get students marks or send requests to each department's office. This currently only works with icarus and sef. In the future i'm gonna add functionality for all the departments of the Aegean University.

NPM

Install

npm install --save icarus-sef-parser

How to use

Create a new object of parser and give username and password to initialize.

require('icarus-sef-parser');

var parser = new auth(USERNAME, PASSWORD);

Below is an example of how to use some of the api functionality.

parser.printStudent();
console.log(parser.getSessionInfo());
console.log(parser.getDepartmentName());

// authenticate and test the other api
parser.authenticate(function (error, response) {
    console.log(response);
    console.log((response.authenticated) ? "Authenticated" : "Authentication Failed.");

    parser.getUserDetails(response.document, response.cookie, function (err, data) {
        if (err) {
            return console.log(err.message)
        }
        console.log(data)
    });
    parser.getSucceededGrades(response.document, function (err, value) {
        if (err) {
            return console.log(err.message)
        }
        console.log(value)
    });
    parser.getAnalyticGrades(response.document, function (err, value) {
        if (err) {
            return console.log(err.message)
        }
        console.log(value)
    });
    parser.getExamGrades(response.document, function (err, value) {
        if (err) {
            return console.log(err.message)
        }
        console.log(value)
    });
    parser.getIntercalaryExamGrades(response.document, function (err, value) {
        if (err) {
            return console.log(err.message)
        }
        console.log(value)
    });
    parser.getCurriculumToDeclare(response.cookie, function (err, value) {
            if (err) {
                console.log('error:', err.message); // Print the error if one occurred
            }
    
            var formData = [];
            for (var i in value) {
                formData.push(value[i].id);
            }
    
            // call postCurriculumToDeclare(formData,  (err, value) {....}) to post them
        });
    parser.postCurriculumToDeclare(['321-2450',
        '331-2205',
        '321-4120',
        '311-0116',
        '311-0238',
        '311-0327',
        '311-0437',
        '331-2708'], response.cookie, function (err, value) {
        if (err) {
            console.log('error:', err.message); // Print the error if one occurred
        }

        console.log(value);
    });
    parser.postRequestToDepartment({
        id: 'test',
        surname: 'test',
        name: 'test',
        father: 'test',
        semester: 'test',
        address2: 'test',
        address: 'test',
        phone: 'test',
        emergency: 'test',
        method: 'test',
        sent_address: 'test',
        other: 'test',
        requests: [
                    {name: 'Βεβαίωση Σπουδών', amount: '1'},
                    {name: 'Βεβαίωση Διαγραφής', amount: '3'},
                    {name: 'Αλλο', amount: '9', what: 'κάτι άλλο'}
                ]
    }, response.cookie, function (err, value) {
        if (err) {
            console.log('error:', err.message); // Print the error if one occurred
        }

        console.log(value);
    })
});

Coding Activity

wakatime