Push MobileDeviceConfigurationProfile after PUT using API

ETI_Admin
New Contributor III

I'm writing a function that uses the classic API to add/delete devices from the Exclusion list for a MobileDeviceConfigurationProfile that has a Single App Mode payload. The scope of the profile includes static groups, but sometimes I want just one device to drop out of Single App Mode, and the Exclusion feature does just exactly that.

When I run through the process of adding a device to the Exclusion list via Jamf Pro webUI, when I hit Save I am prompted how I want to distribute - to all devices or only newly added. Once I make the selection the change is saved and the effect is seen on the device(s) immediately.

From my function, when I execute a PUT on the same mobile device configuration profile and add a <mobile_device> to the <scope><exclusion><mobile_devices> section, the command works. I get a 201 response, and I can confirm that I can see the device added if I go back into that profile within the webUI. So, the function is working to add the device to the Exclusion list.

But, the changes are never pushed out to the devices that were changed. How can I complete this last step?

2 REPLIES 2

ETI_Admin
New Contributor III

Nevermind - Got it.
You need to add '<redeploy_on_update>Newly Assigned</redeploy_on_update>' within the <General> section

I'm trying to do this same thing, but both when I try to add a mobile_device or when I try to change <redeploy_on_update> I am recieving a response of "Conflict" "Unable to update the database". Any idea why that might be?  TIA