Format the events properly

TODO we'll need to clean some of this up and write some tests