SlideShare a Scribd company logo
1 of 26
Download to read offline
Wikimedia APIsLucie-Aimée Kaffee
[[User:Frimelle]]
Find the slides here:
https://tinyurl.com/qemwbfh
Wikimedia APIs
Wikipedia
Wikidata
Wikimedia Commons
Wikiquote
Wikisource
...
Introduction to the APIs
of Wikimedia projects
MediaWiki
(Wikipedia)
MediaWiki
is the software behind the
Wikimedia projects like
Wikipedia
index.php
api.php
RESTbase
index.php
Get the content of a Wikipedia Page
→ as Wikitext
https://en.wikipedia.org/w/index.php?action=raw&title=Alan_Turing
→ as HTML
https://en.wikipedia.org/wiki/Alan_Turing?action=render
_Turing
api.php
→ every MediaWiki has an api, to be found at:
https://en.wikipedia.org/w/api.php
→ documentation:
https://www.mediawiki.org/wiki/API:Main_page
https://rest.wikimedia.org/en.wikipedia.org/v1/?doc#/
→ documentation: https://www.mediawiki.org/wiki/RESTBase
RESTbase
Wikidata
the free knowledge base with
14,958,963 data items that anyone
can edit
Short introduction
→ free knowledge base by the Wikimedia movement
→ structured data
→ user created content
→ linked data
→ people, places, events, …
→ powered by Wikibase (open source)
→ data: CC-0
https://www.wikidata.
org/wiki/Q7251
item
Qid
labels en label
de Bezeichner
…….....
statements
statement
property value
…….....
…….....
…….....
qualifiers
property value
property value
…….....
references reference property value
…….....
…….....
descriptions / aliases / sitelinks
WikidataDataModel
Accessing
Wikidata’s data
Per Item Access
API
SPARQL Endpoint
Wikidata Query (WDQ)
Dumps
https://www.wikidata.
org/wiki/Wikidata:
Data_access
Per Item Access
→ data of for single item can be retrieved via
http://www.wikidata.org/wiki/Special:EntityData/Q7251
→ to get the data of the item in .json format
http://www.wikidata.org/wiki/Special:EntityData/Q7251.json
→ other possible formats:
.rdf, .ttl or .nt
Wikidata API
→ get the data of a single item
https://www.wikidata.org/w/api.php?
action=wbgetentities&ids=Q7251&format=json
→ wbgetentities, wbgetclaims, wbsearchentites
→ Sandbox: wikidata.org/wiki/Special:ApiSandbox
→ additional documentation: mediawiki.org/wiki/Wikibase/API
SPARQL Endpoint
https://query.wikidata.org/
→ complex queries with SPARQL
→ SPARQL? SPARQL! http://tinyurl.
com/nlsoqxf
→ documentation: https://www.
mediawiki.
org/wiki/Wikidata_query_service/Use
r_Manual
→ example: All items, that have
their date of birth (P569) today
http://tinyurl.com/nfeskmf
Wikidata Query and Database Dumps
→ Wikidata Query (WDQ) helps to run
complex queries in another query
language
https://wdq.wmflabs.org/
→ there are Wikidata database dumps
in json (recommended), XML and RDF
https://www.wikidata.
org/wiki/Wikidata:Database_download
Wikimedia Commons
a database of 28,765,395 freely
usable media files to which anyone
can contribute
https://commons.wikimedia.org
Wikimedia Commons API
→ example image URL
https://upload.wikimedia.org/wikipedia/commons/1/17/LuciePixelated.png
→ get a certain image with a set size and metadata like the
license
https://tools.wmflabs.org/magnus-toolserver/commonsapi.php
→ documentation
https://commons.wikimedia.org/wiki/Commons:Commons_API
Examples
Wikidata Game
http://tools.wmflabs.org/wikidata-game/#
→ improve Wikidata’s data in a quick and simple game
Guess the Quote
http://fuzzle.me/guess-the-quote/
→ get your books from inventaire.io (which is build on
Wikidata) including Wikidata entity Id, title and cover link
to Wikimedia Commons
→ check the Item Ids of the books and get their Wikiquote
sitelink via the Wikidata API
→ get a random quote from Wikiquote using https://github.
com/natetyler/wikiquotes-api
Contact me!
lucie.kaffee@wikimedia.de
@frimelle
Thank you!
Presentation:
http://tinyurl.com/qemwbfh
Lucie-Aimée Kaffee
CC-BY-SA
numbers as of 23.10.15

More Related Content

Similar to Wikimedia Game Jam 20015: Wikimedia APIs

Wikipedia Day 2011 Talk
Wikipedia Day 2011 TalkWikipedia Day 2011 Talk
Wikipedia Day 2011 TalkMark Reynolds
 
Web2.0 2012 - lesson 5 - wiki
Web2.0 2012 - lesson 5 - wikiWeb2.0 2012 - lesson 5 - wiki
Web2.0 2012 - lesson 5 - wikiCarlo Vaccari
 
Open Knowledge Management
Open Knowledge ManagementOpen Knowledge Management
Open Knowledge ManagementFrieda Brioschi
 
DM110 - Week 3 - Wikis
DM110 - Week 3 - WikisDM110 - Week 3 - Wikis
DM110 - Week 3 - WikisJohn Breslin
 
MySQL at Wikipedia: How we do relational data at the Wikimedia Foundation
MySQL at Wikipedia: How we do relational data at the Wikimedia FoundationMySQL at Wikipedia: How we do relational data at the Wikimedia Foundation
MySQL at Wikipedia: How we do relational data at the Wikimedia FoundationJaime Crespo
 
Lessons learned from Semantic Wiki
Lessons learned from Semantic WikiLessons learned from Semantic Wiki
Lessons learned from Semantic WikiJie Bao
 
Wikidata and Semantic MediaWiki
Wikidata and Semantic MediaWiki Wikidata and Semantic MediaWiki
Wikidata and Semantic MediaWiki Bernhard Krabina
 
Enabling cross-wikis integration by extending the SIOC ontology
Enabling cross-wikis integration by extending the SIOC ontologyEnabling cross-wikis integration by extending the SIOC ontology
Enabling cross-wikis integration by extending the SIOC ontologyFabrizio Orlandi
 
Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...
Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...
Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...Artefactual Systems - AtoM
 
BAAC conference 2018 - Wikimedia keynote
BAAC conference 2018 - Wikimedia keynoteBAAC conference 2018 - Wikimedia keynote
BAAC conference 2018 - Wikimedia keynoteSandra Fauconnier
 
GDG Meets U event - Big data & Wikidata - no lies codelab
GDG Meets U event - Big data & Wikidata -  no lies codelabGDG Meets U event - Big data & Wikidata -  no lies codelab
GDG Meets U event - Big data & Wikidata - no lies codelabCAMELIA BOBAN
 
Linked open data with Semantic MediaWiki - ENDORSE 2021
Linked open data with Semantic MediaWiki - ENDORSE 2021Linked open data with Semantic MediaWiki - ENDORSE 2021
Linked open data with Semantic MediaWiki - ENDORSE 2021Bernhard Krabina
 
Semantic Tagging for the XWiki Platform with Zemanta and DBpedia
Semantic Tagging for the XWiki Platform with Zemanta and DBpediaSemantic Tagging for the XWiki Platform with Zemanta and DBpedia
Semantic Tagging for the XWiki Platform with Zemanta and DBpediaElena-Oana Tabaranu
 
2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projects
2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projects2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projects
2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projectsAndy Mabbett
 
Sgmp Wiki - GenNxt Wiki Concepts
Sgmp Wiki - GenNxt Wiki ConceptsSgmp Wiki - GenNxt Wiki Concepts
Sgmp Wiki - GenNxt Wiki Conceptsprasadburra
 
DBpedia Tutorial - Feb 2015, Dublin
DBpedia Tutorial - Feb 2015, DublinDBpedia Tutorial - Feb 2015, Dublin
DBpedia Tutorial - Feb 2015, Dublinm_ackermann
 

Similar to Wikimedia Game Jam 20015: Wikimedia APIs (20)

Wikipedia Day 2011 Talk
Wikipedia Day 2011 TalkWikipedia Day 2011 Talk
Wikipedia Day 2011 Talk
 
Web2.0 2012 - lesson 5 - wiki
Web2.0 2012 - lesson 5 - wikiWeb2.0 2012 - lesson 5 - wiki
Web2.0 2012 - lesson 5 - wiki
 
Open Knowledge Management
Open Knowledge ManagementOpen Knowledge Management
Open Knowledge Management
 
Fantastic Two wiki's
Fantastic Two wiki'sFantastic Two wiki's
Fantastic Two wiki's
 
Fantastic Two
Fantastic TwoFantastic Two
Fantastic Two
 
DM110 - Week 3 - Wikis
DM110 - Week 3 - WikisDM110 - Week 3 - Wikis
DM110 - Week 3 - Wikis
 
MySQL at Wikipedia: How we do relational data at the Wikimedia Foundation
MySQL at Wikipedia: How we do relational data at the Wikimedia FoundationMySQL at Wikipedia: How we do relational data at the Wikimedia Foundation
MySQL at Wikipedia: How we do relational data at the Wikimedia Foundation
 
Lessons learned from Semantic Wiki
Lessons learned from Semantic WikiLessons learned from Semantic Wiki
Lessons learned from Semantic Wiki
 
Wikidata and Semantic MediaWiki
Wikidata and Semantic MediaWiki Wikidata and Semantic MediaWiki
Wikidata and Semantic MediaWiki
 
Linked Open Data stuff
Linked Open Data stuffLinked Open Data stuff
Linked Open Data stuff
 
Enabling cross-wikis integration by extending the SIOC ontology
Enabling cross-wikis integration by extending the SIOC ontologyEnabling cross-wikis integration by extending the SIOC ontology
Enabling cross-wikis integration by extending the SIOC ontology
 
Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...
Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...
Technologie Proche: Imagining the Archival Systems of Tomorrow With the Tools...
 
BAAC conference 2018 - Wikimedia keynote
BAAC conference 2018 - Wikimedia keynoteBAAC conference 2018 - Wikimedia keynote
BAAC conference 2018 - Wikimedia keynote
 
GDG Meets U event - Big data & Wikidata - no lies codelab
GDG Meets U event - Big data & Wikidata -  no lies codelabGDG Meets U event - Big data & Wikidata -  no lies codelab
GDG Meets U event - Big data & Wikidata - no lies codelab
 
Linked open data with Semantic MediaWiki - ENDORSE 2021
Linked open data with Semantic MediaWiki - ENDORSE 2021Linked open data with Semantic MediaWiki - ENDORSE 2021
Linked open data with Semantic MediaWiki - ENDORSE 2021
 
Semantic Tagging for the XWiki Platform with Zemanta and DBpedia
Semantic Tagging for the XWiki Platform with Zemanta and DBpediaSemantic Tagging for the XWiki Platform with Zemanta and DBpedia
Semantic Tagging for the XWiki Platform with Zemanta and DBpedia
 
2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projects
2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projects2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projects
2014 05-21 poster on ORCID identifiers in Wikipedia, Wikidata & sister projects
 
Sgmp Wiki - GenNxt Wiki Concepts
Sgmp Wiki - GenNxt Wiki ConceptsSgmp Wiki - GenNxt Wiki Concepts
Sgmp Wiki - GenNxt Wiki Concepts
 
DBpedia Tutorial - Feb 2015, Dublin
DBpedia Tutorial - Feb 2015, DublinDBpedia Tutorial - Feb 2015, Dublin
DBpedia Tutorial - Feb 2015, Dublin
 
2007 03 12 Swecr 2
2007 03 12 Swecr 22007 03 12 Swecr 2
2007 03 12 Swecr 2
 

Recently uploaded

A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxComplianceQuest1
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...gurkirankumar98700
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
Active Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfActive Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfCionsystems
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
Test Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendTest Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendArshad QA
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfjoe51371421
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...MyIntelliSource, Inc.
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
Clustering techniques data mining book ....
Clustering techniques data mining book ....Clustering techniques data mining book ....
Clustering techniques data mining book ....ShaimaaMohamedGalal
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...OnePlan Solutions
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantAxelRicardoTrocheRiq
 

Recently uploaded (20)

A Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docxA Secure and Reliable Document Management System is Essential.docx
A Secure and Reliable Document Management System is Essential.docx
 
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
(Genuine) Escort Service Lucknow | Starting ₹,5K To @25k with A/C 🧑🏽‍❤️‍🧑🏻 89...
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
Active Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdfActive Directory Penetration Testing, cionsystems.com.pdf
Active Directory Penetration Testing, cionsystems.com.pdf
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
Test Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and BackendTest Automation Strategy for Frontend and Backend
Test Automation Strategy for Frontend and Backend
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdf
 
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
Steps To Getting Up And Running Quickly With MyTimeClock Employee Scheduling ...
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
Clustering techniques data mining book ....
Clustering techniques data mining book ....Clustering techniques data mining book ....
Clustering techniques data mining book ....
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
 
Exploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the ProcessExploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the Process
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service Consultant
 

Wikimedia Game Jam 20015: Wikimedia APIs