forked from kyngs/LibreLogin
-
Notifications
You must be signed in to change notification settings - Fork 16
API Events
Navio1430 edited this page Jul 23, 2025
·
1 revision
All event handling is done via EventProvider which can be obtained from LibrePremiumPlugin.
The subscribe method requires you to specify the type you can obtain from the class EventTypes and the action. Example:
var eventTypes = eventProvider.getTypes()
eventProvider.subscribe(eventTypes.passwordChange, event -> {
var old = event.getOldPassword();
var newPassword = event.getUser().getHashedPassword();
// Do some stuff
});All events are documented, check the events package for further details.