Docs menu

Upload a voicemail greeting

PUT/v1/profiles/{profile_id}/voicemail-greeting

  • Scope calls:write

The request body is the audio file itself: MP3 or WAV, up to 5 MB and 2 minutes, at least half a second. A new greeting replaces the old one.

Parameters

Path

  • profile_idstringrequired

    The line (prf_…).

Query

  • source"recorded" | "uploaded"

    uploaded (default) or recorded.

  • file_namestring

    The file's name, for people.

Request body

The MP3 or WAV file. Content types: audio/mpeg, audio/wav, application/octet-stream.

Response

200 OKThe greeting.

  • object"voicemail_greeting"required

  • profile_idstringrequired

    prf_…

  • audioobject or nullrequired

    The recorded or uploaded greeting callers hear; null = they hear text (or default_text) read aloud.

    Fields of audio
    • urlstringrequired

    • content_typestringrequired

    • size_bytesintegerrequired

    • duration_secondsnumberrequired

    • source"recorded" | "uploaded"required

    • file_namestring or nullrequired

    • created_attimestamprequired

  • textstring or nullrequired

  • default_textstringrequired

Errors

StatusCodeMeans
400unsupported_audioThe greeting isn't an MP3 or WAV file.
400greeting_too_longThe greeting is longer than 2 minutes.
400greeting_too_shortThe greeting is shorter than half a second.
400unreadable_audioThe audio file couldn't be read.
413greeting_too_largeThe greeting file is over 5 MB.
409calling_not_set_upThe line has no calling.
503storage_disabledFile storage is off on this server.
400validation_failedA field is missing or invalid.
401unauthorizedThe API key is missing, unknown or revoked.
403insufficient_scopeThe API key lacks the scope this needs.
404not_foundNo such object, or the key can't see it.

Every error is { "error": { "code", "message" } }. All error codes.

Keys come with your first line.

Request an invite and we'll set up a line for your team. API access is part of every plan.

Request an invite