Messaging custom components
From MoodleDocs
Since Moodle 2.0 it has been possible to easily integrate your own custom components into the Moodle messaging system. There are two types of components you may wish to implement.
- message providers - These create new messages and send them via the messaging system.
- message processors - These are optionally used by message recipients and receive and process messages sent to that user.