Python server SDK for the CALL-E Developer API.
Project description
calle-ai
Python server SDK for the CALL-E Developer API.
Use this SDK from backend services, workers, and other trusted server environments. Do not expose CALL-E API keys in browser code.
Documentation
- Developer docs: https://docs.heycall-e.com/
- SDK guide: https://docs.heycall-e.com/#/sdks
- API Reference: https://docs.heycall-e.com/#/api-reference
- Webhooks: https://docs.heycall-e.com/#/webhooks
- Changelog: https://docs.heycall-e.com/#/changelog
Install
Install the stable package from PyPI:
pip install calle-ai
Pin the current stable release when your deployment process requires exact package reproducibility:
pip install calle-ai==0.2.0
Use a local checkout for development and package smoke tests:
bash scripts/validate.sh
Examples
Set the API key before running call examples:
export CALLE_API_KEY="calle_test_key"
export CALLE_BASE_URL="https://api.heycall-e.com"
export CALLE_EXAMPLE_PHONE="+14155550100"
Run the create-and-wait example from a local checkout:
uv run python examples/create_and_wait.py
Run the webhook receiver example:
export CALLE_WEBHOOK_SECRET="whsec_test_key"
uv run python examples/webhook_server.py
The webhook receiver listens on POST /calle/webhook and verifies
CALL-E-Timestamp and CALL-E-Signature against the raw request body.
Quickstart
import os
from calle import CalleClient
client = CalleClient(
api_key=os.environ["CALLE_API_KEY"],
base_url="https://api.heycall-e.com",
)
call = client.calls.create_and_wait(
task="Call each recipient and ask whether they can attend Friday lunch in San Francisco.",
recipients=[{"phones": ["+14155550100"], "region": "US", "locale": "en-US"}],
result_schema={
"type": "object",
"required": ["completed_count"],
"properties": {
"completed_count": {"type": "integer"},
},
},
recipient_result_schema={
"type": "object",
"required": ["can_attend"],
"properties": {
"can_attend": {"type": "string", "enum": ["yes", "no", "unknown"]},
},
},
metadata={"workflow_run_id": "wf_123"},
idempotency_key="wf_123_friday_lunch",
)
print(call["status"], call["structured_result"])
print(call["task_completed"], call["completion_confidence"], call["evidence"])
print(call["recipients"][0]["structured_result"])
Webhook Verification
event = client.webhooks.unwrap(
raw_body=raw_body,
headers=headers,
secret=os.environ["CALLE_WEBHOOK_SECRET"],
)
Release
This repository publishes the Python distribution calle-ai. Application code
imports it as calle.
See RELEASE.md for the release checklist, GitHub Actions workflow, and post-publish install smoke test.
Prerequisites:
- Create a PyPI API token and add it to this repository as the GitHub Actions secret
PYPI_API_TOKEN. - Keep the package version in
pyproject.tomlunique before each publish.
Manual stable PyPI publish:
- Open the
Publish Python packageGitHub Actions workflow. - Run it from
mainwith repositorypypiand authtoken. - Verify install in a temporary environment:
python -m venv .venv
. .venv/bin/activate
pip install calle-ai==0.2.0
python -c 'from calle import CalleClient; print(CalleClient)'
The current stable version is 0.2.0. Do not reuse a previously published PyPI version.
Project Documents
Project details
Release history Release notifications | RSS feed
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 calle_ai-0.2.0.tar.gz.
File metadata
- Download URL: calle_ai-0.2.0.tar.gz
- Upload date:
- Size: 76.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4bd4260f6915f81de6504f6aa34048a5c9f645bf9b69744878d8cf90bcff7ca9
|
|
| MD5 |
f69c950e4c72a2ab6b6cc6eab804d779
|
|
| BLAKE2b-256 |
185ae6f2ca0b377c50c2b01b7b1805473045123c11f51108b5feabc44b1bb57c
|
File details
Details for the file calle_ai-0.2.0-py3-none-any.whl.
File metadata
- Download URL: calle_ai-0.2.0-py3-none-any.whl
- Upload date:
- Size: 36.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e67010516047156d2470817039441723a3d1df6f90947dddfcd34eab297c0436
|
|
| MD5 |
2906ba29b856b8b85a5123d84151a02a
|
|
| BLAKE2b-256 |
fa8e23ce0e54fc7d97915b792b6a34fc9835a90ca2a5416a8531417605a0025b
|