ddfa1fc6ad0b0c2eba6897982dee729c9671f83a
[motion2.git] / server / services / agi / vertices.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0xe4c6=['shellCommand','exec','trim','replace','googleCloudTTS','google_cloud_tts_text_type','text','en-US','ssmlGender','audioEncoding','googleTTS','google_tts_language','restAPI','method','timeout','includes','POST','PUT','toUpperCase','body','An\x20incorrect\x20formatted\x20json\x20body\x20has\x20been\x20passed\x20to\x20the\x20function','parse','An\x20incorrect\x20formatted\x20json\x20headers\x20has\x20been\x20passed\x20to\x20the\x20function','computedVariables','sync','uri','render','headers','stringify','statusMessage','statusCode','message','500\x20-\x20Internal\x20Server\x20Error','googleDialogflow','key','sestekNDA','ispeechTTS','ispeech_tts_language','speed','ispeechASR','ispeech_asr_language','model','awsPolly','aws_access_key_id','aws_polly_region','Amy','aws_text_type','awsLex','aws_secret_access_key','aws_lex_region','googleASR','google_asr_language','tildeASR','appid','clear','clone','hasOwnProperty','isString','replaceAllVariables','recursiveNodeIndex','isPlainObject','isArray','length','saveRestApiResult','%s.%s','setVariable','replaceObjectAllVariables','split','getAndSetVariable','result','extra','maxRetry','createSquareDetailsReport','Enter\x20in\x20AGI\x20(%s)\x20block','isConfigured','wait','answer','no\x20list\x20selected','delay','add','minutes','noop','custom_app','Enter\x20in\x20CUSTOM\x20APP\x20(%s)\x20block','application','Executed\x20command\x20%s\x20%s','options','lumenvoxtts','Enter\x20in\x20LUMENVOXTTS\x20(%s)\x20block','MRCPSynth','Executed\x20command\x20MRCPSynth\x20%s','sestektts','Enter\x20in\x20SESTEKTTS\x20(%s)\x20block','no\x20text\x20configured','lumenvoxasr','grammar','RECOG_INPUT()','LUMENVOX_ASR_TRANSCRIPT','RECOG_INSTANCE()','LUMENVOX_ASR_INSTANCE','Executed\x20command\x20MRCPRecog\x20%s','sestekasr','Enter\x20in\x20SESTEKASR\x20(%s)\x20block','no\x20grammar\x20configured','MRCPRecog','RECOG_CONFIDENCE()','SESTEK_ASR_CONFIDENCE','SESTEK_ASR_TRANSCRIPT','SESTEK_ASR_INSTANCE','Enter\x20in\x20DATABASE\x20(%s)\x20block','no\x20database\x20selected','no\x20query\x20configured','query:\x20%s','variable_id','no\x20variable\x20selected\x20for\x20the\x20result','no\x20variable\x20found','keys','forEach','%s[%s][%s]','variable\x20%s\x20set','dial','Enter\x20in\x20DIAL\x20(%s)\x20block','sip_id','no\x20user\x20found','DIAL','SIP/%s','opts','url','Executed\x20command\x20%s','Enter\x20in\x20DIALOGFLOW\x20(%s)\x20block','no\x20key\x20configured','Trying\x20Dialogflow:\x20%s','DIALOGFLOW_%s','speech','out','Dialogflow\x20Result\x20%s','Dialogflow\x20is\x20unreachable','Enter\x20in\x20SESTEKNDA\x20(%s)\x20block','ndauth_url','no\x20ndauth\x20url\x20configured','no\x20username\x20configured','password','no\x20password\x20configured','bot','audiofile','Sestek\x20NDA\x20%s\x20file\x20created','streamFile','unlink','SestekNDA\x20Result\x20%s','SestekNDA\x20is\x20unreachable','Enter\x20in\x20END\x20(%s)\x20block','ext_dial','Enter\x20in\x20EXTERNAL\x20DIAL\x20(%s)\x20block','trunk_id','no\x20trunk\x20selected','getTrunk','no\x20trunk\x20found','trunk_name','SIP/%s/%s','finally','Enter\x20in\x20FINALLY\x20(%s)\x20block','Enter\x20in\x20GETDIGITS\x20(%s)\x20block','retry','file_id','no\x20file\x20audio\x20selected','no\x20file\x20audio\x20found','getData','response','test','mindigit','maxdigit','hiddendigitsnum','generate','substr','Enter\x20in\x20GETSECRETDIGITS\x20(%s)\x20block','goal','GOAL\x20%s','goalname','[AGI]\x20Enter\x20in\x20AWSPOLLY\x20(%s)\x20block','aws\x20Polly\x20%s\x20file\x20created','awslex','Enter\x20in\x20Amazon\x20Lex\x20(%s)\x20block','no\x20valid\x20credentials\x20configured','aws_bot_name','no\x20bot\x20name\x20configured','Amazon\x20Lex\x20ready\x20for\x20fulfillment','Amazon\x20Lex\x20Result\x20%s','googleasr','Enter\x20in\x20GOOGLEASR\x20(%s)\x20block\x20%s','%s/recordings/%s','beep','NOBEEP','recordFile','intKey','google\x20%s\x20file\x20created','GoogleASR\x20Result\x20%s','Enter\x20in\x20TILDEASR\x20(%s)\x20block','appsecret','no\x20appsecret\x20configured','wav','tilde\x20%s\x20file\x20created','TILDE_ASR_%s','TildeASR\x20Result\x20%s','gotoc','continueAt','gotoif','Enter\x20in\x20GOTOIF\x20(%s)\x20block','condition','false','EVAL\x20CONDITION\x20%s\x20%s','Enter\x20in\x20GOTOIFTIME\x20(%s)\x20block','interval_id','no\x20interval\x20configured','no\x20intervals\x20found','IFTIME(%s?true:false)','IFTIME\x20%s\x20%s','true','hangup','Enter\x20in\x20HANGUP\x20(%s)\x20block','ispeechasr','Enter\x20in\x20ISPEECHASR\x20(%s)\x20block','ispeech\x20%s\x20file\x20created','ISPEECH_ASR_%s','IspeechASR\x20Result\x20%s','ispeechtts','Enter\x20in\x20ISPEECHTTS\x20(%s)\x20block','.wav','login','Enter\x20in\x20LOGIN\x20(%s)\x20block','findBy','AGENT\x20%s\x20FOUND\x20BY','success','AGENT\x20%s\x20NOT\x20FOUND\x20BY','logout','no\x20find\x20by\x20configured','FIND\x20AGENT\x20%s\x20BY\x20%s','math','Enter\x20in\x20MATH\x20(%s)\x20block','no\x20operation\x20configured','math\x20%s','operation','%s[%s]','variable\x20%s[key]\x20set','output','pause','pause_id','failure','playback','Enter\x20in\x20PLAYBACK\x20(%s)\x20block','PLAYBACK','queue','Enter\x20in\x20QUEUE\x20(%s)\x20block','queue_id','no\x20queue\x20selected','getVoiceQueue','indexOf','XMCS-QUEUE','toLowerCase','gosub','QUEUE','record','Enter\x20in\x20RECORD\x20(%s)\x20block','recordingFormat','%s_%s','RECORDING_SAVENAME','escape_digits','restapi','Enter\x20in\x20RESTAPI\x20(%s)\x20block','no\x20url\x20configured','Response:','no\x20variable\x20selected\x20for\x20the\x20response','%s_STATUS_CODE','200','%s_STATUS_MESSAGE','Unable\x20to\x20set\x20result\x20in\x20variable\x20%s','saydigits','Enter\x20in\x20SAYDIGITS\x20(%s)\x20block','sayDigits','digits','saynumber','sayphonetic','Enter\x20in\x20SAYPHONETIC\x20(%s)\x20block','sayPhonetic','Enter\x20in\x20SENDMAIL\x20(%s)\x20block','account_id','no\x20mail\x20account\x20configured','Smtp','\x22%s\x22\x20<%s>','email','user','bcc','subject','service','host','port','secure','authentication','auth','debug','sendMail\x20message','Trying\x20SendMail\x20with\x20account\x20%s','Mail\x20message\x20added\x20to\x20outgoing\x20process','Enter\x20in\x20SENDFAX\x20(%s)\x20block','SENDFAX\x20block\x20not\x20implemented','sendSMS','Enter\x20in\x20SENDSMS\x20(%s)\x20block','sms_account_id','no\x20sms\x20account\x20configured','no\x20sms\x20account\x20found','sms_text','sendSMS\x20message','createSmsMessage','set','no\x20variable\x20selected','variable_value','START\x20CALLY\x20SQUARE','Answer','subproject','project_id','no\x20subproject\x20selected','no\x20subproject\x20found\x20with\x20id\x20%d','project\x20in\x20subproject\x20must\x20be\x20different\x20from\x20the\x20called\x20project','AGI','agi://%s/square,\x22%s\x22,\x22%s\x22','system','Enter\x20in\x20SYSTEM\x20(%s)\x20block','command','sh\x20command:\x20%s\x20result\x20on\x20variable:\x20%s','sh\x20command:\x20%s\x20result\x20no\x20stored','Enter\x20in\x20Google\x20Cloud\x20TTS\x20(%s)\x20block','apiKey','no\x20apiKey\x20configured','Trying\x20Google\x20Cloud\x20TTS\x20%s','Google\x20Cloud\x20TTS\x20is\x20unreachable','tts','Trying\x20Google\x20TTS\x20%s','Google\x20TTS\x20%s\x20file\x20created','Google\x20TTS\x20is\x20unreachable','unpause','Enter\x20in\x20UNPAUSE\x20(%s)\x20block','voicemail','Enter\x20in\x20VOICEMAIL\x20(%s)\x20block','VOICEMAIL','mailbox','vswitch','replaceAll','path','util','lodash','shelljs','odbc','randomstring','moment','../../config/logger','agi','../../config/environment','./scripts','rawHeaders','rawBody','menu','getdigits','getsecretdigits','rpc','getVariable','getVariableById','then','name','catch','prototype','getVoiceQueueById','getSquareProject','getSquareProjectById','getSquareOdbc','getSquareOdbcById','getUser','getUserById','getSound','getSoundById','getSoundPath','save_name','getMailAccount','getMailAccountById','sendMailMessage','getIntervals','getIntervalById','IntervalId','map','Intervals','interval','%s/sounds/converted/%s','open','error','info','ODBC\x20connection\x20successfully','query','Query\x20executed\x20correctly\x20%s','close','Error\x20closing\x20connection\x20to\x20odbc\x20%s','getSmsAccountById','channel','label','agicommand','createSquareRecording','uniqueid','callerid','calleridname','context','extension','priority','accountcode','arg_1','file','createSquareMessage','createCmContact','isEmpty','isNil','callback_','random','lastName','phone','list_id','callback','scheduledAt','toString','callback_priority','getPause','getPauseById','agent','agentPause','agentUnpause','agentLogout','agentLogin','internal','format','%s/%s@from-sip/n'];(function(_0x24cf1b,_0x341be8){var _0x3398f9=function(_0x23d957){while(--_0x23d957){_0x24cf1b['push'](_0x24cf1b['shift']());}};_0x3398f9(++_0x341be8);}(_0xe4c6,0x15a));var _0x6e4c=function(_0x4960b4,_0xc44bf5){_0x4960b4=_0x4960b4-0x0;var _0x1b9779=_0xe4c6[_0x4960b4];return _0x1b9779;};'use strict';var fs=require('fs');var path=require(_0x6e4c('0x0'));var util=require(_0x6e4c('0x1'));var _=require(_0x6e4c('0x2'));var sh=require(_0x6e4c('0x3'));var odbc=require(_0x6e4c('0x4'))();var rs=require(_0x6e4c('0x5'));var moment=require(_0x6e4c('0x6'));var Mustache=require('mustache');var rp=require('request-promise');var logger=require(_0x6e4c('0x7'))(_0x6e4c('0x8'));var config=require(_0x6e4c('0x9'));var scripts=require(_0x6e4c('0xa'));var FILES_PATH='/var/opt/motion2/server/files';var recursiveMapAttributes=[_0x6e4c('0xb'),_0x6e4c('0xc')];var verticesWithRetry=[_0x6e4c('0xd'),_0x6e4c('0xe'),_0x6e4c('0xf')];var AGIVertices=function(_0x2ab43f,_0x4ece25,_0x3ead50){this['channel']=_0x2ab43f;this[_0x6e4c('0x10')]=_0x4ece25;this['mailRpc']=_0x3ead50;};AGIVertices['prototype'][_0x6e4c('0x11')]=function(_0x17ff93,_0x14df0b){this[_0x6e4c('0x10')][_0x6e4c('0x12')](_0x17ff93)[_0x6e4c('0x13')](function(_0x1c39b8){_0x14df0b(null,_0x1c39b8?_0x1c39b8[_0x6e4c('0x14')]:![]);})[_0x6e4c('0x15')](function(_0x5c741b){_0x14df0b(_0x5c741b);});};AGIVertices[_0x6e4c('0x16')]['getVoiceQueue']=function(_0x3b5a9d,_0x265577){this[_0x6e4c('0x10')][_0x6e4c('0x17')](_0x3b5a9d)[_0x6e4c('0x13')](function(_0x425109){_0x265577(null,_0x425109?_0x425109[_0x6e4c('0x14')]:![]);})[_0x6e4c('0x15')](function(_0x439ff){_0x265577(_0x439ff);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x18')]=function(_0x549189,_0x5bd7d6){this[_0x6e4c('0x10')][_0x6e4c('0x19')](_0x549189)[_0x6e4c('0x13')](function(_0x315bbe){_0x5bd7d6(null,_0x315bbe?_0x315bbe[_0x6e4c('0x14')]:![]);})[_0x6e4c('0x15')](function(_0x238887){_0x5bd7d6(_0x238887);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x1a')]=function(_0x1d69ff,_0x3f52e5){this[_0x6e4c('0x10')][_0x6e4c('0x1b')](_0x1d69ff)[_0x6e4c('0x13')](function(_0xc68988){_0x3f52e5(null,_0xc68988?_0xc68988['dsn']:![]);})[_0x6e4c('0x15')](function(_0xd63df0){_0x3f52e5(_0xd63df0);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x1c')]=function(_0x48a16c,_0xdd3d77){this[_0x6e4c('0x10')][_0x6e4c('0x1d')](_0x48a16c)[_0x6e4c('0x13')](function(_0x4f83b8){_0xdd3d77(null,_0x4f83b8?_0x4f83b8[_0x6e4c('0x14')]:![]);})['catch'](function(_0x46e026){_0xdd3d77(_0x46e026);});};AGIVertices[_0x6e4c('0x16')]['getTrunk']=function(_0x239320,_0x514d2a){this[_0x6e4c('0x10')]['getTrunkById'](_0x239320)['then'](function(_0x2bc3c9){_0x514d2a(null,_0x2bc3c9?_0x2bc3c9['name']:![]);})[_0x6e4c('0x15')](function(_0x4ce1d1){_0x514d2a(_0x4ce1d1);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x1e')]=function(_0x211107,_0x95efaf){var _0x266f3a=this;this[_0x6e4c('0x10')][_0x6e4c('0x1f')](_0x211107)[_0x6e4c('0x13')](function(_0x35f7a0){_0x95efaf(null,_0x35f7a0?_0x266f3a[_0x6e4c('0x20')](_0x35f7a0[_0x6e4c('0x21')]):![]);})[_0x6e4c('0x15')](function(_0x38547c){_0x95efaf(_0x38547c);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x22')]=function(_0x1a00fd,_0x761d5c){this[_0x6e4c('0x10')][_0x6e4c('0x23')](_0x1a00fd)['then'](function(_0x3d0a74){_0x761d5c(null,_0x3d0a74?_0x3d0a74:![]);})[_0x6e4c('0x15')](function(_0x13aaa7){_0x761d5c(_0x13aaa7);});};AGIVertices['prototype'][_0x6e4c('0x24')]=function(_0x5953e2,_0x16e3f6,_0x5807e8){this['mailRpc'][_0x6e4c('0x24')](_0x5953e2,_0x16e3f6)[_0x6e4c('0x13')](function(){_0x5807e8(null);})[_0x6e4c('0x15')](function(_0x4a4373){_0x5807e8(_0x4a4373);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x25')]=function(_0x5ec94f,_0x3bd3a6){this[_0x6e4c('0x10')][_0x6e4c('0x26')](_0x5ec94f)[_0x6e4c('0x13')](function(_0x53ccb1){if(_0x53ccb1){if(_0x53ccb1[_0x6e4c('0x27')]){_0x3bd3a6(null,[_0x53ccb1['interval']]);}else{_0x3bd3a6(null,_[_0x6e4c('0x28')](_0x53ccb1[_0x6e4c('0x29')],_0x6e4c('0x2a')));}}else{_0x3bd3a6(null,![]);}})[_0x6e4c('0x15')](function(_0x5996ca){_0x3bd3a6(_0x5996ca);});};AGIVertices['prototype']['getSoundPath']=function(_0x24aa9e){return util['format'](_0x6e4c('0x2b'),FILES_PATH,_0x24aa9e);};AGIVertices[_0x6e4c('0x16')]['getQueryOdbc']=function(_0x5eb0cd,_0x8ab1ad,_0x4917fe){odbc[_0x6e4c('0x2c')](_0x5eb0cd,function(_0x58a03c){if(_0x58a03c){logger[_0x6e4c('0x2d')]('Error\x20getting\x20ODBC\x20connection\x20%s',_0x58a03c);_0x4917fe(_0x58a03c);}else{logger[_0x6e4c('0x2e')](_0x6e4c('0x2f'));odbc[_0x6e4c('0x30')](_0x8ab1ad,function(_0x32d03d,_0x49b1be){if(_0x32d03d){logger['info']('Error\x20executing\x20query\x20%s',_0x8ab1ad);_0x4917fe(_0x32d03d);}else{logger['info'](_0x6e4c('0x31'),_0x8ab1ad);odbc[_0x6e4c('0x32')](function(_0x265bda){if(_0x265bda){logger['error'](_0x6e4c('0x33'),_0x265bda);}_0x4917fe(null,_0x49b1be);});}});}});};AGIVertices['prototype']['getSmsAccount']=function(_0x46981a,_0x5ac359){this[_0x6e4c('0x10')][_0x6e4c('0x34')](_0x46981a)['then'](function(_0x5ca2ee){_0x5ac359(null,_0x5ca2ee?_0x5ca2ee:![]);})['catch'](function(_0x3af649){_0x5ac359(_0x3af649);});};AGIVertices[_0x6e4c('0x16')]['createSmsMessage']=function(_0x4e8e07,_0x426d84){this[_0x6e4c('0x10')]['createSmsMessage'](_0x4e8e07)[_0x6e4c('0x13')](function(_0x4866ca){_0x426d84(null,_0x4866ca);})[_0x6e4c('0x15')](function(_0x304e45){_0x426d84(_0x304e45);});};AGIVertices[_0x6e4c('0x16')]['createSquareDetailsReport']=function(_0x840cbe,_0x28cc8c,_0x5dd922){this[_0x6e4c('0x10')]['createSquareDetailsReport']({'uniqueid':this[_0x6e4c('0x35')]['uniqueid'],'node':_0x840cbe[_0x6e4c('0x36')],'application':_0x840cbe[_0x6e4c('0x37')],'data':_0x28cc8c||null,'project_name':this[_0x6e4c('0x35')]['arg_1'],'callerid':this[_0x6e4c('0x35')]['callerid']})['then'](function(_0x332ad3){if(_0x5dd922){_0x5dd922(null,_0x332ad3);}})['catch'](function(_0x599ef2){if(_0x5dd922){_0x5dd922(_0x599ef2);}});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x38')]=function(_0x655d78,_0x1203e4,_0x1dcdfb,_0x142a7e){this[_0x6e4c('0x10')][_0x6e4c('0x38')]({'uniqueid':this[_0x6e4c('0x35')][_0x6e4c('0x39')],'callerid':this[_0x6e4c('0x35')][_0x6e4c('0x3a')],'calleridname':this[_0x6e4c('0x35')][_0x6e4c('0x3b')],'context':this[_0x6e4c('0x35')][_0x6e4c('0x3c')],'extension':this[_0x6e4c('0x35')][_0x6e4c('0x3d')],'priority':this['channel'][_0x6e4c('0x3e')],'accountcode':this[_0x6e4c('0x35')][_0x6e4c('0x3f')],'dnid':this[_0x6e4c('0x35')]['dnid'],'projectName':this['channel'][_0x6e4c('0x40')],'saveName':_0x1203e4,'filename':_0x655d78[_0x6e4c('0x41')]||_0x1203e4,'savePath':_0x1dcdfb})['then'](function(_0x21f1d0){_0x142a7e(null,_0x21f1d0);})[_0x6e4c('0x15')](function(_0x45bd58){_0x142a7e(_0x45bd58);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x42')]=function(_0x1a3f90,_0x37c9bc,_0x398fb3){this[_0x6e4c('0x10')][_0x6e4c('0x42')]({'uniqueid':this[_0x6e4c('0x35')][_0x6e4c('0x39')],'body':_0x1a3f90,'direction':_0x37c9bc})[_0x6e4c('0x13')](function(_0x1be206){if(_0x398fb3){_0x398fb3(null,_0x1be206);}})[_0x6e4c('0x15')](function(_0x5151d2){if(_0x398fb3){_0x398fb3(_0x5151d2);}});};AGIVertices['prototype']['createCmContact']=function(_0x846782,_0x302cff){this[_0x6e4c('0x10')][_0x6e4c('0x43')]({'firstName':_[_0x6e4c('0x44')](_0x846782['name'])||_[_0x6e4c('0x45')](_0x846782[_0x6e4c('0x14')])?_0x6e4c('0x46')+Math[_0x6e4c('0x47')]():_0x846782[_0x6e4c('0x14')],'lastName':_[_0x6e4c('0x44')](_0x846782['lastName'])||_[_0x6e4c('0x45')](_0x846782[_0x6e4c('0x48')])?null:_0x846782['lastName'],'phone':_0x846782[_0x6e4c('0x49')],'ListId':_0x846782[_0x6e4c('0x4a')],'scheduledat':_0x846782['scheduledAt'],'callbackUniqueid':this[_0x6e4c('0x35')][_0x6e4c('0x39')],'tags':_0x6e4c('0x4b'),'description':'Callback\x20scheduled\x20at\x20'+_0x846782[_0x6e4c('0x4c')][_0x6e4c('0x4d')](),'priority':_0x846782[_0x6e4c('0x4e')]})[_0x6e4c('0x13')](function(_0x37e60c){_0x302cff(null,_0x37e60c);})[_0x6e4c('0x15')](function(_0x439ebf){_0x302cff(_0x439ebf);});};AGIVertices['prototype'][_0x6e4c('0x4f')]=function(_0x75c570,_0x59dc33){this[_0x6e4c('0x10')][_0x6e4c('0x50')](_0x75c570)[_0x6e4c('0x13')](function(_0x3e73ae){_0x59dc33(null,_0x3e73ae?_0x3e73ae[_0x6e4c('0x14')]:![]);})[_0x6e4c('0x15')](function(_0x4c5fc3){_0x59dc33(_0x4c5fc3);});};AGIVertices[_0x6e4c('0x16')]['agentPause']=function(_0x66ac3b,_0x288e59,_0x146530){var _0x526107={'role':_0x6e4c('0x51')};_0x526107[_0x66ac3b]=this[_0x6e4c('0x35')][_0x6e4c('0x3a')];this[_0x6e4c('0x10')][_0x6e4c('0x52')](_0x526107,_0x288e59,this['channel'][_0x6e4c('0x39')])['then'](function(_0x422162){_0x146530(null,_[_0x6e4c('0x45')](_0x422162)?![]:!![]);})[_0x6e4c('0x15')](function(_0x103099){logger[_0x6e4c('0x2d')](_0x103099);_0x146530(null,![]);});};AGIVertices['prototype']['agentUnpause']=function(_0x1e8a1b,_0x30667f){var _0x4282a1={'role':'agent'};_0x4282a1[_0x1e8a1b]=this[_0x6e4c('0x35')][_0x6e4c('0x3a')];this['rpc'][_0x6e4c('0x53')](_0x4282a1)[_0x6e4c('0x13')](function(_0x443655){_0x30667f(null,_[_0x6e4c('0x45')](_0x443655)?![]:!![]);})[_0x6e4c('0x15')](function(_0x33fa6e){logger['error'](_0x33fa6e);_0x30667f(null,![]);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x54')]=function(_0x1cbe02,_0x2ddc88){var _0x2f9f53={'role':_0x6e4c('0x51')};_0x2f9f53[_0x1cbe02]=this[_0x6e4c('0x35')][_0x6e4c('0x3a')];this[_0x6e4c('0x10')][_0x6e4c('0x54')](_0x2f9f53)[_0x6e4c('0x13')](function(_0x14587f){_0x2ddc88(null,_['isNil'](_0x14587f)?![]:!![]);})[_0x6e4c('0x15')](function(_0x4618af){logger[_0x6e4c('0x2d')](_0x4618af);_0x2ddc88(null,![]);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x55')]=function(_0x321497,_0x34af32){var _0x5df0b8={'role':_0x6e4c('0x51')};_0x5df0b8[_0x321497]=this[_0x6e4c('0x35')]['callerid'];var _0x596e62=_0x321497!=_0x6e4c('0x56')?util[_0x6e4c('0x57')](_0x6e4c('0x58'),'LOCAL',this[_0x6e4c('0x35')][_0x6e4c('0x3a')]):undefined;this['rpc']['agentLogin'](_0x5df0b8,_0x596e62)[_0x6e4c('0x13')](function(_0x1a6994){_0x34af32(null,_[_0x6e4c('0x45')](_0x1a6994)?![]:!![]);})[_0x6e4c('0x15')](function(_0x3ec44a){logger[_0x6e4c('0x2d')](_0x3ec44a);_0x34af32(null,![]);});};AGIVertices['prototype'][_0x6e4c('0x59')]=function(_0x1ebd17,_0x5e8753){sh[_0x6e4c('0x5a')](_[_0x6e4c('0x5b')](_0x1ebd17),function(_0x5721dc,_0x34c6b4){var _0x566178=_0x34c6b4[_0x6e4c('0x5c')](/(\r\n|\n|\r)/gm,'');_0x5e8753(null,_0x566178);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x5d')]=function(_0x255df9,_0x51e62e){scripts[_0x6e4c('0x5d')](_0x255df9['apiKey'],_0x255df9[_0x6e4c('0x5e')]||_0x6e4c('0x5f'),_0x255df9[_0x6e4c('0x5f')],_0x255df9['languageCode']||_0x6e4c('0x60'),_0x255df9[_0x6e4c('0x61')]||'MALE',_0x255df9[_0x6e4c('0x62')]||'MP3')[_0x6e4c('0x13')](function(_0x1b96a2){_0x51e62e(null,_0x1b96a2);})[_0x6e4c('0x15')](function(_0x590c98){_0x51e62e(_0x590c98);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x63')]=function(_0x3d33e3,_0x440879){scripts[_0x6e4c('0x63')](_0x3d33e3[_0x6e4c('0x5f')],_0x3d33e3[_0x6e4c('0x64')]||'en',0x1)[_0x6e4c('0x13')](function(_0x239d34){_0x440879(null,_0x239d34);})['catch'](function(_0x59ee94){_0x440879(_0x59ee94);});};AGIVertices['prototype'][_0x6e4c('0x65')]=function(_0x1a3a89,_0x30ca00){var _0x163845={'uri':_0x1a3a89['url'],'method':_0x1a3a89[_0x6e4c('0x66')],'json':!![],'resolveWithFullResponse':!![],'timeout':typeof parseInt(_0x1a3a89[_0x6e4c('0x67')])==='number'&&parseInt(_0x1a3a89[_0x6e4c('0x67')])>=0x1?parseInt(_0x1a3a89['timeout'])*0x3e8:0x5*0x3e8};if(_[_0x6e4c('0x68')]([_0x6e4c('0x69'),_0x6e4c('0x6a')],_0x163845[_0x6e4c('0x66')][_0x6e4c('0x6b')]())){try{_0x163845[_0x6e4c('0x6c')]=_0x1a3a89['rawBody']?JSON['parse'](_0x1a3a89[_0x6e4c('0xc')]):{};}catch(_0x351a89){logger['error'](_0x6e4c('0x6d'),_0x351a89);}}try{_0x163845['headers']=_0x1a3a89[_0x6e4c('0xb')]?JSON[_0x6e4c('0x6e')](_0x1a3a89['rawHeaders']):{};}catch(_0x15ae9f){logger[_0x6e4c('0x2d')](_0x6e4c('0x6f'),_0x15ae9f);}if(_0x1a3a89[_0x6e4c('0x70')]){try{var _0x3786ff=require(_0x1a3a89['computedVariables'])[_0x6e4c('0x71')](this,_0x163845);_0x163845[_0x6e4c('0x72')]=Mustache[_0x6e4c('0x73')](_0x1a3a89['url'],_0x3786ff,{},['$$','$$']);if(_0x163845[_0x6e4c('0x74')]){_0x163845[_0x6e4c('0x74')]=JSON[_0x6e4c('0x6e')](Mustache[_0x6e4c('0x73')](JSON[_0x6e4c('0x75')](_0x163845[_0x6e4c('0x74')]),_0x3786ff,{},['$$','$$']));}if(_0x163845[_0x6e4c('0x6c')]){_0x163845[_0x6e4c('0x6c')]=JSON['parse'](Mustache[_0x6e4c('0x73')](JSON[_0x6e4c('0x75')](_0x163845[_0x6e4c('0x6c')]),_0x3786ff,{},['$$','$$']));}}catch(_0x431b72){logger[_0x6e4c('0x2d')]('An\x20incorrect\x20formatted\x20json\x20has\x20been\x20passed\x20to\x20the\x20function',_0x431b72);}}rp(_0x163845)['then'](function(_0x4ba614){var _0x278cc5={'statusCode':_0x4ba614['statusCode']||0xc8,'statusMessage':_0x4ba614[_0x6e4c('0x76')]||'OK','headers':_0x4ba614[_0x6e4c('0x74')]||{},'body':_0x4ba614[_0x6e4c('0x6c')]||{}};_0x30ca00(null,_0x278cc5);})['catch'](function(_0x538497){var _0x5d76d6={'statusCode':_0x538497[_0x6e4c('0x77')]||0x1f4,'statusMessage':_0x538497[_0x6e4c('0x78')]||_0x6e4c('0x79'),'headers':_0x538497['options'][_0x6e4c('0x74')]||{},'body':_0x538497['options'][_0x6e4c('0x6c')]||{}};_0x30ca00(null,_0x5d76d6);});};AGIVertices[_0x6e4c('0x16')]['googleDialogflow']=function(_0x953e1,_0x440167){scripts[_0x6e4c('0x7a')](this[_0x6e4c('0x35')][_0x6e4c('0x39')],_0x953e1[_0x6e4c('0x7b')],_0x953e1[_0x6e4c('0x5f')],_0x953e1['dialogflow_language']||'en')[_0x6e4c('0x13')](function(_0x3e991b){_0x440167(null,_0x3e991b);})['catch'](function(_0x1c5fb6){_0x440167(_0x1c5fb6);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x7c')]=function(_0x364f44,_0x24c4ca){scripts['sestekNDA'](this[_0x6e4c('0x35')],_0x364f44)[_0x6e4c('0x13')](function(_0x1a2967){_0x24c4ca(null,_0x1a2967);})[_0x6e4c('0x15')](function(_0x51609d){_0x24c4ca(_0x51609d);});};AGIVertices[_0x6e4c('0x16')]['ispeechTTS']=function(_0x4fc259,_0x54183f){scripts[_0x6e4c('0x7d')](_0x4fc259['key'],_0x4fc259[_0x6e4c('0x5f')],_0x4fc259[_0x6e4c('0x7e')]||_0x6e4c('0x60'),_0x4fc259[_0x6e4c('0x7f')])['then'](function(_0x2f41ad){_0x54183f(null,_0x2f41ad);})[_0x6e4c('0x15')](function(_0x4e7ae1){_0x54183f(_0x4e7ae1);});};AGIVertices['prototype'][_0x6e4c('0x80')]=function(_0x59857f,_0xdf71f9,_0x2ffe76){scripts[_0x6e4c('0x80')](_0xdf71f9,_0x59857f['key'],_0x59857f[_0x6e4c('0x81')]||_0x6e4c('0x60'),this['isConfigured'](_0x59857f['model'])?_0x59857f[_0x6e4c('0x82')]:undefined)['then'](function(_0x52d8bf){_0x2ffe76(null,_0x52d8bf);})[_0x6e4c('0x15')](function(_0x1b5cdb){_0x2ffe76(_0x1b5cdb);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x83')]=function(_0x229211,_0x113333){scripts[_0x6e4c('0x83')](_0x229211[_0x6e4c('0x84')],_0x229211['aws_secret_access_key'],_0x229211[_0x6e4c('0x85')],_0x229211['aws_polly_voice']||_0x6e4c('0x86'),_0x229211[_0x6e4c('0x5f')],_0x229211[_0x6e4c('0x87')]||_0x6e4c('0x5f'))[_0x6e4c('0x13')](function(_0x137456){_0x113333(null,_0x137456);})[_0x6e4c('0x15')](function(_0x472e25){_0x113333(_0x472e25);});};AGIVertices['prototype'][_0x6e4c('0x88')]=function(_0x3ed97f,_0x56a719){scripts[_0x6e4c('0x88')](this[_0x6e4c('0x35')][_0x6e4c('0x39')],_0x3ed97f[_0x6e4c('0x84')],_0x3ed97f[_0x6e4c('0x89')],_0x3ed97f[_0x6e4c('0x8a')],_0x3ed97f[_0x6e4c('0x5f')],_0x3ed97f['aws_bot_name'])[_0x6e4c('0x13')](function(_0x5d0c31){_0x56a719(null,_0x5d0c31);})[_0x6e4c('0x15')](function(_0x3fe212){_0x56a719(_0x3fe212);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x8b')]=function(_0x272a73,_0x8c5fc2,_0xd401b4){scripts[_0x6e4c('0x8b')](_0x8c5fc2,_0x272a73[_0x6e4c('0x7b')],_0x272a73[_0x6e4c('0x8c')]||_0x6e4c('0x60'))[_0x6e4c('0x13')](function(_0x7dcb85){_0xd401b4(null,_0x7dcb85);})['catch'](function(_0x4ff0ae){_0xd401b4(_0x4ff0ae);});};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x8d')]=function(_0x28214f,_0x2fdcbc,_0x25dfea){scripts[_0x6e4c('0x8d')](_0x2fdcbc,_0x28214f[_0x6e4c('0x8e')],_0x28214f['appsecret'],_0x28214f[_0x6e4c('0x72')])['then'](function(_0xf676d2){_0x25dfea(null,_0xf676d2);})[_0x6e4c('0x15')](function(_0x34e19e){_0x25dfea(_0x34e19e);});};AGIVertices['prototype'][_0x6e4c('0x8f')]=function(_0x482f99){var _0x3e34fb=_[_0x6e4c('0x68')](verticesWithRetry,_0x482f99[_0x6e4c('0x37')])?_0x482f99:_[_0x6e4c('0x90')](_0x482f99);for(var _0x22c52b in _0x3e34fb){if(_0x3e34fb[_0x6e4c('0x91')](_0x22c52b)){if(_0x3e34fb[_0x22c52b]&&_[_0x6e4c('0x92')](_0x3e34fb[_0x22c52b])){if(_['includes'](recursiveMapAttributes,_0x22c52b)){_0x3e34fb[_0x22c52b]=this['replaceObjectAllVariables'](_0x3e34fb[_0x22c52b]);}else{_0x3e34fb[_0x22c52b]=this[_0x6e4c('0x93')](_0x3e34fb[_0x22c52b]);}}}}return _0x3e34fb;};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x94')]=function(_0x2dcd85){for(var _0x1a7453 in _0x2dcd85){if(_0x2dcd85['hasOwnProperty'](_0x1a7453)){if(_[_0x6e4c('0x95')](_0x2dcd85[_0x1a7453])){this[_0x6e4c('0x94')](_0x2dcd85[_0x1a7453]);}else if(_[_0x6e4c('0x96')](_0x2dcd85[_0x1a7453])){for(var _0x3e9606=0x0;_0x3e9606<_0x2dcd85[_0x1a7453][_0x6e4c('0x97')];_0x3e9606++){this[_0x6e4c('0x94')](_0x2dcd85[_0x1a7453][_0x3e9606]);}}else if(_['isString'](_0x2dcd85[_0x1a7453])){_0x2dcd85[_0x1a7453]=this[_0x6e4c('0x93')](_0x2dcd85[_0x1a7453]);}}}};AGIVertices[_0x6e4c('0x16')]['saveRestApiResult']=function(_0x5b506b,_0x374e11){for(var _0x19ab98 in _0x5b506b){if(_0x5b506b[_0x6e4c('0x91')](_0x19ab98)){if(_[_0x6e4c('0x95')](_0x5b506b[_0x19ab98])){if(!_[_0x6e4c('0x44')](_0x5b506b[_0x19ab98])){this[_0x6e4c('0x98')](_0x5b506b[_0x19ab98],util[_0x6e4c('0x57')](_0x6e4c('0x99'),_0x374e11,_0x19ab98));}}else if(_[_0x6e4c('0x96')](_0x5b506b[_0x19ab98])){for(var _0x1df51d=0x0;_0x1df51d<_0x5b506b[_0x19ab98][_0x6e4c('0x97')];_0x1df51d++){this[_0x6e4c('0x98')](_0x5b506b[_0x19ab98][_0x1df51d],util['format'](_0x6e4c('0x99'),_0x374e11,_0x19ab98+'['+_0x1df51d+']'));}}else{if(!_['isNil'](_0x5b506b[_0x19ab98])){this['channel'][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0x99'),_0x374e11,_0x19ab98),_0x5b506b[_0x19ab98]);}}}}};AGIVertices['prototype'][_0x6e4c('0x9b')]=function(_0x557478){try{var _0x433f82=JSON[_0x6e4c('0x6e')](_0x557478);this[_0x6e4c('0x94')](_0x433f82);return JSON['stringify'](_0x433f82);}catch(_0x5365fe){return this[_0x6e4c('0x93')](_0x557478);}};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x93')]=function(_0x188dda){var _0x406fbc=_0x188dda[_0x6e4c('0x9c')]('{');for(var _0x3ed1d8=0x1;_0x3ed1d8<_0x406fbc['length'];_0x3ed1d8+=0x1){var _0x45fc50=_0x406fbc[_0x3ed1d8][_0x6e4c('0x9c')]('}');if(_0x45fc50['length']>0x1){_0x188dda=_0x188dda['replaceAll']('{'+_0x45fc50[0x0]+'}',this[_0x6e4c('0x35')][_0x6e4c('0x11')](_0x45fc50[0x0])['extra']||_0x45fc50[0x0]);}}if(_0x406fbc['length']===0x1){return _0x188dda['toString']();}return this['replaceAllVariables'](_0x188dda);};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x9d')]=function(_0x39d1d6,_0x3270da){var _0x3fded3=this[_0x6e4c('0x35')]['getVariable'](_0x39d1d6);if(_0x3fded3[_0x6e4c('0x9e')]===-0x1){return _0x3fded3;}logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('The\x20\x22%s\x22\x20variable\x20value\x20is:\x20%s',_0x3270da,_0x3fded3['extra']));return this['channel'][_0x6e4c('0x9a')](_0x3270da,_0x3fded3[_0x6e4c('0x9f')]);};AGIVertices[_0x6e4c('0x16')]['isConfigured']=function(_0x100108){return _0x100108&&_0x100108!=='0'&&_0x100108!=='-1'&&_0x100108!=='';};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xa0')]=function(_0x1673ea){this[_0x6e4c('0xa1')]['sync'](this,_0x1673ea,'-');_0x1673ea['retry']=_0x1673ea[_0x6e4c('0xa0')];return{'code':0xc8,'result':'-'};};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x8')]=function(_0x8329c8){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0xa2'),_0x8329c8['label']));return this['channel'][_0x6e4c('0x8')]([_0x8329c8['command'],_0x8329c8['args']]);};AGIVertices['prototype']['answer']=function(_0x3cf124){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20ANSWER\x20(%s)\x20block',_0x3cf124[_0x6e4c('0x36')]));if(this[_0x6e4c('0xa3')](_0x3cf124[_0x6e4c('0x67')])){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Wait\x20%s\x20seconds\x20before\x20answer',_0x3cf124[_0x6e4c('0x67')]));var _0x34faa4=this[_0x6e4c('0x35')][_0x6e4c('0xa4')](_0x3cf124[_0x6e4c('0x67')]);if(_0x34faa4['result']===-0x1){return _0x34faa4;}}return this[_0x6e4c('0x35')][_0x6e4c('0xa5')]();};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x4b')]=function(_0x1db1e8){logger['info'](util[_0x6e4c('0x57')]('Enter\x20in\x20CALLBACK\x20(%s)\x20block',_0x1db1e8[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x1db1e8['list_id'])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x1db1e8,_0x6e4c('0xa6'));}_0x1db1e8['scheduledAt']=moment();if(this['isConfigured'](_0x1db1e8[_0x6e4c('0xa7')])){_0x1db1e8[_0x6e4c('0x4c')]=moment()[_0x6e4c('0xa8')](_0x1db1e8[_0x6e4c('0xa7')],_0x6e4c('0xa9'));}if(!this[_0x6e4c('0xa3')](_0x1db1e8[_0x6e4c('0x4e')])){_0x1db1e8[_0x6e4c('0x4e')]=0x2;}this[_0x6e4c('0x43')][_0x6e4c('0x71')](this,_0x1db1e8);return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('CALLBACK\x20added\x20phone:\x20%s\x20on\x20list:\x20%s\x20at\x20%s',_0x1db1e8[_0x6e4c('0x49')],_0x1db1e8[_0x6e4c('0x4a')],_0x1db1e8[_0x6e4c('0x4c')]));};AGIVertices['prototype'][_0x6e4c('0xab')]=function(_0x1be70a){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0xac'),_0x1be70a[_0x6e4c('0x36')]));var _0x673145=this[_0x6e4c('0x35')][_0x6e4c('0x5a')](_0x1be70a[_0x6e4c('0xad')],_0x1be70a['options']);if(_0x673145['result']===-0x1){return _0x673145;}return this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xae'),_0x1be70a[_0x6e4c('0xad')],_0x1be70a[_0x6e4c('0xaf')]));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xb0')]=function(_0x38f116){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0xb1'),_0x38f116[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x38f116[_0x6e4c('0x5f')])){return this['channel'][_0x6e4c('0xaa')]('no\x20text\x20configured');}var _0x2f6a36='\x22'+_0x38f116[_0x6e4c('0x5f')]+'\x22';if(this[_0x6e4c('0xa3')](_0x38f116[_0x6e4c('0xaf')])){_0x2f6a36+=','+_0x38f116[_0x6e4c('0xaf')];}var _0x43c41a=this[_0x6e4c('0x35')]['exec'](_0x6e4c('0xb2'),_0x2f6a36);if(_0x43c41a[_0x6e4c('0x9e')]===-0x1){return _0x43c41a;}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xb3'),_0x2f6a36));};AGIVertices['prototype'][_0x6e4c('0xb4')]=function(_0x641822){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0xb5'),_0x641822[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x641822['text'])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xb6'));}var _0x45af6e='\x22'+_0x641822['text']+'\x22';if(this['isConfigured'](_0x641822['options'])){_0x45af6e+=','+_0x641822[_0x6e4c('0xaf')];}var _0x4a469d=this['channel'][_0x6e4c('0x5a')](_0x6e4c('0xb2'),_0x45af6e);if(_0x4a469d[_0x6e4c('0x9e')]===-0x1){return _0x4a469d;}return this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('Executed\x20command\x20MRCPSynth\x20%s',_0x45af6e));};AGIVertices['prototype'][_0x6e4c('0xb7')]=function(_0x1b885f){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20LUMENVOXASR\x20(%s)\x20block',_0x1b885f['label']));if(!this[_0x6e4c('0xa3')](_0x1b885f[_0x6e4c('0xb8')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')]('no\x20grammar\x20configured');}var _0xf30e1f=_0x1b885f[_0x6e4c('0xb8')];if(this[_0x6e4c('0xa3')](_0x1b885f['options'])){_0xf30e1f+=','+_0x1b885f[_0x6e4c('0xaf')];}var _0x59ad34=this[_0x6e4c('0x35')][_0x6e4c('0x5a')]('MRCPRecog',_0xf30e1f);if(_0x59ad34['result']===-0x1){return _0x59ad34;}var _0x1f2c67=this[_0x6e4c('0x9d')]('RECOG_CONFIDENCE()','LUMENVOX_ASR_CONFIDENCE');if(_0x1f2c67[_0x6e4c('0x9e')]===-0x1){return _0x1f2c67;}var _0x496a41=this['getAndSetVariable'](_0x6e4c('0xb9'),_0x6e4c('0xba'));if(_0x496a41[_0x6e4c('0x9e')]===-0x1){return _0x496a41;}var _0x5c8cad=this[_0x6e4c('0x9d')](_0x6e4c('0xbb'),_0x6e4c('0xbc'));if(_0x5c8cad[_0x6e4c('0x9e')]===-0x1){return _0x5c8cad;}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xbd'),_0xf30e1f));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xbe')]=function(_0x2e412a){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0xbf'),_0x2e412a[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x2e412a[_0x6e4c('0xb8')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xc0'));}var _0xb554a7=_0x2e412a[_0x6e4c('0xb8')];if(this[_0x6e4c('0xa3')](_0x2e412a[_0x6e4c('0xaf')])){_0xb554a7+=','+_0x2e412a['options'];}var _0x2c93d5=this[_0x6e4c('0x35')][_0x6e4c('0x5a')](_0x6e4c('0xc1'),_0xb554a7);if(_0x2c93d5[_0x6e4c('0x9e')]===-0x1){return _0x2c93d5;}var _0x380772=this[_0x6e4c('0x9d')](_0x6e4c('0xc2'),_0x6e4c('0xc3'));if(_0x380772[_0x6e4c('0x9e')]===-0x1){return _0x380772;}var _0x2d1fbc=this[_0x6e4c('0x9d')](_0x6e4c('0xb9'),_0x6e4c('0xc4'));if(_0x2d1fbc[_0x6e4c('0x9e')]===-0x1){return _0x2d1fbc;}var _0x1f9333=this[_0x6e4c('0x9d')]('RECOG_INSTANCE()',_0x6e4c('0xc5'));if(_0x1f9333['result']===-0x1){return _0x1f9333;}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util['format'](_0x6e4c('0xbd'),_0xb554a7));};AGIVertices[_0x6e4c('0x16')]['database']=function(_0x5f5339){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0xc6'),_0x5f5339[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x5f5339['odbc_id'])){return this[_0x6e4c('0x35')]['error'](_0x5f5339,_0x6e4c('0xc7'));}var _0x672def=this[_0x6e4c('0x1a')][_0x6e4c('0x71')](this,_0x5f5339['odbc_id']);if(!_0x672def){return this['channel'][_0x6e4c('0x2d')](_0x5f5339,'no\x20odbc\x20database\x20found');}if(!this[_0x6e4c('0xa3')](_0x5f5339['query'])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x5f5339,_0x6e4c('0xc8'));}var _0x4fd6e0=_0x5f5339[_0x6e4c('0x30')][_0x6e4c('0x5c')](/(\r\n|\n|\r)/gm,'\x20');this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xc9'),_0x4fd6e0));var _0x1f506e=this['getQueryOdbc'][_0x6e4c('0x71')](this,_0x672def,_0x4fd6e0);this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x5f5339,_0x4fd6e0);if(!this['isConfigured'](_0x5f5339[_0x6e4c('0xca')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xcb'));}var _0x1b30ee=this[_0x6e4c('0x11')][_0x6e4c('0x71')](this,_0x5f5339[_0x6e4c('0xca')]);if(!_0x1b30ee){return this[_0x6e4c('0x35')]['error'](_0x5f5339,_0x6e4c('0xcc'));}var _0x48821f=this;_0x1f506e['forEach'](function(_0x2be5ff,_0x10c1b1){Object[_0x6e4c('0xcd')](_0x2be5ff)[_0x6e4c('0xce')](function(_0x2501d4){_0x48821f[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0xcf'),_0x1b30ee,_0x10c1b1,_0x2501d4),_0x2be5ff[_0x2501d4]);});});this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util['format']('%s_ROWS_COUNT',_0x1b30ee),_0x1f506e[_0x6e4c('0x97')]);return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util['format'](_0x6e4c('0xd0'),_0x1b30ee));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xd1')]=function(_0x2ca3af){logger['debug'](util[_0x6e4c('0x57')](_0x6e4c('0xd2'),_0x2ca3af[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x2ca3af[_0x6e4c('0xd3')])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x2ca3af,'no\x20user\x20selected');}var _0x466e35=this[_0x6e4c('0x1c')][_0x6e4c('0x71')](this,_0x2ca3af[_0x6e4c('0xd3')]);if(!_0x466e35){return this[_0x6e4c('0x35')]['error'](_0x2ca3af,_0x6e4c('0xd4'));}var _0x4fcf29=this[_0x6e4c('0x35')][_0x6e4c('0x5a')](_0x6e4c('0xd5'),[util[_0x6e4c('0x57')](_0x6e4c('0xd6'),_0x466e35),_0x2ca3af[_0x6e4c('0x67')],_0x2ca3af[_0x6e4c('0xd7')],_0x2ca3af[_0x6e4c('0xd8')]]);if(_0x4fcf29[_0x6e4c('0x9e')]===-0x1){return _0x4fcf29;}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util['format'](_0x6e4c('0xd9'),_0x6e4c('0xd5')));};AGIVertices['prototype']['dialogflow']=function(_0x1ee6b3){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0xda'),_0x1ee6b3[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x1ee6b3[_0x6e4c('0x7b')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xdb'));}if(!this['isConfigured'](_0x1ee6b3[_0x6e4c('0x5f')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')]('no\x20text\x20configured');}this[_0x6e4c('0x35')]['bot']=!![];this[_0x6e4c('0xa1')](_0x1ee6b3);this[_0x6e4c('0x42')](_0x1ee6b3['text'],'in');this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xdc'),_0x1ee6b3[_0x6e4c('0x5f')]));var _0x59d1c1=this[_0x6e4c('0x7a')][_0x6e4c('0x71')](this,_0x1ee6b3);if(_0x59d1c1){for(var _0x26441e in _0x59d1c1){if(_0x59d1c1[_0x6e4c('0x91')](_0x26441e)){this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0xdd'),_0x26441e[_0x6e4c('0x6b')]()),_0x59d1c1[_0x26441e]);}}this[_0x6e4c('0x42')](_0x59d1c1[_0x6e4c('0xde')],_0x6e4c('0xdf'));return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xe0'),_0x59d1c1[_0x6e4c('0xde')]));}return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x1ee6b3,_0x6e4c('0xe1'));};AGIVertices[_0x6e4c('0x16')]['sesteknda']=function(_0xe2fa08){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0xe2'),_0xe2fa08[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0xe2fa08[_0x6e4c('0xe3')])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xe4'));}if(!this['isConfigured'](_0xe2fa08['username'])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xe5'));}if(!this[_0x6e4c('0xa3')](_0xe2fa08[_0x6e4c('0xe6')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xe7'));}if(!this[_0x6e4c('0xa3')](_0xe2fa08['ndassistant_url'])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xb6'));}this['channel'][_0x6e4c('0xe8')]=!![];this[_0x6e4c('0xa1')](_0xe2fa08);this[_0x6e4c('0x42')](_0xe2fa08[_0x6e4c('0x5f')],'in');this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('Trying\x20SestekNDA:\x20%s',_0xe2fa08[_0x6e4c('0x5f')]));var _0x4b9626=this[_0x6e4c('0x7c')]['sync'](this,_0xe2fa08);if(_0x4b9626){for(var _0xf494ba in _0x4b9626){if(_0x4b9626[_0x6e4c('0x91')](_0xf494ba)){this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')]('SESTEK_NDA_%s',_0xf494ba[_0x6e4c('0x6b')]()),_0x4b9626[_0xf494ba]);}}this[_0x6e4c('0x42')](_0x4b9626[_0x6e4c('0xde')],_0x6e4c('0xdf'));if(_0x4b9626[_0x6e4c('0xe9')]){this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')](_0x6e4c('0xea'),_0x4b9626['audiofile']));var _0x3021dd=this['channel'][_0x6e4c('0xeb')](_0x4b9626['audiofile']);try{fs[_0x6e4c('0xec')](_0x4b9626['audiofile']+'.wav');}catch(_0x4eef39){logger[_0x6e4c('0x2d')](_0x4eef39);}return _0x3021dd;}else{return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util['format'](_0x6e4c('0xed'),_0x4b9626[_0x6e4c('0xde')]));}}return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0xe2fa08,_0x6e4c('0xee'));};AGIVertices[_0x6e4c('0x16')]['end']=function(_0x5b20fb){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0xef'),_0x5b20fb[_0x6e4c('0x36')]));return this[_0x6e4c('0x35')][_0x6e4c('0xaa')]('end');};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xf0')]=function(_0x2a3f0b){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0xf1'),_0x2a3f0b['label']));var _0x538dc7='';if(_0x2a3f0b[_0x6e4c('0xf2')]){if(!this['isConfigured'](_0x2a3f0b[_0x6e4c('0xf2')])){return this['channel'][_0x6e4c('0x2d')](_0x2a3f0b,_0x6e4c('0xf3'));}else{var _0x52f616=parseInt(_0x2a3f0b['trunk_id'],0xa);if(isNaN(_0x52f616)){_0x538dc7=_0x2a3f0b['trunk_id'];}else{_0x538dc7=this[_0x6e4c('0xf4')][_0x6e4c('0x71')](this,_0x2a3f0b['trunk_id']);if(!_0x538dc7){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x2a3f0b,_0x6e4c('0xf5'));}}}}else if(_0x2a3f0b[_0x6e4c('0xf6')]){_0x538dc7=_0x2a3f0b[_0x6e4c('0xf6')];}else{return this['channel'][_0x6e4c('0x2d')](_0x2a3f0b,_0x6e4c('0xf3'));}var _0x5a0fe9=this['channel'][_0x6e4c('0x5a')](_0x6e4c('0xd5'),[util[_0x6e4c('0x57')](_0x6e4c('0xf7'),_0x538dc7,_0x2a3f0b['phone']),_0x2a3f0b[_0x6e4c('0x67')],_0x2a3f0b[_0x6e4c('0xd7')],_0x2a3f0b[_0x6e4c('0xd8')]]);if(_0x5a0fe9[_0x6e4c('0x9e')]===-0x1){return _0x5a0fe9;}return this['channel'][_0x6e4c('0xaa')](util['format'](_0x6e4c('0xd9'),'DIAL'));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xf8')]=function(_0x57e3c6){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0xf9'),_0x57e3c6[_0x6e4c('0x36')]));return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xf8'));};AGIVertices[_0x6e4c('0x16')]['getdigits']=function(_0x1ab421){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0xfa'),_0x1ab421['label']));if(_0x1ab421[_0x6e4c('0xfb')]===0x0){return this[_0x6e4c('0xa0')](_0x1ab421);}_0x1ab421[_0x6e4c('0xfb')]-=0x1;if(!this[_0x6e4c('0xa3')](_0x1ab421[_0x6e4c('0xfc')])){return this['channel']['error'](_0x1ab421,_0x6e4c('0xfd'));}var _0x44bff5=this[_0x6e4c('0x1e')][_0x6e4c('0x71')](this,_0x1ab421[_0x6e4c('0xfc')]);if(!_0x44bff5){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x1ab421,_0x6e4c('0xfe'));}if(!this['isConfigured'](_0x1ab421[_0x6e4c('0xca')])){return this[_0x6e4c('0x35')]['error'](_0x6e4c('0xcb'));}var _0x108ec2=this[_0x6e4c('0x35')][_0x6e4c('0xff')](_0x44bff5,_0x1ab421[_0x6e4c('0x100')],_0x1ab421['maxdigit']);var _0x1c5275=_0x108ec2['result']?_0x108ec2['result'][_0x6e4c('0x4d')]():'';logger['info'](_0x6e4c('0x101'),JSON[_0x6e4c('0x75')](_0x108ec2));if(_0x108ec2[_0x6e4c('0x9e')]===-0x1){this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x1ab421,_0x1c5275);return _0x108ec2;}else if(_0x108ec2[_0x6e4c('0x9f')]===_0x6e4c('0x67')){_0x108ec2[_0x6e4c('0x9e')]=_0x1c5275[_0x6e4c('0x97')]>=parseInt(_0x1ab421[_0x6e4c('0x102')])?'x':'i';}else{_0x108ec2['result']=_0x1c5275[_0x6e4c('0x97')]>=parseInt(_0x1ab421['mindigit'])&&_0x1c5275['length']<=parseInt(_0x1ab421[_0x6e4c('0x103')])?'x':'i';}var _0x3accc7=this[_0x6e4c('0x11')]['sync'](this,_0x1ab421[_0x6e4c('0xca')]);if(!_0x3accc7){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x1ab421,_0x6e4c('0xcc'));}this[_0x6e4c('0x35')][_0x6e4c('0x9a')](_0x3accc7,_0x1c5275);if(this[_0x6e4c('0xa3')](_0x1ab421[_0x6e4c('0x104')])){var _0x106c57=parseInt(_0x1ab421[_0x6e4c('0x104')],0xa);var _0x1f2d9a=rs[_0x6e4c('0x105')]({'charset':'*','length':_0x106c57});var _0x19428c=_0x1c5275[_0x6e4c('0x97')];if(_0x19428c>0x0){if(_0x19428c>_0x106c57){this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x1ab421,_0x1ab421['hiddendigitspos']==='first'?_0x1f2d9a+_0x1c5275['substr'](_0x106c57):_0x1c5275[_0x6e4c('0x106')](0x0,_0x19428c-_0x106c57)+_0x1f2d9a);}else{this[_0x6e4c('0xa1')]['sync'](this,_0x1ab421,rs['generate']({'charset':'*','length':_0x19428c}));}}else{this[_0x6e4c('0xa1')]['sync'](this,_0x1ab421,'');}}else{this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x1ab421,_0x1c5275);}return _0x108ec2;};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xf')]=function(_0x3de757){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x107'),_0x3de757[_0x6e4c('0x36')]));return this[_0x6e4c('0xe')](_0x3de757);};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x108')]=function(_0x4e005e){logger[_0x6e4c('0x2e')](util['format']('Enter\x20in\x20GOAL\x20(%s)\x20block',_0x4e005e[_0x6e4c('0x36')]));this[_0x6e4c('0xa1')]['sync'](this,_0x4e005e,_0x4e005e['goalname']);return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x109'),_0x4e005e[_0x6e4c('0x10a')]));};AGIVertices[_0x6e4c('0x16')]['awspolly']=function(_0x4caa5f){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x10b'),_0x4caa5f['label']));if(!this[_0x6e4c('0xa3')](_0x4caa5f[_0x6e4c('0x84')])||!this[_0x6e4c('0xa3')](_0x4caa5f[_0x6e4c('0x89')])){return this[_0x6e4c('0x35')]['noop']('no\x20valid\x20credentials\x20configured');}if(!this[_0x6e4c('0xa3')](_0x4caa5f[_0x6e4c('0x5f')])){return this['channel'][_0x6e4c('0xaa')]('no\x20text\x20configured');}this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('Trying\x20aws\x20Polly\x20%s',_0x4caa5f[_0x6e4c('0x5f')]));var _0x59dfdd=this[_0x6e4c('0x83')][_0x6e4c('0x71')](this,_0x4caa5f);if(_0x59dfdd){this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x10c'),_0x59dfdd));var _0x3d8de0=this[_0x6e4c('0x35')][_0x6e4c('0xeb')](_0x59dfdd);try{fs[_0x6e4c('0xec')](_0x59dfdd+'.wav');}catch(_0x579ff4){logger[_0x6e4c('0x2d')](_0x579ff4);}return _0x3d8de0;}return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x4caa5f,'aws\x20Polly\x20is\x20unreachable');};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x10d')]=function(_0x346a14){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0x10e'),_0x346a14[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x346a14[_0x6e4c('0x84')])||!this[_0x6e4c('0xa3')](_0x346a14['aws_secret_access_key'])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0x10f'));}if(!this[_0x6e4c('0xa3')](_0x346a14[_0x6e4c('0x110')])){return this['channel']['noop'](_0x6e4c('0x111'));}if(!this[_0x6e4c('0xa3')](_0x346a14[_0x6e4c('0x5f')])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xb6'));}this[_0x6e4c('0x35')]['bot']=!![];this[_0x6e4c('0xa1')](_0x346a14);this['createSquareMessage'](_0x346a14[_0x6e4c('0x5f')],'in');this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')]('Trying\x20Amazon\x20Lex:\x20%s',_0x346a14[_0x6e4c('0x5f')]));var _0x1c62d2=this[_0x6e4c('0x88')][_0x6e4c('0x71')](this,_0x346a14);if(_0x1c62d2){for(var _0x2f0fd7 in _0x1c62d2){if(_0x1c62d2[_0x6e4c('0x91')](_0x2f0fd7)&&_[_0x6e4c('0x92')](_0x1c62d2[_0x2f0fd7])){this['channel']['setVariable'](util['format']('AWS_LEX_%s',_0x2f0fd7[_0x6e4c('0x6b')]()),_0x1c62d2[_0x2f0fd7]);}}if(_[_0x6e4c('0x45')](_0x1c62d2[_0x6e4c('0x78')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0x112'));}else{this[_0x6e4c('0x42')](_0x1c62d2[_0x6e4c('0x78')],_0x6e4c('0xdf'));return this['channel']['noop'](util[_0x6e4c('0x57')](_0x6e4c('0x113'),_0x1c62d2[_0x6e4c('0x78')]));}}return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x346a14,'Amazon\x20Lex\x20is\x20unreachable');};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x114')]=function(_0x53dc0a){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0x115'),_0x53dc0a[_0x6e4c('0x36')],_0x53dc0a[_0x6e4c('0x67')]));if(!this[_0x6e4c('0xa3')](_0x53dc0a[_0x6e4c('0x7b')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xdb'));}var _0x423ced='wav';var _0x40a7a2=util[_0x6e4c('0x57')](_0x6e4c('0x116'),FILES_PATH,rs[_0x6e4c('0x105')](0x4));var _0x310d9f=util[_0x6e4c('0x57')](_0x6e4c('0x99'),_0x40a7a2,_0x423ced);var _0x59866b=!![];if(_0x53dc0a[_0x6e4c('0x117')]===_0x6e4c('0x118')){_0x59866b=![];}var _0x3b0781=this['channel'][_0x6e4c('0x119')](_0x40a7a2,_0x423ced,_0x53dc0a[_0x6e4c('0x11a')],_0x53dc0a[_0x6e4c('0x67')],undefined,_0x59866b);if(_0x3b0781[_0x6e4c('0x9e')]!==-0x1){this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x11b'),_0x310d9f));var _0x568262=this['googleASR'][_0x6e4c('0x71')](this,_0x53dc0a,_0x310d9f);if(_0x568262){for(var _0x1f5cfe in _0x568262){if(_0x568262[_0x6e4c('0x91')](_0x1f5cfe)){this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')]('GOOGLE_ASR_%s',_0x1f5cfe[_0x6e4c('0x6b')]()),_0x568262[_0x1f5cfe]);}}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x11c'),JSON[_0x6e4c('0x75')](_0x568262)));}}return _0x3b0781;};AGIVertices[_0x6e4c('0x16')]['tildeasr']=function(_0x5ac2b2){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0x11d'),_0x5ac2b2['label']));if(!this['isConfigured'](_0x5ac2b2['appid'])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')]('no\x20appid\x20configured');}if(!this[_0x6e4c('0xa3')](_0x5ac2b2[_0x6e4c('0x11e')])){return this['channel'][_0x6e4c('0xaa')](_0x6e4c('0x11f'));}var _0x4a57ad=_0x6e4c('0x120');var _0x345af4=util[_0x6e4c('0x57')](_0x6e4c('0x116'),FILES_PATH,rs[_0x6e4c('0x105')](0x4));var _0x150c69=util[_0x6e4c('0x57')]('%s.%s',_0x345af4,_0x4a57ad);var _0x185d8a=!![];if(_0x5ac2b2[_0x6e4c('0x117')]===_0x6e4c('0x118')){_0x185d8a=![];}var _0x2c1170=this[_0x6e4c('0x35')][_0x6e4c('0x119')](_0x345af4,_0x4a57ad,_0x5ac2b2[_0x6e4c('0x11a')],_0x5ac2b2[_0x6e4c('0x67')],undefined,_0x185d8a);if(_0x2c1170['result']!==-0x1){this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x121'),_0x150c69));var _0x2c8f3b=this[_0x6e4c('0x8d')]['sync'](this,_0x5ac2b2,_0x150c69);if(_0x2c8f3b){for(var _0x4bb214 in _0x2c8f3b){if(_0x2c8f3b[_0x6e4c('0x91')](_0x4bb214)){this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0x122'),_0x4bb214['toUpperCase']()),_0x2c8f3b[_0x4bb214]);}}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x123'),JSON[_0x6e4c('0x75')](_0x2c8f3b)));}}return _0x2c1170;};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x124')]=function(_0x1a0fe8){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20GOTO\x20(%s)\x20block',_0x1a0fe8['label']));return this[_0x6e4c('0x35')][_0x6e4c('0x125')](_0x1a0fe8[_0x6e4c('0x3c')],_0x1a0fe8[_0x6e4c('0x3d')],_0x1a0fe8['priority']);};AGIVertices['prototype'][_0x6e4c('0x126')]=function(_0x2cc663){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0x127'),_0x2cc663[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x2cc663[_0x6e4c('0x128')])){return this['channel'][_0x6e4c('0x2d')](_0x2cc663,'no\x20condition\x20configured');}try{var _0x50bfe6=eval(_0x2cc663[_0x6e4c('0x128')])?'true':_0x6e4c('0x129');this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')](_0x6e4c('0x12a'),_0x2cc663[_0x6e4c('0x128')],_0x50bfe6));return{'code':0xc8,'result':_0x50bfe6};}catch(_0x131a24){return{'code':0xc8,'result':_0x6e4c('0x129')};}};AGIVertices[_0x6e4c('0x16')]['gotoiftime']=function(_0x294fc7){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x12b'),_0x294fc7['label']));if(!this[_0x6e4c('0xa3')](_0x294fc7[_0x6e4c('0x12c')])){return this['channel'][_0x6e4c('0x2d')](_0x294fc7,_0x6e4c('0x12d'));}var _0x1f5d69=this[_0x6e4c('0x25')]['sync'](this,_0x294fc7[_0x6e4c('0x12c')]);if(!_0x1f5d69){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x294fc7,_0x6e4c('0x12e'));}for(var _0x45f937=0x0;_0x45f937<_0x1f5d69[_0x6e4c('0x97')];_0x45f937+=0x1){var _0x2e8afc=this[_0x6e4c('0x35')]['getVariable'](util['format'](_0x6e4c('0x12f'),_0x1f5d69[_0x45f937]));if(_0x2e8afc['result']===-0x1){return _0x2e8afc;}logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x130'),_0x1f5d69[_0x45f937],_0x2e8afc[_0x6e4c('0x9f')]));if(_0x2e8afc[_0x6e4c('0x9f')]==='true'){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0x130'),_0x1f5d69[_0x45f937],_0x6e4c('0x131')));this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('IFTIME\x20%s\x20%s',_0x1f5d69[_0x45f937],_0x6e4c('0x131')));return{'code':0xc8,'result':_0x6e4c('0x131')};}else{logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x130'),_0x1f5d69[_0x45f937],'false'));this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')]('IFTIME\x20%s\x20%s',_0x1f5d69[_0x45f937],_0x6e4c('0x129')));}}return{'code':0xc8,'result':'false'};};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x132')]=function(_0x783bf0){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x133'),_0x783bf0[_0x6e4c('0x36')]));return this['channel'][_0x6e4c('0x132')]();};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x134')]=function(_0x185bd9){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x135'),_0x185bd9[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x185bd9['key'])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')]('no\x20key\x20configured');}var _0x4e525b=_0x6e4c('0x120');var _0x21f495=util[_0x6e4c('0x57')](_0x6e4c('0x116'),FILES_PATH,rs[_0x6e4c('0x105')](0x4));var _0xbe06e2=util[_0x6e4c('0x57')](_0x6e4c('0x99'),_0x21f495,_0x4e525b);var _0x275360=!![];if(_0x185bd9[_0x6e4c('0x117')]===_0x6e4c('0x118')){_0x275360=![];}var _0x2de67d=this[_0x6e4c('0x35')][_0x6e4c('0x119')](_0x21f495,_0x4e525b,_0x185bd9[_0x6e4c('0x11a')],_0x185bd9[_0x6e4c('0x67')],undefined,_0x275360);if(_0x2de67d[_0x6e4c('0x9e')]!==-0x1){this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')](_0x6e4c('0x136'),_0xbe06e2));var _0x47e6a7=this[_0x6e4c('0x80')][_0x6e4c('0x71')](this,_0x185bd9,_0xbe06e2);if(_0x47e6a7){for(var _0x2c388d in _0x47e6a7){if(_0x47e6a7[_0x6e4c('0x91')](_0x2c388d)){this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0x137'),_0x2c388d[_0x6e4c('0x6b')]()),_0x47e6a7[_0x2c388d]);}}return this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')](_0x6e4c('0x138'),JSON[_0x6e4c('0x75')](_0x47e6a7)));}}return _0x2de67d;};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x139')]=function(_0x151a5f){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x13a'),_0x151a5f[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x151a5f[_0x6e4c('0x7b')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xdb'));}if(!this[_0x6e4c('0xa3')](_0x151a5f[_0x6e4c('0x5f')])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xb6'));}this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('Trying\x20ispeech\x20TTS\x20%s',_0x151a5f[_0x6e4c('0x5f')]));var _0x5164f7=this[_0x6e4c('0x7d')][_0x6e4c('0x71')](this,_0x151a5f);if(_0x5164f7){this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x136'),_0x5164f7));var _0x5cb889=this['channel'][_0x6e4c('0xeb')](_0x5164f7,_0x151a5f[_0x6e4c('0x11a')]);try{fs[_0x6e4c('0xec')](_0x5164f7+_0x6e4c('0x13b'));}catch(_0x293032){logger['error'](_0x293032);}return _0x5cb889;}return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x151a5f,'ispeech\x20TTS\x20is\x20unreachable');};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x13c')]=function(_0x348a33){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x13d'),_0x348a33[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x348a33[_0x6e4c('0x13e')])){return this[_0x6e4c('0x35')]['error'](_0x348a33,'no\x20find\x20by\x20configured');}logger['info'](util[_0x6e4c('0x57')]('FIND\x20AGENT\x20%s\x20BY\x20%s',this['channel'][_0x6e4c('0x3a')],_0x348a33['findBy']));var _0x20686a=this[_0x6e4c('0x55')][_0x6e4c('0x71')](this,_0x348a33[_0x6e4c('0x13e')]);if(_0x20686a){logger['info'](util['format'](_0x6e4c('0x13f'),this[_0x6e4c('0x35')]['callerid'],_0x348a33['findBy']));this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x13f'),this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0x348a33[_0x6e4c('0x13e')]));return{'code':0xc8,'result':_0x6e4c('0x140')};}else{logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x141'),this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0x348a33[_0x6e4c('0x13e')]));this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util['format'](_0x6e4c('0x141'),this['channel'][_0x6e4c('0x3a')],_0x348a33[_0x6e4c('0x13e')]));return{'code':0xc8,'result':'failure'};}};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x142')]=function(_0xf6b02f){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20LOGOUT\x20(%s)\x20block',_0xf6b02f[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0xf6b02f['findBy'])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0xf6b02f,_0x6e4c('0x143'));}logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x144'),this['channel'][_0x6e4c('0x3a')],_0xf6b02f[_0x6e4c('0x13e')]));var _0x5b4097=this[_0x6e4c('0x54')][_0x6e4c('0x71')](this,_0xf6b02f[_0x6e4c('0x13e')]);if(_0x5b4097){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x13f'),this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0xf6b02f[_0x6e4c('0x13e')]));this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x13f'),this['channel'][_0x6e4c('0x3a')],_0xf6b02f['findBy']));return{'code':0xc8,'result':'success'};}else{logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0x141'),this['channel'][_0x6e4c('0x3a')],_0xf6b02f[_0x6e4c('0x13e')]));this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util['format'](_0x6e4c('0x141'),this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0xf6b02f[_0x6e4c('0x13e')]));return{'code':0xc8,'result':'failure'};}};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x145')]=function(_0x3e9a07){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x146'),_0x3e9a07[_0x6e4c('0x36')]));if(!this['isConfigured'](_0x3e9a07['operation'])){return this[_0x6e4c('0x35')]['error'](_0x3e9a07,_0x6e4c('0x147'));}this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x148'),_0x3e9a07[_0x6e4c('0x149')]));var _0x5de72e=eval(_0x3e9a07['operation']);if(!this[_0x6e4c('0xa3')](_0x3e9a07[_0x6e4c('0xca')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xcb'));}var _0x5576b9=this[_0x6e4c('0x11')][_0x6e4c('0x71')](this,_0x3e9a07[_0x6e4c('0xca')]);if(!_0x5576b9){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x3e9a07,_0x6e4c('0xcc'));}if(_[_0x6e4c('0x96')](_0x5de72e)){var _0x5169dd=this;_0x5de72e[_0x6e4c('0xce')](function(_0x2c5a09,_0x5a3876){_0x5169dd['channel'][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0x14a'),_0x5576b9,_0x5a3876),_0x2c5a09);});return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x14b'),_0x5576b9));}else{return this[_0x6e4c('0x35')][_0x6e4c('0x9a')](_0x5576b9,_0x5de72e);}};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0xd')]=function(_0x587082){logger['info'](util[_0x6e4c('0x57')]('Enter\x20in\x20MENU\x20(%s)\x20block',_0x587082[_0x6e4c('0x36')]));if(_0x587082[_0x6e4c('0xfb')]===0x0){return this['maxRetry'](_0x587082);}_0x587082[_0x6e4c('0xfb')]-=0x1;if(!this[_0x6e4c('0xa3')](_0x587082[_0x6e4c('0xfc')])){return this['channel'][_0x6e4c('0x2d')](_0x587082,'no\x20file\x20audio\x20selected');}var _0x3981ea=this[_0x6e4c('0x1e')][_0x6e4c('0x71')](this,_0x587082['file_id']);if(!_0x3981ea){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x587082,_0x6e4c('0xfe'));}var _0x4f603c=this[_0x6e4c('0x35')][_0x6e4c('0xff')](_0x3981ea,_0x587082[_0x6e4c('0x100')],_0x587082['digit']);var _0x508f45=_0x4f603c[_0x6e4c('0x9e')];if(_0x4f603c['result']===-0x1){this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x587082,'-1');return _0x4f603c;}else if(_0x4f603c[_0x6e4c('0x9f')]===_0x6e4c('0x67')){_0x4f603c[_0x6e4c('0x9e')]=_0x4f603c[_0x6e4c('0x9e')][_0x6e4c('0x97')]>0x0?_0x4f603c[_0x6e4c('0x9e')]:'t';}else if(_[_0x6e4c('0x44')](_0x4f603c[_0x6e4c('0x9e')])){_0x4f603c[_0x6e4c('0x9e')]='#';_0x508f45='#';}if(!this[_0x6e4c('0xa3')](_0x587082['variable_id'])){this[_0x6e4c('0x35')]['noop'](_0x6e4c('0xcb'));}else{var _0xe96eda=this['getVariable'][_0x6e4c('0x71')](this,_0x587082[_0x6e4c('0xca')]);if(!_0xe96eda){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x587082,_0x6e4c('0xcc'));}this[_0x6e4c('0x35')][_0x6e4c('0x9a')](_0xe96eda,_0x508f45);}this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x587082,_0x508f45);return _0x4f603c;};AGIVertices['prototype']['noop']=function(_0x38977d){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20NOOP\x20(%s)\x20block',_0x38977d[_0x6e4c('0x36')]));return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x38977d[_0x6e4c('0x14c')]||_0x38977d[_0x6e4c('0x36')]);};AGIVertices['prototype'][_0x6e4c('0x14d')]=function(_0x43247a){logger['info'](util[_0x6e4c('0x57')]('Enter\x20in\x20PAUSE\x20(%s)\x20block',_0x43247a[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x43247a[_0x6e4c('0x13e')])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x43247a,_0x6e4c('0x143'));}logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x144'),this[_0x6e4c('0x35')]['callerid'],_0x43247a[_0x6e4c('0x13e')]));var _0x98546e=this['getPause'][_0x6e4c('0x71')](this,_0x43247a[_0x6e4c('0x14e')]);var _0x461182=this[_0x6e4c('0x52')][_0x6e4c('0x71')](this,_0x43247a['findBy'],_0x98546e);if(_0x461182){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x13f'),this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0x43247a[_0x6e4c('0x13e')]));this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('AGENT\x20%s\x20FOUND\x20BY',this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0x43247a[_0x6e4c('0x13e')]));return{'code':0xc8,'result':_0x6e4c('0x140')};}else{logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0x141'),this[_0x6e4c('0x35')]['callerid'],_0x43247a[_0x6e4c('0x13e')]));this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x13f'),this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0x43247a[_0x6e4c('0x13e')]));return{'code':0xc8,'result':_0x6e4c('0x14f')};}};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x150')]=function(_0x255232){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0x151'),_0x255232['label']));if(!this['isConfigured'](_0x255232['file_id'])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x255232,_0x6e4c('0xfd'));}var _0x1bb4da=this['getSound'][_0x6e4c('0x71')](this,_0x255232[_0x6e4c('0xfc')]);if(!_0x1bb4da){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x255232,_0x6e4c('0xfe'));}var _0x485d79=this[_0x6e4c('0x35')][_0x6e4c('0x5a')](_0x6e4c('0x152'),[_0x1bb4da,_0x255232[_0x6e4c('0xd7')]]);if(_0x485d79[_0x6e4c('0x9e')]===-0x1){return _0x485d79;}return this['channel'][_0x6e4c('0xaa')](util['format'](_0x6e4c('0xae'),_0x6e4c('0x152'),_0x1bb4da));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x153')]=function(_0x5c58d8){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x154'),_0x5c58d8['label']));if(!this[_0x6e4c('0xa3')](_0x5c58d8[_0x6e4c('0x155')])){return this[_0x6e4c('0x35')]['error'](_0x5c58d8,_0x6e4c('0x156'));}var _0x50a615='';var _0x4b16d6=parseInt(_0x5c58d8[_0x6e4c('0x155')],0xa);if(isNaN(_0x4b16d6)){_0x50a615=_0x5c58d8['queue_id'];}else{_0x50a615=this[_0x6e4c('0x157')][_0x6e4c('0x71')](this,_0x5c58d8[_0x6e4c('0x155')]);if(!_0x50a615){return this['channel'][_0x6e4c('0x2d')](_0x5c58d8,'no\x20queue\x20found');}}var _0x17e74c='';if(this['isConfigured'](_0x5c58d8[_0x6e4c('0xfc')])){var _0x2bcbf9=this[_0x6e4c('0x1e')][_0x6e4c('0x71')](this,_0x5c58d8[_0x6e4c('0xfc')]);if(_0x2bcbf9){_0x17e74c=_0x2bcbf9;}}this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x5c58d8,_0x50a615);if(_0x5c58d8['opts'][_0x6e4c('0x158')]('x')<0x0){_0x5c58d8[_0x6e4c('0xd7')]+='x';}if(_0x5c58d8[_0x6e4c('0xd7')]['indexOf']('X')<0x0){_0x5c58d8['opts']+='X';}this['channel'][_0x6e4c('0x9a')](_0x6e4c('0x159'),_0x50a615?_0x50a615[_0x6e4c('0x15a')]():'');var _0x2fea7f=this[_0x6e4c('0x35')][_0x6e4c('0x5a')]('QUEUE',[_0x50a615,_0x5c58d8[_0x6e4c('0xd7')],_0x5c58d8[_0x6e4c('0xd8')],_0x17e74c,_0x5c58d8[_0x6e4c('0x67')],_0x5c58d8[_0x6e4c('0x8')],_0x5c58d8['macro'],_0x5c58d8[_0x6e4c('0x15b')],'',_0x5c58d8['position']]);if(_0x2fea7f[_0x6e4c('0x9e')]===-0x1){return _0x2fea7f;}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xae'),_0x6e4c('0x15c'),_0x50a615));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x15d')]=function(_0x4de793){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x15e'),_0x4de793[_0x6e4c('0x36')]));var _0x4888e0=_0x4de793[_0x6e4c('0x15f')]||_0x6e4c('0x120');var _0x5758b3=util[_0x6e4c('0x57')](_0x6e4c('0x160'),this[_0x6e4c('0x35')][_0x6e4c('0x39')],rs['generate'](0x5));var _0x2bffdf=util['format']('%s/recordings/%s.%s',FILES_PATH,_0x5758b3,_0x4888e0);var _0x223ae7=util['format'](_0x6e4c('0x116'),FILES_PATH,_0x5758b3);this[_0x6e4c('0x38')]['sync'](this,_0x4de793,_0x5758b3,_0x2bffdf);this[_0x6e4c('0x35')][_0x6e4c('0x9a')](_0x6e4c('0x161'),_0x5758b3);logger[_0x6e4c('0x2e')]('Recording\x20%s\x20%s\x20%s\x20%s',_0x223ae7,_0x4888e0,_0x4de793[_0x6e4c('0x162')],_0x4de793[_0x6e4c('0x67')]);return this[_0x6e4c('0x35')][_0x6e4c('0x119')](_0x223ae7,_0x4888e0,_0x4de793[_0x6e4c('0x162')],_0x4de793['timeout'],undefined,!![]);};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x163')]=function(_0x3fc7db){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x164'),_0x3fc7db['label']));if(!this[_0x6e4c('0xa3')](_0x3fc7db['url'])){return this['channel'][_0x6e4c('0xaa')](_0x6e4c('0x165'));}var _0x5877d7=this[_0x6e4c('0x65')][_0x6e4c('0x71')](this,_0x3fc7db);logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x166'),util['inspect'](_0x5877d7,{'showHidden':![],'depth':null})));if(!this[_0x6e4c('0xa3')](_0x3fc7db['variable_id'])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0x167'));}var _0x54e546=this[_0x6e4c('0x11')][_0x6e4c('0x71')](this,_0x3fc7db[_0x6e4c('0xca')]);if(!_0x54e546){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x3fc7db,_0x6e4c('0xcc'));}this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0x168'),_0x54e546),_0x5877d7[_0x6e4c('0x77')]?_0x5877d7[_0x6e4c('0x77')]:_0x6e4c('0x169'));this[_0x6e4c('0x35')][_0x6e4c('0x9a')](util[_0x6e4c('0x57')](_0x6e4c('0x16a'),_0x54e546),_0x5877d7[_0x6e4c('0x76')]?_0x5877d7[_0x6e4c('0x76')]:'OK');if(_0x5877d7[_0x6e4c('0x6c')]){try{this[_0x6e4c('0x98')](_0x5877d7[_0x6e4c('0x6c')],_0x54e546);}catch(_0x55b89d){logger['error'](util[_0x6e4c('0x57')](_0x6e4c('0x16b'),_0x54e546));}}return this['channel']['noop'](util['format']('variable\x20%s\x20set',_0x54e546));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x16c')]=function(_0x1fa7d2){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x16d'),_0x1fa7d2[_0x6e4c('0x36')]));return this[_0x6e4c('0x35')][_0x6e4c('0x16e')](_0x1fa7d2[_0x6e4c('0x16f')][_0x6e4c('0x5c')](/\s+/g,''),_0x1fa7d2[_0x6e4c('0x162')]);};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x170')]=function(_0x53f011){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20SAYNUMBER\x20(%s)\x20block',_0x53f011['label']));return this['channel']['sayNumber'](_0x53f011['number']['replace'](/\s+/g,''),_0x53f011[_0x6e4c('0x162')]);};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x171')]=function(_0x36db26){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x172'),_0x36db26['label']));return this[_0x6e4c('0x35')][_0x6e4c('0x173')](_0x36db26[_0x6e4c('0x5f')],_0x36db26[_0x6e4c('0x162')]);};AGIVertices['prototype']['sendMail']=function(_0xd892f7){logger['info'](util[_0x6e4c('0x57')](_0x6e4c('0x174'),_0xd892f7[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0xd892f7[_0x6e4c('0x175')])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0x176'));}var _0x2d042f=this['getMailAccount'][_0x6e4c('0x71')](this,_0xd892f7['account_id']);if(!_0x2d042f||!_0x2d042f[_0x6e4c('0x177')]){return this['channel'][_0x6e4c('0x2d')](_0xd892f7,'no\x20mail\x20account\x20found');}var _0x168b75={'from':util[_0x6e4c('0x57')](_0x6e4c('0x178'),_0x2d042f[_0x6e4c('0x14')],_0x2d042f[_0x6e4c('0x179')]||_0x2d042f['Smtp'][_0x6e4c('0x17a')]),'to':_0xd892f7['to']||'','cc':_0xd892f7['cc']||'','bcc':_0xd892f7[_0x6e4c('0x17b')]||'','subject':_0xd892f7[_0x6e4c('0x17c')],'html':_0xd892f7[_0x6e4c('0x5f')],'text':_0xd892f7[_0x6e4c('0x5f')]};var _0x1254f8={'tls':{'rejectUnauthorized':![]}};if(_0x2d042f[_0x6e4c('0x177')][_0x6e4c('0x17d')]){_0x1254f8['service']=_0x2d042f[_0x6e4c('0x177')][_0x6e4c('0x17d')];}else{_0x1254f8[_0x6e4c('0x17e')]=_0x2d042f['Smtp'][_0x6e4c('0x17e')];_0x1254f8[_0x6e4c('0x17f')]=_0x2d042f[_0x6e4c('0x177')][_0x6e4c('0x17f')];_0x1254f8[_0x6e4c('0x180')]=_0x2d042f[_0x6e4c('0x177')][_0x6e4c('0x180')];}if(_0x2d042f[_0x6e4c('0x177')][_0x6e4c('0x181')]){_0x1254f8[_0x6e4c('0x182')]={'user':_0x2d042f[_0x6e4c('0x177')][_0x6e4c('0x17a')],'pass':_0x2d042f['Smtp']['pass']};}if(this[_0x6e4c('0xa3')](_0xd892f7['template_id'])){}logger[_0x6e4c('0x183')](_0x6e4c('0x184'),JSON[_0x6e4c('0x75')](_0x168b75));this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0xd892f7,_0xd892f7['account_id']);this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x185'),_0x2d042f['name']));this['sendMailMessage'][_0x6e4c('0x71')](this,_0x1254f8,_0x168b75);return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0x186'));};AGIVertices['prototype']['sendFax']=function(_0x51d095){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x187'),_0x51d095[_0x6e4c('0x36')]));return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0x188'));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x189')]=function(_0x1ed746){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x18a'),_0x1ed746[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x1ed746[_0x6e4c('0x18b')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0x18c'));}var _0x15b7ce=this['getSmsAccount'][_0x6e4c('0x71')](this,_0x1ed746[_0x6e4c('0x18b')]);if(!_0x15b7ce){return this[_0x6e4c('0x35')]['error'](_0x1ed746,_0x6e4c('0x18d'));}var _0x43a7da={'body':_0x1ed746[_0x6e4c('0x18e')],'phone':_0x1ed746['to']||'','SmsAccountId':_0x15b7ce['id']};logger[_0x6e4c('0x183')](_0x6e4c('0x18f'),JSON[_0x6e4c('0x75')](_0x43a7da));this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x1ed746,_0x1ed746[_0x6e4c('0x18b')]);this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('Trying\x20SendSMS\x20with\x20account\x20%s',_0x15b7ce['name']));this[_0x6e4c('0x190')][_0x6e4c('0x71')](this,_0x43a7da);return this[_0x6e4c('0x35')][_0x6e4c('0xaa')]('Sms\x20message\x20added\x20to\x20outgoing\x20process');};AGIVertices['prototype'][_0x6e4c('0x191')]=function(_0x57e32a){logger[_0x6e4c('0x2e')](util['format']('Enter\x20in\x20SET\x20(%s)\x20block',_0x57e32a[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x57e32a[_0x6e4c('0xca')])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x57e32a,_0x6e4c('0x192'));}var _0x5adb82=this[_0x6e4c('0x11')][_0x6e4c('0x71')](this,_0x57e32a[_0x6e4c('0xca')]);if(!_0x5adb82){return this[_0x6e4c('0x35')]['error'](_0x57e32a,_0x6e4c('0xcc'));}return this['channel'][_0x6e4c('0x9a')](_0x5adb82,_0x57e32a[_0x6e4c('0x193')]);};AGIVertices[_0x6e4c('0x16')]['start']=function(_0x4b27b5){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20START\x20(%s)\x20block',_0x4b27b5[_0x6e4c('0x36')]));this[_0x6e4c('0x35')]['noop'](_0x6e4c('0x194'));if(_0x4b27b5[_0x6e4c('0xa5')]==='yes'){this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0x195'));return this[_0x6e4c('0x35')]['answer']();}return this['channel'][_0x6e4c('0xaa')]('Skipped\x20Answer');};AGIVertices['prototype'][_0x6e4c('0x196')]=function(_0x2a5011){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20SUBPROJECT\x20(%s)\x20block',_0x2a5011[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x2a5011[_0x6e4c('0x197')])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x2a5011,_0x6e4c('0x198'));}var _0x430e82=this['getSquareProject'][_0x6e4c('0x71')](this,_0x2a5011[_0x6e4c('0x197')]);if(!this[_0x6e4c('0xa3')](_0x430e82)){return this['channel'][_0x6e4c('0x2d')](_0x2a5011,util['format'](_0x6e4c('0x199'),_0x2a5011[_0x6e4c('0x197')]));}if(_0x430e82===this[_0x6e4c('0x35')][_0x6e4c('0x40')]){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x2a5011,_0x6e4c('0x19a'));}this['createSquareDetailsReport'][_0x6e4c('0x71')](this,_0x2a5011,_0x430e82);var _0x482b2e=this[_0x6e4c('0x35')][_0x6e4c('0x5a')](_0x6e4c('0x19b'),util[_0x6e4c('0x57')](_0x6e4c('0x19c'),config[_0x6e4c('0x8')][_0x6e4c('0x17e')]||'127.0.0.1',_0x430e82,this[_0x6e4c('0x35')]['arg_1']));if(_0x482b2e[_0x6e4c('0x9e')]===-0x1){return _0x482b2e;}return this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0xae'),'AGI',_0x430e82));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x19d')]=function(_0x129fc1){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0x19e'),_0x129fc1['label']));var _0x38e4f7=this['shellCommand']['sync'](this,_0x129fc1[_0x6e4c('0x19f')]);this[_0x6e4c('0xa1')][_0x6e4c('0x71')](this,_0x129fc1,_0x129fc1[_0x6e4c('0x19f')]);if(this['isConfigured'](_0x129fc1[_0x6e4c('0xca')])){var _0xb20a2a=this[_0x6e4c('0x11')]['sync'](this,_0x129fc1['variable_id']);if(_0xb20a2a){this['channel'][_0x6e4c('0x9a')](_0xb20a2a,_0x38e4f7);return this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')](_0x6e4c('0x1a0'),_0x129fc1['command'],_0xb20a2a));}}return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x1a1'),_0x129fc1['command']));};AGIVertices[_0x6e4c('0x16')]['google_cloud_tts']=function(_0x225a65){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x1a2'),_0x225a65['label']));if(!this[_0x6e4c('0xa3')](_0x225a65[_0x6e4c('0x1a3')])){return this[_0x6e4c('0x35')]['noop'](_0x6e4c('0x1a4'));}if(!this[_0x6e4c('0xa3')](_0x225a65[_0x6e4c('0x5f')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')](_0x6e4c('0xb6'));}this[_0x6e4c('0x35')]['noop'](util[_0x6e4c('0x57')](_0x6e4c('0x1a5'),_0x225a65['text']));var _0x367ec3=this[_0x6e4c('0x5d')][_0x6e4c('0x71')](this,_0x225a65);if(_0x367ec3){this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util[_0x6e4c('0x57')]('Google\x20Cloud\x20TTS\x20%s\x20file\x20created',_0x367ec3));var _0x34cf2c=this[_0x6e4c('0x35')][_0x6e4c('0xeb')](_0x367ec3);try{fs[_0x6e4c('0xec')](_0x367ec3+_0x6e4c('0x13b'));}catch(_0x1d969a){logger['error'](_0x1d969a);}return _0x34cf2c;}return this['channel'][_0x6e4c('0x2d')](_0x225a65,_0x6e4c('0x1a6'));};AGIVertices['prototype'][_0x6e4c('0x1a7')]=function(_0x5380a7){logger['info'](util['format']('Enter\x20in\x20GOOGLETTS\x20(%s)\x20block',_0x5380a7[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x5380a7[_0x6e4c('0x5f')])){return this[_0x6e4c('0x35')][_0x6e4c('0xaa')]('no\x20text\x20configured');}this['channel'][_0x6e4c('0xaa')](util[_0x6e4c('0x57')](_0x6e4c('0x1a8'),_0x5380a7[_0x6e4c('0x5f')]));var _0x3fe44f=this[_0x6e4c('0x63')][_0x6e4c('0x71')](this,_0x5380a7);if(_0x3fe44f){this[_0x6e4c('0x35')][_0x6e4c('0xaa')](util['format'](_0x6e4c('0x1a9'),_0x3fe44f));var _0x3cf905=this[_0x6e4c('0x35')]['streamFile'](_0x3fe44f);try{fs[_0x6e4c('0xec')](_0x3fe44f+'.wav');}catch(_0x4f06bb){logger['error'](_0x4f06bb);}return _0x3cf905;}return this[_0x6e4c('0x35')]['error'](_0x5380a7,_0x6e4c('0x1aa'));};AGIVertices['prototype'][_0x6e4c('0x1ab')]=function(_0x130808){logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0x1ac'),_0x130808[_0x6e4c('0x36')]));if(!this[_0x6e4c('0xa3')](_0x130808['findBy'])){return this['channel'][_0x6e4c('0x2d')](_0x130808,_0x6e4c('0x143'));}logger['info'](util[_0x6e4c('0x57')]('FIND\x20AGENT\x20%s\x20BY\x20%s',this['channel']['callerid'],_0x130808[_0x6e4c('0x13e')]));var _0x44ed21=this[_0x6e4c('0x53')]['sync'](this,_0x130808['findBy']);if(_0x44ed21){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x13f'),this['channel'][_0x6e4c('0x3a')],_0x130808[_0x6e4c('0x13e')]));this[_0x6e4c('0x35')]['noop'](util['format']('AGENT\x20%s\x20FOUND\x20BY',this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0x130808[_0x6e4c('0x13e')]));return{'code':0xc8,'result':_0x6e4c('0x140')};}else{logger[_0x6e4c('0x2e')](util['format'](_0x6e4c('0x141'),this[_0x6e4c('0x35')]['callerid'],_0x130808[_0x6e4c('0x13e')]));this['channel']['noop'](util['format'](_0x6e4c('0x141'),this[_0x6e4c('0x35')][_0x6e4c('0x3a')],_0x130808[_0x6e4c('0x13e')]));return{'code':0xc8,'result':_0x6e4c('0x14f')};}};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x1ad')]=function(_0x9c1d38){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')](_0x6e4c('0x1ae'),_0x9c1d38[_0x6e4c('0x36')]));var _0x4cd00f=this[_0x6e4c('0x35')][_0x6e4c('0x5a')](_0x6e4c('0x1af'),[_0x9c1d38[_0x6e4c('0x1b0')],_0x9c1d38[_0x6e4c('0xaf')]]);if(_0x4cd00f[_0x6e4c('0x9e')]===-0x1){return _0x4cd00f;}return this[_0x6e4c('0x35')]['noop'](util['format']('Executed\x20command\x20%s\x20%s','VOICEMAIL',_0x9c1d38['mailbox']));};AGIVertices[_0x6e4c('0x16')][_0x6e4c('0x1b1')]=function(_0x208c77){logger[_0x6e4c('0x2e')](util[_0x6e4c('0x57')]('Enter\x20in\x20SWITCH\x20(%s)\x20block',_0x208c77['label']));if(!this[_0x6e4c('0xa3')](_0x208c77[_0x6e4c('0xca')])){return this[_0x6e4c('0x35')][_0x6e4c('0x2d')](_0x208c77,'no\x20variable\x20selected');}var _0x9015ba=this[_0x6e4c('0x11')][_0x6e4c('0x71')](this,_0x208c77[_0x6e4c('0xca')]);if(!_0x9015ba){return this['channel'][_0x6e4c('0x2d')](_0x208c77,_0x6e4c('0xcc'));}var _0x19ce22=this['channel'][_0x6e4c('0x11')](_0x9015ba);return{'code':0xc8,'result':_0x19ce22[_0x6e4c('0x9f')]?_0x19ce22[_0x6e4c('0x9f')]:'-'};};String['prototype'][_0x6e4c('0x1b2')]=function(_0x522e31,_0x50b5c1){return this[_0x6e4c('0x9c')](_0x522e31)['join'](_0x50b5c1);};module['exports']=AGIVertices;