Reputation: 1052
Wikipedia article United States presidential election, 2016 has page information which contains "Date of page creation" under "Edit history" section. How do I get this date through an API?
Upvotes: 2
Views: 3152
Reputation: 7036
For this goal you need to use action query with property revisions:
https://en.wikipedia.org/w/api.php?action=query&prop=revisions&rvlimit=1&rvprop=timestamp&rvdir=newer&titles=United States presidential election, 2016
where:
In your case the result will be: "2009-02-03T09:59:37Z"
→ 09:59, 3 February 2009
.
Upvotes: 7