A small Python package to request listings from marktplaats.nl
Project description
marktplaats-py
A small Python package to request listings from marktplaats.nl. It supports python 3.7+.
Installing
pip3 install marktplaats
Example
This is an example on how to use the library:
from marktplaats import SearchQuery
search = SearchQuery("fiets", # Search query
zip_code="1016LV", # Zip code to base distance from
distance=100000, # Max distance from the zip code for listings
price_from=0, # Lowest price to search for
price_to=100, # Highest price to search for
limit=5, # Max listings (page size, max 25)
offset=0) # Offset for listings (page * limit)
listings = search.get_listings()
for listing in listings:
print(listing.title)
print(listing.description)
print(listing.price)
print(listing.link)
# the location object
print(listing.location)
# the seller object
print(listing.seller)
# the datetime object
print(listing.date)
# the full seller object (another request)
print(listing.seller.get_seller())
for image in listing.images:
print(image.medium)
print("-----------------------------")
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
marktplaats-0.1.4.tar.gz
(5.8 kB
view hashes)
Built Distribution
Close
Hashes for marktplaats-0.1.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5837aab6efcbb79bdf7aacddd4a7b4e7fa14a0a34fed925967defd4f8944ad04 |
|
MD5 | 02fcdd782f180e6ec9b7225974419afa |
|
BLAKE2b-256 | 2a1d75587846e8b3af64c58268bbddefe77249fb83a369660f994563fa84d618 |