Class 'Microsoft\Graph\Graph' not found - Laravel
cslater77 opened this issue · 1 comments
Describe the bug
I am trying to use the Microsoft SDK via Composer for my website project. I have a Transport controller that lists
Use Microsoft\Graph\Graph;
However I am getting the error Class "Use Microsoft\Graph\Graph" not found.
I have installed version microsoft\microsoft-graph version 2.12.0 and microsoft\microsoft-graph-core version 2.2.0
Expected behavior
I would be expecting when using this command, that it is being registered via the mail controller/ transporter
How do I resolve this?
SDK Version
2.12.0
Thanks for reporting this @cslater77.
Microsoft Graph version 2.x
initialises a GraphServiceClient
that is imported under this namespace
use Microsoft\Graph\GraphServiceClient;
Microsoft\Graph\Graph
exists in the 1.x
versions of this package. You'll need to install our latest 1.x
version for that code to work.
Is this Transport controller part of an open source Laravel project/template? If so, please share & we can collaborate to update its code to use version 2.x
of this SDK