D
D
Demigodd2018-09-04 19:35:20
Parsing
Demigodd, 2018-09-04 19:35:20

How to get the site body through a request?

Using the needle module. I send a GET request to get the Body of the site.
needle.get(' www.google.com ', function(error, response) {
console.log(response.body);
});
But alas, this is not enough, and for a complete request, you need to specify more cookies and various options. How can I find out the exact data that needs to be sent along with the GET request.
Or maybe you can somehow imitate the browser during the request to get the HTML of the site?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton fon Faust, 2018-09-04
@Demigodd

headless chrome to the rescue

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question