authsquare/app/scripts/googly.py

12 lines
294 B
Python
Raw Normal View History

2024-06-17 17:31:07 +07:00
import json
import requests
def recaptcha(captcha, secret):
url = "https://www.google.com/recaptcha/api/siteverify"
myobj = {
"secret" : secret,
"response" : captcha
}
response = json.loads(requests.post(url, data = myobj).text)
return response