-
Import the API Proxy into your instance of SAP API Management via the Design menu > Import API.
-
Update the Target EndPoint to reflect your environment. The host name depends on which region you are subscribed in and can be retrieved from the service keys created in the previous section.
.
-
Implement the SAP Cloud Foundry services policy from the Policies menu, which is already included as part of the proxy file above.
-
Update TargetEndpoint > PreFlow > getcredential > sapapim.clientid and sapapim.clientsecret values using the credentials for the Developer portal service instance created in the previous section.
-
Update TargetEndpoint > PreFlow getoauthtoken > HTTPTargetConnection > URL to the tokenUrl property of the service key.
-
Update Scripts > setTarget.js > targetHost to the url property of the service key (e.g. https://eu10devportal.cfapps.eu10.hana.ondemand.com or https://us20devportal.cfapps.us20.hana.ondemand.com)
-
Click Update, Save, and Redeploy the modified proxy.
- Create an API Product from the Develop > Products > Create menu and add the newly created DevPortal_Anonymous API to it (all methods).
- Publish the API Product.
- Register an application and generate an API Key for the service account.
-
Access the Business Hub Enterprise via the URL you saved in the previous step, or by selecting the subscription link from the SAP Integration Suite launchpad.
-
Select My Workspace > Applications > Create.
-
Provide an application name, check Create this application on behalf of someone else and select the SYSTEM USER you registered previously, and add the API Product you created in the prior step. Save the Application.
-
Copy the Application Key and Secret and navigate to the Test Console
-
Select the Guest Access product you created in the previous step and the APIMgmt.APIProducts resource
-
Remove APIMgmt. from the resource field
-
Enable Basic Authentication and enter the API Key and Secret in the user and password fields, respectively. The URL rewrite is needed to handle the entity container that the platform API are inside of. The EntityContainer.EntitySet syntax is not widely used in SAP applications. Without the rewrite, the URL is created with only the EntitySet being added, resulting in a 404 error.
-
Test the request and confirm you can see the API Products in your API management instance.
- Access your subaccount in the SAP BTP cockpit.
- Select Connectivity > Destinations.
- Select Import Destination and provide the destination template.
- Customize the URL to reflect the service path from your API proxy.
- Update the user name and password fields with the API Key and Secret from the previous step.
- Save the destination.