I have an out-of-the-box Visual Studio 2013 SPA using WebApi. I added Twitter authentication to Startup.Auth.cs and all of it works just fine when I publish to the root of an IIS web site or when I debug in VS with localhost.
What I can't figure out is how to publish the project to a subfolder like this:
In other words, http://localhost/api
The site itself works. It is the ReturnUrl from Twitter that always redirects to http://localhost/# It includes the correct access_token but in this format:
After going through each folder, I noticed one folder that I did not check - Providers. And in there is a class called ApplicationOAuthProviders.cs. Once I changed values in that file, social logins started to redirect correctly.
There are a number of changes that need to change to publish to a subfolder; they are: