UPDATE 12.12.2022
Now ChatGPT has Cloudflare protection.
No Selenium or another testing tools. Pure Python.
Now performs login, handles captcha, sends message and prints ChatGPT answer.
Disclaimer: just for dev purposes.
Create the account for ChatGPT (login by email and password).
$ git clone https://github.com/akdev-tech/python-chatgpt.git
$ cd python-chatgpt
$ python3 -m venv env
$ source env/bin/activate
$ pip install -r requirements.txt
$ python3 main.py -u <email> -p <password> -m "<message>"
If it asks for captcha code, you can take a captcha image at captcha.svg
. The captcha code is case sensitive!
To run in debug
mode add the -vvv
flag.
- Occasional uncatched errors
- Make a module package
- Automatic solving captchas
- Consider ChatGPT rate-limits
- Type annotations