Сделал следующим образом. Работает.
exten = _X.,1,NoOp(${CALLERID(num)} => ${EXTEN})
same = n,Answer()
same = n,Playback(ivr/none-worktime)
same = n,Set(fname=${UNIQUEID}-${STRFTIME(${EPOCH},,%Y-%m-%d-%H_%M)}-${CALLERID(num)}-${EXTEN});
same = n,Set(CDR(filename)=${fname}.wav);
same = n,Set(CDR(realdst)=${EXTEN});
same = n,Set(CDR(remoteip)=${CHANNEL(recvip)});
same = n,NoOp(File name is ${fname})
same = n,Record(${DIR_RECORDS}${fname}.wav,10,60,kx)
same = n,Hangup()