Code snippets in Javascript demonstrating how to use various modules of the MediaWiki Action API
- API:Tokens
- tokens.js: get tokens for data modifying operations
- API:Logout
- logout.js: logout
- API:User contributions
- get_usercontribs.js: list user contributions
- API:Watchlist feed
- get_my_watchlist_feed.js: access an RSS feed of your own watchlist
- get_user_watchlist_feed.js: access an RSS feed of another user's watchlist
- API:Rsd
- rsd.js: export an RSD schema
- API:Parse
- parse.js: parse content of a page
- parse_wikitable.js: parse a section of its page and fetch its table data
- API:Categorymembers
- get_category_items.js: list twenty items in a category
- get_recent_category_items.js: get the ten articles most recently added to a category
- get_subcategories.js: get ten subcategories of a category
- API:Images
- get_page_images.js: get page images embedded on a page
- API:Redirects
- redirects.js: return redirects to the given page(s)
- API:Deletedrevs
- get_deleted_revisions.js: list deleted revisions from a user
- API:Revisions
- get_pages_revisions.js: get revision data of multiple pages
- get_filtered_page_revisions.js: get revision data of a page filtered by date and user
- API:Alldeletedrevisions
- get_alldeletedrevs.js: get all deleted revision data by a user or in a namespace.
- API:Links
- get_links.js: get links embedded on a page
- get_red_links.js: get the first twenty red links in a page
- API:Info
- get_info.js: get basic information about a page
- API:Allpages
- get_allpages.js: get all pages which fit a certain criteria, within a namespace
- API:Edit
- edit.js: edit a page
- API:Allimages
- get_allimages_by_date.js: list all images in a namespace, starting from a certain timestamp
- get_allimages_by_name.js: list all images in a namespace, starting from a certain filename
- API:Imageinfo
- get_imageinfo.js get information about an image file
- API:Categories
- get_categories.js: get categories associated with a page
- API:Allcategories
- get_allcategories.js: get all categories that fit certain criteria relating to their titles
- API:Allusers
- get_allusers.js: get a list of all registered users, as ordered by username
- get_allcategories.js: get all categories that fit certain criteria relating to their titles
- API:Backlinks
- get_backlinks.js: list pages which link to a certain page
- API:Random
- get_random.js: get a list of random pages
- API:Alllinks
- get_alllinks.js: list links to a namespace
- API:Embeddedin
- get_embedded_pages.js: get all page(s) that embed a page
- API:Mergehistory
- mergehistory.js: Merge the page revisions of Oldpage dating up to 2015-12-31T04:37:41Z into Newpage
- API:Contributors
- get_contributors.js: get request to list all logged-in contributors and count of anonymous contributors to a page
- API:Stashedit
- stashedit.js: Prepare an edit in shared cache
- API:Search
- search.js: search for a title or a text
- API:Geosearch
- geosearch.js: search for pages nearby
- geoimagesearch.js: search for pages nearby with images
- geocoordinates.js: obtain coordinates for wiki pages nearby
- API:Opensearch
- opensearch.js: fetch results in an opensearch format
- API:Prefixsearch
- prefixsearch.js: perform a prefix search for page titles
- API:Languagesearch
- languagesearch.js: search for a language
- API:Parameter information
- paraminfo.js: get information about another action API module and its parameters