Create auto answer message


I need to record a message that the company is not working from 18:00 until 8:00 and make it autoplay those specific hours.
in which format do i record the message also what should i use to add it to asterisk?
Please note that im using asterisk 13.23.1

Iā€™d recommend recording in your native channel format to reduce transcoding overhead, typically this is ulaw or alaw, You could also record in signed linear.

You would modify your dialplan to play the message with Playback() or Background()

this is the easy part. how to make it play only specific hours. do you have any example?

See extensions.conf.sample.

It was much easier than what i was expecting. Here is a small example:

exten => s,1,NoOp(Incoming Call)
exten => s,n,ExecIfTime(09:00-12:00,mon-fri,1-31,jan-dec?Playback(good-morning))
exten => s,n,ExecIfTime(12:01-18:00,mon-fri,1-31,jan-dec?Playback(good-afternoon))
exten => s,n,ExecIfTime(18:01-21:00,mon-fri,1-31,jan-dec?Playback(good-night))
exten => s,VoiceMail(1101@default,u)

Thanks for the info