Herulee | 2 Mar 2010 09:58

Pywikipediabot login


Hello,

I want to configure the information about user in advance
Can we configure the login and password information of the user in
pywikipedia?

Thanx

--

-- 
View this message in context: http://old.nabble.com/Pywikipediabot-login-tp27753441p27753441.html
Sent from the WikiMedia API mailing list archive at Nabble.com.
Roan Kattouw | 2 Mar 2010 11:16
Picon

Re: Pywikipediabot login

2010/3/2 Herulee <heramb.forums <at> googlemail.com>:
>
> Hello,
>
> I want to configure the information about user in advance
> Can we configure the login and password information of the user in
> pywikipedia?
>
Probably. Pywikipediabot is a third-party framework that's not
directly associated with the MediaWiki API, it just interfaces with
it. You should ask the pywikipediabot people or read its
documentation.

Roan Kattouw (Catrope)
Diego Alcántara | 3 Mar 2010 17:57
Picon

XSD for API xml format

Hi all, I'm wondering if there is a XSD file describing the XML response 
given by the API. If there is no "official" XSd, does anyone have 
written one?

Best Regards,
Diego.
Roan Kattouw | 3 Mar 2010 18:29
Picon

Re: XSD for API xml format

2010/3/3 Diego Alcántara <diego.faz <at> gmail.com>:
> Hi all, I'm wondering if there is a XSD file describing the XML response
> given by the API. If there is no "official" XSd, does anyone have
> written one?
>
No. There are vague plans to have an automatically generated schema,
but no one's been poking at that yet.

Roan Kattouw (Catrope)
Diego Alcántara | 4 Mar 2010 20:59
Picon

Re: XSD for API xml format

Roan Kattouw escribió:
2010/3/3 Diego Alcántara <diego.faz <at> gmail.com>:
Hi all, I'm wondering if there is a XSD file describing the XML response given by the API. If there is no "official" XSd, does anyone have written one?
No. There are vague plans to have an automatically generated schema, but no one's been poking at that yet. Roan Kattouw (Catrope) _______________________________________________ Mediawiki-api mailing list Mediawiki-api <at> lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-api

For what I've seen, it would be quite difficult to have an XSD (either "automatically generated" or "manually written"), because much of the queries to the API return the same node structure (XPATH) with different meanings.

Anyway, Thank you for your time.
Best regards,
Diego.
_______________________________________________
Mediawiki-api mailing list
Mediawiki-api <at> lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api
Herulee | 5 Mar 2010 13:32

Page Locking


Hello

Is it possible to  lock the page through API?

Thanx

--

-- 
View this message in context: http://old.nabble.com/Page-Locking-tp27793348p27793348.html
Sent from the WikiMedia API mailing list archive at Nabble.com.
Roan Kattouw | 5 Mar 2010 14:15
Picon

Re: Page Locking

2010/3/5 Herulee <heramb.forums <at> googlemail.com>:
>
> Hello
>
> Is it possible to  lock the page through API?
>
http://www.mediawiki.org/wiki/API:Edit_-_Protect
Herulee | 5 Mar 2010 14:42

Re: Page Locking


It gives me the error

There seems to be a problem with your login session;
this action has been canceled as a precaution against session hijacking.
Please hit "back" and reload the page you came from, then try again.</p>
<p>You may view and change the protection level here for the page

Roan Kattouw-2 wrote:
> 
> 2010/3/5 Herulee <heramb.forums <at> googlemail.com>:
>>
>> Hello
>>
>> Is it possible to  lock the page through API?
>>
> http://www.mediawiki.org/wiki/API:Edit_-_Protect
> 
> _______________________________________________
> Mediawiki-api mailing list
> Mediawiki-api <at> lists.wikimedia.org
> https://lists.wikimedia.org/mailman/listinfo/mediawiki-api
> 
> 

--

-- 
View this message in context: http://old.nabble.com/Page-Locking-tp27793348p27793995.html
Sent from the WikiMedia API mailing list archive at Nabble.com.

_______________________________________________
Mediawiki-api mailing list
Mediawiki-api <at> lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api
Roan Kattouw | 5 Mar 2010 14:51
Picon

Re: Page Locking

2010/3/5 Herulee <heramb.forums <at> googlemail.com>:
>
> It gives me the error
>
> There seems to be a problem with your login session;
> this action has been canceled as a precaution against session hijacking.
> Please hit "back" and reload the page you came from, then try again.</p>
> <p>You may view and change the protection level here for the page
>
Use api.php?action=protect , not index.php?action=protect , and make
sure you're passing login cookies correctly.

Roan Kattouw (Catrope)
Andre Engels | 5 Mar 2010 14:54
Picon

Re: Pywikipediabot login

On Tue, Mar 2, 2010 at 9:58 AM, Herulee <heramb.forums <at> googlemail.com> wrote:

> I want to configure the information about user in advance
> Can we configure the login and password information of the user in
> pywikipedia?

The login information should be specified in a file called
user-config.py. This can have various elements, but the most common
are (using # for comments as is usual in Python)

family = 'wikipedia'    # Or whatever family your bot will (mainly) run on)
mylang = 'en'   # idem for the language
usernames['wikipedia']['en'] = "MyNameBot"

It is possible to store passwords in a file, but I myself prefer to run

login.py -all -pass:pwd

 with your bot account's password instead of 'pwd'. This will try to
login to all accounts using that password. After that you won't have
to think about passwords any more for a long time, because
pywikipediabot remembers cookies, and thus remains logged on.

--

-- 
André Engels, andreengels <at> gmail.com

_______________________________________________
Mediawiki-api mailing list
Mediawiki-api <at> lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api

Gmane