Unauthorized request - No active license found (when trying to access Defender API)

ZH-DL 0 Reputation points
2024-09-25T21:05:56.16+00:00

I built a script to try call Windows Defender https://api.security.microsoft.com/api/alerts API. i was able to retrieve a JWT but when i tried to hit the api end point i kept getting below error.

{ "error": { "code": "Unauthorized", "message": "Unauthorized request - No active license found", "target": "|3defab3c-436edc959eec30d4." } }

I confirmed that my org has Windows Defender Plan 2 and the registered APP has the correct permission to call alerts API endpoint.

Any helps / suggestions will be greatly appreciated

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,392 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.