List of steps to reproduce
- Query the API with a username that is too similar to an existing one: https://meta.wikimedia.org/w/api.php?action=query&list=users&ususers=Rages0ss&usprop=cancreate&format=json&origin=*
What happens?:
- The response looks like this:
{"batchcomplete":"","query":{"users":[{"name":"Rages0ss","missing":"","cancreateerror":[{"message":"$1","params":["The username "Rages0ss" is too similar to the following username:<ul><li>Ragesoss</li></ul>Please choose another username."],"code":"_1","type":"error"}]}]}}
Unlike other error responses (for example, when a username is invalid), this cancreaterror does not include a meaningful code attribute. Instead of _1, it should be something like toosimilar.