Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var _ = API("cellar", func() {
- Title("The virtual wine cellar")
- Description("A basic example of an API implemented with goa")
- Scheme("http")
- Host("localhost:8989")
- })
- var _ = Resource("bottle", func() {
- BasePath("/bottles")
- DefaultMedia(BottleMedia)
- Action("show", func() {
- Description("Retrieve bottle with given id")
- Routing(GET("/:bottleID"))
- Params(func() {
- Param("bottleID", Integer, "Bottle ID")
- })
- Response(OK)
- Response(NotFound)
- })
- })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement