commercetools / commercetools/commercetools-api-reference
Add body for default ResourceNotFound error
- Dominant language
- RAML
- Stars
- 66
- Forks
- 33
- PR merge metrics
- No merged PRs in 30d
Description
Currently in `api-specs/api/traits/errorable.raml` the 404 response is missing a body description. During code generation this causes the [Go code generator](https://github.com/commercetools/rmf-codegen/blob/main/languages/go/src/main/kotlin/io/vrap/codegen/languages/go/client/MethodRenderer.kt#L309) to skip generating a typed error for a ResourceNotFound response, defaulting to a GenericRequestError instead. I believe this happens because the 404 error gets filtered from the possible responses before being passed to the code generation method.
Would it be possible to add this body to the RAML definitions? Or do you maybe have other suggestions on how to deal with this type of missing body in described responses? I have tried hardcoding a 404 response in the code generation, but this conflicts with potential other raml definitions where there is a fully described 404.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.