API:Purge

From MediaWiki.org

Jump to: navigation, search
Tools clipart.png This page is part of the MediaWiki API documentation.
MediaWiki API
MediaWiki version: 1.14

Contents

[edit] Purging pages' caches

You can purge the cache of one or more pages using action=purge.

[edit] Parameters

  • titles: A list of titles

[edit] Example

Purging the cache of Main Page, Nonexistent and Talk:

<?xml version="1.0" encoding="utf-8"?>
<api>
  <purge>
    <page ns="0" title="Main Page" purged="" />
    <page ns="0" title="Nonexistent" missing="" />
    <page title="Talk:" invalid="" />
  </purge>
</api>

[edit] Possible errors

  • code: cantpurge
    • info: Only users with the 'purge' right can purge pages via the API