- 258
- 40
Как обойти рекапчу в пост запросе, хочу сделать запрос на смс, но выводит ошибку. Вот код для примера (номер виртуальный).
Консоль
Python:
import requests
import random
import json
import time
number = '+380934611668'
number_bs = number[0:3]
number_rbp = number[1:3] + ' (' + number[3:6] + ') ' + number[7:10] + '-' + number[11:13] + '-' + number[13:15]
_name = ''
for x in range(1,12):
_name = _name + random.choice(list('123456789qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM'))
password = _name + random.choice(list('123456789qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM'))
username = _name + random.choice(list('123456789qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM'))
email = _name + '@gmail.com'
try:
a = requests.post(url='https://rieltor.ua/api/users/register-sms/',
json={
"phone": number[1:],
"retry": 0,
"recaptcha": "03AGdBq26bcuYTRleAVXBi151VXfGlhqYBJKaLortn8Zv2ya1nj4ab5GHfr8jz39tcks5gNgKwmcFC01yYBbTUiGlJl1Cymofs-Ij93byY7TBwEr28Azs40SA43t6rrglNLI-XWeou5lyQ2NB7ozU3eipurDpbBy46ZVYOPlVJkEblpI35_Cv4_TuwPkugC0EeSwEyfV8ELXOEPth_0dS9iFNIcJu-22ydPPDTIR9ctaU4RQfxNIr_EoUOAhhEAjzJiWCXqo346A2x8cxKsdT9b4jbvu2yUEEaUK3Gc0V0YSjJflGSo6EzeKN2125m41JOZ08qr74OS3XC73PfnPyPXO_WunXczSEBGoeePBpfSR0RT6vKjjBRV2MC5R0FqHIg8xf4b3_gmd-SNp8cAMa-_wcR5UveypTB-tGckbsu4xEI_saLkHuC1SVXPAO8ilQ4PQ1AneOqKhK9"
})
print(f'[+] rieltor sent! {a.text}')
except Exception:
print('[-] rieltor sent!')
Консоль
Код:
[+] rieltor sent! {"error":"wrong_captcha","status":"ERROR"}