Skip to content

A Plugin to Make Your Bot Force Users to Subscribe Your Channel (for Telegraf)

Notifications You must be signed in to change notification settings

kashyapndps00/telegraf-fsub

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Telegraf Fsub

This plugin can help you to force your bot users to subscribe your channel before using the bot.

Installation

You can install this plugin in any Telegraf Bot.

Install the NPM Plugin

npm i telegraf-fsub
#or
yarn add telegraf-fsub

Import and Use in code

import fsub from "telegraf-fsub"

const botFsub = fsub({ 
    channels : ["@channel"]
});
bot.use(botFsub)

Advanced Installation

You can pass these options in bot like this

import fsub from "telegraf-fsub"

const botFsub = fsub({ 
    channels: [],
    notJoinedMessage: "Hello {user}, You Must Joined <b>{channel}</b>",
    enable_inline: true,
    parse_mode: "HTML"
});
bot.use(botFsub)

Note : channels option is required without that bot will crash

Help

You can open a Issue for ressolving your problem

Contribution

You can contribute to this plugin by just opening a pull request.

About

A Plugin to Make Your Bot Force Users to Subscribe Your Channel (for Telegraf)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published