Added support for events.

Also fixed an issue where arrays where not properly type hinted.
Also added a default for Media MetaData.