Skip navigation
All Places > Canvas Admins > Blog > 2015 > April

Canvas Admins

April 2015 Previous month Next month

I'm sure over 90% of people know some of these tricks but I always like to share stuff just in case someone doesn't know some ways to get things back in Canvas.


Recovering things in a course

As a former Blackabord admin I always got that cold feeling in my stomach when someone would call me to tell me they deleted a bunch of things out of their course by accident. Unless it was backed up I knew it would be an uphill battle to get it back. In Canvas however that is not as big of a deal.

Before these steps are laid out, please keep in mind that every Account Rep and tech support person I spoke to about this specifically told me that this is NOT 100%. So you may still be out of luck. Please keep that in mind if you try this and it doesn't work. If that happens a call to Canvas Support might be your best bet.


Step 1 -  Go the course in question.


Step 2 - Check the URL you should see something like this (your institution's name should be there)

Step 2.png

Step 3 - At the end of the URL, type /undelete

Step 3.png

Step 4 - Once you hit enter, you'll see a list of restorable stuff.



What to do if we're a Banner School and we have a course in our feed but it doesn't show up in Canvas

I'm currently working at a Banner School. Our integration has a combo of manual and automatic exports. We also currently cross list outside of Canvas so the cross listed courses with enrollments feed into Canvas rather than using Canvas to cross list (this is likely going to change). At any rate on occasion we run into this problem where we have an uncrosslisted section become cross listed. The uncrosslisted course was already deleted in Canvas but the new course will not show up. For a while this was quite puzzling but we have found a pretty easy solution. I believe this is because when the old course is deleted it marks anything with that information as deleted making the cross listed course automatically become deleted.

SO to fix.


Step 1 - Go in to the Admin Section/Reports


Step 2 - Run a Provisioning report for Courses within the given term.


You'll end up with a huge CSV, but the first column will contain the Canvas course ID which is a specific number for each course (You can find this ID in the URL,


Step 3 - In our case we can find both the uncrosslisted and the crosslisted course. In this case we need the crosslisted ID.


Step 4 - Canvas was awesome enough to add a course restore in the Admin Tools section. Just click there and paste that ID in there. Now you can pull the course back and you're all set.



This is also applicable to people if they have duplicate SIS id's or were disabled for some reason in the Banner feed. The only difference is it can take some editing of IDs and a SIS import to fix.


Post'Em for Canvas@UD

Posted by BKINNEY@UDEL.EDU Apr 15, 2015

At the University of Delaware, we support two Learning Management Systems. We have been running Sakai ever since Blackboard bought out WebCT, and now we have added Canvas. Migration to Canvas is entirely optional. We really are not pressuring people to choose Canvas over Sakai, so no one needs to give up what they know. On the other hand, we like to remove barriers, and one tool that Canvas has no counterpart for is the Sakai Post'Em tool.


Post'Em itself is a work-around for anyone dissatisfied with the Sakai gradebook. It is a very simple tool, which allows instructors to upload the contents of their Excel gradebook spreadsheet, and have individual rows presented securely to students. This by-passes any and all limitations with the gradebook itself. You can take advantage of the full power of Excel (or any other program exportable to .csv) in order to calculate grades. Some instructors on our campus who are otherwise ready and willing to try something new were hesitant to make the move to Canvas without having a Post'Em equivalent, so we took advantage of the Canvas LTI and API to build one.


Recently, we have received a request from Indiana University to share the code, which we have done, and no doubt they are by now well on their way to making it better.


This is not necessarily the best place to try to make a record of what has been done, but I did promise to do something on the new Canvas Community site to get some conversation going around the Post'Em effort. Since I wanted to figure out how blogging works on this site, I thought I'd just throw something out there and see what happens. I apologize if this is the wrong approach to take.


Due to Financial Aid Federal Regulations our College must show the last date of attendance for dropped students. For online students we define attendance as the last date the student submitted any type of assignment in Canvas. The Business office and Financial Aid office need this information but due to the difficulty in obtaining the information from Canvas Online Learning staff was tasked with getting the information. Online Learning staff found it very time consuming to manually locate this information in Canvas, so they worked with the College’s Internet Systems Specialist to create a better way to quickly  and easily access this information. A web interface allows you to select the student and course. “Course Information” image is an example of what shows up once you select a student from the web interface.

The submission report (Example shown below) shows every assignment in the course, whether the student submitted the assignment, and the date of submission if an assignment was submitted or the due date if it wasn’t submitted.

Submission information is now so easy to access that the Business and Financial Aid offices are able to run their own reports, saving Online Learning a lot of time and energy.


What was the need for the submission report?

  • The College needed access to a list of every assignment a student submitted in the course and the date the assignment was submitted.
  • Accessing submission information, including when the assignment was submitted, in Canvas is time consuming and requires multiple clicks for every assignment the student submitted.


Fetch the Data

There are three or four API calls that are used to obtain the report.

  1. Obtain the Canvas User ID and (recommended) Canvas Course ID for the student and course if you don't already have it cached locally. I recommend storing them in your database to speed up processing. If you don't store these locally, use the Enrollments API to obtain both the course ID and student ID in one call. We cache both of these locally, so this step isn't required.
    1. If no data is returned, stop, because you won't be able to do any processing.
    2. If data is returned, then loop through it until you match the SIS ID. Then make note of the Canvas User ID and Canvas Course ID.
  2. Get the student's activity using the Analytics API. This specific call is to the Get user-in-a-course-level assignment data endpoint. This involves the Student ID, which is SISable, but it does not return the Canvas User ID with the data, so you will need to have the Canvas User ID from somewhere else.
    1. If this comes back empty, then stop because there is nothing to process. This could happen when there is a problem getting information back from the API.
    2. If a "status" field exists, make sure it's not "not found". This means there is no information for that student in that course. It also happens when a student has been deleted from a course. Stop processing.
    3. Check to see if an "errors" field exists. If it does, there was a problem. However, this can also happen when a student has been deleted from the course. Stop processing.
  3. Get a list of assignments for the course using the Assignments API. This is done through the List Assignments endpoint. This is necessary so we know what assignments are possible in the class.
  4. Get a list of submissions for that student using the Submissions API. This is done through the List submissions for multiple assignments endpoint. This API calls takes an extra parameter called 'student_ids[]', which contains a list of students IDs -- in this case, just the one. However, this needs to be the Canvas ID for the student, not the SIS ID, which the reason for obtaining that information in step 1.

Process the Data

  1. Assuming that the activities from the analytics call (step 2) doesn't contain a 'status' or 'errors' field, iterate through all of the activities. Each activity is an entry in an array. I generate a sequential integer key for each value so that I can maintain the order. You cannot sort by date because not all assignments have been submitted.
  2. Obtain the date the activity occurred and incorporate this into the key. The first part of the key is the submitted_at date, if it exists, and the second part is the sequence number of the record.
    1. If there is no "submission" field, then the key looks like "-001" or "-002".
    2. If there is a "submission.submitted_at" date, then the key will be a ISO 8061 formatted timestamp with the sequence number appended at the end.
  3. For each activity, store the assignment title, assignment_id, submission date*, score received*, and possible points. (* may not exist)
  4. If there is assignment data (step 3 of the fetch data phase), then loop through them trying to find the one that matches the assignment_id. If you find it, then save the possible submission types into the data structure started in step 3.
  5. If there is submission data (step 4 of the fetch data phase), the loop through them trying to find the one that matches the assignment and record the submission type in the data structure created in step 3.
  6. Check to see if the student has submitted the assignment. Default to "no".
    1. If there is a submission_type (found in step 5) for the assignment submission, then it's a grade due to a submission, not just a grade the faculty put into the system (like a 0 for a missing grade).
    2. If there is no submission_type (missing from step 5) then check to see if "none" is one of the allowed submission types (from step 4).
      1. If "none" is allowed and there the possible points is positive, then look at the score received. If the score greater than 0, then count that as a submission. otherwise mark it as "Unknown" since we don't know whether the 0 came from failing miserably on the assignment or from not completing the assignment at all.
      2. If "none" is allowed and the possible points is 0, then just record it as "Ungraded"
    3. Add the submission summary (step a or b) to the data structure.
    4. If the submission summary is "No", then make the date to put in the key as the due date of the assignment and also record this in the data structure so we can distinguish "due at" from when it was submitted.
  7. Save the data structure into an array, keyed by the date/sequence key.
  8. Repeat steps 1-7 for all activity from the analytics report.
  9. Reverse sort the data based on the key, which is composed of a timestamp and a sequential number. This puts all the the submitted stuff at the top with the newest first and all the unsubmitted assignments at the bottom. This allows the person reading the report to see right away what the student did last.
  10. Generate the report.

API Calls


  1. Enrollments: List Course Enrollments (not needed if you cache Canvas IDs locally)
    GET /api/v1/courses/:course_id/enrollments
  2. Analytics: Get user-in-a-course-level assignment data
    GET /api/v1/courses/:course_id/analytics/users/:student_id/assignments
  3. Assignments: List Assignments
    GET /api/v1/courses/:course_id/assignments
  4. Submissions: List submissions for multiple assignments
    GET /api/v1/courses/:course_id/students/submissions

Contact Information

Kona Jones, Director of Online Learning

James Jones, Internet System Specialist & Professor of Mathematics


At Richland Community College all students must complete an online student orientation before they are able to access their courses in Canvas. For more information on our Orientation itself see the following article - and resource in the Community - Canvas Instructor Training and Student Orientation


This process starts when a student registers for a class. Students who have already completed the orientation are enrolled in the proper section of their courses, but students who have not completed the orientation are added to the orientation and to a special section of their course. This special section is called "Need to complete Orientation" and the start and end dates for that section are set to the end of the course. This allows the student to see that the course exists, but not be able to access it. To access their course the student has to complete the orientation. The orientation is self-paced and includes 10 modules. Students must work through the Modules in order and complete the final cumulative exam with an 85% or higher to complete the orientation. Once students have completed the orientation they are removed from the orientation course, added to the Canvas Student Resources course (FAQ), and switched from the “Need to complete Orientation” section of their course into the section in which they are enrolled.


Why have a mandatory orientation?

  • We saw a 7.7% increase in retention for our online courses after implementing the mandatory orientation.
  • Helps improve students’ confidence in their ability to successfully use Canvas for their courses.
  • Gives faculty back their first week of class since they don’t have to troubleshoot and play tech support
  • Faculty teaching traditional courses are more likely to use Canvas and use more advanced Canvas features because they know their students have completed the orientation and should know how to use it.


Why do we add students who have not completed the orientation into a separate “Need to complete Orientation” rather than not adding them to the course until after they have completed the orientation?

  • Faculty can easily see who has completed the orientation and who hasn’t. If the students weren’t add to the course until after they completed the orientation the instructor would have no easy way of seeing who still needed to complete the orientation.
  • Faculty can still take attendance and enter grades for students who haven’t completed the orientation. All of this information stays with the student when they move from the “Need to complete Orientation” section to their regular course section.
  • Students who haven’t completed the orientation can see their course(s), but when they click on them are not given access.


Concluded, deleted, vs. active?

  • Concluded - students have access, but can’t do anything in the course. If there is any student data it is retained and is accessible to the instructor. [In Beta right now: It appears that the concluded state will prevent students from accessing their course.]
  • Deleted - students do not have any access to the course. All student data is wiped, including that they were ever signed up for the course.
  • Active - students have access to the course and student data is available/accessible to the instructor.


Our Canvas database systems are maintained separately from our Student Information System (SIS). There is no requirement for this, but the employee working on the Canvas stuff is in a separate department and doesn't like to alter the SIS database unless necessary. There is a lot of duplication that could be removed if they were integrated, but for now, it means that our SIS contains no information about which course sections use Canvas and how they are configured.

Our Canvas database systems are running on a MySQL server, but again, there is no requirement for that. MySQL is widely supported by programming languages, including


PERL and PHP, which are the ones used by the integration. The SIS database is running Informix and compiling PERL and PHP with support requires compiling from source since precompiled packages are generally not available.


When we were developing the system, we found that it was easier to access information through the API using the Canvas IDs for values, so we have a system that contains all of the information that is in Canvas for terms, accounts, courses, sections, users, and enrollments. Many of these have a last_updated field, so that we can tell when they were last changed and reduce the information being sent to Canvas.


Helpful Hint: Store the Canvas IDs in your database. Some of the API calls return Canvas IDs and not SIS IDs and this will save extra API calls when you need that that information.

Canvas API

The system makes some calls to the Canvas API to obtain user information and assignment submissions. We use PERL and PHP but there were no sufficiently developed libraries at the time so we wrote our own libraries to handle the API calls.


PERL is used for almost all of the backend processing. The API calls are performed using the  LWP::UserAgent module. Although lib-www-perl (LWP) is part of CPAN, it was available through the system's package manager and had been used for other programs so it was familiar. PERL itself was chosen because an existing PERL codebase that handled the creation of student accounts. One major issue I had with PERL is that I tried to implement a schema to validate the input before making the call. The CPAN module Data::Schema was one of only a few available without a lot of overhead, but was deprecated in 2011 (and since removed from CPAN) in favor of a new module, Data::SAH, by the same author. Unfortunately, that newer module isn't fully compatible with the old one and no tool is provided for automated migration. A replacement validation module should able to work in both PERL and PHP but the search returned nothing useful, so Data::Schema is still in use.


PHP is used for all pages with a web-interface as well as a few of the backend processes. In PHP, I am using the cURL library that comes with PHP. Unlike PERL, there is not a library built-in to PHP that accomplishes that. There are some packages written, but there doesn't appear to be a clear winner like there is in the case of PERL. There was an HttpRequest module available in PECL, but my experience has been that packages that come precompiled work better than those available through either PEAR or PECL.

At the 2014 InstructureCon, I learned that most programming languages come with a REST package. CPAN includes REST::Client for PERL and there are several available for PHP. However, none of these have as much support as LWP::UserAgent or cURL.

Registering Students

Not every course at our institution uses Canvas. Faculty must request that their courses be created inside Canvas and whether multiple sections of the a course should be combined in Canvas or created separately. There is no requirement that faculty decide that their course will use Canvas prior to the start of registration for a semester or even before the semester begins. Some divisions shuffle teaching assignments the weekend before classes begin and courses that didn't require Canvas under the one instructor now need those added into Canvas.


In short, there is no way to definitively know which students are going to need Canvas before the semester starts. But there is Board of Trustees policy (adopted May 2012) that states, "All students enrolling in a course utilizing a learning management system are required to successfully complete the mandatory technology orientation." The procedure we use to implement that policy is that students are required to complete an orientation course inside Canvas prior to taking courses that use Canvas.


Since students aren't allowed into their courses until they complete the orientation and we sometimes don't know which students will need the orientation until right before classes start, we have a potential problem. The solution was to put all students into the Canvas orientation, not just those who are enrolled in courses that will be using Canvas.

The process to create network accounts and assign emails is ran every 10 minutes. The process to add students to Canvas is ran every 20 minutes, but only processes those students who have already had their accounts created. The longest delay a student may have between signing up for classes and being added to Canvas is 25 minutes.

Completing the Orientation

There is a mandatory orientation to Canvas for students. Students must successfully complete the orientation before they are allowed into their courses. The orientation undergoes regular revisions as part of a quality improvement process and to reflect changes in Canvas, but students do not need to retake the orientation.


Inside the Canvas orientation, there is a "final review" assignment. Completion of this assignment means that they have successfully completed the orientation. That is the official end of the orientation.


However, we added an external tool titled "Click here to complete orientation" after the final review. When a student clicks on this, it calls a small PHP script that records that the student has completed the orientation. This LTI does not make API calls to remove the student from the orientation as that might be too strange for the student to be kicked out of the orientation while they are in it.


We also correctly anticipated that not all students would not click on the external tool, so we use the Submissions API to get a list of the course submissions. There is a course id and assignment id that is unique to the final review, and we ask Canvas for that information and then record the completion for any student it returns.

GET /api/v1/courses/:course_id/assignments/:assignment_id/submissions


However, the Submissions API does not return the SIS code for the student, it returns the Canvas User ID. We would need to call the Users API to get the students SIS code so that we could record which students have completed the orientation. We maintain a cache of the Canvas information in our local system, so we just lookup the student's SIS id locally in the cache. If we find that a student's Canvas ID isn't in our system, then we'll go ahead and look it up using the Users API Get Profile command.GET /api/v1/users/:user_id/profile


Looking up the users that are missing their Canvas ID in the local cache is also a regular part of the process, so finding someone who has completed the orientation before obtaining their Canvas user ID is rare.


On our end, either through the LTI or Submissions API, we record the date, time, and version number of the orientation completed. We only use the version number for reporting purposes. We also use the date and time to process recent changes rather than processing all of the information.

Background Processing after Completion

If a student clicks on the "Click here to complete the orientation" external tool assignment, the only processing that is done is to write a successful completion to our database. No other processing occurs at that time.


We have a process that runs every 20 minutes between 6:05 am and 2:55 am. It takes a break between 3:00 - 6:00 am for additional processing, including a full batch upload in case something fell through the cracks during the day.


Here are some of the items that occur during that process.

  • The list of submissions for the final review is obtained and any students who didn't click on the "Click here to complete orientation" link are noted as having completed the orientation.
  • Any students who have completed the online orientation are deleted from the orientation and placed into a Student Resources course. This course is essentially the orientation with the quizzes removed and allows students to access the information in the orientation after they are removed from the actual orientation.
  • Any students who completed the orientation and are enrolled in a course that is using Canvas are deleted from the "Needs to complete Orientation" sections and placed into the correct sections.
  • Any courses that have had all students complete the orientation have the "Needs to complete Orientation" section deleted.
  • Any new courses that have been added into Canvas in the last 20 minutes are processed. This includes enrollments and might involve the creation of a "Needs to complete Orientation" section.
  • Changes in faculty are automatically processed as well. This might include changes in faculty due to teaching assignment changes, but it might also include existing faculty who have recently completed the Canvas Faculty Training course. That course has three levels of training: enhanced, hybrid, and online courses, and a faculty who has only gone through enhanced training won't be added as the instructor in an online course.
  • The SIS imports are sent to Canvas. This is done incrementally through the day, with changes within the last hour being sent. The overnight processing sends a full upload to catch anything that slipped through the cracks.

Contact Information

Kona Jones, Director of Online Learning

James Jones, Internet System Specialist & Professor of Mathematics

Filter Blog

By date: By tag: