Closed stephan418 closed 2 years ago
Where is this standard responses detailed?
Also where is the documentation you were writing?
The standard response is detailed nowhere, but it should use the format all other endpoints use (with type and payload fields; ref: https://github.com/detleph/server/blob/5b02905d7169a0a1b272fadf22aa178d084f4dbe/src/Controllers/admin.controller.ts#L181)
And I have documentation for the event endpoints. I stopped working on it, however, as it took me nearly 3 hours to write only this part (which is a fraction of the whole thing) and I don't think that is viable for such a limited-use API.
And the error occurs whenever data which is not parsable by the JSON parser is sent to the server (for example the string "test"). When this is done, a 400 response with a plain-text traceback is returned
Note: This is reffring to the express json parser which will just return a stack trace instead of a normal response.
The traceback is then forwarded to the client, which is, however, expecting a standard error response