telnyx
The official Python library for the telnyx API
What it is and what it does
Telnyx is the official Python SDK for the Telnyx communications platform REST API. It wraps HTTP calls to Telnyx's endpoints with a typed, object-oriented interface, supporting both synchronous and asynchronous workflows. The library is generated using Stainless and includes full type hints for all request parameters and response fields, enabling IDE autocomplete and static type checking.
The package is built on httpx for HTTP transport and pydantic for response validation. It handles pagination automatically, provides helper methods for serializing responses to JSON or dictionaries, and includes error classes for connection and API status failures. Async usage is identical to sync except for await keywords; you can optionally swap httpx for aiohttp as the HTTP backend for improved concurrency performance.
Use it for:
- Programmatically dial phone calls, manage connections, and configure answering machine detection in voice applications.
- Build IVR systems or contact center integrations that need to interact with Telnyx's telephony platform.
- Transcribe audio files or access AI-powered communication features via the Telnyx API.
- Manage phone numbers, access IP addresses, and handle number orders through the REST API.
- Integrate Telnyx webhooks and event handling into async Python applications with type safety.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides a Python client library for the Telnyx REST API, offering both synchronous and asynchronous interfaces with full type definitions for requests and responses.
Yes. The library is actively maintained, has no known vulnerabilities, uses permissive MIT licensing, and offers low install friction. It is the official Telnyx SDK with full type support and both sync/async interfaces—the right choice for any Python application integrating Telnyx communications services.
Install
telnyx on PyPI
pip
pip install telnyxuv
uv add telnyxpoetry
poetry add telnyxInstalling telnyx
Before you install
Low install friction with a pure-Python wheel and six common dependencies (anyio, distro, httpx, pydantic, sniffio, typing-extensions). Actively maintained with a release 2 days old and recent commits.
License in practice
MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute this library freely provided you include the license notice.
Quickstart
pip install telnyx
import os
from telnyx import Telnyx
client = Telnyx(api_key=os.environ.get("TELNYX_API_KEY"))
response = client.calls.dial(
connection_id="conn12345",
from_="+15557654321",
to="+15551234567",
webhook_url="https://your-webhook.url/events",
)
print(response.data)
Requires Python 3.9 or later; TELNYX_API_KEY environment variable or explicit api_key parameter needed to authenticate.
Verify before relying
- Whether the library's auto-pagination handles all edge cases and rate-limiting scenarios reliably.
- Performance characteristics when handling large concurrent requests with the async client.
- Completeness of type coverage across all Telnyx API endpoints and response schemas.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 6 — anyio, distro, httpx, pydantic, sniffio, typing-extensions |
| Maintenance | actively maintained — 2 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 720,461/month — #5,236 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: telnyx-4.173.0-py3-none-any.whl
Tags
More Python Modules packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
PyYAMLPyYAML parses and emits YAML 1.1 data format,…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
annotated-typesProvides reusable metadata objects for use with…
permissive · top 100 on PyPI
typing-inspectionProvides runtime tools to inspect and…
permissive · top 100 on PyPI
linq-pythonA Python SDK for the Linq API V3 REST API,…
permissive · top 15,000 on PyPI
composio-clientA Python client library for the Composio REST…
permissive · top 5,000 on PyPI
agentex-clientProvides a typed Python REST client for the…
permissive · top 15,000 on PyPI
opencode-aiProvides a Python client library for the…
permissive · top 15,000 on PyPI
modern-treasuryProvides a typed Python client library for the…
permissive · top 15,000 on PyPI
python-intercomA Python client library for the Intercom API,…
unclear · top 15,000 on PyPI
twilioPython client library for the Twilio API that…
permissive · top 5,000 on PyPI
supermemoryProvides a Python client library for the…
permissive · top 15,000 on PyPI
simple-rest-clientA lightweight HTTP client library for building…
unclear · top 15,000 on PyPI
lithicProvides a typed Python client for the Lithic…
permissive · top 15,000 on PyPI