How to get image url in wiki api?

When I call the wiki APIs to access image URLs, I get image URLs like this,

File:Ad-tech London 2010 (2).JPG 

How to get the correct URL for this file from the wiki API?

+5
source share
2 answers

You can get property URLs from an imageinfo request, for example:

 https://en.wikipedia.org/w/api.php?action=query&titles=File:Test.jpg&prop=imageinfo&iilimit=50&iiend=2007-12-31T23:59:59Z&iiprop=timestamp|user|url 

See the MediaWiki API Help for more information.

+3
source

All Articles