How to get actual response body in Error object #461
-
|
I almost spent an hour cause I was not able to get the exact error and was unable to figure out what's going on. I know I can disable It would be better if we had some way we could get the body in error object itself. |
Beta Was this translation helpful? Give feedback.
Answered by
sindresorhus
Oct 24, 2022
Replies: 1 comment 2 replies
-
|
You should be able to get the body by accessing |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
sindresorhus
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You should be able to get the body by accessing
error.request.body: https://github.com/sindresorhus/ky#httperror