# GenAIKeys [WIP]
GenAIKeys is a Python library that streamlines API key management for Generative AI applications by securely
storing the keys in cloud secret vaults like [Azure Key Vault](https://azure.microsoft.com/en-us/services/key-vault/),
[AWS Secrets Manager](https://aws.amazon.com/secrets-manager/), and [Google Secret Manager](https://cloud.google.com/secret-manager).
> **Disclaimer**: Please exercise caution when using this package in production environments. We recommend that you
> review the codebase and ensure that it meets your security requirements before deploying it in a production environment.
[![PyPI version](https://badge.fury.io/py/genaikeys.svg)](https://badge.fury.io/py/genaikeys)
[![License](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)
## Features
- 🔐 Secure API key management for GenAI services
- 🚀 Zero environment variable configuration
- ⚡️ Direct integration with cloud secret vaults
- 🔌 Built-in support for OpenAI, Anthropic, and Google Gemini
- 🛠 Extensible architecture for custom secret backends
## Installation
```bash
pip install genaikeys
```
## Quick Start
```python
from genaikeys import SecretKeeper
# Initialize GenAIKeys
skp = SecretKeeper.from_defaults()
# Get API keys directly
api_key = skp.get('huggingface-api-key')
# Use convenience methods
openai_key = skp.get_openai_key()
anthropic_key = skp.get_anthropic_key()
gemini_key = skp.get_gemini_key()
```
## Configuration
* By default, GenAIKeys uses the `Azure Key Vault` secret backend. You can configure the secret backend by setting
the `SECRET_KEEPER_BACKEND` environment variable to one of the following values:
- `AZURE`
- `AWS`
- `GCP`
* We recommend setting the `SECRET_KEEPER_BACKEND` environment variable in a persistent configuration file like
`.bashrc` or `.zshrc`.*
* You will also need to provide the configurations for the secret backend you choose.
#### Azure Key Vault
- The following environment variables are required for the `Azure Key Vault` secret backend:
- `AZURE_KEY_VAULT_URL`
- Optionally you can also provide the following environment variables:
- `MANGED_IDENTITY_CLIENT_ID` (for User Assigned Managed Identity authentication)
#### AWS Secrets Manager [WIP]
#### Google Secret Manager [WIP]
## Documentation
For detailed usage instructions, API reference, and advanced configuration options, visit
our [documentation](https://docs.GenAIKeys.dev).
## Contributing
We welcome contributions! Please see our [contribution guidelines](CONTRIBUTING.md) before submitting pull requests.
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
Raw data
{
"_id": null,
"home_page": "https://github.com/ndamulelonemakh/genaikeys",
"name": "genaikeys",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.10",
"maintainer_email": null,
"keywords": "secrets, AI, cloud, vault, security",
"author": "Ndamulelo Nemakhavhani",
"author_email": "ndamulelo@rihonegroup.com",
"download_url": "https://files.pythonhosted.org/packages/36/66/cd1c3245545c0210541b7872ad4dd9d41137a2226f4774231701ab5ff73c/genaikeys-0.0.1rc2.tar.gz",
"platform": null,
"description": "# GenAIKeys [WIP]\n\nGenAIKeys is a Python library that streamlines API key management for Generative AI applications by securely\nstoring the keys in cloud secret vaults like [Azure Key Vault](https://azure.microsoft.com/en-us/services/key-vault/), \n[AWS Secrets Manager](https://aws.amazon.com/secrets-manager/), and [Google Secret Manager](https://cloud.google.com/secret-manager).\n\n> **Disclaimer**: Please exercise caution when using this package in production environments. We recommend that you\n> review the codebase and ensure that it meets your security requirements before deploying it in a production environment.\n\n[![PyPI version](https://badge.fury.io/py/genaikeys.svg)](https://badge.fury.io/py/genaikeys)\n[![License](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n\n## Features\n\n- \ud83d\udd10 Secure API key management for GenAI services\n- \ud83d\ude80 Zero environment variable configuration\n- \u26a1\ufe0f Direct integration with cloud secret vaults\n- \ud83d\udd0c Built-in support for OpenAI, Anthropic, and Google Gemini\n- \ud83d\udee0 Extensible architecture for custom secret backends\n\n## Installation\n\n```bash\npip install genaikeys\n```\n\n## Quick Start\n\n```python\nfrom genaikeys import SecretKeeper\n\n# Initialize GenAIKeys\nskp = SecretKeeper.from_defaults()\n\n# Get API keys directly\napi_key = skp.get('huggingface-api-key')\n\n# Use convenience methods\nopenai_key = skp.get_openai_key()\nanthropic_key = skp.get_anthropic_key()\ngemini_key = skp.get_gemini_key()\n```\n\n## Configuration\n\n* By default, GenAIKeys uses the `Azure Key Vault` secret backend. You can configure the secret backend by setting\n the `SECRET_KEEPER_BACKEND` environment variable to one of the following values:\n - `AZURE`\n - `AWS`\n - `GCP`\n* We recommend setting the `SECRET_KEEPER_BACKEND` environment variable in a persistent configuration file like\n `.bashrc` or `.zshrc`.*\n\n* You will also need to provide the configurations for the secret backend you choose.\n\n#### Azure Key Vault\n\n- The following environment variables are required for the `Azure Key Vault` secret backend:\n - `AZURE_KEY_VAULT_URL`\n- Optionally you can also provide the following environment variables:\n - `MANGED_IDENTITY_CLIENT_ID` (for User Assigned Managed Identity authentication)\n\n#### AWS Secrets Manager [WIP]\n\n#### Google Secret Manager [WIP]\n\n## Documentation\n\nFor detailed usage instructions, API reference, and advanced configuration options, visit\nour [documentation](https://docs.GenAIKeys.dev).\n\n## Contributing\n\nWe welcome contributions! Please see our [contribution guidelines](CONTRIBUTING.md) before submitting pull requests.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A convenient secret retrieval proxy backed by cloud scale secret vaults",
"version": "0.0.1rc2",
"project_urls": {
"Homepage": "https://github.com/ndamulelonemakh/genaikeys",
"Repository": "https://github.com/ndamulelonemakh/genaikeys"
},
"split_keywords": [
"secrets",
" ai",
" cloud",
" vault",
" security"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "08f7796ddd01508c4ef767702a5a3d4269be22aa8add446ea83e4857acc63d3b",
"md5": "9b91f3228bd790a2d6fbdaa63671f81f",
"sha256": "9c575798312404ff024f638cb9a8e1153dfb90fc16cfacea679aa8d4ecd62ef4"
},
"downloads": -1,
"filename": "genaikeys-0.0.1rc2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "9b91f3228bd790a2d6fbdaa63671f81f",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.10",
"size": 7813,
"upload_time": "2024-11-23T07:00:02",
"upload_time_iso_8601": "2024-11-23T07:00:02.532405Z",
"url": "https://files.pythonhosted.org/packages/08/f7/796ddd01508c4ef767702a5a3d4269be22aa8add446ea83e4857acc63d3b/genaikeys-0.0.1rc2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "3666cd1c3245545c0210541b7872ad4dd9d41137a2226f4774231701ab5ff73c",
"md5": "2fba4505dc512043256702711f3bf064",
"sha256": "505bb5bbbd4153cb953c29e576534bc0bd0e465dc0a2db10ac712cf03a7f2d24"
},
"downloads": -1,
"filename": "genaikeys-0.0.1rc2.tar.gz",
"has_sig": false,
"md5_digest": "2fba4505dc512043256702711f3bf064",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.10",
"size": 5497,
"upload_time": "2024-11-23T07:00:04",
"upload_time_iso_8601": "2024-11-23T07:00:04.349800Z",
"url": "https://files.pythonhosted.org/packages/36/66/cd1c3245545c0210541b7872ad4dd9d41137a2226f4774231701ab5ff73c/genaikeys-0.0.1rc2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-11-23 07:00:04",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "ndamulelonemakh",
"github_project": "genaikeys",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"requirements": [],
"lcname": "genaikeys"
}