DD063520 created this task. DD063520 added a project: Wikidata. Restricted Application added a subscriber: Aklapper.
TASK DESCRIPTION Hello, we would like to allow users to do edits in Wikidata via OAuth. What we have already done and is working: 1. Get the consumer approved 2. Letting the user authorize 3. Accessing the MediaWiki API api.php?action=query&meta=userinfo&format=json via OAuth to retrive the username of the user So the OAuth identification is working and we can use it to access some API of Mediawiki. The problem is now that we are not able to make an edit in Wikidata. Currently what we are doing is: 1. get a csrftoken via ?action=query&format=json&meta=tokens 2. Setting a description using wbsetdescription Unfortunately this results in a "permissiondenied, You do not have the permissions needed to carry out this action" We came to the conclusion that we do not know how the APIs work and we didn't find documentation. The nearest we came across is: https://www.wikidata.org/wiki/Wikidata:ExtractTransformLoad/Analysis section "Issue 1: API complexity - Cookies, Tokens, CSRF token expiration". The problem is that point 2 assumes we authorize via username and password. But in this case we are via OAuth. So we do not have the cookies name C2 in the instruction. The question is the following .... can you detail the exact mechanism of the wikibase API when we authorize via OAuth. Or can you point to some code where this is already implemented, so that we can migrate it to our java implementation. Thank you very much D063520 TASK DETAIL https://phabricator.wikimedia.org/T246751 EMAIL PREFERENCES https://phabricator.wikimedia.org/settings/panel/emailpreferences/ To: DD063520 Cc: Lucas_Werkmeister_WMDE, DD063520, Aklapper, darthmon_wmde, Nandana, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, _jensen, rosalieper, Scott_WUaS, Wikidata-bugs, aude, Mbch331
_______________________________________________ Wikidata-bugs mailing list Wikidata-bugs@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs