Opendata.cat Estadistiques API

Estadistiques d'us i cataleg

GitHub OpenAPI

Operations 2

GET /stats.php Estadistiques de portals #
GET /mcp-stats.php Estadistiques d'us del MCP #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/opendata-cat:opendata-cat-estadistiques-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

opendata-cat-estadistiques-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Opendata.cat Estadistiques API
  description: API publica per accedir al cataleg de +2.800 datasets de dades obertes de Catalunya. 9 portals (Generalitat, Barcelona, Diba, AOC, Reus, Girona, FGC, Idescat, Renfe) + dades de +1.000 municipis. Queryable via Socrata, CKAN, Opendatasoft, Idescat API, GTFS-RT i Renfe GTFS-RT JSON.
  version: 1.0.0
  contact:
    name: opendata.cat
    url: https://opendata.cat
    email: xavi.vinaixa@gmail.com
  license:
    name: MIT
    url: https://opensource.org/licenses/MIT
servers:
- url: https://opendata.cat/api
  description: Produccio
tags:
- name: Estadistiques
  description: Estadistiques d'us i cataleg
paths:
  /stats.php:
    get:
      tags:
      - Estadistiques
      summary: Estadistiques de portals
      description: Retorna estadistiques agregades dels portals de transparencia. Cache d'1 hora.
      operationId: getStats
      responses:
        '200':
          description: Estadistiques
          content:
            application/json:
              schema:
                type: object
                properties:
                  total:
                    type: integer
                    description: Nombre total de portals
                  by_admin:
                    type: array
                    items:
                      type: object
                      properties:
                        tipus_administracio:
                          type: string
                        total:
                          type: integer
                  updated_at:
                    type: string
                    format: date-time
  /mcp-stats.php:
    get:
      tags:
      - Estadistiques
      summary: Estadistiques d'us del MCP
      description: 'Retorna metriques d''us del servidor MCP: crides totals, tools mes usades, cerques populars, datasets mes consultats i volum diari.'
      operationId: getMcpStats
      responses:
        '200':
          description: Estadistiques MCP
          content:
            application/json:
              schema:
                type: object
                properties:
                  mcp:
                    type: object
                    properties:
                      total:
                        type: integer
                      last_7_days:
                        type: integer
                      last_24h:
                        type: integer
                      unique_clients:
                        type: integer
                  top_tools:
                    type: array
                    items:
                      type: object
                  top_searches:
                    type: array
                    items:
                      type: object
                  top_datasets:
                    type: array
                    items:
                      type: object
                  catalog:
                    type: object
                    properties:
                      total_datasets:
                        type: integer
                      portals:
                        type: array
                        items:
                          type: object