Beta/test environments refreshes and cloning Microsoft Teams Sync and LTI settings from Prod

Jump to solution
NickKays
Community Explorer
Hi All.

After some more testing it appears as though the Microsoft Teams Sync integration along with some LTI settings get copied over from Canvas production to the test and beta environments with each weekly/monthly refresh. This means that its possible that when testing in test/beta you may change something that impacts production.

I was wondering if any other canvas customers have run into this issue and if you had any process in place to manage the test/beta environments? We have been considering doing a clean up every Monday morning which would include turning off the Microsoft Teams Sync and turning off any concerning LTIs but its a fairly manual and time consuming process so I'd love to hear if anyone else has a better way of handling this scenario. 
 
Thanks heaps for your help.
 
Cheers
Nick  
Labels (1)
1 Solution
jerry_nguyen
Community Contributor

@NickKays 

You can use API (API allows you to get/create/edit data of an application - e.g. Canvas without interacting with the web UI) then write a script to automate a process or plug it into a workflow automation tool like Zapier or n8n

There is an API endpoint for most of the actions on Canvas, most of them are documented here: https://canvas.instructure.com/doc/api/

If an action is not documented (E.g. in your case, turning off Microsoft Teams Sync), you can try to find an API by using your web browser Developer Tools (E.g. F12 for Google Chrome)

Canvas_FindAPI.jpg

Example: You can send a PUT request to yourinsitution.instructure.com/api/v1/accounts/1 with the following JSON request to turn off Microsoft Teams Sync

 

{"account":{"settings":{"microsoft_sync_enabled":false,"microsoft_sync_tenant":"test.microsoft.com","microsoft_sync_login_attribute":"email","microsoft_sync_login_attribute_suffix":"","microsoft_sync_remote_attribute":"userPrincipalName"}}}

 

 

View solution in original post