Play Music and then busy tone

On an Incoming call, I want to play a music to the caller and then give him a busy signal. I need help with the dial plan. I don’t want the call to be answered.

Sounds weird. But, okay, taken at face value:

I always thought that if you want to play something to the caller, you need to answer the call. But, apparently some channels can play back sounds without answering. Not sure how this works. But, assuming you have to answer your channel and your music is in a sound file:

exten => s,1,Answer()
exten => s,n,Playback(soundfile)
exten => s,n,Busy()

OK I have done some googling myself,

By default, the Playback () App answers the call itself. You don’t have to explicitly specify “Answer()”

But here is a way you can do it,

exten => s,n,Playback(soundfile,noanswer)
exten => s,n,Busy()

Simply specify “noanswer” within the Playback App.

Of course, if the call is coming over the PSTN and you are not yourself a public network operator, it is unlikely that you will be allowed to send any tone without answering. The Progress indication will be ignored, substituted by Ringing, or an Answer will be generated by the network.

To do otherwise, would allow people to provide services without the network charging for them.