catalyst-zero/api-schema — pull request #9 by denderello (2014-10-07 10:51:20+00:00)
Title: Added new Respone and ResponseError structs

This makes the usage of responses a lot easier

```go
func GetFooBar () ([]string, error) {
response, err := ParseResponse(http.Get("/foobar"))
if err != nil {
return err
}

if err := response.EnsureStatusCode(apischema.StatusData); err != nil {
if apischema.IsStatusWrongInput(response) {
return nil, errgo.Mask(ErrWrongInput)
}
return nil, errgo.Mask(err)
}

// all good, continue
var data []string
if err := response.ParseData(&data); err != nil {
return nil, errgo.Mask(err)
}

return data, nil
}
```