>- Transcribe audio to text via the OpenAI-compatible transcription endpoint. Supports multiple models, languages, and keyword biasing. Also lists available speech-to-text providers and service types.
npx skills add https://github.com/team-telnyx/ai --skill telnyx-stt-python
pip install telnyx
import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"),
)
All examples below assume client is already initialized as shown above.
All API calls can fail with network errors, rate limits (429), validation errors (422),
or authentication errors (401). Always handle errors in production code:
import telnyx
try:
response = client.ai.audio.transcribe(
model="openai/whisper-large-v3-turbo",
url="https://example.com/audio.mp3",
)
except telnyx.APIConnectionError:
print("Network error — check connectivity and retry")
except telnyx.RateLimitError:
import time
time.sleep(1)
except telnyx.APIStatusError as e:
print(f"API error {e.status_code}: {e.message}")
Common error codes: 401 invalid API key, 403 insufficient permissions,
404 resource not found, 422 validation error, 429 rate limited.
Transcribe an audio file to text. This endpoint is consistent with the
and may be used with the OpenAI JS or Python SDK.
POST /ai/audio/transcriptions
| Parameter | Type | Required | Description |
|-----------|------|----------|-------------|
| url | string (URL) | Yes | URL of the audio file to transcribe. |
| model | string | No | Model ID (e.g., openai/whisper-large-v3-turbo, distil-whisper/distil-large-v2). |
| language | string | No | Language code (e.g., en, es, fr). |
| prompt | string | No | Optional prompt to guide transcription style. |
| response_format | enum | No | json, text, srt, verbose_json, vtt. Default: json. |
| temperature | number | No | Sampling temperature (0-1). Default: 0. |
| keywords | array[string] | No | Keyword biasing — improve accuracy for domain-specific terms. |
# Basic transcription
response = client.ai.audio.transcribe(
url="https://example.com/audio.mp3",
)
print(response.text)
# With specific model and language
response = client.ai.audio.transcribe(
url="https://example.com/audio.mp3",
model="openai/whisper-large-v3-turbo",
language="es",
)
print(response.text)
# With keyword biasing for domain-specific terms
response = client.ai.audio.transcribe(
url="https://example.com/audio.mp3",
keywords=["Telnyx", "API", "WebRTC", "SIP"],
)
print(response.text)
# Verbose JSON with segments
response = client.ai.audio.transcribe(
url="https://example.com/audio.mp3",
response_format="verbose_json",
)
for segment in response.segments:
print(f"[{segment.start:.1f}s - {segment.end:.1f}s] {segment.text}")
Primary response fields:
response.text — Full transcription textresponse.duration — Audio duration in secondsresponse.segments — Array of segment objects (with start, end, text) when using verbose_json formatRetrieve a list of available speech-to-text providers and their service types.
GET /ai/audio/transcriptions/providers
response = client.ai.audio.list_providers()
for provider in response.providers:
print(f"{provider['name']} — {provider['service_type']}")
# Filter by provider name
response = client.ai.audio.list_providers(provider="telnyx")
for provider in response.providers:
print(f"{provider['name']} — {provider['service_type']}")
# Filter by service type
response = client.ai.audio.list_providers(service_type="transcription")
for provider in response.providers:
print(f"{provider['name']} — {provider['service_type']}")
Primary response fields:
response.providers — Array of provider objects with name and service_typeThe Telnyx Agent CLI provides composite commands for STT:
# Transcribe audio
telnyx-agent stt --audio-url https://example.com/audio.mp3 --json
# With specific model and language
telnyx-agent stt --audio-url https://example.com/audio.mp3 --model openai/whisper-large-v3-turbo --language es --json
# List available providers
telnyx-agent stt-providers --json
# Filter by provider or service type
telnyx-agent stt-providers --provider telnyx --service-type transcription --json
https://api.telnyx.com/v2/ai/openai.keywords to improve transcription accuracy for domain-specific terms, product names, or acronyms that generic models may mishear.openai/whisper-large-v3-turbo (fast, accurate) and distil-whisper/distil-large-v2 (lightweight). Check stt-providers for the full list.en, es, fr, de, ja, etc.). Omit to auto-detect.verbose_json to get timestamps and segments. Use srt or vtt for subtitle files.Python library for working with DICOM (Digital Imaging and Communications in Medicine) files. Use this skill when reading, writing, or modifying medical imaging data in DICOM format, extracting pixel data from medical images (CT, MRI, X-ray, ultrasound), anonymizing DICOM files, working with DICOM metadata and tags, converting DICOM images to other formats, handling compressed DICOM data, or processing medical imaging datasets. Applies to tasks involving medical image analysis, PACS systems, radiology workflows, and healthcare imaging applications.
Python library for working with DICOM (Digital Imaging and Communications in Medicine) files. Use this skill when reading, writing, or modifying medical imaging data in DICOM format, extracting pixel data from medical images (CT, MRI, X-ray, ultrasound), anonymizing DICOM files, working with DICOM metadata and tags, converting DICOM images to other formats, handling compressed DICOM data, or processing medical imaging datasets. Applies to tasks involving medical image analysis, PACS systems, radiology workflows, and healthcare imaging applications.
Best practices for Remotion - Video creation in React
Generate AI-powered podcast-style audio narratives using Azure OpenAI's GPT Realtime Mini model via WebSocket. Use when building text-to-speech features, audio narrative generation, podcast creation from content, or integrating with Azure OpenAI Realtime API for real audio output. Covers full-stack implementation from React frontend to Python FastAPI backend with WebSocket streaming.
Best practices for Remotion - Video creation in React
Port an existing Remotion (React) composition''s source to HyperFrames HTML. Use ONLY on an explicit ask to port/convert/migrate/translate a Remotion source — one-way, Remotion-only. A passing Remotion mention, reference-only code, or "make something like my Remotion video" is a fresh build (/general-video). Unclear → /hyperframes.
Use this skill when building applications with Gemini API hosted models, including Gemini and Gemma 4, working with multimodal content (text, images, audio, video), implementing function calling, using structured outputs, or needing current model specifications. Covers SDK usage...
Turn error logs, screenshots, voice notes, and rough bug reports into crisp, developer-ready GitHub issues with repro steps, impact, and evidence.
Take team-telnyx/telnyx-stt-python from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.
The instructions reference pip.
Without those the skill loads but fails at the first command.