cancel
Showing results for 
Search instead for 
Did you mean: 

Unable to use SAP API HUB to send REST APIs to SAP Digital Manufacturing Cloud

SunnyCH
Explorer
0 Kudos
159

Hi all, 

I am trying to test REST APIs for SAP Digital Manufacturing using SAP API Hub (https://api.sap.com/package/SAPDigitalManufacturingCloud/overview). 

I followed this note (https://me.sap.com/notes/0003464193) to configure the environment, current config as following, client ID and client Secret retrieved from the S4H Integration OAuth instance - service key on BTP, and copy pasted to SAP API HUB: 

ry_sunny_1-1730803615561.png

The API i am testing is: https://api.sap.com/api/sapdme_inventory/tryout

When I click on 'Run', I have the error message: Invalid JWT. 

ry_sunny_0-1730803517342.png

So I tried to test in Postman to ensue i have the valid token, however i retrieved the same error response: 

ry_sunny_2-1730803754209.png

ry_sunny_3-1730803839889.png

The Username and Password I used are the account I used to login to SAP DM, based on the error, seems like the end point is not expecting the token from my user, perhaps a different user (i.e., technical user?), if yes, where can i find this info?  

Any hints are appreciated, thanks in advance guys! 
SAP Digital Manufacturing API SAP BTP, Cloud Foundry runtime and environment 

View Entire Topic
lukas_furmanek
Advisor
Advisor
0 Kudos

Hi, as you already pointed the API clientID and secret is not the same as your login data to DM. You need to create a DM service key on BTP and use that data. This SAP Help page describes how to do it: https://help.sap.com/docs/sap-digital-manufacturing/operations-guide/prepare-for-api-integration 

I assume at least steps 1-3 were already done in your case so you can skip them if you find the configuration to be existent.

SunnyCH
Explorer
0 Kudos

hi Lukas,
Thank you for the proposed solution. 
Everything was configured, the missing part was the Starting URL, since it's a QA tenant, i suppose to select URL contains "test" on it. 
It's working well now. 
Closing this. 

KR,
Sunny