https://github.com/jdtzmn/gators
Free and easy texting framework for node using SMS gateways
https://github.com/jdtzmn/gators
free gateways gator gators node sms text
Last synced: 2 days ago
JSON representation
Free and easy texting framework for node using SMS gateways
- Host: GitHub
- URL: https://github.com/jdtzmn/gators
- Owner: jdtzmn
- License: mit
- Created: 2017-11-12T22:55:09.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2023-03-15T04:17:31.000Z (over 3 years ago)
- Last Synced: 2026-07-02T17:43:53.780Z (2 days ago)
- Topics: free, gateways, gator, gators, node, sms, text
- Language: TypeScript
- Homepage:
- Size: 373 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# gators
Free and easy texting framework for node using [SMS gateways][SMS-article].
[![GitHub stars][stars-image]][stars-url]
[![GitHub forks][forks-image]][forks-url]
[![GitHub issues][issues-image]][issues-url]
[![License][license-image]][license-url]
```js
import Gators from 'gators'
const emailAuthentication = {
account: { /* ... */ },
smtp: { /* ... */ },
imap: { /* ... */ }
}
const gators = new Gators(emailAuthentication)
gators.on('connected', () => console.log('connected!'))
gators.on('message', (details, sendReply) => {
const text = details.text.toLowerCase()
console.log(`> Received message: ${text}`)
// send reply
if (text === 'ping') sendReply('pong')
})
gator.on('error', (err: any) => console.log(err))
gator.connect()
```
[](https://nodei.co/npm/gators/)
## Getting Started
> DISCLAIMER: This package has not been tested with all SMS gateway providers nor phone operating systems.
> For a list of supported providers, see [SUPPORT.md](SUPPORT.md).
> For instructions on how you can contribute, see [CONTRIBUTE.md](CONTRIBUTE.md).
This is a module from npm.
Before installing, download and install [node.js](https://nodejs.org/) and [npm](https://npmjs.com).
### Install gators
```bash
$ npm i -s gators
# or yarn add gators
```
### Create auth file from template
```bash
$ touch auth.js
```
auth.js
```js
module.exports = {
account: {
user: '****@****.com',
pass: '$!J$#LK#K'
},
smtp: {
host: 'smtp.*****.com',
port: 465,
secure: true
},
imap: {
host: 'imap.*****.com',
port: 993,
secure: true
}
}
```
### Manually test with one of the included examples
```bash
$ ts-node ./examples/ping
```
## Built With
* [node-imap](https://github.com/mscdex/node-imap) - IMAP Client
* [Nodemailer](https://nodemailer.com/) - SMTP Client
* [Mailparser](https://nodemailer.com/extras/mailparser/) - Elegantly parse emails
* [html-to-text](https://github.com/werk85/node-html-to-text) - HTML interpreter
## Versioning
We use [SemVer](http://semver.org/) for versioning. For the versions available, see the [tags on this repository](https://github.com/jdtzmn/gators/tags).
## Coding Style
[](https://github.com/standard/standard)
## Authors
* **jdtzmn** - *Initial work* - [jdtzmn](https://github.com/jdtzmn)
See also the list of [contributors](https://github.com/jdtzmn/gators/contributors) who participated in this project.
## License
This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details
## Acknowledgments
* This amazing [README template](https://gist.github.com/PurpleBooth/109311bb0361f32d87a2).
* [NodeICO](https://nodei.co) for the npm badge.
* [gitignore.io](https://gitignore.io) for .gitignore
[SMS-article]: https://en.wikipedia.org/wiki/SMS_gateway#Email_clients
[stars-image]: https://img.shields.io/github/stars/jdtzmn/gators.svg
[stars-url]: https://github.com/jdtzmn/gators/stargazers
[forks-image]: https://img.shields.io/github/forks/jdtzmn/gators.svg
[forks-url]: https://github.com/jdtzmn/gators/network
[issues-image]: https://img.shields.io/github/issues/jdtzmn/gators.svg
[issues-url]: https://github.com/jdtzmn/gators/issues
[license-image]: https://img.shields.io/github/license/jdtzmn/gators.svg
[license-url]: https://github.com/jdtzmn/gators/blob/master/LICENSE.md