make code more go-stylish, phase#2
change API version handling