cancel
Showing results for 
Search instead for 
Did you mean: 

How to add REST API Data Entity inside Build Apps from Service Cloud V2?

kaizen9
Explorer
0 Kudos
154

Hello together,
Being very new to SAP world and Build Apps, I am not able to fetch the entities of SCV2. The use case to fetch "location" data inside Build Apps from SCV2 using Basic Authentication method. Works very well in Postman. https://api.sap.com/api/SalesSvcCloudV2_functionalLocation/overview

Created destination with steps mentioned here. 

https://help.sap.com/docs/build-apps/service-guide/sap-systems#adding-a-btp-destination-prerequisite...


Destination additional properties:

kaizen9_0-1741878665315.png

Destination was added under integration tab.

kaizen9_1-1741879349474.png

After many trial and error, I still get following error message and cannot list expected data inside Build Apps.

kaizen9_2-1741879635170.png
After "Run Test", I got following response, but no expected response again.

kaizen9_3-1741880275450.png

What wrong I am doing?

Can anyone support please? Thanks.

@Dan_Wroblewski



 

 

 

 

View Entire Topic
Sankara1
Product and Topic Expert
Product and Topic Expert

Hello Kaizen, 

To add a REST API data entity from Service Cloud V2 in SAP Build Apps, follow these steps:

  1. Create or Open a Project:

    • Start by creating a new SAP Build Apps project or open an existing one. You can do this from the SAP Build Lobby, which is accessible from the SAP BTP Cockpit 
  2. Navigate to the Integrations Tab:

    • Go to the Integrations tab, select Add Integration, and then choose BTP Destinations 
  3. Select REST API Destination:

    • Choose the desired REST API destination (endpoint) from the list. The selected destination will open in a new window. Confirm with the Install Integration button
  4. Add REST API Data Entity:

    • To add a data entity from this destination, select Add REST API Data Entity. In the opened window:
      • Set the name for this data entity.
      • Specify the correct entity path within the API.
      • Select desired capabilities from the Enable Capabilities list 
         
  5. Confirm and Repeat:

    • Confirm using the Add button. Repeat steps 3-5 to add all the data entities you plan to use in your app 
  6. Configure Resource Schema:

    • In the Base tab, scroll to the Resource schema section. Configure the request body JSON in a visual way. Use the larger + ADD NEW button to create entries such as context (Object) and definitionId (Text). Add object properties like filename (Text), foldername (Text), employeemail (Text), and employeename (Text) 
  7. Test the Integration:

    • Navigate to the create tab to configure the Process triggering event. Bind the Request Headers to a list of values and enter the following:
      • Header name: Content-Type
      • Header value: application/json
    • Go to the TEST tab, enter desired values, and click RUN TEST. You should get an OK (201) response, indicating that the workflow has initialized 
       
kaizen9
Explorer
0 Kudos
Thank you @Sankara1