Docs Rizler

Voice Templates

Create Voice Template

POSThttps://app.rizzdial.com/api/template/voice
Create Voice Template
curl --request POST \
  --url https://app.rizzdial.com/api/template/voice \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --data type=text_to_speech \
  --data title=Voicemail \
  --data status=active \
  --data 'texttospeech=Please call us back.'
{
  "data": {
    "id": "MQ==",
    "type": "text_to_speech",
    "audio": null,
    "title": "Voicemail",
    "status": "active",
    "texttospeech": "Please call us back."
  },
  "message": "Voice template created successfully.",
  "success": true
}

Create Voice Template#

Creates a voice template. text_to_speech needs texttospeech. audio_file and record_voice need an MP3 or WAV file in audio.

Authorizationstringheaderrequired

Bearer token in the format: Bearer {access_token}

titlestringbodyrequired

Template name, max 255 characters. Unique per company

typestringbodyrequired

text_to_speech, audio_file, or record_voice

statusstringbody

active or inactive. Defaults to active

texttospeechstringbody

Required when type is text_to_speech

audiofilebody

MP3 or WAV. Required when type is audio_file or record_voice

curl --request POST \
  --url https://app.rizzdial.com/api/template/voice \
  --header 'Authorization: Bearer {{bearer_token}}' \
  --form 'title=Voicemail' \
  --form 'type=text_to_speech' \
  --form 'status=active' \
  --form 'texttospeech=Please call us back.'
messagestring

Voice template created successfully.

Send this request as multipart/form-data. POST /api/template/voice/create calls the same action.