55import string
66
77import os
8+ import time
89
910from threading import Thread , active_count
1011
1112
12- script_version = "1.2 "
13+ script_version = "2.0 "
1314script_title = "Spotify Account Creator By ALIILAPRO"
1415script_info = f'''
1516 ..: { script_title } :..
2425 [-] Telegram : aliilapro
2526 --------
2627'''
27-
2828class Main :
2929
3030 def clear (self , text ):
@@ -34,49 +34,17 @@ def clear(self, text):
3434 def settitle (self , title_name :str ):
3535 os .system ("title {0}" .format (title_name ))
3636
37- def readfile (self , filename , method ):
38- with open (filename ,method ) as f :
39- content = [line .strip ('\n ' ) for line in f ]
40-
41- return content
42-
43- def countfile (self , filename , method ):
44- file = open (filename ,method )
45- Counter = 0
46- Content = file .read ()
47- CoList = Content .split ("\n " )
48- for i in CoList :
49- if i :
50- Counter += 1
51-
52- return Counter
53-
54- def getproxy (self ):
55- r = requests .get ('https://xcoder.fun/p.php?r=y' )
56-
57- with open ('proxy.txt' ,'w' ) as fd :
58- fd .write (r .text .replace ('\n ' ,'' ))
59-
60- def getrandomproxy (self ):
61- proxies_file = self .readfile ('proxy.txt' ,'r' )
62- proxies = {
63- "http" :"http://{0}" .format (random .choice (proxies_file )),
64- "https" :"https://{0}" .format (random .choice (proxies_file ))
65- }
66-
67- return proxies
68-
6937 def __init__ (self ):
7038 self .settitle (script_title )
7139 self .clear (script_info )
72- self .getproxy ()
7340 self .email = input ('[#] Enter Email: ' )
7441 self .password = input ('[#] Enter Password: ' )
7542 self .birth_year = int (input ('[#] Enter the birth year (only year): ' ))
7643 self .birth_month = int (input ('[#] Enter the birth month (1 - 12): ' ))
7744 self .birth_day = int (input ('[#] Enter the birth day (1 - 28): ' ))
7845 self .gender = input ('[#] Enter the gender (male or female): ' )
79- self .threads = self .countfile ('proxy.txt' ,'r' )
46+ self .threads = 10
47+
8048
8149 def gencredentailsmethod (self ):
8250 credentails = {}
@@ -94,50 +62,61 @@ def gencredentailsmethod(self):
9462
9563 def creator (self ):
9664 try :
65+ session = requests .Session ()
9766
9867 headers = {
99- 'User-agent' : 'S4A/2.0.15 (com.spotify.s4a; build:201500080; iOS 13.4.0) Alamofire/4.9.0' ,
100- 'Content-Type' : 'application/x-www-form-urlencoded; charset=utf-8' ,
101- 'Accept' : 'application/json, text/plain;q=0.2, */*;q=0.1' ,
102- 'App-Platform' : 'IOS' ,
103- 'Spotify-App' : 'S4A' ,
104- 'Accept-Language' : 'en-TZ;q=1.0' ,
105- 'Accept-Encoding' : 'gzip;q=1.0, compress;q=0.5' ,
106- 'Spotify-App-Version' : '2.0.15'
68+ "Accept" : "*/*" ,
69+ "User-Agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4280.141 Safari/537.36" ,
70+ "Content-Type" : "application/x-www-form-urlencoded" ,
71+ "Referer" : "https://www.spotify.com/"
10772 }
10873
109-
110- url = 'https://spclient.wg.spotify.com/signup/public/v1/account'
11174 credentails = self .gencredentailsmethod ()
112- data = 'creation_point=lite_7e7cf598605d47caba394c628e2735a2&password_repeat={0}&platform=Android-ARM&iagree=true&password={1}&gender={2}&key=a2d4b979dc624757b4fb47de483f3505&birth_day={3}&birth_month={4}&email={5}&birth_year={6}' .format (credentails ['password' ],credentails ['password' ],credentails ['gender' ],credentails ['birth_day' ],credentails ['birth_month' ],credentails ['email' ],credentails ['birth_year' ])
113- req = requests .post (url = url , data = data , headers = headers , proxies = self .getrandomproxy (), timeout = 5 )
114- json_data = json .loads (req .text )
115-
116-
117- if 'status' in json_data :
118- if json_data ['status' ] == 1 :
119- username = json_data ['username' ]
120- if username != '' :
121- self .clear (script_info )
122- print ('[>] ACCOUNT CREATED SUCCESSFULLY\n [-] Email:{0}\n [-] Password:{1}\n [-] Username:{2}\n [-] Gender:{3}\n [-] Birth year:{4}\n [-] Birth month:{5}\n [-] Birth day:{6}\n ' .format (credentails ['email' ],credentails ['password' ],credentails ['username' ],credentails ['gender' ],credentails ['birth_year' ],credentails ['birth_month' ],credentails ['birth_day' ]))
123- with open ('reg.txt' ,'a' ) as f :
124- f .write ('[INFO ACCOUNT]\n Email:{0}\n Password:{1}\n Username:{2}\n Gender:{3}\n Birth year:{4}\n Birth month:{5}\n Birth day:{6}\n ___________________\n \n ' .format (credentails ['email' ],credentails ['password' ],credentails ['username' ],credentails ['gender' ],credentails ['birth_year' ],credentails ['birth_month' ],credentails ['birth_day' ]))
125- else :
126- self .creator ()
127- else :
128- self .creator ()
75+ data = 'birth_day={0}&birth_month={1}&birth_year={2}&collect_personal_info=undefined&creation_flow=&creation_point=https://www.spotify.com/uk/&displayname={3}&email={4}&gender={5}&iagree=1&key=a1e486e2729f46d6bb368d6b2bcda326&password={6}&password_repeat={7}&platform=www&referrer=&send-email=1&thirdpartyemail=0&fb=0' .format (credentails ['birth_day' ],credentails ['birth_month' ],credentails ['birth_year' ],credentails ['username' ],credentails ['email' ],credentails ['gender' ],credentails ['password' ],credentails ['password' ])
76+ req = session .post ("https://spclient.wg.spotify.com/signup/public/v1/account" , headers = headers , data = data )
77+ if "login_token" in req .text :
78+ login_token = req .json ()['login_token' ]
79+
12980 else :
130- self .creator ()
131- except :
132- self .creator ()
81+ return
13382
83+ r = session .get ("https://www.spotify.com/uk/signup/?forward_url=https://accounts.spotify.com/en/status&sp_t_counter=1" )
84+ crsf = r .text .split ('csrfToken":"' )[1 ].split ('"' )[0 ]
85+
86+ headers = {
87+ "Accept" : "*/*" ,
88+ "User-Agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36" ,
89+ "Content-Type" : "application/x-www-form-urlencoded" ,
90+ "X-CSRF-Token" : crsf ,
91+ "Host" : "www.spotify.com"
92+ }
93+ session .post ("https://www.spotify.com/api/signup/authenticate" , headers = headers , data = "splot=" + login_token )
94+ headers = {
95+ "accept" : "application/json" ,
96+ "Accept-Encoding" : "gzip, deflate, br" ,
97+ "accept-language" : "en" ,
98+ "User-Agent" : "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36" ,
99+ "spotify-app-version" : "1.1.52.204.ge43bc405" ,
100+ "app-platform" : "WebPlayer" ,
101+ "Host" : "open.spotify.com" ,
102+ "Referer" : "https://open.spotify.com/"
103+ }
104+
105+ r = session .get ("https://open.spotify.com/get_access_token?reason=transport&productType=web_player" , headers = headers )
106+ token = r .json ()["accessToken" ]
107+ self .settitle (script_title )
108+ self .clear (script_info )
109+ print ('[>] ACCOUNT CREATED SUCCESSFULLY\n [-] Email:{0}\n [-] Password:{1}\n [-] Username:{2}\n [-] Gender:{3}\n [-] Birth year:{4}\n [-] Birth month:{5}\n [-] Birth day:{6}\n ' .format (credentails ['email' ],credentails ['password' ],credentails ['username' ],credentails ['gender' ],credentails ['birth_year' ],credentails ['birth_month' ],credentails ['birth_day' ]))
110+ with open ('ACCOUNT-SPOTIFY.txt' ,'a' ) as f :
111+ f .write ('[INFO ACCOUNT]\n Email:{0}\n Password:{1}\n Username:{2}\n Gender:{3}\n Birth year:{4}\n Birth month:{5}\n Birth day:{6}\n Token:{7}\n ___________________\n \n ' .format (credentails ['email' ],credentails ['password' ],credentails ['username' ],credentails ['gender' ],credentails ['birth_year' ],credentails ['birth_month' ],credentails ['birth_day' ],token ))
112+ except Exception as e :
113+ print (e )
134114
135115 def start (self ):
136116 while True :
137- if active_count () <= self .threads :
117+ if active_count () < self .threads :
138118 Thread (target = self .creator ).start ()
139119
140-
141120if __name__ == "__main__" :
142121 main = Main ()
143122 main .start ()
0 commit comments