6c08e67dae504e3506a59e984083ab836703c462
[motion-next.git] / server / services / ami / rpc / voiceCallReport.js
1 const a1124_0x3818=['type','endOf','YYYY-MM-DD\x20HH:mm:ss','GetVoiceCallReport','../client','outbound','day','context','create','DOCUMENTATION','Request','startOf','GetVoiceCallReports','getVoiceCallReports','disposition','duration','CreateVoiceCallReport','moment','callerid'];(function(_0x15857a,_0x381858){const _0x13eb20=function(_0xde1f5b){while(--_0xde1f5b){_0x15857a['push'](_0x15857a['shift']());}};_0x13eb20(++_0x381858);}(a1124_0x3818,0x1d9));const a1124_0x13eb=function(_0x15857a,_0x381858){_0x15857a=_0x15857a-0x0;let _0x13eb20=a1124_0x3818[_0x15857a];return _0x13eb20;};const _0x2922a2=a1124_0x13eb;'use strict';const moment=require(_0x2922a2('0x0')),_=require('lodash'),client=require(_0x2922a2('0x6'));exports[_0x2922a2('0xa')]=function(_0xde1f5b){const _0x11461b=_0x2922a2;return client[_0x11461b('0xc')](_0x11461b('0x12'),{'body':_['merge'](_0xde1f5b,{'source':_0xde1f5b['calleridnum'],'destinationcontext':_0xde1f5b[_0x11461b('0x9')],'callerid':_0xde1f5b[_0x11461b('0x1')],'amaflags':_0x11461b('0xb')}),'log':_0x11461b('0x12')});},exports[_0x2922a2('0xf')]=function(){return function(){const _0x1fe2cc=a1124_0x13eb;return client[_0x1fe2cc('0xc')](_0x1fe2cc('0x5'),{'options':{'where':{'type':[_0x1fe2cc('0x7')],'createdAt':{'$between':[moment()[_0x1fe2cc('0xd')](_0x1fe2cc('0x8'))['format']('YYYY-MM-DD\x20HH:mm:ss'),moment()[_0x1fe2cc('0x3')]('day')['format'](_0x1fe2cc('0x4'))]}},'attributes':[_0x1fe2cc('0x2'),_0x1fe2cc('0x10'),_0x1fe2cc('0x11'),'billableseconds']},'log':_0x1fe2cc('0xe')});};};