Available from version 1.18.0
Used to add extra information to the SiteInfo general information output
Define function:
public static function onAPIQuerySiteInfoGeneralInfo( $module, &$result ) { ... }
Attach hook:

In extension.json:

	"Hooks": {
		"APIQuerySiteInfoGeneralInfo": "MyExtensionHooks::onAPIQuerySiteInfoGeneralInfo"

For MediaWiki ≤1.25:

$wgHooks['APIQuerySiteInfoGeneralInfo'][] = 'MyExtensionHooks::onAPIQuerySiteInfoGeneralInfo';
Called from:File(s): api/ApiQuerySiteinfo.php

For more information about attaching hooks, see Manual:Hooks.
For examples of extensions using this hook, see Category:APIQuerySiteInfoGeneralInfo extensions.


  • $module: ApiQuerySiteInfo module.
  • &$result: Result array for extra information to be added to.