Skip to Content
avatar image
Former Member

How to call remote rest service from xsjs?

Hi all,

I'm pretty new to SAP HANA and I need to call a rest service from my xsjs (for example: http://requestb.in/1lce0gv1).

My xsjs looks like the one I attached. The question is: how do I do it?

I tried to make a post:

$.post("http://requestb.in/1lce0gv1");

But I got a 500 error page. I also tried get

$.get("http://requestb.in/1lce0gv1");

But also got a 500 error page.

Thanks in advance!!!

teste.txt.zip (1.0 kB)
Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Jun 23, 2015 at 10:51 AM

    Hello Rodrigo,

    in HANA there exists outbound HTTP connectivity. Just follow the description in the online documentation Maintaining HTTP Destinations - SAP HANA Developer Guide for SAP HANA Studio - SAP Library.

    Best Regards,

    Florian

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jun 23, 2015 at 07:19 PM

    Hi all!

    I got it done! I followed the examples in

    SAP HANA Cloud Platform

    and now it works. Thanks!!!

    Add comment
    10|10000 characters needed characters exceeded