User:Catrope/Wikimania/API requests

For how to do POST requests with jQuery, see this.

Main page with docs

 * http://en.wikipedia.org/w/api.php

Information about the wiki

 * http://en.wikipedia.org/w/api.php?action=query&meta=siteinfo
 * http://en.wikipedia.org/w/api.php?action=query&meta=siteinfo&siprop=general|namespaces|namespacealiases
 * http://es.wikipedia.org/w/api.php?action=query&meta=siteinfo&siprop=general|namespaces|namespacealiases
 * http://en.wikipedia.org/w/api.php?action=query&meta=userinfo&uiprop=groups|rights

Title normalization

 * http://en.wikipedia.org/w/api.php?action=query&titles=Image:Wiki.png|foo_bar_baz|Talk:Talk:Foo
 * http://en.wiktionary.org/w/api.php?action=query&titles=Image:Wiki.png|foo_bar_baz|Talk:Talk:Foo
 * http://es.wikipedia.org/w/api.php?action=query&titles=Image:Wiki.png|foo_bar_baz|Talk:Talk:Foo

Redirect resolution

 * http://en.wikipedia.org/w/api.php?action=query&titles=main_page&redirects
 * http://prototype.wikimedia.org/s/api.php?action=query&titles=foo&redirects

Information about pages

 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page&prop=info

Running multiple queries

 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page&prop=info|revisions

Limits and continuations

 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page&prop=info|revisions&rvlimit=5
 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page&prop=info|revisions&rvlimit=5&rvcontinue=queryContinueGoesHere
 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page&prop=info|revisions&rvlimit=max
 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page&prop=info|revisions&rvlimit=max&rvprop=content

Can't get multiple revisions of multiple pages

 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page|Albert_Einstein&prop=info|revisions&rvlimit=5
 * http://en.wikipedia.org/w/api.php?action=query&titles=Main_Page|Albert_Einstein&prop=info|revisions
 * TODO: Scrap this section?

Image information

 * http://en.wikipedia.org/w/api.php?action=query&titles=File:Frisian_Flag.png&prop=imageinfo
 * http://en.wikipedia.org/w/api.php?action=query&titles=File:Frisian_Flag.png&prop=imageinfo&iiprop=url
 * http://en.wikipedia.org/w/api.php?action=query&titles=File:Frisian_Flag.png&prop=imageinfo&iiprop=url&iiurlwidth=200
 * http://en.wikipedia.org/w/api.php?action=query&titles=File:Frisian_Flag.png&prop=imageinfo&iiprop=url&iiurlwidth=199

Lists of pages

 * http://www.mediawiki.org/w/api.php?action=query&list=allpages
 * http://www.mediawiki.org/w/api.php?action=query&list=allpages&apnamespace=2
 * http://www.mediawiki.org/w/api.php?action=query&list=allpages&apnamespace=2&apprefix=Catrope/

Generators

 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&prop=revisions
 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&gapnamespace=2&gapprefix=Catrope/&prop=revisions
 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&gapnamespace=2&gapprefix=Catrope/&prop=revisions&rvprop=content

Continuing generators

 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&gapnamespace=2&gapprefix=Catrope/&prop=revisions&rvprop=content&gapcontinue=queryContinueGoesHere
 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&gapnamespace=2&gapprefix=Catrope/&prop=revisions&rvprop=content&gaplimit=1
 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&gapnamespace=2&gapprefix=Catrope/&prop=revisions&rvprop=content&gaplimit=1&rvcontinue=queryContinueGoesHere
 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&gapnamespace=2&gapprefix=Catrope/&prop=revisions&rvprop=content&gaplimit=1&gapcontinue=queryContinueGoesHere

Editing pages

 * Get token and basetimestamp
 * http://www.mediawiki.org/w/api.php?action=query&titles=User:Catrope/Sandbox&prop=info|revisions&intoken=edit
 * The actual edit (needs POST request)
 * http://www.mediawiki.org/w/api.php?action=edit&title=User:Catrope/Sandbox&text=IT%20WORKS!&summary=API%20demonstration%20at%20Wikimania&token=tokenGoesHere&basetimestamp=timestampGoesHere
 * Appending text to pages
 * http://en.wikipedia.org/w/api.php?action=edit&title=WP:Sandbox&appendtext=API%20edit%20rules&summary=API%20demonstration%20at%20Wikimania&token=tokenGoesHere