This is a library of scrapers for various University of Toronto websites.
- Requirements
- Installation
- Usage
- Library Reference
pip install uoftscrapers
import uoftscrapers
# Example: scrape http://map.utoronto.ca building data to ./some/path
uoftscrapers.Buildings.scrape('./some/path')
# Example: scrape http://coursefinder.utoronto.ca to current working directory
uoftscrapers.Courses.scrape()
uoftscrapers.Courses
http://coursefinder.utoronto.ca
{
"id": String,
"code": String,
"name": String,
"description": String,
"division": String,
"department": String,
"prerequisites": String,
"exclusions": String,
"level": Number,
"campus": String,
"term": String,
"breadths": [Number],
"meeting_sections": [{
"code": String,
"instructors": [String],
"times": [{
"day": String,
"start": Number,
"end": Number,
"duration": Number,
"location": String
}],
"size": Number,
"enrolment": Number
}]
}
uoftscrapers.Buildings
{
"id": String,
"code": String,
"name": String,
"short_name": String,
"campus": String,
"address": {
"street": String,
"city": String,
"province": String,
"country": String,
"postal": String
},
"lat": Number,
"lng": Number,
"polygon": [
[Number, Number]
]
}
uoftscrapers.Textbooks
{
"id": String,
"isbn": String,
"title": String,
"edition": Number,
"author": String,
"image": String,
"price": Number,
"url": String,
"courses":[{
"id": String,
"code": String,
"requirement": String,
"meeting_sections":[{
"code": String,
"instructors": [String]
}]
}]
}
uoftscrapers.Food
{
"id": String,
"building_id": String,
"name": String,
"short_name": String,
"description": String,
"url": String,
"tags": [String],
"image": String,
"campus": String,
"lat": Number,
"lng": Number,
"address": String,
"hours": {
"sunday": {
"closed": Boolean,
"open": Number,
"close": Number
},
"monday": {
"closed": Boolean,
"open": Number,
"close": Number
}
"tuesday": {
"closed": Boolean,
"open": Number,
"close": Number
},
"wednesday": {
"closed": Boolean,
"open": Number,
"close": Number
},
"thursday": {
"closed": Boolean,
"open": Number,
"close": Number
},
"friday": {
"closed": Boolean,
"open": Number,
"close": Number
},
"saturday": {
"closed": Boolean,
"open": Number,
"close": Number
}
}
}
uoftscrapers.Calendar
Not implemented.
uoftscrapers.UTSGCalendar
http://www.artsandscience.utoronto.ca/ofr/calendar/
Refer to Calendar
uoftscrapers.UTMCalendar
https://student.utm.utoronto.ca/calendar/calendar.pl
Refer to Calendar
uoftscrapers.UTSCCalendar
http://www.utsc.utoronto.ca/~registrar/calendars/calendar/index.html
Refer to Calendar
uoftscrapers.Timetable
{
"id": String,
"code": String,
"name": String,
"description": String,
"division": String,
"department": String,
"prerequisites": String,
"exclusions": String,
"level": Number,
"campus": String,
"term": String,
"breadths": [Number],
"meeting_sections": [{
"code": String,
"instructors": [String],
"times": [{
"day": String,
"start": Number,
"end": Number,
"duration": Number,
"location": String
}],
"size": Number,
"enrolment": Number
}]
}
uoftscrapers.UTSGTimetable
https://timetable.iit.artsci.utoronto.ca
Refer to Timetable
uoftscrapers.UTMTimetable
https://student.utm.utoronto.ca/timetable
Refer to Timetable
uoftscrapers.UTSCTimetable
http://www.utsc.utoronto.ca/~registrar/scheduling/timetable
Refer to Timetable
uoftscrapers.Exams
{
"id": String,
"course_id": String,
"course_code": String
"period": String,
"date": String,
"start_time": Number,
"end_time": Number,
"duration": Number,
"sections": [{
"lecture_code": String,
"exam_section": String,
"location": String
}]
}
uoftscrapers.UTSGExams
http://www.artsci.utoronto.ca/current/exams
Refer to Exams
uoftscrapers.UTMExams
https://student.utm.utoronto.ca/examschedule/finalexams.php
Refer to Exams
uoftscrapers.UTSCExams
http://www.utsc.utoronto.ca/registrar/examination-schedule
Refer to Exams
uoftscrapers.Athletics
{
"date": String,
"events":[{
"title": String,
"campus": String,
"location": String,
"building_id": String,
"start_time": Number,
"end_time": Number,
"duration": Number
}]
}
uoftscrapers.UTSGAthletics
Not yet implemented
Refer to Athletics
uoftscrapers.UTMAthletics
http://www.utm.utoronto.ca/athletics/schedule/month/
Refer to Athletics
uoftscrapers.UTSCAthletics
http://www.utsc.utoronto.ca/athletics/calendar-node-field-date-time/month/
Refer to Athletics
uoftscrapers.Parking
{
"id": String,
"title": String,
"building_id": String,
"campus": String,
"type": String,
"description": String,
"lat": Number,
"lng": Number,
"address": String
}
uoftscrapers.Shuttles
https://m.utm.utoronto.ca/shuttle.php
{
"date": String,
"routes": [{
"id": String,
"name": String,
"stops": [{
"location": String,
"building_id": String,
"times": [{
"time": Number,
"rush_hour": Boolean,
"no_overload": Boolean
}]
}]
}]
}
uoftscrapers.Events
https://www.events.utoronto.ca/
{
id: String,
title: String,
start_date: String
end_date: String,
start_time: Number,
end_time: Number,
duration: Number,
url: String,
description: String,
admission_price: String,
campus: String,
location: String,
audiences: [String],
}
uoftscrapers.Libraries
https://onesearch.library.utoronto.ca/
{
id: String,
name: String,
image: String,
website: String,
address: String,
phone: String,
about: String,
collection_strengths: String,
access: String,
hours: {
sunday: {
closed: Boolean,
open: String,
close: String,
},
monday: {
closed: Boolean,
open: Number,
close: Number,
},
tuesday: {
closed: Boolean,
open: Number,
close: Number,
},
wednesday: {
closed: Boolean,
open: Number,
close: Number,
},
thursday: {
closed: Boolean,
open: Number,
close: Number,
},
friday: {
closed: Boolean,
open: Number,
close: Number,
},
saturday: {
closed: Boolean,
open: Number,
close: Number,
}
}
}
uoftscrapers.Dates
{
"date": String,
"events": [{
"end_date": String,
"session": String,
"campus": String,
"description": String
}]
}
uoftscrapers.UTSGDates
http://www.artsci.utoronto.ca/current/course/timetable/ http://www.undergrad.engineering.utoronto.ca/About/Dates_Deadlines.htm
Refer to Exams
uoftscrapers.UTMDates
http://m.utm.utoronto.ca/importantDates.php
Refer to Exams