Find Jobs
Hire Freelancers

Using NodeJS, print all HTTPS Requests a given URL performs

R$30-45 BRL

Imefungwa
Imechapishwa about 6 years ago

R$30-45 BRL

Kulipwa wakati wa kufikishwa
Whenever I access a URL that is always given to me (let's call it "search URL"), it makes several subsequent HTTPS requests. Between these requests, there are 4 ones that I need (let's call them "desired URLs"). Given any "search URL" I can easily get the "desired URLs" via Chrome DevTools (Network/XHR), but I need it in nodejs. So I need a script that outputs me ([login to view URL]) the "desired URLs" when I give it a "search URL". I had a working script, but it broke in a recent site update (I will give you a printscreen of the new site to make sure we are on the same page). Here is the NON-WORKING example: //=========================================================== //=========================================================== // OLD SITE WORKING [login to view URL] const phantom = require('phantom'); // searchURLs TO TEST THE SCRIPT (I ALWAYS HAVE THESE URLs) var searchURL1 = "*"; var searchURL2 = "*"; var searchURL3 = "*"; var searchURL4 = "*"; // RANDOMLY PICK ONE OF THE ABOVE var randomURLNumber= [login to view URL](([login to view URL]() * 4) + 1); if (randomURLNumber == 1){ getMMjsonURLs(searchURL1); } else { if (randomURLNumber == 2){ getMMjsonURLs(searchURL2); } else {if (randomURLNumber == 3){ getMMjsonURLs(searchURL3); } else {getMMjsonURLs(searchURL4); }; }; }; // PRINT THE desiredURLs async function getMMjsonURLs(url) { const instance = await [login to view URL](); const page = await [login to view URL](); await [login to view URL]('onResourceRequested', function (requestData) { //// PRINT ALL REQUESTS //[login to view URL]("ALL_REQUESTS: " + [login to view URL]); //// FILTER (should get 4 URLs similtar to: **) var desiredURL = [login to view URL]('airline'); if (desiredURL != null) { //// PRINT FILTERED REQUESTS [login to view URL]("**desiredURL: " + [login to view URL]); }; }); const status = await [login to view URL](url); await [login to view URL](); }; //=========================================================== //===========================================================
Kitambulisho cha mradi: 16515152

Kuhusu mradi

5 mapendekezo
Mradi wa mbali
Inatumika 6 yrs ago

Unatafuta kupata pesa?

Faida za kutoa zabuni kwenye Freelancer

Weka bajeti yako na muda uliopangwa
Pata malipo kwa kazi yako
Eleza pendekezo lako
Ni bure kujiandikisha na kutoa zabuni kwa kazi
5 wafanyakazi huru wana zabuni kwa wastani R$41 BRL kwa kazi hii
Picha ya Mtumiaji
I will use Phantomjs tool which will give you all the request is made. from that we can extract the desired URLs. I will do it in the node.js
R$50 BRL ndani ya siku 1
4.9 (44 hakiki)
6.0
6.0
Picha ya Mtumiaji
This letter is to express my interest in the job posted on your website for an experienced, detailed-oriented, front-end web developer. As you'll see, I have six years of hands-on experience efficiently coding websites and applications using modern HTML, CSS, JavaScript and node js. Building state-of-the-art, easy to use, user-friendly websites and applications is truly a passion of mine and I am confident I would be an excellent addition to your organization. In addition to my knowledge base, I actively seek out new technologies and stay up-to-date on industry trends and advancements. This has allowed me to stay ahead of the curve and deliver exceptional work to all of my employers, including those I've worked for on a project basis. Thank you for your time and consideration. I look forward to speaking with you about this opportunity.
R$52 BRL ndani ya siku 10
0.0 (0 hakiki)
0.0
0.0
Picha ya Mtumiaji
Please pick me
R$30 BRL ndani ya siku 1
0.0 (0 hakiki)
0.0
0.0

Kuhusu mteja

Bedera ya BRAZIL
Brazil
0.0
0
Njia ya malipo imethibitishwa
Mwanachama tangu Mac 13, 2018

Uthibitishaji wa Mteja

Asante! Tumekutumia kiungo cha kudai mkopo wako bila malipo kwa barua pepe.
Hitilafu fulani imetokea wakati wa kutuma barua pepe yako. Tafadhali jaribu tena.
Watumiaji Waliosajiliwa Jumla ya Kazi Zilizochapishwa
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Onyesho la kukagua linapakia
Ruhusa imetolewa kwa Uwekaji wa Kijiografia.
Muda wako wa kuingia umeisha na umetoka nje. Tafadhali ingia tena.