datagouv-apis

Installation
SKILL.md

data.gouv.fr APIs — Consolidated Reference

Three HTTP APIs (Main, Metrics, Tabular) plus dataservices (external HTTP APIs described on the platform; they used to be referenced on api.gouv.fr and are now dataservices on data.gouv.fr). This file is consumption-first: read paths and discovery; writes only when the user explicitly wants them and an API key is available.


How to use this skill

  • MCP first: If the client exposes data.gouv.fr MCP tools, use them for conversational catalog exploration; they orchestrate the same platform capabilities with typed tool calls. For dataservices in particular, search_dataservices matches the intent of GET /dataservices/; after a hit, load the detail record (machine_documentation_url, base_api_url, etc.) via MCP or via GET /dataservices/{id}/ before calling the upstream API. Endpoint: https://mcp.data.gouv.fr/mcp. Repos: datagouv-mcp, datagouv-skill. Tool names vary by server version—follow the host’s tool list and fall back to the HTTP endpoints in this document when MCP is missing or insufficient (dataservices: GET https://www.data.gouv.fr/api/1/dataservices/ with q, filters, and next_page, then GET /dataservices/{id}/).
  • HTTP otherwise: Use the Main, Metrics, and Tabular base URLs below. Prefer GET responses over assumptions: do not invent dataset or resource IDs; cite slugs, UUIDs, and URLs returned by the API.
  • Automation vs chat: MCP suits interactive exploration; the Main API suits reproducible scripts and the full route surface.
  • Writes (atypical): Never log or echo X-API-KEY. Use POST/PUT/PATCH/DELETE only with clear user intent and a configured key. On 401/403, distinguish missing key from insufficient permissions; on 404, re-check id vs slug and use search. Do not expand into full producer pipelines here.

Choosing an API (intent → surface)

Installs
18
GitHub Stars
42
First Seen
Feb 26, 2026