JSON API » mailboxes » mailboxes/update
Updates an existing mailbox.
Input parameters
Requires authentication and the administrator, residential, or user role privileges.
Name | Type | Description | Required | Default value |
---|---|---|---|---|
auth_username | String | Authentication username. | Yes | |
auth_password | String | Authentication password. | Yes | |
mailbox | String | Mailbox to update. | Yes | |
customer | Integer | ID of customer owning mailbox. | No | Customer of authentication user. |
callerid | String | Callerid to use on notification calls. Empty string for unknown. | No | Current value. |
description | String | Description. | No | Current value. |
dtype | String | Destination type if caller presses 0 during greeting. | No | Current value. |
dnumber | String | Destination number if caller presses 0 during greeting. | No | Current value. |
envelope | Integer | 1 to play message envelope, 0 not to. | No | Current value. |
notify_dnumber | String | Number to call for notification calls. Empty string for none. | No | Current value. |
notify_email | String | "owner" to notify mailbox owner by email, "owner_wav" to also attach voicemail as .wav, empty string not to notify. | No | Current value. |
notify_for | String | "all" to notify for all messages, "fax" to notify for faxes, "text" to notify for text messages, "voicemail" to notify for voicemails, "voicemail_fax" to nofify for voicemails and faxes, empty string for no notifications. | No | Current value. |
notify_ltype | String | What to play on notifications calls. "voicemailbox" for access to mailbox without PIN, "voicemailboxpin" for access to mailbox with PIN, "voicemaillogin" to ask for mailbox and PIN. | No | Current value. |
notify_message | String | "owner" to send text message to mailbox owner, empty string not to. | No | Current value. |
notify_only | Integer | 1 to delete the message after sending notification emails, 0 not to. | No | Current value. |
owner | Integer | ID of owner. 0 for none. | No | Current value. |
pager | String | Secondary email address to notify. Empty string for none. | No | Current value. |
pager_attach | Integer | 1 to attach voicemail or fax to email to secondary address, 0 not to. | No | Current value. |
panel | Integer | 1 to show in control panel, 0 not to. | No | Current value. |
pin | String | PIN. Empty string is treated as keeping the current value. | No | Current value. |
play | String | "oldest" to play oldest message first, "newest" to play newest message first. | No | Current value. |
saycid | Integer | 1 to say callerid, 0 not to. | No | Current value. |
sayduration | Integer | 1 to say message duration, 0 not to. | No | Current value. |
temporary_active | Integer | 1 if temporary greeting is active, 0 if not. | No | Current value. |
timezone | String | Time zone. | No | Current value. |
transcribe | Integer | 1 to send new voicemails to transcription URL, 0 not to. Only used if configured. | No | 0 |
validation | Integer | 1 to validate input then return, 0 for full action. | No | 0 |
Responses
Code | Description |
---|---|
201 | Input passed validation. Only returned if validation=1. |
204 | Success. |
400 | Invalid input parameters specified. Check the key and message fields for more details. |
401 | The authentication details provided are invalid. |
402 | Your role does not allow this. |
403 | Your rate plan does not allow this. |
404 | The mailbox does not exist, or you do not have permission to update it. |
Data returned
No data is returned.
Example: Changing the PIN
http://enswitch.example.com/api/json/mailboxes/update/?auth_username=user;auth_password=password;mailbox=1234;pin=567890{ "responses":[ { "code":"204", "key":"", "message":"OK" } ] }
Change history
Version | Changes |
---|---|
3.15 | "all" and "text" values added to notify_for input parameter. |
3.14 | transcribe input parameter added. |
3.13 | Function added. |