Getting an error when executing Powershell Invoke RestMethod function get error: HTTP Status 405
说明
Getting an error when executing Powershell Invoke RestMethod function get error: HTTP Status 405. Are there any examples showing how to use the RestAPI with powershell?
The message below is reported when running the following method:
Invoke-RestMethod : HTTP Status 405 - Method Not Allowed type Status report message Method Not Allowed description The specified HTTP method is not allowed for the requested resource. Apache Tomcat/7.0.82
解决办法
Following is an example of how to get the accesstoken via login restapi in powershell: