Provide free GPT-3.5 API service by reverse engineering the login-free ChatGPT website.
docker run -d -p 3040:3040 --name chatgpt-free-api xsigoking/chatgpt-free-api
Download it from GitHub Releases, unzip, and add chatgpt-free-api to your $PATH
.
chatgpt-api-server # Listening on 0.0.0.0:3040, no proxy
PORT=8080 chatgpt-api-server # Use $PORT to change the listening port
ALL_PROXY=http://localhost:18080 chatgpt-api-server # Use $ALL_PROXY to set the proxy server
curl http://127.0.0.1:3040/v1/chat/completions \
-i -X POST \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-3.5-turbo",
"messages": [
{
"role": "user",
"content": "Hello!"
}
],
"stream": true
}'
The project is under the MIT License, Refer to the LICENSE file for detailed information.