some error handling updates and golint
renamed leveled print functions to appease govet
started adding api stuff