[Mediawiki-api] Editing a page from Bash: copy-pasted token works, parsed token value from API doesnt

2017-01-31 Thread geoffreydebelie
Hi everyone, I'm trying to login using the MediaWiki API. This works if I copy the token manually in the code every time again. Using the token from the variable DOESNT work, but copy pasting the same token into the TOKEN= assignment (into the source code) DOES work! After that, I'm trying to

Re: [Mediawiki-api] Editing a page from Bash: copy-pasted token works, parsed token value from API doesnt

2017-01-31 Thread geoffreydebelie
at 12:08 AM, geoffreydebelie <geoffreydebe...@zoho.com> > wrote: > > ___ > Mediawiki-api mailing list > Mediawiki-api@lists.wikimedia.org > https://lists.wikimedia.org/mailman/listinfo/mediawiki-api > Hi everyone, > >

[Mediawiki-api] Newline in appendtext (action=edit)

2017-02-01 Thread geoffreydebelie
Hi, How do I include a newline at the start of "appendtext"? Do I use "\n"? Kind regards, Geoffrey De Belie window.onbeforeunload = function() {} ___ Mediawiki-api mailing list Mediawiki-api@lists.wikimedia.org

Re: [Mediawiki-api] Newline in appendtext (action=edit)

2017-02-01 Thread geoffreydebelie
On wo, 01 feb 2017 15:33:51 +0100 Bartosz Dziewoński wrote > MediaWiki expects a literal newline (%0A when URL-encoded). How to > include one in a string depends on the programming language you're > accessing the API from. > Thanks a lot :) I was using

Re: [Mediawiki-api] Logging in to use action=edit from within Bash

2017-01-30 Thread geoffreydebelie
better than doing this using clean Bash. Have a look at Manual:Pywikibot at MediaWiki.org. Best, Martin Urbanec Dne po 30. led 2017 20:20 uživatel geoffreydebelie geoffreydebe...@zoho.com napsal: ___ Mediawiki-api mailing list Mediawiki

[Mediawiki-api] Logging in to use action=edit from within Bash

2017-01-30 Thread geoffreydebelie
Hi, I'm trying to append text to a page as logged in MediaWiki user from within Bash. I tried this, but it's very outdated: https://www.mediawiki.org/wiki/API:Client_code/Bash I had updated it to this: http://pastebin.com/e9LF3UDa I want to use this:

Re: [Mediawiki-api] Logging in to use action=edit from within Bash

2017-01-30 Thread geoffreydebelie
> It's not really clear what you are asking. Are you trying to add an edit > request to that paste? What part of it is problematic? > > (In any case, you probably want to use bot passwords, not clientlogin. It > does work but is not ideal.) > &

Re: [Mediawiki-api] Logging in to use action=edit from within Bash

2017-01-30 Thread geoffreydebelie
at MediaWiki.org. Best, Martin Urbanec Dne po 30. led 2017 20:20 uživatel geoffreydebelie geoffreydebe...@zoho.com napsal: Hi, I'm trying to append text to a page as logged in MediaWiki user from within Bash. I tried this, but it's very outdated: https://www.mediawiki.org/wiki

Re: [Mediawiki-api] Client-login attemps unsuccesful

2017-01-19 Thread geoffreydebelie
On do, 19 jan 2017 15:22:11 +0100 Bartosz Dziewoński <matma@gmail.com> wrote > On 2017-01-19 15:15, geoffreydebelie wrote: > > Input (text/plain): > > logintoken=85af2296d03f8ce504123b7733b0a7ad5880c782+\\=Smile4ever=***=1 > > >

Re: [Mediawiki-api] Client-login attemps unsuccesful

2017-01-19 Thread geoffreydebelie
On do, 19 jan 2017 15:40:06 +0100 Bartosz Dziewoński wrote > You are sending it with two backslashes at the end, while the token > should only have one. > That's right, thanks! { "clientlogin": { "status": "PASS", "username": "Smile4ever" } }

Re: [Mediawiki-api] Client-login attemps unsuccesful

2017-01-19 Thread geoffreydebelie
On do, 19 jan 2017 16:25:03 +0100 Brad Jorsch (Anomie) <bjor...@wikimedia.org> wrote > On Thu, Jan 19, 2017 at 9:43 AM, geoffreydebelie <geoffreydebe...@zoho.com> > wrote: > However, I wonder why > > https://nl.wikipedia.org/w/api.php?act

Re: [Mediawiki-api] Clientlogin web service API

2018-02-22 Thread geoffreydebelie
Hi, The example for Bash is here: https://www.mediawiki.org/wiki/API:Client_code/Bash Kind regards Geoffrey De Belie On do, 22 feb 2018 04:51:36 +0100 Ren Wang renwang...@gmail.com wrote I have posted a similar message on the Wikimedia Developer Support, but I still

[Mediawiki-api] Getting the date of the first and last user contribution when all contributions are deleted revisions

2018-03-02 Thread geoffreydebelie
Hi, I'm having trouble getting the first and last user contribution when all contributions are deleted revisions. Returns the last user contribution for Smile4ever: https://nl.wikipedia.org/w/api.php?action=querylist=usercontribsucuser=Smile4everuclimit=1ucdir=olderformat=json How can I