1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

[GET] Build your own Bots for Facebook, Pinterest, Twitter and more! (free/open-source)

Discussion in 'Black Hat SEO Tools' started by ikstob, Nov 20, 2012.

  1. ikstob

    ikstob Junior Member

    Joined:
    Nov 12, 2012
    Messages:
    147
    Likes Received:
    129
    Location:
    ikstob.com
    Home Page:
    I've been working on building simple bots and tools to automate a lot of dull tasks. In the process of doing that I started to tidy up my code in preparation to make it freely available to others. This project is nicknamed "botski" and you can find all the source code and instructions on "ikstob_com", it will require some basic knowledge of code to make the most of it - but its all free/open-source and ready to go.

    So rather than waffling on about it, here's an example.

    Example: Automatically liking pins on Pinterest in ~10 lines of code
    (excluding the comments of course)

    Basically this logs into Pinterest (optionally using a proxy), finds any pins with a 'Like' button on your homepage/timeline and then randomly 'Likes' about 10% of them.

    Code:
        // Set your Proxy here
        useProxy("123.123.123.123", 8080);
        
        // Default to Firefox, but could use Chrome
        initializeFirefox();
        
        // Login and goto the homepage
        pinterestLogin("emailaddress", "password");
        
        // Search the DOM to find all visible Like buttons
        List<WebElement> list = browser.findElements( By.className("likebutton") );
        System.out.println("Found " + list.size() + " 'Like' buttons!");
        
        // Randomly 'Like' ~ 10% of them
        int count = 0;
        for ( WebElement element : list )
        {
            if ( Math.random() <= 0.10 ) // roughly 10%
            {
                // Click the 'Like' button using Javascript
                javascript.executeScript("arguments[0].click();", element);
                System.out.println("   ... Liked pin " + element.getAttribute("data-id"));
                count++;
            }
        }
        System.out.println("Liked " + count + " pins!");
        
        // Sleep for 5 seconds then quit
        sleep(5000);
        browser.quit();
    The complete source code for this example and everything you need to run it is on GitHub: github_com/ikstob/botski

    Part of the project is a Java class called "SocialBot" that includes the login code for Facebook, Twitter & Pinterest. If you take this code as an example you can easily write your own login code for just about anything else.

    NOTE: The rationale for releasing this code is to enable others to write their own bots and customize them to their needs, this is *not* a finished-product that you can just point/click.
     
    • Thanks Thanks x 3
    Last edited: Nov 20, 2012
  2. YouFeelMeDawg?

    YouFeelMeDawg? BANNED BANNED

    Joined:
    Aug 10, 2011
    Messages:
    266
    Likes Received:
    371
    This is a fantastic idea, however I think you chosed the wrong language to do it. Due to the fact that many users here arent coders,and the few that are only seem to know to code in .net, you should go ahead and try to do this project in .net Now I honestly think your doing a great job, I have a lot of code too that I think I could contribute. This code though is purely all AutoIt, but pretty much includes 80% of all youtube functions, including account creation.
     
  3. ikstob

    ikstob Junior Member

    Joined:
    Nov 12, 2012
    Messages:
    147
    Likes Received:
    129
    Location:
    ikstob.com
    Home Page:
    Hello YouFeelMeDawg, I can totally see your point, but beg to differ. Even though I do write a lot of C# & .NET during my day job, it isn't a portable for use on Mac/UNIX - "Mono" is supposed to solve that but it doesn't. AutoIT is fun and I've written some bots it it, but again its basically Windows-only and kinda limited. The prime objective of this little project was to make a cross-platform set of tools that anyone can use (with a little Java).

    Right now I can run this framework doing multiple tasks simultaneously on a cheap $2/month Linux VPS server. While Java can be a bit of a clunky language, all the tools are free/open-source and fairly easy to understand. If you are familiar with any form of programming I am sure you can pick up the basics of Java quickly enough! :D
     
  4. MrBlue

    MrBlue Senior Member

    Joined:
    Dec 18, 2009
    Messages:
    950
    Likes Received:
    662
    Occupation:
    Web/Bot Developer
    Great share. I use a similar method of browser manipulation using Python.
     
  5. ikstob

    ikstob Junior Member

    Joined:
    Nov 12, 2012
    Messages:
    147
    Likes Received:
    129
    Location:
    ikstob.com
    Home Page:
    Yup, good point .. while my project makes use of "Selenium" from Java, you can also use Selenium from any C#, Python or Ruby project.
     
  6. dannyvriens

    dannyvriens Registered Member

    Joined:
    Apr 3, 2010
    Messages:
    91
    Likes Received:
    32
    I do the same as you :)
    Python gives me for this work the same tools and options as Java does.
    But Python is a lot easy'er to understand in my eyes :p
     
  7. YouFeelMeDawg?

    YouFeelMeDawg? BANNED BANNED

    Joined:
    Aug 10, 2011
    Messages:
    266
    Likes Received:
    371
    Fair enough point taken. I wasn't complaining because of the language, I can pretty much pick up Java and understand it since I can understand a lot of C++ since I have been studying it for a while.What I was trying to say was that, most people would want to make bots where they can compile them and run them as exes . You gotta remember, this isnt a programming forum, the level that most users have on programming is very little compared to stackedoverflow and other programming sites, heck most users would barely know how to setup Java to run this.Why do you think ubot,zennoposter is very popular here? I have no problem reading your code, but you have to acknowledge that your level of programming here is way higher than the average one. This is the place where shitty coding can be sold for monthly subscriptions via bots. Trust me , if you already program in your day job then all you really need is to code your own bots and employ it with the knowledge that you have. Open source in IM doesn't work well because of the fact that these bots are highly correlated with the amount of money you make, this isn't programming for fun, people program in IM for the whole purpose to scale, explode efficiency, and speed.
     
  8. saxgod

    saxgod Regular Member

    Joined:
    Sep 19, 2010
    Messages:
    351
    Likes Received:
    337
    I wouldn't opensource it though. Now the targets can plug the holes in the time it takes noobs to compile this into a jar file and get it running.
     
  9. ikstob

    ikstob Junior Member

    Joined:
    Nov 12, 2012
    Messages:
    147
    Likes Received:
    129
    Location:
    ikstob.com
    Home Page:
    Totally understand your point(s), I thought about writing my own shiny tools and selling them on tasty subscriptions but I just don't have the time to manage/update them for paying subscribers. So just for a bit of fun I put this project together and open-sourced it.

    On its own there aren't any real "targets" to plug, the "login" functionality I've included is just looking for and populating form fields and would be trivial to update. I expect others will take this "bot base" and build their own methods/techniques on-top for that reason I licensed it under the "Apache License 2.0" which allows you to mix open/closed source and even sell it as a finished product.

    :D