简体   繁体   中英

Python web scraper and input

I had started to build a program for my personal work use of web scraping and input for mortgage rates. Essentially what i wanted to do was have my program log into each website, enter the mortgage data necessary, and it would return rates and compare each site so that i wouldnt have to manually do this on each site.

The problem i didnt think of is the login portion. i would have to store tokens and a few other items in order for me to navigate from page to page within each website.

my question is, is this even possible since i dont know the credentials/tokens to send to each page within a site? (i have the login info but unsure if i need more than just the credentials and the tokens)

This is complicated with just the request module.

Note that this approach requires more system resources

You can use PlayWright to control a chromium instance.

Chromium saves the credentials and tokens like nearly every other browser and you just have to program the browser to login and scrape.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM