I have a lambda function defined as
getDta:
handler: src/handlers/data/get.getAll
events:
- http:
path: groups/{groupsId}/data
method: get
cors: true
private: true
If I use API like http://localhost:3000/groups//data where groupsId is missing from path please take a look again.
In this case serverless itself return 404 - Route not found. How can I override this error to 400 - Bad request?
I appreciate your suggestion! (edited)