Function wicrs_server::api::complete_login[][src]

pub async fn complete_login(
    auth_manager: Arc<RwLock<Auth>>,
    service: Service,
    query: AuthQuery
) -> Result<IDToken>

Completes the OAuth login request.

Arguments

  • auth_manager - The Authentication manager for the current server instance, wrapped in Arc> so that it can be used by multiple threads.
  • service - The OAuth service used in the start_login step.
  • query - The OAuth query containing the state string and the OAuth code as well as an optional expiry time.

Errors

This function may return an error for any of the reasons outlined in Auth::handle_oauth.