
Iana Registries Mcp Server
io.github.cyanheadsv0.1.1更新於 Oct 1, 2026
Find IANA ports, MIME types, HTTP codes/fields, URI schemes, PENs, BCP 47 tags, RFCs, any registry.
概覽
讓助理查詢 IANA 登錄資料,例如連接埠、媒體類型、HTTP 狀態碼與欄位、URI 配置、PEN 和 BCP 47 語言標籤,以及 RFC 與草案狀態。
- 功能
- 提供十個查詢工具,涵蓋 IANA 協定登錄:連接埠與服務名稱、媒體(MIME)類型、HTTP 狀態碼與欄位、URI 配置、私有企業編號(PEN)以及 BCP 47 語言標籤。也可從 RFC Editor 和 IETF Datatracker 取得 RFC 與 Internet-Draft 的狀態,並能搜尋與讀取 IANA 協定索引中的任何登錄。RFC 相關結果僅為中介資料,伺服器不會回傳 RFC 內文。
- 適用情境
- 當助理需要權威的協定常數或文件狀態時適用:確認某個連接埠屬於哪項服務、某個媒體類型或 HTTP 欄位是現行還是已棄用、驗證語言標籤,或確認某份 RFC 是否已被取代或更新。它是參考資料查詢工具,不是通用網頁搜尋。
- 執行需求
- 透過 npm 以本機 stdio 程序(或本機 Streamable HTTP 伺服器)執行,需要 Bun v1.4.0+ 或 Node.js v24+。不需要 API 金鑰或帳號,上游來源皆免金鑰。需要連線至 iana.org、rfc-editor.org 和 datatracker.ietf.org 的網路。可選的框架變數包括 MCP_TRANSPORT_TYPE、MCP_HTTP_PORT、MCP_HTTP_HOST、MCP_HTTP_ENDPOINT_PATH、MCP_AUTH_MODE 和 MCP_LOG_LEVEL。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Iana Registries Mcp Server,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
@cyanheads/iana-registries-mcp-server
Look up IANA ports, media types, HTTP status codes and fields, URI schemes, enterprise numbers, and BCP 47 language tags; check RFC status; search and read any IANA registry via MCP. STDIO or Streamable HTTP.
Overview
Protocol parameters from the IANA registries, and document status from the RFC Editor and the IETF Datatracker. Look up ports, media types, HTTP status codes and fields, URI schemes, Private Enterprise Numbers, and BCP 47 language tags; check whether an RFC is current, obsoleted, or updated, and where an Internet-Draft stands; and search and read any other registry in the IANA protocol index. RFC answers are metadata only: the server never returns RFC text. Runs as a stdio process or a local Streamable HTTP server.
Tools
Capability reference
iana_lookup_port tool
- One of
port(0–65535),service(exact name), orkeyword;transport(tcp,udp,sctp,dccp) filters every mode - Each row carries
state(assigned,reserved,unassigned,unnamed) and its transport; port mode addsport_class(system,user,dynamic) and the range rows that contain the port
iana_lookup_media_type tool
- One of
type(e.g.application/json; parameters after;are dropped) orkeyword;top_levelnarrows keyword mode statusiscurrent,deprecated, orobsoleted, withreplaced_bywhen the registry names a replacementtypemode also reads the registration template and returns its file-extension, intended-usage, and deprecated-alias statements undertemplate;template.fetchedisfalsewhen the template can't be read
iana_lookup_http_status tool
- One of
code(100–599) orkeywordover registered reason phrases - Returns
classandstate(assigned,temporary,obsoleted,unused) with the defining reference and section; an unassigned code returnsfound: falseand itsunassigned_range
iana_lookup_http_field tool
- One of
name(case-insensitive) orkeywordover names and comments;statusfilters both modes - Returns
status(permanent,provisional,deprecated,obsoleted),structured_typewhen one is registered, comments, and the defining reference
iana_lookup_uri_scheme tool
- One of
scheme(a trailing:or://is ignored) orkeyword;status(permanent,provisional,historical) filters both modes - Returns the description, references,
well_known_uri_support, andtemplate_urlwhen a registration template is published
iana_lookup_pen tool
- One of
pen(a number, or an OID under1.3.6.1.4.1) ororganizationwords - Each entry carries its
oidprefix andstate(assigned,reserved,unassigned);organization_withheld: truemarks an organization line held back because it mixes in contact details - An OID with arcs below the enterprise number echoes
requested_oidandsub_arcs; those arcs are assigned by the enterprise, not IANA
iana_lookup_language_tag tool
- One of
tag(underscores read as hyphens) ordescription;subtag_typenarrows description mode - Tag mode returns
well_formed,valid,canonical_tag(valid tags only), each part insubtags[], andissues[]:kindunknownandwrong_positionmake a tag invalid, whiledeprecated,variant_prefix_mismatch,suppress_script_redundant, andextension_not_validatedare advisory - A single-subtag input lists records of other types under the same subtag in
also_registered_as
iana_get_rfc_status tool
- Up to 10
idsper call: RFC numbers in any common form, RFC Editor or Datatracker URLs, and draft names with or without a revision suffix; BCP, STD, and FYI numbers come back askind: "unsupported" documents[]gives RFCs their current and as-published status, stream, group, obsoletes and updates relations, and errata page, and gives drafts their state, IESG state, replacements, andbecame_rfc; an unknown id isfound: falsewithguidance- An id whose upstream lookup fails lands in
failed[]while the rest still answer; the call fails only when every id failed
iana_search_registries tool
querywords matched against registry titles, categories, and ids, with an exact registry or sub-registry id ranked first;limit1–50, default 15, paged byoffset- Each entry carries the
registry_idandsubregistry_idthatiana_get_registry_recordsreads, plus registration procedure, defining documents, and page and XML URLs
iana_get_registry_records tool
- A
registryid oriana.org/assignmentsURL, optionalsubregistry, and filtersvalue(exact match on the key column; a decimal also matches range rows) andcontains(words in any field) - Pages by
cursor/next_cursorwithinlimit(1–100, default 25) and a 48,000-character records budget; a field over 2,000 characters is cut, a record keeps at most 16 fields, andcut_fieldsnames what was cut - A registry with several sub-registries and none chosen returns
subregistries[]instead of records; failures carryunknown_registry,unknown_subregistry,non_xml_registry,invalid_cursor, orcursor_mismatch
Features
Built on @cyanheads/mcp-ts-core: stdio and Streamable HTTP transports, pluggable auth (none / jwt / oauth), swappable storage (in-memory, filesystem, Supabase, Cloudflare KV/R2/D1), structured logging with optional OpenTelemetry tracing.
IANA-specific:
- Live, keyless reads of the IANA registry files, the RFC Editor's per-RFC JSON, and the IETF Datatracker
- Each registry loads on first use and stays cached for 24 hours before revalidating; when a refresh fails, a cached copy up to 7 days old answers with
source.stale: true - Self-imposed request pacing per host (iana.org, rfc-editor.org, datatracker.ietf.org) and one 45-second budget per tool call that covers every retry and queue wait
- Generic records keep the registry's XML element names as field names (
recis the Recommended column); the registry notes returned on the first page usually explain them - Contact, designated-expert, and registrant-person fields are dropped by design, and email addresses in free text are replaced with
[email removed]
Agent-friendly output:
- Misses are results, not errors: a lookup that finds nothing returns
found: falsewith anoticenaming the next step, an unknown RFC or draft returnsfound: falsewithguidance, and an invalid language tag returnsvalid: falsewith itsissues[]. A miss means IANA has no registration, not that a value is unused in practice - Uniform lookup contract: every lookup takes exactly one mode key and fails
mode_requiredotherwise;limitis 1–100, default 25, and the list modes (keyword,organization,description) page withoffsetand returnnext_offset, alongsidetotalCount,shown, andtruncated - Provenance on every registry response:
sourcenames the registry file,registry_updated(the registry's own last-updated date),fetched_at, andstale - Typed failures with recovery hints: every tool declares
upstream_unreadable(index_unreadablefor search) andpacer_shed, which carriesretryAfterwhen this server's own request queue is full
Getting started
Add the following to your MCP client configuration file.
Or with npx (no Bun required):
Or with Docker:
For Streamable HTTP, set the transport and start the server:
Prerequisites
- Bun v1.4.0 or higher (or Node.js v24+).
- No API key or account: IANA, the RFC Editor, and the IETF Datatracker are all keyless.
Installation
- Clone the repository:
- Navigate into the directory:
- Install dependencies:
- Configure environment (optional):
Configuration
The server reads no environment variables of its own. These framework settings apply:
See .env.example for the full list of framework overrides.
Running the server
Local development
-
Build and run the production version:
-
Run checks and tests:
Project structure
Development guide
See CLAUDE.md for development guidelines and architectural rules. The short version:
- Handlers throw, framework catches — no
try/catchin tool logic - Use
ctx.logfor logging; registry text is third-party, soformat()renders it through thequote()andinline()helpers - Register new tools in the barrel at
src/mcp-server/tools/definitions/index.ts - Wrap external API calls: validate raw → normalize to domain type → return output schema; never fabricate missing fields
Contributing
Issues are welcome. Run checks and tests before submitting:
License
This project is licensed under the Apache 2.0 License. See the LICENSE file for details.
IANA and the IETF Trust dedicate the protocol registries to the public domain under CC0 1.0 (licensing terms, joint statement of 10 November 2021). RFC documents are excluded from that statement; this server returns RFC metadata only, never RFC text. This project is independent of IANA, the IETF, and the RFC Editor.
來源:README.md,提交 1b2030f
工具
0版本歷史
1- v0.1.1最新Oct 1, 2026

