cancel
Showing results for 
Search instead for 
Did you mean: 

Access oData API for ElectronicSignatureLogs from POD View Plugin

stephan_madlmayr
Explorer
0 Kudos
504

Hi Experts,

I am wondering how to access the Electronic SIgnature API within a POD View Plugin.

This is the URL I use in the ajaxGetRequest:

`${podController.getSignatureODataDataSourceUri()}electronicsignature/v1/signatureLogs?$expand=contexts($expand=values)

In the respone header I get Error 403 with "The request requires higher privileges than provided by the access token."

Is this the correct way to call the SAP DM Public APIs from a POD plugin extension?

Thanks in advance,

Stephan

Accepted Solutions (1)

Accepted Solutions (1)

stephan_madlmayr
Explorer
0 Kudos

Good news, SAP has provided a solution in the release 2402

They have created a new role template "Electronic_Signature_Read".
Users assigned to this role template can now call the GET /sigantureLogs API endpoint from a custom POD plugin!

Regards,
Stephan

Answers (1)

Answers (1)

tobias_renth
Participant
0 Kudos

I assume that the URL is correct. The request seems to fail due to missing authorization.

The only role I know in this area is Electronic_Signature_Sign, do you have this one?

See prerequesites here: https://help.sap.com/docs/sap-digital-manufacturing/pod-designer/electronic-signature?locale=en-US

stephan_madlmayr
Explorer
0 Kudos

Hi Tobias,

yes, both my users have this role. I am able to do a signing in the POD with the electronic signature plugin with no problems when I enter my IAS user there.
But I have tried already with both users to do the call from my POD View Plugin Extenstion, the request fails.

tobias_renth
Participant
0 Kudos

Idea for an alternative solution if you cannot fix it: Call from the plugin a production process, and make the call to the signatures from the process. Inside the process the API call should be made with a different context, getting the token directly from the service key and not based on the actual user. If this scenario is also not working, it may be needed to generate a new service key.