Web part shows Grant API Access error
In recent months, the team at adenin have observed that a small number of customers experience an anomaly when installing SharePoint web parts. This issue affects the use adenin's own web parts. In this guide we'll walk you through how to fix this glitch. It will take less than 10 minutes to fix.
Symptom
You just installed a SharePoint web part by adenin, and followed the installation instructions. Specifically, you have already checked that there are no pending API requests by the adenin web part.
Yet, when you add the web part to your page and click 'Configure' you get this error message in the sidebar:
Solution
The issue is that you will likely already have TWO API requests listed on your API Access page that interfer with this installation.
To fix this, please click on Grant API Access in the sidebar which will take you the API Access page (Requires SharePoint Admin role).
On this page you'll see a long list of "scopes" in the Approved requests section. Among the many scopes there will be two instances of User.Read
Note, there will be similar but longer scopes like
User.ReadBasic.All
which should be ignored as they don't relate to the solution in this article
Select both these scopes and remove them one after the other.
You can safely ignore the warning message. Removing a scope will simply cause it to move upwards to the Pending approval section.
Now, move onto your SharePoint Admin Center where you will click on More features → Apps → Open. In your list of apps locate the adenin web part you have installed.
Then delete it, and re-install it from the SharePoint Store as you did initially.
After this second installation has completed, becasue we fixed underlying SharePoint glitch, we will now expect one instance of the User.Read
scope being requested by the adenin web part.
Approve this scope only, and your web part will now start working as expected.