C#: Exchange an auth code for a session
Exchanges an auth code for a session as part of the PKCE flow.
- Used to complete a PKCE sign-in flow (for example after an OAuth redirect or a password reset).
- Pass the code verifier you generated at the start of the flow along with the auth code returned in the redirect.
Examples
Exchange an auth code
var session = await supabase.Auth.ExchangeCodeForSession(codeVerifier, authCode);