Created
November 12, 2021 08:56
-
-
Save danishjafri/b7c0f58016ba0c53b8578d36e94085a1 to your computer and use it in GitHub Desktop.
API Invoke Script using PowerShell
This file contains 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
# 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 | |
$Reponse |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment