Search code examples
macosmdm

Correct InstallApplication command format for OS X MDM


I am trying to send InstallApplication command to OS X device enrolled into MDM.

I am sending following:

<plist version="1.0">

 <dict>
      <key>Command</key>
      <dict>
           <key>Identifier</key>

           <string>com.oovoo.mac</string>
           <key>ManagementFlags</key>
           <integer>0</integer>
           <key>Options</key>
           <dict>

                <key>NotManaged</key>

                <true/>

           </dict>

           <key>RequestType</key>

           <string>InstallApplication</string>

      </dict>

      <key>CommandUUID</key>

      <string>4da44c2c-1189-493a-a906-919d027e6271</string>

 </dict>

I am getting an error back "PurchaseMethod must be 1 <MDMClientError:97>".

However, this application is free: https://itunes.apple.com/us/app/oovoo-video-call-text-voice/id792672319?mt=12

As result, I wonder whether something wrong about this command.

BTW. I tried to remove ManagementFlags, but it didn't help.

I wonder if OS X only allows to install apps through VPP and it should go through VPP even for free apps.

I tried to add PurchaseMethod = 1, but not it's failing with another issue: "Redownload not offered by store"


Solution

  • I checked with Apple and apparently apps installed to OS X through MDM should go through VPP. It includes both paid and free apps.

    As result, you need to add an app to VPP. Issue correct commands to handle VPP (register user, assign license) and only after that you can install the app.

    • PurchaseMethod should be 1
    • NotManaged should be True