An unofficial API for scrapping Moteur.ma
Project description
moteur-ma-api
This is an unofficial Python API for Moteur.ma
install
pip install moteurmapy
Quick Start
Example 1: collect search results
from moteurmapy import MoteurList
moteur_list = MoteurList()
url = "https://www.moteur.ma/fr/voiture/achat-voiture-occasion/recherche/?ville=rabat&per_page=30"
list_of_cars, page_count = moteur_list.run( url )
df_list = pd.DataFrame( list_of_cars )
Example 2: collect details about a car
from moteurmapy import MoteurDetails
moteur_details = MoteurDetails()
url = "https://www.moteur.ma/fr/voiture/achat-voiture-occasion/detail-annonce/387055/renault-scenic-.html"
details_of_one_car = moteur_details.run( url )
Example 3: build queries for MoteurList
from moteurmapy import QueryBuilder
query_builder = QueryBuilder()
url = query_builder.build(marque="dacia",
carburant="diesel",
km=20000,
region="rabat-sale-kenitra",
first_use=True,
page=0)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
moteurmapy-1.0.4.tar.gz
(4.5 kB
view hashes)
Built Distribution
Close
Hashes for moteurmapy-1.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 65ee023d79ff0f6d24f128bb4a2d2b234c2e68fa98a25af46aa9d2f6c2895b89 |
|
MD5 | 0e49cd6a99ecf43872a149974b4c4b37 |
|
BLAKE2b-256 | d59f6135fd445243392a758e27c29b431b71a043426799836599c7a92421f26d |