To enable your SAP Build Apps app to use the OData endpoints of your CAP application, you need a destination in the subaccount where you develop the application and also in the subaccount where you deploy the application.
-
In the SAP BTP cockpit, navigate to your subaccount.
-
In the left-side subaccount menu, navigate to Connectivity → Destinations.
-
Choose New Destination to create a new destination or you can choose Import Destination to import the sample destination file DWCMISSION_FARMTANKS.
-
Configure the Destination by entering or adjusting the following values:
- Name: a meaningful name, for example DWCMISSION_FARMTANKS
- Type: HTTP
- Description: for example OData Endpoints to Farm Tank entities
- URL: the application route (obtained when deploying the CAP application) followed by /odata/v4/farm-tank
- ProxyType: Internet
- Authentication: BasicAuthentication
- User: field.technician@tester.sap.com
- Password: the password you configured for your OData endpoint
- Add the following Additional Properties by choosing New Property. If you have imported the sample destination file, the following properties are automatically added:
- Name: AppgyverEnabled - value: true
- Name: HTML5.DynamicDestination - value: true
- Name: WebIDEUsage - value: odata_gen
-
Select the Use default JDK truststore checkbox.
-
Save your settings.
-
Choose Check Connection. You should get a 200 OK response.
You have created a destination in the subaccount in SAP BTP that can be used by SAP Build Apps to consume your OData service.