@pipeworx/kokkai-diet

Connect: https://gateway.pipeworx.io/kokkai-diet/mcp · Install: one-click buttons

Tools: 3

Speech-level full-text search of Japanese National Diet (parliament) proceedings back to 1947 — both chambers, every recorded speech with speaker, party, session, date, and a permalink.

Tools

  • search_speeches(query?, speaker?, speaker_group?, house?, from?, until?, start_record?, max_records?) — full-text speech search by keyword and/or speaker, with optional party/house/date-range filters. Paginated (max 100/request).
  • search_meetings(query?, meeting_name?, house?, from?, until?, start_record?, max_records?) — find meetings/sittings by name, chamber, or date range. Paginated (max 10/request — lower cap than speeches).
  • get_speech(speech_id) — fetch one speech’s full text and metadata by its speechID.

Auth

Keyless.

Data sources

Both are JSON/XML endpoints of the National Diet Library’s 国会会議録検索システム (Kokkai Kaigiroku Search System).

Traps for the next person

  • The API requires a real search anchor. from/until/nameOfHouse alone are accepted (200 OK) but silently return zero records — they’re filters, not search conditions. search_speeches requires query and/or speaker; search_meetings requires query, meeting_name, or house. A no-condition request 400s with (19007)検索条件を指定してください.
  • Per-request record caps differ by endpoint, and out-of-range values 400 rather than clamp. /api/speech: maximumRecords 1–100 (default 30). /api/meeting: maximumRecords 1–10 (default 3) — easy to miss since it’s a third the speech cap. Both tools here clamp client-side to the valid range, but a caller reading raw upstream docs will hit (19005)/(19006) if they don’t.
  • Never let a capped page read as the complete result. Both tools return next_start_record (from the API’s nextRecordPosition) and is_complete_result (true only when next_start_record is null). total (upstream numberOfRecords) is the true count — a caller must check it against returned before assuming they’ve seen everything.
  • Queries are Japanese-first. The full-text index is Japanese; partial-match works on Japanese substrings. English keywords (e.g. “semiconductors”) will under-match or return zero even when substantial Japanese-language debate exists on the topic — use Japanese keywords (e.g. “半導体”). Tool descriptions say this explicitly so an empty result isn’t misread as “no debate on this”.
  • search_speeches returns a speech preview (400 chars), not the full text — fetch the complete speech with get_speech(speech_id) using the speech_id from the search hit. This keeps list responses from blowing up on speeches that run thousands of characters.
  • 400 error bodies from the upstream carry a useful Japanese message + details array (e.g. (19005)maximumRecordsには1~100の値を指定してください) — this pack surfaces that text verbatim rather than a generic HTTP error, since it tells the caller exactly which parameter is wrong.

Tools

  • search_speeches — Full-text search of Japanese National Diet (parliament) speeches back to 1947, via the National Diet Library’s kokkai.ndl.go.jp API. Requires “query” and/or “speaker”. Returns speaker, party (speaker_
  • search_meetings — Search Japanese National Diet meetings/sittings (a meeting = one committee or plenary session on one day) by meeting name, chamber, or date range, via kokkai.ndl.go.jp. Requires at least one of “query
  • get_speech — Fetch one Diet speech’s full text and metadata by its speechID (from search_speeches’ “speech_id” field). Returns the complete speech text (search_speeches only gives a preview), speaker, party, house

Tools

  • get_speech — Fetch one Diet speech's full text and metadata by its speechID (from search_speeches' speech_id field). Returns the complete speech text (search_speeches only gives a preview), speaker, party, house,
  • search_meetings — Search Japanese National Diet meetings/sittings (a meeting = one committee or plenary session on one day) by meeting name, chamber, or date range, via kokkai.ndl.go.jp. Requires at least one of query
  • search_speeches — Full-text search of Japanese National Diet (parliament) speeches back to 1947, via the National Diet Library's kokkai.ndl.go.jp API. Requires query and/or speaker . Returns speaker, party (speaker_gro

Regenerated from source · build September 13, 2026