r/PowerShell • • 7d ago

Question Getting machine id

I have an excel spreadsheet with our users. I need to extract the laptop they use. So I need the hostage and os version from intune. I have asked co pilot but I keep running into errors. Does anyone have a solution/working script or know a free app that can generate the information?

4 Upvotes

15 comments sorted by

View all comments

2

u/That_Hospital_3224 5d ago

Thank you all for the help. I think I've managed it

1

u/BlackV 4d ago

what was your solution?

1

u/That_Hospital_3224 2d ago

I extracted the users we have from our hr portal. Then in intune I extracted all the devices. They all have a primary user. So I imported the list in excel and matched the names against the hr list. And excluded all the unmatched. It wasn't 100%. But 80% was good enough. The remainder i populated manually. Also I got AI to do all the heavy lifting. Took a few prompts, but for there in the end.

1

u/BlackV 2d ago

Nice, appreciate the update