zmp-openapi-toolkit
Introduction
This is a toolkit library for the LLM application using the multiple openapi specifications
Key Features
- Support the OpenAPI request wrapper
- OpenAPI parameters and request type validation
- Convenient authentication management
Installation
Install using pip:
pip install zmp-openapi-toolkit
Install using poetry:
poetry add zmp-openapi-toolkit
Usage
Basic example:
import logging
import logging.config
from typing import List
from zmp_openapi_toolkit import (
MixedAPISpecConfig,
ZmpAPIWrapper,
ZmpTool,
ZmpToolkit,
)
logging.getLogger("zmp_openapi_toolkit.openapi.zmpapi_models").setLevel(logging.INFO)
logging.getLogger("zmp_openapi_toolkit.toolkits.toolkit").setLevel(logging.INFO)
if __name__ == "__main__":
mixed_api_spec_config = MixedAPISpecConfig.from_mixed_spec_file(
file_path="samples/openapi/zmp_mixed_api_spec.json"
)
zmp_api_wrapper = ZmpAPIWrapper(
"https://your.server.com", mixed_api_spec_config=mixed_api_spec_config
)
toolkit = ZmpToolkit.from_zmp_api_wrapper(zmp_api_wrapper=zmp_api_wrapper)
tools: List[ZmpTool] = toolkit.get_tools()
For more detailed usage instructions, please refer to our documentation.
Development Setup
- Clone the repository
git clone https://github.com/yourusername/zmp-openapi-toolkit.git
cd zmp-openapi-toolkit
- Create and activate virtual environment
python -m venv .venv
source .venv/bin/activate # Windows: venv\Scripts\activate
- Install development dependencies
poetry install
Contributing
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Contact
- Issue Tracker: https://github.com/yourusername/zmp-openapi-toolkit/issues
- Email: kilsoo75@gmail.com
Metadata
Release files for zmp-openapi-toolkit 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| zmp_openapi_toolkit-0.2.0.tar.gz | 4.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| zmp_openapi_toolkit-0.2.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 10.7 kB
Release files / zmp_openapi_toolkit-0.2.0.tar.gz
| Download URL | zmp_openapi_toolkit-0.2.0.tar.gz |
|---|---|
| Size | 4.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
e916fbb837027790ce2a16180b6a5d985aa52b827acab11abb333d8f64b673d0
|
|
BLAKE2b-256 checksum How to use checksums |
6d2afe51867b84fa538d18ae953b54bdc8033035bb32d5406b5a4f9f013786cb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.1 CPython/3.11.10 Darwin/24.3.0
|
Release files / zmp_openapi_toolkit-0.2.0-py3-none-any.whl
| Download URL | zmp_openapi_toolkit-0.2.0-py3-none-any.whl |
|---|---|
| Size | 5.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
37ead12da59a1b41b8a4ac152e36fe5a9f7c68508eaf40842c05f5f2a69097f8
|
|
BLAKE2b-256 checksum How to use checksums |
6a7daea4a7c8e4063aa69b2574224d2823811215197d57bc32108da68d9b78e3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.1.1 CPython/3.11.10 Darwin/24.3.0
|