Aditi’s Status Report for 10.28.23

This week, I worked on the Canvas scraping software, and finished it completely. It was pretty difficult to figure out everything about using the API, so this is the work I did for the bulk of the week. First, I had to create a new Canvas instructor account in order to create new test classes, and then I had to get the API key associated with the account. Then, I had to perform the following steps in the code:

1. Make a request to Canvas for the most recent file under the “Lectures” module, if such a module exists. I sent Canvas my API token and authorization key in the header for the security handshake.

2. Canvas sent me a JSON file of metadata about the most recent file. This was the most confusing part of the API — with no warning, when making a request for a specific file, the API will send back the JSON of metadata rather than the file itself, but the name of the JSON will be exactly identical to the name of the file.

3. Within this JSON, there is a value called “html_url,” which is the actual location of the file we need to extract. So, we must make another request to that url in order to retrieve the file.

Next week, I plan on modifying the app to make a settings screen, where they can set the classes they are taking, and the class code associated with each one, which also means I need to add functionality to support extracting information from multiple classes. I also plan to refine the UI to make it more accessible using the WCAG 2 guidelines.

I am still ahead of schedule, and am on track to finishing the app within the next couple of weeks. The final thing I need to do after next week will be integrating the button press/camera with the Flask server, and my subsystem will be complete.

Leave a Reply

Your email address will not be published. Required fields are marked *