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&rvstartid=273421236
 * 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

Image information

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

Lists of pages

 * http://www.mediawiki.org/w/api.php?action=query&list=allpages&aplimit=5
 * http://www.mediawiki.org/w/api.php?action=query&list=allpages&aplimit=5&apnamespace=2
 * http://www.mediawiki.org/w/api.php?action=query&list=allpages&aplimit=5&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&gaplimit=5&gapnamespace=2&gapprefix=Catrope/&prop=revisions
 * http://www.mediawiki.org/w/api.php?action=query&generator=allpages&gaplimit=5&gapnamespace=2&gapprefix=Catrope/&prop=revisions&rvprop=content

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