Skip to content
This repository has been archived by the owner on Oct 2, 2021. It is now read-only.
/ jsmagister Public archive

A high level api making it easier to perform various tasks on Magister.

License

Notifications You must be signed in to change notification settings

kiip1/jsmagister

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jsmagister

A high level api making it easier to perform various tasks on Magister.

Getting started

  1. Install the package.
npm i jsmagister
  1. Place the following code somewhere.
const magister = require('jsmagister');

(async () => {
  // Log in to Magister. 
  // Note: The school is the subdomain you will be on once you're logged in to Magister.
  await magister.login('<username>', '<password>', '<school>');

  // Wait for the page to load.
  await magister.waitForPageLoad();

  // Navigate to the 'cijfers' tab.
  await magister.navigate('cijfers');

  // Wait for page content to load.
  await magister.waitForTimeout(1000);

  // Take a screenshot and save it.
  await magister.takeScreenShot('grades.png');

  // Close magister.
  await magister.close();
})();
  1. Run the code and if everything works like intended, a screenshot of the last grades should be saved.

About

A high level api making it easier to perform various tasks on Magister.

Topics

Resources

License

Stars

Watchers

Forks

Packages