Change Voicemail Greeting from extension number to Inbound DID

Is there a way to change the default playback in voicemail?
The storage folder for an extension appears to control what the automated attendant reads back as the extension. (var/spool/asterisk/voicemail/)

Each extension on our system has a DID Routed to it. We would like the DID to be read back to the caller instead of the extension.

Example 1):Extension; When you create an extension (1201), the IVR reads back "The person at extension 1,2,0,1 is unavailable, please leave your message after the tone, when done please hang up or press the pound key.

/var/spool/asterisk/voicemail/device/1201

Example 2):DID; When you create an extension as a DID (3065551212), the IVR reads back "The person at extension 3,0,6,5,5,5,1,2,1,2 is unavailable, please leave your message after the tone, when done please hang up or press the pound key.

/var/spool/asterisk/voicemail/device/3065551212

We use 4 x 24 port SIP Gateways to create a POTS line into each room. (Seniors Apartment Building) We then have extensions assigned to each room (1201, 1202, 1203 etc). This enables the caretaker to simply dial the room number to reach a senior. No need to remember 10 digit phone numbers.

We assign DID’s using “Inbound Route” to each occupied room. The room users change frequently so we are deleting Inbound routed DID’s and then assigning new DID’s when a room is occupied by a new resident.
Has anyone figured out how to have the IVR read the DID back to callers instead of the room extension number?

Thanks.

I found the following link:

http://astbook.asteriskdocs.org/en/2nd_Edition/asterisk-book-html-chunk/asterisk-APP-D-SECT-41.html

It references a custom context variable:

cidinternalcontexts
Sets the internal context for name playback instead of extension digits when saying the Caller ID information.

Does anyone know how to implement this in FreePBX?

Thanks.

I don’t think that is what you are looking for. I think that option is used when retrieving voicemail messages and playing the “envelope” information. I think the option is to play the caller’s name rather than the number.

Just as an experiment, you could try this:

Create a new extension. BEFORE leaving any voicemail, change the “mailbox” setting from extension_number@device to DID@device (substituting the actual DID number for “DID”). Then make a test call to get the voicemail and see what it reads back. If that works as you want, you could then change the mailbox setting in your existing extensions BUT you will then need to make a test call into the new mailbox (use *+extension number) to initialize, and then to copy any saved messages, stored recordings, etc. you will need to go to /var/spool/asterisk/voicemail/default/extension_number and copy the contents to /var/spool/asterisk/voicemail/default/DID (which should already be created at this point). Make sure you copy everything including all subdirectories. After you know it’s working, you can delete the original /var/spool/asterisk/voicemail/default/extension_number mailbox, and also the /var/spool/asterisk/voicemail/device/extension_number symlink.

I have not actually tried any of the above so test thoroughly and don’t delete the “old” mailboxes until you are sure the new ones are working exactly as you want.