Skip to main content

TELES

xDR files​

note

Please note that starting from v3.25.0, we are supporting Teles v3.6 for CDR integration.

In order to set up xDR files integration you need to enable Ifilter and Ofilter in the global config. Also, make sure the following parameters are configured properly:

CDR config
idacdr(Default) {
special = "IDACDR_ON,IDACDR_LEGACY_OFF,IDACDR_OUT_CALL_CONNECT_OFF,IDACDR_UPDATE_CONNECT_TIME_OFF,IDACDR_UPDATE_INTERIM_TIME_OFF,IDACDR_SESSION_TIME_ROUNDUP_ON";
ifilter_start(SIP);
ifilter_update(SIP);
ifilter_stop(SIP);
ofilter_start(SIP);
ofilter_update(SIP);
ofilter_stop(SIP);
ifilter_start(TDM);
ifilter_update(TDM);
ifilter_stop(TDM);
ofilter_start(TDM);
ofilter_update(TDM);
ofilter_stop(TDM);
}

############# Set xad for reroute
ree_forward() {
jump() {
subst() {
#xad="e302-REROUTING"; # example
xad = "eCarrierReroute";
#wad = "[to.hn]n";
}
}
}

The collector adds two special values to the xDRs List report in the Custom field:

  • call_id – call ID generated by TELES
  • xdr_order – order of the record in the TELES CDR file, which can be used to analyze real order of the routes within the routing

RADIUS​

To set up RADIUS integration you need to create RADIUS instances for both authorization and accounting. Please check following screenshots for reference:

RADIUS accounting

RADIUS authentication

While configuring TDM parameters, make sure that it contains the following:

TDM RADIUS Packet
ifilter_start(TDM) {
match() {
dno = ".*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$ridno]n";
ida.nportid = "e";
ida.clisid = "[oad]s/....//";
ida.cldsid = "[dad]s/..//";
ida.uname = "[$user:oad:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ihctype]n";
ida.hcorg = "[$ihcorg]n";
ida.tud2 = "[vad]s/:.*//";
}
}
ifilter_update(TDM) {
match() {
dno = ".*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$ridno]n";
ida.nportid = "e";
ida.clisid = "[oad]s/....//";
ida.cldsid = "[dad]s/..//";
ida.uname = "[$user:oad:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ihctype]n";
ida.hcorg = "[$ihcorg]n";
}
}
ifilter_stop(TDM) {
match() {
dno = ".*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$ridno]n";
ida.nportid = "e";
ida.clisid = "[oad]s/....//";
ida.cldsid = "[dad]s/..//";
ida.uname = "[$user:oad:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ihctype]n";
ida.hcorg = "[$ihcorg]n";
ida.incid = "[vad]s/:.*//";
ida.hdcau = "[$icau]n";
ida.hremaddr = "[$irip]n";
ida.hivrin = "[$hivrin]n";
ida.ctr = "[$ictr]n";
ida.tud4 = "[$ixcau]n";
}
}
ofilter_start(TDM) {
match() {
dno = ".*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$rodno]n";
ida.nportid = "e";
ida.clisid = "[oad]s/....//";
ida.cldsid = "[dad]s/..//";
ida.uname = "[$user:oad:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.outcid = "[$orip]n";
ida.outifdesc = "[$rotrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ohctype]n";
ida.hcorg = "[$ohcorg]n";
}
}
ofilter_update(TDM) {
match() {
dno = ".*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$rodno]n";
ida.nportid = "e";
ida.clisid = "[oad]s/....//";
ida.cldsid = "[dad]s/..//";
ida.uname = "[$user:oad:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.outifdesc = "[$rotrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ohctype]n";
ida.hcorg = "[$ohcorg]n";
}
}
ofilter_stop(TDM) {
match() {
dno = ".*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$rodno]n";
ida.nportid = "e";
ida.clisid = "[oad]s/....//";
ida.cldsid = "[dad]s/..//";
ida.uname = "[$user:oad:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.outifdesc = "[$rotrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ohctype]n";
ida.hcorg = "[$ohcorg]n";
ida.incid = "[$irip:$ricid:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.outcid = "[$orip]n";
ida.hdcau = "[$ocau]n";
ida.hremaddr = "[$orip]n";
ida.hivrin = "[$hivrin]n";
ida.ctr = "[$octr]n";
ida.tud4 = "[$oxcau]n";
}
}

External routing​

In order to set up external routing first of all, you need to configure SIP parameters. While doing it, please make sure that contents include the following:

SIP packet
ifilter_start(SIP) {
match() {
dno = "[AS].*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$ridno]n";
ida.nportid = "e";
ida.clisid = "[from.un]n";
ida.cldsid = "[req.un]n"; # Destination number
ida.incid = "[vad]s/:.*//";
ida.uname = "[$user:from.un:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ihctype]n";
ida.hcorg = "[$ihcorg]n";
ida.tud2 = "[vad]s/:.*//";
}
}
ifilter_update(SIP) {
match() {
dno = "[AS].*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$ridno]n";
ida.nportid = "e";
ida.clisid = "[from.un]n";
ida.cldsid = "[req.un]n";
ida.incid = "[$irip]n";
ida.uname = "[$user:from.un:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ihctype]n";
ida.hcorg = "[$ihcorg]n";
}
}
ifilter_stop(SIP) {
match() {
dno = "[AS].*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$ridno]n";
ida.nportid = "e";
ida.clisid = "[from.un]n";
ida.cldsid = "[zad]n";
ida.uname = "[$user:from.un:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ihctype]n";
ida.hcorg = "[$ihcorg]n";
ida.incid = "[vad]s/:.*//";
ida.hdcau = "[$icau]n";
ida.hremaddr = "[$irip]n";
ida.hivrin = "[$hivrin]n";
ida.ctr = "[$ictr]n";
ida.tud4 = "[$ixcau]n";
}
}
ofilter_start(SIP) {
match() {
dno = "[AS].*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$rodno]n";
ida.nportid = "e";
ida.clisid = "[from.un]n";
ida.cldsid = "[req.un]n";
ida.outcid = "[$orip]n";
ida.uname = "[$user:from.un:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.outifdesc = "[$rotrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ohctype]n";
ida.hcorg = "[$ohcorg]n";
}
}
ofilter_update(SIP) {
match() {
dno = "[AS].*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$rodno]n";
ida.nportid = "e";
ida.clisid = "[from.un]n";
ida.cldsid = "[req.un]n";
ida.outcid = "[$orip]n";
ida.uname = "[$user:from.un:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.outifdesc = "[$rotrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ohctype]n";
ida.hcorg = "[$ohcorg]n";
}
}
ofilter_stop(SIP) {
match() {
dno = "[AS].*";
}
idasubst() {
ida.stype = "e1";
ida.nporttype = "e0";
ida.nport = "[$rodno]n";
ida.nportid = "e";
ida.clisid = "[from.un]n";
ida.cldsid = "[req.un]n";
ida.uname = "[$user:from.un:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.inifdesc = "[$ritrk]n";
ida.outifdesc = "[$rotrk]n";
ida.hgwid = "[$lnm]n";
ida.hconfid = "[$hconfid]n";
ida.hctype = "[$ohctype]n";
ida.hcorg = "[$ohcorg]n";
ida.incid = "[$irip:$ricid:]s/[:]*\([^:][^:]*\):.*/\1/";
ida.outcid = "[$orip]n";
ida.hdcau = "[$ocau]n";
ida.hremaddr = "[$orip]n";
ida.hivrin = "[$hivrin]n";
ida.ctr = "[$octr]n";
ida.tud4 = "[$oxcau]n";
}
}

The next step is to specify a route for redirection to JeraSoft Billing (from `mgc.rou``).

Routing config
########################################
route(set_zad){
match(){
zad="";
}
jump(){
subst(){
zad="[$req.un]n";
}
}
}
#########################################
route(set_wad){
match(){
wad="";
}
jump(){
subst(){
wad="[$vad]s/:.*//";
}
}
}
###########################################
1.{
dno = "r/A1";
xad = "";
}
mediain(Mediain_ISP2){
caps = "g711alaw, g711ulaw, g729r8, g729ar8, g723r53, g723ar53, g723r63, g729br8, g729abr8, gsmfr, gsmefr, telev";
modcaps = "g711alaw, g711ulaw, g729r8, g729ar8, g723r53, g723ar53, g723r63, g729br8, g729abr8, gsmfr, gsmefr, telev, t38";
faxcaps = "t38, g711alaw, g711ulaw";
modemdt = "all";
modemcaps = "g711alaw, g711ulaw";
ece = "yes";
sce = "no";
capsstrat = "force";
realm = "mp4";
}
share(SH_Jera_Redirect);
reject(){
cau = "CAU_NO_RT_DST";
location = "LOC_USER";
}
}
share(SH_Jera_Redirect){
subst(){
dno = "r/A128/";
vad = "e127.0.0.1:5060";
req.hn = "e127.0.0.1";
req.pt = "e5060";
to.hn = "e127.0.0.1";
from.hn = "[wad]n";
priv.hpm = "[$hconfid]n";
rcause(REE_CAUSES){
ree_cause= "CAU_SIP_MCHO";
}
}
}
###########################################
2.
route(JLCR_REROU){
match(){
xad = "CarrierReroute";
bcont.hn = "^[^R].*";
}
subst(){
vad = "[bcont.hn:bcont.pt]n"; # ..
to.scm = "esip";
to.hn = "[bcont.hn]n";
to.un = "[bcont.un]n"; # ..
to.dn = "[bcont.un]n";
req.scm = "esip";
req.hn = "[bcont.hn]n"; # ..
req.un = "[bcont.un]n";
req.pm = "[bcont.pm]n";
req.upm = "[bcont.upm]n";
from.scm = "esip";
from.hn = "e127.0.0.1";
yad = "[bcont.un]n";
}
jump(NEXT_CONTACT);
}