Incorrect MDM Command Structure in DeclarativeManagement Example

I'm writing to point out a potential structural error in an example of the DeclarativeManagement command. This could cause significant confusion for developers implementing the MDM protocol.

The standard structure for a server-to-device MDM command requires CommandUUID and the Command dictionary to be siblings under the top-level dictionary. The CommandUUID serves as a top-level identifier for the entire command envelope.

This is the correct, expected structure:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Command</key>
    <dict>
        <key>Command</key>
        <dict>
            <key>RequestType</key>
            <string>DeclarativeManagement</string>
        </dict>
    </dict>
    <key>CommandUUID</key>
    <string>0001_DeclarativeManagement</string>
</dict>
</plist>

This is an example of the incorrect structure I've seen:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>Command</key>
    <dict>
        <key>CommandUUID</key>
        <string>0001_DeclarativeManagement</string>
        <key>Command</key>
        <dict>
            <key>RequestType</key>
            <string>DeclarativeManagement</string>
        </dict>
    </dict>
</dict>
</plist>

Incorrect MDM Command Structure in DeclarativeManagement Example
 
 
Q