2021 Oct 25 5:45 PM - edited 2024 Feb 04 2:22 AM
Hi,
I have created IRPA bot to update the custom business object data via API through IRPA after business process execution. We have custom script that makes dummy call to the S4 HANA cloud API. From the error response, we will retrieve csrf token however after IRPA Core SDK update the below codes stopped working. Please suggest if you have any other alternative to retrieve csrf token to do post/patch operation to S4 API.
const options = { resolveBodyOnly: true, responseType: 'json', url: vURL, method: 'GET', headers: { 'x-csrf-token': 'fetch', 'Accept': 'application/json', 'Content-Type': 'application/json', 'Authorization': auth }};var token = '';try { const response = await irpa_core.request.call(options);} catch (error) { token = error.response.headers['x-csrf-token'];Request clarification before answering.
antoraja
As you had mentioned the code was working with earlier Core SDK.
Can you tell me which version of core SDK the code works and version of SDK where the code not to work.You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can check the Webservices Sample BOT from BOT store(Learning Content)
User | Count |
---|---|
80 | |
30 | |
9 | |
9 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.