Skip to content

Library for interacting with the SiteMatrix extension, [READ-ONLY] split from https://github.com/addwiki/addwiki

License

Notifications You must be signed in to change notification settings

addwiki/mediawiki-sitematrix-api

Repository files navigation

mediawiki-sitematrix-api

GitHub issue custom search in repo

Installation

Use composer to install the library and all its dependencies:

composer require "addwiki/mediawiki-sitematrix-api:~0.1.0"

Example Usage

// Load all the stuff
require_once( __DIR__ . '/vendor/autoload.php' );

// Log in to a wiki
$api = new \Addwiki\Mediawiki\Api\Client\Action\MediawikiApi( 'http://localhost/w/api.php' );
$services = new \Mediawiki\SiteMatrix\Api\MediawikiSitematrixFactory( $api );

// Get the sitelist
$siteList = $services->newSiteListGetter()->getSiteList();