It seems registry REST API is not there in API-M 1.10.

Using the following command I can get a registry resource in API-M 1.10

curl -X GET -k -H "Authorization:Basic YWRtaW46YWRtaW4=" "
https://127.0.0.1:9443/registry/resource/_system/governance/apimgt/applicationdata/provider/admin/CalculatorAPI/1.0/in/cal_log_in_message
"

Similarly, how can I add/update a resource?

Thanks.

On Sun, Mar 12, 2017 at 11:29 PM, Rajkumar Rajaratnam <rajkum...@wso2.com>
wrote:

> Hi,
>
> I'm referring [1] and trying to add a registry resource using registry
> REST API in API Manager 1.10 using the following command.
>
> curl -X PUT -k -H "Authorization:Basic YWRtaW46YWRtaW4=" -H "Content-Type:
> application/xml" -H "Media-Type: application/xml" -d
> @cal_log_in_message.xml "https://127.0.0.1:9443/resource/1.0.0/artifact/_
> system/governance/apimgt/applicationdata/provider/
> admin/CalculatorAPI/1.0/in/cal_log_in_message"
>
> It's not working. Here is the response.
>
> raj@raj-Latitude-E6540:~/workspace$ curl -i -X PUT -k -H
> "Authorization:Basic YWRtaW46YWRtaW4=" -H "Content-Type: application/xml"
> -H "Media-Type: application/xml" -d @cal_log_in_message.xml "
> https://127.0.0.1:9443/resource/1.0.0/artifact/_system/governance/apimgt/
> applicationdata/provider/admin/CalculatorAPI/1.0/in/cal_log_in_message"
> HTTP/1.1 302 Found
> Set-Cookie: JSESSIONID=1A4DC76C0BB20201DF5C416D5B7105FE; Path=/; Secure;
> HttpOnly
> Set-Cookie: requestedURI=../../resource/1.0.0/artifact/_system/
> governance/apimgt/applicationdata/provider/admin/CalculatorAPI/1.0/in/cal_log_in_message;
> Path=/
> Location: https://127.0.0.1:9443/carbon/admin/login.jsp
> Content-Type: text/html;charset=UTF-8
> Content-Length: 0
> Date: Mon, 13 Mar 2017 03:22:18 GMT
> Server: WSO2 Carbon Server
>
> Can you please advise how to do it in API-M 1.10?
>
> [1] https://docs.wso2.com/display/Governance510/Resources+with+REST+API
>
> Thanks,
> Raj.
>
> --
> Rajkumar Rajaratnam
> Committer & PMC Member, Apache Stratos
> Senior Software Engineer, WSO2
>
> LinkedIn: https://lk.linkedin.com/in/rajuu
> Mobile: +1 408 791 7640 <(408)%20791-7640>
> Blogs: http://wso2tech.blogspot.com/ | https://medium.com/@wso2tech
>



-- 
Rajkumar Rajaratnam
Committer & PMC Member, Apache Stratos
Senior Software Engineer, WSO2

LinkedIn: https://lk.linkedin.com/in/rajuu
Mobile: +1 408 791 7640
Blogs: http://wso2tech.blogspot.com/ | https://medium.com/@wso2tech
_______________________________________________
Dev mailing list
Dev@wso2.org
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to