SPA +WEB Integartion
Hi ,I have created React application (SPA in Okta) and Java Spring Boot application (WEB in Okta) in Okta its working fine in React ,when i hit UI url it is navigating okta sing in page and coming back to Home page and for Java API also its working fine ,when i hit API URL in browser its navigating to Okta sign in and coming back to api and its displaying response in browser.
Now the problem is when i call API in react application on button click am getting CORS issue browser not allowing to redirect to Okta from API (UI -API -Okta sign in ). How can I Integrate SPA and WEB .I tried Token validation but if i follow token validation its working through React App but if user hit API URL in browser its throwing unauthorized error because there is no token …
Please help me how to handle this scenario