Actually update the API as well as example!

API update for adding event support.