Skip to content

Instantly share code, notes, and snippets.

@groegercesg
groegercesg / testing.py
Created November 1, 2025 20:33
Quick test to see how many user agents are accepted by daft.ie
from daftlistings import Daft, SearchType, Location, PropertyType
def do_search(user_agent):
daft = Daft()
daft.set_headers({"User-Agent": user_agent})
daft.set_location(Location.DUBLIN_1_DUBLIN)
daft.set_search_type(SearchType.RESIDENTIAL_RENT)
daft.set_property_type(PropertyType.APARTMENT)