summaryrefslogtreecommitdiff
path: root/post_bot.py
blob: aa9a49da8d4836691eb769c11668be166d6a9c6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#!/usr/bin/env python3
import requests
from time import sleep
from os import fork

post_cooloff = 7

rs = requests.session()
rp = rs.post('https://recolor.me/login?json', data = {
    'action':'login', 
    'account_name':'testingaccount1', 
    'account_password':'1234',
    'account_cookie':'1'})

if not rp.json()['account_id']:
    print("wrong login info!")
    exit(1)

rp = rs.get('https://recolor.me/')
key_pos = rp.text.find("site.my_key = \'") + len("site.my_key =  ")
key = rp.text[key_pos:key_pos+32]


rs.post('https://recolor.me/topic/1557621', data={
    'key':key,
    'page':'topic',
    'action':'reply',
    'topic_id':'1557621',
    'reply_message':'posts with 7 second delay (pair 2)',
    'box_color':'#ff0000',
    'post_color':'#0',
    'post_style':'0'
    })
rs.post('https://recolor.me/topic/1557621', data={
    'key':key,
    'page':'topic',
    'action':'reply',
    'topic_id':'1557621',
    'reply_message':'posts with 7 second delay (pair 2)',
    'box_color':'#0000ff',
    'post_color':'#0',
    'post_style':'0'
    })



    #while True:
    #treats += 1
    #print("Trick or treats: {}".format(treats))
    #print("Money accumulated: {}".format(treats * 10))
#cfc4cfa627a259e8d810849680c0460aeb369b93f3d40bd17ab7401031419b43ffebf8e79cb655a3eaeff675427ad6832b2d0eb8813d0844ddef7f9166d0470d