Prototype · Preview: every server in the official registry, synced every 30 minutes. Sign in with Google to write reviews.Prototype · updated every 30 min
PopNx MCPMCP servers for people who use AI · explained in plain words Sign in

DOF: Diario Oficial de la Federación

by BEG-lagversion 1.0.0i★ 0iRuns on your computerRepository ↗
Registry nameio.github.BEG-lag/mcp-dof

How to install

What it does

Mexico's official gazette (DOF): daily editions, full texts, title search, FIX, UDIS and TIIE.

  • Connects Runs on your computer
  • Account or key No key needed
  • Category Search & AI memory

Use together with

Skills that teach the AI this kind of work; they work alongside this one

timesfm

TimesFM (Time Series Foundation Model) is a pretrained time-series foundation model developed by Google Research for time-series forecasting.

by google-research★ 35,6421 skills

Skill · How-to guide

Shadowbroker

Open-source intelligence for the global theater. Track everything from the corporate/private jets of the wealthy, and spy satellites, to seismic events in one unified interface. Hook an AI agent up to have it parse through data and find previously unseen correlations. The knowledge is available to…

by BigBodyCobain★ 11,6081 skills

Skill · How-to guide

google-maps-scraper

scrape data from Google Maps. Extracts data such as the name, address, phone number, website URL, rating, reviews number, latitude and longitude, reviews,email and more for each place

by gosom★ 8,2561 skills

Skill · How-to guide

Why it ranks here

Lists are ordered by a usage score (out of 100) built from these parts

Popularity0/80GitHub stars or weekly downloads: the larger counts 60, the smaller 20
Freshness12/12Full marks for a release or code change within 30 days
Still answering0/8The cloud endpoint answered at the last check
Usage score12/100

Quality: Passed 3/3 basic checks (shown, not used for ordering) · Momentum: No data yet (Used only on the Trending tab)

Install

Pick the AI app you use, then copy the settings.

Let your AI install it with one sentence

Please install DOF: Diario Oficial de la Federación. Follow https://mcp.popnx.com/i/beg-lag-mcp-dof.md, show me the commands and wait for my OK before running them.

Paste it into an AI that can work on your computer (such as Claude Code or Cursor). It reads our steps, shows you the commands and waits for your OK. No key, no sign-up. · See the full text your AI reads

Passed 3/3 checks · Runs on your computer · ✓ Commands checked Nov 18, 2026

First: which AI do you use?

Pick your app and the steps appear below.

Works with Claude, with some setup first

Install Docker on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone

Let AI install it

Copy this message into a Claude chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server DOF: Diario Oficial de la Federación for Claude on this computer, in this order: 1) Check Docker with docker --version. If it is missing, tell me to install it from https://www.docker.com/products/docker-desktop/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "dof": { "command": "docker", "args": [ "run", "-i", "--rm", "ghcr.io/beg-lag/mcp-dof:1.0.0" ] } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the DOF: Diario Oficial de la Federación tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Docker (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    docker --version
    • A version number such as Docker version … = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Install Docker Desktop: on Mac open Docker.dmg and drag the icon to Applications (pick Apple silicon or Intel to match your Mac) · on Windows double-click Docker Desktop Installer.exe · then open the Docker Desktop app and leave it running. No curl command needed

    Open the Docker download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: docker --version

    Install once; it works for everything that needs Docker

  2. Open the Claude desktop app’s settings file

    SettingsDeveloperEdit Config

  3. Paste these settings and save the file

    {
      "mcpServers": {
        "dof": {
          "command": "docker",
          "args": [
            "run",
            "-i",
            "--rm",
            "ghcr.io/beg-lag/mcp-dof:1.0.0"
          ]
        }
      }
    }
  4. Quit Claude and open it again

  5. Try it

    Use DOF: Diario Oficial de la Federación and tell me what you can do for me, then show me one thing

    ✓ If Claude says it is using DOF: Diario Oficial de la Federación or shows a DOF: Diario Oficial de la Federación tool in the answer, you are connected

Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version

ChatGPT cannot connect DOF: Diario Oficial de la Federación yet

DOF: Diario Oficial de la Federación runs on your computer, but ChatGPT can only connect servers that run on the web

What you can do instead

A · Use an app that can connect DOF: Diario Oficial de la Federación

  • Install Docker on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone
  • Install Docker on your computer first (one time)
  • Install Docker on your computer first (one time)
  • Install Docker on your computer first (one time)

B · Others in Search & AI memory that work with ChatGPT

Picked from the most used in the same category, only ones that connect by address with no key

Works with Claude Code, with some setup first

Install Docker on your computer first (one time)

Let AI install it

Copy this message into a Claude Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server DOF: Diario Oficial de la Federación for Claude Code on this computer, in this order: 1) Check Docker with docker --version. If it is missing, tell me to install it from https://www.docker.com/products/docker-desktop/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): claude mcp add --scope user dof -- docker run -i --rm ghcr.io/beg-lag/mcp-dof:1.0.0 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the DOF: Diario Oficial de la Federación tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Docker (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    docker --version
    • A version number such as Docker version … = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Install Docker Desktop: on Mac open Docker.dmg and drag the icon to Applications (pick Apple silicon or Intel to match your Mac) · on Windows double-click Docker Desktop Installer.exe · then open the Docker Desktop app and leave it running. No curl command needed

    Open the Docker download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: docker --version

    Install once; it works for everything that needs Docker

  2. Open Terminal

    Mac: press Command+Space and type Terminal · Windows: open PowerShell

  3. Paste this command and press Enter

    claude mcp add --scope user dof -- docker run -i --rm ghcr.io/beg-lag/mcp-dof:1.0.0
  4. Type /mcp in Claude Code

    You should see DOF: Diario Oficial de la Federación listed as connected

  5. Try it

    Use DOF: Diario Oficial de la Federación and tell me what you can do for me, then show me one thing

    ✓ If Claude Code says it is using DOF: Diario Oficial de la Federación or shows a DOF: Diario Oficial de la Federación tool in the answer, you are connected

Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Works with Cursor, with some setup first

Install Docker on your computer first (one time)

Let AI install it

Copy this message into a Cursor chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server DOF: Diario Oficial de la Federación for Cursor on this computer, in this order: 1) Check Docker with docker --version. If it is missing, tell me to install it from https://www.docker.com/products/docker-desktop/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "dof": { "command": "docker", "args": [ "run", "-i", "--rm", "ghcr.io/beg-lag/mcp-dof:1.0.0" ] } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the DOF: Diario Oficial de la Federación tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Docker (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    docker --version
    • A version number such as Docker version … = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Install Docker Desktop: on Mac open Docker.dmg and drag the icon to Applications (pick Apple silicon or Intel to match your Mac) · on Windows double-click Docker Desktop Installer.exe · then open the Docker Desktop app and leave it running. No curl command needed

    Open the Docker download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: docker --version

    Install once; it works for everything that needs Docker

  2. Click this button to open Cursor

    Open in Cursor

    Cursor asks you to confirm; click Install

  3. Open the AI chat in Cursor in Agent mode

  4. Try it

    Use DOF: Diario Oficial de la Federación and tell me what you can do for me, then show me one thing

    ✓ If Cursor says it is using DOF: Diario Oficial de la Federación or shows a DOF: Diario Oficial de la Federación tool in the answer, you are connected

Menu names checked against Cursor’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Works with VS Code, with some setup first

Install Docker on your computer first (one time)

Let AI install it

Copy this message into a VS Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.

Please install the MCP server DOF: Diario Oficial de la Federación for VS Code on this computer, in this order: 1) Check Docker with docker --version. If it is missing, tell me to install it from https://www.docker.com/products/docker-desktop/; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "servers": { "dof": { "type": "stdio", "command": "docker", "args": [ "run", "-i", "--rm", "ghcr.io/beg-lag/mcp-dof:1.0.0" ] } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) No key is needed. 5) Do what we agreed, then check that the DOF: Diario Oficial de la Federación tools really show up.

This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.

  1. Install Docker (if you don’t have it)

    Already installed? Check first · Open Terminal, type this command and press Enter

    docker --version
    • A version number such as Docker version … = installed, skip this step
    • "command not found" (on Windows: "is not recognized") = not installed yet, or installed but Terminal needs to be closed and reopened
    How to open Terminal

    Mac: press ⌘ + Space, type Terminal, press Enter

    Windows: open Start, type Windows PowerShell, then Open

    Not installed: Install Docker Desktop: on Mac open Docker.dmg and drag the icon to Applications (pick Apple silicon or Intel to match your Mac) · on Windows double-click Docker Desktop Installer.exe · then open the Docker Desktop app and leave it running. No curl command needed

    Open the Docker download page ↗

    When it’s done, close Terminal, open it again and run the same command. You should see a version number: docker --version

    Install once; it works for everything that needs Docker

  2. Click this button to open VS Code

    Open in VS Code

    VS Code asks you to confirm; click Install

  3. Open the AI chat in VS Code in Agent mode

  4. Try it

    Use DOF: Diario Oficial de la Federación and tell me what you can do for me, then show me one thing

    ✓ If VS Code says it is using DOF: Diario Oficial de la Federación or shows a DOF: Diario Oficial de la Federación tool in the answer, you are connected

Menu names checked against VS Code’s help page on Nov 11, 2026 · your screen may differ slightly by app version

Other apps that use MCP, such as Windsurf, Zed or Gemini CLI, each add servers differently. See how in the app list.

See every app that uses MCP →

JSON settings are under “For developers” below

Stuck? Ask people who use DOF: Diario Oficial de la Federación💬 Discussion →
For developers: Terminal commands and JSON settings

Installed on your computer

Claude Code

claude mcp add --scope user dof -- docker run -i --rm ghcr.io/beg-lag/mcp-dof:1.0.0

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "dof": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/beg-lag/mcp-dof:1.0.0"
      ]
    }
  }
}

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "dof": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/beg-lag/mcp-dof:1.0.0"
      ]
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "dof": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "ghcr.io/beg-lag/mcp-dof:1.0.0"
      ]
    }
  }
}

These settings are generated from the maker’s registry entry. If the README says otherwise, follow the README.

At a glance

Downloads per weeki
Not on npm/PyPI
Connection
Runs on your computer
Latest versioni
1.0.0
Published to registryi
Nov 18, 2026
Code last changedi
Nov 18, 2026
Maker
BEG-lag
Packages
oci: ghcr.io/beg-lag/mcp-dof:1.0.0
Website
github.com
Registry status
Active

Which apps can use it

Based on how this server connects and on each app’s own docs, checked Nov 10, 2026.

Run on your computer in

ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast

All apps, with pros and cons →

Related guides

What it can do

Runs on your computer; the tool list appears in your AI app after you install it.

Basic checksi

We check information anyone can see; we have not read the code. Checks that do not apply are left out of the count. · Checked Nov 20, 2026

  • ✓ Pass

    Maker matches the repo

    The registry name was verified with the GitHub account BEG-lag, which owns the repo

  • ✓ Pass

    Still maintained

    Code last changed 2 days ago

  • ✓ Pass

    Has a licence

    Uses MIT

  • – Not applicable

    Endpoint responds

    This one runs on your computer; there is no internet endpoint

  • – Not applicable

    Sign-in with OAuth

    Runs on your computer and uses local settings instead

  • … Not checked yet

    No hidden instructions in tool descriptions

    Runs on your computer; we can only read tool lists from internet endpoints

Published vulnerabilities (OSV.dev)

Not checked: only npm and PyPI packages with a version can be checked

What we check → · JSON

Makers: ask for a re-check or report wrong info
For makers: add a badge to your README

If you made this, paste this code into your README. The badge links back to this page.

[![Featured on PopNx MCP](https://mcp.popnx.com/badge/beg-lag-mcp-dof.svg)](https://mcp.popnx.com/en/servers/beg-lag-mcp-dof)

Discussion

Ask, share a tip or report that it does not work. Sorted by what people marked helpful.

No posts yet. Be the first to ask or share.

Posts here are written by users, not the PopNx team.

Sign in to post

User reviews

No reviews yet

Sign in to write a review

Compared with others in Search & AI memoryi

  • More stars than 0% of the other 6508 servers in this category
  • Published to the registry more recently than 93% of the other 6508 servers in this category
  • Basic checks equal to or better than 99% of the other 6508 servers in this category

Compared with every active server in this category in the registry. Stars count only when the publisher owns the repo.

Common questions

Is DOF: Diario Oficial de la Federación safe?

It passed 3 of 3 applicable basic checks. We have not read the code. Before adding a key or token, see what access the server asks for and use a key with only the permissions you need.

What keys or codes does it need?

The registry does not list a required key, though some servers ask you to sign in on first use.

Does it run on my computer or in the cloud?

It runs on your computer. Your AI app starts it when needed, and data does not pass through the maker’s servers (unless it calls an online service itself).

Is it still maintained?

The GitHub repo last changed 2 days ago, and the latest version (1.0.0) reached the registry 2 days ago.

Which apps can use it?

Apps that support MCP, such as Claude Desktop, Claude Code, Cursor and VS Code. You also need Docker on your computer.

What can I use instead?

In the same category: OpenSEO, Exa, Microsoft Learn MCP, Docs, COTAL actions (cotal.ai)

Similar alternatives

Same category, other makers, commands already checked. Official ones first, then by stars.

Reading a card:↓ Downloads per weeki★ GitHub starsiThree pillars: reviews · checks · usageiUpdated = latest version published to the registryi

OpenSEO

Keyword research, site audits, rank tracking and AI visibility for your AI agent.

by every-appWidely used★ 28.4KUpdated 6 days ago

Runs in the cloud✓ everyapp.com

Exa

Official Exa MCP for web search, content fetching, and multi-step research.

by exa-labsWidely used★ 5.2KUpdated today

Runs in the cloud✓ service owner · exa.aiTried by the PopNx team

Microsoft Learn MCP

Official Microsoft Learn MCP Server – real-time, trusted docs & code samples for AI and LLMs.

by MicrosoftDocsWidely used★ 2KUpdated 12 months ago

Runs in the cloud✓ service owner · microsoft.comTried by the PopNx team

Docs

Search and read Empryo's documentation. Read-only, no auth, no local access.

by proxysoulGrowing★ 1.6KUpdated 2 months ago

Runs in the cloud✓ empryo.com
Compared with similar ones
This one
DOF: Diario Oficial de la Federación
OpenSEOExaMicrosoft Learn MCPDocsCOTAL actions (cotal.ai)
Runs whereInstalls on your computerRuns in the cloud, nothing to installRuns in the cloud, nothing to installRuns in the cloud, nothing to installRuns in the cloud, nothing to installRuns in the cloud, nothing to install
Needs a keyNoNoNoNoNoNo
Add with + in ClaudeNoYesYesYesNoNo
Basic checks3/35/52/44/44/44/4
LicenseMITMITMITCC-BY-4.0NOASSERTIONApache-2.0
PriceNo cost listed in the registryNo cost listed in the registryNo cost listed in the registryNo cost listed in the registryNo cost listed in the registryNo cost listed in the registry

README from the maker

Open the README

Copied from the maker’s repo as written. PopNx MCP has not reviewed or endorsed it. HTML, images and scripts are removed. Links lead off this site.

English · Español

Re-staged from the real session in docs/demo.md . MP4 version .

mcp-dof is a Model Context Protocol server that lets Claude and other AI agents read Mexico's *Diario Oficial de la Federación* (DOF): what was published on any day, the full text of every decree, rule or notice as clean Markdown, title search over date ranges, and the exchange rate, UDIS and TIIE the DOF publishes daily.

The DOF is where Mexican federal law becomes law. Lawyers, compliance teams and analysts check it every morning. This server lets an agent do the reading, always citing the official link.

Demo

Real output, recorded through a real MCP client over stdio against the live API on 2026-11-17. Excerpts below are copied verbatim (… marks omitted lines); the full, unedited transcript is in docs/demo.md.

<!-- list_edition(date="2026-11-13") · 0.4 s -->

DOF 2026-11-13 · Friday

66 notes in 2 edition(s): matutina, vespertina. 44 avisos judiciales y generales hidden (pass include_avisos=true to list them).

Edición matutina · 61 notes (44 avisos hidden) · edition PDF

PODER EJECUTIVO › PRESIDENCIA DE LA REPUBLICA

  • 5803757 Decreto por el que se expide la Ley de Ingresos de la Federación para el Ejercicio Fiscal de 2027. · p. 4 · DOF

…

<!-- get_indicators(date="2026-11-17") · 0.2 s -->
IndicatorValueUnitPublishedKey
Tipo de cambio FIX (dólar)18.5525MXN per USD2026-11-17usd
UDIS8.913896MXN per UDI2026-11-17udis
TIIE 28 días6.5147%% annual2026-11-17tiie28
TIIE 91 días6.5492%% annual2026-11-17tiie91
TIIE 182 días6.5995%% annual2026-11-17tiie182
TIIE de fondeo6.26%% annual2026-11-17tiie_fondeo

…

search_notes(practice_area="hidrocarburos", date_from="2026-10-01", date_to="2026-11-13") scanned 44 days (535 notes) in 10.7 s with a cold cache and returned 32 matches, from the CNE rules on marketing of natural gas and petroleum products to the ASEA emergency NOMs on LP gas.

Things you can ask once it is connected (example prompts, not recorded answers):

  • *"¿Qué publicó el DOF hoy? Resume solo lo que toca energía e hidrocarburos."*
  • *"Read the Ley de Ingresos 2027 and list every transitory article with a deadline."*
  • *"Prepara un digest regulatorio de minería de las últimas dos semanas."* (uses the regulatory_digest prompt)
  • *"How did the FIX exchange rate move in October 2026?"*

Quickstart

You need uv. Nothing else: uvx downloads and runs the server.

Claude Code

claude mcp add dof -- uvx --from git+https://github.com/BEG-lag/mcp-dof mcp-dof

Claude Desktop: add this to claude_desktop_config.json (macOS: ~/Library/Application Support/Claude/, Windows: %APPDATA%\Claude\) and restart:

{

"mcpServers": { "dof": { "command": "uvx", "args": ["--from", "git+https://github.com/BEG-lag/mcp-dof", "mcp-dof"] } } }

Docker: every release publishes a multi-arch image (linux/amd64, linux/arm64) to GitHub Container Registry. In any client config, use "command": "docker" with these arguments:

docker run -i --rm ghcr.io/beg-lag/mcp-dof:1.0.0

Any other MCP client: run mcp-dof over stdio, or mcp-dof --transport http --port 8000 for streamable HTTP at http://127.0.0.1:8000/mcp.

The metadata for the MCP Registry lives in server.json, under the name io.github.BEG-lag/mcp-dof.

Tools

ToolWhat it does
list_edition(date, edition, include_avisos)Table of contents of a day (matutina, vespertina, extraordinaria), grouped by issuing agency, with note codes, pages, official links and the edition PDF. On weekends and holidays it points to the latest edition.
get_note(code, start, max_chars)Full text of a note as Markdown (bold, tables and links preserved) with a metadata table. Long instruments are paginated.
search_notes(query, date_from, date_to, practice_area, edition, include_avisos, limit)Title search over up to 92 days, newest first, with progress notifications. Accent and case insensitive, prefix matching (eléctric), "phrases", `a \b alternatives and acronyms (CFE, ISR`).
get_indicators(date)FIX exchange rate, UDIS, TIIE 28/91/182 and TIIE de fondeo for a date; weekends are completed with the latest publication of each indicator.
get_indicator_history(indicator, date_from, date_to)One indicator over up to 400 days, with first, last, change, low and high.

Practice-area presets for search_notes: energia, hidrocarburos, mineria, fiscal, ambiental, competencia, financiero, comercio_exterior, laboral, datos_personales, normas, telecom.

Also exposed: the prompt `regulatory_digest(practice_area, date_from, date_to, language)` and the resources dof://edition/{date} (JSON), dof://note/{code} (Markdown) and dof://practice-areas. Dates accept YYYY-MM-DD, DD-MM-YYYY, today or yesterday, in Mexico City time. All tools are annotated read-only.

How it works

flowchart LR

A["Claude or any MCP client"] -- "stdio / HTTP" --> B["mcp-dof FastMCP tools, prompt, resources"] B --> C{"TTL cache past days 12 h today 5 min"} C -- miss --> D["SIDOF client 250 ms spacing retries + backoff"] D -- "GET /notas/{fecha} /notas/nota/{id} /indicadores/..." --> E[("SIDOF API sidof.segob.gob.mx")] B --> F["HTML to Markdown styles to bold, tables kept"] B --> G["Title search accents, prefixes, presets"]

The DOF has no official API documentation beyond a few PDFs, so the endpoints, quirks and limits were probed by hand and written up in docs/api.md. A few highlights: a bare Accept: application/json header gets HTTP 406, invalid dates return HTTP 500, every table of contents mixes untitled separator rows with real notes, and the public search backend returns HTTP 204 for every query, which is why search_notes scans daily indexes instead.

Being polite to a government server is part of the design: a descriptive User-Agent, at least 250 ms between requests, exponential backoff that honours Retry-After, timeouts, and caching.

Project structure

src/mcp_dof/

server.py FastMCP app: tools, resources, prompt, CLI entry point client.py async SIDOF client: throttling, retries, TTL cache models.py typed parsing of SIDOF payloads (editions, notes, indicators) markdown.py note HTML to Markdown, pagination at paragraph boundaries search.py query parser, accent-insensitive matching, practice-area presets formatting.py Markdown rendering of tool results dates.py date parsing and validation in Mexico City time tests/ 87 offline tests on recorded fixtures + 3 opt-in live tests scripts/ record_fixtures.py, demo.py (writes docs/demo.md), smoke_stdio.py (handshake check) docs/api.md the SIDOF API, as observed Dockerfile container image published to ghcr.io/beg-lag/mcp-dof server.json MCP Registry metadata

Development

uv sync

uv run pytest # offline: recorded SIDOF responses, no network uv run pytest --live -m live # opt in: hits the real API uv run ruff check . && uv run ruff format --check . uv run python scripts/demo.py # real MCP round trip over stdio docker build -t mcp-dof . && uv run python scripts/smoke_stdio.py -- docker run -i --rm mcp-dof

CI runs ruff and the offline suite on Python 3.12, 3.13 and 3.14, validates server.json against the official MCP Registry schema, and builds the container and checks its MCP handshake. Pushing a vX.Y.Z tag publishes the image to GHCR. A separate weekly workflow runs the live tests, so a change in the government API shows up as a failed check instead of a confused agent.

Limitations

  • Search covers titles, not full text, and at most 92 days per call: SIDOF's own search endpoint did not return results when probed. Scanning a cold range takes roughly 0.25 s per day.
  • Avisos judiciales y generales are listed by SIDOF with reference codes as titles (Aviso REF:581596), so they are hidden by default and not searchable by content.
  • Full text is available only when SIDOF has HTML for the note (its existeHtml flag). Otherwise get_note returns the metadata plus the Word and edition PDF links.
  • The SIDOF API is undocumented and can change without notice; the weekly live check is the early warning.
  • Indicators are listed by DOF publication date; Banco de México determines the FIX and the TIIE on the previous business day.

Disclaimer

Unofficial: only the printed/official DOF is authoritative; not legal advice. This project is not affiliated with the Secretaría de Gobernación or the DOF. Verify any legal conclusion against the official publication and with the competent authority.

Author

Built by Benjamín Esponda García, a Mexican corporate lawyer (energy, hydrocarbons and mining) who builds with AI. More at pivotek.mx and in the portfolio. Companion project: dof-diario, a living open dataset of the DOF table of contents.

Code released under the MIT License.