1

I found out that I can use:

https://en.wikipedia.org/w/api.php?format=json&action=query&prop=extracts&exintro=&explaintext=&titles=Stack%20Overflow

To retrieve the intro section of a Wikipedia page. But now I would like to get the URL of the same page.

Termininja
  • 6,620
  • 12
  • 48
  • 49
DynamicQ
  • 115
  • 2
  • 5
  • 11

1 Answers1

2

Use prop=info&inprop=url: https://en.wikipedia.org/wiki/Special:ApiSandbox#action=query&format=json&prop=extracts%7Cinfo&titles=Stack+Overflow&exintro=1&explaintext=1&inprop=url

In general, ApiSandbox is a good way to discover the capabilities of the API.

Tgr
  • 27,442
  • 12
  • 81
  • 118