CORS Error from JS

Hi Everyone,

I’m aware there are some of the posts available for this topic. But no resolutions matched

I was successfully able to execute access_token request https://cloud.uipath.com/identity_/connect/token

But facing the below error, when tried to access to request endpoint(https://cloud.uipath.com/xxx/xxx/orchestrator_/odata/Buckets(xxx)/UiPath.Server.Configuration.OData.GetWriteUri?path=test.txt) from client side JS.

from origin ‘http://localhost:3000’ has been blocked by CORS policy: Response to preflight request doesn’t pass access control check: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.

Tried heroku proxy url, But i’m not sure it will introduce any security risk. Please help.

@loginerror

1 Like

Hey @Rajesh_Manikandan

This error usually occurs when you try to hit the request from Client code which may expose your sensitive details as well like access token client credentials etc.

Is it possible to place these in backend ?

Just curious to know which language your using in building this ?

Thanks
#nK