node-chatgpt-api
Free4.2k
About node-chatgpt-api
node-chatgpt-api is an open-source client implementation for ChatGPT and Bing AI, developed by waylaidwanderer. It supports multiple integration modes: a Node.js module for programmatic use, a REST API server for web services, and a CLI app for command-line interactions. The library provides support for the official OpenAI gpt-3.5-turbo model (the same model behind ChatGPT), as well as fallback to text-davinci-003. It also includes an experimental ChatGPTBrowserClient that leverages a Cloudflare bypass to access chat.openai.com without browser automation, and support for reverse proxy servers to access underlying ChatGPT models. Features like userLabel, chatGptLabel, and promptPrefix allow customization of system instructions. Docker support is available via Dockerfile and docker-compose.yml.
Key Features
Pros & Cons
- Multiple deployment modes (module, REST API, CLI) for flexibility
- Supports both official API (gpt-3.5-turbo) and browser-based access
- Active development with frequent updates and community contributions
- Free and open source with permissive license
- Docker support simplifies setup and deployment
- Using browser-based methods may risk account ban from OpenAI
- Reverse proxy servers expose access token to third-party servers
- Official API usage incurs costs (though relatively cheap at $0.002/1k tokens)
- Experimental features like ChatGPTBrowserClient may be unstable or break