npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

raza-kashif

v1.5.3

Published

Facebook Chat API Bot by Kashif Raza - Advanced Messenger Integration

Readme

🚀 Raza-Kashif | Advanced Facebook Chat API Bot

Version License Node Status

A Powerful and Secure Facebook Messenger Bot Framework with Advanced Integration Features

GitHubNPMContact


📋 Table of Contents


✨ Features

Core Functionality

  • Full Messenger API Support - Complete Facebook Messenger integration
  • Real-time Message Handling - Instant message reception and processing
  • Group Management - Create, modify, and manage Facebook groups
  • User Management - Add/remove members, manage permissions
  • Media Support - Send images, videos, documents, and attachments
  • Story Management - Post and manage stories
  • Typing Indicators - Show user when bot is typing
  • Message Reactions - Like, love, laugh reactions on messages

Security Features

  • 🔒 AES-256 Encryption - Military-grade encryption for sensitive data
  • 🔐 Secure Authentication - Two-factor authentication support
  • 🛡️ Auto-Login - Secure credential storage and auto-login
  • 🔑 Token Management - Automatic token refresh and management
  • ⚠️ Bypass Detection - Facebook checkpoint (956) bypass support

Performance & Reliability

  • Memory Optimization - Automatic memory leak detection and repair
  • 📊 Auto-Restart - Configurable automatic restart on crashes
  • 📈 Uptime Monitoring - Real-time uptime tracking
  • 🔄 MQTT Support - Real-time data synchronization
  • 📝 Logging System - Comprehensive logging with rotation

Developer Features

  • 📚 Rich API - 50+ API functions for bot control
  • 🎨 Customizable - Extensive configuration options
  • 🌐 Multi-Language - Vietnamese and English support
  • 🔧 DevMode - Built-in development mode for debugging
  • 📦 Easy Installation - Simple npm installation
  • 🚀 Hot Reload - Automatic code reload support

📦 Installation

Via NPM (Recommended)

npm install raza-kashif

Via GitHub

git clone https://github.com/nobita136/raza-kashif.git
cd raza-kashif
npm install

Requirements

  • Node.js >= 14.x
  • npm or yarn
  • Facebook Account
  • Valid Messenger Session

🚀 Quick Start

Basic Setup

const fca = require('raza-kashif');

fca({ 
    email: '[email protected]', 
    password: 'your-password' 
}, (error, api) => {
    if (error) return console.error(error);
    
    // Listen for incoming messages
    api.listenMqtt((error, event) => {
        if (event.type === 'message') {
            console.log('New message:', event.body);
            
            // Send a reply
            api.sendMessage('Hello! 👋', event.threadID);
        }
    });
});

Configuration File

The bot automatically creates a FastConfigFca.json file with default settings:

{
    "Language": "vi",
    "PreKey": "KashifRaza",
    "AutoUpdate": false,
    "MainColor": "#9900FF",
    "MainName": "[ Kashif Raza ]",
    "DevMode": false,
    "AutoLogin": false,
    "Login2Fa": false,
    "BroadCast": true
}

⚙️ Configuration

FastConfigFca.json Options

| Option | Type | Default | Description | |--------|------|---------|-------------| | Language | String | vi | Bot language (en, vi) | | MainName | String | [ Kashif Raza ] | Display name in logs | | MainColor | String | #9900FF | Color code for output | | AutoLogin | Boolean | false | Auto-login on restart | | Login2Fa | Boolean | false | Two-factor authentication | | DevMode | Boolean | false | Enable debug mode | | AutoUpdate | Boolean | false | Auto-update checking | | BroadCast | Boolean | true | Send notifications | | EncryptFeature | Boolean | true | Encrypt sensitive data | | Uptime | Boolean | false | Track bot uptime |


💡 Usage Examples

1. Message Handling

api.listenMqtt((error, event) => {
    if (event.type === 'message') {
        const { threadID, senderID, body } = event;
        
        if (body.toLowerCase() === 'ping') {
            api.sendMessage('Pong! 🏓', threadID);
        }
    }
});

2. Send Rich Messages

// Send message with attachments
api.sendMessage({
    body: 'Check this out!',
    attachments: [{
        attachment: fs.createReadStream('/path/to/image.png')
    }]
}, threadID);

3. Group Management

// Create a new group
api.createNewGroup(['uid1', 'uid2'], 'Group Name', (error, groupId) => {
    if (!error) console.log('Group created:', groupId);
});

// Change group title
api.setTitle('New Group Title', threadID);

// Add user to group
api.addUserToGroup('uid', threadID);

4. User Information

api.getUserInfo('userid', (error, info) => {
    if (!error) console.log(info);
});

api.getFriendsList((error, list) => {
    if (!error) console.log('Friends:', list);
});

5. Message Management

// Mark as read
api.markAsRead(threadID);

// Set reaction
api.setMessageReaction('❤️', messageID);

// Edit message
api.editMessage('Updated text', messageID);

// Unsend message
api.unsendMessage(messageID);

6. Typing Indicator

// Show typing indicator
api.sendTypingIndicator(threadID);

// Hide after 3 seconds
setTimeout(() => {
    api.markAsDelivered(threadID);
}, 3000);

🔧 Advanced Features

Memory Management

Enable automatic memory leak detection and repair:

{
    "AntiStuckAndMemoryLeak": {
        "AutoRestart": {
            "Use": true,
            "Explain": "Restart when memory reaches 90%"
        },
        "LogFile": {
            "Use": true,
            "Explain": "Log memory usage to Raza_DataBase/memory.logs"
        }
    }
}

Two-Factor Authentication Bypass

{
    "CheckPointBypass": {
        "956": {
            "Allow": true,
            "Difficult": "Easy",
            "Notification": "2FA Bypass Active"
        }
    }
}

Encryption

All sensitive data is encrypted using AES-256:

const Security = require('./Extra/Security');
const encrypted = Security.Encrypt('sensitive-data');
const decrypted = Security.Decrypt(encrypted);

Database Management

Local SQLite database for storing user data:

const Database = require('./Extra/Database');
const db = Database();

db.set('AccountEmail', '[email protected]');
db.get('AccountEmail');
db.delete('AccountEmail');

📚 API Reference

Core Methods

listenMqtt(callback)

Listen for real-time events via MQTT connection.

sendMessage(message, threadID, callback)

Send a message to a thread (user or group).

setTitle(title, threadID, callback)

Set the title/name of a conversation.

getThreadInfo(threadID, callback)

Get detailed information about a thread.

getUserInfo(uid, callback)

Get user profile information.

setMessageReaction(reaction, messageID, callback)

React to a message with emoji.

editMessage(text, messageID, callback)

Edit a previously sent message.

unsendMessage(messageID, callback)

Delete a message from both users.

createNewGroup(userList, title, callback)

Create a new group chat.

addUserToGroup(uid, groupID, callback)

Add user to an existing group.

removeUserFromGroup(uid, groupID, callback)

Remove user from a group.

getFriendsList(callback)

Get list of all friends.

getThreadList(limit, timestamp, callback)

Get list of conversations.

markAsRead(threadID, callback)

Mark all messages as read.

sendTypingIndicator(threadID, callback)

Show typing indicator.


🔄 Update Command

To update the FCA to the latest version:

npm update raza-kashif

Or reinstall the latest version:

npm install raza-kashif@latest

📝 Scripts

# Start the bot
npm start

# Run tests
npm test

# Publish to npm (maintainers only)
npm run publish

🤝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

📞 Contact

Kashif Raza

  • WhatsApp: +923003310470
  • Email: [email protected]
  • GitHub: @nobita136
  • Repository: https://github.com/nobita136/raza-kashif
  • NPM Package: https://www.npmjs.com/package/raza-kashif

⚠️ Disclaimer

This library is for educational and authorized use only. Unauthorized access to computer systems is illegal. Users are responsible for their own actions and compliance with Facebook's Terms of Service.


📄 License

This project is licensed under the MIT License - see the LICENSE file for details.


🙏 Acknowledgments

  • Original FCA team
  • KanzuWakazaki & HZI Team
  • All contributors and users

📊 Stats

GitHub Stars GitHub Forks GitHub Issues


Made with ❤️ by Kashif Raza

Stay Updated | Star the Repository | Share with Friends