Showing results for 
Show  only  | Search instead for 
Did you mean: 
New Member

Disabling/Terminating a user account

Hello Devs.

From one Dev to another, as a part of the usual day-to-day operations, teachers and staff go through periods of employment, at the end of which require some shutting down accounts in systems, including Canvas, now that we have joined the community.


Unless I missed it, the API was mum on how to do so programmatically. The best solution I know so far, is to add a few random characters to the login account and password, this again has to be done manually, due to lack of API support.


Do you devs have a better programmatic solution or can y'all add an API call?



Matthew Kaiser

Systems Developer

IT Department

Midwestern University

0 Kudos
6 Replies
Community Contributor

Are you talking about something other than deleting them in an SIS import? We have the same question.

0 Kudos

Yes, we need to keep their existence and data for IT historical purposes, but when a faculty member leaves employment, we really need to just disable their login.

So I need a programmatical way to do that through the API.

0 Kudos

Hi Matthew --

I believe you should be able to do this via the API: 

Logins - Canvas LMS REST API Documentation 

You'll probably need to fetch the login(s) for the particular user first in order to get the ID of the login to delete: 

Logins - Canvas LMS REST API Documentation 


0 Kudos

I don't think you can do it like this.

You cannot delete the last login: "Users must have at least one login"

0 Kudos
Community Champion

You could add a dummy login and then delete the real one(s).

Community Champion

Hi Matthew,

While everything said above does provide you the information you need to modify a users account upon them being terminated or just need disabled. I must ask if your school is using an authentication method other than Canvas (LDAP, SAML, etc.)?

If you are using one of those methods then you would not need to modify anything within Canvas upon them leaving your school as once they have been disabled in those systems they would no longer be able to access Canvas either. 

One thing you might want to do that I have done for my school is remove the forgot password option from the Canvas login page.  I did this because this removes the users ability to reset their password and use Canvas authentication all together.