@Abdul Kalam Asath,Thanks for posting in Q&A.
From your description, I know that you want to use "AUTOPILOT_MARKER" to retrieve the Autopilot profile.
Based on my research, Windows Autopilot uses the “AUTOPILOT_MARKER” UEFI firmware to retrieve the Autopilot profile. However, the “AUTOPILOT_MARKER” UEFI firmware variable is only created and populated after the device has been registered for Autopilot. This means that you cannot use the “AUTOPILOT_MARKER” UEFI firmware variable to identify whether a device is enrolled in Autopilot or not.
But you can find the AUTOPILOT_MARKER in the registry after the device registered for Autopilot. Location: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\UEFI\AUTOPILOT_MARKER
Hope this can be helpful.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.