MCP server
JMAD runs a keyless MCP server at https://dnk.co/japan/mcp, using streamable HTTP. There is no auth handshake and no key to fetch first: an MCP client sends initialize, then calls tools.
Adding it to a client
Most MCP clients accept a remote server by URL. The exact settings screen differs, but the shape is the same everywhere: add a remote MCP server and give it https://dnk.co/japan/mcp. A generic config entry looks like this:
{
"mcpServers": {
"jmad": {
"url": "https://dnk.co/japan/mcp"
}
}
}Claude Desktop, Claude Code, Cursor, and ChatGPT all support adding a remote MCP server this way. Check your client's own documentation for where that setting lives; nothing about JMAD's server is client-specific.
Protocol versions and headers
The server speaks MCP 2025-11-25, 2025-06-18, 2025-03-26 and 2024-11-05; initialize negotiates one of them and the response carries it in the Mcp-Protocol-Version header, along with an Mcp-Session-Id. Under the two newest revisions the specification makes Mcp-Protocol-Version a required header on every request after initialize, and the server enforces that: a tools/list or tools/call without it is rejected with a 400 whose body is a JSON-RPC error naming the missing header. Every MCP client library sends it for you; you only meet this when driving the endpoint by hand with curl. Transport-level rejections (a missing or wrong Accept, an unsupported content type, a wrong method) likewise carry a JSON-RPC error body (code: -32600) rather than an empty response.
Server instructions
initialize returns an instructions string, which most clients hand to the model as context before its first tool call. It covers the usual workflow (resolve_area for slugs, search_assets to find buildings, get_asset for one record, get_owner_portfolio for one owner, get_reit_portfolio and list_reits for REITs, then the market and news tools for context), the ID and slug formats, units, paging limits, how to cite a value from its sources entry, and what invalid_argument and not_found mean. The text is guidance for the model. Every rule it states is also enforced by the tools.
Tools
The tools are all read-only and all backed by the same store as the REST API. Each one is annotated readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false, so a client that gates tool calls on annotations can run them without confirmation. Every input property in tools/list carries a description with an example.
resolve_area. Turns a place name into the prefecture, ward and machiAza slugs the other tools take. See Finding slugs with resolve_area below.
search_assets. Finds buildings and returns up to 10 compact, ranked rows (25 with limit), with total, hasMore and a hint. It carries every area-list filter, including owner, plus a point or box. Its parameters and result are its own, not the REST search's. See Searching with search_assets below.
get_asset. Takes a DNK Asset ID and returns a compact building record built for a model's context window, not the full page. Merged IDs resolve internally to the published survivor, whose ID is returned in id. The full document, every provenance object included, stays one hop away: apiUrl is GET /japan/api/v1/assets/{id} and url is the markdown twin.
get_assets. Takes ids, 1 to 25 DNK Asset IDs, and reads them in one call. See Reading many buildings with get_assets below.
get_asset_sources. Takes a DNK Asset ID and returns { "buildingId": "<canonical ID>", "sources": [...], "attribution": {...} }: the list of sources joined into that building, each with its source ID, source record ID, source URL, and the fields it supplied, plus the licence and credits those sources require (see licensing and attribution). The array is the same one GET /japan/api/v1/assets/{id}/sources returns; MCP structured content has to be an object, hence the wrapper. get_asset carries the same licence and credits as a one-line attribution string.
get_owner_portfolio. Takes an owner name and pages through every building recorded under that public owner, in the same compact rows as search_assets. See Owner portfolios below.
get_asset_reit. Takes a DNK Asset ID and returns the accepted REIT disclosures matched to that building: each publication's values exactly as disclosed (document.agreement), explicit missing states, and on request a citation to the source document for every field. Each publication is cut to the holdings matched to that building; the REIT's other holdings are left out. Optional period (an integer fiscal period) keeps one period, fields keeps agreement paths as in get_reit_portfolio below, and include adds revisions (every revision with its per-field citations, plus heads and, in a schemaVersion 2 document, the cited sources) and footing; both are left out by default. A publication prepared before agreements were stored has no document.agreement, so it keeps its revisions without being asked; with fields, only the revisions that cite those paths. Permissions and building matches are checked on every call. An empty publications list means no accepted disclosure. The unprojected publications stay available at GET /japan/api/v1/assets/{id}/reit. See REIT property history.
{ "tool": "get_asset_reit", "arguments": { "id": "DNK-JP-13-01630018", "period": 46, "fields": ["/interestAtEnd"], "include": ["revisions"] } }get_reit_portfolio. Takes slug (currently tokyu-reit) and an optional integer period from 1 through 2147483647. Returns { "portfolio": snapshot } for one accepted fiscal-period snapshot, or { "portfolio": null } when unavailable. Omit the period for the latest snapshot; an unavailable in-range period also selects the latest. Check selectedPeriod in the result. Acquisition-only and deliberately unlinked holdings retain their source-backed states without invented history or building links. Current permissions and per-building PLATEAU identity are checked on every call. Invalid periods fail with JSON-RPC -32602. See portfolio snapshots.
The MCP result is a projection of the snapshot, so a call carries only what it needs:
| Parameter | Type | Meaning |
|---|---|---|
holdingIds | list of UUIDs (up to 100) | Keep only these holdings, as in document.matches[].holdingId |
buildingIds | list of DNK Asset IDs (up to 100) | Keep the holdings matched to these buildings. Combined with holdingIds as a union |
fields | list of agreement paths (up to 50) | Keep only these paths in document.agreement, with their sub-paths: /cells keeps /cells/noi. derived and registers are not narrowed |
include | revisions, footing | Sections left out by default. revisions (with heads) holds holding names and acquisition and exit events |
A holding filter applies to every holding-keyed section (holdings, matches, agreement, derived, footing, withheldConsensus, places, registers and the holding ID lists). Organization and fund-period revisions always stay. An empty list filters nothing. A building the REIT does not hold returns empty holdings. A malformed ID or path is an invalid_argument tool error. For tokyu-reit's latest period the whole snapshot is about 1.3 MB, a default call about 860 KB and one building about 26 KB.
{ "tool": "get_reit_portfolio", "arguments": { "slug": "tokyu-reit", "buildingIds": ["DNK-JP-13-01630018"], "fields": ["/interestAtEnd", "/cells"] } }list_reits. Takes no arguments and lists the REITs whose accepted disclosures are matched to JMAD buildings: { "reits": [...], "hint": "..." }. Each entry has the REIT's securities code, its slug where JMAD knows one, nameJa and nameEn as disclosed, currentBuildings (matched to a holding the REIT holds now), formerBuildings (matched only to holdings it has sold), and portfolio, true when get_reit_portfolio serves the slug. Take slugs from here for the reitOrg filter and get_reit_portfolio rather than guessing them. Permissions are checked on every call. The list reads short stored columns only, never a disclosure document.
get_area_market_prices. Takes prefecture and ward slugs and returns the ward's sold prices, the same MarketAreaResult as GET /japan/api/v1/areas/{prefecture}/{ward}/market: median price and ¥/㎡ for land, land and building, and apartments over the latest three years and 20 quarters from MLIT transaction prices, with REINS closed prices as a separate series and a pooled prefecture baseline. Cells under the minimum trade count are suppressed. A ward with no market data comes back as a tool error whose text is not_found: no market data for <prefecture>/<ward>.
get_asset_news, get_area_market_news, get_national_market_news. Permission-checked news for a building (id), a ward (prefecture, ward) or Japan as a whole, each paged with an opaque cursor. The two market feeds take an optional types list of asset categories; an empty list means no filter. They match GET /japan/api/v1/assets/{id}/news, /areas/{prefecture}/{ward}/news and /market-news.
To keep tools/list small, the news tools, get_asset_reit and get_reit_portfolio advertise an outline of their output schema. The structured content they return is the full JSON, the same as the REST responses, except that get_asset_reit and get_reit_portfolio return the projections above.
The REIT results are large, so get_asset_reit and get_reit_portfolio send their data once, in structuredContent. Their text content is a short summary instead of a second, escaped copy of the JSON: what was returned (publications, holdings, periods, value counts, sections left out) and the REST URL of the same data. A client that shows the model only text content should read structuredContent for these two tools, or fetch that URL. Sessions that negotiate 2025-03-26 or 2024-11-05, which have no structuredContent, still receive the JSON as text. Every other tool returns its JSON in both places.
Finding slugs with resolve_area
resolve_area{ "tool": "resolve_area", "arguments": { "q": "渋谷", "limit": 2 } }| Parameter | Type | Meaning |
|---|---|---|
q | string | A place name in Japanese or romaji, such as 渋谷 or shibuya. Kana readings do not match |
prefecture | slug | Narrows q to a prefecture, or without q lists that prefecture's wards |
ward | slug | Narrows q to a ward, or without q lists that ward's machi-aza. A ward without prefecture is resolved nationwide |
limit | integer | Rows, 1 to 25, default 8 |
With q, matches are ordered with a ward ahead of its blocks, then by building count, and total counts every match. Without q, the tool lists the children of prefecture or ward by building count. With no arguments it lists the prefectures. Each row is { prefecture, ward?, machiAza?, nameJa?, buildingCount }, and the hint says how many rows matched and what to do next:
{
"items": [
{ "prefecture": "tokyo", "ward": "shibuya", "nameJa": "渋谷区", "buildingCount": 38059 },
{ "prefecture": "tokyo", "ward": "shibuya", "machiAza": "shibuya-1-chome", "nameJa": "渋谷1丁目", "buildingCount": 265 }
],
"total": 5,
"hint": "Showing 2 of 5 matching areas, best match first. Pass the slugs to search_assets or the area market tools."
}A ward slug that names no recorded ward returns an empty list with a hint to try q.
Searching with search_assets
search_assets{
"tool": "search_assets",
"arguments": { "ward": "chiyoda", "type": ["office"], "heightMin": 100 }
}Every parameter is optional, and filters combine with AND.
| Parameter | Type | Meaning |
|---|---|---|
q | string, up to 200 characters | Free text over names, addresses, aliases and DNK IDs, matched as on REST search (see matching) |
prefecture | slug | Prefecture, e.g. tokyo |
ward | slug | Municipality. Without prefecture it is resolved nationwide; a slug that names more than one municipality fails with ambiguous_area and the candidates |
machiAza | slug | Machi-aza within ward (or within prefecture when no ward is given) |
wards | slug list, up to 10 | Several whole municipalities searched as one area, e.g. ["minato", "chuo"]; combines with ward |
type | category list | Any of these asset categories. A category also matches the PLATEAU usage values it covers (field dictionary) |
has | list | All of owner (owner named), yearBuilt (year known), noConflict (no source conflict), venues (venues listed), reit (matched to any REIT holding, held now or before) |
reit | list of current, former | Matched to a REIT holding the REIT holds now (current) or has sold (former). Without reitOrg, any REIT |
reitOrg | slug list, up to 10 | Any of these REITs, by slug from list_reits, e.g. ["tokyu-reit"]. An unknown slug fails with invalid_argument |
owner | string | Exact Japanese public owner name: 三菱地所, not 三菱 or Mitsubishi Estate |
floorsMin, floorsMax | integer, 1 to 100 | Floors above ground |
heightMin, heightMax | number, 0 to 1,000 | Height in metres |
builtMin, builtMax | integer, 1850 to 2030 | Year built |
near | { lat, lon, radiusM } | Buildings whose centroid lies within radiusM of a WGS84 point. radiusM is more than 0 and at most 2,000, default 500 |
bbox | { west, south, east, north } | Buildings whose centroid lies in a WGS84 box, at most 5 km a side |
sort | relevance, distance, footprint, height, floors, built, name | Default: distance with near, relevance with q, otherwise footprint, largest first |
limit | integer, 1 to 25 | Rows per page, default 10 |
page | integer | Page, from 1 |
The server does not geocode: pass coordinates in near or bbox, not an address. near and bbox cannot be combined. A slug that is well formed but names no area with buildings is reported in the hint ("No municipality with buildings matches …"). If every area named is unknown, the search returns no rows. It never widens to all of Japan.
Ordering. relevance puts an exact name first, then a name that starts with the query, then names containing every term, then the other matches, with ties broken by footprint. distance orders nearest first, and each row then carries distanceM, whole metres from the point to the building's centroid. built is newest first. Asking for relevance without q, or distance without near, falls back to the default order.
The result. Each row is a flat summary. Absent values are left out, never sent as null. This is page 2 of { "ward": "chiyoda", "type": ["office"], "limit": 1 }:
{
"items": [
{
"id": "DNK-JP-13-01589270",
"nameJa": "大手町ビル",
"nameEn": "Otemachi Building",
"address": "東京都千代田区大手町一丁目",
"categories": ["business_facility"],
"heightM": 48.1,
"floorsAbove": 9,
"footprintM2": 10129.1,
"gfaM2": 111419.9,
"url": "https://dnk.co/japan/id/DNK-JP-13-01589270.md"
}
],
"total": 5149,
"totalCapped": false,
"page": 2,
"limit": 1,
"hasMore": true,
"hint": "Showing 2-2 of 5,149 by footprint. Next: page=3. Narrow with q, type, has, owner, reit or a floors/height/built range; get_asset for detail."
}A row holds id, nameJa, nameEn, address, categories (one entry per distinct use: the category, or the source's own value when it has none, such as PLATEAU's business_facility), heightM, floorsAbove, footprintM2, gfaM2, yearBuilt, owner, ownerSource, distanceM (with near only), reits and url, the markdown twin. Measurements are rounded to one decimal. ownerSource is { sourceUrl, retrievedAt } for the owner value, so you can cite an owner straight from the row. A row without an owner has neither key. reits appears only when a REIT's accepted disclosure is matched to the building: one { code, slug, current } entry per REIT, with slug left out when JMAD has none and current false when the REIT has sold its holding. get_reit_portfolio with the slug reads that REIT's values. The other row values carry no provenance: call get_asset or get_assets with the ids for sources, conflicts and estimates before you quote them.
Paging and the 1,000-row cap. hasMore says whether another page exists, and hint names the next page, the order used and the filters that narrow the result. Results stop at row 1,000, whatever the limit: a page past that point is empty and its hint says so. With q, near or bbox, counting also stops at 1,000, so total is 1000 with totalCapped: true; show it as "1,000+". Narrow the query rather than paging deep. A page past the last match returns no rows and a hint giving the full count.
Owner portfolios
{ "tool": "get_owner_portfolio", "arguments": { "owner": "三井不動産", "limit": 2 } }owner is matched exactly on the Japanese public owner name (三井不動産, not 三井 or Mitsui Fudosan), the same rule as the owner filter on search_assets, REST search and area lists. The result is { owner, items, total, page, limit, hasMore, hint }, with the same rows as search_assets, largest footprint first. limit is 1 to 25, default 10, and page starts at 1. total is an exact count, with no 1,000-row cap. An owner with no recorded buildings returns total: 0 and a hint restating the matching rule. The REST endpoint GET /japan/api/v1/owners/{name}/assets still returns full building records without paging.
Tool errors
A tool that cannot answer returns a normal JSON-RPC result with isError: true and one text part, whose text starts with a code:
| Code | When |
|---|---|
invalid_argument | A malformed ID or slug, or a search area over its limit. The text names the argument, the expected format and an example, and quotes what was sent, e.g. invalid_argument: ward must be a lowercase municipality slug (a-z, 0-9 and hyphens), e.g. minato; got "Shibuya". To fix it, call resolve_area with a place name (渋谷 or shibuya) to get the slugs. Fix the argument and call again |
ambiguous_area | A ward slug that matches more than one municipality, usually because no prefecture was given. The text lists the candidates (local-government code, Japanese and romaji name, building count); retry with a prefecture or call resolve_area |
not_found | A well-formed ID with no building, or a ward with no market data. Not a fault |
gone | A building that was retired from publication. The ID is never reused |
internal | A failure on our side. Retrying later is reasonable |
IDs and slugs are advertised as plain text and checked by the tool, so a model sees the reason instead of a protocol error that many clients never show it. A value outside a range the schema declares (limit: 26, floorsMin: 0, a string over 200 characters) is still rejected before the tool runs, as a JSON-RPC error with code -32602 naming the parameter and the allowed range.
Reading get_asset
get_asset{
"tool": "get_asset",
"arguments": { "id": "DNK-JP-13-01000000", "include": ["footprint"] }
}The structured content is a flat record, with dates as ISO-8601 strings and absent values left out rather than sent as null:
id,url,apiUrl, theprefecture,wardandmachiAzaslugs, andareaJa, the Japanese area name.fields: the present values only, keyed by field name. Areas in m² and heights in m are rounded to two decimals.fieldSources: one entry per field, withsourceIndexand, when they apply,estimated: trueandconflict(the losing value and its source).sources: one deduplicated list of{ source, sourceUrl, retrievedAt }. EverysourceIndexin the record, on fields,aliases,assetTypes,footprintandvenues, is a position in this array.aliasesandassetTypes(each type with itscategory),centroidas[lon, lat]to six decimals, andnearbybuildings with whole-metredistanceM.venueCountandphotoCount, so you know whether those sections are worth asking for.historyCountandhistory: the total number of history entries, and the latest five of them (recordedAt,kind,changedFields).recordedAt: when the page was last published.
include is an optional list that adds sections left out by default:
| Value | Adds |
|---|---|
footprint | The building outline, coordinates rounded to six decimals, with its sourceIndex |
history | Every history entry instead of the latest five |
venues | Venues inside the building: name, category, sourceIndex |
photos | Photos with absolute url, author, licence and sourcePageUrl |
The compact record drops what an agent rarely needs per call: each field's unit (the field name carries it, as in heightM or gfaM2), extraction method, confidence, tier, source record ID, inheritance and source classification code. When you need any of that, read apiUrl, which returns the same BuildingPage as the REST endpoint; see provenance and precedence for how to read it. A well-formed ID with no building behind it comes back as a tool error (isError: true) whose text starts with not_found, not as a protocol error.
Reading many buildings with get_assets
get_assets{ "tool": "get_assets", "arguments": { "ids": ["DNK-JP-13-01000000", "DNK-JP-13-99999999"] } }get_assets returns { "items": [...] } with one item per requested ID, in the order sent. An item is either { "id", "asset" }, where asset is the record get_asset returns without include, or { "id", "error": { "code", "message" } }, where code is invalid_argument, not_found or gone. One bad ID does not fail the others. id is the ID as you sent it. A merged ID resolves to its survivor, so asset.id can differ from it. For a footprint, full history, venues or photos, call get_asset for that building. To keep tools/list small, the outputSchema describes asset as a plain object. Its shape is the one documented under Reading get_asset.
Server card
The server advertises itself at /japan/mcp/server-card, returning JSON with name, description, version, the server URL, transport: "streamable-http", and authentication: { "required": false }. A client that discovers the server through the card knows before its first tool call that no key is coming.
NoteJMAD does not publish
/.well-known/oauth-protected-resource,/.well-known/mcp.jsonor/.well-known/mcp/server-card.json:/.well-known/is the host root, which belongs to the DNK marketing site, and there is nothing to protect and nothing to authorize; the server card'sauthentication.required: falseis the whole story.
Rate limits
The MCP surface shares the same fixed 60-second window as the REST API: 120 requests per minute, keyed on the same hashed client identifier described in authentication. Going over it returns a JSON-RPC 2.0 error object rather than the REST API's ApiProblem body, using the MCP error format:
{
"jsonrpc": "2.0",
"id": null,
"error": {
"code": -32000,
"message": "the mcp surface allows 120 requests per minute; retry after 12s"
}
}The response also carries a Retry-After header with the seconds to wait; unlike the REST API it does not carry X-RateLimit-Limit or X-RateLimit-Remaining on any response, success or 429. See rate limits and errors for how the three surfaces compare.
Request and session limits
Each server process admits up to 32 concurrent MCP requests. Excess requests receive HTTP 503 with Retry-After: 1; wait at least one second before retrying. This bound also covers clients that send their request bodies slowly.
MCP POST bodies are limited to 65,536 bytes, measured as received rather than by character count or a trusted Content-Length header. Larger bodies receive HTTP 413 with a JSON-RPC error. The complete body must arrive within 10 seconds or the server returns HTTP 408. Reduce oversized requests; do not retry the same oversized body.
The Mcp-Session-Id is not tied to one server process. Any process behind /japan/mcp can serve a session it has never seen, and a session survives a deploy or restart, so a client behind the load balancer keeps one ID for its whole conversation. A session expires 24 hours after initialization, however active it is. A process drops its working copy of a session after 15 minutes without requests and rebuilds it on the next one, so a pause costs nothing but that first request's latency. Send initialize again without the old Mcp-Session-Id after a 404 unknown-or-expired response. Initialization with an existing session ID is rejected with HTTP 400.
When finished, send DELETE to /japan/mcp with Mcp-Session-Id and the negotiated Mcp-Protocol-Version. Successful termination returns HTTP 204 with no body; treat the ID as spent and do not send it again. Version-header requirements also apply to DELETE. GET remains unsupported.
Each server process holds at most 256 sessions, including initializations in progress and sessions it is rebuilding. When capacity is full, new initializations receive HTTP 503 and Retry-After: 30. Wait at least 30 seconds before retrying.
Next
- Agent discovery for how a crawler or agent finds the server card and
/llms.txtwithout being told the URL directly. - Search and pagination for the REST search, whose text matching
search_assetsshares. - Rate limits and errors for how MCP tool errors compare with REST errors.
Connect from a building page
The homepage and area lists show Connect an agent with MCP in the Build with this data panel. Building records expose it in API & agent, also reachable through Use this data near the title. Expand the control to copy the server URL or generic URL-based JSON configuration. Client configuration formats vary; use the remote server option supported by your client.
Updated 13 days ago
