Setting Auto Update Time on Apps

dsweigart
New Contributor III

Is there a script or something that would make this process a lot faster instead of going into each app and then turning on the auto-update feature and setting a certain time? I know I can go in and turn the auto update on but I don't want to do that thorough MySQL on all of them because of it auto-defaulting to 12 am.

I was thinking if I script could do the following. All apps that start with the letter D set auto update to 4:00 pm. Does that make sense?

4 REPLIES 4

wesleya
Contributor

MySQL or manual might be your best option. I'm looking at the API endpoint, and I don't see anything unfortunately. I could be mistaken though.

cdenesha
Valued Contributor III

For the API endpoint <mobiledeviceapplications>:

keep_description_and_icon_up_to_date - whether the app auto-updates
itunes_sync_time - number of seconds from midnight, in GMT

dsweigart
New Contributor III

@cdenesha Can you explain a little more about how you did this?

cdenesha
Valued Contributor III

Hi @dsweigart,

I haven't updated my apps in this way, but I did collect the information this way. If I was to do it:

You need all the App IDs for your apps. One way is to use https://YourJSSURL:8443/api for 'mobiledeviceapplications' and Try it Out. It takes a little effort to clean it up, but can be done with a good text editor and perhaps a spreadsheet.

Then to leverage the API, you could run a command for each app like:

curl -H "Content-Type: application/xml" -u USERNAME:PASSWORD https://YourJSSURL:8443/JSSResource/mobiledeviceapplications/id/1 -X PUT -d "<mobile_device_application><general><keep_description_and_icon_up_to_date>true</keep_description_and_icon_up_to_date><itunes_sync_time>0</itunes_sync_time></general></mobile_device_application>"