Skip to content

bencevans/brutime

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

brutime

Node.js module for scraping data from Brunel University's timetabling portal.

Install

$ yarn add brutime@bencevans/brutime

# or

$ npm install --save github:bencevans/brutime

Usage

Import BruTime

import BruTime from "brutime";

Create an Instance

const bruTime = new BruTime();

// Creates an instance of puppeteer/chromium
await bruTime.init();

// You can also pass in a puppeteer options object for example the following
// to show the browser window and enable devtools.
await bruTime.init({
  headless: false,
  devtools: true,
});

Login

  • Students: Should use your Student ID and network password.
  • Staff: Should use your network username and password.

Both the student id/staff login and password should be strings.

try {
  await bruTime.login(studentId, password);
} catch (err) {
  console.error(err);
}

Course Timetable

Get Course Timetable Options

TODO: Look in example.js in the meantime.

Get Course Timetable

TODO: Look in example.js in the meantime.

Testing

$  export BRUNEL_ID=YOUR_STUDENT_ID
$  export BRUNEL_PASSWORD=YOUR_STUDENT_PASSWORD
$ npm test

Related

  • bencevans/parse-weeks - Parse a comma separated list of ranges and numbers into an array of all numbers covered.
  • bencevans/brucal - (deprecated) - iCal Web Service for Brunel Timetables. Automatically add your Brunel timetable to Google Calendar, GNOME Calendar or any other calendar application providing support for Web iCal.
  • ... Add Your Project

Licence

MIT © Ben Evans

About

🗓️ Scrape timetabling info for Brunel Uni students.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors