Voice over IP Integration - Call from Any SIP Softphone

Instructions for connecting FusionPBX with the Home Assistant Voice over IP integration:

  1. Setup FusionPBX, provision a SIP device, and verify with a test call. The specifics for completing this step are outside of the scope of these instructions.
  2. Enable Opus module: Advanced menu > Modules option > Codecs header - Set “Opus” to Enabled = True and Start the module.
  3. Add Opus codec to the list of preferred codecs: Advanced menu > Variables option > Codecs header – Add “OPUS” to the beginning of global_codec_prefs and outbound_codec_prefs. Set media_mix_inbound_outbound_codecs to true.
  4. Adjust the SIP Profiles: Advanced menu > SIP Profiles option > Settings section > Internal profile – ensure the following settings are set properly.

inbound-late-negotiation=true,true
inbound-codec-negotiation=generous,true

  1. On your SIP device, add Opus as an active and preferred codec. The process for accomplishing this varies by device and manufacturer. If you are using FusionPBX to provision your SIP device, you may have to adjust the appropriate variables within Advanced menu > Default Settings option > Provision header.
  2. Add the Outbound Dialplan: Dialplan menu > Outbound Routes option. Create a new dialplan with the following settings.

Gateway = enum (we will change this in a moment)
DIalplan Expression = ^111$ (replace 111 with the number you wish to use to reach HA)
Enabled = true
Description = Home Assistant

  1. Edit the dialplan: Dialplan menu > Outbound Routes option > enum.### dialplan.
    a. Change the name of the dialplan to something like “Home Assistant.###” (with ### matching the extension number you chose).
    b. Configure the following settings. For settings where a > true is at the end, this signifies the Enabled column within the Dialplan.

action > set > hangup_after_bridge=true > true action > set > callee_id_name=Home Assistant > true action > set > callee_id_number=### > true (number of the extension you chose) action > bridge > sofia/internal/sip:<HA IP Address> > true (insert IP addr of Home Assistant)

  1. Reboot FusionPBX to ensure everything has taken effect (optional step).
  2. Attempt to call Home Assistant using the extension number you defined above.

so I’ve managed to call from my mac softphone, via FreePBX to Home Assistant.

It plays the ‘go’ sound (the two tones), but when I speak, nothing happens.

When I look in debug, it looks like this, even minutes later (see circle spinning next to STT)

Screenshot 2023-09-12 at 12.51.16

I got mine working using microsip via asterisk to the point where I could hear the ‘This is your home assistant’ loop, I then clicked ‘allow calls’ in hass but when i call it back, i get a ‘not available’ error from my freepbx. Did you have any issues like that/

this is exactlly what i’m looking for. I would like to have like an entitiy in the VOIP integration, to ring the phone. The hook is already detected. So I asume that this would not a big deal for the creator. Did you manage to start a new topic/request this feature?

Maybe this is completely off-topic… I will try nevertheless. I have a VoIP phone in the house of my mum and I would like to use it as an alarm clock to wake her up because her hearing is very bad. Would it be possible to ring the voip phone from HA???

1 Like

If you find a solution for this, please let me know. I’m interested in the exact same feature. Maybe we should contact the developer

1 Like

I tried to build a call flow app for the 3CX pbx that is hosting the phone, but I can’t get it to work… For now I just send her a notification to her iPhone through HA. But it would be so much better if I could call her VoIP phone.

For years I have used Home Assistant and various pbx systems, e.g. 3cx, freepbx, VitalPBX which was good until they limited the extensions to only 10?? Now I have built MikoPBX, which is made by Russian developers and is free to use, no restrictions, but you get paid support and add-ons.

VitalPBX had support for Home Assistant, I would like the same for the MikoPBX system. I just got the Goip adapter working. Or it would also be good if someone developed support for Home assistant in the Goip adapter.

Any of you guys figured out an easier way to broadcasting TTS generated from HA on your SIP phones? :slight_smile: Thanks!