Edit Voicemail Settings

Edit the global voicemail settings.

Request URL

POST {base_url}/{api_path}/vm_settings/update?access_token={access_token}

Request parameters

Parameter Required Type Description
enb_voicemail_number No Integer Whether to enable the voicemail number.

Valid value:

  • 0: Disabled.
  • 1: Enabled.
voicemail_number No String The voicemail number.
Note: The voicemail number must not conflict with any extension number.
enb_dial_exts No Integer Whether to allow callers to dial extensions while leaving a voicemail message.

Valid value:

  • 0: Disabled.
  • 1: Enabled.
dial_ext_list No Array<Allowed_Extension> The list of extensions that callers can dial while leaving a voicemail message.
Note: This parameter takes effect only when enb_dial_exts is set to 1.
enb_press5_leave No Integer Whether to allow callers to press 5 to leave a voicemail message.

Valid value:

  • 0: Disabled.
  • 1: Enabled.
enb_press0 No Integer Whether to allow callers to press 0 to break out from voicemail.

Valid value:

  • 0: Disabled.
  • 1: Enabled.
press0_dest No String The destination type for calls transferred when callers press 0.

Valid value:

  • ivr
  • extension
press0_dest_value No String The destination value for calls transferred when callers press 0.
enb_review No Integer Whether to allow callers to review their voicemail message after leaving it.

Valid value:

  • 0: Disabled.
  • 1: Enabled.
global_vm_greeting No String The file name of the global voicemail greeting.
Note: You can query the available greeting options using the Query Global Voicemail Greeting List interface.
max_greeting_time No Integer The maximum duration of the voicemail greeting, in seconds.

Valid value:

  • 30
  • 60
  • 90
  • 120
  • 600
max_msg_time No Integer The maximum duration of a voicemail message, in seconds.

Valid value:

  • 60
  • 120
  • 300
  • 600
min_msg_time No Integer The minimum duration of a voicemail message, in seconds.

Valid value:

  • 0
  • 1
  • 2
  • 3
  • 4
  • 5
enb_vm_encrypt No Integer Whether to enable voicemail encryption.

Valid value:

  • 0: Disabled.
  • 1: Enabled.
enb_vm_sms_notify No Integer Whether to enable SMS notifications for new voicemail messages.

Valid value:

  • 0: Disabled.
  • 1: Enabled.
vm_sms_channel_id No Integer The ID of the message channel used to send SMS notifications for new voicemail messages.
Note:
  • This parameter is required when enb_vm_sms_notify is set to 1.
  • You can obtain the ID using Get Menu Options (with menu set to message_channel).
vm_sms_did_id No Integer The ID of the number used to send SMS notification for new voicemail messages.
Note:
  • This parameter is required when enb_vm_sms_notify is set to 1.
  • You can obtain the ID using Get Menu Options (with menu set to message_channel).
vm_sms_content No String The content of SMS notifications for new voicemail messages.
Allowed_Extension
Note: The updated extension list replaces the existing configuration.
Parameter Required Type Description
value Yes String The ID of the extension or extension group.
Note: You can obtain the ID using Search Specific Extensions or Search Specific Extension Groups.

Response parameters

Parameter Type Description
errcode Integer Returned error code.
  • 0: Succeed.
  • Non-zero value: Failed.
Note: You can check the error code and error message in Error Code and Error Message.
errmsg String Returned message.
  • SUCCESS: Succeed.
  • FAILURE: Failed.

Example

Request example

POST /openapi/v1.0/vm_settings/update?access_token=w3rTvBskMgZ1XpQd7NhLc0eYfA6UoIjK HTTP/1.1

Host: yeastardocs.example.yeastarcloud.com
Content-Type: application/json
{
    "max_greeting_time": 90
}

Response example

HTTP/1.1 200 OK
{
    "errcode": 0,
    "errmsg": "SUCCESS"
}