2
votes

Wso2 API Manager 1.10.0. PUT method does not work in API store. GET, POST, DELETE methods work, but PUT dose not work.

Error,

Curl

curl -X PUT --header "Content-Type: application/json" --header "Accept: application/json" --header "Authorization: Bearer c6c90338514e561c8a02a7b6a1c96553" -d "{\"payment\":\"PAID\"}" "https://10.138.31.22:8243/Starbucks_API/1/order_1"

Request URL

https://10.138.31.22:8243/Starbucks_API/1/order_1

Response Body

<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: /Starbucks_API/1, version: 1. Check the API documentation and add a proper REST resource path to the invocation URL</ams:description>
</ams:fault>

Response Code
403

Response Headers
{
  "content-type": "application/xml; charset=UTF-8"
}

Resource given in the request is actually matching, which I mentioned in API. Any help is appreciated.

Resource Definition enter image description here

1
Can you add your resource definitions as screenshot here?Abimaran Kugathasan
please find the image here, prntscr.com/bdamuoJohn Seen
I can't reproduce your error locally.Abimaran Kugathasan
Even I do not understand, because resource definition is correct and other methods work, only Put is not working.John Seen
Anyway, You have defined same URL with two HTTP method, which is other issue I found.Abimaran Kugathasan

1 Answers

1
votes

You are having two PUT with same URL. You can't have two different HTTP resource with same URL.