2016-06-06 2 views
2

Wso2 API 관리자 1.10.0. API 저장소에서 PUT 메서드가 작동하지 않습니다. GET, POST, DELETE 메서드는 작동하지만 PUT가 작동하지 않습니다. 내가 API에 언급 실제로 일치하는 요청에 주어진wso2 api 관리자 PUT 메서드가 API 저장소에서 작동하지 않습니다.

오류,

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" 
} 

자원. 도움을 주시면 감사하겠습니다.

자원 정의 당신은 동일한 URL 두 PUT가있는 enter image description here

+0

여기에 스크린 샷으로 리소스 정의를 추가 할 수 있습니까? –

+0

여기에서 이미지를 찾으십시오. http://prntscr.com/bdamuo –

+0

오류를 로컬에서 재현 할 수 없습니다. –

답변

1

. 동일한 URL을 가진 두 개의 서로 다른 HTTP 리소스를 가질 수 없습니다.

+1

혼란 스러웠습니다. 네, 동일한 URL을 가진 두 개의 서로 다른 HTTP 리소스를 가질 수는 없습니다. 사실 모든 PUT 요청을 사용하여 모든 업데이트를 수행 할 수 있습니다. 이것을 강조해 주셔서 감사합니다. –