1. Teleboard | Support Center
  2. Solution home
  3. API Documentation
  4. REST API - DELETE Requests
Open navigation

DELETE/voicemail/file

Function


The DELETE/voicemail/file request will delete one or more voicemail messages from the user's account archive. 


Parameters


All parameters go in the header.


Parameter
Type
Operation
mailboxstring
The  mailbox line from which the message is to be deleted.
file
stringThe file name of the message to be deleted (several can be specified in one request, but each in a separate parameter.)
 
You obtain this file name using the get/voicemail method.
dirstringThe directory for which the messages will be listed, either INBOX or SENT. Default is INBOX.

Example


To delete a message in the inbox directory for voicemail line 1113840 use this syntax:


HTTPS method: DELETE


webserv.telebroad.com/api/teleconsole/rest/voicemail/file?mailbox=1113840&file=voicemail_1515248576_15152485661600208_16487_16317571234_3&dir=INBOX


Response:


A "null" error indicates successful deletion.


It is followed by he actual audio of the voicemail in asci text format, encoded in base64. This may be many pages long. Shown here is a truncated version.


After the asci text there is a definition of the mimetype - the format of the audio file. This is always defined as "audio\/x-wav".


You can convert the asci data into actual audio with any online base64 to Wav converter, such as this one:


http://www.motobit.com/util/base64-decoder-encoder.asp


{

    {error":null,"result":

        {"name":"voicemail_20180106092256_16317571234.wav",

        "data":"UklGRqR6AABXQVZFZm10IBAAAAABAAEAQB8AAIA

        +AAACABAAZGF0YYB6AAD4\/\/j\/+P\/4\/\/j\/+P\/4\/w

        AAAAAAAAAAAAAAAAAAAAAAAAAAAAAIAAAAAAAAAPj\/+P\/

        4\/\/j\/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD4\/\/j\/

        +P\/4\/\/j\/+P\/4\/\/j\/+P\/4\/\/j\/AAAAAAAAAAAAAA

        AAAAAAAAAAAAAAAAgACAAIAAgAAAAAAAAA+P\/4\/\/j\/+P\/4

        \/\/j\/+P\/4\/\/j\/+P8AAPj\/+P\/4\/\/j\/AAAAAPj\/

        AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA+P\/4\

        /\/j\/+P\/4\/\/j\/+P\/4\/wAAAAAAAAAAAAAAAAAAAAA

        AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

        AAAAAAPj\/+P\/4\/\/j\/AAAAAAAAAAAAAAAA+P\/

        4\/\/j\/+P8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

        AAAAAAAAAAAAAAA+P8AAPj\/+P\/4\/wAAAAAAAAA

        AAAAAAAAAAAD4\/wAA+P\/4\/\/

.

.

.
        AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

        AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

        AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA

        AAAAAAAAAAAAAAAAAA"

        ,"mimetype":"audio\/x-wav"

    }

}