Skip to content

A cron job developed using Node.js enables you to send scheduled template messages on several communication platforms.

License

Notifications You must be signed in to change notification settings

ekatraone/schedule-template-messages

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ekatra.one

🏠Homepage

Ekatra is the first low data / no data learning platform.

• Ekatra helps institutions create, deploy, and assess text message-based micro-courses that dramatically improve learning and training.

• Our learning platform helps such organizations focused on career readiness for underserved high schoolers to teach them important job and life skills

• Learn more about Ekatra here: https://www.ekatra.one/


Welcome to Schedule Template Messages 👋

Version Documentation Version Maintenance License: MIT Twitter: @ekatraone Twitter: @ramshaa_shaikh

Schedule Template message is Node.js based cron job program that helps you send schedule messages to users on different channels.

This repository explains how to send template messages to users daily on WhatsApp & Telegram channels at a specific time.

Tech Stack

  1. WhatsApp Business API: WhatsApp API was launched to help medium to large companies that wanted to use WhatsApp to communicate with multiple customers at scale. WhatsApp Business API enables businesses to automate communications with automated replies, WhatsApp chatbots & interactive messages.

  2. node-telegram-bot-api : It is Node.js module to interact with the official Telegram Bot API.

  3. Airtable : Airtable is an easy-to-use online platform for creating and sharing relational databases. It is a spreadsheet-database hybrid which lets you create powerful databases that can be used to power custom applications. Airtable has two APIs:

  4. Heroku : Heroku is a container-based cloud Platform as a Service (PaaS). It is used to deploy, manage, and scale modern apps.


Prerequisites

  1. WATI Account
  2. Airtable Account
  3. Heroku Account

Initial Steps : Obtain required API Keys and Access Tokens 🔑

A. WATI Access Token

  1. Login to your WATI account > Go to API Docs.
  2. On this page you will find the Access Token, API Endpoint and the available API URLs.
  3. Securely store the access token and API Endpoint in .env file

B. Airtable REST API

  1. Go to your account page
  2. Under API heading in Account Overview page, click Generate API key button.
  3. Securely save them in your .env file.

C. Creating new bot with BotFather

  1. Send @BotFather a /newbot message
  2. Pick name and username.
  3. Receive a BOT_TOKEN

Let's discuss about our backend - Airtable.

Head over to Airtable Documentation to understand tables schema, field description.


Heroku Add-ons : Advanced Scheduler ⏲

Heroku add-ons are components that support your application, such as data storage, monitoring, analytics, data processing, and more. These are fully maintained for you by either a third-party provider or by Heroku.

• Head over to Heroku Documentation to schedule the template messages.


WhatsApp Template Message using WATI.

• This application uses WATI as a WhatsApp API solution provider.

WATI is communication platform built on official WhatsApp API. It has feature such as Shared team inbox, Native integration, sending bulk messages and alot more.

• Check out the WATI API Reference and play around with the APIs to get a sense of the basics.

Now let's learn how to create a Template Message.

  1. Login to your WATI account > Go to Broadcast> Click on Template Messages

  2. Before creating a new Template Message go through the documentation below to learn about Template messages.

    Template Messages Guidelines

    Template Messages formatting rules

    Session messages vs Template Messages

WhatsApp Template Messages


Telegram Template Message

• Creating interactive template messages on Telegram is pretty straightforward.

• We create it with the help of keyboard reply_markup option.

• Read about keyboard button: yagop/node-telegram-bot-api#21

Telegram Template Messages


Author

👤 Ramsha Shaikh

🏢 Ekatra Learning, Inc.

🤝 Contributing

Contributions, issues and feature requests are welcome!
If you have any suggestion on how to improve the code create a PR request or faced any issues feel free to contact me.

Show your support

Give a ⭐️ if this project helped you!

📝 License

This project is MIT licensed.


This README was generated with ❤️ by readme-md-generator

About

A cron job developed using Node.js enables you to send scheduled template messages on several communication platforms.

Topics

Resources

License

Stars

Watchers

Forks