Created
December 12, 2019 21:32
-
-
Save DieNand/d361b11f088c8311286a25f7da682e88 to your computer and use it in GitHub Desktop.
Example of using curl in Windows (powershell). In this case it is actually shorthand for Invoke-RestMethod which differs a bit from curl on Linux
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
curl -Method POST -Uri <url> -ContentType 'application/json' -Body '{"content": "Whatever you want to put in here"}' -UseBasicParsing | |
-UseBasicParsing | |
Prints output directly to console and prevents the requirement for having to set up Internet Explorer in Windows 10 | |
See https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.utility/invoke-restmethod?view=powershell-6 for more details. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment