https://github.com/grails-plugins/grails-mail
The Grails Mail Plugin
https://github.com/grails-plugins/grails-mail
Last synced: 5 months ago
JSON representation
The Grails Mail Plugin
- Host: GitHub
- URL: https://github.com/grails-plugins/grails-mail
- Owner: grails-plugins
- License: apache-2.0
- Created: 2010-07-27T10:21:25.000Z (almost 16 years ago)
- Default Branch: 5.0.x
- Last Pushed: 2025-12-15T22:43:51.000Z (6 months ago)
- Last Synced: 2025-12-19T07:11:19.776Z (6 months ago)
- Language: Groovy
- Homepage: http://grails.org/plugin/mail
- Size: 3.03 MB
- Stars: 44
- Watchers: 11
- Forks: 85
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Grails Mail Plugin
[](https://central.sonatype.com/artifact/org.grails.plugins/grails-mail)
[](https://github.com/grails-plugins/grails-mail/actions/workflows/gradle.yml)
The Grails Mail Plugin provides a convenient Domain-Specific Language (DSL) for _sending_ email, supporting features such as plain text, HTML, attachments, inline resources and i18n (internationalization), among others.
Email can be sent using the `mailService.sendMail` method. Here's an example:
```groovy
mailService.sendMail {
to 'fred@gmail.com', 'ginger@gmail.com'
from 'john@gmail.com'
cc 'marge@gmail.com', 'ed@gmail.com'
bcc 'joe@gmail.com'
subject 'Hello John'
text 'this is some text'
}
```
## Installation
Add a dependency in build.gradle
```groovy
repositories {
maven { url 'https://repo.grails.org/grails/core/'}
}
dependencies {
runtimeOnly 'org.grails.plugins:grails-mail:5.0.3'
}
```
## Documentation
- [Latest Release](https://grails-plugins.github.io/grails-mail/latest/)
- [Development Snapshot](https://grails-plugins.github.io/grails-mail/snapshot/)
## Versions
| Branch | Grails Version |
|--------|----------------|
| 1.x | 2 |
| 2.x | 3 |
| 3.x | 4-5 |
| 4.x | 6 |
| 5.x | 7.0.0-M5+ |
## Issues
Issues can be raised via [GitHub Issues](https://github.com/grails-plugins/grails-mail/issues).
## Contributing
Pull requests are the preferred way to submit contributions. Before submitting, please create an issue using the [issue tracker](https://github.com/grails-plugins/grails-mail/issues), outlining the problem your contribution addresses.
For documentation contributions, creating an issue is not required.