Split out the api
0.1 version of API
Close API before exiting
Rename example