on ‎2021 Apr 16 5:50 AM
Hi Experts ,
i am implementing a crud operation using conversational AI , i am successfully able to connect S/4 HANA to conversational AI through ODATA provisioning and able to read the data from ODATA service , Now my doubt is in creation/updation of record at S/4 HANA i want to send the Json payload from conversational AI along with my ODATA Service URL , but i am not getting any documents or blog how to do it .
Request clarification before answering.
Hi Nitin,
In Action tab, before passing the JSON payload data to SAP using POST call, we need to fetch the X-CSRF token first, for this we need to make a dummy call using GET method as below screen.

Once CSRF token is fetch need to make a POST call and provide below required information.
similar way you can pass the payload data to SAP.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi nitssaxena2608
Try to use webhook method and build it through python/nodejs script calling odata service and upload it BTP cloud foundry service.
you can see many examples from blogs :
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Rajesh ,
How you were able to read Empid and Notes from Bot , can you please tell me how you created entity, skills and actions to read the Value from Bot , as i can see you are passing multiple value dynamically , I have same type of requirement i want to read the multiple input from Bot in order to create the record in S/4 HANA , currently i am hardcoding all the value in my Body section and using Post request
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
json-payload.pngHi Rajesh ,
OData service URL is only accepting post request , i am using standard API of sales order simulate where i am doing pricing simulation ,i am able to get the data but not able to Post .
One more issue i am getting data in XML Format in OData service as a response $format=json is not supported and Bot only understand the json format , from where i can change the data in Conversational AI from XML to json ? can we write script any where in BOT
i am passing below URI in Consume API in Actions of conversational AI and passing the json payload in Body
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 11 | |
| 6 | |
| 5 | |
| 4 | |
| 3 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.