How merge the output stream with another audio stream

Hi, I have the following use case.

When a person makes or accepts a call I need to add a background song sound (like Marry Christmas) according to holidays, to the output stream.

Is it possible to implement this using Asterisk ?

If so, please suggest what should I use to implement this.


You can use inject the background music using chanspy and local channel


Do not do this if the destination is a mobile phone, or the recipient is otherwise connected with a low bit rate codec, as the resulting speech is likely to be difficult to understand. This is because the codecs used assume that they are handling pure speech.

Thank you for the response, could you provide any example ? One more question whether a caller will hear this sound as well ? I need only a callee to be able to hear this sound.

The caller will hear an echo of the sound, depending on how much echo there is at the callee and how good the echo cancellation is. Echo cancellation at he actual caller’s phone will be ineffective, because it will not know what it is trying to cancel.