Defender API and Defender Portal

Oscar 177 Reputation points
2025-07-31T11:35:53.5366667+00:00

Hello,

Got interesting behavior using Defender portal and Defender API:

  1. I can run a command towards the machine: "https://eu.api.security.microsoft.com/api/machines/someID" The results show that the device has: "isAadJoined": false, "aadDeviceId": null,

User's image

  1. If I open a portal and find the same device, then I see the values are there, see print screen:

image

How is that possible?

Best regards,

Oscar

Microsoft Security | Microsoft Defender | Other
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Pauline Mbabu 1,410 Reputation points Microsoft Employee
    2025-08-06T15:25:56.4566667+00:00

    Hello Oscar,
    Thank you for reaching out.
    For Entra Joined Devices, when you Run this API , the response should give you the aadDeviceId and the isAadjoined should show as true.
    image You can verify that the Device is AADJoined by looking at the Join type from Entra admin centre under Devices.

    For Devices that are not Entra Joined, the response from the api should give you the aadDeviceId and the isAadJoined should show as false.
    image (1)

    If the Device had been recently onboarded and aadjoined, then it might have been a propagation error, and you can confirm this by trying to run the api once again and see if the response correspons to the above.
    I hope this helps to answer your question.

    If you find the answer above helpful, please Accept the answer to help anyone in the community who might have a similar question to quickly find the solution.

    0 comments No comments

  2. Oscar 177 Reputation points
    2025-08-07T06:15:29.9566667+00:00

    Hello @Pauline Mbabu

    The device was onboarded some time ago, more than a few weeks.

    For the AzureADJoin state, the API shows FALSE, but the portal shows TRUE.

    Bug?

    Best regards,

    Oscar


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.