Hello,
I am writing a Java program to extract the abstract of the wikipedia page
given the title of the wikipedia page. I have done some research and found
out that the abstract with be in rvsection=0
So for example if I want the abstract of 'Eiffel Tower" wiki page then I am
querying using the api in the following way.
http://en.wikipedia.org/w/api.php?action=query&prop=revisions&titles=Eiffel…
and parse the XML data which we get and take the wikitext in the tag <rev
xml:space="preserve"> which represents the abstract of the wikipedia page.
But this wiki text also contains the infobox data which I do not need. I
would like to know if there is anyway in which I can remove the infobox data
and get only the wikitext related to the page's abstract Or if there is any
alternative method by which I can get the abstract of the page directly.
Looking forward to your help.
Thanks in Advance
Aditya Uppu
When list=allusers is used with auactiveusers, a property 'recenteditcount'
is returned in the result. In bug 67301[1] it was pointed out that this
property is including various other logged actions, and so should really be
named something like "recentactions".
Gerrit change 130093,[2] merged today, adds the "recentactions" result
property. "recenteditcount" is also returned for backwards compatability,
but will be removed at some point during the MediaWiki 1.25 development
cycle.
Any clients using this property should be updated to use the new property
name. The new property will be available on WMF wikis with 1.24wmf12, see
https://www.mediawiki.org/wiki/MediaWiki_1.24/Roadmap for the schedule.
[1]: https://bugzilla.wikimedia.org/show_bug.cgi?id=67301
[2]: https://gerrit.wikimedia.org/r/#/c/130093/
--
Brad Jorsch (Anomie)
Software Engineer
Wikimedia Foundation
_______________________________________________
Mediawiki-api-announce mailing list
Mediawiki-api-announce(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce
The API has traditionally ignored values beyond the allowed limit,
returning a warning for this situation since 2008(!). It's long past time
for this error situation to actually raise an error, as requested in
https://phabricator.wikimedia.org/T41936.
This is happening in https://gerrit.wikimedia.org/r/433742. It should be
deployed to Wikimedia wikis with 1.32.0-wmf.6 or later, see
https://www.mediawiki.org/wiki/MediaWiki_1.32/Roadmap for the schedule.
Logs indicate that few clients on Wikimedia wikis are hitting the warning.
You can check your client by seeing if you're receiving a "Too many values
supplied for parameter" warning, or by using Special:ApiFeatureUsage for
your client's user agent and looking for a "too-many-X" code.
If your client is affected, the solution is to divide the values into
batches of the appropriate size. Generally the limit is 50 values for
clients without the apihighlimits right and 500 for clients with that
right. The limits for any particular parameter are documented in the
auto-generated help and are available in machine-readable format via
action=paraminfo.
--
Brad Jorsch (Anomie)
Senior Software Engineer
Wikimedia Foundation
_______________________________________________
Mediawiki-api-announce mailing list
Mediawiki-api-announce(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce
Hello maintainers
I was trying to use curl to POST something to an api.php when I get the
following error:
{"error":{"code":"notoken","info":"The "token" parameter must be
set.","*":"See https://wiki.octave.org/wiki/api.php for API usage.
Subscribe to the mediawiki-api-announce mailing list at <
https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce> for
notice of API deprecations and breaking changes."}}
My api.php is as follows: *https://wiki.octave.org/wiki/api.php
<https://wiki.octave.org/wiki/api.php>*
My POSTFIELDs are as follows: username=myusrname&
password=mypswd&rememberMe=1&logintoken=b86c77706c772328b4ece0e5dfde31
b25af83fcf%2B%5C&loginreturnurl=http%3A%2F%2Fwiki.octave.org%2Fwiki%2Fapi.
php
Note that I'm using libcurl (curl_easy_perform() and alike) for my work. Please
help me where I'm going wrong. I'll be really thankful to you.
Looking forward in anticipation.
Thanks and Regards
Sahil
> Date: Tue, 1 May 2018 15:46:20 -0400
> From: "Brad Jorsch (Anomie)" <bjorsch(a)wikimedia.org>
> To: "MediaWiki API announcements & discussion"
> <mediawiki-api(a)lists.wikimedia.org>
> Subject: Re: [Mediawiki-api] MediaWiki API v1.19.7; edit token
> request; empty response
>
>
> On Tue, May 1, 2018 at 3:38 PM, tom schulze <tom.schulze(a)posteo.de> wrote:
>
>
>> however all I get is an empty response.
>>
>> I created a gist
>> <https://gist.github.com/tomschulze/16fcdf8b88f285ab29365e4e558cb5f5>
>> with my python code.
>>
> You're missing parameters in params_edit_token. Try adding 'titles' with at
> least one title (doesn't have to exist) and 'intoken' with value 'edit'.
>
>
That did it! Thanks so much!
Hi everybody,
I am trying to receive an edit token for the MediaWiki 1.19 API, however
all I get is an empty response.
I created a gist
<https://gist.github.com/tomschulze/16fcdf8b88f285ab29365e4e558cb5f5>
with my python code. The script is successfully logging into the wiki
using my admin credentials prior to sending the request for the edit
token. The WRITE_API is enabled.
I read through the API docs
<MediaWiki%20API%20edit%20token%20request%20empty%20response> and
searched on stackoverflow. However, I could not find any answers. This
is really bugging me...
What am I doing wrong, why is the server not responding with the edit token?
Kind regards,
Tom