Skip to content
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

Improve response errors to be more descriptive #150

Open
andyslack opened this issue Dec 18, 2024 · 0 comments
Open

Improve response errors to be more descriptive #150

andyslack opened this issue Dec 18, 2024 · 0 comments
Assignees

Comments

@andyslack
Copy link
Contributor

When we create records via the POST endpoints we are getting a lot of generic "Bad request - please check your parameters" when incorrect information is passed.

I have noticed this in the following use cases as examples:

  • When there is a unique violation, for example, trying to add a record when the record already exists.
  • When we pass the wrong value type, e.g. passing a number when it should be a string.

I would like the response errors to be way more descriptive in these kinds of situations to help the developers using the API.

It would be helpful to review other use cases where better descriptions would be helpful.

We should also look at the other endpoints (update, delete, get, list) to see if there is room for improvement here.

Finally, we should write tests for these use cases with the new improved error responses to ensure full test coverage.

@andyslack andyslack self-assigned this Dec 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant