Add example script, some cleanups to the handler.