json
{
"PhoneNumber": "+11234567890",
"AccountId": "AID-ab12345-2725-45a1-bd5e-526ed19799xx",
"FirstName": "John",
"LastName": "Doe",
"PIN": "5678",
"Email": "newemail@example.com"
}curl -X POST https://api.telegent.com/v1.0/numbers/voicemail/update \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"PhoneNumber": "+11234567890",
"AccountId": "AID-ab12345-2725-45a1-bd5e-526ed19799xx",
"FirstName": "John",
"LastName": "Doe",
"PIN": "5678",
"Email": "newemail@example.com"
}'import requests
url = "https://api.telegent.com/v1.0/numbers/voicemail/update"
payload = {
"PhoneNumber": "+11234567890",
"AccountId": "AID-ab12345-2725-45a1-bd5e-526ed19799xx",
"PIN": "5678",
"FirstName": "John",
"LastName": "Doe",
"Email": "newemail@example.com"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
PhoneNumber: '+11234567890',
AccountId: 'AID-ab12345-2725-45a1-bd5e-526ed19799xx',
PIN: '5678',
FirstName: 'John',
LastName: 'Doe',
Email: 'newemail@example.com'
})
};
fetch('https://api.telegent.com/v1.0/numbers/voicemail/update', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.telegent.com/v1.0/numbers/voicemail/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'PhoneNumber' => '+11234567890',
'AccountId' => 'AID-ab12345-2725-45a1-bd5e-526ed19799xx',
'PIN' => '5678',
'FirstName' => 'John',
'LastName' => 'Doe',
'Email' => 'newemail@example.com'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.telegent.com/v1.0/numbers/voicemail/update"
payload := strings.NewReader("{\n \"PhoneNumber\": \"+11234567890\",\n \"AccountId\": \"AID-ab12345-2725-45a1-bd5e-526ed19799xx\",\n \"PIN\": \"5678\",\n \"FirstName\": \"John\",\n \"LastName\": \"Doe\",\n \"Email\": \"newemail@example.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.telegent.com/v1.0/numbers/voicemail/update")
.header("Content-Type", "application/json")
.body("{\n \"PhoneNumber\": \"+11234567890\",\n \"AccountId\": \"AID-ab12345-2725-45a1-bd5e-526ed19799xx\",\n \"PIN\": \"5678\",\n \"FirstName\": \"John\",\n \"LastName\": \"Doe\",\n \"Email\": \"newemail@example.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.telegent.com/v1.0/numbers/voicemail/update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"PhoneNumber\": \"+11234567890\",\n \"AccountId\": \"AID-ab12345-2725-45a1-bd5e-526ed19799xx\",\n \"PIN\": \"5678\",\n \"FirstName\": \"John\",\n \"LastName\": \"Doe\",\n \"Email\": \"newemail@example.com\"\n}"
response = http.request(request)
puts response.read_body{
"PhoneNumber": "+11234567890",
"Successful": true,
"Message": "Voicemail settings updated"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}Voicemail
Update Voicemail
Update voicemail settings for a phone number including PIN, notification email, and subscriber name details.
What this does: Returns confirmation that the voicemail configuration has been updated. Only the fields you send are changed; omitted fields retain their current values.
Next steps:
- Confirm the update —
POST /v1.0/numbers/voicemail/info
POST
/
v1.0
/
numbers
/
voicemail
/
update
json
{
"PhoneNumber": "+11234567890",
"AccountId": "AID-ab12345-2725-45a1-bd5e-526ed19799xx",
"FirstName": "John",
"LastName": "Doe",
"PIN": "5678",
"Email": "newemail@example.com"
}curl -X POST https://api.telegent.com/v1.0/numbers/voicemail/update \
-H 'Authorization: Bearer YOUR_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"PhoneNumber": "+11234567890",
"AccountId": "AID-ab12345-2725-45a1-bd5e-526ed19799xx",
"FirstName": "John",
"LastName": "Doe",
"PIN": "5678",
"Email": "newemail@example.com"
}'import requests
url = "https://api.telegent.com/v1.0/numbers/voicemail/update"
payload = {
"PhoneNumber": "+11234567890",
"AccountId": "AID-ab12345-2725-45a1-bd5e-526ed19799xx",
"PIN": "5678",
"FirstName": "John",
"LastName": "Doe",
"Email": "newemail@example.com"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
PhoneNumber: '+11234567890',
AccountId: 'AID-ab12345-2725-45a1-bd5e-526ed19799xx',
PIN: '5678',
FirstName: 'John',
LastName: 'Doe',
Email: 'newemail@example.com'
})
};
fetch('https://api.telegent.com/v1.0/numbers/voicemail/update', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.telegent.com/v1.0/numbers/voicemail/update",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'PhoneNumber' => '+11234567890',
'AccountId' => 'AID-ab12345-2725-45a1-bd5e-526ed19799xx',
'PIN' => '5678',
'FirstName' => 'John',
'LastName' => 'Doe',
'Email' => 'newemail@example.com'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.telegent.com/v1.0/numbers/voicemail/update"
payload := strings.NewReader("{\n \"PhoneNumber\": \"+11234567890\",\n \"AccountId\": \"AID-ab12345-2725-45a1-bd5e-526ed19799xx\",\n \"PIN\": \"5678\",\n \"FirstName\": \"John\",\n \"LastName\": \"Doe\",\n \"Email\": \"newemail@example.com\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.telegent.com/v1.0/numbers/voicemail/update")
.header("Content-Type", "application/json")
.body("{\n \"PhoneNumber\": \"+11234567890\",\n \"AccountId\": \"AID-ab12345-2725-45a1-bd5e-526ed19799xx\",\n \"PIN\": \"5678\",\n \"FirstName\": \"John\",\n \"LastName\": \"Doe\",\n \"Email\": \"newemail@example.com\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.telegent.com/v1.0/numbers/voicemail/update")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"PhoneNumber\": \"+11234567890\",\n \"AccountId\": \"AID-ab12345-2725-45a1-bd5e-526ed19799xx\",\n \"PIN\": \"5678\",\n \"FirstName\": \"John\",\n \"LastName\": \"Doe\",\n \"Email\": \"newemail@example.com\"\n}"
response = http.request(request)
puts response.read_body{
"PhoneNumber": "+11234567890",
"Successful": true,
"Message": "Voicemail settings updated"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}{
"StatusCode": 123,
"Message": "<string>"
}Body
application/json
The phone number to update voicemail settings for (E.164 format)
Example:
"+11234567890"
Optional account ID associated with the phone number
Example:
"AID-ab12345-2725-45a1-bd5e-526ed19799xx"
New voicemail PIN
Example:
"5678"
Subscriber first name
Example:
"John"
Subscriber last name
Example:
"Doe"
New email address for voicemail notifications
Example:
"newemail@example.com"
Response
Success — returns update confirmation
The response is of type object.
⌘I