Voni AI Python SDK
The official Python SDK for the Voniai programmable AI infrastructure.
Installation
pip install voniai
Quick Start (Headless Mode)
from voniai import Voni
# Initialize the client (automatically loads VONI_API_KEY from env)
voni = Voni()
# Send a message to your co-pilot
response = voni.chat.send_message(
project_id="your_project_id",
message="How do I integrate Voni?",
session_id="user_123"
)
print(f"AI Response: {response['message']}")
Features
- Robust Security: Automatic HMAC-SHA256 request signing.
- Environment Support: Automatically loads
VONI_API_KEYfrom environment variables. - Project Management: Create and configure projects programmatically.
- Headless Chat: Interact with the AI engine directly without using the pre-built widget.
- Webhook Management: Register and manage webhooks for event-driven workflows.
Authentication
Voni uses an API Key + HMAC Signature for all requests. The SDK handles this automatically. You can provide your API Key during initialization or set the VONI_API_KEY environment variable.
# Option 1: Load from environment (Recommended)
voni = Voni()
# Option 2: Explicitly provide key
voni = Voni(api_key="...")
Error Handling
from voniai import Voni, VoniAuthError, VoniApiError
try:
projects = voni.projects.list()
except VoniAuthError:
print("Authentication failed. Check your API Key.")
except VoniApiError as e:
print(f"API returned an error: {e.status_code}")
License
MIT
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
voniai-0.1.6.tar.gz
(15.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
voniai-0.1.6-py3-none-any.whl
(22.2 kB
view details)
File details
Details for the file voniai-0.1.6.tar.gz.
File metadata
- Download URL: voniai-0.1.6.tar.gz
- Upload date:
- Size: 15.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
165ed705c476f522e6821fb465aa2937f89ba5c6df844cd3a4115e668906b046
|
|
| MD5 |
cd48175ad10bd6fd2cd2c957126a93fb
|
|
| BLAKE2b-256 |
d46d153372e8c815548f7e6e3af7d7709bf71cd8a9afb70cccf62326111161ae
|
File details
Details for the file voniai-0.1.6-py3-none-any.whl.
File metadata
- Download URL: voniai-0.1.6-py3-none-any.whl
- Upload date:
- Size: 22.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
028c3eafea4531177be2e17d81e5b623d5f459d886db60e7b9866b8998dd3d56
|
|
| MD5 |
21d38f2727281f2089f5955eebc7b000
|
|
| BLAKE2b-256 |
6ae64d3a949bcac63774b74158df2dc1eb05f780278e8a0fcf79e59c175a11d2
|