About the API
What is it for?
The Rutgers Schedule of Classes API gets the job done, but if you don't know what classes you are looking for you cant easily use it. There also is little to no documentation of the usage of it (not that it is very difficult). A sample API request can be made from Rutgers by pulling a web page. The request URL for Computer Science courses might look something like
and you get a list back of the current courses. Its the most up to date data and matches what is shown in the Rutgers WebReg and Course Planner. This API goes a little more in-depth with functionality. With the University API you get one JSON object with all the info you could need about the classes in a department. There is a down side to this Its a lot of data. The new API follows the premise that while I can give you all of it you might just be looking for a info on a specific course. This API is not to be used for course snipers as it is only updated once a day. Plus its not going to be as fast even if it was updated often. An example use of this api would be a class scheduler.
This api is built with 5 pages that take requests.
- Subject Names
- Course Names
Each page has an expected format of requests. All requests are made using GET with parameters.
The subjects API provides the full list of subject codes. Example usage would be the first step in selecting classes to add to a schedule planner. Pulling this page to provide a list of Subjects that the course could be in. The subjects API has the base address http://ru.richgerdes.courses/api/subjects.php. Any request to this page will return a list of all of the subjects that currently have classes in them. The only way to request this page is:
The second part of the Subjects API is the subject name page. This page can be used to get the name of the subject based on a given code.
The Courses API lists all of the courses in a given subject. This request does not return section information just the list of course codes for all of the classes. An example usage is:
Once again along with the list of courses you can convert course codes in to names using a second page.
The final section of the API provides section info for a course. By passing the subject and course to the page you get back the section info. Returned the section number, index, course title, and the original JSON from the university api including meeting times and locations.