Page MenuHomePhabricator

Allow &continue= in wbsearchentities
Open, Needs TriagePublic

Description

At the moment the wbsearchentities-API does not support the mediawiki-continue:

https://wikidata.org/w/api.php?format=xml&action=wbsearchentities&search=Daniel&language=de&limit=7&continue=

will return 7 entries and no continue-code (there are up to 12 entries for this query). While is it no problem here (because I could raise the limit to 50), there is a problem as soon as there are more than 50 entries.

Details

Related Gerrit Patches:
mediawiki/extensions/Wikibase : masterAdd wbsearchentities example with continue param

Event Timeline

DaBPunkt created this task.Jul 29 2016, 1:39 PM
Restricted Application added a project: Wikidata. · View Herald TranscriptJul 29 2016, 1:39 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Addshore closed this task as Invalid.Jul 31 2016, 8:14 PM
Addshore added a subscriber: Addshore.

The following will work / has been implemented for a while

https://wikidata.org/w/api.php?format=xml&action=wbsearchentities&search=Daniel&language=de&limit=7&continue=7

The response has a "search-continue" element which can be passed back to get the next bit of the list.

Change 302138 had a related patch set uploaded (by Addshore):
Add wbsearchentities example with continue param

https://gerrit.wikimedia.org/r/302138

DaBPunkt reopened this task as Open.Aug 3 2016, 1:37 PM

mm, but the search-continue-attribute is only working until you reach the limit of 50.

For example

https://www.wikidata.org/w/api.php?format=xml&action=wbsearchentities&search=M%C3%BCller&language=de&limit=5&continue=45

returns the attribute but

https://www.wikidata.org/w/api.php?format=xml&action=wbsearchentities&search=M%C3%BCller&language=de&limit=5&continue=50

does not. While I can increase the continue-parameter AFAIS, the API does not return the attribute anymore.

Change 302138 merged by jenkins-bot:
Add wbsearchentities example with continue param

https://gerrit.wikimedia.org/r/302138