Пример #1
0
bot = InstaBot(login="******",
               password="******",
               like_per_day=0,
               comments_per_day=0,
               tag_list=[],
               max_like_for_one_tag=50,
               follow_per_day=10000,
               follow_time=12 * 60 * 60,
               unfollow_per_day=0,
               unfollow_break_min=10000,
               unfollow_break_max=100000,
               log_mod=0)

os.system("touch users.txt")

users = getUsers.getUsers()

f = open("users.txt", "w")

for user in users.keys():
    bot.like(users[user])
    sec = 2 + random.random()
    time.sleep(sec)
    print("Following: " + user)
    bot.follow(getId(user))
    f.write(user + "\n")
    pause = random.randint(23, 25)
    pause += random.random()
    time.sleep(pause)
Пример #2
0
    elif mode == 3:
        unfollow_protocol(bot)
        time.sleep(10 * 60)

    elif mode == 4:
        feed_scanner(bot)
        time.sleep(60)
        follow_protocol(bot)
        time.sleep(10 * 60)

    elif mode == 5:
        bot.bot_mode = 2
        unfollow_protocol(bot)
    elif mode == 6:
        # USER LIST - FILL IN DESIRED ACCOUNTS
        userlist = ['barney_vaughan']
        for user in userlist:
            print("Liking %s's 12 most recent media" % (user))
            ui = UserInfo()
            medias = ui.get_media_by_login(user)
            ex = 1
            print(medias)
            for media in medias:
                bot.like(media)
                print("Liked media %i of %i" % (ex, len(medias)))
                ex = ex + 1
                time.sleep(10)
    else:
        print("Wrong mode!")
Пример #3
0
from instabot import InstaBot

bot=InstaBot('login', 'password')

response = bot.like('https://www.instagram.com/p/CH5qV6-so6Y/')
print(response)  # if the response code is 200 that means ok

response = bot.unlike('https://www.instagram.com/p/CH5qV6-so6Y/')
print(response)  # if the response code is 200 that means ok

response = bot.like_recent('instagram')
print(response)  # if the response code is 200 that means ok

response = bot.comment('https://www.instagram.com/p/CH5qV6-so6Y/', comment_text='Nice Post!')
print(response)  # if the response code is 200 that means ok

response = bot.comment_recent('instagram', comment_text='Nice Post!')
print(response)  # if the response code is 200 that means ok

response = bot.follow('instagram')
print(response)  # if the response code is 200 that means ok

response = bot.unfollow('instagram')
print(response)  # if the response code is 200 that means ok

response = bot.story_view('b31ngdev')
print(response)  # if the response code is 200 that means ok

response = bot.upload_post('image.png', caption='Image 1')
print(response)  # if the response code is 200 that means ok