<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: clestigon</title>
    <description>The latest articles on DEV Community by clestigon (@clestigon).</description>
    <link>https://dev.to/clestigon</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4286683%2F938be511-f842-4103-bcab-6ce12a87b3ad.png</url>
      <title>DEV Community: clestigon</title>
      <link>https://dev.to/clestigon</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/clestigon"/>
    <language>en</language>
    <item>
      <title>Wrapping 22 ESG certification registries into one MCP server</title>
      <dc:creator>clestigon</dc:creator>
      <pubDate>Sun, 06 Dec 2026 16:31:03 +0000</pubDate>
      <link>https://dev.to/clestigon/wrapping-22-esg-certification-registries-into-one-mcp-server-11bf</link>
      <guid>https://dev.to/clestigon/wrapping-22-esg-certification-registries-into-one-mcp-server-11bf</guid>
      <description>&lt;p&gt;If you have ever tried to answer a question like &lt;em&gt;"which PEFC chain-of-custody sawmills in Vietnam are flagged for EUDR due diligence?"&lt;/em&gt; with an LLM, you know the failure mode: the model will happily invent a plausible sawmill. The data exists — it is just locked inside twenty different certification registries, each with its own search form, its own pagination, and no API.&lt;/p&gt;

&lt;p&gt;I build data products for a living, so I did the boring part twenty-two times and then wrapped it once.&lt;/p&gt;

&lt;h2&gt;
  
  
  The shape of the problem
&lt;/h2&gt;

&lt;p&gt;Green building and sustainable procurement runs on certificates:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Green building&lt;/strong&gt;: BREEAM / BRE GreenBookLive, LEED-adjacent product lists, IWBI WELL, EDGE&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Product certification&lt;/strong&gt;: UL SPOT (GREENGUARD, ECOLOGO), GECA, Green Tag, SCS FloorScore, CRI Green Label Plus, Blue Angel, Green Seal, EPEAT, KEYMARK, Eurovent, CRRC, SRCC, Phius&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Supply chain&lt;/strong&gt;: GOTS / GRTS, PEFC (including EUDR due-diligence flags)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Each registry is a search page. Some are cold-fusion era ASP.NET, some are modern JS apps, one is a PDF index. None of them gives you:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;a stable record shape,&lt;/li&gt;
&lt;li&gt;paging that does not lose rows,&lt;/li&gt;
&lt;li&gt;the certificate identifier as a field rather than inside a description blob,&lt;/li&gt;
&lt;li&gt;contact data for the certified company.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;So a retrieval-augmented agent cannot answer a certification question even when the answer is public. That is the gap MCP is perfect for: one server, many tools, one schema.&lt;/p&gt;

&lt;h2&gt;
  
  
  Design decisions that mattered
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. One tool, not twenty-two
&lt;/h3&gt;

&lt;p&gt;The naive design exposes 22 tools — &lt;code&gt;breeam_search&lt;/code&gt;, &lt;code&gt;spot_search&lt;/code&gt;, &lt;code&gt;geca_search&lt;/code&gt;... Twenty-two tools in a tool list is a tax on every prompt: the model has to read 22 descriptions before deciding anything.&lt;/p&gt;

&lt;p&gt;Instead the server exposes four:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Tool&lt;/th&gt;
&lt;th&gt;Why&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;esg_list_actors&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;browse the catalog by category or keyword&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;esg_search&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;run one registry synchronously, return items&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;esg_run_async&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;long runs → &lt;code&gt;runId&lt;/code&gt; + &lt;code&gt;datasetId&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;esg_get_run_items&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;page a dataset later&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The agent does discovery with one call, then acts. Tool-selection accuracy went up immediately compared to a flat list — fewer, better-described tools beat more, narrower ones when the input space is homogeneous.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. A friendly input that maps onto hostile schemas
&lt;/h3&gt;

&lt;p&gt;Every registry names its search box differently. Real field names from the twenty-two actors:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight csvs"&gt;&lt;code&gt;&lt;span class="n"&gt;searchQuery&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;searchKeyword&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;keyword&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;brandKeyword&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="n"&gt;manufacturerQuery&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;productQuery&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;certificateHolder&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;producer&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Nobody should have to memorise that. So the server keeps a per-actor field map and translates a single shape:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"actor"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"pefc"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"query"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"plywood"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"country"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Vietnam"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nl"&gt;"maxItems"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mi"&gt;25&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;becomes the actor's actual input, with &lt;code&gt;input&lt;/code&gt; available as an escape hatch that always wins. This is the difference between a tool an agent can use on the first try and a tool that needs a schema-reading round trip.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. A stable envelope, nulls over omissions
&lt;/h3&gt;

&lt;p&gt;Registries disagree about everything except that they are disagreeable. Each record is normalised to a fixed envelope:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"recordId"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"spot-portfolio-insulation"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"recordType"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"BRAND_CERTIFICATION_PORTFOLIO"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"productName"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"manufacturer"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"..."&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"productType"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"Building Materials &amp;amp; Finishes"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"csiMasterFormat"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"09 00 00 Finishes"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"certifications"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"GREENGUARD Gold Certification | GREENGUARD Certification"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"ulStandardNumber"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"UL 2818 - 2022 Gold Standard for Chemical Emissions"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"eligibleGreenCredits"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"LEED v5 BD+C | LEED v5 ID+C | WELL v2 Pilot"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="nl"&gt;"leedV5Compliant"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="kc"&gt;true&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Fields a registry does not publish come back as &lt;code&gt;null&lt;/code&gt;, never missing. Downstream code stops branching on &lt;code&gt;hasOwnProperty&lt;/code&gt;, and the model stops hallucinating a field that was simply absent.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Sync first, async as the escape hatch
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;run-sync-get-dataset-items&lt;/code&gt; is the right default: the agent gets rows in one hop. But registries with 40k rows do not finish in 300 seconds. Those get &lt;code&gt;esg_run_async&lt;/code&gt; returning a &lt;code&gt;runId&lt;/code&gt; and a console link, plus &lt;code&gt;esg_get_run_items&lt;/code&gt; for paging. One extra tool, no extra concepts.&lt;/p&gt;

&lt;h2&gt;
  
  
  What it looks like in practice
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; Find BREEAM-certified heat pump manufacturers in the UK with EPDs

→ esg_search { "actor": "breeam", "query": "heat pump", "country": "United Kingdom" }
← 23 items · manufacturer, certificateNumber, validUntil, epdReference, csiMasterFormat
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;gt; Which GOTS-certified organic cotton mills ship to the EU?

→ esg_list_actors { "keyword": "gots" }
→ esg_search { "actor": "gotspulse", "country": "EU", "maxItems": 100 }
← 61 items with certification body, licence number, product category, country
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The registry quirks stay in the server. The agent sees two tools' worth of vocabulary.&lt;/p&gt;

&lt;h2&gt;
  
  
  Wiring it into a client
&lt;/h2&gt;

&lt;p&gt;Claude Desktop:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;
  &lt;span class="nl"&gt;"mcpServers"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="nl"&gt;"esg-compliance"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;"command"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"npx"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"args"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"-y"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;"apify-esg-compliance-mcp-hub"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
      &lt;span class="nl"&gt;"env"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="nl"&gt;"APIFY_TOKEN"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="s2"&gt;"apify_api_xxx"&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Same block works in Cursor, VS Code, Cline and Continue; any stdio host can run &lt;code&gt;node src/server.js&lt;/code&gt; directly.&lt;/p&gt;

&lt;p&gt;The server itself is about 250 lines: MCP SDK, zod schemas, a catalog JSON, and one &lt;code&gt;fetch&lt;/code&gt; wrapper around the Apify API. No framework, no build step, no Docker.&lt;/p&gt;

&lt;h2&gt;
  
  
  Lessons worth stealing
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Tool count is a budget.&lt;/strong&gt; Four well-described tools outperformed 22 narrow ones. Spend that budget on input mapping instead.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Normalise nulls.&lt;/strong&gt; &lt;code&gt;null&lt;/code&gt; is information: "this registry does not publish EPD references". A missing key is ambiguity, and ambiguity is where models start inventing.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Make the escape hatch explicit.&lt;/strong&gt; &lt;code&gt;input: { raw: true }&lt;/code&gt;-style passthroughs kept me from shipping a mapper for every exotic field, and kept users from being blocked when a registry adds one.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Credential, not demo.&lt;/strong&gt; Running against a paid API ($6 per 1,000 results) means there is no free demo endpoint that silently returns three fake rows — the first call either works or tells you exactly why it did not.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is next
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;a &lt;code&gt;esg_compare(company)&lt;/code&gt; tool that fans out across registries and returns one cross-certification profile&lt;/li&gt;
&lt;li&gt;cached certificate expiry watch: re-check &lt;code&gt;validUntil&lt;/code&gt; monthly and emit changes&lt;/li&gt;
&lt;li&gt;additional registries: RoHS/REACH declarations, FSC, Cradle to Cradle product registry&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The repo is MIT: &lt;a href="https://github.com/clestigon/apify-esg-compliance-mcp-hub" rel="noopener noreferrer"&gt;clestigon/apify-esg-compliance-mcp-hub&lt;/a&gt;. If you are building agents for construction, procurement or compliance, the twenty-two actors behind it are on &lt;a href="https://apify.com/clestigon" rel="noopener noreferrer"&gt;the Apify Store&lt;/a&gt; and each one runs standalone.&lt;/p&gt;

&lt;p&gt;Certification data is public, it is just unreadable. Making it readable is the whole job.&lt;/p&gt;

</description>
      <category>a</category>
    </item>
  </channel>
</rss>
