Page MenuHomePhabricator

Overhaul QueryAbuseFilters
Closed, ResolvedPublic

Description

Parent task for AbuseFilter's QueryAbuseFilters API module (list=abusefilters).

Event Timeline

Here's a summary of changes introduced by this overhaul (listing minor breaking changes only).

  • The abfprop parameter now supports flags as a parameter value, used as a cover term for the older status, private, protected, and suppressed values. The latter four values are now deprecated. (T435834)
  • The enabled, deleted, suppressed, private, and protected properties in the response object were previously always empty strings. Now that the API module supports formatversion=2, they can be returned as booleans when requested. (T435835)
  • The actions property in the response object is now a JSON array instead of a plain string (regardless of formatversion). (T435835)

Before:

{
    "batchcomplete": "",
    "query": {
        "abusefilters": [
            {
                "id": 3,
                "actions": "disallow",
                "protected": ""
            }
        ]
    }
}

After (formatversion=2):

{
    "batchcomplete": true,
    "query": {
        "abusefilters": [
            {
                "id": 3,
                "actions": [
                    "disallow"
                ],
                "suppressed": false,
                "private": false,
                "protected": true,
                "enabled": false,
                "deleted": false
            }
        ]
    }
}

For announcement:

<translate>The <tvar name="1">[https://www.mediawiki.org/w/api.php?action=help&modules=query%2Babusefilters list=abusefilters]</tvar> query module will support <tvar name="2"><code>formatversion=2</code></tvar> along with minor breaking changes. For example, the <tvar name="3"><code>actions</code></tvar> property in the response object will no longer be a plain string but a JSON array. See [[phab:T435828#12327958]] for more details.</translate>

(I already added a user notice for the formatversion change, feel free to replace that with what you have above)

(I already added a user notice for the formatversion change, feel free to replace that with what you have above)

Oh, I thought you meant that you'd added the User-notice tag to the task. I didn't realize m:Special:Diff/31046426 had already been added. I appreciate that!

Dragoniez claimed this task.