Posted on 10-29-2021 01:43 AM
Hi All,
Just wondering .. Using the JAMF API - Can I check that prestage a macOS in enrolled in or part of?
Rk
Posted on 10-29-2021 06:28 AM
Hi @rkeleghan,
If you're using the Classic API you can't retrieve any info of your PreStage like computers went through, profiles used, or skip setup items.
You could only check if a specific computer has gone through DEP and you would assume that a PreStage has been created thanks to the "management_status" property:
With the Jamf Pro API you could check the option "/v2/computer-prestages/{id}" to see all the devices with that exact profile and therefore make other searches:
Hope it helps.
Posted on 01-14-2022 03:55 AM
Using talking moose 's code (thanks a lot!) I did a litte script to move machines from one PrestageEnrollment to another https://gist.github.com/MichaelandMore/d19ccf71f5486ce0db442eedf85953dc
Posted on 08-16-2024 10:05 PM
I'm looking at this at present also, as we had been setting prefix information via the vendor field of prestages, however this isn't reflected correctly to a device if its prestage is moved, the old presage will remain listed under general, and obviously the vendor info where we would store the prefix for the naming convention wouldn't change even if the prestage under general would change automatically on moving the device from one prestage to another.
presently moving forward it's looking like I would need to populate my own records via extension attributes generated from api lookup against: /v2/computer-prestages/scope
which seemingly would result in a big dump of all serials and the associated prestage ids to query against, to then query the assigned prestage for the vendor info and prestage name to then populate new attribute fields via extension attribute scripts.
I've just opened a support ticket, about how the prestage listing under the device, is reflective of the original prestage it was enrolled to, and not its current one. and that the computer commands, do not provide, suitable prestage information, such as a the correct associated prestage ID the device is a member of. Hopefully some of this will be fixed in future releases.