Connect to the Microsoft Graph from SPFx using the MSGraphClient
After adding a web part using the MSGraphClient to the page, you're being redirected to Azure AD where you get the following error:
AADSTS50011: The reply url specified in the request does not match the reply urls configured for the application: 'c58637bb-e2e1-4312-8a00-04b5ffcd3403'.
The tenant is using 2018-05-04.012 release of the SharePoint Framework
This can be resolved by going to modern Admin UI where the permissions are managed. Those pages will automatically make sure that your tenant has the correct configuration. This is not done if you only use PowerShell or other routes for the permission management. This is a bug which will be resolved, but the admin UI trick is a short-term workaround.
Can you please provide specific steps for this?
I am also receiving this error in my SPFX app. Which admin UI do we make this change? Sharepoint admin? azure ad?
https://yourtenant-admin.sharepoint.comOpening this page should trigger provisioning the necessary configuration.
@waldekmastykarz We experience the same error in our customer's environment. The workaround mentioned is not solving the issue. I can see the App id of the SharePoint Online Client Extensi... app differs from the one in the SPFx graph authentication call:


I guess that's the main cause of this error. Already contacted MS Support but no fix from their side yet...
I also guess that removing the OOTB app registration of SPFx is not the solution for this?!
Which version of the SharePoint Framework are you using @advdberg?
for this app SharePoint Framework v1.4.1
Could you check if you can repro the issue on [email protected]? There were quite a few changes related to AAD in 1.6.0 and it could be that the version you're using doesn't work correctly with the GA version of the server configuration.
Thanks for the suggestion, we'll try to update the solution to 1.6.0 and check if that's the fix
Having the same problem on 1.6.0 here, none of the workarounds seem to do anything.
Looked into this further. I see a lot of the libraries are hard-coding the aformentioned GUID in many places. Our SP Client Online app in Azure AD has a different ID. Doing a find and replace all in node_modules, switching the hard-coded ID for our app ID got it working.
Obviously this is a far from ideal solution. Any ideas?
@waldekmastykarz @JakeStanger We鈥檝e managed to update our solution to SharePoint Framework 1.6 (with some help from the CLI, thanks Waldek 馃憤) and this seems to be (at least part of) the solution for this issue. The only thing else I can imagine of is that we also replaced an old PnP Graph call used in the solution by a call with the MSGraphClient so maybe that was also part of the issue...
Issues that have been closed & had no follow-up activity for at least 7 days are automatically locked. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: Issue List: Our approach to locked issues