Spaces:
Running
Running
refactor: clean up app.py and remove redundant prompt
Browse files
app.py
CHANGED
@@ -44,7 +44,7 @@ mcp = FastMCP(
|
|
44 |
description="Exposes the raw content of https://www.auracom.fr/gouv/sitesgouv.txt",
|
45 |
mime_type="text/plain"
|
46 |
)
|
47 |
-
def get_sitesgouv_txt() -> str:
|
48 |
"""Fetches the official government URL list from auracom.fr as plain text."""
|
49 |
response = requests.get("https://www.auracom.fr/gouv/sitesgouv.txt", timeout=10)
|
50 |
response.raise_for_status()
|
@@ -56,7 +56,7 @@ def get_sitesgouv_txt() -> str:
|
|
56 |
description="Exposes the raw CSV content of https://gitlab.adullact.net/dinum/noms-de-domaine-organismes-secteur-public/-/blob/master/domains.csv?ref_type=heads",
|
57 |
mime_type="text/csv"
|
58 |
)
|
59 |
-
def get_public_org_domains_csv() -> str:
|
60 |
"""Fetches the CSV of public organization domains from adullact.net as plain text."""
|
61 |
url = "https://gitlab.adullact.net/dinum/noms-de-domaine-organismes-secteur-public/-/raw/master/domains.csv"
|
62 |
response = requests.get(url, timeout=10)
|
|
|
44 |
description="Exposes the raw content of https://www.auracom.fr/gouv/sitesgouv.txt",
|
45 |
mime_type="text/plain"
|
46 |
)
|
47 |
+
async def get_sitesgouv_txt() -> str:
|
48 |
"""Fetches the official government URL list from auracom.fr as plain text."""
|
49 |
response = requests.get("https://www.auracom.fr/gouv/sitesgouv.txt", timeout=10)
|
50 |
response.raise_for_status()
|
|
|
56 |
description="Exposes the raw CSV content of https://gitlab.adullact.net/dinum/noms-de-domaine-organismes-secteur-public/-/blob/master/domains.csv?ref_type=heads",
|
57 |
mime_type="text/csv"
|
58 |
)
|
59 |
+
async def get_public_org_domains_csv() -> str:
|
60 |
"""Fetches the CSV of public organization domains from adullact.net as plain text."""
|
61 |
url = "https://gitlab.adullact.net/dinum/noms-de-domaine-organismes-secteur-public/-/raw/master/domains.csv"
|
62 |
response = requests.get(url, timeout=10)
|