A mailer is an object that's responsible to deliver a mail message, by rendering one or more templates.
For simplicity, each mailer can handle only one use case (feature).
If in our application we need to send emails for several features like: "confirm your email address" or "forgot password", we will have Mailers::ConfirmEmailAddress and Mailers::ForgotPasswordinstead of a generic UserMailer that manages all these use cases.
A Simple Mailer
Hanami ships a generator that creates a mailer, two templates and the test code.