Skip to content

Instantly share code, notes, and snippets.

@flaredragon
Created January 7, 2018 08:59
Show Gist options
  • Save flaredragon/12183f0ccac4a39adfdc0027af6f0595 to your computer and use it in GitHub Desktop.
Save flaredragon/12183f0ccac4a39adfdc0027af6f0595 to your computer and use it in GitHub Desktop.
Whatsapp Spam Bot
/*
WhatsApp Web Spam Script written by flaredragon.
====================================================================================
DISCLAIMER: I do not take any responsibility for any damage caused with this script.
====================================================================================
Usage: Copy all of this script (Ctrl+A, Ctrl+C).Visit WhatsApp Web, select your
desired contact and Press Ctrl+Shift+I to and paste it in the console and press Enter.
(Imp Note - Whatsapp Controls the message sending rate so sending ~500 together may
cause your Whatsapp to hang so use the script smartly)
====================================================================================
*/
//To Get The React Component
function findReactComponent(dom) {
for (var key in dom)
if (key.startsWith("__reactInternalInstance$")) {
var compInternals = dom[key]._currentElement;
var compWrapper = compInternals._owner;
var comp = compWrapper._instance;
return comp;
}
return null;
};
var inputComponent = findReactComponent(document.getElementsByClassName('block-compose')[0]);
//Get the react component for the chat input
var chat = inputComponent.props.chat;
//Set the number of times to send in the loop Eg - 10 Right now
for(var i=0;i<10;i++)
{
//Delay Helps in Sending Messages at a faster Rate
setTimeout(function(){
chat.sendMessage('Enter any Message here');
}, 1000);
}
@lalune3004
Copy link

how to use this thing?

@bansha06
Copy link

come lo uso?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment