!pip install praw
!pip install gspread-dataframe
!pip install pip install gspread
import praw
import time
import random
import random
import gspread
import gspread_dataframe as gd
gc = gspread.service_account(filename='reddit-bot-crosspost-a1bb4a397210.json')
ws = gc.open("Reddit Crosspost Bot Data").worksheet("Sheet1")
url_title = gd.get_as_dataframe(ws)
url_title = url_title.dropna(axis=1, how='all')
url_title = url_title.dropna(axis=0, how='all')
url_title
CLIENT_ID = "XIHSBvuZyOkIKfiAgXIcOg"
CLIENT_SECRET = "GxfH_QgtexiF6lkXHVKP8F2PHQCgvQ"
PASSWORD = "JwDsXM6zikkNN76"
USER_AGENT = "creating a bot by user/PlentyEstimate842"
USERNAME = "PlentyEstimate842"
cross_post_list = ['baberotica',
'Atlantafreaks95',
'AthenaFaris_',
'AssCracked',
'AshleyBobbio',
'AMELAOMORxo',
'3Somes',
'YummyBoobs',
'yourcollegegirls',
'X0nm_',
'Whopperme_OF',
'Venusmarquezof',
'Tiktoklivenipslips',
'TikThotBabes',
'That_Sexy_Whores',
'taecaldwell',
'Shethickyyy',
'Perculessss',
'Novinha',
'Niquee',
'Mrstrapsavay',
'MissBNastMega',
'MiaFrancisss',
'MellaBarbiexx',
'megane_janell',
'MaluTrevejoOF',
'MaluTrevejo_OF',
'KyRiches',
'KnockoutBoobs',
'Keishlymariee',
'JenforShortt',
'Jeanetteprakash_',
'goatedtruthVids',
'FreakyHoesForever',
'francinepiaiabbb',
'DrippingCum',
'Demontimee',
'DabOfKyaOnly',
'Cherokee_d_ass',
'carolinabell',
'camilabecker',
'BootyHandled',
'BlacChynaOnlyFanss',
'BestPornInGalaxy',
'MollyE',
'youngprettyhoes3',
'onlyfanschicks',
'XlightmoonxX',
'XimenaSaenzNude',
'WeLoveBoobsBigNSmall',
'VIP_PORN_HUB',
'tikthotporn',
'tikthotNSFW',
'ThotsXfam',
'AssVegas',
'BonerMonster']
reddit = praw.Reddit(
client_id=CLIENT_ID,
client_secret=CLIENT_SECRET,
password=PASSWORD,
user_agent=USER_AGENT,
username=USERNAME,
ratelimit_seconds=300,
)
reddit.validate_on_submit = True
redgif_title = url_title['Title'][1]
redgif_title
redgif_url = url_title['URL'][1]
redgif_url
subreddit = reddit.subreddit("ThisHotChick")
title = redgif_title
selftext = redgif_url
try:
submission = subreddit.submit(title, url=selftext)
except Exception as e:
if "RATELIMIT" in str(e):
time.sleep([int(s) for s in str(e).split() if s.isdigit()][0]*60 + 60)
submission = subreddit.submit(title, url=selftext)
else:
print(e)
for i in cross_post_list:
time.sleep(random.randint(60, 200))
try:
cross_post = submission.crosspost(i, send_replies=False, nsfw = True)
except Exception as e:
if "RATELIMIT" in str(e):
time.sleep([int(s) for s in str(e).split() if s.isdigit()][0]*60 + 60)
try:
cross_post = submission.crosspost(i, send_replies=False, nsfw = True)
except Exception as e:
print(e)
# continue
else:
print(e)