Created
April 4, 2021 09:11
-
-
Save esfomeado/becbe4aa1fa3553fd6916f2ef920caba to your computer and use it in GitHub Desktop.
Find Gleam giveaways and add them to GleamList
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import itertools | |
import requests | |
# Function to convert | |
def listToString(s): | |
str1 = "" | |
for ele in s: | |
str1 += ele | |
return str1 | |
# Function to check giveaway | |
def checkGiveaway(comb): | |
url = "https://gleam.io/" + listToString(comb) + "/a" | |
r = session.get(url, timeout=3) | |
if(r.status_code == 200): | |
data = {'urlToUpdate': url} | |
x = requests.put("http://gleamlist.com:5000/api", data) | |
if x.status_code != 200: | |
print("Error submiting to Gleam List") | |
else: | |
print("Added " + url + " to Gleam List") | |
# Start process | |
print("Finding giveaways...") | |
session = requests.Session() | |
for comb in itertools.permutations(['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'w', 'v', 'y', 'x', 'z', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'W', 'V', 'Y', 'X', 'Z'], 5): | |
checkGiveaway(comb) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment