Wikidata APIunofficial
Public Wikidata entity search, selected item claims, and English label resolution.
- wikidata.org
all live 3 operations, checked by the installs that call them.
Seeded by the maintainers.
Try it
Set up API Anything for your agents:
npx -y api-anything setupThen ask your agent, which finds this site by itself, or call it from a shell:
api-anything pull wikidata
api-anything call wikidata getEntity id=Q42Operations
| Operation | Method | Login | Writes | Status |
|---|---|---|---|---|
getEntity(id) -> label, description, aliases, P31, P31ids, P569, P19, P106, P17, P131, enwikiRead English terms, selected displayed claims, and English Wikipedia title from an entity page. |
GET | no | no | Live0 confirmations · success unknown; last worked unknown |
getLabels(ids)Resolve entity and property IDs to English labels and descriptions. |
GET | no | no | Live0 confirmations · success unknown; last worked unknown |
searchEntities(q, type?) -> id, label, description, matchSearch English entity labels and aliases. |
GET | no | no | Live0 confirmations · success unknown; last worked unknown |
Notes
No account is needed. Wikidata's structured data is available under CC0; other content, including linked Wikipedia articles, can have different licenses.
searchEntitiesreturns at most 10 matches. Search defaults to items; lexeme searches can include matches in languages other than English.getEntityaccepts item IDs (Qfollowed by digits). It reads the English item page and returns only selected displayed statements: P31 (instance of), P569 (date of birth), P19 (place of birth), P106 (occupation), P17 (country), and P131 (located in administrative entity). Empty arrays mean no value was displayed for that property, not that no other claims exist. Values are displayed text; qualifiers, references and ranks are not included. P31ids contains links to the linked items and may not align one-to-one with P31. Some fields, including the English Wikipedia title, may be absent. Calendar markers may be joined to dates.getLabelsaccepts IDs separated by|, for exampleP31|Q5, and returns an object keyed by ID. Use it to resolve property IDs and item IDs, including IDs at the ends of P31 links. English labels or descriptions can be missing. Missing entities may appear as entries markedmissing, rather than causing the whole lookup to fail.
About these operations
Each operation is a request learned from Wikidata's own web pages: API Anything replays it over plain HTTP and falls back to a browser when it must. Read them as JSON.