1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
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. *
17 // *************************************************************************
18 var _0xbbb7=['disposition','duration','billableseconds','GetVoiceCallReports','moment','lodash','create','Request','merge','calleridnum','callerid','CreateVoiceCallReport','getVoiceCallReports','GetVoiceCallReport','outbound','startOf','day','YYYY-MM-DD\x20HH:mm:ss','endOf','format','type'];(function(_0x15eb63,_0xd3f629){var _0x19fc81=function(_0x4ddaec){while(--_0x4ddaec){_0x15eb63['push'](_0x15eb63['shift']());}};_0x19fc81(++_0xd3f629);}(_0xbbb7,0x13f));var _0x7bbb=function(_0x28ec29,_0x38469d){_0x28ec29=_0x28ec29-0x0;var _0x299910=_0xbbb7[_0x28ec29];return _0x299910;};'use strict';var moment=require(_0x7bbb('0x0'));var util=require('util');var _=require(_0x7bbb('0x1'));var client=require('../client');exports[_0x7bbb('0x2')]=function(_0x2add0e){return client[_0x7bbb('0x3')]('CreateVoiceCallReport',{'body':_[_0x7bbb('0x4')](_0x2add0e,{'source':_0x2add0e[_0x7bbb('0x5')],'destinationcontext':_0x2add0e['context'],'callerid':_0x2add0e[_0x7bbb('0x6')],'amaflags':'DOCUMENTATION'}),'log':_0x7bbb('0x7')});};exports[_0x7bbb('0x8')]=function(){return function(){return client['Request'](_0x7bbb('0x9'),{'options':{'where':{'type':[_0x7bbb('0xa')],'createdAt':{'$between':[moment()[_0x7bbb('0xb')](_0x7bbb('0xc'))['format'](_0x7bbb('0xd')),moment()[_0x7bbb('0xe')](_0x7bbb('0xc'))[_0x7bbb('0xf')](_0x7bbb('0xd'))]}},'attributes':[_0x7bbb('0x10'),_0x7bbb('0x11'),_0x7bbb('0x12'),_0x7bbb('0x13')]},'log':_0x7bbb('0x14')});};};