Incoming callerid from database when using trunk

Hi,

I may be really confused but I can’t seem to see how callerid should work with a H323 trunk.

We are running FreePBX 2.3 and Asterisk 1.4.10

We’ve got an Avaya IP Office system currently in place but are trialling FreePBX as a replacement. We only have one E1 line coming in, so the Avaya system is routing calls through.

In the h323.conf we have this:

[ipo] canreinvite=no canredirect=no context=from-trunk h245tunneling=yes port=1720 host=192.168.179.1 type=peer

and in FreePBX we have a custom trunk with the dialstring:

H323/[email protected]

We would like to use our MySQL database as the caller id source, however there doesn’t seem to be a way of setting a default? If we manually create an inbound route for an extension that just matches one number and points it at the corresponding extension, then we can set the caller id source and it works correctly. Do we need to create an inbound route for every extension?

Any advice appreciated!

Thanks,
Tom

This is for inbound? Can you route to a custom context and have that set the CID? I do something similar (not for the same reasons tho…)

Yes, this is for incoming CLID. We do get the CLID from the Avaya phone system but it doesn’t do it very well (very limited database size). We have a MySQL database containing all our customers’ outgoing phone numbers.

So, a call comes in from 0161 905 2000 to 0161 906 1000 say, and the IP Office sees that as just ‘01619052000>1000’. I’ve set an incoming route on the IP Office to map the 1000 extension to 3000 on the FreePBX system.

The FreePBX system sees 01619052000>3000 and passes it on to extension 3000 which is a SIP client. The client sees that the call is from 01619052000

If I create an incoming route for each extension and set the caller id source then it looks up 01619052000 in the database correctly, but I thought there might be a better way than creating an incoming route for each extension, all we have currently have in there are hunt groups and a DISA.

I’m not quite sure how to add a custom context…!