1.0.3 • Published 5 years ago
gmass-inbox-api v1.0.3
Unofficial GMASS INBOX API
Usage
import { GmassInboxApi } from "..";
let gmassInboxApi = new GmassInboxApi({
auth: {
pass: config.pass,
user: config.user
},
host: config.host,
port: config.port,
secure: false
});
let result = await gmassInboxApi.check(
{
id: 123,
from: 'cvetko@cns.mk',
fromName: 'Cvetko Stavreski',
html: '<p>This is a test</p>',
subject: 'Test subject',
to: 'test@cns.mk'
})
await gmassInboxApi.close();
return result;
Constructor arguments:
- auth.pass: string (your smtp password)
- auth.user: string (your smtp username)
- host: string (host ex: smtp.gmail.com)
- port: number (smtp port)
- secure: (TLS secure)
Check method arguments:
- id: number (some id)
- from: string (approved smtp from address)
- fromName: string (sender name)
- html: string (body in html format)
- subject: string (subject line)
- to: string (recipients email address or addresses comma separated)