Skip to main content

Inbound DID Forward to External Answering Service

Posted by Ariel on Tue, 03/24/2009

Hi,

I am fairly new to Thirdlane and Asterisk. My task is to learn both and eventually migrate our office (really 2 companies in one office) to Thirdlane ST. We are on an existing Asterisk 1.4 server. I have all the existing configs and features used to work from to put it all in TL.

My current issue is this:

On hours: Ring to internal hunt group, where multiple phones ring at once.

Off hours: Call comes in to the main number and is immediately rerouted to an answering service.
I have a testbed with 3 lines (with external DID) and the server. I have learned how the rule precedence works for the Time-Based-Handlers and have successfully made timing work. However, I cannot find the right method or script to take the call as it comes in and immediately shoot it to the answering service (or any given external number). I have tried using the tl-dialout-1trunk to do it, but there is no place to put the number to dial (we tried putting the whole number as the 'prepend text'). I tried writing my own script using the existing Asterisk server's extension line syntax (the actual line the regular server uses for this forwarding). I have tried using another hunt group and putting this number into the 'other numbers to dial' list (this one fails since it is trying to dial from Local/).

In our office currently, no phone is provisioned to this number specifically, it just hits the Asterisk box and follows its rules for where to send the call inside and then outside, based on time.

I would imagine there is some normal way to do this, but I have not found it.

Thanks,

Ariel


Submitted by eeman on Tue, 03/24/2009 Permalink

there should be no reason that the 'other numbers to dial' wouldnt actually work unless the number you put in here does not match a pattern for an outbound route.

Local/2345678910 should match a _NXXNXXXXXX pattern just like you dialed it from your phone.

hunt lists technically arent the best way to handle this though.

Another less-than-ideal method would be to use the IVR system with a very quick timeout and a invalid and no input option to dial phone number.

you could use the tl-reroute macro, though the whole strip and prepend can get a little confusing when you want to strip the whole thing and prepend a whole new number.

here is a 1-liner

name: bgnv-forward-did

Descriptive name: Forward DID to another number

Script Description:

Forwards an inbound call to another number.

PBX Command:

exten => s,1,Dial(Local/${ARG1}@outgoing${TL_DASH}${tenant})

Arguments

arg 1 - "Number to call" type -> text

Submitted by Ariel on Tue, 03/24/2009 Permalink

Thanks a lot! Your script worked perfectly. I also did think of the reroute method, but it started getting sticky.

I will start a new thread for my other questions.

You've been a lot of help.

Ariel