Invalid State Error after Upgrading from Auth0 PHP SDK v7 to v8

No worries, this is what I’m referring to:

    try {
        $auth0->login();
    } catch (\Exception $e) {

That login() call should instead read:

    try {
        Header('Location: ' . $auth0->login());
        exit;
    } catch (\Exception $e) {

So that the user is redirected for the authentication flow. They’ll be returned to your app and that point the callback parameters will be present