magnussolution / magnusbilling7

MagnusBilling is a fast, secure, efficient, high availability, VOIP Billing.
https://www.magnusbilling.org
GNU Lesser General Public License v3.0
180 stars 107 forks source link

Caller ID set by softphone #375 #497

Closed xceedconnections closed 3 years ago

xceedconnections commented 3 years ago

i added [callerid] exten => _X.,1,Set(CALLERID(nun)=${CALLERID(name)}) IN extension_magnus.conf

how to set the context in magnus billing and forward call to the billing context.

please show an example.

for more info visit https://github.com/magnussolution/magnusbilling7/issues/375 to solve it

xceedconnections commented 3 years ago

@itsshimmer @magnussolution

magnussolution commented 3 years ago

add this line on the context billing exten => _X.,1,Set(CALLERID(nun)=${CALLERID(name)})

xceedconnections commented 3 years ago

LIKE THIS IN extension_magnus.conf ????

add this line on the context billing exten => _X.,1,Set(CALLERID(nun)=${CALLERID(name)})

magnus

uzair329 commented 3 years ago

OR you can write this command in different context and than use Goto option like this we do for one client and set his context to callerid [callerid] exten => _X.,1,Set(cli2=${SIP_HEADER(Remote-Party-ID)}) exten => _X.,n,Set(cli=${CUT(cli2,\",2)}) exten => _X.,n,Noop(${cli}) exten => _X.,n,Set(CALLERID(num)=XXXXXXXXX) exten => _X.,n,Goto(billing,${EXTEN},1) exten => _X.,n,Hangup

uzair329 commented 3 years ago

add these lines in extensions.conf

xceedconnections commented 3 years ago

@uzair329 tried this. its not working. can you please provide me your contact number at my email so i can contact you xceedconnections@gmail.com

uzair329 commented 3 years ago

Please share what you did? And what is your main objective?


From: xceedconnections notifications@github.com Sent: Saturday, March 6, 2021 8:13:08 PM To: magnussolution/magnusbilling7 magnusbilling7@noreply.github.com Cc: uzair329 uzair_a_s@hotmail.com; Mention mention@noreply.github.com Subject: Re: [magnussolution/magnusbilling7] Caller ID set by softphone #375 (#497)

@uzair329https://github.com/uzair329 tried this. its not working. can you please provide me your contact number at my email so i can contact you xceedconnections@gmail.commailto:xceedconnections@gmail.com

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/magnussolution/magnusbilling7/issues/497#issuecomment-791969642, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AOJJLCJRB23KHSX4WDH4NVLTCJBAJANCNFSM4WU63KSQ.

xceedconnections commented 3 years ago

I added

[callerid] exten => _X.,1,Set(cli2=${SIP_HEADER(Remote-Party-ID)}) exten => _X.,n,Set(cli=${CUT(cli2,",2)}) exten => _X.,n,Noop(${cli}) exten => _X.,n,Set(CALLERID(num)=XXXXXXXXX) exten => _X.,n,Goto(billing,${EXTEN},1) exten => _X.,n,Hangup

in extensions.conf.

also in user context I set billing to callerID.

and then tried dialing calls are not going through.

what I want is

my customers can change callerID from eyebeam. right now they are changing callerID from magnus billing portal.

xceedconnections commented 3 years ago

@uzair329 i want my users to change the callerid using xlite/ eyebeam. what ever number they mention in eyebeam display, shoudl be used as their callerid.

uzair329 commented 3 years ago

First check in which variable you are receiving callerid from eyebeam when client is setting and in which format you are getting. You can check this by running sip debug


From: xceedconnections notifications@github.com Sent: Tuesday, March 9, 2021 3:54:42 PM To: magnussolution/magnusbilling7 magnusbilling7@noreply.github.com Cc: uzair329 uzair_a_s@hotmail.com; Mention mention@noreply.github.com Subject: Re: [magnussolution/magnusbilling7] Caller ID set by softphone #375 (#497)

@uzair329https://github.com/uzair329 i want my users to change the callerid using xlite/ eyebeam. what ever number they mention in eyebeam display, shoudl be used as their callerid.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/magnussolution/magnusbilling7/issues/497#issuecomment-793711126, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AOJJLCK7SXVUDFS555YCR4DTCX47FANCNFSM4WU63KSQ.

foryourhost commented 3 years ago

i already add this

[dincli] exten => _[*0-9].,1,AGI("/var/www/html/mbilling/resources/asterisk/mbilling.php$ same => n,Hangup()

exten => _X.,1,Set(CALLERID(nun)=${CALLERID(name)})

exten => h,1,hangup()

exten => *111,1,VoiceMailMain(${CHANNEL(peername)}@dincli) same => n,Hangup()

but error is happen

Executing [12158664168@dincli:1] Set("SIP/97833-00005160", "CALLERID(nun) =13342342407") in new stack [2021-06-04 18:13:37] ERROR[2008][C-0000798d]: func_callerid.c:1271 callerid_wri te: Unknown callerid data type 'nun'. -- Executing [12158664168@dincli:2] Hangup("SIP/97833-00005160", "") in new stack == Spawn extension (dincli, 12158664168, 2) exited non-zero on 'SIP/97833-0000 5160' -- Executing [h@dincli:1] Hangup("SIP/97833-00005160", "") in new stack == Spawn extension (dincli, h, 1) exited non-zero on 'SIP/97833-00005160'

Madji commented 3 years ago

Error this exten => _X.,1,Set(CALLERID(nun)=${CALLERID(name)})

Right exten => _X.,1,Set(CALLERID(num)=${CALLERID(name)})

foryourhost commented 3 years ago

thanks for your replay but we replace that but call is not going to

<------------> -- Executing [12158664168@dincli:1] Set("SIP/97833-00005165", "CALLERID(num)=13342342407") in new stack -- Executing [12158664168@dincli:2] Hangup("SIP/97833-00005165", "") in new stack == Spawn extension (dincli, 12158664168, 2) exited non-zero on 'SIP/97833-00005165' -- Executing [h@dincli:1] Hangup("SIP/97833-00005165", "") in new stack == Spawn extension (dincli, h, 1) exited non-zero on 'SIP/97833-00005165' Scheduling destruction of SIP dialog 'd34f08776e6fdc06NzJmMGVmYzQwZDA3MGZjNTMxMzA3N2U3ZGNiZjRjMDE.' in 30720 ms (Method: INVITE)

<--- Reliably Transmitting (NAT) to 157.40.251.71:7636 ---> SIP/2.0 603 Declined Via: SIP/2.0/UDP 157.40.251.71:7636;branch=z9hG4bK-d87543-2b35a1784a3d1074-1--d87543-;received=157.40.251.71;rport=7636 From: "13342342407"sip:97833@XX.188.186.XXX;tag=617bf73e To: "12158664168"sip:12158664168@XX.188.186.XXX;tag=as441136bb Call-ID: d34f08776e6fdc06NzJmMGVmYzQwZDA3MGZjNTMxMzA3N2U3ZGNiZjRjMDE. CSeq: 2 INVITE Server: MagnusBilling Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, PUBLISH, MESSAGE Supported: replaces, timer Content-Length: 0

<------------>