Play.HT
    • Stream Audio From Text
      POST
    • Generate Audio From Text
      POST
    • Get Text-To-Speech Job Data
      GET
    • List PlayHT Voices
      GET
    • Create Instant Voice Clone (via file upload)
      POST
    • Create Instant Voice Clone (via file URL)
      POST
    • List Cloned Voices
      GET
    • Delete Cloned Voices
      DELETE
    • Timestamp From Audio
      POST
    • Get Transcription Job Data
      GET
    • Convert Plain Text To Speech
      POST
    • Convert SSML To Speech
      POST
    • Get Conversion Job Status
      GET
    • Get Available Voices
      GET

      Convert SSML To Speech

      Develop Env
      https://dev.your-api-server.com
      Develop Env
      https://dev.your-api-server.com
      POST
      /api/v1/convert/
      This endpoint is used to trigger text to speech conversion.
      It can generate text for Standard & Premium (S&P) voices. The identifiers for these voices look like en-US-JennyNeural.
      If you are using PlayHT voices (their identifiers look like larry or a URL), please refer to the Generate Audio From Text endpoint page.
      The request body for this /v1/convert endpoint must contain the SSML to be converted to speech, along with the voice to be used for the conversion.
      The response will contain data about the conversion job created in JSON format.
      To generate audio from SSML, please provide the ssml field in the request body. It is an array of SSML strings. An SSML string looks like: <speak><p>Hello my friend <break time="0.5s"/></p></speak>.
      Use the transcriptionId in the response to check the conversion status in the Get Article Conversion Status endpoint endpoint.

      Request

      Header Params

      Body Params application/json

      Examples

      Responses

      🟢201Created
      application/json
      Bodyapplication/json

      🟠400Bad Request
      Request Request Example
      Shell
      JavaScript
      Java
      Swift
      curl --location 'https://dev.your-api-server.com/api/v1/convert/' \
      --header 'content-type: application/json' \
      --data '{
        "ssml": [
          "<speak><p>Hello my friend. <break time=\"0.5s\"/> Hmm...</p></speak>"
        ],
        "voice": "en-US-JennyNeural"
      }'
      Response Response Example
      201 - Success
      {
        "status": "CREATED",
        "transcriptionId": "-NOjGbpFU1Exf3DxhLHU",
        "contentLength": 1,
        "wordCount": 4
      }
      Modified at 2024-07-30 06:16:55
      Previous
      Convert Plain Text To Speech
      Next
      Get Conversion Job Status
      Built with