Fatal error: Uncaught Error: Class "Microsoft\Graph\Generated\BaseGraphClient" not found in vendor\microsoft\microsoft-graph\src\GraphServiceClient.php #1544
use Microsoft\Kiota\Authentication\Oauth\ClientCredentialContext;
use Microsoft\Graph\Core\Authentication\GraphPhpLeagueAuthenticationProvider;
use Microsoft\Graph\GraphServiceClient;
$tokenRequestContext = new ClientCredentialContext(
$ob_config->tenant,
$ob_config->client_id,
$ob_config->client_secret
);
$scopes = ['User.Read', 'Mail.ReadWrite'];
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
print_r($tokenRequestContext);