Closed xxluke closed 5 years ago
Yes. Use the resolveWithFullResponse: true
parameter to get the full response object (IncomingMessage
) and then use response.req
which is the request object (ClientRequest
). Here is an example of how to use the resolveWithFullResponse
parameter: https://github.com/request/request-promise#get-the-full-response-instead-of-just-the-body
Is it possible to get the actual request object, like I would get if I used
http.request
?I want to use it for debugging reasons, I'm trying to get the curl command by using the request-as-curl or request-to-curl package.