feat(scrapers): add zillow

This commit is contained in:
Cullen Watson
2023-09-17 15:06:31 -05:00
parent 2f3b012747
commit 2f5ea1ca88
11 changed files with 349 additions and 97 deletions

View File

@@ -1,6 +1,6 @@
from dataclasses import dataclass
import requests
from .types import Property, ListingType
from .models import Property, ListingType
@dataclass
@@ -11,9 +11,12 @@ class ScraperInput:
class Scraper:
listing_type = ListingType.FOR_SALE
def __init__(self, scraper_input: ScraperInput):
self.location = scraper_input.location
self.session = requests.Session()
Scraper.listing_type = scraper_input.listing_type
if scraper_input.proxy_url:
self.session.proxies = {
@@ -21,9 +24,12 @@ class Scraper:
"https": scraper_input.proxy_url,
}
def search(self) -> list[Property]: ...
def search(self) -> list[Property]:
...
@staticmethod
def parse_home(home) -> Property: ...
def _parse_home(home) -> Property:
...
def handle_location(self): ...
def handle_location(self):
...