*/ interface MediawikiApiInterface extends ApiRequester, AsyncApiRequester { /** * @since 2.2 * * @return bool|string false or the name of the current user */ public function isLoggedin(); /** * @since 2.2 * * @param ApiUser $apiUser The ApiUser to log in as. * * @throws UsageException * @return bool success */ public function login( ApiUser $apiUser ); /** * @since 2.2 * * @return bool success */ public function logout(); /** * @since 2.2 * * @param string $type The type of token to get. * * @return string */ public function getToken( $type = 'csrf' ); /** * @since 2.2 * * Clears all tokens stored by the api */ public function clearTokens(); /** * @since 2.2 * * @return string */ public function getVersion(); }