Skip to content

Instantly share code, notes, and snippets.

@danishjafri
danishjafri / reset-udemy-course-checked.js
Created November 13, 2021 08:44
Reset Udemy Progress
document.querySelectorAll('[data-purpose="progress-toggle-button"]').forEach((x) => {
if (x.checked == true) {
x.checked = false;
console.log('Completed');
}
else {
console.log('Incomplete');
}
});
@danishjafri
danishjafri / API Invoke Script.ps1
Created November 12, 2021 08:56
API Invoke Script using PowerShell
# Run these using Windows PowerShell ISE
$Reponse = Invoke-RestMethod -Uri 'https://localhost:44356/api/projects' -Method Get
$Reponse
$Reponse = Invoke-RestMethod -Uri 'https://localhost:44356/api/projects/12345' -Method Get
$Reponse
$Reponse = Invoke-RestMethod -Uri 'https://localhost:44356/api/projects' -Method Post
$Reponse
$Reponse = Invoke-RestMethod -Uri 'https://localhost:44356/api/projects' -Method Put
$Reponse
$Reponse = Invoke-RestMethod -Uri 'https://localhost:44356/api/projects/12345' -Method Delete