awabah-hermes
TypeScript icon, indicating that this package has built-in type declarations

0.0.3 • Public • Published

Hermes

npm npm NPM

About

This provides easy access to Hermes APIS. All are properly & fully tested. Available features include:

  • Notification: send email & send sms

Getting Started

Technologies · Installations · Usage · Components · Tests · Author

Technologies Used

  • ESLint - A pluggable and configurable linter tool for identifying and reporting on patterns in JavaScript.
  • Jest - Jest is a JavaScript testing framework maintained by Facebook, Inc. designed and built by Christoph Nakazawa with a focus on simplicity and support for large web applications.
  • Airbnb style guide was followed.
  • TypeScript

Installations

Getting started

  • You need to have your hermes secret key and NPM installed on your computer.

Setup

  • Installing the project dependencies

    Run the command below

    $ npm install awabah-hermes

Usage

$ const { Hermes } = require('awabah-hermes');
$ const  hermes = new Hermes('your-secret-key');

Components

  • Notification
    • Send Email
    const { Hermes } = require('awabah-hermes');
    const  hermes = new Hermes('your-secret-key');
    
    const attachment = {
     filename: string;
     content: string;
     encoding: string;
    }
    const data = {
     from: 'hello@awabahng.com', // required
     subject: 'testing package', // required
     to: ['tina@awabahng.com'], // required
     html: 'hello testing package', // required
     attachments?: attachment // not required
    }
    
    const response = await hermes.notification.sendEmail(data) 
    • Send sms
    const { Hermes } = require('awabah-hermes');
    const  hermes = new Hermes('your-secret-key');
    
    const response = await hermes.notification.sendSms({
        phoneNumber: '+2348160190214', // required
        message: 'testing package', // required
    })

Author

Readme

Keywords

Package Sidebar

Install

npm i awabah-hermes

Weekly Downloads

2

Version

0.0.3

License

MIT

Unpacked Size

8.27 kB

Total Files

8

Last publish

Collaborators

  • awabah-engineering