WSO2 AM HTTP端点

时间:2016-06-28 22:44:14

标签: wso2 wso2-am

在WSO2 AM中使用HTTP端点时遇到问题,

<ams:fault xmlns:ams="http://wso2.org/apimanager/security">
<ams:code>900906</ams:code>
<ams:message>No matching resource found in the API for the given request</ams:message>
<ams:description>Access failure for API: /rest/v1, version: v1. Check the API documentation and add a proper REST resource path to the invocation URL</ams:description>

但是,如果使用Address Endpoint,

就可以了

Address Endpoint info

Address Endpoint Impl

更改为无效的HTTP端点,

enter image description here

3 个答案:

答案 0 :(得分:1)

请注意&#34;找不到匹配的资源&#34;错误与将API请求分派给正确的API和资源有关。因此,它与您的端点类型没有任何关系。

根据附带的屏幕截图,您的API上下文和版本是MrlDatabaseAPI / v1。但你所尝试的是rest / v1。如果您没有带有上下文的API,那么&#34; rest&#34;和版本为&#34; v1&#34;,然后你会得到这种类型的错误。如果要调用MrlDatabaseAPI / v1 API,还要确保将正确的资源路径附加到该(/ pesticides,/ report,/ reportNotes,/ crop,/ cuntries)。

答案 1 :(得分:0)

请更具体,以便其他人可以帮助您,例如什么版本的AM,什么终点有效,什么不对,什么是&#34;地址终点&#34;?

根据您的快照,它看起来会指向/ rest,NOT / rest / v1。

答案 2 :(得分:0)

您可以启用WIRE日志并进一步分析。地址端点和HTTP端点都以类似的方式工作。按照this在API Manager中启用WIRE日志。