decode

The shapes in text, and what was left out.

Throws

if text is not well-formed XML, or XML whose root is not kml (a bare Document, Folder or Placemark is accepted as well).