Skip to main content

Mercado Livre Affiliate - Scraper Tool

Quickstart

Creating Affiliate URL:

from mercado_livre_affiliate import MercadoLivreAffiliate
import json

def main():
    with open("www.mercadolivre.com.br.cookies.json", "r", encoding = "utf-8") as file:
        cookies = json.load(file)

    mercado_livre_affiliate = MercadoLivreAffiliate(
        cookies = cookies, # Mercado Livre site cookies
        origin_url = "https://www.mercadolivre.com.br/", # Mercado Livre root URL in your country
        webdriver_file_path = "path/to/webdriver.exe", # Path to browser webdriver
        headless = True # If the browser will appear
    )

    # Create an affiliate URL like: https://mercadolivre.com/sec/1QJMZsX
    affiliate_url = mercado_livre_affiliate.create_affiliate_url("https://produto.mercadolivre.com.br/MLB-2698490696-capinha-flashcase-aveludada-para-samsung-todos-os-modelos-_JM#reco_item_pos=1&reco_backend=univb-pdp-buybox&reco_backend_type=low_level&reco_client=pdp-v2p&reco_id=36bd3735-c484-4d17-b8f7-80a94da980f5&reco_backend_model=univb") 

    print(affiliate_url)

if __name__ == "__main__":
    main()

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mercado_livre_affiliate_scraper-0.1.0.tar.gz (2.1 kB view details)

Uploaded Source

File details

Details for the file mercado_livre_affiliate_scraper-0.1.0.tar.gz.

File metadata

File hashes

Hashes for mercado_livre_affiliate_scraper-0.1.0.tar.gz
Algorithm Hash digest
SHA256 26e1d7eb010694dc1efb32ffbb5432da5528f010450e5b277e1638f03db1d4c9
MD5 ca76bd0da039252f8d347a2320ef4a4a
BLAKE2b-256 b986ece2e5bb7693a4f99fd4b87987e52c307dea308b0ec512dbc87bfdae7972

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.0 This release

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page