Jump to content
  • 0

pfautoedit API function not working


kafir55

Question

I'm trying to write a python script to use the "pfautoedit" API call to update a number of pages in our wiki.  I'm able to connect to the wiki fine, but the calls to pfautoedit are returning a perplexing message:

"message": "The action you have requested is limited to users in the group: <a href=\"/mediawiki/index.php/TDS-Mediawiki:Users\" title=\"TDS-Mediawiki:Users\">Users</a>."

In short, it seems to complaining that the auth'd user (me) is not a member of the Users group.  Everyone is a member of this group, and for my own credentials, I have all rights assigned.  I don't get what it wants here. 

Any assistance would be appreciated.

Thx

 

Link to comment
Share on other sites

1 answer to this question

Recommended Posts

  • 0

You need to login to the API first (generally this is done by using a bot password generated at Special:BotPasswords). You will need to ensure the bot password used has the appropriate scopes to do whatever you want it to do (such as edit pages).

The login API will attempt to set some cookies. You are required to save these cookies in your python script and present them to all future API requests, so it can pull up your logged-in session.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.