New: Audio API, Embeddings & Realtime WebSocket now available!
osmAPI LogoosmAPI

Create Voice

Create Voice

POST /v1/audio/voices

Creates a custom voice for text-to-speech. Requires a voice consent recording first.

Request

Content-Type: application/json

ParameterTypeRequiredDescription
namestringYesName for the custom voice
descriptionstringNoDescription of the custom voice
consent_idstringYesID of the voice consent recording uploaded via /v1/audio/voice_consents
curl -X POST "https://api.osmapi.com/v1/audio/voices" \
  -H "Authorization: Bearer $OSM_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "my-custom-voice",
    "description": "A custom voice for my app",
    "consent_id": "consent_abc123"
  }'

Notes

  • Request body is passed through to OpenAI's Voices API. See OpenAI documentation for the full parameter schema.
  • Requires an OpenAI provider key with custom voice permissions
  • Voice consent must be uploaded first via /v1/audio/voice_consents
  • See OpenAI Custom Voices documentation for details

How is this guide?