-
Notifications
You must be signed in to change notification settings - Fork 49
If I don't specify default response, I get a TS error on endpoint request #16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I had the same issue, traced, conclude and fixed it the same way. Maybe this serverless-auto-swagger can add default to the first response (would be 200 in your case) if there is not already one? This solution feels like a dirty piece of tape. On the other hand, is it serverless-auto-swagger's responsability to do that? An other solution could be to use something like I can do the PR if you want, but we should find a smart solution that @SamWSoftware agrees with |
Instead of using |
thanks @bfaulk96 ! I think we can now close this issue |
If I don't specify default response, I get a TS error on endpoint request. The error says following:
If I add
default
response, it works.This is probably not desired, as 200 should be automatically the default response.
I traced the problem to
serverless-offline
package, specifically toHttpServer.js
file where the responses are parsed.EXAMPLES
Settings that are cause error:
Settings that work OK:
The text was updated successfully, but these errors were encountered: