You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Tripletex's schema describes 200 OK responses, like this:
but it is lacking in regards to describing the other expected responses like 401, 422 etc. This results in generated clients1 not knowing of all responses an operation may yield, in this case it has no knowledge of any errors:
If I understand swagger's doc2 correctly it would be appropriate to include other common responses too:
Note that an API specification does not necessarily need to cover all possible HTTP response codes, since they may not be known in advance. However, it is expected to cover successful responses and any known errors. By "known errors" we mean, for example, a 404 Not Found response for an operation that returns a resource by ID, or a 400 Bad Request response in case of invalid operation parameters.
Tripletex's schema describes 200 OK responses, like this:
but it is lacking in regards to describing the other expected responses like 401, 422 etc. This results in generated clients1 not knowing of all responses an operation may yield, in this case it has no knowledge of any errors:
If I understand swagger's doc2 correctly it would be appropriate to include other common responses too:
Footnotes
Example https://openapi-ts.pages.dev/ ↩
https://swagger.io/docs/specification/2-0/describing-responses/: ↩
The text was updated successfully, but these errors were encountered: