为什么我得到不支持的请求方法 GET? [英] Why am I getting request method GET not supported?

查看:57
本文介绍了为什么我得到不支持的请求方法 GET?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 PostMan 作为 REST 客户端来测试这个 API 方法 思科 ACL 分析 API.特别是 POST/acl/trace 或 getAClTracksStd(首先进入策略分析)

I am using PostMan as a REST client to test this API method Cisco ACL Analysis API. specifically POST /acl/trace or getAClTracksStd (first go to Policy Analysis)

这是我的 PostMan HTTP 测试调用

Here is my PostMan HTTP test call

熟悉 PostMan 的人是否理解我为什么会从服务器收到此不支持请求方法 'GET'"错误?我正在发出 POST HTTP 请求,而不是 GET.(从下拉菜单中选择)让我得到输入无效参数错误或其他东西更有意义.

Does anyone who is familiar with PostMan understand why I am getting this "Request method 'GET' is not supported" error from the server? I am making a POST HTTP request, not GET.(Selected from Drop down menu) It make more sense for me to get a input invalid parameter error or something.

只是为了表明端点 url 有效,这是一个有效的 HTTP 测试请求(相同链接,主机->主机 API -> GET/host/{startIndex}/{记录返回}

Just to show that the endpoint url works, heres a HTTP test request that works (same link, host->host API -> GET /host/{startIndex}/{recordsToReturn}

推荐答案

我发现您的 REST 调用存在两个问题.首先,您看到的错误是因为调用需要以https://"开头.其次,删除接口 IDs 参数和值.进行这些更改后,您应该会收到包含数据的响应.

There's two issues that I'm seeing with your REST call. First, the error you're seeing is because the call needs to be preceded by "https://". Second, remove the interface IDs parameter and values. You should get a response with data after making these changes.

这篇关于为什么我得到不支持的请求方法 GET?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆