Getting CSRF Token for SAP OData Create service in a Schedule event.

1
In a schedule event, I am calling a microflow which call a SAP OData service to create object in Back-End. Since in the schedule event session object is empty, I cannot get CSRF token from association CSRFToken_Session or may be its not created as well. And its important to have CSRF token before Create service call. Please help what should we do in such scenario.  
asked
2 answers
5

You might want to try to execute a microflow as user first to get a CSRF token. See the community commons executeMicroflowAsUser action. This way you can still use scheduled events but in the context of a user and thus circumvent the problem.

Regards,

Ronald

 

answered
0

Hi Abhishek,

 

Can you please share us the detail procedure or atleast the steps how to update the SAP objects.We already have Odata service created on SAP and we are able to retrieve or get but we are not able to update as we are not able to generate the CSRF token correctly.

 

We are able to login to Mendix App using OIDC module but we want to know from here how can we generate CSRF token and used to call and update SAP Odata objects.

 

Regards,

Muddassar

answered