Main Site ↗

openai-tts

by benchflow-ai890173GitHub

OpenAI Text-to-Speech API for high-quality speech synthesis. Use for generating natural-sounding audio from text with customizable voices and tones.

Unlock Deep Analysis

Use AI to visualize the workflow and generate a realistic output preview for this skill.

Powered by Fastest LLM

Development
Compatible Agents
Claude Code
Claude Code
~/.claude/skills/
Codex CLI
Codex CLI
~/.codex/skills/
Gemini CLI
Gemini CLI
~/.gemini/skills/
O
OpenCode
~/.opencode/skills/
O
OpenClaw
~/.openclaw/skills/
GitHub Copilot
GitHub Copilot
~/.copilot/skills/
Cursor
Cursor
~/.cursor/skills/
W
Windsurf
~/.codeium/windsurf/skills/
C
Cline
~/.cline/skills/
R
Roo Code
~/.roo/skills/
K
Kiro
~/.kiro/skills/
J
Junie
~/.junie/skills/
A
Augment Code
~/.augment/skills/
W
Warp
~/.warp/skills/
G
Goose
~/.config/goose/skills/
SKILL.md

OpenAI TTS (curl)

Generate speech from text via OpenAI's /v1/audio/speech endpoint.

Quick start

{baseDir}/scripts/speak.sh "Hello, world!"
{baseDir}/scripts/speak.sh "Hello, world!" --out /tmp/hello.mp3

Defaults:

  • Model: tts-1 (fast) or tts-1-hd (quality)
  • Voice: alloy (neutral), also: echo, fable, onyx, nova, shimmer
  • Format: mp3

Voices

VoiceDescription
alloyNeutral, balanced
echoMale, warm
fableBritish, expressive
onyxDeep, authoritative
novaFemale, friendly
shimmerFemale, soft

Flags

{baseDir}/scripts/speak.sh "Text" --voice nova --model tts-1-hd --out speech.mp3
{baseDir}/scripts/speak.sh "Text" --format opus --speed 1.2

Options:

  • --voice <name>: alloy|echo|fable|onyx|nova|shimmer (default: alloy)
  • --model <name>: tts-1|tts-1-hd (default: tts-1)
  • --format <fmt>: mp3|opus|aac|flac|wav|pcm (default: mp3)
  • --speed <n>: 0.25-4.0 (default: 1.0)
  • --out <path>: output file (default: stdout or auto-named)

API key

Set OPENAI_API_KEY, or configure in ~/.clawdbot/clawdbot.json:

{
  skills: {
    entries: {
      "openai-tts": {
        apiKey: "sk-..."
      }
    }
  }
}

Pricing

  • tts-1: ~$0.015 per 1K characters
  • tts-1-hd: ~$0.030 per 1K characters

Very affordable for short responses!

Source: https://github.com/benchflow-ai/SkillsBench#tasks-no-skills-pg-essay-to-audiobook-environment-skills-openai-tts

Content curated from original sources, copyright belongs to authors

Grade B
-AI Score
Best Practices
Checking...
Try this Skill

User Rating

USER RATING

0UP
0DOWN
Loading files...

WORKS WITH

Claude Code
Claude
Codex CLI
Codex
Gemini CLI
Gemini
O
OpenCode
O
OpenClaw
GitHub Copilot
Copilot
Cursor
Cursor
W
Windsurf
C
Cline
R
Roo
K
Kiro
J
Junie
A
Augment
W
Warp
G
Goose