Well, my developer answer would be that your command output should be considered a contract, and should be consistent, even if some properties sometimes have null values. Or, give your output object a type name that describes the kind of object it is. Then you can easily look at the type name and know what properties to expect.
To answer your question, pipe the object to GM and capture the output. Yo can easily see what properties exist that way.