Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

CORS and sending cookie in headers request Issues while calling adobe API through SOAP in javascript

Avatar

Level 1

Hello,

I'm trying to use the ACC Web service SOAP calls through a reactJS app.

The first issue I faced was  getting blocked by CORS : img1.jpg

After searching online, I managed to add the necessary response headers in the Apache server config and they seem to appear on the request, but that only lead to another problem which was the OPTION method getting rejected. 

img2.jpg

Many hours of research later without any lead, I decided to discard this CORS issues temporarily and run my devs on a chrome version where CORS is disabled. That seemed to work and I finally managed to call the Logon service.

With both the session and security token at my hands, it's time to call the other services that I disparately need, I configure the request headers and body and execute it, only to be met with : 

img3.jpg

Apparently it is no longer possible to set cookie as a header as the navigators are the ones who can do that now. So I basically cant make any SOAP request as all of them require the session token to be sent in the request header as a cookie.

If anyone got any idea on how to solve any of the issues mentioned above, please help ! 

Side Note : none of these issues were faced while trying to execute the request in POSTMAN, I managed to get both  the logon and other services to respond

Thanks.

 

Reference : https://experienceleague.adobe.com/docs/campaign-classic/using/configuring-campaign-classic/api/web-...

0 Replies