AkashiDocs
Providers

Wikidata

The structured knowledge base behind Wikipedia: entity search and key facts for any person, place, organisation or thing.

ToolPriceWhat it does
wikidata/entity$0.001Key facts about one Wikidata entity: what it is, country, dates, place, people, population, website.
wikidata/search$0.001Find Wikidata entities (Q-ids) by name, with label and one-line description to tell them apart.

Inputs are JSON bodies, and unknown fields are rejected with 422 invalid_input (not charged). POST /v1/inspect with a tool's id returns the same input schema, plus the output schema.

Wikidata Entity Facts

wikidata/entity · $0.001 per call (local) · Knowledge & Reference

Key facts about one Wikidata entity: what it is, country, dates, place, people, population, website.

Reads one item (Q-id) and returns its label, description, aliases, Wikipedia link and a curated set of about 30 common properties (instance of, country, inception, birth/death, headquarters, CEO, population, area, official website, image…), with item values resolved to labels and their Q-ids kept for follow-ups. Only the best-ranked values are kept (up to 5 per property). It does not run SPARQL or list every property; for prose use wikipedia/summary. Find the Q-id with wikidata/search.

Related: wikidata/search, wikipedia/summary.

Input

FieldTypeRequiredDescription
idstringyesA Wikidata item id, e.g. 'Q7251'. Pattern ^[Qq][1-9][0-9]{0,11}$.
langstringnoLabel language, e.g. 'en', 'de', 'ja'. Pattern ^[a-z]{2,3}(-[a-z]{2,8})?$. Default "en".

Example

Input
{
  "id": "Q7251"
}
Run it with the CLI
node akashi.mjs run wikidata/entity --input '{"id":"Q7251"}'

wikidata/search · $0.001 per call (local) · Knowledge & Reference

Find Wikidata entities (Q-ids) by name, with label and one-line description to tell them apart.

Matches labels and aliases (prefix match, so 'Alan Tur' works) and returns each candidate's Q-id, label and description, e.g. to tell Paris the city from Paris Hilton. Pass the chosen id to wikidata/entity for its facts. It matches names, not facts: 'tallest building in Japan' will not work; use akashi/answer or wikipedia/search for questions.

Related: wikidata/entity, wikipedia/search.

Input

FieldTypeRequiredDescription
querystringyesA name or label, e.g. 'Alan Turing' or 'Kyoto'. 1–250 characters.
limitintegernoFrom 1 to 20. Default 5.
langstringnoLabel language, e.g. 'en', 'de', 'ja'. Pattern ^[a-z]{2,3}(-[a-z]{2,8})?$. Default "en".

Example

Input
{
  "query": "Alan Turing",
  "limit": 3
}
Run it with the CLI
node akashi.mjs run wikidata/search --input '{"query":"Alan Turing","limit":3}'

On this page