SecurHost Python SDK
Official Python SDK for the SecurHost AI Gateway. Provides intelligent LLM routing, real-time voice sessions, autonomous job agents, custom personas, website chatbots, enterprise ERP connectors, automated failover, and cost telemetry.
📦 Installation
Direct Install via GitHub (Recommended)
pip install git+https://github.com/Zhost-Consulting-Private-Limited/securhost-python.git
Install from PyPI
pip install securhost
🚀 Quickstart
from securhost import SecurHostClient
# Zero URL configuration needed - defaults to https://securhost.com
client = SecurHostClient(api_key="nxs_live_...")
response = client.chat.complete(
messages=[{"role": "user", "content": "Analyze customer support trends."}],
model="gpt-4o",
request_type="summarization", # Enables smart cost routing
)
print("AI Response:", response.output_text)
print(f"Cost: ${response.cost.amount:.6f} | Saved: ${response.cost.saved:.6f} (Model served: {response.cost.model})")
Async Client
import asyncio
from securhost.aio import AsyncSecurHostClient
async def main():
async with AsyncSecurHostClient(api_key="nxs_live_...") as client:
reply = await client.chat.complete([{"role": "user", "content": "Hello"}])
print(reply.output_text)
asyncio.run(main())
🎙️ Voice Agents & Real-Time Telephony
# Create real-time voice streaming session
session = client.voice.create_session(
persona_id=12,
voice_id="alloy",
model="gpt-4o-realtime",
system_prompt="You are a helpful customer concierge."
)
# Outbound telephony AI call
call = client.voice.initiate_call(
to_number="+14155552671",
persona_id=12,
prompt="Confirm scheduled reservation."
)
🤖 Autonomous Job Agents
# Deploy background AI worker
agent = client.job_agents.create(
name="Lead Researcher",
role_brief={"objective": "Scrape and enrich qualified leads"},
autonomy_level=1,
daily_action_cap=100,
sandbox=False,
tools=["web_search", "crm_sync"]
)
# Emergency pause / resume
client.job_agents.pause(agent_id=agent["id"], reason="Maintenance window")
client.job_agents.resume(agent_id=agent["id"])
🛠️ Build & Publishing Guide
Building Package Locally
python -m pip install --upgrade build twine
python -m build
This produces dist/securhost-0.1.0-py3-none-any.whl and dist/securhost-0.1.0.tar.gz.
Publishing to PyPI
twine upload dist/*
(Or configure PYPI_API_TOKEN secret in GitHub repository settings to publish automatically on release tag)
📄 License
MIT License. Copyright (c) 2026 SecurHost.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
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
File details
Details for the file securhost-0.1.2.tar.gz.
File metadata
- Download URL: securhost-0.1.2.tar.gz
- Upload date:
- Size: 12.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
eba5ac41c6bdbed33b0ed688b5f0a82913cf2cc0ba958818062f66c1ba2978a4
|
|
| MD5 |
6fc11d200b114ddff9fa12a85472a1b7
|
|
| BLAKE2b-256 |
d2b3aa58565d2af2ad254744fd42540b007f83e93662e6285f4e3f73958eac15
|
Provenance
The following attestation bundles were made for securhost-0.1.2.tar.gz:
Publisher:
release.yml on Zhost-Consulting-Private-Limited/securhost-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
securhost-0.1.2.tar.gz -
Subject digest:
eba5ac41c6bdbed33b0ed688b5f0a82913cf2cc0ba958818062f66c1ba2978a4 - Sigstore transparency entry: 2654381300
- Sigstore integration time:
-
Permalink:
Zhost-Consulting-Private-Limited/securhost-python@f7e4a74fc57b78d5b8c1d6178ec7f82e65cd7ac6 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/Zhost-Consulting-Private-Limited
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@f7e4a74fc57b78d5b8c1d6178ec7f82e65cd7ac6 -
Trigger Event:
push
-
Statement type:
File details
Details for the file securhost-0.1.2-py3-none-any.whl.
File metadata
- Download URL: securhost-0.1.2-py3-none-any.whl
- Upload date:
- Size: 14.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9e47f97ebea0a24a0221c9560d0a688f2df33afbe79a0d36cf84dc8c66d37cbb
|
|
| MD5 |
3978b3346ab3c5124b05d5bbb1f3eef4
|
|
| BLAKE2b-256 |
dee96544173bc88a948b4b8e6d68df91864abe80d7bde17e94b816c2ed6ddb89
|
Provenance
The following attestation bundles were made for securhost-0.1.2-py3-none-any.whl:
Publisher:
release.yml on Zhost-Consulting-Private-Limited/securhost-python
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
securhost-0.1.2-py3-none-any.whl -
Subject digest:
9e47f97ebea0a24a0221c9560d0a688f2df33afbe79a0d36cf84dc8c66d37cbb - Sigstore transparency entry: 2654381339
- Sigstore integration time:
-
Permalink:
Zhost-Consulting-Private-Limited/securhost-python@f7e4a74fc57b78d5b8c1d6178ec7f82e65cd7ac6 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/Zhost-Consulting-Private-Limited
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@f7e4a74fc57b78d5b8c1d6178ec7f82e65cd7ac6 -
Trigger Event:
push
-
Statement type: