import datetime
import urllib.parse

# Définir les paramètres de recherche
today = datetime.date.today()
three_years_ago = today - datetime.timedelta(days=3*365)
search_params = {
    "nom": "DUBOIS",
    "dateArriveeMax": three_years_ago.strftime("%Y-%m-%d"),
}

# Construire l'URL avec les paramètres de recherche
base_url = "http://127.0.0.1:5000/salaries"
query_string = urllib.parse.urlencode(search_params)
search_url = f"{base_url}?{query_string}"

print(search_url)


http://127.0.0.1:5000/salaries?nom=DUBOIS&dateArriveeMax=2020-02-06
spam fails_task lang_mismatch pii not_appropriate hate_speech sexual_content quality toxicity humor helpfulness creativity violence