Background music untill call is connected


Is there any way to create dialplan logic described bellow?

  • Answer()
  • PlayMusicInBackground(i cannot use MOH because i want logic to continue execution to next step)
  • perform operation1 (while music is playing),
  • perform operation2 (while music is playing),
  • Dial,
  • Stop music only when dial is connected?

Best regards, KB

If your dialplan operations do not playback any media on the channel, you should be able to use the StartMusicOnHold application to have it playback while doing processing. In the Dial() application, you can use the ‘m’ flag plays back music on hold as the ringback. Maybe some combination of those two things can get you what you need.

Matthew Fredrickson

1 Like

You can use Local channel to place caller on a hold conext while execute the other dial plan task


StartMusicOnHold and StopMusicOnHold did the trick,

Thanks very much for help!

Best regards and have a nice weekend!