Built motion from commit bfc7a72f7045b27461c9a5d1f71c1a658cfd0b8b. Version 3.0.0...
[motion-next.git] / server / services / agi / channel.js
index 5c01a1a..1e6853e 100644 (file)
@@ -1 +1 @@
-const a1026_0x28ba=['lodash','STREAM\x20FILE\x20\x22%s\x22\x20\x22%s\x22','replace','AGI','wav','function','close','E_AGI_SOCKET_CLOSE','SET\x20CONTEXT\x20%s','E_AGI_SOCKET_TIMEOUT','extension','getData','RECORD\x20FILE\x20\x22%s\x22\x20\x22%s\x22\x20\x22%s\x22\x20%s\x20%s\x20%s','length','ANSWER','exec','split','toString','answer','HANGUP','setPriority','substr','isArray','agi','search','setTimeout','continueAt','beep','setEncoding','match','setExtension','command','result=','520-Invalid','no\x20code','isNumber','util','toLowerCase','setVariable','startsWith','format','GET\x20VARIABLE\x20\x22%s\x22','sendRequest','timeout','./error','headers','SET\x20VARIABLE\x20%s\x20\x22%s\x22','substring','indexOf','WAIT','error','BEEP','520\x20End\x20of\x20proper','streamFile','recordFile','ready','SET\x20EXTENSION\x20%s','write','line','label','utf8','prototype','join','sayNumber','setContext','hangup','VERBOSE\x20\x22%s\x22','noop','EXEC\x20%s\x20%s','isBoolean','destroy','wait','emit'];(function(_0x1bac90,_0x28ba34){const _0x30ef9b=function(_0x5c7848){while(--_0x5c7848){_0x1bac90['push'](_0x1bac90['shift']());}};_0x30ef9b(++_0x28ba34);}(a1026_0x28ba,0x77));const a1026_0x30ef=function(_0x1bac90,_0x28ba34){_0x1bac90=_0x1bac90-0x0;let _0x30ef9b=a1026_0x28ba[_0x1bac90];return _0x30ef9b;};const _0x71c7e1=a1026_0x30ef;'use strict';const util=require(_0x71c7e1('0x3f')),_=require(_0x71c7e1('0x1b')),EventEmitter=require('events')['EventEmitter'],AGIReply=require('./reply'),AGIError=require(_0x71c7e1('0x47'));function AGIChannel(_0x5c7848){const _0x2bae32=_0x71c7e1,_0x3867f3=this,_0x682e3b=new AGIReply();let _0x3a0b11=![],_0x5d0b4a={};EventEmitter['call'](_0x3867f3),_0x5c7848[_0x2bae32('0x37')](_0x2bae32('0xe')),_0x5c7848[_0x2bae32('0x34')](0x8*0x3c*0x3c*0x3e8),_0x682e3b[_0x2bae32('0x37')](_0x2bae32('0xe')),_0x682e3b['on'](_0x2bae32('0x48'),function(_0x51d480){const _0x53ba79=_0x2bae32;for(const _0x21dbd5 in _0x51d480){_0x3867f3[_0x21dbd5]=_0x51d480[_0x21dbd5];}_0x3867f3['emit'](_0x53ba79('0x9'));}),_0x682e3b['on'](_0x2bae32('0xc'),function(_0x42cea2){const _0x1ffa3f=_0x2bae32;if(_0x42cea2[_0x1ffa3f('0x40')]()==_0x1ffa3f('0x13')){_0x3867f3[_0x1ffa3f('0x1a')](_0x1ffa3f('0x13'));return;}_0x42cea2[_0x1ffa3f('0x1')](0x0,0xb)==_0x1ffa3f('0x3c')&&(_0x3a0b11=!![]);_0x3a0b11?(_0x5d0b4a['rx']+=_0x42cea2+'\x0a',_0x42cea2[_0x1ffa3f('0x33')](_0x1ffa3f('0x6'))!=-0x1&&(_0x3a0b11=![])):_0x5d0b4a['rx']=_0x42cea2;if(_0x3a0b11)return;if(typeof _0x5d0b4a['cb']==_0x1ffa3f('0x20')){let _0x3e7259=_0x5d0b4a['rx'][_0x1ffa3f('0x1')](0x0,0x3),_0x1421a1=null,_0x31e4ca=null;_0x3e7259=parseInt(_0x3e7259);if(isNaN(_0x3e7259)){_0x5d0b4a['cb'](null,{'code':0x1f4,'result':-0x1,'extra':_0x1ffa3f('0x3d')});return;}if(_0x3e7259!=0xc8){_0x5d0b4a['cb'](null,{'code':_0x3e7259,'result':-0x1,'extra':'KO'});return;}_0x1421a1=_0x5d0b4a['rx'][_0x1ffa3f('0x1')](0x4)[_0x1ffa3f('0x1d')](_0x1ffa3f('0x3b'),'');_0x1421a1[_0x1ffa3f('0x2')]('\x20')!=-0x1&&(_0x1421a1=_0x1421a1[_0x1ffa3f('0x30')](0x0,_0x1421a1[_0x1ffa3f('0x2')]('\x20')));_[_0x1ffa3f('0x42')](_0x1421a1,'-1')&&(_0x1421a1=parseInt(_0x1421a1));_0x31e4ca=_0x5d0b4a['rx'][_0x1ffa3f('0x2b')]('\x20');if(_0x31e4ca[_0x1ffa3f('0x28')]==0x3)_0x31e4ca=_0x31e4ca[0x2][_0x1ffa3f('0x1')](0x1,_0x31e4ca[0x2][_0x1ffa3f('0x28')]-0x1);else{if(_0x31e4ca[_0x1ffa3f('0x28')]>0x3){const _0x53849f=/\((.+)\)/,_0x37b2f7=_0x5d0b4a['rx'][_0x1ffa3f('0x38')](_0x53849f);_0x37b2f7?_0x31e4ca=_0x37b2f7[0x1]:_0x31e4ca=null;}else _0x31e4ca=null;}_0x5d0b4a['cb'](null,{'code':_0x3e7259,'result':_0x1421a1,'extra':_0x31e4ca});}}),_0x5c7848['on']('error',function(_0x3c32aa){const _0x2e3f4b=_0x2bae32;_0x3867f3[_0x2e3f4b('0x1a')](_0x2e3f4b('0x4'),new AGIError('E_AGI_SOCKET_ERROR',_0x3c32aa['code']));}),_0x5c7848['on'](_0x2bae32('0x21'),function(){const _0x32c1f0=_0x2bae32;_0x3867f3[_0x32c1f0('0x1a')]('close',new AGIError(_0x32c1f0('0x22')));}),_0x5c7848['on'](_0x2bae32('0x46'),function(){const _0x3b2963=_0x2bae32;_0x3867f3[_0x3b2963('0x1a')](_0x3b2963('0x46'),new AGIError(_0x3b2963('0x24'))),_0x5c7848[_0x3b2963('0x18')]();}),_0x5c7848['pipe'](_0x682e3b),(this[_0x2bae32('0x3a')]=function(_0x29c6d9,_0x588bf5){const _0x5579cf=_0x2bae32;_0x29c6d9=_0x29c6d9||'',_0x588bf5=typeof _0x588bf5==_0x5579cf('0x20')?_0x588bf5:new Function(),_0x5d0b4a={'tx':_0x29c6d9,'rx':'','cb':_0x588bf5},_0x5c7848[_0x5579cf('0xb')](_0x29c6d9+'\x0a');},this['close']=function(){const _0x3f487b=_0x2bae32;_0x5c7848[_0x3f487b('0x18')]();});}util['inherits'](AGIChannel,EventEmitter),AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x45')]=function(_0x76de8){const _0x2d6204=_0x71c7e1;return this[_0x2d6204('0x3a')]['sync'](this,_0x76de8);},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x2d')]=function(){const _0x14f245=_0x71c7e1;return this[_0x14f245('0x45')](_0x14f245('0x29'));},AGIChannel['prototype'][_0x71c7e1('0x26')]=function(_0xb0ac87,_0x103d5c,_0x213ecd){const _0x434df5=_0x71c7e1;return _0xb0ac87=_0xb0ac87===undefined?_0x434df5('0x36'):_0xb0ac87,_0x103d5c=_0x103d5c===undefined?'5':_0x103d5c,_0x213ecd=_0x213ecd===undefined?'1':_0x213ecd,this[_0x434df5('0x45')](util['format']('GET\x20DATA\x20\x22%s\x22\x20%s\x20%s',_0xb0ac87,_0x103d5c*0x3e8,_0x213ecd));},AGIChannel['prototype'][_0x71c7e1('0x15')]=function(_0x36a1df){const _0x3f2ef2=_0x71c7e1;return _0x36a1df=_0x36a1df||'NO\x20MESSAGE',this[_0x3f2ef2('0x45')](util[_0x3f2ef2('0x43')](_0x3f2ef2('0x14'),_0x36a1df));},AGIChannel[_0x71c7e1('0xf')]['exec']=function(_0x17758b,_0x59eb74){const _0x3641ac=_0x71c7e1;if(_[_0x3641ac('0x31')](_0x59eb74))return this[_0x3641ac('0x45')](util[_0x3641ac('0x43')]('EXEC\x20%s\x20%s',_0x17758b,_0x59eb74[_0x3641ac('0x10')](',')));return this[_0x3641ac('0x45')](util[_0x3641ac('0x43')](_0x3641ac('0x16'),_0x17758b,_0x59eb74));},AGIChannel['prototype']['setContext']=function(_0x401fe1){const _0x3938ba=_0x71c7e1;return this[_0x3938ba('0x45')](util[_0x3938ba('0x43')](_0x3938ba('0x23'),_0x401fe1));},AGIChannel['prototype']['setExtension']=function(_0xdcf1cb){const _0x3eb391=_0x71c7e1;return this['sendRequest'](util['format'](_0x3eb391('0xa'),_0xdcf1cb));},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x2f')]=function(_0x186d4c){const _0x2009d7=_0x71c7e1;return this[_0x2009d7('0x45')](util[_0x2009d7('0x43')]('SET\x20PRIORITY\x20%s',_0x186d4c));},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x13')]=function(){const _0x144ab7=_0x71c7e1;return this[_0x144ab7('0x45')](_0x144ab7('0x2e'));},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x41')]=function(_0x4a1f59,_0x2ffd99){const _0x287d6e=_0x71c7e1,_0x329205=_[_0x287d6e('0x17')](_0x2ffd99)||_[_0x287d6e('0x3e')](_0x2ffd99)?_0x2ffd99[_0x287d6e('0x2c')]():_0x2ffd99;return this[_0x287d6e('0x45')](util[_0x287d6e('0x43')](_0x287d6e('0x0'),_0x4a1f59,_0x329205?_0x329205[_0x287d6e('0x2c')]()['replace'](/(\r\n|\n|\r)/gm,'\x20'):''));},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x11')]=function(_0x4d6409,_0x3aa4c6){const _0x28107c=_0x71c7e1;return this[_0x28107c('0x45')](util[_0x28107c('0x43')]('SAY\x20NUMBER\x20%s\x20%s',_0x4d6409,_0x3aa4c6));},AGIChannel[_0x71c7e1('0xf')]['sayDigits']=function(_0x80ba56,_0x49ccee){const _0x2cc2ff=_0x71c7e1;return this[_0x2cc2ff('0x45')](util[_0x2cc2ff('0x43')]('SAY\x20DIGITS\x20%s\x20%s',_0x80ba56,_0x49ccee));},AGIChannel[_0x71c7e1('0xf')]['sayPhonetic']=function(_0x2690cf,_0x22f25a){const _0xc383f4=_0x71c7e1;return this[_0xc383f4('0x45')](util[_0xc383f4('0x43')]('SAY\x20PHONETIC\x20\x22%s\x22\x20%s',_0x2690cf,_0x22f25a));},AGIChannel['prototype'][_0x71c7e1('0x35')]=function(_0x489975,_0x58976e,_0x1715b4){const _0x647f88=_0x71c7e1;return _0x58976e=_0x58976e||this[_0x647f88('0x25')],_0x1715b4=_0x1715b4||0x1,this[_0x647f88('0x12')](_0x489975),this[_0x647f88('0x39')](_0x58976e),this['setPriority'](_0x1715b4),this[_0x647f88('0x15')](util[_0x647f88('0x43')]('GOTO\x20%s\x20%s\x20%s',_0x489975,_0x58976e,_0x1715b4));},AGIChannel[_0x71c7e1('0xf')]['getVariable']=function(_0x4db3d9){const _0x3fb331=_0x71c7e1;return this[_0x3fb331('0x45')](util['format'](_0x3fb331('0x44'),_0x4db3d9));},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x8')]=function(_0x71d3d0,_0x39d0b1,_0x3e73c0,_0x56e224,_0x454066,_0x471915){const _0x29dde2=_0x71c7e1;return _0x39d0b1=_0x39d0b1||_0x29dde2('0x1f'),_0x3e73c0=_0x3e73c0||'',_0x56e224=_0x56e224===undefined?-0x1:_0x56e224==='-1'?-0x1:_0x56e224*0x3e8,_0x454066=_0x454066===undefined?'':'s='+_0x454066,_0x471915=_0x471915?_0x29dde2('0x5'):'',this[_0x29dde2('0x45')](util['format'](_0x29dde2('0x27'),_0x71d3d0,_0x39d0b1,_0x3e73c0,_0x56e224,_0x471915,_0x454066));},AGIChannel['prototype'][_0x71c7e1('0x7')]=function(_0x108f86,_0x25162e){const _0xdbad65=_0x71c7e1;return _0x25162e=_0x25162e||'',this[_0xdbad65('0x45')](util[_0xdbad65('0x43')](_0xdbad65('0x1c'),_0x108f86,_0x25162e));},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x32')]=function(_0x488120){const _0x5f48bf=_0x71c7e1;return this[_0x5f48bf('0x2a')](_0x5f48bf('0x1e'),_0x488120);},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x19')]=function(_0x28ebc){const _0x4460e0=_0x71c7e1;return this['exec'](_0x4460e0('0x3'),_0x28ebc);},AGIChannel[_0x71c7e1('0xf')][_0x71c7e1('0x4')]=function(_0x1fe29e,_0x4584be){const _0x2da41d=_0x71c7e1;return this[_0x2da41d('0x15')](util[_0x2da41d('0x43')]('ID:%s\x20-\x20LABEL:\x20%s\x20-\x20MSG:\x20%s',_0x1fe29e['id'],_0x1fe29e[_0x2da41d('0xd')],_0x4584be)),{'code':0x1f4,'result':'-1','extra':''};},module['exports']=AGIChannel;
\ No newline at end of file
+const a1026_0x4063=['noop','split','WAIT','events','match','ID:%s\x20-\x20LABEL:\x20%s\x20-\x20MSG:\x20%s','result=','setVariable','timeout','label','function','isNumber','E_AGI_SOCKET_TIMEOUT','wait','AGI','ANSWER','SAY\x20DIGITS\x20%s\x20%s','sync','520-Invalid','SAY\x20PHONETIC\x20\x22%s\x22\x20%s','replace','indexOf','length','SET\x20VARIABLE\x20%s\x20\x22%s\x22','wav','setTimeout','util','continueAt','E_AGI_SOCKET_ERROR','sendRequest','recordFile','VERBOSE\x20\x22%s\x22','join','pipe','SET\x20PRIORITY\x20%s','getVariable','search','sayDigits','520\x20End\x20of\x20proper','GET\x20DATA\x20\x22%s\x22\x20%s\x20%s','isArray','destroy','startsWith','emit','utf8','getData','isBoolean','format','toLowerCase','error','substr','line','RECORD\x20FILE\x20\x22%s\x22\x20\x22%s\x22\x20\x22%s\x22\x20%s\x20%s\x20%s','beep','command','EXEC\x20%s\x20%s','hangup','setExtension','substring','inherits','setPriority','close','SAY\x20NUMBER\x20%s\x20%s','GET\x20VARIABLE\x20\x22%s\x22','./error','prototype','toString','EventEmitter','write','exec','answer'];(function(_0x216d7f,_0x40638b){const _0x584445=function(_0x5f40d4){while(--_0x5f40d4){_0x216d7f['push'](_0x216d7f['shift']());}};_0x584445(++_0x40638b);}(a1026_0x4063,0x124));const a1026_0x5844=function(_0x216d7f,_0x40638b){_0x216d7f=_0x216d7f-0x0;let _0x584445=a1026_0x4063[_0x216d7f];return _0x584445;};const _0x4e107b=a1026_0x5844;'use strict';const util=require(_0x4e107b('0x12')),_=require('lodash'),EventEmitter=require(_0x4e107b('0x42'))[_0x4e107b('0x3b')],AGIReply=require('./reply'),AGIError=require(_0x4e107b('0x38'));function AGIChannel(_0x5f40d4){const _0x1c3248=_0x4e107b,_0x440516=this,_0xf4f77=new AGIReply();let _0x3cc4c6=![],_0x2be629={};EventEmitter['call'](_0x440516),_0x5f40d4['setEncoding'](_0x1c3248('0x24')),_0x5f40d4[_0x1c3248('0x11')](0x8*0x3c*0x3c*0x3e8),_0xf4f77['setEncoding'](_0x1c3248('0x24')),_0xf4f77['on']('headers',function(_0x35e654){const _0x48cda0=_0x1c3248;for(const _0x64d8d1 in _0x35e654){_0x440516[_0x64d8d1]=_0x35e654[_0x64d8d1];}_0x440516[_0x48cda0('0x23')]('ready');}),_0xf4f77['on'](_0x1c3248('0x2b'),function(_0x3886a7){const _0x31be31=_0x1c3248;if(_0x3886a7[_0x31be31('0x28')]()==_0x31be31('0x30')){_0x440516[_0x31be31('0x23')](_0x31be31('0x30'));return;}_0x3886a7[_0x31be31('0x32')](0x0,0xb)==_0x31be31('0xa')&&(_0x3cc4c6=!![]);_0x3cc4c6?(_0x2be629['rx']+=_0x3886a7+'\x0a',_0x3886a7[_0x31be31('0x1c')](_0x31be31('0x1e'))!=-0x1&&(_0x3cc4c6=![])):_0x2be629['rx']=_0x3886a7;if(_0x3cc4c6)return;if(typeof _0x2be629['cb']==_0x31be31('0x2')){let _0x4d8302=_0x2be629['rx'][_0x31be31('0x32')](0x0,0x3),_0x39e8fc=null,_0x516b28=null;_0x4d8302=parseInt(_0x4d8302);if(isNaN(_0x4d8302)){_0x2be629['cb'](null,{'code':0x1f4,'result':-0x1,'extra':'no\x20code'});return;}if(_0x4d8302!=0xc8){_0x2be629['cb'](null,{'code':_0x4d8302,'result':-0x1,'extra':'KO'});return;}_0x39e8fc=_0x2be629['rx'][_0x31be31('0x32')](0x4)[_0x31be31('0xc')](_0x31be31('0x45'),'');_0x39e8fc[_0x31be31('0xd')]('\x20')!=-0x1&&(_0x39e8fc=_0x39e8fc[_0x31be31('0x2a')](0x0,_0x39e8fc['indexOf']('\x20')));_[_0x31be31('0x22')](_0x39e8fc,'-1')&&(_0x39e8fc=parseInt(_0x39e8fc));_0x516b28=_0x2be629['rx'][_0x31be31('0x40')]('\x20');if(_0x516b28[_0x31be31('0xe')]==0x3)_0x516b28=_0x516b28[0x2][_0x31be31('0x32')](0x1,_0x516b28[0x2]['length']-0x1);else{if(_0x516b28[_0x31be31('0xe')]>0x3){const _0xa90ace=/\((.+)\)/,_0x36bab5=_0x2be629['rx'][_0x31be31('0x43')](_0xa90ace);_0x36bab5?_0x516b28=_0x36bab5[0x1]:_0x516b28=null;}else _0x516b28=null;}_0x2be629['cb'](null,{'code':_0x4d8302,'result':_0x39e8fc,'extra':_0x516b28});}}),_0x5f40d4['on'](_0x1c3248('0x29'),function(_0x25f05d){const _0x3f2c2a=_0x1c3248;_0x440516['emit'](_0x3f2c2a('0x29'),new AGIError(_0x3f2c2a('0x14'),_0x25f05d['code']));}),_0x5f40d4['on'](_0x1c3248('0x35'),function(){const _0x34996f=_0x1c3248;_0x440516['emit'](_0x34996f('0x35'),new AGIError('E_AGI_SOCKET_CLOSE'));}),_0x5f40d4['on'](_0x1c3248('0x0'),function(){const _0x572b82=_0x1c3248;_0x440516[_0x572b82('0x23')](_0x572b82('0x0'),new AGIError(_0x572b82('0x4'))),_0x5f40d4[_0x572b82('0x21')]();}),_0x5f40d4[_0x1c3248('0x19')](_0xf4f77),(this['command']=function(_0x2cdf30,_0x554688){const _0x5caf5d=_0x1c3248;_0x2cdf30=_0x2cdf30||'',_0x554688=typeof _0x554688==_0x5caf5d('0x2')?_0x554688:new Function(),_0x2be629={'tx':_0x2cdf30,'rx':'','cb':_0x554688},_0x5f40d4[_0x5caf5d('0x3c')](_0x2cdf30+'\x0a');},this[_0x1c3248('0x35')]=function(){const _0x509b5e=_0x1c3248;_0x5f40d4[_0x509b5e('0x21')]();});}util[_0x4e107b('0x33')](AGIChannel,EventEmitter),AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x15')]=function(_0x59c2f2){const _0x5ecfb=_0x4e107b;return this[_0x5ecfb('0x2e')][_0x5ecfb('0x9')](this,_0x59c2f2);},AGIChannel['prototype'][_0x4e107b('0x3e')]=function(){const _0x5b0b84=_0x4e107b;return this['sendRequest'](_0x5b0b84('0x7'));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x25')]=function(_0x3c6de9,_0x1ef514,_0x102c5b){const _0x4a930d=_0x4e107b;return _0x3c6de9=_0x3c6de9===undefined?_0x4a930d('0x2d'):_0x3c6de9,_0x1ef514=_0x1ef514===undefined?'5':_0x1ef514,_0x102c5b=_0x102c5b===undefined?'1':_0x102c5b,this[_0x4a930d('0x15')](util[_0x4a930d('0x27')](_0x4a930d('0x1f'),_0x3c6de9,_0x1ef514*0x3e8,_0x102c5b));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x3f')]=function(_0x54730b){const _0xdadd3a=_0x4e107b;return _0x54730b=_0x54730b||'NO\x20MESSAGE',this[_0xdadd3a('0x15')](util[_0xdadd3a('0x27')](_0xdadd3a('0x17'),_0x54730b));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x3d')]=function(_0x170ca9,_0x57f34c){const _0xc69702=_0x4e107b;if(_[_0xc69702('0x20')](_0x57f34c))return this[_0xc69702('0x15')](util[_0xc69702('0x27')](_0xc69702('0x2f'),_0x170ca9,_0x57f34c[_0xc69702('0x18')](',')));return this['sendRequest'](util[_0xc69702('0x27')]('EXEC\x20%s\x20%s',_0x170ca9,_0x57f34c));},AGIChannel[_0x4e107b('0x39')]['setContext']=function(_0x5b4057){const _0x4ae677=_0x4e107b;return this[_0x4ae677('0x15')](util[_0x4ae677('0x27')]('SET\x20CONTEXT\x20%s',_0x5b4057));},AGIChannel[_0x4e107b('0x39')]['setExtension']=function(_0xb0f61a){const _0x36a748=_0x4e107b;return this[_0x36a748('0x15')](util['format']('SET\x20EXTENSION\x20%s',_0xb0f61a));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x34')]=function(_0x4e070c){const _0x4eaa38=_0x4e107b;return this[_0x4eaa38('0x15')](util[_0x4eaa38('0x27')](_0x4eaa38('0x1a'),_0x4e070c));},AGIChannel[_0x4e107b('0x39')]['hangup']=function(){const _0x34891e=_0x4e107b;return this[_0x34891e('0x15')]('HANGUP');},AGIChannel['prototype'][_0x4e107b('0x46')]=function(_0x398373,_0x389c85){const _0x427378=_0x4e107b,_0x1b7b19=_[_0x427378('0x26')](_0x389c85)||_[_0x427378('0x3')](_0x389c85)?_0x389c85['toString']():_0x389c85;return this[_0x427378('0x15')](util[_0x427378('0x27')](_0x427378('0xf'),_0x398373,_0x1b7b19?_0x1b7b19[_0x427378('0x3a')]()['replace'](/(\r\n|\n|\r)/gm,'\x20'):''));},AGIChannel[_0x4e107b('0x39')]['sayNumber']=function(_0x42fff,_0x13daec){const _0x542eef=_0x4e107b;return this['sendRequest'](util[_0x542eef('0x27')](_0x542eef('0x36'),_0x42fff,_0x13daec));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x1d')]=function(_0x2dc97c,_0x41d06b){const _0x3c448b=_0x4e107b;return this[_0x3c448b('0x15')](util[_0x3c448b('0x27')](_0x3c448b('0x8'),_0x2dc97c,_0x41d06b));},AGIChannel[_0x4e107b('0x39')]['sayPhonetic']=function(_0x557885,_0x205f8a){const _0x2e843b=_0x4e107b;return this[_0x2e843b('0x15')](util[_0x2e843b('0x27')](_0x2e843b('0xb'),_0x557885,_0x205f8a));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x13')]=function(_0x57b88c,_0x50e808,_0x55ab53){const _0x216856=_0x4e107b;return _0x50e808=_0x50e808||this['extension'],_0x55ab53=_0x55ab53||0x1,this['setContext'](_0x57b88c),this[_0x216856('0x31')](_0x50e808),this[_0x216856('0x34')](_0x55ab53),this[_0x216856('0x3f')](util[_0x216856('0x27')]('GOTO\x20%s\x20%s\x20%s',_0x57b88c,_0x50e808,_0x55ab53));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x1b')]=function(_0x112a19){const _0x39536f=_0x4e107b;return this[_0x39536f('0x15')](util['format'](_0x39536f('0x37'),_0x112a19));},AGIChannel[_0x4e107b('0x39')][_0x4e107b('0x16')]=function(_0x238476,_0x509877,_0x477443,_0x25c5ef,_0x890676,_0x3a29ea){const _0x5b70b5=_0x4e107b;return _0x509877=_0x509877||_0x5b70b5('0x10'),_0x477443=_0x477443||'',_0x25c5ef=_0x25c5ef===undefined?-0x1:_0x25c5ef==='-1'?-0x1:_0x25c5ef*0x3e8,_0x890676=_0x890676===undefined?'':'s='+_0x890676,_0x3a29ea=_0x3a29ea?'BEEP':'',this['sendRequest'](util[_0x5b70b5('0x27')](_0x5b70b5('0x2c'),_0x238476,_0x509877,_0x477443,_0x25c5ef,_0x3a29ea,_0x890676));},AGIChannel[_0x4e107b('0x39')]['streamFile']=function(_0x6e5db4,_0x1aaefd){const _0x3b3064=_0x4e107b;return _0x1aaefd=_0x1aaefd||'',this[_0x3b3064('0x15')](util[_0x3b3064('0x27')]('STREAM\x20FILE\x20\x22%s\x22\x20\x22%s\x22',_0x6e5db4,_0x1aaefd));},AGIChannel[_0x4e107b('0x39')]['agi']=function(_0x240d99){const _0x56316d=_0x4e107b;return this[_0x56316d('0x3d')](_0x56316d('0x6'),_0x240d99);},AGIChannel['prototype'][_0x4e107b('0x5')]=function(_0x7fc2f3){const _0x5adba8=_0x4e107b;return this['exec'](_0x5adba8('0x41'),_0x7fc2f3);},AGIChannel['prototype'][_0x4e107b('0x29')]=function(_0x3f2155,_0x4afc22){const _0x444bab=_0x4e107b;return this['noop'](util[_0x444bab('0x27')](_0x444bab('0x44'),_0x3f2155['id'],_0x3f2155[_0x444bab('0x1')],_0x4afc22)),{'code':0x1f4,'result':'-1','extra':''};},module['exports']=AGIChannel;
\ No newline at end of file