Installed! Please everyone let us know if there are other APIs we can provide to improve this experience so folks feel like they have full confidence in this process. Really fun stuff!!!
Thanks Ben!
If I encounter something I will definitely create an issue on GitHub π
Maybe one thing that took my a couple of minutes, would be to add some kind of validation responses in the response. For example: if the title has not been filled in, the response is 500: Internal Server Error.
curl -X POST -H "Content-Type: application/json" \
-H "api-key: ACCESS_TOKEN" \
-d '{"article": {"body_markdown": "a body"}}' \
https://dev.to/api/articles
But as I'm writing this, I also noticed that the api docs mentioned these validation messages - so it is probably me who's doing something wrong π
If you want I can create an issue for this and we can take it from there.
Installed! Please everyone let us know if there are other APIs we can provide to improve this experience so folks feel like they have full confidence in this process. Really fun stuff!!!
Thanks Ben!
If I encounter something I will definitely create an issue on GitHub π
Maybe one thing that took my a couple of minutes, would be to add some kind of validation responses in the response. For example: if the title has not been filled in, the response is
500: Internal Server Error
.But as I'm writing this, I also noticed that the api docs mentioned these validation messages - so it is probably me who's doing something wrong π
If you want I can create an issue for this and we can take it from there.
Could still benefit from a proper status code, in this case it sounds like you were missing information, so maybe a 400 is appropriate?
422 would probably be more appropriate, but yes, a 4xx status is the way to go.
Yes, I think having a 4xx would make these "errors" more understandable for us.