MCP 서버

wikidata-mcp-server

io.github.cyanheads/wikidata-mcp-server

이 MCP로 할 수 있는 일

Searches and retrieves Wikidata entities, resolves external identifiers, and runs SPARQL queries over the Wikidata graph.

wikidata_get_entity
Get Wikidata Entity
Fetch a Wikidata entity (item or property) by QID or PID. The fields parameter narrows the upstream fetch, not just the response — asking for labels alone costs a fraction of the whole entity, so name the fields you need. Omit fields for all data; a well-connected item is large enough to overflow, and an oversized entity returns kind: "outline" — the field categories with their byte sizes — instead of the data. Follow its retrieval_notice literally rather than picking from sections yourself — it names a fields set already measured to fit, since category sizes are additive and requesting them all would overflow again; for a category too large to deliver whole (statements or sitelinks on a major item) it names the sibling tool that can narrow it. Q-IDs (e.g. Q76) fetch items; P-IDs (e.g. P31) fetch properties from the correct endpoint automatically. Use wikidata_get_statements for deep claim traversal with label resolution, and whenever an entity's statements are large — its properties parameter selects individual P-IDs, granularity fields does not carry.
읽기 전용 외부 접근 가능
입력 스키마
{'type': 'object', '$schema': 'https://json-schema.org/draft/2020-12/schema', 'required': ['id'], 'properties': {'id': {'type': 'string', 'minLength': 1, 'description': 'Q-ID (e.g., "Q76") or P-ID (e.g., "P31"). Case-insensitive â\x80\x94 normalized to uppercase.'}, 'fields': {'type': 'array', 'items': {'enum': ['labels', 'descriptions', 'aliases', 'statements', 'sitelinks'], 'type': 'string'}, 'description': 'Fields to include. Options: "labels", "descriptions", "aliases", "statements", "sitelinks". Narrows the upstream fetch as well as the response, so a narrow selection is markedly cheaper. Omit for all fields.'}, 'languages': {'type': 'array', 'items': {'type': 'string'}, 'description': 'Language codes to include in labels, descriptions, and aliases (e.g., ["en", "de"]). A requested language with no label of its own falls back to the entity\'s multilingual ("mul") value, returned under the requested code. Omit to return all available languages.'}}, 'additionalProperties': False}
출력 스키마
{'type': 'object', 'anyOf': [{'not': {'required': ['error']}, 'required': ['id', 'type', 'kind', 'fieldsReturned']}, {'required': ['error']}], '$schema': 'https://json-schema.org/draft/2020-12/schema', 'properties': {'id': {'type': 'string', 'description': 'Normalized entity ID (e.g., "Q76" or "P31").'}, 'kind': {'enum': ['full', 'outline'], 'type': 'string', 'description': 'full â\x80\x94 the requested field categories carry their data. outline â\x80\x94 the entity overflowed the inline byte budget, so sections lists the categories with their byte sizes instead, and retrieval_notice names how to fetch each one. The id and type are present either way.'}, 'type': {'type': 'string', 'description': 'Entity type: "item" or "property".'}, 'error': {'type': 'object', 'required': ['code', 'message'], 'properties': {'code': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': -9007199254740991, 'description': 'JSON-RPC error code for this failure.'}, 'data': {'type': 'object', 'properties': {'reason': {'type': 'string', 'examples': ['entity_not_found', 'invalid_id'], 'description': 'Machine-readable failure mode. Declared by this tool: `entity_not_found`: No entity exists at this ID â\x80\x94 either unassigned (resource-not-found) or out of range (invalid-path-parameter). `invalid_id`: ID format is not recognized as a Q-ID or P-ID. Other values are possible when a failure originates below the handler.'}, 'recovery': {'type': 'object', 'required': ['hint'], 'properties': {'hint': {'type': 'string'}}, 'description': 'Actionable next step for the caller.', 'additionalProperties': {}}, 'retryable': {'type': 'boolean', 'description': 'Whether retrying may succeed.'}}, 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Human-readable description of what went wrong.'}}, 'description': 'Present when the call failed. Absent on success.', 'additionalProperties': {}}, 'labels': {'type': 'object', 'description': 'Map of language code to label string (e.g., {"en": "Barack Obama", "de": "Barack Obama"}).', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'string'}}, 'aliases': {'type': 'object', 'description': 'Map of language code to list of alias strings (e.g., {"en": ["Barack H. Obama", "President Obama"]}).', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'array', 'items': {'type': 'string'}}}, 'sections': {'type': 'array', 'items': {'type': 'object', 'required': ['name', 'bytes'], 'properties': {'name': {'type': 'string', 'description': 'Section identifier â\x80\x94 pass in `sections` to retrieve it'}, 'bytes': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': 0, 'description': 'Serialized byte size of the section'}}, 'description': 'An available field category â\x80\x94 its name and the serialized byte size of its data.', 'additionalProperties': False}, 'description': "Present when kind = outline: the entity's field categories, largest first, each with its byte size. Sizes are additive â\x80\x94 a set of categories is only retrievable together if their total fits the budget, so follow retrieval_notice rather than requesting every name listed here."}, 'data_type': {'type': 'string', 'description': 'Property data type (e.g., "wikibase-item", "external-id"). Present on properties only.'}, 'sitelinks': {'type': 'object', 'description': 'Map of site code (e.g., "enwiki") to sitelink metadata with title, url, and badges fields.', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'object', 'properties': {}, 'additionalProperties': {}}}, 'statements': {'type': 'object', 'description': "Map of property ID to array of raw statement objects. Use wikidata_get_statements for resolved claims with label resolution, and whenever this entity's statements are large â\x80\x94 its properties parameter selects individual P-IDs, granularity fields does not carry.", 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'array', 'items': {'type': 'object', 'properties': {}, 'additionalProperties': {}}}}, 'descriptions': {'type': 'object', 'description': 'Map of language code to description string (e.g., {"en": "44th President of the United States"}).', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'string'}}, 'fieldsReturned': {'type': 'array', 'items': {'type': 'string'}, 'description': 'Which fields were requested. In outline mode these are the categories the outline covers, not data returned.'}, 'retrieval_notice': {'type': 'string', 'description': 'Present when kind = outline: the next call to make, and the authoritative one to follow. It names a literal fields set already measured to fit the budget, defers any category that would not fit alongside it, and for a category too large for fields to deliver at all names the sibling tool (wikidata_get_statements, wikidata_get_sitelinks) or the languages parameter that can narrow it.'}}, 'additionalProperties': False}
wikidata_get_labels
Get Wikidata Labels
Resolve one or more QIDs or PIDs to their human-readable labels and descriptions. Lightweight — returns no claim data. Supports up to 50 IDs per call (batched automatically). Designed for the common agent pattern: receive QIDs from a SPARQL query, then humanize them.
읽기 전용
입력 스키마
{'type': 'object', '$schema': 'https://json-schema.org/draft/2020-12/schema', 'required': ['ids'], 'properties': {'ids': {'type': 'array', 'items': {'type': 'string', 'minLength': 1}, 'maxItems': 50, 'minItems': 1, 'description': 'Q-IDs (e.g., "Q76") or P-IDs (e.g., "P31") to resolve. 1â\x80\x9350 IDs per call.'}, 'languages': {'type': 'array', 'items': {'type': 'string', 'minLength': 1}, 'default': ['en'], 'minItems': 1, 'description': 'BCP 47 language codes for returned labels and descriptions (e.g., ["en", "de", "fr"]). A language with no label of its own falls back to the entity\'s multilingual ("mul") value, returned under the requested code.'}}, 'additionalProperties': False}
출력 스키마
{'type': 'object', 'anyOf': [{'not': {'required': ['error']}, 'required': ['entities', 'found', 'notFound', 'languages']}, {'required': ['error']}], '$schema': 'https://json-schema.org/draft/2020-12/schema', 'properties': {'error': {'type': 'object', 'required': ['code', 'message'], 'properties': {'code': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': -9007199254740991, 'description': 'JSON-RPC error code for this failure.'}, 'data': {'type': 'object', 'properties': {'reason': {'type': 'string', 'examples': ['invalid_ids'], 'description': 'Machine-readable failure mode. Declared by this tool: `invalid_ids`: One or more IDs in the array are not valid Q-IDs or P-IDs. Other values are possible when a failure originates below the handler.'}, 'recovery': {'type': 'object', 'required': ['hint'], 'properties': {'hint': {'type': 'string'}}, 'description': 'Actionable next step for the caller.', 'additionalProperties': {}}, 'retryable': {'type': 'boolean', 'description': 'Whether retrying may succeed.'}}, 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Human-readable description of what went wrong.'}}, 'description': 'Present when the call failed. Absent on success.', 'additionalProperties': {}}, 'found': {'type': 'number', 'description': 'Count of IDs that returned data.'}, 'entities': {'type': 'object', 'description': 'Map of entity ID to labels and descriptions. IDs that were not found are absent.', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'object', 'required': ['labels', 'descriptions'], 'properties': {'labels': {'type': 'object', 'description': 'Map of language code to label string. Keys match the requested languages that have data.', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'string'}}, 'descriptions': {'type': 'object', 'description': 'Map of language code to description string. Keys match the requested languages that have data.', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'string'}}}, 'additionalProperties': False}}, 'notFound': {'type': 'array', 'items': {'type': 'string'}, 'description': 'IDs from the request that did not return data (not found or invalid).'}, 'languages': {'type': 'array', 'items': {'type': 'string'}, 'description': 'The language codes that were requested.'}}, 'additionalProperties': False}
wikidata_get_sitelinks
Get Wikidata Sitelinks
Fetch Wikipedia and Wikimedia project article URLs for a Wikidata item. A sitelink maps a site code (e.g., "enwiki") to a Wikipedia article title and URL. Major items can have 300+ sitelinks across languages. Use sites to filter to specific language editions, or wikis_only to return only Wikipedia links. Only Q-IDs (items) have sitelinks — properties (P-IDs) do not.
읽기 전용 외부 접근 가능 멱등성
입력 스키마
{'type': 'object', '$schema': 'https://json-schema.org/draft/2020-12/schema', 'required': ['id'], 'properties': {'id': {'type': 'string', 'minLength': 1, 'description': 'Q-ID of the item (e.g., "Q76"). Only items have sitelinks; properties (P-IDs) are not supported.'}, 'sites': {'type': 'array', 'items': {'type': 'string', 'minLength': 1}, 'description': 'Optional filter to specific site codes (e.g., ["enwiki", "frwiki", "dewiki"]). Omit to return all sitelinks.'}, 'wikis_only': {'type': 'boolean', 'default': False, 'description': 'When true, return only Wikipedia sitelinks (site codes ending in "wiki", e.g., "enwiki", "dewiki"). Excludes Wikisource, Wiktionary, Wikiquote, etc.'}}, 'additionalProperties': False}
출력 스키마
{'type': 'object', 'anyOf': [{'not': {'required': ['error']}, 'required': ['id', 'sitelinks', 'count']}, {'required': ['error']}], '$schema': 'https://json-schema.org/draft/2020-12/schema', 'properties': {'id': {'type': 'string', 'description': 'The Q-ID whose sitelinks were fetched.'}, 'count': {'type': 'number', 'description': 'Number of sitelinks returned.'}, 'error': {'type': 'object', 'required': ['code', 'message'], 'properties': {'code': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': -9007199254740991, 'description': 'JSON-RPC error code for this failure.'}, 'data': {'type': 'object', 'properties': {'reason': {'type': 'string', 'examples': ['entity_not_found', 'not_an_item'], 'description': 'Machine-readable failure mode. Declared by this tool: `entity_not_found`: No item exists at this Q-ID â\x80\x94 either unassigned or out of range. `not_an_item`: A P-ID was supplied â\x80\x94 only items (Q-IDs) have sitelinks. Other values are possible when a failure originates below the handler.'}, 'recovery': {'type': 'object', 'required': ['hint'], 'properties': {'hint': {'type': 'string'}}, 'description': 'Actionable next step for the caller.', 'additionalProperties': {}}, 'retryable': {'type': 'boolean', 'description': 'Whether retrying may succeed.'}}, 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Human-readable description of what went wrong.'}}, 'description': 'Present when the call failed. Absent on success.', 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Informational note when no sitelinks were found. Absent when sitelinks are present.'}, 'sitelinks': {'type': 'object', 'description': 'Map of site code to sitelink metadata. Empty when the entity has no matching sitelinks.', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'object', 'required': ['title'], 'properties': {'url': {'type': 'string', 'description': 'Full URL to the article. Omitted when unavailable.'}, 'title': {'type': 'string', 'description': 'Article title on that wiki.'}, 'badges': {'type': 'array', 'items': {'type': 'string'}, 'description': 'Quality badge QIDs (e.g., "Q17437798" = featured article).'}}, 'additionalProperties': False}}}, 'additionalProperties': False}
wikidata_get_statements
Get Wikidata Statements
Fetch property claims for a Wikidata entity with qualifier and reference detail. Value QIDs are resolved to human-readable labels by default. Use the properties parameter to fetch only specific P-IDs — omitting it returns every statement, and a well-connected item (a country, a major city) carries hundreds of properties: more than fits inline. An oversized set comes back as kind: "outline" — every available P-ID with its byte size, largest first — instead of the statements; re-call with the same id plus properties:[...] naming the P-IDs you want. Designed for fact verification: "what does Wikidata say about this entity's {property}?". Preferred-rank statements are the most current values.
읽기 전용 외부 접근 가능 멱등성
입력 스키마
{'type': 'object', '$schema': 'https://json-schema.org/draft/2020-12/schema', 'required': ['id'], 'properties': {'id': {'type': 'string', 'minLength': 1, 'description': 'Q-ID (e.g., "Q76") or P-ID of the entity to fetch statements for.'}, 'language': {'type': 'string', 'default': 'en', 'description': 'Language code for label resolution of QID values (e.g., "en", "de").'}, 'properties': {'type': 'array', 'items': {'type': 'string', 'minLength': 1}, 'description': 'P-IDs to fetch (e.g., ["P31", "P569", "P27"]). Omit to return all properties (may be large for major items).'}, 'resolve_labels': {'type': 'boolean', 'default': True, 'description': 'Resolve wikibase-item value QIDs to human-readable labels via a batched label call. Set to false to skip label resolution and return raw QIDs only (faster, smaller payload).'}}, 'additionalProperties': False}
출력 스키마
{'type': 'object', 'anyOf': [{'not': {'required': ['error']}, 'required': ['id', 'kind', 'propertyCount', 'statementCount', 'labelsResolved']}, {'required': ['error']}], '$schema': 'https://json-schema.org/draft/2020-12/schema', 'properties': {'id': {'type': 'string', 'description': 'The entity ID whose statements were fetched.'}, 'kind': {'enum': ['full', 'outline'], 'type': 'string', 'description': 'full â\x80\x94 statements carries the claims. outline â\x80\x94 the statement set overflowed the inline byte budget, so sections lists the P-IDs available instead; re-call with properties:[...] to retrieve specific ones. The counts below are reported either way.'}, 'error': {'type': 'object', 'required': ['code', 'message'], 'properties': {'code': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': -9007199254740991, 'description': 'JSON-RPC error code for this failure.'}, 'data': {'type': 'object', 'properties': {'reason': {'type': 'string', 'examples': ['entity_not_found', 'invalid_id', 'invalid_property'], 'description': 'Machine-readable failure mode. Declared by this tool: `entity_not_found`: No entity exists at this QID â\x80\x94 either unassigned or out of range. `invalid_id`: ID is not a valid Q-ID or P-ID format. `invalid_property`: A properties entry is not a valid P-ID format. Other values are possible when a failure originates below the handler.'}, 'recovery': {'type': 'object', 'required': ['hint'], 'properties': {'hint': {'type': 'string'}}, 'description': 'Actionable next step for the caller.', 'additionalProperties': {}}, 'retryable': {'type': 'boolean', 'description': 'Whether retrying may succeed.'}}, 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Human-readable description of what went wrong.'}}, 'description': 'Present when the call failed. Absent on success.', 'additionalProperties': {}}, 'sections': {'type': 'array', 'items': {'type': 'object', 'required': ['name', 'bytes'], 'properties': {'name': {'type': 'string', 'description': 'Section identifier â\x80\x94 pass in `sections` to retrieve it'}, 'bytes': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': 0, 'description': 'Serialized byte size of the section'}}, 'description': 'An available property â\x80\x94 its P-ID and the serialized byte size of its statements.', 'additionalProperties': False}, 'description': 'Present when kind = outline: the P-IDs this entity carries statements for, largest first. Copy names into the properties input to retrieve them.'}, 'statements': {'type': 'object', 'description': 'Map of property ID to array of normalized statements. Each statement has id, rank, property, value (with type-specific fields), and optional qualifiers and references arrays. Present in full mode; omitted in outline mode.', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'array', 'items': {'type': 'object', 'properties': {}, 'additionalProperties': {}}}}, 'propertyCount': {'type': 'number', 'description': 'Number of distinct properties â\x80\x94 those returned in full mode, those offered as sections in outline mode.'}, 'labelsResolved': {'type': 'boolean', 'description': 'True when QID values were resolved to labels. False when resolve_labels was set to false.'}, 'statementCount': {'type': 'number', 'description': "Total number of statement objects across all properties. Counted before any overflow, so it reports the entity's full statement volume in both modes."}, 'retrieval_notice': {'type': 'string', 'description': 'Present when kind = outline: how to re-call for specific properties.'}}, 'additionalProperties': False}
wikidata_resolve_external_id
Resolve Wikidata External ID
Look up a Wikidata entity by an external identifier such as a DOI, PubMed ID, ORCID iD, or OpenAlex ID. Returns match=<entity> on success, match=null when not found, and match=null with multipleMatches populated when a Wikidata data integrity issue causes more than one entity to claim the same external ID. Common cross-server join use cases: CrossRef DOI → Wikidata paper QID (P356), PubMed PMID → Wikidata paper QID (P698), ORCID → author QID (P496), OpenAlex ID → entity QID (P10283). The property must be one whose Wikidata data type is external-id — item-valued or media properties (e.g. P31 instance-of, P18 image) are rejected rather than returning an empty match. Known value normalization is applied automatically: surrounding whitespace is trimmed, identifier-resolver URL prefixes are stripped (https://doi.org/, https://pubmed.ncbi.nlm.nih.gov/, https://orcid.org/), DOIs are uppercased, PMID prefixes stripped, ORCID hyphens normalized.
읽기 전용 외부 접근 가능
입력 스키마
{'type': 'object', '$schema': 'https://json-schema.org/draft/2020-12/schema', 'required': ['property', 'value'], 'properties': {'value': {'type': 'string', 'minLength': 1, 'description': 'The external identifier value to look up (e.g., "10.1038/nature01234" for a DOI, "32283226" for a PubMed ID, "0000-0002-1825-0097" for an ORCID). A resolver URL is accepted for DOI, PubMed, and ORCID â\x80\x94 the prefix is stripped before lookup.'}, 'language': {'type': 'string', 'default': 'en', 'description': 'Language code for label and description in the response (e.g., "en", "de").'}, 'property': {'type': 'string', 'minLength': 1, 'description': 'P-ID of the external identifier property, whose Wikidata data type must be external-id (e.g., "P356" for DOI, "P698" for PubMed ID, "P496" for ORCID, "P10283" for OpenAlex ID, "P345" for IMDb ID). Properties of any other data type are rejected â\x80\x94 check an unfamiliar P-ID\'s data type with wikidata_get_entity.'}}, 'additionalProperties': False}
출력 스키마
{'type': 'object', 'anyOf': [{'not': {'required': ['error']}, 'required': ['match', 'property', 'value']}, {'required': ['error']}], '$schema': 'https://json-schema.org/draft/2020-12/schema', 'properties': {'error': {'type': 'object', 'required': ['code', 'message'], 'properties': {'code': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': -9007199254740991, 'description': 'JSON-RPC error code for this failure.'}, 'data': {'type': 'object', 'properties': {'reason': {'type': 'string', 'examples': ['invalid_property', 'not_external_id_property'], 'description': 'Machine-readable failure mode. Declared by this tool: `invalid_property`: Property ID is not in P+digits format. `not_external_id_property`: Property does not exist on Wikidata, or its data type is not external-id. Other values are possible when a failure originates below the handler.'}, 'recovery': {'type': 'object', 'required': ['hint'], 'properties': {'hint': {'type': 'string'}}, 'description': 'Actionable next step for the caller.', 'additionalProperties': {}}, 'retryable': {'type': 'boolean', 'description': 'Whether retrying may succeed.'}}, 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Human-readable description of what went wrong.'}}, 'description': 'Present when the call failed. Absent on success.', 'additionalProperties': {}}, 'match': {'anyOf': [{'type': 'object', 'required': ['id', 'label', 'description', 'url'], 'properties': {'id': {'type': 'string', 'description': 'Wikidata Q-ID of the matching entity (e.g., "Q12345").'}, 'url': {'type': 'string', 'description': 'Wikidata entity page URL (e.g., "https://www.wikidata.org/wiki/Q12345").'}, 'label': {'type': 'string', 'description': 'Display label in the requested language, or empty string if unavailable.'}, 'description': {'type': 'string', 'description': 'Short description in the requested language, or empty string if unavailable.'}}, 'additionalProperties': False}, {'type': 'null'}], 'description': 'Matching entity, or null when no Wikidata entity claims this external identifier (including the case where multipleMatches is populated). A null match is not proof of absence â\x80\x94 the Query Service backing this lookup lags the live wiki, so a recently added identifier may not be indexed yet.'}, 'value': {'type': 'string', 'description': 'The normalized value that was searched (may differ from input due to canonicalization).'}, 'property': {'type': 'string', 'description': 'The P-ID used for the lookup.'}, 'multipleMatches': {'type': 'array', 'items': {'type': 'object', 'required': ['id', 'label'], 'properties': {'id': {'type': 'string', 'description': 'Q-ID of a matching entity.'}, 'label': {'type': 'string', 'description': 'Display label of this match.'}}, 'description': 'One of the entities that claims this external identifier.', 'additionalProperties': False}, 'description': 'Present when more than one Wikidata entity claims this external ID (data integrity issue). match is null when this field is present. Inspect the list and select the correct QID manually.'}}, 'additionalProperties': False}
wikidata_search_entities
Search Wikidata Entities
Search Wikidata for items or properties by text query. Returns QIDs or PIDs with labels, descriptions, and match metadata indicating whether the hit was on a label or alias. Use type="item" for real-world concepts (people, places, works) and type="property" to find predicate P-IDs. The API returns no total count — pagination is offset-based with no result ceiling indicator.
읽기 전용 외부 접근 가능
입력 스키마
{'type': 'object', '$schema': 'https://json-schema.org/draft/2020-12/schema', 'required': ['query'], 'properties': {'type': {'enum': ['item', 'property'], 'type': 'string', 'default': 'item', 'description': 'Entity type to search. Use "item" for Q-IDs (people, places, concepts) or "property" for P-IDs (predicates).'}, 'limit': {'type': 'integer', 'default': 10, 'maximum': 50, 'minimum': 1, 'description': 'Maximum number of results to return. Range: 1â\x80\x9350.'}, 'query': {'type': 'string', 'minLength': 1, 'description': 'Search terms to match against entity labels, aliases, and descriptions.'}, 'offset': {'type': 'integer', 'default': 0, 'maximum': 9007199254740991, 'minimum': 0, 'description': 'Pagination offset. Start at 0; increment by limit to page through results.'}, 'language': {'type': 'string', 'default': 'en', 'description': 'BCP 47 language code for returned labels and descriptions (e.g., "en", "de", "zh").'}}, 'additionalProperties': False}
출력 스키마
{'type': 'object', 'anyOf': [{'not': {'required': ['error']}, 'required': ['results', 'effectiveQuery', 'searchType', 'language', 'shown', 'cap']}, {'required': ['error']}], '$schema': 'https://json-schema.org/draft/2020-12/schema', 'properties': {'cap': {'type': 'number', 'description': 'The limit parameter in effect.'}, 'error': {'type': 'object', 'required': ['code', 'message'], 'properties': {'code': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': -9007199254740991, 'description': 'JSON-RPC error code for this failure.'}, 'data': {'type': 'object', 'properties': {'reason': {'type': 'string', 'description': 'Machine-readable failure mode.'}, 'recovery': {'type': 'object', 'required': ['hint'], 'properties': {'hint': {'type': 'string'}}, 'description': 'Actionable next step for the caller.', 'additionalProperties': {}}, 'retryable': {'type': 'boolean', 'description': 'Whether retrying may succeed.'}}, 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Human-readable description of what went wrong.'}}, 'description': 'Present when the call failed. Absent on success.', 'additionalProperties': {}}, 'shown': {'type': 'number', 'description': 'Number of results returned on this page.'}, 'notice': {'type': 'string', 'description': 'Recovery hint when results are empty â\x80\x94 echoes filters and suggests how to broaden. Absent when results are present.'}, 'results': {'type': 'array', 'items': {'type': 'object', 'required': ['id', 'label', 'description', 'match'], 'properties': {'id': {'type': 'string', 'description': 'Q-ID (e.g., "Q76") or P-ID (e.g., "P31") of the entity.'}, 'label': {'type': 'string', 'description': 'Display label in the requested language, or empty string if unavailable.'}, 'match': {'type': 'object', 'required': ['type', 'language'], 'properties': {'type': {'type': 'string', 'description': 'Match type: "label" for a direct label hit, "alias" for an alias hit.'}, 'language': {'type': 'string', 'description': 'Language of the matched string.'}}, 'description': 'Metadata about how this result matched the query.', 'additionalProperties': False}, 'description': {'type': 'string', 'description': 'Short description in the requested language, or empty string if unavailable.'}}, 'description': 'A single search result with entity ID, label, description, and match metadata.', 'additionalProperties': False}, 'description': 'Ranked list of matching entities. Empty when no results found.'}, 'language': {'type': 'string', 'description': 'The language used for label and description display.'}, 'truncated': {'type': 'boolean', 'description': 'True when results were capped at the limit. The Wikidata search API returns no total count â\x80\x94 use offset pagination to retrieve more.'}, 'searchType': {'type': 'string', 'description': 'The entity type that was searched ("item" or "property").'}, 'effectiveQuery': {'type': 'string', 'description': 'The search query that was executed.'}}, 'additionalProperties': False}
wikidata_sparql_query
Wikidata SPARQL Query
Execute a SPARQL SELECT query against the Wikidata Query Service. Full graph power: multi-hop traversals, aggregations, subqueries, OPTIONAL, FILTER, UNION, BIND. Standard Wikidata prefixes (wd:, wdt:, p:, ps:, pq:, wikibase:, bd:) are auto-injected. The wikibase:label SERVICE is also auto-injected when language is set and the query includes ?<var>Label variables — so you can use ?itemLabel without writing the boilerplate. Hard server timeout is 60s; use LIMIT to keep queries fast. Bindings use the SPARQL 1.1 JSON format: each value is { type, value, "xml:lang"? }. Use wikidata_get_labels to humanize QID results from this tool.
읽기 전용 외부 접근 가능
입력 스키마
{'type': 'object', '$schema': 'https://json-schema.org/draft/2020-12/schema', 'required': ['query'], 'properties': {'query': {'type': 'string', 'minLength': 1, 'description': 'SPARQL SELECT query. Must be a SELECT query (not CONSTRUCT/DESCRIBE/ASK). Standard prefixes (wd:, wdt:, p:, ps:, pq:, wikibase:, bd:) are injected automatically. Example: SELECT ?item ?itemLabel WHERE { ?item wdt:P31 wd:Q146. } LIMIT 10'}, 'timeout': {'type': 'integer', 'default': 30, 'maximum': 55, 'minimum': 1, 'description': 'Client-side timeout in seconds (1â\x80\x9355). Capped at 55s â\x80\x94 the Wikidata server hard limit is 60s.'}, 'language': {'type': 'string', 'default': 'en', 'description': 'Language for the wikibase:label SERVICE (e.g., "en", "de"). Controls the language of ?<var>Label variables. Set to "" to suppress label SERVICE injection.'}}, 'additionalProperties': False}
출력 스키마
{'type': 'object', 'anyOf': [{'not': {'required': ['error']}, 'required': ['results', 'variables', 'truncated', 'totalCount']}, {'required': ['error']}], '$schema': 'https://json-schema.org/draft/2020-12/schema', 'properties': {'error': {'type': 'object', 'required': ['code', 'message'], 'properties': {'code': {'type': 'integer', 'maximum': 9007199254740991, 'minimum': -9007199254740991, 'description': 'JSON-RPC error code for this failure.'}, 'data': {'type': 'object', 'properties': {'reason': {'type': 'string', 'examples': ['parse_error', 'timeout', 'throttled'], 'description': 'Machine-readable failure mode. Declared by this tool: `parse_error`: SPARQL syntax error â\x80\x94 the query could not be parsed. `timeout`: Query exceeded the client-side timeout. `throttled`: Wikidata SPARQL endpoint is rate-limited (60 req/min, 5 concurrent per IP). Other values are possible when a failure originates below the handler.'}, 'recovery': {'type': 'object', 'required': ['hint'], 'properties': {'hint': {'type': 'string'}}, 'description': 'Actionable next step for the caller.', 'additionalProperties': {}}, 'retryable': {'type': 'boolean', 'description': 'Whether retrying may succeed.'}}, 'additionalProperties': {}}, 'message': {'type': 'string', 'description': 'Human-readable description of what went wrong.'}}, 'description': 'Present when the call failed. Absent on success.', 'additionalProperties': {}}, 'notice': {'type': 'string', 'description': 'Recovery hint when no results returned â\x80\x94 suggests checking query logic or broadening filters. Absent on non-empty results.'}, 'results': {'type': 'array', 'items': {'type': 'object', 'propertyNames': {'type': 'string'}, 'additionalProperties': {'type': 'object', 'properties': {}, 'additionalProperties': {}}}, 'description': 'Array of result bindings. Each row maps variable names to binding objects with { type, value, "xml:lang"?, datatype? } fields.'}, 'truncated': {'type': 'boolean', 'description': 'True when the row count equals 10,000 â\x80\x94 the Wikidata/Blazegraph server-side cap â\x80\x94 indicating the result set was likely truncated. False otherwise. Add a LIMIT clause to avoid hitting the cap. Note: the SPARQL endpoint does not expose an explicit truncation flag; this is an inferred signal.'}, 'variables': {'type': 'array', 'items': {'type': 'string'}, 'description': 'Variable names returned by the SELECT clause.'}, 'totalCount': {'type': 'number', 'description': 'Number of result rows returned.'}}, 'additionalProperties': False}
추가됨
wikidata_resolve_external_id
2026년 9월 17일 12:41 PM
추가됨
wikidata_sparql_query
2026년 9월 17일 12:41 PM
추가됨
wikidata_get_sitelinks
2026년 9월 17일 12:41 PM
추가됨
wikidata_get_statements
2026년 9월 17일 12:41 PM
추가됨
wikidata_get_labels
2026년 9월 17일 12:41 PM
추가됨
wikidata_get_entity
2026년 9월 17일 12:41 PM
추가됨
wikidata_search_entities
2026년 9월 17일 12:41 PM