Changed device api to use go-martini