After discussions in today's watercooler between me @pwangai and @zeljkofilipin we decided that for the next version of the API implementation in core, we should hide the backend implementation. Today in core we expose mwbot, and that makes it hard to know what part of the API is actually used by extensions. By defining the API ourselves in core, this will make it easier for us to maintain.
This is a first step to make the code more maintainable and it will make it easier to remove the use of mwbot.
AC:
- Change so you as a user of the API in core cannot get hold of mwbot (remove https://gerrit.wikimedia.org/r/plugins/gitiles/mediawiki/core/+/refs/heads/master/tests/selenium/wdio-mediawiki/Api.js#25)
- Expose the functions that use mwbot in core in Api.js