How to get Current session or create/refresh session

Hi Team,

We implemented OKTA SDK in Classic ASP.Net webforms project and once user successful login and user was redirected to our website.

From idp_token and access_token and user Id from HttpContext.Current.GetOwinContext().Authentication. Can you please share API call to create OKTA session by using id_token or access_token?

I tried with https://{{org}}.okta.com/api/v1/sessions/me API call but I am getting {“The remote server returned an error: (404) Not Found.”} error

You can’t create session for user w/o his username/password combination, from what I know

It does seem possible. You can get a session token by using the openid endpoint for oAuth. Never tried this approach. We usually use refresh tokens to renew the id tokens, which can be used to extend the application session. Downside is that you do not have a new Okta session unless you do described in the link below.

https://developer.okta.com/docs/guides/session-cookie/overview/#retrieving-a-session-cookie-via-openid-connect-authorization-endpoint
https://developer.okta.com/docs/reference/api/oidc/#token