Enterprise Resource Planning Blogs by SAP
Get insights and updates about cloud ERP and RISE with SAP, SAP S/4HANA and SAP S/4HANA Cloud, and more enterprise management capabilities with SAP blog posts.
Showing results for 
Search instead for 
Did you mean: 
Product and Topic Expert
Product and Topic Expert

As you might know our SAP Business One Service Layer provides an OData interface (see more details about Service Layer in our SAP Business One,version for SAP HANA Extensibility topics page). You can then develop applications in top of Service Layer to manage SAP Business One data.


One of the possibilities to create your own application in top of SAP HANA and Service Layer is to use SAP HANA XS (see details at Introducing...SAP HANA Extended Application Services (XS)).

In HANA XS to be able to call an https service from java script code it is required to create a destination and import the certificate into HANA XS. The following blogs provide detailed explanations how to set up the trust relation between your HANA XS application and an https service like our B1 Service Layer and how to define and call the https destination.


Videos in youtube are also showing step by step how to proceed:

Outbound httpS with HANA XS

Outbound httpS with HANA XS (part 2) - set up the trust relation

Outbound httpS with HANA XS (part 3) - call the https outbound service in XS server side JavaScript


Once these steps followed you will have

  • a destination file (.xshttpdest) in your HANA XS project containing details of the Service Layer destination.
    Pay attention the xshttpdest need to be in the same package as the xsjs file connecting to it (see attached B1SL.xshtppdes.txt file, remove the txt extension in your project)

  • an xsjs file using the destination file to call Service Layer (see attached CallSL_HTTPS.xsjs.txt file, remove the txt extension in your project).
    This xsjs file shows how to call B1 Service Layer fusing the HANA XS server side Java Script API (http://help.sap.com/hana/SAP_HANA_XS_JavaScript_Reference_en/$.net.http.Client.html).

  • a TrustedStore defined via HANA XS Admin tool and attached to your destination file also via HANA XS Admin tool

and you will be able to call https B1 Service Layer from your HANA XS.


Please find attached a sample HANA XS .xsjs file (change extension to .xsjs as only .txt accepted to be attached to a blog)


Note: This trusted relation can only setup between HANA XS and B1 Service Layer from B1H 9.1 PL10 on.