MediaWiki API help

This is an auto-generated MediaWiki API documentation page.

Documentation and examples: https://www.mediawiki.org/wiki/API

list=blocks (bk)

(main | query | blocks)
  • Denna modul kräver läsrättigheter.
  • Source: MediaWiki
  • License: GPL-2.0+

Lista alla blockerade användare och IP-adresser.

Parametrar:
bkstart

The timestamp to start enumerating from.

Type: timestamp (allowed formats)
bkend

The timestamp to stop enumerating at.

Type: timestamp (allowed formats)
bkdir

In which direction to enumerate:

newer
List oldest first. Note: bkstart has to be before bkend.
older
List newest first (default). Note: bkstart has to be later than bkend.
Ett av följande värden: newer, older
Default: older
bkids

List of block IDs to list (optional).

Type: list of integers
Separate values with |. Maximum number of values is 50 (500 for bots).
bkusers

List of users to search for (optional).

Type: list of user names
Separate values with |. Maximum number of values is 50 (500 for bots).
bkip

Get all blocks applying to this IP address or CIDR range, including range blocks. Cannot be used together with bkusers. CIDR ranges broader than IPv4/16 or IPv6/19 are not accepted.

bklimit

The maximum number of blocks to list.

Inte mer än 500 (5 000 för robotar) tillåts.
Type: integer or max
Default: 10
bkprop

Vilka egenskaper att hämta.

id
Lägger till ID på blocket.
user
Lägger till användarnamn för den blockerade användaren.
userid
Lägger till användar-ID för den blockerade användaren.
by
Adds the username of the blocking user.
byid
Adds the user ID of the blocking user.
timestamp
Lägger till en tidsstämpel för när blockeringen gavs.
expiry
Lägger till en tidsstämpel för när blockeringen går ut.
reason
Lägger till de skäl som angetts för blockeringen.
range
Lägger till intervallet av IP-adresser som berörs av blockeringen.
flags
Tags the ban with (autoblock, anononly, etc.).
Värden (separerade med |): id, user, userid, by, byid, timestamp, expiry, reason, range, flags
Default: id|user|by|timestamp|expiry|reason|flags
bkshow

Show only items that meet these criteria. For example, to see only indefinite blocks on IP addresses, set bkshow=ip|!temp.

Värden (separerade med |): account, !account, temp, !temp, ip, !ip, range, !range
bkcontinue

When more results are available, use this to continue.

Examples:
Lista blockeringar.
api.php?action=query&list=blocks [open in sandbox]
Lista blockeringar av användarna Alice och Bob.
api.php?action=query&list=blocks&bkusers=Alice|Bob [open in sandbox]