API:Users
From MediaWiki.org
| This page is part of the MediaWiki API documentation. |
Quick overview:
- Quick start guide
- FAQ
- Tutorial
- Formats
- Error reporting
- Restricting usage
- Cross-site requests
- Authentication
- Queries
- Search suggestions
- Parsing wikitext and expanding templates
- Purging pages' caches
- Parameter information
- Changing wiki content
- Watchlist feed
- Wikidata
- Extensions
- Using the API in MediaWiki and extensions
- Miscellaneous
- Implementation
- Client code
- Asserting
| MediaWiki version: | 1.12 |
Get information about a list of users. This module cannot be used as a generator. This module is implemented by ApiQueryUsers.php.
Parameters[edit | edit source]
ususers: A list of user names to get information forustoken: Which tokens to getuserrights: Token for changing a user's group membership
usprop: Which properties to getblockinfo: Whether the user is blocked, by whom and whygroups: All groups the user belongs toimplicitgroups: All groups a user is automatically a member ofrights: All rights the user haseditcount: The number of edits the user has maderegistration: The time and date the user registered atemailable: Whether the user can and wants to receive e-mail through Special:Emailusergender: Tags the gender of the user. Returns "male", "female", or "unknown"
Example[edit | edit source]
Getting information about a list of users
| Result |
|---|
<?xml version="1.0"?> <api> <query> <users> <user name="1.2.3.4" invalid="" /> <user name="Catrope" editcount="153" registration="2007-06-07T16:36:03Z" emailable="" gender="male" /> <user name="Vandal01" missing="" /> <user name="Bob" editcount="4517" registration="2006-11-18T21:55:03Z" emailable="" gender="male"> <groups> <g>*</g> <g>user</g> <g>autoconfirmed</g> <g>reviewer</g> </groups> </user> </users> </query> </api> |
Error Codes[edit | edit source]
None