{"uid":"cap_SbaQ1qXTaAtQ5nM98N49N","slug":"openai-text-to-speech-tts-via-x402-5f2bca15","name":"OpenAI Text to Speech (TTS) via x402","description":"OpenAI text to speech (gpt-4o-mini-tts, tts-1, tts-1-hd), paid per call in USDC. OpenAI list $15 / $30 per 1M characters (tts-1 / tts-1-hd) or $12 per 1M audio tokens (gpt-4o-mini-tts, quoted at 4 per character), plus $0.0005 (Base) or $0.0005 (Solana) per call; up to 4096 characters. Standard OpenAI body (input, voice, response_format, speed). Returns the audio bytes. One endpoint per model: /x402/v1/models/<key>/audio/speech. Rates: https://openai.mm.family/x402/pricing","url":"https://openai.mm.family/x402/v1/audio/speech?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"input":{"type":"string"},"model":{"enum":["gpt-4o-mini-tts","tts-1","tts-1-hd"],"type":"string"},"speed":{"type":"number"},"voice":{"type":"string"},"instructions":{"type":"string"},"response_format":{"enum":["mp3","opus","aac","flac","wav","pcm"],"type":"string"}}},"responseSchema":{"type":"json","example":{"body":"binary audio bytes (mp3 by default)","content_type":"audio/mpeg"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_aS45SSX25WDBkDWcmabzB","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Converts text to spoken audio using OpenAI TTS models (gpt-4o-mini-tts, tts-1, tts-1-hd), returning audio bytes paid per call in USDC via x402","exampleAgentPrompt":"Convert the following text to speech using the tts-1-hd model with the 'alloy' voice and return it as a WAV file: 'Welcome to our platform. We're glad you're here and hope you enjoy your experience.'","exampleUseCases":[{"title":"Podcast intro narration generation","prompt":"Turn this script into spoken audio using the tts-1-hd model and the 'nova' voice as an MP3: 'Welcome back to The Daily Digest. Today we're covering the top five stories shaping the world of technology.'"},{"title":"Accessibility audio for article","prompt":"Read this article summary aloud using the gpt-4o-mini-tts model with the 'shimmer' voice at 0.9 speed and give me the audio as a WAV: 'Researchers have discovered a new method for carbon capture that could reduce atmospheric CO2 by up to 30 percent by 2050.'"},{"title":"E-learning course voiceover","prompt":"Generate a voiceover for my online course slide using tts-1, the 'onyx' voice, and opus format: 'In this module, you will learn the fundamentals of machine learning, including supervised and unsupervised techniques.'"}],"resultDescription":"Binary audio bytes (default MP3, or the format specified via response_format such as opus, aac, flac, wav, or pcm) representing the synthesized speech of the input text, with content-type audio/mpeg or appropriate audio MIME type.","failureModes":["Input text exceeds 4096 character limit — request rejected","Invalid or unsupported voice name — model may error or use a default","Payment failure via x402 — call not processed","Unsupported response_format value — schema validation error","Model enum value not recognized — returns error","Empty input string — may return silence or error"],"whenToPreferThis":"Choose this endpoint when you need high-quality OpenAI TTS audio generation with per-call USDC micropayment billing via the x402 protocol, especially if you want access to multiple model tiers (gpt-4o-mini-tts for cost efficiency, tts-1 for standard quality, tts-1-hd for high fidelity) and flexible audio output formats without managing OpenAI API keys directly.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T12:42:24.836Z","isFirstParty":false,"canonicalSlug":"openai-text-to-speech-tts-via-x402-5f2bca15"}