Applies to: Cayosoft Administrator 4.3 or later.
Summary: In order to access Microsoft Graph API to collect analytical data, the Cayosoft Service Account must be granted Administrative Consent.
This article describes typical issues associated with Graph API.
Error when running Analytics collection | Microsoft Office 365 Usage rule
Issue: you configured HOME > RULES > Built-in Rules (Pre-configured) > Analytics collection | Microsoft Office 365 Usage rule to use Graph API to collect data and the rule shows error in its results:
Access denied: Administrative consent to use Microsoft Graph API has not been granted. Please go to Cayosoft Console > Configuration > Microsoft Office 365 > Admin Consent, to grant it this permission.
- Verify that you have granted consent as it described in this article: Admin Consent to Azure APIs - Connecting to the Microsoft Graph API and re-run the Analytics collection runbook.
- If you have already done this, but the error has not disappeared, check the MSOnline PowerShell module version as it described in the next section.
Consent Granted field didn't change to YES after click on Grant...
Issue: you performed all actions described in the article Admin Consent to Azure APIs - Connecting to the Microsoft Graph API but Consent Granted still shows NO in HOME > CONFIGURATION > Microsoft Office 365 > Admin Consent to Azure API-s
Resolution: You need to reinstall MSOnline PowerShell module:
- Stop Cayosoft Administrator service
- Click the Windows Start icon
- Type ISE
You will see the Windows PowerShell ISE appear on the screen
- RIGHT-CLICK Windows PowerShell ISE and click Run As Administrator
- After the Windows PowerShell ISE Console appears, run the following commands (copy & paste should work)
Get-Module -Name MSOnline -ListAvailable
- If version is not 184.108.40.206 or 220.127.116.11 run the following commands:
UnInstall-Module -Name MSOnline
Install-Module -Name MSOnline -RequiredVersion 18.104.22.168
- Start Cayosoft Service, perform Grant Consent procedure again if you need so.