Celebrate Excellence in Education: Nominate Outstanding Educators by April 15!
Found this content helpful? Log in or sign up to leave a like!
I'm working on a "control center" app for common work tasks. I need a function that takes in a user, then opens a web browser with the signed-in admin acting as that user. I'm scanning all through the docs and can't find any way to activate the "act as". Is there any way to do this via API? If not, any other ideas? Pretty new to Python so any module recommendations would be pretty neat too. 🙂
Solved! Go to Solution.
You can masquerade (or act as) when calling an API by adding this parameter "as_user_id" to your request. You can read more about Masquerading through API here: 📔https://canvas.instructure.com/doc/api/file.masquerading.html
You can masquerade (or act as) when calling an API by adding this parameter "as_user_id" to your request. You can read more about Masquerading through API here: 📔https://canvas.instructure.com/doc/api/file.masquerading.html
Appreciate you!
You won't be able to log into Canvas as the other user directly by launching a browser. The quickest way to get this is to take the admin to the masquerade URL for the user. That's the last screen you see before clicking "Proceed" to start the masquerading.
The URL has the form <canvas instance>/users/:user_id/masquerade
You can replace :user_id with the Canvas user ID or with sis_user_id:1234 (assuming the SIS user ID is 1234).
If you need to act as someone via the API (without actually being in Canvas), see masquerading in the API documentation.
To participate in the Instructure Community, you need to sign up or log in:
Sign In