Open an issue in the appropriate repository or here for any complaints about me as a human.
acheong08 / chatgptproxy Goto Github PK
View Code? Open in Web Editor NEWSimple Cloudflare bypass for ChatGPT
License: The Unlicense
Simple Cloudflare bypass for ChatGPT
License: The Unlicense
Open an issue in the appropriate repository or here for any complaints about me as a human.
生成的反向代理地址路径是什么,直接访问页面显示404
openai return 500 Internal Server Error
服务器不支持ChatGPT,可以使用socks或http代理么?
> go install github.com/acheong08/ChatGPT-Proxy-V4@latest
# github.com/fvbock/endless
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:64:11: undefined: syscall.SIGUSR1
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:65:11: undefined: syscall.SIGUSR2
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:68:11: undefined: syscall.SIGTSTP
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:111:13: undefined: syscall.SIGUSR1
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:112:13: undefined: syscall.SIGUSR2
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:115:13: undefined: syscall.SIGTSTP
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:119:13: undefined: syscall.SIGUSR1
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:120:13: undefined: syscall.SIGUSR2
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:123:13: undefined: syscall.SIGTSTP
..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:224:11: undefined: syscall.Kill..\..\go\pkg\mod\github.com\fvbock\[email protected]\endless.go:224:11: too many errors
I got ChatGPT plus
It is able to translate given vtt file if you give input as chunks
but this is extremely tedious
Can I use this for this task?
please add some more info how to use to readme file
basically no info provided there
any guides tutorials documentation examples?
Permanently Error: 500 Internal Server Error
现在这个还可以过CF吗? 我不太会部署,请教一下
Anyone got banned using this with plus accounts?
Hey!!!
Thanks for this awesome project. Can you please provide some more documentation and its features?
Is this project only a proxy server? Or can it also get the access tokens using the email:password? I think not, but can I use your chatgpt-to-api project to achieve that functionality combined with this project?
Is there an python code ?
Where do you find them? is access_token __Secure-next-auth.session-token? and what is the puid taken from?
部署完成后报403,是不是因为部署这个代理服务的机器被墙了。大家有啥可以用的云机推荐么
..
Where do puid come from? I don't have a puid field in my cookie
how to solve this error
又新增变量了吗,这个怎么获取,
If I compile this tool from scratch and run it correctly, does it mean that the relevant API token in ChatGPT does not need to be configured separately?
How does it work without setting any Cloudflare related cookies? I checked your code did not set any __cf_bm
related cookies, how does it bypass cloudflare? Is it because tls_client
can bypass it? I saw the cloudflare related profile here: https://github.com/bogdanfinn/tls-client/blob/09eace9c44148f7d8fccf8e829baebf14edce1d9/custom_profiles.go#L398
I had used both puid and access_token, and got response: 200 OK when the proxy start.But got 401 when I request the api.
curl "http://127.0.0.1:8080/api/conversations?offset=0&limit=20"
{"detail":{"message":"Unauthorized - Access token is missing"}}
Is it a alias of Secret key? if true , what function the program do?
Proxy-V4 shows
[GIN] 2023/04/17 - 03:52:06 | 403 | 55.76265ms | 127.0.0.1 | GET "/api/conversation/cc726f70-4963-1cf5-b0bd-faf50560d26a"
[GIN] 2023/04/17 - 03:52:06 | 403 | 8.479793ms | 127.0.0.1 | POST "/api/conversation"
revChatGPT/V1.py shows
File "/home/ec2-user/.local/lib/python3.11/site-packages/revChatGPT/V1.py", line 696, in __check_response
raise error from e
revChatGPT.typings.Error: OpenAI: error code: 1020 (code: 403)
But revChatGPT/V1.py works well with the default proxy https://chat.gateway.do/api/
You do not have access to chat.openai.com.
The site owner may have set restrictions that prevent you from accessing the site.
Got response: 200 OK
│ puid: user-
│ 2023/04/06 02:16:17 1 Received SIGTERM. │
│ 2023/04/06 02:16:17 1 Waiting for connections to finish... │
│ 2023/04/06 02:16:17 1 Serve() returning... │
│ Stream closed EOF for default/chatgpt-proxy-v4-7b57b74bb9-5wl95 (chatgpt-proxy-v4)
$ ChatGPT-Proxy-V4
[GIN-debug] [WARNING] Creating an Engine instance with the Logger and Recovery middleware already attached.
[GIN-debug] [WARNING] Running in "debug" mode. Switch to "release" mode in production.
[GIN-debug] GET /ping --> main.main.func2 (3 handlers)
[GIN-debug] GET /api/*path --> main.proxy (3 handlers)
[GIN-debug] POST /api/*path --> main.proxy (3 handlers)
[GIN-debug] PUT /api/*path --> main.proxy (3 handlers)
[GIN-debug] PATCH /api/*path --> main.proxy (3 handlers)
[GIN-debug] HEAD /api/*path --> main.proxy (3 handlers)
[GIN-debug] OPTIONS /api/*path --> main.proxy (3 handlers)
[GIN-debug] DELETE /api/*path --> main.proxy (3 handlers)
[GIN-debug] CONNECT /api/*path --> main.proxy (3 handlers)
[GIN-debug] TRACE /api/*path --> main.proxy (3 handlers)
2023/04/03 20:40:22 2243901 :8080
Error: Failed to refresh puid cookie
I have adapted this proxy for my own use, and I was wondering what the license is and if I can publish my tweaks
之前一直用好好地,现在不行了,换了puid和access_token也不行,查看日志报错如下:
[GIN-debug] [WARNING] Creating an Engine instance with the Logger and Recovery middleware already attached.
[GIN-debug] [WARNING] Running in "debug" mode. Switch to "release" mode in production.
[GIN-debug] GET /ping --> main.main.func2 (3 handlers)
[GIN-debug] GET /api/*path --> main.proxy (3 handlers)
[GIN-debug] POST /api/*path --> main.proxy (3 handlers)
[GIN-debug] PUT /api/*path --> main.proxy (3 handlers)
[GIN-debug] PATCH /api/*path --> main.proxy (3 handlers)
[GIN-debug] HEAD /api/*path --> main.proxy (3 handlers)
[GIN-debug] OPTIONS /api/*path --> main.proxy (3 handlers)
[GIN-debug] DELETE /api/*path --> main.proxy (3 handlers)
[GIN-debug] CONNECT /api/*path --> main.proxy (3 handlers)
[GIN-debug] TRACE /api/*path --> main.proxy (3 handlers)
[GIN-debug] POST /admin/update --> main.main.func3 (3 handlers)
2023/04/15 21:28:14 115812 :8080
Got response: 403 Forbidden
Error: 403 Forbidden
Please stand by, while we are checking your browser...
Redirecting...
ChatGPT-Proxy-V4
[GIN-debug] [WARNING] Creating an Engine instance with the Logger and Recovery middleware already attached.
[GIN-debug] [WARNING] Running in "debug" mode. Switch to "release" mode in production.
[GIN-debug] GET /ping --> main.main.func2 (3 handlers)
[GIN-debug] GET /api/*path --> main.proxy (3 handlers)
[GIN-debug] POST /api/*path --> main.proxy (3 handlers)
[GIN-debug] PUT /api/*path --> main.proxy (3 handlers)
[GIN-debug] PATCH /api/*path --> main.proxy (3 handlers)
[GIN-debug] HEAD /api/*path --> main.proxy (3 handlers)
[GIN-debug] OPTIONS /api/*path --> main.proxy (3 handlers)
[GIN-debug] DELETE /api/*path --> main.proxy (3 handlers)
[GIN-debug] CONNECT /api/*path --> main.proxy (3 handlers)
[GIN-debug] TRACE /api/*path --> main.proxy (3 handlers)
2023/03/16 23:49:30 3000 :8080
Error: Failed to refresh puid cookie
2023/03/15 16:13:01 23368 :8080
Got response: 403 Forbidden
Error: 403 Forbidden
error code: 1020
Error: Failed to refresh puid cookie
2023/03/15 16:13:13 23368 Received SIGINT.
2023/03/15 16:13:13 23368 Waiting for connections to finish...
2023/03/15 16:13:13 23368 Serve() returning...
So, I exported the PUID and Access token via export ACCESS_TOKEN="..." & export PUID="..."
in the repos' directory on my Linux machine.
When starting the server, I get the ol' 404: Not found error.
@acheong08 suggested here that a CHATGPT_BASE_URL environment variable has to be set.
But no matter what I set as the value, I keep getting 404. I entered export CHATGPT_BASE_URL="https://chat.openai.com/chat?model=gpt-4"
in the bin directory just like I did with the PUID and Access Token, but I got the same error. Changing the Base URL to chat.openai.com or different variations didn't help.
Can someone - maybe hopefully @acheong08 themselves - help?
thanks for your work, and , can you tell me why ChatGPT plus account is required other than normal account?
C:\Users\jiraf.config\revChatGPT>python -m revChatGPT.V1
ChatGPT - A command-line interface to OpenAI's ChatGPT (https://chat.openai.com/chat)
Repo: github.com/acheong08/ChatGPT
Type '!help' to show a full list of commands
←[1m←[93mPress Esc followed by Enter or Alt+Enter to send a message.←[0m
←[94m←[1mYou: ←[0m
hello
←[92m←[1mChatbot: ←[0m
Traceback (most recent call last):
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connectionpool.py", line 696, in urlopen
self._prepare_proxy(conn)
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connectionpool.py", line 964, in _prepare_proxy
conn.connect()
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connection.py", line 371, in connect
self._tunnel()
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\http\client.py", line 924, in _tunnel
raise OSError(f"Tunnel connection failed: {code} {message.strip()}")
OSError: Tunnel connection failed: 404 Not Found
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\adapters.py", line 489, in send
resp = conn.urlopen(
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen
retries = retries.increment(
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\urllib3\util\retry.py", line 574, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='bypass.churchless.tech', port=443): Max retries exceeded with url: /api/conversation (Caused by ProxyError('Cannot connect to proxy.', OSError('Tunnel connection failed: 404 Not Found')))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\V1.py", line 962, in main
for data in chatbot.ask(prompt):
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\V1.py", line 443, in ask
response = self.session.post(
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\sessions.py", line 635, in post
return self.request("POST", url, data=data, json=json, **kwargs)
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\sessions.py", line 587, in request
resp = self.send(prep, **send_kwargs)
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\sessions.py", line 701, in send
r = adapter.send(request, **kwargs)
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\adapters.py", line 559, in send
raise ProxyError(e, request=request)
requests.exceptions.ProxyError: HTTPSConnectionPool(host='bypass.churchless.tech', port=443): Max retries exceeded with url: /api/conversation (Caused by ProxyError('Cannot connect to proxy.', OSError('Tunnel connection failed: 404 Not Found')))
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\V1.py", line 986, in
main(configure())
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\V1.py", line 58, in wrapper
out = func(*args, **kwargs)
File "C:\Users\jiraf\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\V1.py", line 972, in main
raise error from e
revChatGPT.typings.CLIError: command line program unknown error
The chatbot works like a charm without a proxy, with proxy it begins to have problems, I look over the issues about CHATGPT_BASE_URL, it works but does not connect to proxy server on linux virtual machine.
How can I use it with https://github.com/acheong08/ChatGPT, or I have to implement that by myself?
Proxy:
[GIN] 2023/03/31 - 09:59:47 | 404 | 179.137025ms | 10.0.2.2 | GET "/api/"
[GIN] 2023/03/31 - 09:59:50 | 405 | 178.347612ms | 10.0.2.2 | GET "/api/conversation"
[GIN] 2023/03/31 - 10:01:21 | 200 | 259.397µs | 10.0.2.2 | GET "/ping"
Host:
{"detail":"Not Found"} (404)
{"detail":"Method Not Allowed"} (405)
{"message":"pong"} (200)
If there are applications that can use this proxy?
[ChatGPT error 429: {"detail":"Only one message at a time. Please allow any other responses to complete before sending another message, or wait one minute."}]
does someone run into this situation?
thanks for your works, can you tell some details difference between them?I have to make a choice between them.
When I trying to test ChatgptAPI, I've receive 404 error.
Error code from revChatGPT.V1
python3 -m revChatGPT.V1
ChatGPT - A command-line interface to OpenAI's ChatGPT (https://chat.openai.com/chat)
Repo: github.com/acheong08/ChatGPT
Type '!help' to show a full list of commands
Press Esc followed by Enter or Alt+Enter to send a message.
You:
hi
Chatbot:
Traceback (most recent call last):
File "/Users/noirmist/opt/anaconda3/envs/gpt/lib/python3.11/site-packages/urllib3/connectionpool.py", line 700, in urlopen
self._prepare_proxy(conn)
File "/Users/noirmist/opt/anaconda3/envs/gpt/lib/python3.11/site-packages/urllib3/connectionpool.py", line 996, in _prepare_proxy
conn.connect()
File "/Users/noirmist/opt/anaconda3/envs/gpt/lib/python3.11/site-packages/urllib3/connection.py", line 369, in connect
self._tunnel()
File "/Users/noirmist/opt/anaconda3/envs/gpt/lib/python3.11/http/client.py", line 924, in _tunnel
raise OSError(f"Tunnel connection failed: {code} {message.strip()}")
OSError: Tunnel connection failed: 404 Not Found
I guess, I have issue to setting proxy server. Please share some information to setting the proxy.
chatgpt-web项目:https://github.com/Chanzhaoyu/chatgpt-web
Hello,
Ran into some trouble using the unofficial ChatGPT API today; looks like it's caused by a Bad Gateway from bypass.churchless.tech (my apologies if this isn't the correct repository for churchless).
Here's an example response after trying to query all conversations. I didn't show my access token for obvious reasons, but it's valid & non expired (plus, the endpoint seems to fail regardless of a valid token).
Thanks.
I already set it via modifying main.go but it still saying when trying to run
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.