Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

notification-service-sdk-prodio

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

notification-service-sdk-prodio

Sdk for consuming prodio notification service

  • 1.0.11
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

notification-service-sdk-prodio

Build Status

notification-service-sdk-prodio is an node js client for the prodio-notification-service API. Integrate in to any application to send emails, sms, and push app notifications to both mobile phones and web browsers.

Philosophy

This project is started with an aim to reduce implementing and re-architecting common product features/requirements like notification service & thus increasing productivity and more focus on business goals. Goal of this service is to bundle and provide common features related to notification services like sending emails, sms, notifications to users, notification logs and history, events and templates creation for easier integration with web and mobile Apps.

Features!

  • Register users and store all user tokens
  • Send emails ( sendInBlue )
  • Template types ( email, sms and app notification )
  • Link templates with events
  • Send Push notifications by triggering events

Prerequisite:

Note:

prodio-notification-service uses loopback as the core framework for developing API's, so all customisations, configurations, middlewares, events, and db connectors can be used which you would have used in loopback.

Installation

$ npm install notification-service-sdk-prodio--save

Initialization

Require the notification-service-sdk-prodio module and initialize the notificationSdk client, passing your base_url as the first argument.


 var  notificationSdk = require('notification-service-sdk-prodio');
 var notificationModule = new notificationSdk('YOUR_BASE_URL');

Usage

Sdk module provides a easy and fast way to build notifications in the product.Examples like New Member added to a team, Someone messaged you, one of your friends liked your post, etc are events. Keeping event-driven architecture in mind this service works or reacts to events, which integration with others services easier. You can trigger emails, or send notifications in response to an event.

This application will run as a separate micro-service independent of your product services which makes it easier to implement, debug and test.

Method

createUser: method will Register the User in database for the BASE_URL initialized with and with provided user_id and payload of meta_info i.e basic details of the user will register the user in Database.

Payload

PropTypeDescription
user_idstringunique Identity Id of the user created
email_addressstringEmail address of the user created.
user_namestringName of the user created
Event_NamestringEvent name for creating events for triggering notifications related to events.
Example

	var  notificationSdk = require('notification-service-sdk-prodio');
	var notificationModule = new notificationSdk('YOUR_BASE_URL');
		//create user in notification module
		const meta_info = {
		     "user_name":"NAME",
		      "email":"EMAIL_ADDRESS",
		    }
		const  payload = {
		"user_id":"USER_ID",
		"meta_info":meta_info,
		"EVENT_NAME":"CREATE_USER"
		};

		let  createUser = notificationModule.createUser(payload);

  

Keywords

FAQs

Package last updated on 03 Nov 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc