| Lucas_Werkmeister_WMDE created this task. Lucas_Werkmeister_WMDE added projects: Wikidata, Lexicographical data. |
TASK DESCRIPTION
You can create a form using wbeditentity:
(new mw.Api()).postWithToken('csrf', { action:'wbeditentity', 'new': 'form', data: JSON.stringify({ lexemeId: 'L1', representations: { en: { language: 'en', value: 'test form' } }, grammaticalFeatures: [] }) })
However, the API response doesn’t contain the full entity data:
{ "entity": { "claims": {}, "id": null, "type": "form", "lastrevid": 1449 }, "success": 1 }It doesn’t even contain the form ID, which would otherwise at least let you issue a wbgetentities request for the data. (You can try to work around this by getting the full entity data for the lexeme and assuming the last form is the one you added, but that’s susceptible to a race condition.)
(wbeditentity doesn’t yet support senses, but with some WIP patches to set up the wiring I’m seeing the same problem there, too.)
TASK DETAIL
EMAIL PREFERENCES
To: Lucas_Werkmeister_WMDE
Cc: Lucas_Werkmeister_WMDE, Mringgaard, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, Wikidata-bugs, aude, Darkdadaah, Mbch331
Cc: Lucas_Werkmeister_WMDE, Mringgaard, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, Wikidata-bugs, aude, Darkdadaah, Mbch331
_______________________________________________ Wikidata-bugs mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs
