Windows defender advanced queries return 403

QA Account 5 Reputation points
2023-05-01T14:16:35.55+00:00

I am getting the following error when trying to use "advancedqueries".

how can I trace the issue? how can I fix it? (I have followed the documentation and I have all the relevant permissions)

Unauthorized request - reason of failure: Account mode is inactive

com.microsoft.graph.http.GraphServiceException: Error code: Unauthorized

Error message: Unauthorized request - reason of failure: Account mode is inactive

POST https://api.securitycenter.windows.com/api/advancedqueries/run

SdkVersion : graph-java/v5.46.0

Content-Type : application/json

User-Agent : MdePartner-Illusive-ActiveDefenseSuit[...]

[...]

403 :

Microsoft Defender for Cloud
Microsoft Defender for Cloud
An Azure service that provides threat protection for workloads running in Azure, on-premises, and in other clouds. Previously known as Azure Security Center and Azure Defender.
1,373 questions
Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
21,696 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.