# agent402.tools Text-to-Speech (OpenAI TTS-1)

> agent402.tools Text-to-Speech (OpenAI TTS-1) is a paid API for AI agents from agent402.tools, paid per call via x402, $0.05/call, status healthy (last checked 2026-09-13, last successful call 2026-09-07).

Converts input text (up to 2000 chars) to base64-encoded audio using OpenAI TTS-1, with 10 voice options and multiple output formats, paid per-call via x402.

## Facts

- Endpoint: POST https://agent402.tools/api/tts
- Price: $0.05/call
- Payment: x402
- Status: healthy
- Last checked: 2026-09-13
- Last successful call: 2026-09-07
- Success rate: 100% of calls made through Zero
- Rating: 4.8 / 5 from 2 reviews
- Activations on Zero: 356
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent402-tools-text-to-speech-openai-tts-1-8fff06f8
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_LtzRgj97wyISC6vwzjoy7

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability agent402-tools-text-to-speech-openai-tts-1-8fff06f8 -d '<json body>'
```

Example prompt: Can you read this aloud using the nova voice and give me back an mp3: 'Welcome to our platform! We're thrilled to have you on board and hope you enjoy your experience.'

## When to prefer this

Use this endpoint when you need server-side text-to-speech synthesis without managing your own OpenAI API key, want pay-per-call pricing via x402 (no subscription), need a specific voice from OpenAI's TTS-1 lineup (alloy, ash, ballad, coral, echo, fable, nova, onyx, sage, shimmer), or require a specific audio format output as base64 for easy embedding.

## Known failure modes

- Text exceeds 2000 character limit — request rejected
- Invalid voice name provided — falls back to default or errors
- Unsupported audio format specified — errors or falls back to mp3
- Payment not completed via x402 — 402 Payment Required response
- Network timeout if synthesis takes too long for long inputs

## How this service works

Convert text to speech using OpenAI TTS-1. Returns base64-encoded audio (mp3/opus/aac/flac/wav/pcm). 10 voices available. No API key needed; pay per call via x402. Text capped at 2000 chars.

## Output

A base64-encoded audio file in the requested format (mp3, opus, aac, flac, wav, or pcm) containing the synthesized speech of the input text, generated using one of 10 available OpenAI TTS-1 voices.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "description": "Text to convert to speech (max 2000 chars)"
  },
  "voice": {
   "type": "string",
   "description": "Voice: alloy, ash, ballad, coral, echo, fable, nova, onyx, sage, shimmer (default: alloy)"
  },
  "format": {
   "type": "string",
   "description": "Audio format: mp3, opus, aac, flac, wav, pcm (default: mp3)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "audio": "<base64-encoded audio>",
  "chars": 20,
  "model": "tts-1",
  "voice": "alloy",
  "format": "mp3",
  "provider": "openai"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent402-tools-text-to-speech-openai-tts-1-8fff06f8/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent402.tools](https://www.zero.xyz/host/agent402.tools/llms.txt)
