A secure and efficient gateway for interacting with OpenAI's API, featuring load balancing, user request handling without individual API keys, and global access control.
OpenAI Hub is a comprehensive and robust tool designed to streamline and enhance your interaction with OpenAI's API. It features an innovative way to load balance multiple API keys, allowing users to make requests without needing individual OpenAI API keys. Additionally, it employs a global access control list (ACL) that gives you the power to regulate which APIs and models users can utilize. The Hub also includes JWT Authentication for secure and reliable user authentication, and now, an Access Log feature for tracking API usage and token consumption.
You can run OpenAI Hub either by cloning the repository and using Cargo, or by using Docker.
git clone https://github.com/lightsing/openai-hub.git
cd openai-hub
# build and run
cargo run run --bin openai-hubd --all-features --release
# pull the Docker image
docker pull lightsing/openai-hub:latest
# run the Docker container
docker run -p 8080:8080 lightsing/openai-hub
# or with your custom configs
docker run -v /your/path/to/config:/opt/openai-hub/config -p <yourport> lightsing/openai-hub
Please replace username
with the appropriate GitHub username.
We're always working to improve OpenAI Hub and add new features. Stay tuned for these exciting updates!
We encourage you to contribute to OpenAI Hub! Please check out the Contributing to OpenAI Hub guide for guidelines about how to proceed.
OpenAI Hub is released under the MIT License.
If you have any questions, issues, or suggestions for improvement, please feel free to open an issue in this repository or contact us directly.
We're excited to see how you'll use OpenAI Hub!