UNPKG

@taazkareem/clickup-mcp-server

Version:

ClickUp MCP Server - Powering AI Agents with full ClickUp task, document, and chat management capabilities.

1 lines 40.6 kB
const a0_0x1553b4=a0_0x2673;function a0_0x2673(_0x2e937c,_0x5bb7e3){_0x2e937c=_0x2e937c-0x70;const _0x2a8d2c=a0_0x2a8d();let _0x2673c1=_0x2a8d2c[_0x2e937c];if(a0_0x2673['UJmxaA']===undefined){var _0x585ac6=function(_0x1c4f76){const _0x45c85b='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x4c2a46='',_0x59c492='';for(let _0x42d50e=0x0,_0x44e972,_0x41020c,_0x4678fa=0x0;_0x41020c=_0x1c4f76['charAt'](_0x4678fa++);~_0x41020c&&(_0x44e972=_0x42d50e%0x4?_0x44e972*0x40+_0x41020c:_0x41020c,_0x42d50e++%0x4)?_0x4c2a46+=String['fromCharCode'](0xff&_0x44e972>>(-0x2*_0x42d50e&0x6)):0x0){_0x41020c=_0x45c85b['indexOf'](_0x41020c);}for(let _0x59bb1c=0x0,_0x1359c3=_0x4c2a46['length'];_0x59bb1c<_0x1359c3;_0x59bb1c++){_0x59c492+='%'+('00'+_0x4c2a46['charCodeAt'](_0x59bb1c)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x59c492);};a0_0x2673['LvtbGN']=_0x585ac6,a0_0x2673['samxIg']={},a0_0x2673['UJmxaA']=!![];}const _0x1827b7=_0x2a8d2c[0x0],_0x425d34=_0x2e937c+_0x1827b7,_0x1fc5a7=a0_0x2673['samxIg'][_0x425d34];return!_0x1fc5a7?(_0x2673c1=a0_0x2673['LvtbGN'](_0x2673c1),a0_0x2673['samxIg'][_0x425d34]=_0x2673c1):_0x2673c1=_0x1fc5a7,_0x2673c1;}(function(_0x4947ec,_0x5bfd6e){const _0xcf9c5e=a0_0x2673,_0x1c495a=_0x4947ec();while(!![]){try{const _0x40d33a=-parseInt(_0xcf9c5e(0xf3))/0x1*(-parseInt(_0xcf9c5e(0x139))/0x2)+parseInt(_0xcf9c5e(0x92))/0x3*(parseInt(_0xcf9c5e(0x84))/0x4)+parseInt(_0xcf9c5e(0x7f))/0x5*(parseInt(_0xcf9c5e(0xca))/0x6)+-parseInt(_0xcf9c5e(0xd3))/0x7*(-parseInt(_0xcf9c5e(0x8f))/0x8)+parseInt(_0xcf9c5e(0x14a))/0x9+-parseInt(_0xcf9c5e(0xe5))/0xa*(-parseInt(_0xcf9c5e(0x75))/0xb)+-parseInt(_0xcf9c5e(0x1b9))/0xc;if(_0x40d33a===_0x5bfd6e)break;else _0x1c495a['push'](_0x1c495a['shift']());}catch(_0x5126e3){_0x1c495a['push'](_0x1c495a['shift']());}}}(a0_0x2a8d,0xab74e));import{BaseClickUpService,ErrorCode,ClickUpServiceError}from'../base.js';function a0_0x2a8d(){const _0x26595d=['yxrLzee','AxrLBxm','zxjYB3i','vw5Qwui','DhvZ','zgvFBwe','rNjVBvu','zMLLBgq','igL0zw0','C3rfEgK','BfrHC2S','AKLOr3K','yKHyzfq','rNLktfO','B25Zzsa','vu5ltK8','C3rYAw4','BwfRzvi','DgfZA0K','BgvHCMu','Axb0Aw8','AgfUzgW','zwqGkfa','CgvZ','zxn0Aw0','zsb0yxm','Aw5MBW','C2TcEum','ig1VDMu','Dxn0B20','zw50CMK','yxnZAwC','igzYB20','y3vZDg8','uKfor0u','zuLK','C3rZ','B0zcsNu','Cg9ZDa','AxrOigm','BM93','Axn0igK','yMfZzvu','l2f0Dge','zM9Yrwe','z2XXvem','rcbHBMq','Dg9mB3C','Chv0','zvrHC2S','CYbMB3i','uNn4yLK','tgLZDca','DMfSDwu','C3rHCNq','DgfZAYa','BL9Kzxm','DxbSB2e','Axn0','tM9Ulwq','Axr5','l21LBwi','BM9YBwe','yxrPB24','vejprge','yxbWzw4','l2j1BgS','vhblvfu','zcb0BYa','vgfZA04','B3iGDge','A190Exa','DgfZAW','vgfZA0y','CZ10CNu','ug90zw4','Aw1PDcK','AxfTr0y','BNrZlMO','C2TbDhq','yw1Lvg8','ihrHC2S','u3rHDhu','Bv9Pza','zxb0igm','DgL0Bgu','CMvTB3y','z2v0igm','x2LK','AcbHBgW','ihrVigW','BwfW','CgfJzvm','y2f0zsa','DgfNCW','y3jPChq','yKLozu8','ihjLC3a','DhrHy2G','Bg9Nt3a','C2TuAw0','CMTKB3C','q0fdseu','BNrZ','yxnRvhK','z2v0ihm','y2f0y2G','Axn0ici','tK9ux0y','ndmZmZeWmdrqtufbD3q','DMfSAwq','B3Dezxm','rNLAC2m','Bwf0y2G','rerftG','x1ruta','yxbPs2u','BMvLCW','Aw1LigK','ALbpDKm','ExbLCW','BhvL','zunOzwm','odm1nJm3AvzLwujb','zxf1zxm','r2Llq2q','AxbSzsa','zxj2Awm','BgTuyxm','Bg9Nz2u','y3rPDMu','rMfPBgu','Dw5Yzxm','ndG5mti1nu9Yu3rMtq','C2TfEgK','BwvUDhm','zwrPDem','BffSD3m','mtu0mtuYnhLpvhPWva','iIbMB3i','rgf0yq','AxrLBq','lI90yxm','Bv9MAwu','lI4Vy3u','B25Zzq','zxH0CMe','zM91BMq','x2rHDgu','oej3AhvVza','ywnOBwu','Aw9U','m25ptgfbBa','CMvJCMu','C2v0','BgLZDfm','yxrLtgK','vMfSDwu','l2n1C3q','zNL2r1O','Dg9Y','DgHLBG','z2v0ige','z2v0vge','suqGDxa','B3bLCMe','q2fJAgu','A0rHDge','zwjus2i','v2zxANy','BNbvAvy','ihrLEhq','C2vZ','DxbKyxq','ChjVEhK','yMvYCW','iIbMB3u','y2HL','ig5VDca','y3ruyxm','tLLMtMS','AxzLrMe','CYb3Axq','ignOzwm','l3rLyw0','Dhj1y3q','DwXRihq','DwuU','ChjPB3i','C3bSAxq','DxjS','C3rHDhu','yxnRia','yw1IAwC','B25L','yxnRCZ0','C3rVBvq','yxrL','y2fJAgu','BwvZC2e','wMn3tvu','D29YA3m','zhvLx2q','zgvFC3u','zgf0yq','CMvZB2W','BMvL','zvrLyw0','nNrNBvnlAa','zsaI','zgvZ','BgrZ','zgvZy3i','Dgf0Dxm','BgLZDhm','C2TZ','y3rqCMK','odu2odiWm2jyvgfnDq','BgL6zvm','l3rHC2S','rNjVBuW','ChvZAa','wurqzg8','ywrKihq','ugfYyw0','yxrLigm','DgvHBuK','B29SCY8','DgLTzv8','ywXS','BgXIywm','A1rPBwu','y29Kzq','x2LUx3m','rxHZDwe','mtbSC1H1y3K','Esb3Axq','yxrLvge','q0X1A0K','CfrHC2S','B3nrv3C','AgLptMq','Dhj1zsy','BgvUz3q','AY1JAgu','z2LMEq','qLbeDeO','DhvZigy','B21FAxq','otL6r0LywfC','zxjdyxm','BMqGAw4','z2v0q3u','AgvJA2W','z2v0ig0','yNvPBgq','x3rPBwu','y3rezwu','DgLTzxO','Axn0ia','C3vIDge','sxrLBq','wKTjqLq','BMfTzq','AZOGDhi','Aw5JBhu','A3mGzM8','zxjHDgK','vw5LEha','igzHAwW','yxnR','Bv9PDgu','yxr1CW','Dhj1zq','igLUifq','C2v0rMK','zfrHC2S','A2XPC3q','C3vJy2u','DMvK','rK9sqKK','l3rPBwu','Bw92zsa','AY1HDhq','ugDAtK8','BgLZDa','B0LKq2e','DwL0EtO','zgvSzxq','DgfZA3m','C2TuExa','AxnbCNi','ie11Bhq','C2TuB0W','DxrPBgK','ihr5Cgu','DgfZAY8','Bw92zvq','Ag1LBNq','AgfUz2u','zhvWBgK','zw1Izxi','yLruChy','t1vora','z2v0','zuvYCM8','z2v0tgK','CIb0yxm','ieLeia','z2v0ihq','Bv90yxm','zMLSDgu','yNrHC2S','nhWWFdi','y2TSAxm','BgfUigW','B3jPDhK','igXPC3q','zgf0zwq','mJi5ntbHzM5QvM0','y2XPzw4','yxnRihC','yxnRieK','zxrZ','ywrKvge','C2Tnzw0','y2XLyxi','y3jLyxq','l2XPC3q','AwX0zxi','y2HLy2S','C3rVBs0','Axn0sxq','zsbZDwi','tLLvtu4','zwn0zwq','ndyYmtK1mfDiq05isW','BMfTzvq'];a0_0x2a8d=function(){return _0x26595d;};return a0_0x2a8d();}import{ListService}from'../list.js';import{findBestMatchInArray}from'../../../utils/resolver-utils.js';import a0_0x4d3499 from'qs';export class TaskServiceCore extends BaseClickUpService{constructor(_0x51b461,_0x57b002,_0x525990,_0x42390f,_0x17612b,_0x27b7fb){const _0x590bb4=a0_0x2673;super(_0x51b461,_0x57b002,_0x525990,_0x27b7fb),this[_0x590bb4(0xc3)+'paceS'+_0x590bb4(0x79)+'e']=null,this[_0x590bb4(0x1ba)+'ation'+'Cache']={'tasks':new Map(),'lists':new Map(),'taskTypes':new Map()},this[_0x590bb4(0x14b)+'oIdCa'+_0x590bb4(0xab)]=new Map(),this['CACHE'+_0x590bb4(0x1bf)]=0x5*0x3c*0x3e8,_0x42390f&&(this['works'+_0x590bb4(0x1a8)+_0x590bb4(0x79)+'e']=_0x42390f),this[_0x590bb4(0x95)+_0x590bb4(0x79)+'e']=_0x17612b||new ListService(_0x51b461,_0x57b002,_0x525990,this[_0x590bb4(0xc3)+_0x590bb4(0x1a8)+_0x590bb4(0x79)+'e']);}['updat'+a0_0x1553b4(0xc9)+'Id'](_0x4fd670){const _0x5a5961=a0_0x1553b4,_0x1b6cd7=(_0x5a5961(0x133)+'|1|3')[_0x5a5961(0xb7)]('|');let _0x29033a=0x0;while(!![]){switch(_0x1b6cd7[_0x29033a++]){case'0':this[_0x5a5961(0x1ba)+_0x5a5961(0x18b)+_0x5a5961(0xa0)][_0x5a5961(0x11b)][_0x5a5961(0x140)]();continue;case'1':this['nameT'+_0x5a5961(0x118)+_0x5a5961(0xab)]['clear']();continue;case'2':this['valid'+'ation'+'Cache'][_0x5a5961(0xd0)]['clear']();continue;case'3':this[_0x5a5961(0x7b)+'r'][_0x5a5961(0x166)]('Team\x20'+_0x5a5961(0x9e)+_0x5a5961(0x138)+',\x20tas'+'k\x20cac'+'hes\x20c'+_0x5a5961(0x15f)+'d',{'teamId':_0x4fd670});continue;case'4':super[_0x5a5961(0xa7)+_0x5a5961(0xc9)+'Id'](_0x4fd670);continue;}break;}}['build'+a0_0x1553b4(0x195)+a0_0x1553b4(0x143)+a0_0x1553b4(0xda)+'s'](_0x5cd670){const _0x1bfa93=a0_0x1553b4,_0x28a070={'npUiV':'brack'+_0x1bfa93(0x13d),'GiKCd':function(_0x130b8b,_0x3d8aa8){return _0x130b8b>_0x3d8aa8;},'JdwDI':_0x1bfa93(0x16e),'glqTC':function(_0x3f0a10,_0x59923e){return _0x3f0a10===_0x59923e;}},_0xf84d01={};for(const [_0x483402,_0x5dcb13]of Object[_0x1bfa93(0x16a)+'es'](_0x5cd670)){_0x5dcb13!==undefined&&_0x5dcb13!==null&&(_0xf84d01[_0x483402]=_0x5dcb13);}_0xf84d01[_0x1bfa93(0x103)+_0x1bfa93(0x151)+_0x1bfa93(0x1b1)+'n_des'+_0x1bfa93(0x1ab)+'ion']&&(_0xf84d01['inclu'+'de_ma'+_0x1bfa93(0x1b1)+_0x1bfa93(0x184)+_0x1bfa93(0x1ab)+'ion']=_0x1bfa93(0x10b));const _0x5120b9=_0xf84d01[_0x1bfa93(0x16d)+_0x1bfa93(0x89)+'lds'];delete _0xf84d01[_0x1bfa93(0x16d)+_0x1bfa93(0x89)+_0x1bfa93(0xcd)];const _0x3993b2=a0_0x4d3499[_0x1bfa93(0x15c)+_0x1bfa93(0xef)](_0xf84d01,{'arrayFormat':_0x28a070[_0x1bfa93(0xa4)],'skipNulls':!![]}),_0x1726e8=new URLSearchParams(_0x3993b2);if(Array[_0x1bfa93(0x11d)+'ay'](_0x5120b9)&&_0x28a070[_0x1bfa93(0x77)](_0x5120b9['lengt'+'h'],0x0)){const _0x4aa228=[];for(const _0x3a39a1 of _0x5120b9){_0x3a39a1[_0x1bfa93(0x9f)+_0x1bfa93(0x9a)]===_0x28a070['JdwDI']&&Array[_0x1bfa93(0x11d)+'ay'](_0x3a39a1[_0x1bfa93(0x181)])&&_0x28a070[_0x1bfa93(0x179)](_0x3a39a1[_0x1bfa93(0x181)][_0x1bfa93(0xed)+'h'],0x2)?(_0x4aa228[_0x1bfa93(0xd7)]({'field_id':_0x3a39a1[_0x1bfa93(0x153)+_0x1bfa93(0x1a4)],'operator':'>=','value':_0x3a39a1['value'][0x0]}),_0x4aa228[_0x1bfa93(0xd7)]({'field_id':_0x3a39a1[_0x1bfa93(0x153)+_0x1bfa93(0x1a4)],'operator':'<=','value':_0x3a39a1[_0x1bfa93(0x181)][0x1]})):_0x4aa228[_0x1bfa93(0xd7)](_0x3a39a1);}_0x1726e8[_0x1bfa93(0x18d)+'d'](_0x1bfa93(0x16d)+_0x1bfa93(0x89)+'lds',JSON['strin'+'gify'](_0x4aa228));}return _0x1726e8;}async['extra'+a0_0x1553b4(0xfb)+a0_0x1553b4(0xe9)+a0_0x1553b4(0x86)](_0xff38b2){const _0xeaeecb=a0_0x1553b4,_0x8f56bb={'bINeO':function(_0x586ff7,_0x11421b){return _0x586ff7>_0x11421b;}},_0x35072b=await this[_0xeaeecb(0x9d)+'sk'](_0xff38b2),_0x2b66ef=this[_0xeaeecb(0x8c)+_0xeaeecb(0xad)+_0xeaeecb(0xa1)](_0x35072b),_0x4b73da=await this['getSu'+_0xeaeecb(0x132)+'s'](_0xff38b2);_0x8f56bb[_0xeaeecb(0x1ac)](_0x4b73da[_0xeaeecb(0xed)+'h'],0x0)&&(_0x2b66ef[_0xeaeecb(0xfe)+'sks']=await Promise[_0xeaeecb(0xdf)](_0x4b73da['map'](_0x3537ac=>this[_0xeaeecb(0x8c)+_0xeaeecb(0xfb)+'pTask'+'Data'](_0x3537ac['id']))));_0x35072b[_0xeaeecb(0x144)+'lists']?.[_0xeaeecb(0xed)+'h']&&(_0x2b66ef[_0xeaeecb(0x144)+_0xeaeecb(0xd0)]=_0x35072b[_0xeaeecb(0x144)+_0xeaeecb(0xd0)]['map'](_0x1558e8=>({'name':_0x1558e8[_0xeaeecb(0x101)],'items':_0x1558e8[_0xeaeecb(0x14d)][_0xeaeecb(0x1a7)](_0xe50334=>({'name':_0xe50334[_0xeaeecb(0x101)],'resolved':_0xe50334[_0xeaeecb(0xc7)+_0xeaeecb(0x111)],'assignee':_0xe50334[_0xeaeecb(0x16b)+_0xeaeecb(0xc8)]?.['id']}))})));const _0x3dc701=await this['getTa'+'skAtt'+_0xeaeecb(0x90)+_0xeaeecb(0x1b3)](_0xff38b2);return _0x3dc701[_0xeaeecb(0xed)+'h']>0x0&&(_0x2b66ef['attac'+'hment'+'s']=_0x3dc701[_0xeaeecb(0x1a7)](_0x4a5a20=>({'url':_0x4a5a20['url'],'title':_0x4a5a20[_0xeaeecb(0x1a1)]}))),_0x2b66ef;}async[a0_0x1553b4(0x9d)+a0_0x1553b4(0x19b)+a0_0x1553b4(0x90)+a0_0x1553b4(0x1b3)](_0x1581fb){const _0xb16e3d=a0_0x1553b4;return this[_0xb16e3d(0x15d)+'eques'+'t'](async()=>{const _0x4fdf2e=_0xb16e3d,_0x13944a=await this[_0x4fdf2e(0x13a)+'t']['get'](_0x4fdf2e(0xd5)+'/'+_0x1581fb+(_0x4fdf2e(0x177)+'chmen'+'t')),_0x152f3b=_0x13944a[_0x4fdf2e(0xc6)];return _0x152f3b['attac'+'hment'+'s']||[];})[_0xb16e3d(0x1b6)](_0x33615f=>{const _0xbaafc5=_0xb16e3d;return this[_0xbaafc5(0x7b)+'r'][_0xbaafc5(0x14e)](_0xbaafc5(0x7d)+_0xbaafc5(0x190)+_0xbaafc5(0x9c)+_0xbaafc5(0x1ae)+_0xbaafc5(0x81)+'\x20for\x20'+'task\x20'+_0x1581fb,_0x33615f),[];});}['extra'+a0_0x1553b4(0xad)+a0_0x1553b4(0xa1)](_0x5d8f54,_0x51c018){const _0x5df250=a0_0x1553b4,_0xc927dd={'lQlws':function(_0x1bb6c6,_0x281632){return _0x1bb6c6(_0x281632);}},_0x293b12={'name':_0x51c018||_0x5d8f54['name'],'description':_0x5d8f54[_0x5df250(0xce)+_0x5df250(0x160)+'n']||'','status':_0x5d8f54[_0x5df250(0xb9)+'s']?.[_0x5df250(0xb9)+'s'],'priority':this[_0x5df250(0x8c)+_0x5df250(0xd2)+_0x5df250(0x136)+'Value'](_0x5d8f54),'due_date':_0x5d8f54[_0x5df250(0xc4)+'ate']?_0xc927dd[_0x5df250(0x83)](Number,_0x5d8f54[_0x5df250(0xc4)+_0x5df250(0xbf)]):undefined,'assignees':_0x5d8f54[_0x5df250(0x16b)+_0x5df250(0x1c1)]?.[_0x5df250(0x1a7)](_0x3b78f4=>_0x3b78f4['id'])||[],'tags':_0x5d8f54[_0x5df250(0x1aa)]?.[_0x5df250(0x1a7)](_0x3dff69=>_0x3dff69['name'])||[],'time_estimate':_0x5d8f54[_0x5df250(0xde)+_0x5df250(0x164)+'ate']||undefined,'start_date':_0x5d8f54[_0x5df250(0x182)+'_date']?Number(_0x5d8f54[_0x5df250(0x182)+_0x5df250(0x8e)]):undefined};if(Array[_0x5df250(0x11d)+'ay'](_0x5d8f54[_0x5df250(0x16d)+_0x5df250(0x89)+_0x5df250(0xcd)])){const _0x426009=_0x5d8f54[_0x5df250(0x16d)+'m_fie'+'lds'][_0x5df250(0x131)+'r'](_0x4275a4=>_0x4275a4[_0x5df250(0x181)]!==undefined&&_0x4275a4['value']!==null)['map'](_0x1e8e08=>({'id':_0x1e8e08['id'],'value':_0x1e8e08[_0x5df250(0x181)]}));_0x426009[_0x5df250(0xed)+'h']>0x0&&(_0x293b12['custo'+_0x5df250(0x89)+_0x5df250(0xcd)]=_0x426009);}return _0x293b12;}['extra'+a0_0x1553b4(0xd2)+a0_0x1553b4(0x136)+a0_0x1553b4(0x97)](_0x1a4ffc){const _0x1f7fdf=a0_0x1553b4,_0x343f68={'jPOvC':function(_0x3dbcd9,_0x1d4a7e){return _0x3dbcd9(_0x1d4a7e);},'TpKTU':function(_0x2db555,_0x4a6fe8){return _0x2db555<_0x4a6fe8;},'CLukI':function(_0x571c97,_0x29d027){return _0x571c97>_0x29d027;}};if(!_0x1a4ffc[_0x1f7fdf(0xb6)+_0x1f7fdf(0x188)]||!_0x1a4ffc[_0x1f7fdf(0xb6)+_0x1f7fdf(0x188)]['id'])return null;const _0x2864d8=_0x343f68[_0x1f7fdf(0x71)](parseInt,_0x1a4ffc[_0x1f7fdf(0xb6)+_0x1f7fdf(0x188)]['id']);return isNaN(_0x2864d8)||_0x343f68[_0x1f7fdf(0x18f)](_0x2864d8,0x1)||_0x343f68[_0x1f7fdf(0xe8)](_0x2864d8,0x4)?null:_0x2864d8;}async[a0_0x1553b4(0xf6)+a0_0x1553b4(0xbe)+a0_0x1553b4(0x1b4)+a0_0x1553b4(0x163)](_0x37198b=this[a0_0x1553b4(0xdc)+'d']){const _0x228908=a0_0x1553b4,_0x295fd9={'ZKIBT':'Faile'+_0x228908(0x190)+_0x228908(0x1a3)+'ustom'+_0x228908(0x19d)+_0x228908(0x121)+'s'},_0x103e23=this[_0x228908(0x1ba)+_0x228908(0x18b)+'Cache']['taskT'+_0x228908(0x72)][_0x228908(0x12a)](_0x37198b);if(_0x103e23&&Date['now']()-_0x103e23[_0x228908(0x1ba)+'atedA'+'t']<this[_0x228908(0x1b2)+_0x228908(0x1bf)])return _0x103e23['types'];return this['makeR'+'eques'+'t'](async()=>{const _0x4b1595=_0x228908,_0x411cfd=await this[_0x4b1595(0x13a)+'t'][_0x4b1595(0x12a)](_0x4b1595(0xb2)+'/'+_0x37198b+(_0x4b1595(0x98)+_0x4b1595(0xf2)+'em')),_0x439fff=_0x411cfd[_0x4b1595(0xc6)][_0x4b1595(0x16d)+_0x4b1595(0x109)+'ms']||[];return this['valid'+'ation'+_0x4b1595(0xa0)]['taskT'+_0x4b1595(0x72)][_0x4b1595(0x94)](_0x37198b,{'types':_0x439fff,'validatedAt':Date[_0x4b1595(0x174)]()}),_0x439fff;})[_0x228908(0x1b6)](_0x4fe5f4=>{const _0x4fa295=_0x228908;throw this[_0x4fa295(0x161)+_0x4fa295(0x12b)+'r'](_0x4fe5f4,_0x295fd9[_0x4fa295(0x100)]);});}async['getTa'+'skTyp'+a0_0x1553b4(0x16f)](_0x1e376e){const _0x333562=a0_0x1553b4,_0x40c2e3={'uSadK':function(_0x211d79,_0xc1dc1c,_0x1e0747){return _0x211d79(_0xc1dc1c,_0x1e0747);}},_0x4ff603=await this['getCu'+_0x333562(0xbe)+_0x333562(0x1b4)+'pes'](),_0x42d828=_0x4ff603['find'](_0x13c684=>_0x13c684[_0x333562(0x101)]['toLow'+_0x333562(0xf4)+'e']()===_0x1e376e[_0x333562(0x17b)+'erCas'+'e']());if(_0x42d828)return _0x42d828['id'];const _0x3830e9=_0x40c2e3['uSadK'](findBestMatchInArray,_0x4ff603,_0x1e376e);return _0x3830e9?_0x3830e9[_0x333562(0x87)]['id']:null;}async[a0_0x1553b4(0x141)+a0_0x1553b4(0x17d)](_0x1ff6dc,_0x57d5a2){const _0x4e976a=a0_0x1553b4,_0x15b271={'vQMQp':_0x4e976a(0x15c)+'g','FyJLZ':'Unexp'+_0x4e976a(0x149)+_0x4e976a(0xa5)+_0x4e976a(0x1ad)+_0x4e976a(0x15a)+'from\x20'+'API','PgZNO':'creat'+_0x4e976a(0x17d),'ebTKb':function(_0x14a6b4,_0x913c0d){return _0x14a6b4!==_0x913c0d;},'jIhGy':function(_0xef20c3,_0x35cca4){return _0xef20c3(_0x35cca4);},'pKTuj':_0x4e976a(0x88)+_0x4e976a(0x115)+'achme'+_0x4e976a(0x19a)+'s','VgRRT':_0x4e976a(0x7d)+_0x4e976a(0x190)+_0x4e976a(0x141)+_0x4e976a(0x165)+'k'};this[_0x4e976a(0x1af)+_0x4e976a(0x105)+'on'](_0x15b271[_0x4e976a(0x116)],{'listId':_0x1ff6dc,..._0x57d5a2});const {subtasks:_0xd8d222,checklists:_0x507276,attachments:_0x15658f,..._0x4698df}=_0x57d5a2;if(_0x4698df['custo'+_0x4e976a(0x130)+'k_typ'+'e']&&!_0x4698df[_0x4e976a(0x16d)+_0x4e976a(0x109)+_0x4e976a(0x19f)]){const _0x1c03e4=await this['getTa'+_0x4e976a(0x11c)+_0x4e976a(0x16f)](_0x4698df[_0x4e976a(0x16d)+'m_tas'+'k_typ'+'e']);if(_0x15b271[_0x4e976a(0xa2)](_0x1c03e4,null))_0x4698df[_0x4e976a(0x16d)+_0x4e976a(0x109)+_0x4e976a(0x19f)]=_0x1c03e4;}if(_0x4698df['statu'+'s']){await this[_0x4e976a(0x1ba)+_0x4e976a(0x96)+'stExi'+'sts'](_0x1ff6dc)[_0x4e976a(0x1b6)](()=>{});const _0x1dd54d=this[_0x4e976a(0x1ba)+_0x4e976a(0x18b)+_0x4e976a(0xa0)][_0x4e976a(0xd0)][_0x4e976a(0x12a)](_0x1ff6dc);_0x4698df[_0x4e976a(0xb9)+'s']=this[_0x4e976a(0x18a)+_0x4e976a(0xd4)+_0x4e976a(0xcf)](_0x4698df[_0x4e976a(0xb9)+'s'],_0x1dd54d?.[_0x4e976a(0xb9)+_0x4e976a(0xa6)]);}try{const _0x355c0f=await this[_0x4e976a(0x15d)+'eques'+'t'](async()=>{const _0x5d570d=_0x4e976a,{custom_task_type:_0x13b354,..._0x27b257}=_0x4698df,_0x1ef0dd=await this['clien'+'t'][_0x5d570d(0x172)](_0x5d570d(0x142)+'/'+_0x1ff6dc+'/task',_0x27b257),_0x475515=_0x1ef0dd[_0x5d570d(0xc6)];if(typeof _0x475515===_0x15b271['vQMQp']){const _0x2ec019=_0x475515[_0x5d570d(0x1bd)](/task.*?(\w{9,10})/i);if(_0x2ec019)return await this[_0x5d570d(0x9d)+'sk'](_0x2ec019[0x1]);throw new ClickUpServiceError(_0x15b271[_0x5d570d(0x159)],ErrorCode[_0x5d570d(0x15b)+'WN'],_0x475515);}if(_0x475515?.[_0x5d570d(0xb9)+'s']&&_0x475515[_0x5d570d(0x117)]?.['id'])this['cache'+_0x5d570d(0x19e)+'s'](_0x475515[_0x5d570d(0x117)]['id'],_0x475515[_0x5d570d(0xb9)+'s'][_0x5d570d(0xb9)+'s']);return _0x475515;});if(_0x507276?.[_0x4e976a(0xed)+'h']){const {TaskChecklistsService:_0x5ddf79}=await import(_0x4e976a(0x88)+_0x4e976a(0xee)+_0x4e976a(0x134)+'ts.js'),_0x109773=new _0x5ddf79(this);for(const _0x1ffd0c of _0x507276){try{const _0x31a0ff=await _0x109773['creat'+_0x4e976a(0x74)+_0x4e976a(0x10f)](_0x355c0f['id'],_0x1ffd0c[_0x4e976a(0x101)]);if(_0x31a0ff[_0x4e976a(0x110)+'ss']&&_0x31a0ff[_0x4e976a(0xc6)]){const _0x1eaa60=_0x31a0ff[_0x4e976a(0xc6)]['id'];for(const _0x25a2f3 of _0x1ffd0c['items']){try{const _0x2840a6=await _0x109773[_0x4e976a(0x141)+_0x4e976a(0x74)+_0x4e976a(0x10f)+_0x4e976a(0xff)](_0x1eaa60,_0x25a2f3[_0x4e976a(0x101)],_0x25a2f3[_0x4e976a(0x16b)+_0x4e976a(0xc8)]);if(_0x2840a6['succe'+'ss']&&_0x2840a6[_0x4e976a(0xc6)]&&_0x25a2f3['resol'+_0x4e976a(0x111)]){const _0x7df9ca=_0x2840a6[_0x4e976a(0xc6)][_0x4e976a(0x14d)][_0x4e976a(0x131)+'r'](_0x322f1c=>_0x322f1c['name']===_0x25a2f3[_0x4e976a(0x101)]&&!_0x322f1c[_0x4e976a(0xc7)+_0x4e976a(0x111)]);_0x7df9ca[_0x4e976a(0xed)+'h']>0x1&&this[_0x4e976a(0x7b)+'r']['warn'](_0x4e976a(0x197)+'tial\x20'+_0x4e976a(0xbb)+_0x4e976a(0x119)+_0x4e976a(0x11e)+_0x4e976a(0x78)+_0x4e976a(0x7e)+'olved'+'\x20chec'+_0x4e976a(0x10f)+_0x4e976a(0x154)+_0x4e976a(0xb0)+'h\x20nam'+_0x4e976a(0xcb)+_0x25a2f3[_0x4e976a(0x101)]+(_0x4e976a(0xaa)+_0x4e976a(0xf5)+'\x20chec'+_0x4e976a(0x10f)+'\x20\x22')+_0x1ffd0c[_0x4e976a(0x101)]+'\x22.',{'checklistId':_0x1eaa60,'itemName':_0x25a2f3[_0x4e976a(0x101)],'matchCount':_0x7df9ca[_0x4e976a(0xed)+'h']});const _0x3d957d=_0x7df9ca[0x0];_0x3d957d&&await _0x109773[_0x4e976a(0x82)+_0x4e976a(0xf7)+_0x4e976a(0x146)+'em'](_0x1eaa60,_0x3d957d['id'],{'resolved':!![]});}}catch(_0x121d38){this['logge'+'r'][_0x4e976a(0x14e)]('Faile'+_0x4e976a(0x190)+_0x4e976a(0x93)+_0x4e976a(0xdb)+_0x4e976a(0xf7)+_0x4e976a(0x175)+'tem\x20\x22'+_0x25a2f3[_0x4e976a(0x101)]+(_0x4e976a(0x85)+_0x4e976a(0xb1)+_0x4e976a(0x10f)+'\x20\x22')+_0x1ffd0c[_0x4e976a(0x101)]+'\x22',{'error':_0x121d38 instanceof Error?_0x121d38[_0x4e976a(0xc1)+'ge']:_0x15b271[_0x4e976a(0x157)](String,_0x121d38),'checklistId':_0x1eaa60});}}}}catch(_0xe9c7f5){this['logge'+'r'][_0x4e976a(0x14e)](_0x4e976a(0x7d)+_0x4e976a(0x190)+_0x4e976a(0x93)+_0x4e976a(0xdb)+'heckl'+_0x4e976a(0x1b7)+_0x1ffd0c['name']+'\x22',{'error':_0xe9c7f5 instanceof Error?_0xe9c7f5[_0x4e976a(0xc1)+'ge']:String(_0xe9c7f5),'taskId':_0x355c0f['id']});}}}if(_0x15658f?.['lengt'+'h']){const {TaskServiceAttachments:_0x23a1c2}=await import(_0x15b271['pKTuj']),_0x2a71d2=new _0x23a1c2(this);for(const _0x420b54 of _0x15658f){try{await _0x2a71d2[_0x4e976a(0x185)+_0x4e976a(0x10e)+'Attac'+_0x4e976a(0x124)+_0x4e976a(0x152)+'rl'](_0x355c0f['id'],_0x420b54[_0x4e976a(0xb8)],_0x420b54[_0x4e976a(0x1a1)]);}catch(_0x10ba3c){this[_0x4e976a(0x7b)+'r'][_0x4e976a(0x14e)](_0x4e976a(0x7d)+_0x4e976a(0x190)+_0x4e976a(0xa8)+'\x20atta'+'chmen'+'t\x20\x22'+_0x420b54[_0x4e976a(0x1a1)]+'\x22',_0x10ba3c);}}}if(_0xd8d222?.[_0x4e976a(0xed)+'h']){_0x355c0f[_0x4e976a(0xfe)+_0x4e976a(0xd1)]=[];for(const _0x5e20ec of _0xd8d222){try{const _0x20622b=await this[_0x4e976a(0x141)+_0x4e976a(0x17d)](_0x1ff6dc,{..._0x5e20ec,'parent':_0x355c0f['id']});_0x355c0f[_0x4e976a(0xfe)+_0x4e976a(0xd1)][_0x4e976a(0xd7)](_0x20622b);}catch(_0x4f6734){this[_0x4e976a(0x7b)+'r'][_0x4e976a(0x14e)](_0x4e976a(0x7d)+_0x4e976a(0x190)+_0x4e976a(0x141)+_0x4e976a(0x147)+'task\x20'+'\x22'+_0x5e20ec[_0x4e976a(0x101)]+'\x22',_0x4f6734);}}}return _0x355c0f;}catch(_0x292ce5){throw this['handl'+_0x4e976a(0x12b)+'r'](_0x292ce5,_0x15b271['VgRRT']);}}async['getTa'+'sk'](_0x585065,_0x5a9699=![]){const _0x4f8f76=a0_0x1553b4,_0x178d93={'YDPdo':_0x4f8f76(0x15c)+'g','NYUMN':'../..'+'/../t'+_0x4f8f76(0xdd)+_0x4f8f76(0x122)+_0x4f8f76(0x120)+'ties.'+'js','hiONd':function(_0x4056e4,_0x24d426){return _0x4056e4(_0x24d426);}},{isCustomTaskId:_0x7eedee}=await import(_0x178d93[_0x4f8f76(0x148)]);if(_0x178d93[_0x4f8f76(0xeb)](_0x7eedee,_0x585065))return this[_0x4f8f76(0x9d)+_0x4f8f76(0x167)+_0x4f8f76(0x169)+'Id'](_0x585065,undefined,_0x5a9699);try{return await this['makeR'+_0x4f8f76(0x76)+'t'](async()=>{const _0x395022=_0x4f8f76,_0xfda85c=await this[_0x395022(0x13a)+'t'][_0x395022(0x12a)](_0x395022(0xd5)+'/'+_0x585065,{'params':_0x5a9699?{'include_markdown_description':_0x395022(0x10b)}:{}}),_0x361b93=_0xfda85c[_0x395022(0xc6)];if(typeof _0x361b93===_0x178d93[_0x395022(0xd8)])throw new ClickUpServiceError(_0x395022(0x106)+_0x395022(0x149)+'\x20text'+_0x395022(0x1ad)+_0x395022(0x8b),ErrorCode[_0x395022(0x15b)+'WN'],_0x361b93);if(_0x361b93?.['statu'+'s']&&_0x361b93['list']?.['id'])this['cache'+_0x395022(0x19e)+'s'](_0x361b93['list']['id'],_0x361b93[_0x395022(0xb9)+'s'][_0x395022(0xb9)+'s']);return _0x361b93;});}catch(_0x3289d7){throw this['handl'+_0x4f8f76(0x12b)+'r'](_0x3289d7,'Faile'+_0x4f8f76(0x190)+_0x4f8f76(0x12f)+_0x4f8f76(0xba)+_0x585065);}}async['getTa'+a0_0x1553b4(0xd1)](_0x3762a0,_0x41c307={},_0x2b14aa){const _0xdc6f19=a0_0x1553b4,_0x412ae1={'bHXdT':function(_0x1ea64d,_0x499ec2){return _0x1ea64d===_0x499ec2;}};try{if(_0x41c307[_0xdc6f19(0xb9)+_0xdc6f19(0xa6)]?.[_0xdc6f19(0xed)+'h']){const _0x6de20b=this['valid'+_0xdc6f19(0x18b)+'Cache'][_0xdc6f19(0xd0)][_0xdc6f19(0x12a)](_0x3762a0);_0x41c307[_0xdc6f19(0xb9)+_0xdc6f19(0xa6)]=_0x41c307[_0xdc6f19(0xb9)+'ses'][_0xdc6f19(0x1a7)](_0x4a9ddd=>this[_0xdc6f19(0x18a)+_0xdc6f19(0xd4)+_0xdc6f19(0xcf)](_0x4a9ddd,_0x6de20b?.[_0xdc6f19(0xb9)+'ses']));}if(_0x41c307[_0xdc6f19(0x16d)+'m_tas'+'k_typ'+'es']?.[_0xdc6f19(0xed)+'h']){const _0x47075e=_0x41c307['custo'+_0xdc6f19(0x109)+'ms']||[];for(const _0x12c0f7 of _0x41c307[_0xdc6f19(0x16d)+_0xdc6f19(0x130)+'k_typ'+'es']){const _0x536a31=await this[_0xdc6f19(0x9d)+_0xdc6f19(0x11c)+_0xdc6f19(0x16f)](_0x12c0f7);if(_0x536a31!==null)_0x47075e[_0xdc6f19(0xd7)](_0x536a31);}_0x41c307[_0xdc6f19(0x16d)+'m_ite'+'ms']=_0x47075e;}return await this[_0xdc6f19(0x15d)+'eques'+'t'](async()=>{const _0xa352e1=_0xdc6f19,_0x38e632=this[_0xa352e1(0xf9)+_0xa352e1(0x195)+_0xa352e1(0x143)+_0xa352e1(0xda)+'s'](_0x41c307),_0xff972=_0x2b14aa||this['teamI'+'d'],_0x7ccecf=await this[_0xa352e1(0x13a)+'t'][_0xa352e1(0x12a)]('/list'+'/'+_0x3762a0+_0xa352e1(0xd5),{'params':_0x38e632}),_0x2187a0=_0x7ccecf[_0xa352e1(0xc6)];if(_0x412ae1[_0xa352e1(0x158)](typeof _0x2187a0,_0xa352e1(0x15c)+'g'))throw new ClickUpServiceError(_0xa352e1(0x106)+_0xa352e1(0x149)+_0xa352e1(0xa5)+_0xa352e1(0x1ad)+_0xa352e1(0x8b),ErrorCode[_0xa352e1(0x15b)+'WN'],_0x2187a0);if(_0x2187a0?.[_0xa352e1(0xb9)+'ses']){const _0x1e0b8d=this[_0xa352e1(0x1ba)+_0xa352e1(0x18b)+_0xa352e1(0xa0)]['lists']['get'](_0x3762a0);this['valid'+_0xa352e1(0x18b)+_0xa352e1(0xa0)][_0xa352e1(0xd0)][_0xa352e1(0x94)](_0x3762a0,{'validatedAt':Date[_0xa352e1(0x174)](),'valid':!![],'statuses':_0x2187a0[_0xa352e1(0xb9)+'ses'],..._0x1e0b8d});}return Array[_0xa352e1(0x11d)+'ay'](_0x2187a0)?_0x2187a0:_0x2187a0[_0xa352e1(0x11b)]||[];});}catch(_0x229127){throw this[_0xdc6f19(0x161)+_0xdc6f19(0x12b)+'r'](_0x229127,_0xdc6f19(0x7d)+_0xdc6f19(0x190)+_0xdc6f19(0x12f)+'asks\x20'+'for\x20l'+_0xdc6f19(0xfd)+_0x3762a0);}}async['getAl'+a0_0x1553b4(0x156)+'s'](_0x51844c,_0x226f29={}){const _0x405eca=a0_0x1553b4,_0x41040a={'osQWw':function(_0x19e36a,_0x46ca99){return _0x19e36a<_0x46ca99;},'bwkrw':function(_0x3ccb6c,_0x1bbc80){return _0x3ccb6c===_0x1bbc80;}},_0x4146c0=[];for(let _0xbde4c8=0x0;_0x41040a[_0x405eca(0xea)](_0xbde4c8,0x64);_0xbde4c8++){const _0xaa6f46=await this[_0x405eca(0x9d)+'sks'](_0x51844c,{..._0x226f29,'page':_0xbde4c8});if(_0x41040a['bwkrw'](_0xaa6f46[_0x405eca(0xed)+'h'],0x0))break;_0x4146c0[_0x405eca(0xd7)](..._0xaa6f46);if(_0xaa6f46[_0x405eca(0xed)+'h']<0x64)break;}return _0x4146c0;}async['getSu'+a0_0x1553b4(0x132)+'s'](_0x2f1cb9){const _0x12221f=a0_0x1553b4;return this[_0x12221f(0x15d)+'eques'+'t'](async()=>{const _0x15fc3d=_0x12221f,_0x392b6f=await this['clien'+'t'][_0x15fc3d(0x12a)](_0x15fc3d(0xd5)+'/'+_0x2f1cb9+('?subt'+_0x15fc3d(0xbd)+_0x15fc3d(0xec)+_0x15fc3d(0x103)+_0x15fc3d(0xc5)+'btask'+_0x15fc3d(0x196)+'e')),_0x2cae8d=_0x392b6f[_0x15fc3d(0xc6)];return _0x2cae8d[_0x15fc3d(0xfe)+_0x15fc3d(0xd1)]||[];})[_0x12221f(0x1b6)](_0x581cf5=>{const _0x39b0b8=_0x12221f;throw this[_0x39b0b8(0x161)+_0x39b0b8(0x12b)+'r'](_0x581cf5,_0x39b0b8(0x7d)+_0x39b0b8(0x190)+_0x39b0b8(0x1b5)+'ubtas'+_0x39b0b8(0x104)+_0x39b0b8(0x12d)+'k\x20'+_0x2f1cb9);});}async[a0_0x1553b4(0x9d)+a0_0x1553b4(0x167)+'ustom'+'Id'](_0xbc6266,_0x585b7c,_0x2195e2=![]){const _0x1ca40d=a0_0x1553b4,_0x2f9318={'FyZsc':_0x1ca40d(0x10b),'Exsua':function(_0x21a54d,_0x10dbc4){return _0x21a54d===_0x10dbc4;}};try{return await this[_0x1ca40d(0x15d)+_0x1ca40d(0x76)+'t'](async()=>{const _0x1e8103=_0x1ca40d,_0x6294f6=new URLSearchParams({'custom_task_ids':_0x2f9318[_0x1e8103(0x1bc)],'team_id':this['teamI'+'d']});if(_0x2195e2)_0x6294f6['appen'+'d'](_0x1e8103(0x103)+_0x1e8103(0x151)+_0x1e8103(0x1b1)+'n_des'+_0x1e8103(0x1ab)+_0x1e8103(0x91),_0x2f9318[_0x1e8103(0x1bc)]);const _0x5b13a3=await this['clien'+'t'][_0x1e8103(0x12a)](_0x1e8103(0xd5)+'/'+encodeURIComponent(_0xbc6266),{'params':_0x6294f6});if(_0x2f9318[_0x1e8103(0xe4)](typeof _0x5b13a3['data'],_0x1e8103(0x15c)+'g'))throw new ClickUpServiceError(_0x1e8103(0x106)+'ected'+'\x20text'+_0x1e8103(0x1ad)+'onse',ErrorCode['UNKNO'+'WN'],_0x5b13a3[_0x1e8103(0xc6)]);return _0x5b13a3[_0x1e8103(0xc6)];});}catch(_0x2aa116){throw this[_0x1ca40d(0x161)+_0x1ca40d(0x12b)+'r'](_0x2aa116,_0x1ca40d(0x7d)+_0x1ca40d(0x190)+_0x1ca40d(0x12f)+_0x1ca40d(0x13b)+_0x1ca40d(0x173)+_0x1ca40d(0x169)+_0x1ca40d(0x12e)+_0xbc6266);}}async[a0_0x1553b4(0xa7)+'eTask'](_0x51cb25,_0x394649){const _0x3a5515=a0_0x1553b4,_0x18e99a={'iqmGF':_0x3a5515(0x15c)+'g','fyvGZ':'Unexp'+_0x3a5515(0x149)+_0x3a5515(0xa5)+_0x3a5515(0x1ad)+_0x3a5515(0x8b),'UnjYB':function(_0x210433,_0x310cc1){return _0x210433!==_0x310cc1;},'TBODa':_0x3a5515(0x8a)+_0x3a5515(0x145)+_0x3a5515(0x153)+'.js'};if(_0x394649[_0x3a5515(0x16d)+_0x3a5515(0x130)+_0x3a5515(0x193)+'e']&&!_0x394649['custo'+_0x3a5515(0x109)+_0x3a5515(0x19f)]){const _0x339e19=await this[_0x3a5515(0x9d)+_0x3a5515(0x11c)+_0x3a5515(0x16f)](_0x394649['custo'+'m_tas'+_0x3a5515(0x193)+'e']);if(_0x18e99a[_0x3a5515(0x14f)](_0x339e19,null))_0x394649[_0x3a5515(0x16d)+_0x3a5515(0x109)+_0x3a5515(0x19f)]=_0x339e19;}try{const {custom_fields:_0x46cea0,assignees:_0x3b54fa,custom_task_type:_0x37b6d0,..._0x25163a}=_0x394649;if(_0x25163a['statu'+'s']){const _0x4e6433=await this[_0x3a5515(0x9d)+'sk'](_0x51cb25),_0x59f2e4=this[_0x3a5515(0x1ba)+_0x3a5515(0x18b)+_0x3a5515(0xa0)]['lists']['get'](_0x4e6433[_0x3a5515(0x117)]['id']);_0x25163a[_0x3a5515(0xb9)+'s']=this[_0x3a5515(0x18a)+_0x3a5515(0xd4)+_0x3a5515(0xcf)](_0x25163a[_0x3a5515(0xb9)+'s'],_0x59f2e4?.[_0x3a5515(0xb9)+_0x3a5515(0xa6)]);}if(_0x3b54fa!==undefined){const _0x12b7fd=await this['getTa'+'sk'](_0x51cb25),_0x4a40ed=_0x12b7fd[_0x3a5515(0x16b)+'nees'][_0x3a5515(0x1a7)](_0x1b17bc=>Number(_0x1b17bc['id'])),_0x4a2fd5=Array[_0x3a5515(0x11d)+'ay'](_0x3b54fa)?_0x3b54fa['map'](Number):[];if(Array[_0x3a5515(0x11d)+'ay'](_0x3b54fa)){const _0x1df4dc=_0x4a2fd5['filte'+'r'](_0x34149e=>!_0x4a40ed[_0x3a5515(0x103)+_0x3a5515(0xcc)](_0x34149e)),_0x6b6816=_0x4a40ed[_0x3a5515(0x131)+'r'](_0x53868e=>!_0x4a2fd5[_0x3a5515(0x103)+_0x3a5515(0xcc)](_0x53868e));(_0x1df4dc[_0x3a5515(0xed)+'h']>0x0||_0x6b6816[_0x3a5515(0xed)+'h']>0x0)&&(_0x25163a['assig'+_0x3a5515(0x1c1)]={'add':_0x1df4dc,'rem':_0x6b6816});}else _0x25163a['assig'+'nees']=_0x3b54fa;}const _0x30daa2=await this[_0x3a5515(0x15d)+_0x3a5515(0x76)+'t'](async()=>{const _0x5b8eb3=_0x3a5515,_0x2166ce=await this[_0x5b8eb3(0x13a)+'t'][_0x5b8eb3(0x17c)](_0x5b8eb3(0xd5)+'/'+_0x51cb25,_0x25163a),_0x563c9c=_0x2166ce[_0x5b8eb3(0xc6)];if(typeof _0x563c9c===_0x18e99a[_0x5b8eb3(0x199)]){const _0x25b912=_0x563c9c['match'](/task.*?(\w{9,10})/i);if(_0x25b912)return await this['getTa'+'sk'](_0x25b912[0x1]);throw new ClickUpServiceError(_0x18e99a[_0x5b8eb3(0x99)],ErrorCode[_0x5b8eb3(0x15b)+'WN'],_0x563c9c);}return _0x563c9c;});if(_0x46cea0?.[_0x3a5515(0xed)+'h']){const {CustomFieldService:_0x250baf}=await import(_0x18e99a[_0x3a5515(0x18c)]),_0xdb681e=new _0x250baf(this[_0x3a5515(0x1c0)+'y'],this[_0x3a5515(0xdc)+'d'],this[_0x3a5515(0x176)+'rl'],this[_0x3a5515(0xfc)+_0x3a5515(0xbc)]);for(const _0xb9d590 of _0x46cea0){await _0xdb681e[_0x3a5515(0x10d)+'eldVa'+_0x3a5515(0x73)](_0x51cb25,_0xb9d590['id'],_0xb9d590[_0x3a5515(0x181)]);}}return _0x30daa2;}catch(_0x4dc313){throw this[_0x3a5515(0x161)+'eErro'+'r'](_0x4dc313,_0x3a5515(0x7d)+_0x3a5515(0x190)+_0x3a5515(0xa7)+'e\x20tas'+'k\x20'+_0x51cb25);}}async[a0_0x1553b4(0x9d)+a0_0x1553b4(0x1b0)+'eInSt'+a0_0x1553b4(0x10a)](_0x3408bf){const _0x42eba4=a0_0x1553b4;return this[_0x42eba4(0x15d)+_0x42eba4(0x76)+'t'](()=>this[_0x42eba4(0x13a)+'t'][_0x42eba4(0x12a)](_0x42eba4(0xd5)+'/'+_0x3408bf+(_0x42eba4(0x113)+_0x42eba4(0xe3)+_0x42eba4(0xcf))))[_0x42eba4(0x9b)](_0x49323e=>_0x49323e[_0x42eba4(0xc6)])[_0x42eba4(0x1b6)](_0x14ff04=>{const _0x27472a=_0x42eba4;throw this[_0x27472a(0x161)+_0x27472a(0x12b)+'r'](_0x14ff04,_0x27472a(0x7d)+_0x27472a(0x190)+_0x27472a(0x12f)+'ime\x20i'+'n\x20sta'+_0x27472a(0xf1)+_0x27472a(0x192)+'sk\x20'+_0x3408bf);});}async['getBu'+a0_0x1553b4(0x7a)+a0_0x1553b4(0xe1)+'InSta'+a0_0x1553b4(0x150)](_0x3b7454,_0x69c95a){const _0x3dcf27=a0_0x1553b4,_0x48fd4e={'JsXdY':_0x3dcf27(0x7d)+'d\x20to\x20'+'get\x20b'+_0x3dcf27(0xb4)+_0x3dcf27(0x70)+'n\x20sta'+_0x3dcf27(0x150)};return this['makeR'+'eques'+'t'](()=>this['clien'+'t'][_0x3dcf27(0x12a)](_0x3dcf27(0xd5)+_0x3dcf27(0x18e)+_0x3dcf27(0xfa)+_0x3dcf27(0xe3)+_0x3dcf27(0xcf),{'params':{'task_ids':_0x3b7454,'custom_task_ids':_0x69c95a}}))[_0x3dcf27(0x9b)](_0x538150=>_0x538150[_0x3dcf27(0xc6)])[_0x3dcf27(0x1b6)](_0x5743ff=>{const _0x4348c7=_0x3dcf27;throw this[_0x4348c7(0x161)+_0x4348c7(0x12b)+'r'](_0x5743ff,_0x48fd4e['JsXdY']);});}async[a0_0x1553b4(0x9d)+a0_0x1553b4(0x13f)+a0_0x1553b4(0xa9)](_0x228ae4){const _0x236d79=a0_0x1553b4;return this[_0x236d79(0x15d)+_0x236d79(0x76)+'t'](()=>this[_0x236d79(0x13a)+'t'][_0x236d79(0x12a)](_0x236d79(0xd5)+'/'+_0x228ae4+(_0x236d79(0x189)+'er')))[_0x236d79(0x9b)](_0x45dcd4=>_0x45dcd4[_0x236d79(0xc6)])[_0x236d79(0x1b6)](_0x4a16d3=>{const _0x24bcc5=_0x236d79;throw this[_0x24bcc5(0x161)+_0x24bcc5(0x12b)+'r'](_0x4a16d3,_0x24bcc5(0x7d)+'d\x20to\x20'+_0x24bcc5(0xf8)+_0x24bcc5(0x127)+_0x24bcc5(0x17e)+_0x24bcc5(0x19d)+'\x20'+_0x228ae4);});}async[a0_0x1553b4(0x11a)+a0_0x1553b4(0x17d)](_0x42b7f9){const _0x26e377=a0_0x1553b4;return this['handl'+'eRequ'+'est'](_0x26e377(0x11a)+_0x26e377(0x17d),()=>this[_0x26e377(0x13a)+'t'][_0x26e377(0x11a)+'e'](_0x26e377(0xd5)+'/'+_0x42b7f9),_0x26e377(0x7d)+'d\x20to\x20'+_0x26e377(0x11a)+_0x26e377(0x165)+'k\x20'+_0x42b7f9);}async[a0_0x1553b4(0x123)+a0_0x1553b4(0x108)](_0xd08444,_0x39e00d,_0x439e25=![]){const _0x8e8dd5=a0_0x1553b4,_0x13810d={'ZcwMU':function(_0x54cfcc,_0x86bc3f){return _0x54cfcc===_0x86bc3f;}};try{const [_0x16d50d]=await Promise[_0x8e8dd5(0xdf)]([this[_0x8e8dd5(0x1ba)+'ateTa'+_0x8e8dd5(0x80)+_0x8e8dd5(0x170)](_0xd08444),this[_0x8e8dd5(0x1ba)+_0x8e8dd5(0x96)+_0x8e8dd5(0x155)+_0x8e8dd5(0x170)](_0x39e00d)]),_0x2794bf=_0x16d50d['list']['id'];if(_0x13810d[_0x8e8dd5(0xc2)](_0x2794bf,_0x39e00d))return _0x16d50d;try{return await this[_0x8e8dd5(0x13e)+_0x8e8dd5(0x11f)+'ist'](_0xd08444,_0x39e00d),await this['remov'+'eTask'+_0x8e8dd5(0xd6)+_0x8e8dd5(0x186)](_0xd08444,_0x2794bf);}catch(_0x41f1fb){if(_0x41f1fb instanceof ClickUpServiceError&&_0x13810d[_0x8e8dd5(0xc2)](_0x41f1fb[_0x8e8dd5(0xe2)],ErrorCode[_0x8e8dd5(0x112)+_0x8e8dd5(0x1be)])){if(!_0x439e25)throw new ClickUpServiceError(_0x8e8dd5(0x187)+'estru'+_0x8e8dd5(0x7c)+_0x8e8dd5(0x168)+_0x8e8dd5(0x107)+_0x8e8dd5(0x162)+_0x8e8dd5(0x135)+_0x8e8dd5(0x198)+'.\x20Acc'+_0x8e8dd5(0x1a0)+_0x8e8dd5(0x125)+_0x8e8dd5(0x10c)+_0x8e8dd5(0x13c)+_0x8e8dd5(0x17a)+'\x20retr'+_0x8e8dd5(0xe6)+_0x8e8dd5(0x1a5)+_0x8e8dd5(0x1bb)+_0x8e8dd5(0xb3)+_0x8e8dd5(0xaf)+_0x8e8dd5(0xe0)+_0x8e8dd5(0x102)+_0x8e8dd5(0xb5),ErrorCode[_0x8e8dd5(0x112)+_0x8e8dd5(0x1be)]);const _0x25b94a=await this[_0x8e8dd5(0x8c)+'ctDee'+_0x8e8dd5(0xe9)+_0x8e8dd5(0x86)](_0xd08444),_0x289a70=await this[_0x8e8dd5(0x141)+_0x8e8dd5(0x17d)](_0x39e00d,_0x25b94a);return await this[_0x8e8dd5(0x11a)+_0x8e8dd5(0x17d)](_0xd08444),_0x289a70;}throw _0x41f1fb;}}catch(_0x3de0f8){throw this[_0x8e8dd5(0x161)+_0x8e8dd5(0x12b)+'r'](_0x3de0f8,_0x8e8dd5(0x7d)+_0x8e8dd5(0x190)+_0x8e8dd5(0x114)+_0x8e8dd5(0x194));}}async[a0_0x1553b4(0x13e)+'skToL'+a0_0x1553b4(0x186)](_0x32a37c,_0x280aa9){const _0x252a5c=a0_0x1553b4;return this[_0x252a5c(0x15d)+'eques'+'t'](async()=>{const _0x572687=_0x252a5c;return await Promise[_0x572687(0xdf)]([this[_0x572687(0x1ba)+'ateTa'+_0x572687(0x80)+_0x572687(0x170)](_0x32a37c),this[_0x572687(0x1ba)+_0x572687(0x96)+_0x572687(0x155)+_0x572687(0x170)](_0x280aa9)]),await this['clien'+'t'][_0x572687(0x172)](_0x572687(0x142)+'/'+_0x280aa9+(_0x572687(0xd5)+'/')+_0x32a37c),this[_0x572687(0x1ba)+_0x572687(0x18b)+_0x572687(0xa0)][_0x572687(0x11b)]['delet'+'e'](_0x32a37c),await this[_0x572687(0x9d)+'sk'](_0x32a37c);})[_0x252a5c(0x1b6)](_0x389fe0=>{const _0x191848=_0x252a5c;throw this[_0x191848(0x161)+_0x191848(0x12b)+'r'](_0x389fe0,'Faile'+_0x191848(0x190)+_0x191848(0xd9)+_0x191848(0xba)+_0x32a37c+(_0x191848(0x1a6)+_0x191848(0xfd))+_0x280aa9);});}async[a0_0x1553b4(0x1a2)+a0_0x1553b4(0x17d)+a0_0x1553b4(0xd6)+a0_0x1553b4(0x186)](_0x548ddc,_0x2a4ef1){const _0x38190b=a0_0x1553b4;return this[_0x38190b(0x15d)+_0x38190b(0x76)+'t'](async()=>{const _0x4534b1=_0x38190b;return await Promise[_0x4534b1(0xdf)]([this['valid'+_0x4534b1(0xe7)+'skExi'+_0x4534b1(0x170)](_0x548ddc),this[_0x4534b1(0x1ba)+'ateLi'+_0x4534b1(0x155)+_0x4534b1(0x170)](_0x2a4ef1)]),await this[_0x4534b1(0x13a)+'t'][_0x4534b1(0x11a)+'e']('/list'+'/'+_0x2a4ef1+(_0x4534b1(0xd5)+'/')+_0x548ddc),this[_0x4534b1(0x1ba)+_0x4534b1(0x18b)+'Cache'][_0x4534b1(0x11b)]['delet'+'e'](_0x548ddc),await this[_0x4534b1(0x9d)+'sk'](_0x548ddc);})[_0x38190b(0x1b6)](_0x4765c0=>{const _0x563842=_0x38190b;throw this[_0x563842(0x161)+'eErro'+'r'](_0x4765c0,_0x563842(0x7d)+'d\x20to\x20'+_0x563842(0x1a2)+_0x563842(0x165)+'k\x20'+_0x548ddc+(_0x563842(0x16c)+_0x563842(0x137)+'\x20')+_0x2a4ef1);});}async['dupli'+'cateT'+'ask'](_0x4e8404,_0x4edc8){const _0x485cc0=a0_0x1553b4;try{const _0x34b74d=await this[_0x485cc0(0x9d)+'sk'](_0x4e8404),_0x52fea0=_0x4edc8||_0x34b74d[_0x485cc0(0x117)]['id'],_0xe56e97=await this[_0x485cc0(0x8c)+_0x485cc0(0xfb)+_0x485cc0(0xe9)+_0x485cc0(0x86)](_0x4e8404),_0x321169=await this[_0x485cc0(0x141)+_0x485cc0(0x17d)](_0x52fea0,_0xe56e97);return _0x321169;}catch(_0x1ad2f7){throw this[_0x485cc0(0x161)+_0x485cc0(0x12b)+'r'](_0x1ad2f7,_0x485cc0(0x7d)+_0x485cc0(0x190)+_0x485cc0(0x126)+_0x485cc0(0x1a9)+_0x485cc0(0x183)+_0x4e8404);}}async[a0_0x1553b4(0x1ba)+a0_0x1553b4(0xe7)+a0_0x1553b4(0x80)+'sts'](_0x187959){const _0x49aedd=a0_0x1553b4,_0xb3c240={'WfWjv':function(_0x387aa8,_0x31cacc){return _0x387aa8<_0x31cacc;}},_0xd9bd4a=this['valid'+'ation'+_0x49aedd(0xa0)][_0x49aedd(0x11b)][_0x49aedd(0x12a)](_0x187959);if(_0xd9bd4a&&_0xb3c240[_0x49aedd(0xa3)](Date[_0x49aedd(0x174)]()-_0xd9bd4a[_0x49aedd(0x1ba)+'atedA'+'t'],this['CACHE'+'_TTL']))return _0xd9bd4a[_0x49aedd(0x194)];const _0x2a1b04=await this[_0x49aedd(0x9d)+'sk'](_0x187959);return this['valid'+_0x49aedd(0x18b)+_0x49aedd(0xa0)][_0x49aedd(0x11b)][_0x49aedd(0x94)](_0x187959,{'validatedAt':Date[_0x49aedd(0x174)](),'task':_0x2a1b04}),_0x2a1b04;}async[a0_0x1553b4(0x1ba)+a0_0x1553b4(0x96)+a0_0x1553b4(0x155)+a0_0x1553b4(0x170)](_0x197524){const _0x1fd3db=a0_0x1553b4,_0xb8a91a={'RsxbY':function(_0x2b18b7,_0x3a429c){return _0x2b18b7-_0x3a429c;}},_0x4ef060=this[_0x1fd3db(0x1ba)+_0x1fd3db(0x18b)+_0x1fd3db(0xa0)][_0x1fd3db(0xd0)][_0x1fd3db(0x12a)](_0x197524);if(_0x4ef060&&_0xb8a91a[_0x1fd3db(0x17f)](Date[_0x1fd3db(0x174)](),_0x4ef060[_0x1fd3db(0x1ba)+_0x1fd3db(0x14c)+'t'])<this['CACHE'+_0x1fd3db(0x1bf)]){if(!_0x4ef060[_0x1fd3db(0x1ba)])throw new ClickUpServiceError(_0x1fd3db(0x180)+_0x197524+(_0x1fd3db(0xac)+_0x1fd3db(0x8d)),ErrorCode[_0x1fd3db(0x1b8)+_0x1fd3db(0x129)]);return;}try{const _0x1d557d=await this[_0x1fd3db(0x95)+_0x1fd3db(0x79)+'e'][_0x1fd3db(0x12c)+'st'](_0x197524);this[_0x1fd3db(0x1ba)+_0x1fd3db(0x18b)+_0x1fd3db(0xa0)][_0x1fd3db(0xd0)][_0x1fd3db(0x94)](_0x197524,{'validatedAt':Date[_0x1fd3db(0x174)](),'valid':!![],'statuses':_0x1d557d[_0x1fd3db(0xb9)+_0x1fd3db(0xa6)]?.[_0x1fd3db(0x1a7)](_0x5058ee=>_0x5058ee[_0x1fd3db(0xb9)+'s'])});}catch(_0x47c6d9){this[_0x1fd3db(0x1ba)+'ation'+'Cache']['lists'][_0x1fd3db(0x94)](_0x197524,{'validatedAt':Date[_0x1fd3db(0x174)](),'valid':![]});throw _0x47c6d9;}}[a0_0x1553b4(0x18a)+a0_0x1553b4(0xd4)+a0_0x1553b4(0xcf)](_0x21162f,_0x35c697){const _0x143a62=a0_0x1553b4,_0x9e7496={'oFBJu':function(_0x19d702,_0x2ffc0d){return _0x19d702===_0x2ffc0d;},'bTTpv':function(_0xbab21f,_0x5eda7e,_0x3f18a3){return _0xbab21f(_0x5eda7e,_0x3f18a3);}};if(!_0x35c697||_0x9e7496[_0x143a62(0x171)](_0x35c697[_0x143a62(0xed)+'h'],0x0))return _0x21162f[_0x143a62(0x17b)+'erCas'+'e']();const _0x56d286=_0x21162f[_0x143a62(0x17b)+_0x143a62(0xf4)+'e'](),_0x3e4a9d=_0x35c697['find'](_0x5490f4=>_0x5490f4[_0x143a62(0x17b)+_0x143a62(0xf4)+'e']()===_0x56d286);if(_0x3e4a9d)return _0x3e4a9d;const _0x2c0995=_0x9e7496[_0x143a62(0x128)](findBestMatchInArray,_0x35c697['map'](_0x4ff3d5=>({'name':_0x4ff3d5})),_0x21162f);return _0x2c0995?_0x2c0995[_0x143a62(0x87)][_0x143a62(0x101)]:_0x21162f[_0x143a62(0x17b)+'erCas'+'e']();}[a0_0x1553b4(0xc0)+a0_0x1553b4(0x19e)+'s'](_0x2076b9,_0x332962){const _0xbfeb84=a0_0x1553b4,_0xe30f03=this[_0xbfeb84(0x1ba)+_0xbfeb84(0x18b)+_0xbfeb84(0xa0)][_0xbfeb84(0xd0)][_0xbfeb84(0x12a)](_0x2076b9),_0x166bf3=_0xe30f03?.[_0xbfeb84(0xb9)+_0xbfeb84(0xa6)]||[];!_0x166bf3[_0xbfeb84(0x103)+_0xbfeb84(0xcc)](_0x332962)&&this['valid'+'ation'+_0xbfeb84(0xa0)][_0xbfeb84(0xd0)][_0xbfeb84(0x94)](_0x2076b9,{'validatedAt':Date[_0xbfeb84(0x174)](),'valid':!![],'statuses':[..._0x166bf3,_0x332962]});}['getCa'+'chedT'+'askId'](_0x5508bd,_0x5f5404,_0x36313d){const _0x4a3913=a0_0x1553b4,_0x3eea5f={'irDWC':function(_0x1f48bb,_0x367eef){return _0x1f48bb<_0x367eef;}},_0x4631ef=_0x36313d||this[_0x4a3913(0xdc)+'d'],_0x32a2d8=_0x4631ef+':'+_0x5508bd,_0x9d68eb=this[_0x4a3913(0x14b)+'oIdCa'+_0x4a3913(0xab)][_0x4a3913(0x12a)](_0x32a2d8);return _0x9d68eb&&_0x3eea5f['irDWC'](Date[_0x4a3913(0x174)]()-_0x9d68eb['valid'+'atedA'+'t'],this['CACHE'+_0x4a3913(0x1bf)])&&(!_0x5f5404||_0x9d68eb['listI'+'d']===_0x5f5404)?_0x9d68eb[_0x4a3913(0x15e)+'d']:null;}['cache'+a0_0x1553b4(0x191)+a0_0x1553b4(0x19c)+'Id'](_0x116028,_0x30d56c,_0x2136a7,_0x5cd4bb){const _0x19f852=a0_0x1553b4,_0x20e3c9=_0x5cd4bb||this[_0x19f852(0xdc)+'d'],_0x5d3352=_0x20e3c9+':'+_0x116028;this[_0x19f852(0x14b)+_0x19f852(0x118)+_0x19f852(0xab)][_0x19f852(0x94)](_0x5d3352,{'taskId':_0x30d56c,'validatedAt':Date['now'](),'listId':_0x2136a7});}async[a0_0x1553b4(0x1ba)+a0_0x1553b4(0xe7)+'sksEx'+a0_0x1553b4(0x186)](_0x38fc5c){const _0x1290ee=a0_0x1553b4,_0x2fafde={'BPDtJ':function(_0x2f2477,_0x232346){return _0x2f2477-_0x232346;},'NYfNk':function(_0x456b8e,_0x59e701){return _0x456b8e<_0x59e701;}},_0x4dc69e=new Map(),_0x1e7eea=_0x38fc5c[_0x1290ee(0x131)+'r'](_0x187c85=>{const _0x21db1c=_0x1290ee,_0x367d1f=this[_0x21db1c(0x1ba)+_0x21db1c(0x18b)+_0x21db1c(0xa0)][_0x21db1c(0x11b)][_0x21db1c(0x12a)](_0x187c85);if(_0x367d1f&&_0x2fafde[_0x21db1c(0xf0)](Date['now'](),_0x367d1f[_0x21db1c(0x1ba)+_0x21db1c(0x14c)+'t'])<this['CACHE'+'_TTL'])return _0x4dc69e[_0x21db1c(0x94)](_0x187c85,_0x367d1f['task']),![];return!![];});if(_0x1e7eea[_0x1290ee(0xed)+'h'])for(let _0x4da347=0x0;_0x2fafde[_0x1290ee(0xae)](_0x4da347,_0x1e7eea[_0x1290ee(0xed)+'h']);_0x4da347+=0x5){const _0x4f6004=_0x1e7eea['slice'](_0x4da347,_0x4da347+0x5),_0x1928df=await Promise[_0x1290ee(0xdf)](_0x4f6004['map'](_0x35b826=>this[_0x1290ee(0x9d)+'sk'](_0x35b826)));_0x1928df[_0x1290ee(0x178)+'ch']((_0x41e680,_0xe87569)=>{const _0x4fafdb=_0x1290ee;this[_0x4fafdb(0x1ba)+'ation'+'Cache'][_0x4fafdb(0x11b)][_0x4fafdb(0x94)](_0x4f6004[_0xe87569],{'validatedAt':Date[_0x4fafdb(0x174)](),'task':_0x41e680}),_0x4dc69e['set'](_0x4f6004[_0xe87569],_0x41e680);});}return _0x4dc69e;}}