Replies: 2 comments 1 reply
-
Example:
The generated client still requires application/json for the 200 OK response. |
Beta Was this translation helpful? Give feedback.
1 reply
-
Are you using convenient errors? Am not here
…On Thu, Jun 13, 2024 at 11:48 PM tdakkota ***@***.***> wrote:
I can't reproduce it.
Generated decoder looks like this and it allows 200 OK to have any
Content-Type.
func decodeV1UserPasswordResetRequestPostResponse(resp *http.Response) (res V1UserPasswordResetRequestPostRes, _ error) {
switch resp.StatusCode {
case 200:
// Code 200.
return &V1UserPasswordResetRequestPostOK{}, nil
case 400:
// Code 400.
ct, _, err := mime.ParseMediaType(resp.Header.Get("Content-Type"))
if err != nil {
return res, errors.Wrap(err, "parse media type")
}
switch {
case ct == "application/json":...
—
Reply to this email directly, view it on GitHub
<#1265 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AF632FI2AM7Y7V6IQNXT7QLZHJRXBAVCNFSM6AAAAABJHGUZV6VHI2DSMVQWIX3LMV43SRDJONRXK43TNFXW4Q3PNVWWK3TUHM4TONRZHEZTC>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
For those really backwards APIs and folks who don't maintain their specs... We still have to consume those APIs.
Beta Was this translation helpful? Give feedback.
All reactions