MediaWiki API help

This is an auto-generated MediaWiki API documentation page.

Documentation and examples: https://www.mediawiki.org/wiki/API

action=wbsgetsuggestions

(main | wbsgetsuggestions)
  • This module requires read rights.
  • Source: PropertySuggester
  • License: GPL-2.0-or-later

API module for getting suggestions of additional properties to add to a Wikibase entity. The API module is primarily intended for use by the suggester widget when users are editing Wikibase entities.

Parameters:
entity

Suggest properties for the given entity, based on existing list of properties that the entity has.

properties

Suggest additional properties for the given list of properties.

Separate values with | or alternative. Maximum number of values is 50 (500 for bots).
limit

Maximum number of results.

No more than 50 (500 for bots) allowed.
Type: integer or max
Default: 7
continue

Offset where to continue a search.

language

Language for result.

One of the following values: aa, ab, ace, ady, ady-cyrl, aeb, aeb-arab, aeb-latn, af, ak, aln, als, am, an, ang, anp, ar, arc, arn, arq, ary, arz, as, ase, ast, atj, av, avk, awa, ay, az, azb, ba, ban, bar, bat-smg, bbc, bbc-latn, bcc, bcl, be, be-tarask, be-x-old, bg, bgn, bh, bho, bi, bjn, bm, bn, bo, bpy, bqi, br, brh, bs, bto, bug, bxr, ca, cbk-zam, cdo, ce, ceb, ch, cho, chr, chy, ckb, co, cps, cr, crh, crh-cyrl, crh-latn, cs, csb, cu, cv, cy, da, de, de-at, de-ch, de-formal, din, diq, dsb, dtp, dty, dv, dz, ee, egl, el, eml, en, en-ca, en-gb, eo, es, es-formal, et, eu, ext, fa, ff, fi, fit, fiu-vro, fj, fo, fr, frc, frp, frr, fur, fy, ga, gag, gan, gan-hans, gan-hant, gcr, gd, gl, glk, gn, gom, gom-deva, gom-latn, gor, got, grc, gsw, gu, gv, ha, hak, haw, he, hi, hif, hif-latn, hil, ho, hr, hrx, hsb, ht, hu, hu-formal, hy, hz, ia, id, ie, ig, ii, ik, ike-cans, ike-latn, ilo, inh, io, is, it, iu, ja, jam, jbo, jut, jv, ka, kaa, kab, kbd, kbd-cyrl, kbp, kg, khw, ki, kiu, kj, kk, kk-arab, kk-cn, kk-cyrl, kk-kz, kk-latn, kk-tr, kl, km, kn, ko, ko-kp, koi, kr, krc, kri, krj, krl, ks, ks-arab, ks-deva, ksh, ku, ku-arab, ku-latn, kum, kv, kw, ky, la, lad, lb, lbe, lez, lfn, lg, li, lij, liv, lki, lmo, ln, lo, loz, lrc, lt, ltg, lus, luz, lv, lzh, lzz, mai, map-bms, mdf, mg, mh, mhr, mi, min, mk, ml, mn, mo, mr, mrj, ms, mt, mus, mwl, my, myv, mzn, na, nah, nan, nap, nb, nds, nds-nl, ne, new, ng, niu, nl, nl-informal, nn, no, nov, nrm, nso, nv, ny, nys, oc, olo, om, or, os, pa, pag, pam, pap, pcd, pdc, pdt, pfl, pi, pih, pl, pms, pnb, pnt, prg, ps, pt, pt-br, qu, qug, rgn, rif, rm, rmy, rn, ro, roa-rup, roa-tara, ru, rue, rup, ruq, ruq-cyrl, ruq-latn, rw, sa, sah, sat, sc, scn, sco, sd, sdc, sdh, se, sei, ses, sg, sgs, sh, shi, shi-latn, shi-tfng, shn, si, simple, sk, skr, skr-arab, sl, sli, sm, sma, sn, so, sq, sr, sr-ec, sr-el, srn, ss, st, stq, sty, su, sv, sw, szl, ta, tay, tcy, te, tet, tg, tg-cyrl, tg-latn, th, ti, tk, tl, tly, tn, to, tpi, tr, tru, ts, tt, tt-cyrl, tt-latn, tum, tw, ty, tyv, tzm, udm, ug, ug-arab, ug-latn, uk, ur, uz, uz-cyrl, uz-latn, ve, vec, vep, vi, vls, vmf, vo, vot, vro, wa, war, wo, wuu, xal, xh, xmf, yi, yo, yue, za, zea, zh, zh-classical, zh-cn, zh-hans, zh-hant, zh-hk, zh-min-nan, zh-mo, zh-my, zh-sg, zh-tw, zh-yue, zu
Default: en
context

Either item, reference or qualifier.

One of the following values: item, qualifier, reference
Default: item
include

Which suggestions to include: Per default only properties that might be added (non-deprecated, not yet present) will be suggested.

One of the following values: Can be empty, or all
Default: (empty)
search

Search for this text.

Default: (empty)
Examples:
Get suggestions for entity Q4
api.php?action=wbsgetsuggestions&entity=Q4 [open in sandbox]
Get suggestions for entity Q4 from rank 10 to 15
api.php?action=wbsgetsuggestions&entity=Q4&continue=10&limit=5 [open in sandbox]
Get suggestions for the property combination P21 and P31
api.php?action=wbsgetsuggestions&properties=P31|P21 [open in sandbox]
Get suggestions for the qualifiers that are used with P21
api.php?action=wbsgetsuggestions&properties=P21&context=qualifier [open in sandbox]
Get suggestions for the references that are used with P21
api.php?action=wbsgetsuggestions&properties=P21&context=reference [open in sandbox]