I ran into the same problem. After above fix changing the URL fixed the original issue, I am getting an error with token response response at line 75 of https://github.com/oktadeveloper/okta-aspnet-mvc-example/blob/master/OktaAspNetExample/Startup.cs. Error is “not found”.
AuthorizationCodeReceived = async context => { // Exchange code for access and ID tokens var tokenClient = new TokenClient( issuer + "/v1/token", clientId, clientSecret); var tokenResponse = await tokenClient.RequestAuthorizationCodeAsync(context.ProtocolMessage.Code, redirectUri); if (tokenResponse.IsError) // <---- error occurs here with "not found" { throw new Exception(tokenResponse.Error); }
issuer is “https://{{myOktaTrialPrefix}}.okta.com/”