func main() { bar := new(Bar) var api = new(sleepy.Api) api.AddResource(bar, "/bar") api.Start(3000) }
func main() { item := new(Item) var api = new(sleepy.Api) api.AddResource(item, "/items") api.Start(3000) }