Created
December 12, 2018 21:22
-
-
Save tidusx18/ea873e73181708799d4eeb6da38bb21c to your computer and use it in GitHub Desktop.
The code can be pasted into the console of a browser window with an active Canvas session with the appropriate course ID and assignment ID.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let csrf = Cookies.get('_csrf_token') | |
let courseID = '' | |
let assignmentID = '' | |
fetch('https://fiu.instructure.com/courses/${courseID}/undelete/assignment_${assignmentID}', { | |
method: 'POST', | |
headers: { | |
'X-CSRF-Token': csrf | |
}, | |
}) | |
.then( res => res.json() ) | |
.then( res => console.log(res) ) // confirmation |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment