cc-ding 0.0.3 → 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin/cc-ding.js +1 -1
- package/dist/src/biz/api-key-manager.js +1 -1
- package/dist/src/biz/cc-ding-cli.js +1 -1
- package/dist/src/biz/claude-process.js +1 -1
- package/dist/src/biz/commands.js +1 -1
- package/dist/src/biz/cron.js +1 -1
- package/dist/src/biz/doctor.js +1 -1
- package/dist/src/biz/image.js +1 -1
- package/dist/src/biz/lock.js +1 -1
- package/dist/src/biz/messaging.js +1 -1
- package/dist/src/biz/quote.js +1 -1
- package/dist/src/biz/session.js +1 -1
- package/dist/src/biz/task.js +1 -1
- package/dist/src/biz/types.js +1 -1
- package/dist/src/common.js +1 -1
- package/dist/src/constants.js +1 -1
- package/package.json +5 -1
package/dist/bin/cc-ding.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
'use strict';const
|
|
2
|
+
'use strict';const a0_0xcee1f1=a0_0x347a;(function(_0xc08000,_0x11f325){const _0x128719=a0_0x347a,_0x4723b0=_0xc08000();while(!![]){try{const _0x10cc7e=-parseInt(_0x128719(0x14d))/0x1*(-parseInt(_0x128719(0x182))/0x2)+-parseInt(_0x128719(0x18a))/0x3*(-parseInt(_0x128719(0x183))/0x4)+-parseInt(_0x128719(0x180))/0x5+parseInt(_0x128719(0x15d))/0x6*(-parseInt(_0x128719(0x170))/0x7)+-parseInt(_0x128719(0x197))/0x8+parseInt(_0x128719(0x185))/0x9*(-parseInt(_0x128719(0x156))/0xa)+parseInt(_0x128719(0x17b))/0xb*(parseInt(_0x128719(0x16d))/0xc);if(_0x10cc7e===_0x11f325)break;else _0x4723b0['push'](_0x4723b0['shift']());}catch(_0x2c7237){_0x4723b0['push'](_0x4723b0['shift']());}}}(a0_0x4127,0x36217));var __importDefault=this&&this[a0_0xcee1f1(0x152)]||function(_0x3a124f){const _0x5e8a33=a0_0xcee1f1;return _0x3a124f&&_0x3a124f[_0x5e8a33(0x160)]?_0x3a124f:{'default':_0x3a124f};};Object[a0_0xcee1f1(0x154)](exports,'__esModule',{'value':!![]});const common_1=require(a0_0xcee1f1(0x157)),commander_1=require('commander'),session_1=require(a0_0xcee1f1(0x15e)),path_1=__importDefault(require('path')),cc_ding_cli_1=require(a0_0xcee1f1(0x16a)),lock_1=require(a0_0xcee1f1(0x18c)),doctor_1=require(a0_0xcee1f1(0x18e)),fs_1=__importDefault(require('fs'));(0x0,common_1[a0_0xcee1f1(0x175)])(),process[a0_0xcee1f1(0x184)](a0_0xcee1f1(0x14c)),process[a0_0xcee1f1(0x195)](0x0),process['on'](a0_0xcee1f1(0x187),function(_0x4a679f){const _0x14c170=a0_0xcee1f1;console[_0x14c170(0x199)]('Caught\x20exception:\x20'+_0x4a679f),process[_0x14c170(0x172)](0x1);});function a0_0x4127(){const _0x59cdf8=['\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20功能:\x20钉钉机器人对接本地Claude,\x20支持会话模式和任务队列模式\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20会话数据路径:\x20~/.cc-ding/{clientId}/{MD5}/.sessions/{claudeSessionId}/session.{json|log}\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20任务数据路径:\x20~/.cc-ding/{clientId}/{MD5}/.tasks/{时间戳}/task.{json|log}\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20定时任务数据:\x20~/.cc-ding/{clientId}/cron.json\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20启动方式:\x20pm2\x20start\x20--name\x20\x22cc-ding-{clientId}\x22\x20npx\x20--\x20-p\x20cc-ding\x20run\x20-ci\x20{clientId}\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20会话模式说明\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20会话ID:\x20由\x20Claude\x20分配的\x20claudeSessionId\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20结束会话:\x20/end\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20新会话:\x20/new\x20[初始消息]\x20强制结束当前会话并开启新会话\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20恢复会话:\x20/resume\x20[会话ID]\x20恢复指定历史会话,\x20不指定则恢复最近一个\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20会话持久化:\x20活跃会话自动保存到\x20active.json,\x20服务重启后自动恢复\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20群内多用户:\x20允许群内所有白名单用户参与对话\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20/help:\x20查看所有可用命令(含版本、作者、文档链接);\x20/{命令}\x20--help\x20查看命令详细用法\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20图片消息支持\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20支持接收钉钉图片消息(picture)和富文本消息(richText,\x20含内嵌图片)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20图片自动下载保存到\x20<会话目录>/.images/\x20下\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20useLocalOcr:\x20默认开启,\x20使用本地OCR识别图片文字,\x20同时传入原图路径供Claude自主查看\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20配置方式:\x20conversations[].useLocalOcr\x20=\x20false\x20可关闭OCR(适用于支持图片识别的模型)\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20任务模式说明\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20任务ID:\x20任务接收时间戳\x0a\x20\x20\x20\x20\x20\x20\x20\x20-\x20API\x20Key\x20池化管理(可选,\x20配置apiKeyCfg后启用)\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20429自动切换:\x20自动切换到API\x20Key模式\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20Key轮换:\x20API\x20Key遇到429或连续TPM不稳定时自动换Key\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20-\x20跨天重置:\x20每日自动重置API\x20Key状态\x0a\x20\x20\x20\x20\x20\x20','.cc-ding','loadEnv','requiredOption','projUtil','mobile','version','DingClaude','187gWvOis','printDoctorResults','split','default','\x20\x203.\x20推荐PM2启动:','14515aPEdpU','existsSync','44kSGmHO','68KugMSB','removeAllListeners','314343boNSZN','clientName','uncaughtException','<兜底钉钉机器人Token-用于无dingToken群的消息接收>','\x0a💡\x20请升级\x20Node\x20版本后重新运行\x0a','69777wxREnk','acquirePidLock','../src/biz/lock','slice','../src/biz/doctor','parse','clientSecret\x20(钉钉Stream连接密钥)','-m,\x20--mobile\x20<value>','\x20\x20要求:Node\x20>=\x2024','-cs,\x20--clientSecret\x20<value>','clientId','setMaxListeners','\x20\x201.\x20编辑\x20config.json\x20添加\x20conversations\x20配置(群聊需配置dingToken)','388760AgOatj','-ci,\x20--clientId\x20<value>','log','\x0a❌\x20Node\x20版本过低,无法执行\x20init\x20命令','warning','4584NVoFKA','description','mobile\x20(自己的手机号,\x20自动加入白名单)','before','doctor','__importDefault','after','defineProperty','runDoctor','50xqbjkp','../src/common','addHelpText','argv','command','后续步骤:','\x22\x20npx\x20--\x20-p\x20cc-ding\x20cc-ding\x20run\x20-ci\x20','44778TevGVj','../src/biz/session','option','__esModule','初始化cc-ding配置文件,\x20生成最简config.json','join','/.cc-ding/','配置文件已生成:','\x20\x202.\x20启动机器人:\x20cc-ding\x20run\x20-ci','cc助手','/config.json','配置文件已存在:\x20','action','../src/biz/cc-ding-cli','clientSecret','Command','239772xXEeAW','getHomeDir','initClientDir','364XgtIWc','检查指定client的配置文件schema合法性和有效性','exit'];a0_0x4127=function(){return _0x59cdf8;};return a0_0x4127();}const program=new commander_1[(a0_0xcee1f1(0x16c))]();function a0_0x347a(_0x37abab,_0x2fc1c4){_0x37abab=_0x37abab-0x14b;const _0x4127a0=a0_0x4127();let _0x347a0c=_0x4127a0[_0x37abab];return _0x347a0c;}program[a0_0xcee1f1(0x158)](a0_0xcee1f1(0x150),'\x0a\x20\x20\x20\x20cc-ding\x20for\x20connect\x20ClaudeCode\x20to\x20DingDingRobot\x0a\x20\x20')[a0_0xcee1f1(0x158)](a0_0xcee1f1(0x153),'\x0aExamples:\x0a\x20\x20$\x20cc-ding\x20init\x20-ci\x20{clientId}\x20-cs\x20{clientSecret}\x20-m\x20{mobile}\x0a\x20\x20$\x20cc-ding\x20run\x20-ci\x20{clientId}\x0a')['version']((0x0,common_1[a0_0xcee1f1(0x177)])()['getPkgVersion']()),program[a0_0xcee1f1(0x15a)]('init')[a0_0xcee1f1(0x14e)](a0_0xcee1f1(0x161))['requiredOption']('-ci,\x20--clientId\x20<value>',a0_0xcee1f1(0x194))[a0_0xcee1f1(0x176)](a0_0xcee1f1(0x193),a0_0xcee1f1(0x190))[a0_0xcee1f1(0x176)](a0_0xcee1f1(0x191),a0_0xcee1f1(0x14f))[a0_0xcee1f1(0x15f)]('-cn,\x20--clientName\x20<value>','clientName\x20(机器人名称,\x20可选)')[a0_0xcee1f1(0x169)](async _0x29e2d8=>{const _0x291c1d=a0_0xcee1f1,_0x2f4809=process[_0x291c1d(0x179)][_0x291c1d(0x18d)](0x1),_0x3d8b46=parseInt(_0x2f4809[_0x291c1d(0x17d)]('.')[0x0],0xa);_0x3d8b46<0x18&&(console['log'](_0x291c1d(0x14b)),console[_0x291c1d(0x199)]('\x20\x20当前版本:'+_0x2f4809),console[_0x291c1d(0x199)](_0x291c1d(0x192)),console[_0x291c1d(0x199)](_0x291c1d(0x189)),process[_0x291c1d(0x172)](0x1));const _0x30fda1=(0x0,session_1[_0x291c1d(0x16e)])()+_0x291c1d(0x163)+_0x29e2d8[_0x291c1d(0x194)],_0x3d01e0=_0x30fda1+_0x291c1d(0x167);fs_1[_0x291c1d(0x17e)][_0x291c1d(0x181)](_0x3d01e0)&&(console['log'](_0x291c1d(0x168)+_0x3d01e0),console[_0x291c1d(0x199)]('如需重新初始化,\x20请先删除已有配置文件'),process['exit'](0x1));const _0x169d61={'clientName':_0x29e2d8[_0x291c1d(0x186)]||_0x291c1d(0x166),'owner':_0x29e2d8['mobile'],'whiteUserList':[_0x29e2d8[_0x291c1d(0x178)]],'clientSecret':_0x29e2d8[_0x291c1d(0x16b)],'defaultDingToken':_0x291c1d(0x188),'conversations':[],'includeThinking':![],'resultOnly':!![],'debug':![],'taskQueueSize':0xa,'taskHandlerCount':0x1,'sessionMaxConcurrency':0x14};(0x0,session_1[_0x291c1d(0x16f)])(_0x29e2d8[_0x291c1d(0x194)],_0x169d61),console[_0x291c1d(0x199)](_0x291c1d(0x164),_0x3d01e0),console['log'](''),console['log'](_0x291c1d(0x15b)),console[_0x291c1d(0x199)](_0x291c1d(0x196)),console['log'](_0x291c1d(0x165),_0x29e2d8['clientId']),console[_0x291c1d(0x199)](_0x291c1d(0x17f)),console[_0x291c1d(0x199)]('\x20\x20\x20\x20\x20pm2\x20start\x20--name\x20\x22cc-ding-'+_0x29e2d8[_0x291c1d(0x194)]+_0x291c1d(0x15c)+_0x29e2d8[_0x291c1d(0x194)]);}),program[a0_0xcee1f1(0x15a)]('run')[a0_0xcee1f1(0x14e)](a0_0xcee1f1(0x173))[a0_0xcee1f1(0x176)](a0_0xcee1f1(0x198),a0_0xcee1f1(0x194))[a0_0xcee1f1(0x169)](async _0x146f17=>{const _0x18f1d0=a0_0xcee1f1;(0x0,session_1['ensureClientDir'])(_0x146f17[_0x18f1d0(0x194)]);const _0x3898d8=path_1[_0x18f1d0(0x17e)]['join']((0x0,session_1[_0x18f1d0(0x16e)])(),_0x18f1d0(0x174),_0x146f17['clientId']);(0x0,lock_1[_0x18f1d0(0x18b)])(_0x3898d8,_0x146f17[_0x18f1d0(0x194)]),await new cc_ding_cli_1[(_0x18f1d0(0x17a))](_0x146f17['clientId'])['run']();}),program[a0_0xcee1f1(0x15a)](a0_0xcee1f1(0x151))['description'](a0_0xcee1f1(0x171))[a0_0xcee1f1(0x176)](a0_0xcee1f1(0x198),a0_0xcee1f1(0x194))[a0_0xcee1f1(0x169)](async _0x431d8e=>{const _0x4338b0=a0_0xcee1f1,_0x223aad=path_1['default'][_0x4338b0(0x162)]((0x0,session_1['getHomeDir'])(),_0x4338b0(0x174),_0x431d8e[_0x4338b0(0x194)]),_0x39e1d6=(0x0,doctor_1[_0x4338b0(0x155)])(_0x223aad);(0x0,doctor_1[_0x4338b0(0x17c)])(_0x39e1d6);}),program[a0_0xcee1f1(0x18f)](process[a0_0xcee1f1(0x159)]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const a1_0x2b6750=a1_0x15c9;(function(_0x522308,_0x33ff2a){const _0x16b360=a1_0x15c9,_0x4451d0=_0x522308();while(!![]){try{const _0x45a4d4=parseInt(_0x16b360(0x136))/0x1+parseInt(_0x16b360(0x12f))/0x2+-parseInt(_0x16b360(0x148))/0x3+-parseInt(_0x16b360(0x129))/0x4+-parseInt(_0x16b360(0x120))/0x5+parseInt(_0x16b360(0x13d))/0x6+-parseInt(_0x16b360(0x15c))/0x7*(-parseInt(_0x16b360(0x155))/0x8);if(_0x45a4d4===_0x33ff2a)break;else _0x4451d0['push'](_0x4451d0['shift']());}catch(_0x52a38){_0x4451d0['push'](_0x4451d0['shift']());}}}(a1_0x4cad,0x3bf34));var __importDefault=this&&this[a1_0x2b6750(0x18b)]||function(_0x50d1c3){const _0x3edf1e=a1_0x2b6750;return _0x50d1c3&&_0x50d1c3[_0x3edf1e(0xff)]?_0x50d1c3:{'default':_0x50d1c3};};Object[a1_0x2b6750(0x128)](exports,a1_0x2b6750(0xff),{'value':!![]}),exports[a1_0x2b6750(0xf7)]=saveClientConfig,exports[a1_0x2b6750(0x121)]=resetApiKeyCfg,exports['scheduleApiKeyCfgDailyReset']=scheduleApiKeyCfgDailyReset,exports[a1_0x2b6750(0x189)]=settingLabel,exports[a1_0x2b6750(0x146)]=rotateApiKey,exports[a1_0x2b6750(0x17c)]=pickValidApiKey,exports[a1_0x2b6750(0x176)]=ensureSettingsWithApiKey,exports['isQuotaExhaustedError']=isQuotaExhaustedError,exports[a1_0x2b6750(0x13c)]=isAuthenticationError,exports[a1_0x2b6750(0x135)]=readApiKeyFromSettings,exports[a1_0x2b6750(0x186)]=getForceEnabledSettingsPath,exports[a1_0x2b6750(0x15e)]=startupCheck;function a1_0x15c9(_0x2fe1cf,_0x2e7c9b){_0x2fe1cf=_0x2fe1cf-0xf7;const _0x4cad92=a1_0x4cad();let _0x15c9c9=_0x4cad92[_0x2fe1cf];return _0x15c9c9;}const fs_1=__importDefault(require('fs')),path_1=__importDefault(require(a1_0x2b6750(0xfd))),child_process_1=require(a1_0x2b6750(0x126)),session_1=require(a1_0x2b6750(0x185)),utils_ok_1=require(a1_0x2b6750(0x18a));function saveClientConfig(_0x51d212){const _0x53c60f=a1_0x2b6750,_0x2cde8e=_0x51d212[_0x53c60f(0x159)]()+_0x53c60f(0x11a);try{fs_1[_0x53c60f(0x154)][_0x53c60f(0x17f)](_0x2cde8e,JSON[_0x53c60f(0x17d)](_0x51d212[_0x53c60f(0x104)],null,0x2),_0x53c60f(0x11d));}catch(_0x1ea28e){console[_0x53c60f(0x163)]('['+(0x0,session_1[_0x53c60f(0x167)])()+_0x53c60f(0x114),_0x1ea28e);}}function resetApiKeyCfg(_0x24e8fa){const _0x125f80=a1_0x2b6750,_0xadf80e=_0x24e8fa['config'][_0x125f80(0xfc)];if(!_0xadf80e)return;const _0x337395=new Date();_0xadf80e['resetTime']=utils_ok_1[_0x125f80(0x169)]['mm'](_0x337395[_0x125f80(0x14c)]())['format'](_0x125f80(0x170));let _0x549918=0x0;for(const _0x1914cc of _0xadf80e[_0x125f80(0x12d)]){!_0x1914cc[_0x125f80(0x125)]&&(_0x1914cc[_0x125f80(0x125)]=!![],_0x549918++);}_0x549918>0x0&&console[_0x125f80(0x131)]('['+(0x0,session_1[_0x125f80(0x167)])()+']\x20'+_0x549918+_0x125f80(0x102)),saveClientConfig(_0x24e8fa),console[_0x125f80(0x131)]('['+(0x0,session_1[_0x125f80(0x167)])()+_0x125f80(0x12c));}function a1_0x4cad(){const _0x1cfd13=['apiKeyCfg.claudeSettings\x20共\x20','getTime','linkConversationId','\x20致命','clientSecret\x20(钉钉\x20Stream\x20Client\x20密钥)','which\x20claude',',\x20smallModel:\x20','push','apiKeyCfg.claudeSettings[','default','20904mrsvnE','FATAL',']\x20==========\x20启动自检\x20==========','settings-ding.json','getClientDir','isArray','find','525HNHqIe','model','startupCheck','apiKey','level','settings-tpl.json','boolean','error','floor','conversationTitle','has','timestamp','.cc-ding','dateUtil','[WARN]\x20','\x20isValid\x20类型异常:\x20','settings-tpl.json\x20有效,env\x20包含:\x20','filter','pipe',']\x20自检完成:\x20','YYYY-MM-DD\x20HH:mm:ss',',创建\x20settings-ding.json\x20时将使用空模板','PASS','FORCE_ENABLE','...','memo','ensureSettingsWithApiKey','\x20警告,\x20','claude\x20命令不可用,请确认\x20Claude\x20Code\x20CLI\x20已安装','\x22\x20未在\x20conversations\x20中找到','slice','claude\x20命令可用','pickValidApiKey','stringify','\x20apiKey\x20重复:\x20','writeFileSync','whiteUserList\x20(白名单用户)','ANTHROPIC_AUTH_TOKEN','\x20linkConversationId\x20\x22','object','message','./session','getForceEnabledSettingsPath','execSync','add','settingLabel','utils-ok','__importDefault','saveClientConfig','parse','\x20通过,\x20','conversationId','工作目录不可写:\x20','apiKeyCfg','path','conversations','__esModule',']\x20检测到\x20settings-ding.json\x20FORCE_ENABLE=','join','\x20个已失效\x20Claude\x20Setting\x20重新标记为有效','getFullYear','config','.claude','\x20缺少\x20apiKey','getHomeDir',']\x20启动自检发现致命错误,进程退出','settings-tpl.json\x20缺少\x20env\x20字段,创建\x20settings-ding.json\x20时将不包含预配置环境变量','existsSync','WARN','\x20缺少\x20conversationId',',\x20model:\x20','\x20—\x20','readFileSync','apiKeyCfg\x20上次重置时间:\x20','conversations\x20应为数组或已配置','getConversationDir','conversations[',']\x20保存\x20config.json\x20失败:','test','settings-tpl.json\x20不存在:\x20','conversations\x20为空数组,可通过\x20/reg\x20命令动态注册','群工作目录已就绪:\x20','random','/config.json','getMonth','resetTime','utf-8','mkdirSync','ANTHROPIC_BASE_URL','1943250NPSIVT','resetApiKeyCfg','工作目录可写:\x20','length','env','isValid','child_process','群工作目录创建失败:\x20','defineProperty','27452lcfSjv','some','exit',']\x20apiKeyCfg\x20已重置\x20(所有\x20Claude\x20Setting\x20isValid=true)','claudeSettings',']\x20Claude\x20Setting\x20已失效:\x20','176352jSNHLp','whiteUserList','log','apiKeyCfg.claudeSettings\x20为空,无可用\x20Key','\x20个群配置','(空)','readApiKeyFromSettings','298680SOpOim','clientSecret','ANTHROPIC_MODEL',',\x20剩余有效:\x20','config.json\x20缺少必填字段:\x20','\x20conversationId\x20重复:\x20','isAuthenticationError','1022484iZJpju','smallModel','baseUrl','conversations\x20共\x20','\x20缺少\x20baseUrl',']\x20定时重置\x20apiKeyCfg\x20(每天0点)','toISOString','owner','.healthcheck','rotateApiKey','keys','336528NUYtjD','CLAUDE_SMALL_FAST_MODEL','apiKeyCfg.claudeSettings\x20不是数组,API\x20Key\x20轮换功能不可用'];a1_0x4cad=function(){return _0x1cfd13;};return a1_0x4cad();}function scheduleApiKeyCfgDailyReset(_0x5a2746){const _0x3741f3=()=>{const _0x2be77e=a1_0x15c9,_0x28dea7=new Date(),_0x2c1859=new Date(_0x28dea7[_0x2be77e(0x103)](),_0x28dea7[_0x2be77e(0x11b)](),_0x28dea7['getDate']()+0x1,0x0,0x0,0x0,0x0),_0x1a98dc=_0x2c1859[_0x2be77e(0x14c)]()-_0x28dea7[_0x2be77e(0x14c)]();setTimeout(()=>{const _0x15e604=_0x2be77e;console['log']('['+(0x0,session_1[_0x15e604(0x167)])()+_0x15e604(0x142)),resetApiKeyCfg(_0x5a2746),_0x3741f3();},_0x1a98dc),console[_0x2be77e(0x131)]('['+(0x0,session_1[_0x2be77e(0x167)])()+']\x20apiKeyCfg\x20每日重置已调度,下次重置:\x20'+_0x2c1859[_0x2be77e(0x143)]());};_0x3741f3();}function settingLabel(_0xc6e115){const _0x227de6=a1_0x2b6750;return _0xc6e115[_0x227de6(0x175)]?_0xc6e115['memo']:_0x227de6(0x174)+_0xc6e115[_0x227de6(0x15f)][_0x227de6(0x17a)](-0x6);}function findSettingLabel(_0x115d10,_0x59e5bc){const _0x190e73=a1_0x2b6750,_0x33cfab=_0x115d10[_0x190e73(0x15b)](_0x2df110=>_0x2df110[_0x190e73(0x15f)]===_0x59e5bc);return _0x33cfab?settingLabel(_0x33cfab):_0x190e73(0x174)+_0x59e5bc[_0x190e73(0x17a)](-0x6);}function rotateApiKey(_0x77ffcd,_0x22b505){const _0x309296=a1_0x2b6750,_0x96c7c3=_0x77ffcd[_0x309296(0x104)][_0x309296(0xfc)];if(!_0x96c7c3)return null;for(const _0x399415 of _0x96c7c3['claudeSettings']){if(_0x399415['apiKey']===_0x22b505&&_0x399415['isValid']){_0x399415['isValid']=![];break;}}const _0x2120ab=_0x96c7c3[_0x309296(0x12d)]['filter'](_0x57116f=>_0x57116f[_0x309296(0x125)])[_0x309296(0x123)],_0x52e4c7=findSettingLabel(_0x96c7c3['claudeSettings'],_0x22b505);return console[_0x309296(0x131)]('['+(0x0,session_1[_0x309296(0x167)])()+_0x309296(0x12e)+_0x52e4c7+_0x309296(0x139)+_0x2120ab),saveClientConfig(_0x77ffcd),pickValidApiKey(_0x77ffcd);}function pickValidApiKey(_0x26dff7){const _0x16132c=a1_0x2b6750,_0x4bed6f=_0x26dff7[_0x16132c(0x104)][_0x16132c(0xfc)];if(!_0x4bed6f)return null;const _0x397256=_0x4bed6f[_0x16132c(0x12d)][_0x16132c(0x16d)](_0x2ed890=>_0x2ed890[_0x16132c(0x125)]);if(_0x397256[_0x16132c(0x123)]===0x0)return null;return _0x397256[Math[_0x16132c(0x164)](Math[_0x16132c(0x119)]()*_0x397256[_0x16132c(0x123)])];}function ensureSettingsWithApiKey(_0x2b5a64,_0x16a498){const _0x341e3d=a1_0x2b6750,_0x43e8e3=path_1['default'][_0x341e3d(0x101)](_0x2b5a64,'.claude'),_0x154a7=path_1[_0x341e3d(0x154)][_0x341e3d(0x101)](_0x43e8e3,_0x341e3d(0x158));let _0x49c328={};if(fs_1[_0x341e3d(0x154)][_0x341e3d(0x10a)](_0x154a7))try{_0x49c328=JSON[_0x341e3d(0xf8)](fs_1[_0x341e3d(0x154)][_0x341e3d(0x10f)](_0x154a7,'utf-8'));}catch{_0x49c328={};}else{const _0x57c0be=path_1[_0x341e3d(0x154)][_0x341e3d(0x101)]((0x0,session_1[_0x341e3d(0x107)])(),_0x341e3d(0x168),_0x341e3d(0x161));if(fs_1['default'][_0x341e3d(0x10a)](_0x57c0be))try{_0x49c328=JSON['parse'](fs_1[_0x341e3d(0x154)][_0x341e3d(0x10f)](_0x57c0be,_0x341e3d(0x11d))),console[_0x341e3d(0x131)]('['+(0x0,session_1[_0x341e3d(0x167)])()+']\x20从模板创建\x20settings-ding.json:\x20'+_0x57c0be);}catch{_0x49c328={};}}!_0x49c328[_0x341e3d(0x124)]&&(_0x49c328['env']={});let _0x1f5c4c=![];_0x49c328['env']['ANTHROPIC_AUTH_TOKEN']!==_0x16a498[_0x341e3d(0x15f)]&&(_0x49c328[_0x341e3d(0x124)][_0x341e3d(0x181)]=_0x16a498[_0x341e3d(0x15f)],_0x1f5c4c=!![]);_0x16a498['baseUrl']&&_0x49c328[_0x341e3d(0x124)]['ANTHROPIC_BASE_URL']!==_0x16a498[_0x341e3d(0x13f)]&&(_0x49c328[_0x341e3d(0x124)][_0x341e3d(0x11f)]=_0x16a498['baseUrl'],_0x1f5c4c=!![]);_0x16a498[_0x341e3d(0x15d)]&&_0x49c328[_0x341e3d(0x124)][_0x341e3d(0x138)]!==_0x16a498[_0x341e3d(0x15d)]&&(_0x49c328[_0x341e3d(0x124)][_0x341e3d(0x138)]=_0x16a498[_0x341e3d(0x15d)],_0x1f5c4c=!![]);const _0x5e63d6=_0x16a498[_0x341e3d(0x13e)]||_0x16a498[_0x341e3d(0x15d)];return _0x5e63d6&&_0x49c328[_0x341e3d(0x124)][_0x341e3d(0x149)]!==_0x5e63d6&&(_0x49c328['env'][_0x341e3d(0x149)]=_0x5e63d6,_0x1f5c4c=!![]),_0x1f5c4c&&(fs_1[_0x341e3d(0x154)]['mkdirSync'](_0x43e8e3,{'recursive':!![]}),fs_1[_0x341e3d(0x154)][_0x341e3d(0x17f)](_0x154a7,JSON['stringify'](_0x49c328,null,0x2),_0x341e3d(0x11d)),console[_0x341e3d(0x131)]('['+(0x0,session_1[_0x341e3d(0x167)])()+']\x20已写入\x20Claude\x20配置到\x20'+_0x154a7+'\x20('+settingLabel(_0x16a498)+_0x341e3d(0x10d)+_0x16a498['model']+_0x341e3d(0x151)+_0x5e63d6+')')),_0x154a7;}function isQuotaExhaustedError(_0x2058eb){const _0x3853e7=a1_0x2b6750;if(/Request\s+rejected.*429/i[_0x3853e7(0x115)](_0x2058eb))return!![];if(/429.*Request\s+rejected/i[_0x3853e7(0x115)](_0x2058eb))return!![];if(/429.*(?:超过.*上限|使用上限|配额|quota|capacity)/i[_0x3853e7(0x115)](_0x2058eb))return!![];if(/(?:超过.*上限|使用上限|配额|quota|capacity).*429/i[_0x3853e7(0x115)](_0x2058eb))return!![];return![];}function isAuthenticationError(_0x2dc64a){const _0x23d3e7=a1_0x2b6750;if(/authentication_error/i[_0x23d3e7(0x115)](_0x2dc64a))return!![];if(/401.*(?:未授权|unauthorized|invalid\s*(?:key|token|api)|auth)/i[_0x23d3e7(0x115)](_0x2dc64a))return!![];if(/(?:未授权|unauthorized|invalid\s*(?:key|token|api)|auth).*401/i[_0x23d3e7(0x115)](_0x2dc64a))return!![];return![];}function readApiKeyFromSettings(_0x316da1){const _0x394893=a1_0x2b6750,_0x52be39=path_1['default'][_0x394893(0x101)](_0x316da1,_0x394893(0x105),_0x394893(0x158));if(!fs_1[_0x394893(0x154)][_0x394893(0x10a)](_0x52be39))return null;try{const _0x14c72a=JSON[_0x394893(0xf8)](fs_1[_0x394893(0x154)][_0x394893(0x10f)](_0x52be39,'utf-8'));return _0x14c72a[_0x394893(0x124)]?.['ANTHROPIC_AUTH_TOKEN']||null;}catch{return null;}}function getForceEnabledSettingsPath(_0x47d0a7){const _0x2989f6=a1_0x2b6750,_0x36c62d=path_1['default'][_0x2989f6(0x101)](_0x47d0a7,_0x2989f6(0x105),'settings-ding.json');if(!fs_1[_0x2989f6(0x154)]['existsSync'](_0x36c62d))return null;try{const _0x326485=JSON[_0x2989f6(0xf8)](fs_1[_0x2989f6(0x154)][_0x2989f6(0x10f)](_0x36c62d,_0x2989f6(0x11d))),_0x3986c5=_0x326485[_0x2989f6(0x124)]?.[_0x2989f6(0x173)];if(_0x3986c5!==undefined&&_0x3986c5!==![]&&_0x3986c5!=='')return console[_0x2989f6(0x131)]('['+(0x0,session_1[_0x2989f6(0x167)])()+_0x2989f6(0x100)+_0x3986c5+',强制使用该配置'),_0x36c62d;return null;}catch{return null;}}function startupCheck(_0x12e4a2){const _0x269a3b=a1_0x2b6750,_0x2167eb=[],_0x913cba=_0x12e4a2[_0x269a3b(0x104)],_0x4220bc=_0x12e4a2[_0x269a3b(0x159)](),_0x5c5697=[{'key':_0x269a3b(0x137),'label':_0x269a3b(0x14f)},{'key':_0x269a3b(0x130),'label':_0x269a3b(0x180)},{'key':_0x269a3b(0x144),'label':'owner\x20(机器人\x20owner)'}];for(const {key:_0x2ddf62,label:_0x2f8f9a}of _0x5c5697){const _0x10777a=_0x913cba[_0x2ddf62];_0x10777a===undefined||_0x10777a===null||_0x10777a===''||Array[_0x269a3b(0x15a)](_0x10777a)&&_0x10777a[_0x269a3b(0x123)]===0x0?_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x156),'message':_0x269a3b(0x13a)+_0x2f8f9a}):_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':'config.json\x20'+_0x2f8f9a+'\x20✓'});}if(!Array[_0x269a3b(0x15a)](_0x913cba[_0x269a3b(0xfe)]))_0x2167eb[_0x269a3b(0x152)]({'level':'FATAL','message':_0x269a3b(0x111)});else{if(_0x913cba[_0x269a3b(0xfe)]['length']===0x0)_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':_0x269a3b(0x117)});else{const _0x1a427a=new Set();for(let _0x3c8163=0x0;_0x3c8163<_0x913cba[_0x269a3b(0xfe)][_0x269a3b(0x123)];_0x3c8163++){const _0x2c5b5c=_0x913cba[_0x269a3b(0xfe)][_0x3c8163],_0x327c9b=_0x269a3b(0x113)+_0x3c8163+']';if(!_0x2c5b5c[_0x269a3b(0xfa)])_0x2167eb['push']({'level':_0x269a3b(0x156),'message':_0x327c9b+_0x269a3b(0x10c)});else _0x1a427a['has'](_0x2c5b5c[_0x269a3b(0xfa)])?_0x2167eb['push']({'level':_0x269a3b(0x10b),'message':_0x327c9b+_0x269a3b(0x13b)+_0x2c5b5c[_0x269a3b(0xfa)]}):_0x1a427a[_0x269a3b(0x188)](_0x2c5b5c['conversationId']);_0x2c5b5c[_0x269a3b(0x14d)]&&!_0x913cba[_0x269a3b(0xfe)][_0x269a3b(0x12a)](_0x20b835=>_0x20b835['conversationId']===_0x2c5b5c[_0x269a3b(0x14d)])&&_0x2167eb[_0x269a3b(0x152)]({'level':'WARN','message':_0x327c9b+_0x269a3b(0x182)+_0x2c5b5c[_0x269a3b(0x14d)]+_0x269a3b(0x179)});}_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':_0x269a3b(0x140)+_0x913cba[_0x269a3b(0xfe)][_0x269a3b(0x123)]+_0x269a3b(0x133)});}}if(_0x913cba['apiKeyCfg']){const _0x2ec498=_0x913cba[_0x269a3b(0xfc)];_0x2ec498[_0x269a3b(0x11c)]&&_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':_0x269a3b(0x110)+_0x2ec498[_0x269a3b(0x11c)]});if(!Array['isArray'](_0x2ec498[_0x269a3b(0x12d)]))_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':_0x269a3b(0x14a)});else{if(_0x2ec498[_0x269a3b(0x12d)]['length']===0x0)_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':_0x269a3b(0x132)});else{const _0x57b305=new Set();for(let _0x25fe6f=0x0;_0x25fe6f<_0x2ec498[_0x269a3b(0x12d)][_0x269a3b(0x123)];_0x25fe6f++){const _0x52f67e=_0x2ec498[_0x269a3b(0x12d)][_0x25fe6f],_0x415bcc=_0x269a3b(0x153)+_0x25fe6f+']';if(!_0x52f67e[_0x269a3b(0x15f)])_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x156),'message':_0x415bcc+_0x269a3b(0x106)});else _0x57b305[_0x269a3b(0x166)](_0x52f67e[_0x269a3b(0x15f)])?_0x2167eb[_0x269a3b(0x152)]({'level':'WARN','message':_0x415bcc+_0x269a3b(0x17e)+settingLabel(_0x52f67e)}):_0x57b305['add'](_0x52f67e[_0x269a3b(0x15f)]);!_0x52f67e[_0x269a3b(0x13f)]&&_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':_0x415bcc+_0x269a3b(0x141)}),!_0x52f67e['model']&&_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':_0x415bcc+'\x20缺少\x20model'}),typeof _0x52f67e[_0x269a3b(0x125)]!==_0x269a3b(0x162)&&_0x2167eb['push']({'level':_0x269a3b(0x10b),'message':_0x415bcc+_0x269a3b(0x16b)+typeof _0x52f67e[_0x269a3b(0x125)]});}const _0x159e89=_0x2ec498[_0x269a3b(0x12d)][_0x269a3b(0x16d)](_0x20b4a6=>_0x20b4a6[_0x269a3b(0x125)])[_0x269a3b(0x123)];_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':_0x269a3b(0x14b)+_0x2ec498['claudeSettings']['length']+'\x20项,有效\x20'+_0x159e89});}}}const _0x25615e=path_1[_0x269a3b(0x154)][_0x269a3b(0x101)]((0x0,session_1[_0x269a3b(0x107)])(),_0x269a3b(0x168),'settings-tpl.json');if(fs_1['default'][_0x269a3b(0x10a)](_0x25615e))try{const _0x48ba25=JSON[_0x269a3b(0xf8)](fs_1[_0x269a3b(0x154)][_0x269a3b(0x10f)](_0x25615e,_0x269a3b(0x11d)));if(typeof _0x48ba25!==_0x269a3b(0x183)||_0x48ba25===null)_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':'settings-tpl.json\x20根元素不是对象'});else{if(!_0x48ba25[_0x269a3b(0x124)]||typeof _0x48ba25['env']!=='object')_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':_0x269a3b(0x109)});else{const _0x4363ef=Object[_0x269a3b(0x147)](_0x48ba25[_0x269a3b(0x124)]);_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':_0x269a3b(0x16c)+(_0x4363ef[_0x269a3b(0x101)](',\x20')||_0x269a3b(0x134))});}}}catch(_0x21d7e2){_0x2167eb[_0x269a3b(0x152)]({'level':'WARN','message':'settings-tpl.json\x20解析失败:\x20'+(_0x21d7e2 instanceof Error?_0x21d7e2['message']:_0x21d7e2)});}else _0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':_0x269a3b(0x116)+_0x25615e+_0x269a3b(0x171)});try{(0x0,child_process_1[_0x269a3b(0x187)])(_0x269a3b(0x150),{'stdio':_0x269a3b(0x16e)}),_0x2167eb['push']({'level':_0x269a3b(0x172),'message':_0x269a3b(0x17b)});}catch{_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x156),'message':_0x269a3b(0x178)});}try{const _0x3fc086=path_1[_0x269a3b(0x154)][_0x269a3b(0x101)](_0x4220bc,_0x269a3b(0x145));fs_1[_0x269a3b(0x154)][_0x269a3b(0x17f)](_0x3fc086,'ok',_0x269a3b(0x11d)),fs_1[_0x269a3b(0x154)]['unlinkSync'](_0x3fc086),_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':_0x269a3b(0x122)+_0x4220bc});}catch(_0x3f8176){_0x2167eb['push']({'level':_0x269a3b(0x156),'message':_0x269a3b(0xfb)+_0x4220bc+_0x269a3b(0x10e)+(_0x3f8176 instanceof Error?_0x3f8176['message']:_0x3f8176)});}if(Array[_0x269a3b(0x15a)](_0x913cba[_0x269a3b(0xfe)]))for(const _0x4428d3 of _0x913cba[_0x269a3b(0xfe)]){const _0x15188c=_0x12e4a2[_0x269a3b(0x112)](_0x4428d3[_0x269a3b(0xfa)]);try{fs_1[_0x269a3b(0x154)][_0x269a3b(0x11e)](_0x15188c,{'recursive':!![]}),_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x172),'message':_0x269a3b(0x118)+(_0x4428d3[_0x269a3b(0x165)]||_0x4428d3[_0x269a3b(0xfa)])});}catch(_0x4ec318){_0x2167eb[_0x269a3b(0x152)]({'level':_0x269a3b(0x10b),'message':_0x269a3b(0x127)+_0x15188c+_0x269a3b(0x10e)+(_0x4ec318 instanceof Error?_0x4ec318[_0x269a3b(0x184)]:_0x4ec318)});}}console[_0x269a3b(0x131)]('\x0a['+(0x0,session_1[_0x269a3b(0x167)])()+_0x269a3b(0x157));const _0xd447c0=_0x2167eb[_0x269a3b(0x12a)](_0x284943=>_0x284943['level']===_0x269a3b(0x156));for(const _0x29f980 of _0x2167eb){const _0x538e55=_0x29f980['level']==='PASS'?'✓':_0x29f980['level']===_0x269a3b(0x156)?'✗':'⚠',_0x117b45=_0x29f980[_0x269a3b(0x160)]===_0x269a3b(0x172)?_0x29f980[_0x269a3b(0x184)]:_0x29f980[_0x269a3b(0x160)]===_0x269a3b(0x156)?'[FATAL]\x20'+_0x29f980['message']:_0x269a3b(0x16a)+_0x29f980[_0x269a3b(0x184)];console['log']('\x20\x20'+_0x538e55+'\x20'+_0x117b45);}const _0x111463=_0x2167eb[_0x269a3b(0x16d)](_0x3b7996=>_0x3b7996['level']==='PASS')[_0x269a3b(0x123)],_0x4c4333=_0x2167eb[_0x269a3b(0x16d)](_0x428648=>_0x428648[_0x269a3b(0x160)]===_0x269a3b(0x10b))[_0x269a3b(0x123)],_0x1dc98d=_0x2167eb[_0x269a3b(0x16d)](_0x1587cf=>_0x1587cf[_0x269a3b(0x160)]===_0x269a3b(0x156))[_0x269a3b(0x123)];console[_0x269a3b(0x131)]('['+(0x0,session_1['timestamp'])()+_0x269a3b(0x16f)+_0x111463+_0x269a3b(0xf9)+_0x4c4333+_0x269a3b(0x177)+_0x1dc98d+_0x269a3b(0x14e)),console[_0x269a3b(0x131)]('['+(0x0,session_1[_0x269a3b(0x167)])()+']\x20==============================\x0a'),_0xd447c0&&(console['error']('['+(0x0,session_1['timestamp'])()+_0x269a3b(0x108)),process[_0x269a3b(0x12b)](0x1));}
|
|
1
|
+
'use strict';const a1_0x456413=a1_0x125f;function a1_0x125f(_0x2322b8,_0x55c887){_0x2322b8=_0x2322b8-0xa7;const _0x2d464d=a1_0x2d46();let _0x125f8b=_0x2d464d[_0x2322b8];return _0x125f8b;}(function(_0x8d2d5b,_0x4b8ce8){const _0x5707e7=a1_0x125f,_0x4f4026=_0x8d2d5b();while(!![]){try{const _0x37fee5=-parseInt(_0x5707e7(0xb2))/0x1+-parseInt(_0x5707e7(0x128))/0x2*(parseInt(_0x5707e7(0xc9))/0x3)+-parseInt(_0x5707e7(0xe9))/0x4*(parseInt(_0x5707e7(0x11c))/0x5)+parseInt(_0x5707e7(0x10f))/0x6+parseInt(_0x5707e7(0x10c))/0x7+parseInt(_0x5707e7(0xf4))/0x8+-parseInt(_0x5707e7(0xf2))/0x9*(-parseInt(_0x5707e7(0xd1))/0xa);if(_0x37fee5===_0x4b8ce8)break;else _0x4f4026['push'](_0x4f4026['shift']());}catch(_0x203ac8){_0x4f4026['push'](_0x4f4026['shift']());}}}(a1_0x2d46,0x2df3a));var __importDefault=this&&this['__importDefault']||function(_0x39459d){const _0x115bea=a1_0x125f;return _0x39459d&&_0x39459d[_0x115bea(0xa9)]?_0x39459d:{'default':_0x39459d};};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a1_0x456413(0xfd)]=saveClientConfig,exports[a1_0x456413(0xf6)]=resetApiKeyCfg,exports[a1_0x456413(0xdc)]=scheduleApiKeyCfgDailyReset,exports[a1_0x456413(0xd6)]=settingLabel,exports[a1_0x456413(0x104)]=rotateApiKey,exports[a1_0x456413(0x11f)]=pickValidApiKey,exports[a1_0x456413(0xc4)]=ensureSettingsWithApiKey,exports[a1_0x456413(0xc7)]=isQuotaExhaustedError,exports['isAuthenticationError']=isAuthenticationError,exports[a1_0x456413(0x121)]=readApiKeyFromSettings,exports[a1_0x456413(0xea)]=getForceEnabledSettingsPath,exports['startupCheck']=startupCheck;function a1_0x2d46(){const _0x445905=['default','slice',']\x20==============================\x0a','./session','clientSecret\x20(钉钉\x20Stream\x20Client\x20密钥)','\x20个群配置','settings-tpl.json\x20根元素不是对象','apiKeyCfg.claudeSettings\x20为空,无可用\x20Key','29215HYPKIS','.cc-ding','whiteUserList','pickValidApiKey','keys','readApiKeyFromSettings','claudeSettings','getHomeDir','ANTHROPIC_AUTH_TOKEN','claude\x20命令不可用,请确认\x20Claude\x20Code\x20CLI\x20已安装','CLAUDE_SMALL_FAST_MODEL','settings-tpl.json','34faJCWU','settings-tpl.json\x20解析失败:\x20','exit','toISOString','...','PASS','level','settings-tpl.json\x20不存在:\x20','\x20警告,\x20','getFullYear','dateUtil','push','__esModule','linkConversationId','getClientDir','getMonth',',\x20model:\x20','isArray','config.json\x20','timestamp','clientSecret','256485YBmdUB','群工作目录已就绪:\x20','add','settings-tpl.json\x20有效,env\x20包含:\x20','filter','owner\x20(机器人\x20owner)','pipe','conversationId','\x20致命','which\x20claude','apiKey','apiKeyCfg.claudeSettings\x20不是数组,API\x20Key\x20轮换功能不可用','\x20缺少\x20apiKey','conversations[','random','\x20isValid\x20类型异常:\x20','config.json\x20缺少必填字段:\x20',']\x20启动自检发现致命错误,进程退出','ensureSettingsWithApiKey','[WARN]\x20','settings-ding.json','isQuotaExhaustedError','\x20conversationId\x20重复:\x20','46971EZvtsP','path','conversations','工作目录不可写:\x20','join','some','message','readFileSync','4078590VtDhNZ','群工作目录创建失败:\x20',']\x20已写入\x20Claude\x20配置到\x20','utf-8','resetTime','settingLabel','test','env',',\x20smallModel:\x20',']\x20apiKeyCfg\x20已重置\x20(所有\x20Claude\x20Setting\x20isValid=true)','\x20缺少\x20model','scheduleApiKeyCfgDailyReset','apiKeyCfg','boolean',']\x20从模板创建\x20settings-ding.json:\x20','conversations\x20共\x20','getConversationDir','existsSync','conversations\x20为空数组,可通过\x20/reg\x20命令动态注册','model','FATAL','format','baseUrl','log','140tCFMSL','getForceEnabledSettingsPath','conversationTitle','has','\x20—\x20','\x20apiKey\x20重复:\x20','stringify','WARN','memo','9SeODzh','isValid','509520wkVQIN','\x20缺少\x20conversationId','resetApiKeyCfg',',创建\x20settings-ding.json\x20时将使用空模板','utils-ok','getTime','writeFileSync','/config.json',']\x20检测到\x20settings-ding.json\x20FORCE_ENABLE=','saveClientConfig','getDate',']\x20==========\x20启动自检\x20==========','length','claude\x20命令可用',']\x20Claude\x20Setting\x20已失效:\x20','\x22\x20未在\x20conversations\x20中找到','rotateApiKey','ANTHROPIC_BASE_URL','parse','\x20项,有效\x20','owner','smallModel','object',']\x20apiKeyCfg\x20每日重置已调度,下次重置:\x20','671349pwfSYb','\x20通过,\x20','apiKeyCfg.claudeSettings\x20共\x20','2087526KwKxzg','.claude','ANTHROPIC_MODEL','config','find'];a1_0x2d46=function(){return _0x445905;};return a1_0x2d46();}const fs_1=__importDefault(require('fs')),path_1=__importDefault(require(a1_0x456413(0xca))),child_process_1=require('child_process'),session_1=require(a1_0x456413(0x117)),utils_ok_1=require(a1_0x456413(0xf8));function saveClientConfig(_0x57d208){const _0x24e7bb=a1_0x456413,_0x491d4b=_0x57d208[_0x24e7bb(0xab)]()+_0x24e7bb(0xfb);try{fs_1['default'][_0x24e7bb(0xfa)](_0x491d4b,JSON[_0x24e7bb(0xef)](_0x57d208[_0x24e7bb(0x112)],null,0x2),'utf-8');}catch(_0xee673){console['error']('['+(0x0,session_1[_0x24e7bb(0xb0)])()+']\x20保存\x20config.json\x20失败:',_0xee673);}}function resetApiKeyCfg(_0x2a9ab5){const _0x46343e=a1_0x456413,_0x585bc4=_0x2a9ab5[_0x46343e(0x112)][_0x46343e(0xdd)];if(!_0x585bc4)return;const _0x35e080=new Date();_0x585bc4['resetTime']=utils_ok_1[_0x46343e(0xa7)]['mm'](_0x35e080[_0x46343e(0xf9)]())[_0x46343e(0xe6)]('YYYY-MM-DD\x20HH:mm:ss');let _0xe07065=0x0;for(const _0x3bb3d3 of _0x585bc4['claudeSettings']){!_0x3bb3d3[_0x46343e(0xf3)]&&(_0x3bb3d3['isValid']=!![],_0xe07065++);}_0xe07065>0x0&&console[_0x46343e(0xe8)]('['+(0x0,session_1[_0x46343e(0xb0)])()+']\x20'+_0xe07065+'\x20个已失效\x20Claude\x20Setting\x20重新标记为有效'),saveClientConfig(_0x2a9ab5),console[_0x46343e(0xe8)]('['+(0x0,session_1[_0x46343e(0xb0)])()+_0x46343e(0xda));}function scheduleApiKeyCfgDailyReset(_0x23c28b){const _0x5138b2=()=>{const _0x54fbae=a1_0x125f,_0x4abd55=new Date(),_0x431ffc=new Date(_0x4abd55[_0x54fbae(0x131)](),_0x4abd55[_0x54fbae(0xac)](),_0x4abd55[_0x54fbae(0xfe)]()+0x1,0x0,0x0,0x0,0x0),_0x53e0be=_0x431ffc[_0x54fbae(0xf9)]()-_0x4abd55[_0x54fbae(0xf9)]();setTimeout(()=>{const _0x337bc5=_0x54fbae;console[_0x337bc5(0xe8)]('['+(0x0,session_1[_0x337bc5(0xb0)])()+']\x20定时重置\x20apiKeyCfg\x20(每天0点)'),resetApiKeyCfg(_0x23c28b),_0x5138b2();},_0x53e0be),console[_0x54fbae(0xe8)]('['+(0x0,session_1[_0x54fbae(0xb0)])()+_0x54fbae(0x10b)+_0x431ffc[_0x54fbae(0x12b)]());};_0x5138b2();}function settingLabel(_0x349385){const _0xd39266=a1_0x456413;return _0x349385[_0xd39266(0xf1)]?_0x349385[_0xd39266(0xf1)]:_0xd39266(0x12c)+_0x349385[_0xd39266(0xbc)][_0xd39266(0x115)](-0x6);}function findSettingLabel(_0x216c79,_0x8db208){const _0x55955a=a1_0x456413,_0x30e9d6=_0x216c79[_0x55955a(0x113)](_0x245786=>_0x245786['apiKey']===_0x8db208);return _0x30e9d6?settingLabel(_0x30e9d6):_0x55955a(0x12c)+_0x8db208['slice'](-0x6);}function rotateApiKey(_0x5dfeeb,_0x4fbfe4){const _0x218b8b=a1_0x456413,_0x12c5f6=_0x5dfeeb[_0x218b8b(0x112)]['apiKeyCfg'];if(!_0x12c5f6)return null;for(const _0x55972d of _0x12c5f6['claudeSettings']){if(_0x55972d[_0x218b8b(0xbc)]===_0x4fbfe4&&_0x55972d['isValid']){_0x55972d[_0x218b8b(0xf3)]=![];break;}}const _0x530b84=_0x12c5f6[_0x218b8b(0x122)]['filter'](_0xc75af3=>_0xc75af3[_0x218b8b(0xf3)])[_0x218b8b(0x100)],_0x1507ca=findSettingLabel(_0x12c5f6[_0x218b8b(0x122)],_0x4fbfe4);return console[_0x218b8b(0xe8)]('['+(0x0,session_1[_0x218b8b(0xb0)])()+_0x218b8b(0x102)+_0x1507ca+',\x20剩余有效:\x20'+_0x530b84),saveClientConfig(_0x5dfeeb),pickValidApiKey(_0x5dfeeb);}function pickValidApiKey(_0x3eb232){const _0x312d9a=a1_0x456413,_0x3bfbb7=_0x3eb232[_0x312d9a(0x112)]['apiKeyCfg'];if(!_0x3bfbb7)return null;const _0xe7ac5=_0x3bfbb7[_0x312d9a(0x122)][_0x312d9a(0xb6)](_0xe5f137=>_0xe5f137[_0x312d9a(0xf3)]);if(_0xe7ac5['length']===0x0)return null;return _0xe7ac5[Math['floor'](Math[_0x312d9a(0xc0)]()*_0xe7ac5[_0x312d9a(0x100)])];}function ensureSettingsWithApiKey(_0x403d89,_0x42d31e){const _0x243186=a1_0x456413,_0x5b20ce=path_1[_0x243186(0x114)]['join'](_0x403d89,_0x243186(0x110)),_0x448ece=path_1[_0x243186(0x114)][_0x243186(0xcd)](_0x5b20ce,'settings-ding.json');let _0x527e0a={};if(fs_1[_0x243186(0x114)]['existsSync'](_0x448ece))try{_0x527e0a=JSON['parse'](fs_1[_0x243186(0x114)][_0x243186(0xd0)](_0x448ece,_0x243186(0xd4)));}catch{_0x527e0a={};}else{const _0x2da54f=path_1['default'][_0x243186(0xcd)]((0x0,session_1[_0x243186(0x123)])(),_0x243186(0x11d),_0x243186(0x127));if(fs_1[_0x243186(0x114)][_0x243186(0xe2)](_0x2da54f))try{_0x527e0a=JSON[_0x243186(0x106)](fs_1['default'][_0x243186(0xd0)](_0x2da54f,_0x243186(0xd4))),console[_0x243186(0xe8)]('['+(0x0,session_1[_0x243186(0xb0)])()+_0x243186(0xdf)+_0x2da54f);}catch{_0x527e0a={};}}!_0x527e0a[_0x243186(0xd8)]&&(_0x527e0a[_0x243186(0xd8)]={});let _0x536c7e=![];_0x527e0a[_0x243186(0xd8)][_0x243186(0x124)]!==_0x42d31e['apiKey']&&(_0x527e0a[_0x243186(0xd8)][_0x243186(0x124)]=_0x42d31e[_0x243186(0xbc)],_0x536c7e=!![]);_0x42d31e[_0x243186(0xe7)]&&_0x527e0a[_0x243186(0xd8)]['ANTHROPIC_BASE_URL']!==_0x42d31e[_0x243186(0xe7)]&&(_0x527e0a[_0x243186(0xd8)][_0x243186(0x105)]=_0x42d31e[_0x243186(0xe7)],_0x536c7e=!![]);_0x42d31e[_0x243186(0xe4)]&&_0x527e0a['env'][_0x243186(0x111)]!==_0x42d31e[_0x243186(0xe4)]&&(_0x527e0a['env'][_0x243186(0x111)]=_0x42d31e[_0x243186(0xe4)],_0x536c7e=!![]);const _0x29297a=_0x42d31e[_0x243186(0x109)]||_0x42d31e['model'];return _0x29297a&&_0x527e0a['env'][_0x243186(0x126)]!==_0x29297a&&(_0x527e0a[_0x243186(0xd8)]['CLAUDE_SMALL_FAST_MODEL']=_0x29297a,_0x536c7e=!![]),_0x536c7e&&(fs_1[_0x243186(0x114)]['mkdirSync'](_0x5b20ce,{'recursive':!![]}),fs_1[_0x243186(0x114)][_0x243186(0xfa)](_0x448ece,JSON['stringify'](_0x527e0a,null,0x2),_0x243186(0xd4)),console[_0x243186(0xe8)]('['+(0x0,session_1[_0x243186(0xb0)])()+_0x243186(0xd3)+_0x448ece+'\x20('+settingLabel(_0x42d31e)+_0x243186(0xad)+_0x42d31e[_0x243186(0xe4)]+_0x243186(0xd9)+_0x29297a+')')),_0x448ece;}function isQuotaExhaustedError(_0x1eca93){const _0x5642fb=a1_0x456413;if(/Request\s+rejected.*429/i[_0x5642fb(0xd7)](_0x1eca93))return!![];if(/429.*Request\s+rejected/i['test'](_0x1eca93))return!![];if(/429.*(?:超过.*上限|使用上限|配额|quota|capacity)/i[_0x5642fb(0xd7)](_0x1eca93))return!![];if(/(?:超过.*上限|使用上限|配额|quota|capacity).*429/i[_0x5642fb(0xd7)](_0x1eca93))return!![];return![];}function isAuthenticationError(_0x434481){const _0x5285ad=a1_0x456413;if(/authentication_error/i[_0x5285ad(0xd7)](_0x434481))return!![];if(/401.*(?:未授权|unauthorized|invalid\s*(?:key|token|api)|auth)/i[_0x5285ad(0xd7)](_0x434481))return!![];if(/(?:未授权|unauthorized|invalid\s*(?:key|token|api)|auth).*401/i['test'](_0x434481))return!![];return![];}function readApiKeyFromSettings(_0x31972b){const _0x201b62=a1_0x456413,_0x239751=path_1[_0x201b62(0x114)][_0x201b62(0xcd)](_0x31972b,'.claude',_0x201b62(0xc6));if(!fs_1[_0x201b62(0x114)][_0x201b62(0xe2)](_0x239751))return null;try{const _0xe85b1a=JSON[_0x201b62(0x106)](fs_1[_0x201b62(0x114)][_0x201b62(0xd0)](_0x239751,_0x201b62(0xd4)));return _0xe85b1a[_0x201b62(0xd8)]?.[_0x201b62(0x124)]||null;}catch{return null;}}function getForceEnabledSettingsPath(_0x35eef9){const _0xe00be4=a1_0x456413,_0x19a6c5=path_1['default'][_0xe00be4(0xcd)](_0x35eef9,_0xe00be4(0x110),'settings-ding.json');if(!fs_1[_0xe00be4(0x114)]['existsSync'](_0x19a6c5))return null;try{const _0x1c2687=JSON[_0xe00be4(0x106)](fs_1[_0xe00be4(0x114)][_0xe00be4(0xd0)](_0x19a6c5,_0xe00be4(0xd4))),_0x4ee1d3=_0x1c2687[_0xe00be4(0xd8)]?.['FORCE_ENABLE'];if(_0x4ee1d3!==undefined&&_0x4ee1d3!==![]&&_0x4ee1d3!=='')return console[_0xe00be4(0xe8)]('['+(0x0,session_1[_0xe00be4(0xb0)])()+_0xe00be4(0xfc)+_0x4ee1d3+',强制使用该配置'),_0x19a6c5;return null;}catch{return null;}}function startupCheck(_0x2f159f){const _0xa5f20c=a1_0x456413,_0x5dc717=[],_0x4ff22e=_0x2f159f['config'],_0x220af4=_0x2f159f[_0xa5f20c(0xab)](),_0x491db5=[{'key':_0xa5f20c(0xb1),'label':_0xa5f20c(0x118)},{'key':_0xa5f20c(0x11e),'label':'whiteUserList\x20(白名单用户)'},{'key':_0xa5f20c(0x108),'label':_0xa5f20c(0xb7)}];for(const {key:_0xb88534,label:_0x471542}of _0x491db5){const _0x50b952=_0x4ff22e[_0xb88534];_0x50b952===undefined||_0x50b952===null||_0x50b952===''||Array[_0xa5f20c(0xae)](_0x50b952)&&_0x50b952[_0xa5f20c(0x100)]===0x0?_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xe5),'message':_0xa5f20c(0xc2)+_0x471542}):_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0x12d),'message':_0xa5f20c(0xaf)+_0x471542+'\x20✓'});}if(!Array[_0xa5f20c(0xae)](_0x4ff22e[_0xa5f20c(0xcb)]))_0x5dc717[_0xa5f20c(0xa8)]({'level':'FATAL','message':'conversations\x20应为数组或已配置'});else{if(_0x4ff22e['conversations'][_0xa5f20c(0x100)]===0x0)_0x5dc717['push']({'level':_0xa5f20c(0x12d),'message':_0xa5f20c(0xe3)});else{const _0x405c9c=new Set();for(let _0x18a2a7=0x0;_0x18a2a7<_0x4ff22e[_0xa5f20c(0xcb)]['length'];_0x18a2a7++){const _0x482d52=_0x4ff22e[_0xa5f20c(0xcb)][_0x18a2a7],_0x202b21=_0xa5f20c(0xbf)+_0x18a2a7+']';if(!_0x482d52['conversationId'])_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xe5),'message':_0x202b21+_0xa5f20c(0xf5)});else _0x405c9c[_0xa5f20c(0xec)](_0x482d52['conversationId'])?_0x5dc717[_0xa5f20c(0xa8)]({'level':'WARN','message':_0x202b21+_0xa5f20c(0xc8)+_0x482d52['conversationId']}):_0x405c9c[_0xa5f20c(0xb4)](_0x482d52[_0xa5f20c(0xb9)]);_0x482d52[_0xa5f20c(0xaa)]&&!_0x4ff22e[_0xa5f20c(0xcb)][_0xa5f20c(0xce)](_0x3bd877=>_0x3bd877[_0xa5f20c(0xb9)]===_0x482d52[_0xa5f20c(0xaa)])&&_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':_0x202b21+'\x20linkConversationId\x20\x22'+_0x482d52['linkConversationId']+_0xa5f20c(0x103)});}_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0x12d),'message':_0xa5f20c(0xe0)+_0x4ff22e[_0xa5f20c(0xcb)]['length']+_0xa5f20c(0x119)});}}if(_0x4ff22e[_0xa5f20c(0xdd)]){const _0x45d464=_0x4ff22e[_0xa5f20c(0xdd)];_0x45d464['resetTime']&&_0x5dc717[_0xa5f20c(0xa8)]({'level':'PASS','message':'apiKeyCfg\x20上次重置时间:\x20'+_0x45d464[_0xa5f20c(0xd5)]});if(!Array['isArray'](_0x45d464[_0xa5f20c(0x122)]))_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':_0xa5f20c(0xbd)});else{if(_0x45d464[_0xa5f20c(0x122)][_0xa5f20c(0x100)]===0x0)_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':_0xa5f20c(0x11b)});else{const _0x2c2488=new Set();for(let _0xf2cc34=0x0;_0xf2cc34<_0x45d464[_0xa5f20c(0x122)][_0xa5f20c(0x100)];_0xf2cc34++){const _0x1078cc=_0x45d464['claudeSettings'][_0xf2cc34],_0x33dc9f='apiKeyCfg.claudeSettings['+_0xf2cc34+']';if(!_0x1078cc['apiKey'])_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xe5),'message':_0x33dc9f+_0xa5f20c(0xbe)});else _0x2c2488[_0xa5f20c(0xec)](_0x1078cc[_0xa5f20c(0xbc)])?_0x5dc717[_0xa5f20c(0xa8)]({'level':'WARN','message':_0x33dc9f+_0xa5f20c(0xee)+settingLabel(_0x1078cc)}):_0x2c2488['add'](_0x1078cc[_0xa5f20c(0xbc)]);!_0x1078cc[_0xa5f20c(0xe7)]&&_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':_0x33dc9f+'\x20缺少\x20baseUrl'}),!_0x1078cc[_0xa5f20c(0xe4)]&&_0x5dc717['push']({'level':_0xa5f20c(0xf0),'message':_0x33dc9f+_0xa5f20c(0xdb)}),typeof _0x1078cc[_0xa5f20c(0xf3)]!==_0xa5f20c(0xde)&&_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':_0x33dc9f+_0xa5f20c(0xc1)+typeof _0x1078cc['isValid']});}const _0x40e1fc=_0x45d464[_0xa5f20c(0x122)][_0xa5f20c(0xb6)](_0x441640=>_0x441640['isValid'])[_0xa5f20c(0x100)];_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0x12d),'message':_0xa5f20c(0x10e)+_0x45d464[_0xa5f20c(0x122)][_0xa5f20c(0x100)]+_0xa5f20c(0x107)+_0x40e1fc});}}}const _0x3dacab=path_1[_0xa5f20c(0x114)][_0xa5f20c(0xcd)]((0x0,session_1['getHomeDir'])(),_0xa5f20c(0x11d),'settings-tpl.json');if(fs_1[_0xa5f20c(0x114)][_0xa5f20c(0xe2)](_0x3dacab))try{const _0x2da787=JSON['parse'](fs_1['default'][_0xa5f20c(0xd0)](_0x3dacab,_0xa5f20c(0xd4)));if(typeof _0x2da787!==_0xa5f20c(0x10a)||_0x2da787===null)_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':_0xa5f20c(0x11a)});else{if(!_0x2da787[_0xa5f20c(0xd8)]||typeof _0x2da787[_0xa5f20c(0xd8)]!=='object')_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':'settings-tpl.json\x20缺少\x20env\x20字段,创建\x20settings-ding.json\x20时将不包含预配置环境变量'});else{const _0x3b17c1=Object[_0xa5f20c(0x120)](_0x2da787[_0xa5f20c(0xd8)]);_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0x12d),'message':_0xa5f20c(0xb5)+(_0x3b17c1['join'](',\x20')||'(空)')});}}}catch(_0x443629){_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xf0),'message':_0xa5f20c(0x129)+(_0x443629 instanceof Error?_0x443629['message']:_0x443629)});}else _0x5dc717['push']({'level':_0xa5f20c(0xf0),'message':_0xa5f20c(0x12f)+_0x3dacab+_0xa5f20c(0xf7)});try{(0x0,child_process_1['execSync'])(_0xa5f20c(0xbb),{'stdio':_0xa5f20c(0xb8)}),_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0x12d),'message':_0xa5f20c(0x101)});}catch{_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xe5),'message':_0xa5f20c(0x125)});}try{const _0xbbeccc=path_1[_0xa5f20c(0x114)][_0xa5f20c(0xcd)](_0x220af4,'.healthcheck');fs_1[_0xa5f20c(0x114)][_0xa5f20c(0xfa)](_0xbbeccc,'ok',_0xa5f20c(0xd4)),fs_1['default']['unlinkSync'](_0xbbeccc),_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0x12d),'message':'工作目录可写:\x20'+_0x220af4});}catch(_0x268cb2){_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0xe5),'message':_0xa5f20c(0xcc)+_0x220af4+_0xa5f20c(0xed)+(_0x268cb2 instanceof Error?_0x268cb2['message']:_0x268cb2)});}if(Array['isArray'](_0x4ff22e[_0xa5f20c(0xcb)]))for(const _0x9d62dc of _0x4ff22e[_0xa5f20c(0xcb)]){const _0x17023c=_0x2f159f[_0xa5f20c(0xe1)](_0x9d62dc[_0xa5f20c(0xb9)]);try{fs_1[_0xa5f20c(0x114)]['mkdirSync'](_0x17023c,{'recursive':!![]}),_0x5dc717[_0xa5f20c(0xa8)]({'level':_0xa5f20c(0x12d),'message':_0xa5f20c(0xb3)+(_0x9d62dc[_0xa5f20c(0xeb)]||_0x9d62dc['conversationId'])});}catch(_0x36c496){_0x5dc717[_0xa5f20c(0xa8)]({'level':'WARN','message':_0xa5f20c(0xd2)+_0x17023c+_0xa5f20c(0xed)+(_0x36c496 instanceof Error?_0x36c496[_0xa5f20c(0xcf)]:_0x36c496)});}}console[_0xa5f20c(0xe8)]('\x0a['+(0x0,session_1[_0xa5f20c(0xb0)])()+_0xa5f20c(0xff));const _0x47b19d=_0x5dc717[_0xa5f20c(0xce)](_0x2a2e30=>_0x2a2e30[_0xa5f20c(0x12e)]===_0xa5f20c(0xe5));for(const _0x21bd38 of _0x5dc717){const _0x1ceb28=_0x21bd38[_0xa5f20c(0x12e)]===_0xa5f20c(0x12d)?'✓':_0x21bd38[_0xa5f20c(0x12e)]===_0xa5f20c(0xe5)?'✗':'⚠',_0x4348c6=_0x21bd38[_0xa5f20c(0x12e)]===_0xa5f20c(0x12d)?_0x21bd38[_0xa5f20c(0xcf)]:_0x21bd38[_0xa5f20c(0x12e)]==='FATAL'?'[FATAL]\x20'+_0x21bd38[_0xa5f20c(0xcf)]:_0xa5f20c(0xc5)+_0x21bd38[_0xa5f20c(0xcf)];console['log']('\x20\x20'+_0x1ceb28+'\x20'+_0x4348c6);}const _0x45b838=_0x5dc717[_0xa5f20c(0xb6)](_0x5abbfb=>_0x5abbfb[_0xa5f20c(0x12e)]===_0xa5f20c(0x12d))[_0xa5f20c(0x100)],_0x21fbc1=_0x5dc717[_0xa5f20c(0xb6)](_0x4a3a62=>_0x4a3a62[_0xa5f20c(0x12e)]===_0xa5f20c(0xf0))[_0xa5f20c(0x100)],_0x4dc19c=_0x5dc717[_0xa5f20c(0xb6)](_0x25703d=>_0x25703d[_0xa5f20c(0x12e)]===_0xa5f20c(0xe5))[_0xa5f20c(0x100)];console['log']('['+(0x0,session_1[_0xa5f20c(0xb0)])()+']\x20自检完成:\x20'+_0x45b838+_0xa5f20c(0x10d)+_0x21fbc1+_0xa5f20c(0x130)+_0x4dc19c+_0xa5f20c(0xba)),console[_0xa5f20c(0xe8)]('['+(0x0,session_1[_0xa5f20c(0xb0)])()+_0xa5f20c(0x116)),_0x47b19d&&(console['error']('['+(0x0,session_1[_0xa5f20c(0xb0)])()+_0xa5f20c(0xc3)),process[_0xa5f20c(0x12a)](0x1));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';const a2_0x329fca=a2_0x10b9;(function(_0x5542c0,_0x171672){const _0x362225=a2_0x10b9,_0x17d9f5=_0x5542c0();while(!![]){try{const _0x259393=-parseInt(_0x362225(0xfe))/0x1*(-parseInt(_0x362225(0x22c))/0x2)+-parseInt(_0x362225(0xf9))/0x3+parseInt(_0x362225(0x1e1))/0x4+parseInt(_0x362225(0x189))/0x5*(-parseInt(_0x362225(0x1d6))/0x6)+-parseInt(_0x362225(0x147))/0x7*(parseInt(_0x362225(0x10f))/0x8)+-parseInt(_0x362225(0x1f8))/0x9+parseInt(_0x362225(0xfb))/0xa;if(_0x259393===_0x171672)break;else _0x17d9f5['push'](_0x17d9f5['shift']());}catch(_0x4778bd){_0x17d9f5['push'](_0x17d9f5['shift']());}}}(a2_0x1145,0x26125));function a2_0x1145(){const _0x3848d3=['parseCfgCommand','getDirectoryStructure','assistant','getClientConfig','\x20行日志:\x0a```\x0a','抱歉,该群的机器人未在服务端注册,请联系应用机器人owner注册(','__esModule','⚠️\x20目录已存在:\x20`','whiteUserList','resolve','linkConversationId','cleanCache','parseOpenCommand','interruptClaudeProcess','抱歉,您暂无使用权限,请联系应用机器人owner授权...','-\x20**linkConversationId:**\x20','resolveAllPhonesInConfig','del','恢复定时任务\x20','exec','parseContinueSessionCommand','19792WZReBZ','❌\x20文件创建失败:\x20`','getOwnPropertyNames','type','🚀\x20请输入您的问题开始新会话','parseResetApiKeyCfgCommand',']\x20注册新群:\x20','未找到定时任务:\x20','cancel','robotCode','formatHelpOverview','⚠️\x20文件已存在:\x20`','picture','../','input','loadActiveSessions','-\x20**群ID:**\x20','isOwner','sanitizeOutput','job','YYYY-MM-DD\x20HH:mm:ss','isValidCronExpression','robot','**版本:**\x20','(无历史数据)','列出\x20','findSubdirByName','catch','messageId','./task','DEFAULT_TASK_HANDLER_COUNT','\x20到当前群白名单\x0a当前白名单:\x20','CronEngine','claudeSettings','🧹\x20缓存清理完成',']\x20创建工作目录:\x20','finishTask','parseVersionCommand','⚠️\x20无法解析手机号:\x20','(无输出)','dingStreamClient','parse','parseMqCommand','cronEngine','getSessionsDir','findActiveSession','activeSessions','###\x20💬\x20当前会话信息\x0a','\x0a\x0a💡\x20你也可以直接指定cron表达式:\x20`/cron\x200\x209\x20*\x20*\x20*\x20任务描述`','then','utf-8',']\x20任务处理器数量:\x20','YYYY-MM-DD-HH-mm-ss','useLocalOcr','90072zUWnnX','isMobile','373780IqRHTY','min','handleMkdirCommand','23VBjaHJ','formatConversationInfo','getClientDir','errors','data','**\x20已暂停','getOrCreateLogSession','path','../common','-\x20图片文件:\x20','层):\x0a```\x0a','sessionsDeleted','isArray','📭\x20当前无排队消息','✅\x20已移除\x20','trim','📋\x20任务已收到,完成后我会回复','138936RGNYds','getOneTodoTask','❌\x20路径已存在但不是文件:\x20`',',\x20会话ID=','atSender','dateUtil','error','connect','folder','description','###\x20🤖\x20群配置信息\x0a','./messaging','📂\x20工作目录:\x20`','-\x20**群名称:**\x20','formatGlobalConfig','parsePwdCommand','DingClaude','cmd.exe','❌\x20未找到命令:\x20**','###\x20💬\x20当前会话信息\x0a无活跃会话','some','/cron\x20list','startsWith','clientSecret','senderNick','❌\x20只有机器人\x20owner\x20才能执行此操作','parseBashCommand','conversationTitle','getSessionId','runTaskHandlerLoop','substring','log','⚠️\x20该群未注册,请先使用\x20`/cfg`\x20命令注册','❌\x20删除失败:\x20`','exit','parseHelpCommand','headers','quoteText','processRichTextMessage','prototype','count','open\x20\x22','staffId','resetTime','get','sendDingMessage','(空,使用全局白名单)','mkdirSync','\x0a⚠️\x20错误:\x20','content','list','✅\x20群已注册','scheduleApiKeyCfgDailyReset','pictureDownloadCode','writeFileSync','unlinkSync','21QlstRB','收到消息:\x20群=','Fatal\x20error','toggleJob','\x0a...(输出已截断)','/cron\x20delete\x20','###\x20📝\x20任务队列信息\x0a','resume','✅\x20文件创建成功:\x20`','📂\x20已在文件管理器中打开:\x0a```\x0a','findHistorySession','conversationId','formatCronJobInfo','resolveAndValidatePath','dingToken','switchToSession','📋\x20最近\x20','slice','isDirectory','userIdToPhone','endSession','dirname','❌\x20定时任务分析失败:\x20','当前工作目录','cronExpression','run','**\x20已删除','startupCheck','clientId','hasOwnProperty','\x0a\x0a**stderr:**\x0a```\x0a','findIndex','existsSync','\x20条消息','session','replace','收到新会话命令,结束旧会话:\x20群=','parseCommandHelp','###\x20🌐\x20全局核心配置\x0a','✅\x20已从队尾移除\x20','appendSessionLog','sanitizeLogContent','parseClaudeStreamLine','getPkgVersion','registerCallbackListener','❌\x20路径不存在:\x20`','resetApiKeyCfg','__importStar','markdown','defineProperty','sessionDir','mtime',',\x20内容=','removeJob','/cron\x20','\x20已在当前群白名单中','tasksDeleted','(未配置群级白名单,使用全局白名单)','`\x0a原因:\x20','/cron\x20pause\x20','join','parseInfoCommand','./api-key-manager','未注册的机器人,群:','projUtil','timestamp','10gNmwwk','**\x20的目录','call','defaultDingToken','...','formatCronJobList','⚠️\x20当前无活跃会话或暂无日志','create_nl','DEFAULT_SESSION_MAX_CONCURRENCY','\x0a```','delete','✅\x20群配置已刷新','),\x20类型=','❌\x20当前群未配置\x20dingToken\x20且无客户端级\x20defaultDingToken,\x20定时任务无法主动发送消息,\x20请联系管理员配置','open\x20-a\x20Terminal\x20\x22','/session.log',':**\x20','message','debugLog','sendClaudeResponseToDing','conversations','getSessionDir','❌\x20路径超出工作目录范围','创建定时任务:\x20','getConversationConfig','⏳\x20正在分析定时任务描述...','requireOwner',']\x20[SYSTEM]:\x20创建会话用于记录\x20/cron\x20命令操作\x0a','quoteMessageId','[cron]','format',']\x20刷新群配置:\x20','handleTask','formatSessionInfo','./session','./image','richText','imagesDeleted','map','senderStaffId','length','test','startNewSession','saveActiveSession','pause','create','\x20个定时任务','root','handleRmCommand','getTasksDir','authCheck','updateSessionFile','-\x20**receiveReply:**\x20false\x20(不回复确认消息)','apiKeyCfg','darwin','parseCleanCommand','key','push','-\x20会话目录:\x20','⚠️\x20未配置\x20apiKeyCfg,无需重置','.\x20**','user','statSync','preBash','/task\x20','configurable','handleSessionMessage','default','📂\x20当前工作目录:\x0a```\x0a','text','/v1.0/im/bot/messages/get','socketCallBackResponse','删除定时任务\x20','-\x20**atSender:**\x20false\x20(不\x20@\x20发送人)','),\x20发送者=','create_cron','▶️\x20定时任务\x20**','204030qXnQJa',':\x20`','\x20&&\x20','formatTaskInfo','getCommandByName','sendCronNoNotifyError','receiveReply','-\x20**dingToken:**\x20','❌\x20未找到定时任务:\x20','formatCommandHelp','config','1083060RhKhxh','✅\x20已清空消息队列,共移除\x20','resolveToUserId','add','/cron\x20resume\x20','rmSync','processPictureMessage','/session.json','formatPromptWithQuote','handleCronCommand','botMsgGetCallback','resolveUserId','检测到引用消息:\x20quoteMessageId=','now','saveClientConfig','filter','prompt','appendFileSync','conversationConfig','⚠️\x20','\x0a💡\x20活跃会话已保留','parseLsCommand','Error:\x20DingStreamClient\x20init\x20failed.','2067075rZLDEM','truncateMsg','start','⚠️\x20未找到已结束的会话','findLatestSession','writable','hashConversationId','saveTask','`\x0a\x0a💡\x20格式:\x20`分\x20时\x20日\x20月\x20周`,如\x20`0\x209\x20*\x20*\x20*`','\x20(展开','\x20错误:','❌\x20路径已存在但不是目录:\x20`','all','getConversationDir','hasNotifyCapability','\x20不在当前群白名单中','❌\x20无效的cron表达式:\x20`','parseCronCommand','❌\x20打开失败:\x20','⏸️\x20定时任务\x20**','任务处理器\x20#','handleTouchCommand','❌\x20路径不能使用绝对路径(不能以\x20/\x20开头)','task','messageQueue','\x20条)\x0a','readSessionLogTail','parseAuthCommand','cancelTask','debug','./commands'];a2_0x1145=function(){return _0x3848d3;};return a2_0x1145();}var __createBinding=this&&this['__createBinding']||(Object[a2_0x329fca(0x1b6)]?function(_0x2f07c2,_0x142867,_0x2fbbaa,_0x2ac65d){const _0x10a097=a2_0x329fca;if(_0x2ac65d===undefined)_0x2ac65d=_0x2fbbaa;var _0x1d16cf=Object['getOwnPropertyDescriptor'](_0x142867,_0x2fbbaa);(!_0x1d16cf||(_0x10a097(0x13b)in _0x1d16cf?!_0x142867[_0x10a097(0x21d)]:_0x1d16cf[_0x10a097(0x1fd)]||_0x1d16cf[_0x10a097(0x1ca)]))&&(_0x1d16cf={'enumerable':!![],'get':function(){return _0x142867[_0x2fbbaa];}}),Object['defineProperty'](_0x2f07c2,_0x2ac65d,_0x1d16cf);}:function(_0x43d527,_0x39c9b5,_0x6d7f0b,_0x141a4){if(_0x141a4===undefined)_0x141a4=_0x6d7f0b;_0x43d527[_0x141a4]=_0x39c9b5[_0x6d7f0b];}),__setModuleDefault=this&&this['__setModuleDefault']||(Object['create']?function(_0x30dcb4,_0xbb47bc){const _0x4f2e4b=a2_0x329fca;Object[_0x4f2e4b(0x178)](_0x30dcb4,_0x4f2e4b(0x1cc),{'enumerable':!![],'value':_0xbb47bc});}:function(_0x1a93ed,_0x2f837b){const _0x872ea9=a2_0x329fca;_0x1a93ed[_0x872ea9(0x1cc)]=_0x2f837b;}),__importStar=this&&this[a2_0x329fca(0x176)]||(function(){var _0xf9724c=function(_0x255b24){const _0x4e249f=a2_0x10b9;return _0xf9724c=Object[_0x4e249f(0xc5)]||function(_0x417bd0){const _0x32a63e=_0x4e249f;var _0x4e2693=[];for(var _0x58bdc0 in _0x417bd0)if(Object[_0x32a63e(0x136)][_0x32a63e(0x164)][_0x32a63e(0x18b)](_0x417bd0,_0x58bdc0))_0x4e2693[_0x4e2693['length']]=_0x58bdc0;return _0x4e2693;},_0xf9724c(_0x255b24);};return function(_0x9ddee8){const _0x1ebeff=a2_0x10b9;if(_0x9ddee8&&_0x9ddee8['__esModule'])return _0x9ddee8;var _0x4e9a90={};if(_0x9ddee8!=null){for(var _0x3565bd=_0xf9724c(_0x9ddee8),_0xe959ca=0x0;_0xe959ca<_0x3565bd[_0x1ebeff(0x1b1)];_0xe959ca++)if(_0x3565bd[_0xe959ca]!==_0x1ebeff(0x1cc))__createBinding(_0x4e9a90,_0x9ddee8,_0x3565bd[_0xe959ca]);}return __setModuleDefault(_0x4e9a90,_0x9ddee8),_0x4e9a90;};}()),__importDefault=this&&this['__importDefault']||function(_0x557c16){return _0x557c16&&_0x557c16['__esModule']?_0x557c16:{'default':_0x557c16};};Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[a2_0x329fca(0x11f)]=void 0x0;const child_process_1=require('child_process'),utils_ok_1=require('utils-ok'),fs_1=__importDefault(require('fs')),path_1=__importDefault(require(a2_0x329fca(0x105))),common_1=require(a2_0x329fca(0x106)),quote_1=require('./quote'),messaging_1=require(a2_0x329fca(0x11a)),image_1=require(a2_0x329fca(0x1ac)),commands_1=require(a2_0x329fca(0x216)),messaging_2=require(a2_0x329fca(0x11a)),claude_process_1=require('./claude-process'),session_1=require(a2_0x329fca(0x1ab)),task_1=require(a2_0x329fca(0xe0)),api_key_manager_1=require(a2_0x329fca(0x185)),cron_1=require('./cron'),TOOL_VERSION=(0x0,common_1[a2_0x329fca(0x187)])()[a2_0x329fca(0x172)]();function a2_0x10b9(_0x4049b3,_0x205724){_0x4049b3=_0x4049b3-0xc4;const _0x1145cb=a2_0x1145();let _0x10b954=_0x1145cb[_0x4049b3];return _0x10b954;}class DingClaude{constructor(_0x2f5d6d){const _0xd8edc3=a2_0x329fca;this['resolvedPhones']={},this['activeSessions']=new Map(),this[_0xd8edc3(0x191)]=0x5,this[_0xd8edc3(0xe1)]=0x1,this['DEFAULT_TASK_QUEUE_SIZE']=0x32,this[_0xd8edc3(0x13c)]=_0x1b0b06=>(0x0,messaging_2['sendDingMessage'])(this,_0x1b0b06),this[_0xd8edc3(0x19c)]=(_0x5197fb,_0x491163,_0x58edb9,_0x5a73e3)=>(0x0,messaging_2[_0xd8edc3(0x19c)])(this,_0x5197fb,_0x491163,_0x58edb9,_0x5a73e3),this[_0xd8edc3(0x171)]=claude_process_1[_0xd8edc3(0x171)],this[_0xd8edc3(0x224)]=(_0x47638c,_0x79ad43)=>(0x0,claude_process_1['interruptClaudeProcess'])(_0x47638c,_0x79ad43),this['executeClaudeQuery']=(_0x405116,_0x50fd35,_0x185226)=>(0x0,claude_process_1['executeClaudeQuery'])(this,_0x405116,_0x50fd35,_0x185226),this['getClientDir']=()=>(0x0,session_1[_0xd8edc3(0x100)])(this),this['getClientConfig']=()=>(0x0,session_1['getClientConfig'])(this),this['authCheck']=(_0x483b04,_0x44e30a)=>(0x0,session_1[_0xd8edc3(0x1bb)])(this,_0x483b04,_0x44e30a),this[_0xd8edc3(0xd4)]=_0x188620=>(0x0,session_1['isOwner'])(this,_0x188620),this[_0xd8edc3(0x19b)]=(_0x99234d,..._0x27d6e5)=>(0x0,session_1['debugLog'])(this,_0x99234d,..._0x27d6e5),this[_0xd8edc3(0x1fe)]=_0x32c440=>(0x0,session_1[_0xd8edc3(0x1fe)])(this,_0x32c440),this[_0xd8edc3(0x1a1)]=_0x1f1f4e=>(0x0,session_1[_0xd8edc3(0x1a1)])(this,_0x1f1f4e),this['getConversationDir']=_0x489e31=>(0x0,session_1[_0xd8edc3(0x205)])(this,_0x489e31),this['getSessionsDir']=_0x5981f4=>(0x0,session_1[_0xd8edc3(0xef)])(this,_0x5981f4),this[_0xd8edc3(0x1ba)]=_0x358cc5=>(0x0,session_1[_0xd8edc3(0x1ba)])(this,_0x358cc5),this[_0xd8edc3(0x19e)]=_0x42a90d=>(0x0,session_1[_0xd8edc3(0x19e)])(this,_0x42a90d),this['getSessionId']=session_1['getSessionId'],this[_0xd8edc3(0x1aa)]=_0x4036b6=>(0x0,session_1[_0xd8edc3(0x1aa)])(this,_0x4036b6),this[_0xd8edc3(0x212)]=(_0x14d796,_0x2920c9)=>(0x0,session_1[_0xd8edc3(0x212)])(this,_0x14d796,_0x2920c9),this[_0xd8edc3(0xf0)]=_0x2843af=>(0x0,session_1[_0xd8edc3(0xf0)])(this,_0x2843af),this[_0xd8edc3(0x151)]=(_0x1d429c,_0x56de56)=>(0x0,session_1[_0xd8edc3(0x151)])(this,_0x1d429c,_0x56de56),this[_0xd8edc3(0x1fc)]=_0x40cdae=>(0x0,session_1['findLatestSession'])(this,_0x40cdae),this[_0xd8edc3(0x1bc)]=(_0x3b0d71,_0x391b73)=>(0x0,session_1[_0xd8edc3(0x1bc)])(this,_0x3b0d71,_0x391b73),this[_0xd8edc3(0x16f)]=session_1[_0xd8edc3(0x16f)],this['getActiveSessionsFile']=_0x874941=>(0x0,session_1['getActiveSessionsFile'])(this,_0x874941),this[_0xd8edc3(0x1b4)]=_0x511f72=>(0x0,session_1['saveActiveSession'])(this,_0x511f72),this[_0xd8edc3(0xd2)]=()=>(0x0,session_1[_0xd8edc3(0xd2)])(this),this[_0xd8edc3(0x15b)]=(_0x34a2c1,_0x5c8a26)=>(0x0,session_1[_0xd8edc3(0x15b)])(this,_0x34a2c1,_0x5c8a26),this[_0xd8edc3(0x156)]=(_0x27befe,_0x2b6343,_0x7101b0,_0x3e9e44,_0x3742c)=>(0x0,session_1['switchToSession'])(this,_0x27befe,_0x2b6343,_0x7101b0,_0x3e9e44,_0x3742c),this[_0xd8edc3(0x1b3)]=_0x24046a=>(0x0,session_1['startNewSession'])(this,_0x24046a),this[_0xd8edc3(0x1cb)]=_0x4e3f06=>(0x0,session_1['handleSessionMessage'])(this,_0x4e3f06),this[_0xd8edc3(0x222)]=(_0x186035,_0x39fb62=!![])=>(0x0,session_1[_0xd8edc3(0x222)])(this,_0x186035,_0x39fb62),this['formatTaskInfo']=()=>(0x0,task_1[_0xd8edc3(0x1d9)])(this),this[_0xd8edc3(0x214)]=(_0x3ef2a9,_0x2cffc7)=>(0x0,task_1[_0xd8edc3(0x214)])(this,_0x3ef2a9,_0x2cffc7),this['countTodoTask']=()=>(0x0,task_1['countTodoTask'])(this),this[_0xd8edc3(0x110)]=()=>(0x0,task_1[_0xd8edc3(0x110)])(this),this[_0xd8edc3(0xe7)]=_0x546d15=>(0x0,task_1[_0xd8edc3(0xe7)])(this,_0x546d15),this[_0xd8edc3(0x1a9)]=()=>(0x0,task_1[_0xd8edc3(0x1a9)])(this),this['runTaskHandlerLoop']=()=>(0x0,task_1[_0xd8edc3(0x12c)])(this),this['saveTask']=_0x36f7be=>(0x0,task_1[_0xd8edc3(0x1ff)])(this,_0x36f7be),this[_0xd8edc3(0x163)]=_0x2f5d6d,this[_0xd8edc3(0x1e0)]=(0x0,session_1[_0xd8edc3(0x21a)])(this);try{this['dingStreamClient']=new utils_ok_1['DingStreamClient']({'clientId':_0x2f5d6d,'clientSecret':this[_0xd8edc3(0x1e0)][_0xd8edc3(0x126)],'keepAlive':!![],'debug':this['config'][_0xd8edc3(0x215)]??![]});}catch(_0x59b8a3){console[_0xd8edc3(0x115)](_0xd8edc3(0x1f7),_0x59b8a3),process[_0xd8edc3(0x131)](0x1);}this[_0xd8edc3(0xee)]=new cron_1[(_0xd8edc3(0xe3))](this);}async[a2_0x329fca(0x1a3)](_0x1cf830,_0x22ab33,_0x497684){const _0x3cf13b=a2_0x329fca;if(!this[_0x3cf13b(0xd4)](_0x497684))return await this['sendDingMessage']({'conversationId':_0x1cf830,'sessionWebhook':_0x22ab33,'content':_0x3cf13b(0x128),'msgType':_0x3cf13b(0x177)}),![];return!![];}async[a2_0x329fca(0x1ea)](_0x378f6b,_0x118549){const _0x1a8e6f=a2_0x329fca,{conversationId:_0x481411,sessionWebhook:_0x202309,senderStaffId:_0x488df6,senderNick:_0x419907,conversationConfig:_0x11abf7}=_0x118549;switch(_0x378f6b['type']){case _0x1a8e6f(0x141):{const _0x300963=await this['getOrCreateLogSession'](_0x481411,_0x202309,_0x488df6,_0x419907,_0x11abf7,!![]),_0x28cdde=this['cronEngine']['listJobs'](_0x481411);_0x300963[_0x1a8e6f(0x179)]&&(this['appendSessionLog'](_0x300963[_0x1a8e6f(0x179)],_0x1a8e6f(0x1c6),_0x1a8e6f(0x124)),this[_0x1a8e6f(0x16f)](_0x300963[_0x1a8e6f(0x179)],_0x1a8e6f(0x219),_0x1a8e6f(0xdc)+_0x28cdde[_0x1a8e6f(0x1b1)]+_0x1a8e6f(0x1b7)));await this['sendDingMessage']({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':(0x0,cron_1[_0x1a8e6f(0x18e)])(_0x28cdde),'msgType':_0x1a8e6f(0x177)});return;}case _0x1a8e6f(0x193):{const _0x5b39cb=this[_0x1a8e6f(0xee)][_0x1a8e6f(0x17c)](_0x378f6b['id']),_0x485c9f=await this[_0x1a8e6f(0x104)](_0x481411,_0x202309,_0x488df6,_0x419907,_0x11abf7);_0x485c9f[_0x1a8e6f(0x179)]&&(this['appendSessionLog'](_0x485c9f[_0x1a8e6f(0x179)],_0x1a8e6f(0x1c6),_0x1a8e6f(0x14c)+_0x378f6b['id']),this[_0x1a8e6f(0x16f)](_0x485c9f['sessionDir'],_0x1a8e6f(0x219),_0x5b39cb?_0x1a8e6f(0x1d1)+_0x378f6b['id']:'未找到定时任务:\x20'+_0x378f6b['id']));await this[_0x1a8e6f(0x13c)]({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':_0x5b39cb?'✅\x20定时任务\x20**'+_0x378f6b['id']+_0x1a8e6f(0x161):_0x1a8e6f(0x1de)+_0x378f6b['id'],'msgType':'markdown'});return;}case _0x1a8e6f(0x1b5):{const _0xc5a814=this['cronEngine'][_0x1a8e6f(0x14a)](_0x378f6b['id'],![]),_0x14e1e9=await this[_0x1a8e6f(0x104)](_0x481411,_0x202309,_0x488df6,_0x419907,_0x11abf7);_0x14e1e9[_0x1a8e6f(0x179)]&&(this[_0x1a8e6f(0x16f)](_0x14e1e9[_0x1a8e6f(0x179)],_0x1a8e6f(0x1c6),_0x1a8e6f(0x182)+_0x378f6b['id']),this[_0x1a8e6f(0x16f)](_0x14e1e9[_0x1a8e6f(0x179)],'assistant',_0xc5a814?'暂停定时任务\x20'+_0x378f6b['id']:_0x1a8e6f(0xca)+_0x378f6b['id']));await this['sendDingMessage']({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':_0xc5a814?_0x1a8e6f(0x20b)+_0x378f6b['id']+_0x1a8e6f(0x103):_0x1a8e6f(0x1de)+_0x378f6b['id'],'msgType':'markdown'});return;}case _0x1a8e6f(0x14e):{const _0x2cc1bf=this[_0x1a8e6f(0xee)][_0x1a8e6f(0x14a)](_0x378f6b['id'],!![]),_0x267d5e=await this[_0x1a8e6f(0x104)](_0x481411,_0x202309,_0x488df6,_0x419907,_0x11abf7);_0x267d5e[_0x1a8e6f(0x179)]&&(this['appendSessionLog'](_0x267d5e[_0x1a8e6f(0x179)],_0x1a8e6f(0x1c6),_0x1a8e6f(0x1e5)+_0x378f6b['id']),this[_0x1a8e6f(0x16f)](_0x267d5e[_0x1a8e6f(0x179)],_0x1a8e6f(0x219),_0x2cc1bf?_0x1a8e6f(0x229)+_0x378f6b['id']:_0x1a8e6f(0xca)+_0x378f6b['id']));await this['sendDingMessage']({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':_0x2cc1bf?_0x1a8e6f(0x1d5)+_0x378f6b['id']+'**\x20已恢复':_0x1a8e6f(0x1de)+_0x378f6b['id'],'msgType':_0x1a8e6f(0x177)});return;}case _0x1a8e6f(0x1d4):{if(!(0x0,cron_1[_0x1a8e6f(0xd8)])(_0x378f6b[_0x1a8e6f(0x15f)])){await this['sendDingMessage']({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':_0x1a8e6f(0x208)+_0x378f6b[_0x1a8e6f(0x15f)]+_0x1a8e6f(0x200),'msgType':_0x1a8e6f(0x177)});return;}if(!this[_0x1a8e6f(0x206)](_0x118549[_0x1a8e6f(0x1f3)])){await this['sendCronNoNotifyError'](_0x481411,_0x202309);return;}const _0x22dc6d=this[_0x1a8e6f(0xee)]['addJob']({'conversationId':_0x481411,'cronExpression':_0x378f6b[_0x1a8e6f(0x15f)],'description':this[_0x1a8e6f(0x170)](_0x378f6b[_0x1a8e6f(0x1f1)][_0x1a8e6f(0x12d)](0x0,0x32)),'prompt':_0x378f6b[_0x1a8e6f(0x1f1)],'senderStaffId':_0x488df6,'senderNick':_0x419907}),_0x38258e=await this[_0x1a8e6f(0x104)](_0x481411,_0x202309,_0x488df6,_0x419907,_0x11abf7);_0x38258e['sessionDir']&&(this['appendSessionLog'](_0x38258e[_0x1a8e6f(0x179)],'user','/cron\x20'+_0x378f6b['cronExpression']+'\x20'+this[_0x1a8e6f(0x170)](_0x378f6b[_0x1a8e6f(0x1f1)])),this['appendSessionLog'](_0x38258e[_0x1a8e6f(0x179)],_0x1a8e6f(0x219),_0x1a8e6f(0x1a0)+_0x22dc6d['id']+'\x20['+_0x22dc6d[_0x1a8e6f(0x15f)]+']\x20'+_0x22dc6d['description']));await this[_0x1a8e6f(0x13c)]({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':(0x0,cron_1['formatCronJobInfo'])(_0x22dc6d),'msgType':'markdown'});return;}case _0x1a8e6f(0x190):{if(!this[_0x1a8e6f(0x206)](_0x118549[_0x1a8e6f(0x1f3)])){await this[_0x1a8e6f(0x1db)](_0x481411,_0x202309);return;}await this[_0x1a8e6f(0x13c)]({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':_0x1a8e6f(0x1a2)});const _0x3c3008=await this['cronEngine']['analyzeAndCreate'](_0x481411,_0x378f6b[_0x1a8e6f(0xd1)],_0x488df6,_0x419907),_0x4e81d0=await this[_0x1a8e6f(0x104)](_0x481411,_0x202309,_0x488df6,_0x419907,_0x11abf7);_0x3c3008[_0x1a8e6f(0xd6)]?(_0x4e81d0[_0x1a8e6f(0x179)]&&(this[_0x1a8e6f(0x16f)](_0x4e81d0['sessionDir'],'user',_0x1a8e6f(0x17d)+this['sanitizeLogContent'](_0x378f6b[_0x1a8e6f(0xd1)])),this[_0x1a8e6f(0x16f)](_0x4e81d0['sessionDir'],_0x1a8e6f(0x219),_0x1a8e6f(0x1a0)+_0x3c3008[_0x1a8e6f(0xd6)]['id']+'\x20['+_0x3c3008[_0x1a8e6f(0xd6)]['cronExpression']+']\x20'+_0x3c3008[_0x1a8e6f(0xd6)][_0x1a8e6f(0x118)])),await this[_0x1a8e6f(0x13c)]({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':(0x0,cron_1[_0x1a8e6f(0x153)])(_0x3c3008[_0x1a8e6f(0xd6)]),'msgType':_0x1a8e6f(0x177)})):(_0x4e81d0['sessionDir']&&(this[_0x1a8e6f(0x16f)](_0x4e81d0[_0x1a8e6f(0x179)],_0x1a8e6f(0x1c6),_0x1a8e6f(0x17d)+this[_0x1a8e6f(0x170)](_0x378f6b['input'])),this[_0x1a8e6f(0x16f)](_0x4e81d0[_0x1a8e6f(0x179)],_0x1a8e6f(0x219),'定时任务分析失败:\x20'+_0x3c3008['error'])),await this[_0x1a8e6f(0x13c)]({'conversationId':_0x481411,'sessionWebhook':_0x202309,'content':_0x1a8e6f(0x15d)+_0x3c3008[_0x1a8e6f(0x115)]+_0x1a8e6f(0xf3),'msgType':_0x1a8e6f(0x177)}));return;}}}[a2_0x329fca(0x170)](_0x567ce1){const _0x1e03a9=a2_0x329fca;return _0x567ce1[_0x1e03a9(0x16a)](/\n/g,'\x5cn')[_0x1e03a9(0x16a)](/\r/g,'\x5cr');}[a2_0x329fca(0xd5)](_0x4b43e5){const _0x4cb791=a2_0x329fca,_0x437263=_0x4b43e5[_0x4cb791(0x16a)](/\r\n/g,'\x0a'),_0x40252a=0x1f40;if(_0x437263[_0x4cb791(0x1b1)]>_0x40252a)return _0x437263[_0x4cb791(0x12d)](0x0,_0x40252a)+_0x4cb791(0x14b);return _0x437263;}[a2_0x329fca(0x1f9)](_0x485920,_0x2122c2=0x64){const _0x4dbfe9=a2_0x329fca,_0x253949=_0x485920['replace'](/\n/g,'\x20')[_0x4dbfe9(0x10d)]();return _0x253949[_0x4dbfe9(0x1b1)]>_0x2122c2?_0x253949[_0x4dbfe9(0x158)](0x0,_0x2122c2)+_0x4dbfe9(0x18d):_0x253949;}async[a2_0x329fca(0x104)](_0x482ea8,_0x279fe8,_0x15aff8,_0x3a4431,_0x56dd1a,_0x291fdb=![]){const _0x5e0077=a2_0x329fca,_0x43a781=this['findActiveSession'](_0x482ea8);if(_0x43a781){const _0x5ebe77=this[_0x5e0077(0x19e)](_0x43a781[_0x5e0077(0x169)][_0x5e0077(0x169)]);return{'sessionDir':_0x5ebe77,'isNew':![]};}if(_0x291fdb)return{'sessionDir':null,'isNew':![]};const _0x106c40=Date[_0x5e0077(0x1ee)](),_0x53d75f={'conversationId':_0x482ea8,'sessionWebhook':_0x279fe8,'startTime':_0x106c40,'startTimeStr':utils_ok_1[_0x5e0077(0x114)]['mm'](_0x106c40)[_0x5e0077(0x1a7)](_0x5e0077(0xf7)),'startStaffId':_0x15aff8,'startNickName':_0x5e0077(0x1a6)+_0x3a4431},_0x31d97a=this['getSessionDir'](_0x53d75f);return fs_1['default'][_0x5e0077(0x13e)](_0x31d97a,{'recursive':!![]}),fs_1[_0x5e0077(0x1cc)][_0x5e0077(0x145)](_0x31d97a+_0x5e0077(0x1e8),JSON['stringify'](_0x53d75f,null,0x2),_0x5e0077(0xf5)),fs_1[_0x5e0077(0x1cc)][_0x5e0077(0x1f2)](_0x31d97a+_0x5e0077(0x198),'['+(0x0,session_1[_0x5e0077(0x188)])()+_0x5e0077(0x1a4),_0x5e0077(0xf5)),{'sessionDir':_0x31d97a,'isNew':!![]};}[a2_0x329fca(0x206)](_0x3ecc3f){const _0x3ae539=a2_0x329fca;return!!(_0x3ecc3f[_0x3ae539(0x155)]||this[_0x3ae539(0x1e0)][_0x3ae539(0x18c)]);}async[a2_0x329fca(0x1db)](_0x49a73c,_0x1554da){const _0x38fe6a=a2_0x329fca;await this[_0x38fe6a(0x13c)]({'conversationId':_0x49a73c,'sessionWebhook':_0x1554da,'content':_0x38fe6a(0x196),'msgType':'markdown'});}[a2_0x329fca(0x154)](_0x247ddb,_0x3470c5){const _0x3727a3=a2_0x329fca,_0x27d547=this[_0x3727a3(0x205)](_0x247ddb);if(_0x3470c5[_0x3727a3(0x125)]('/'))return{'absolutePath':'','error':_0x3727a3(0x20e)};const _0x476ced=path_1[_0x3727a3(0x1cc)][_0x3727a3(0x220)](_0x27d547,_0x3470c5);if(!_0x476ced[_0x3727a3(0x125)](_0x27d547))return{'absolutePath':'','error':_0x3727a3(0x19f)};return{'absolutePath':_0x476ced};}async[a2_0x329fca(0xfd)](_0xdba801,_0x3bf8c9,_0x445f0e){const _0x463cf1=a2_0x329fca,{absolutePath:_0x37321f,error:_0x4bb638}=this[_0x463cf1(0x154)](_0xdba801,_0x445f0e);if(_0x4bb638){await this[_0x463cf1(0x13c)]({'conversationId':_0xdba801,'sessionWebhook':_0x3bf8c9,'content':_0x4bb638,'msgType':_0x463cf1(0x177)});return;}try{const _0x286cf6=fs_1[_0x463cf1(0x1cc)][_0x463cf1(0x1c7)](_0x37321f);_0x286cf6[_0x463cf1(0x159)]()?await this[_0x463cf1(0x13c)]({'conversationId':_0xdba801,'sessionWebhook':_0x3bf8c9,'content':_0x463cf1(0x21e)+_0x445f0e+'`','msgType':'markdown'}):await this[_0x463cf1(0x13c)]({'conversationId':_0xdba801,'sessionWebhook':_0x3bf8c9,'content':_0x463cf1(0x203)+_0x445f0e+'`','msgType':'markdown'});return;}catch{}try{fs_1[_0x463cf1(0x1cc)][_0x463cf1(0x13e)](_0x37321f,{'recursive':!![]}),await this[_0x463cf1(0x13c)]({'conversationId':_0xdba801,'sessionWebhook':_0x3bf8c9,'content':'✅\x20目录创建成功:\x20`'+_0x445f0e+'`','msgType':_0x463cf1(0x177)});}catch(_0x4b0140){await this[_0x463cf1(0x13c)]({'conversationId':_0xdba801,'sessionWebhook':_0x3bf8c9,'content':'❌\x20目录创建失败:\x20`'+_0x445f0e+_0x463cf1(0x181)+(_0x4b0140 instanceof Error?_0x4b0140['message']:String(_0x4b0140)),'msgType':_0x463cf1(0x177)});}}async[a2_0x329fca(0x1b9)](_0x3e07cb,_0x3b97b5,_0x2db938){const _0x47c98e=a2_0x329fca,{absolutePath:_0x24c57f,error:_0xd9ed5e}=this[_0x47c98e(0x154)](_0x3e07cb,_0x2db938);if(_0xd9ed5e){await this[_0x47c98e(0x13c)]({'conversationId':_0x3e07cb,'sessionWebhook':_0x3b97b5,'content':_0xd9ed5e,'msgType':'markdown'});return;}let _0x40e076;try{_0x40e076=fs_1[_0x47c98e(0x1cc)][_0x47c98e(0x1c7)](_0x24c57f);}catch{await this['sendDingMessage']({'conversationId':_0x3e07cb,'sessionWebhook':_0x3b97b5,'content':_0x47c98e(0x174)+_0x2db938+'`','msgType':_0x47c98e(0x177)});return;}const _0x361338=_0x40e076[_0x47c98e(0x159)]();try{_0x361338?fs_1[_0x47c98e(0x1cc)][_0x47c98e(0x1e6)](_0x24c57f,{'recursive':!![],'force':!![]}):fs_1[_0x47c98e(0x1cc)][_0x47c98e(0x146)](_0x24c57f),await this[_0x47c98e(0x13c)]({'conversationId':_0x3e07cb,'sessionWebhook':_0x3b97b5,'content':'✅\x20已删除'+(_0x361338?'目录':'文件')+_0x47c98e(0x1d7)+_0x2db938+'`','msgType':_0x47c98e(0x177)});}catch(_0x52f62c){await this[_0x47c98e(0x13c)]({'conversationId':_0x3e07cb,'sessionWebhook':_0x3b97b5,'content':_0x47c98e(0x130)+_0x2db938+'`\x0a原因:\x20'+(_0x52f62c instanceof Error?_0x52f62c[_0x47c98e(0x19a)]:String(_0x52f62c)),'msgType':_0x47c98e(0x177)});}}async[a2_0x329fca(0x20d)](_0x17a27b,_0x33bc09,_0x545e53){const _0x31388c=a2_0x329fca,{absolutePath:_0xf1ee6d,error:_0xe14dfb}=this[_0x31388c(0x154)](_0x17a27b,_0x545e53);if(_0xe14dfb){await this[_0x31388c(0x13c)]({'conversationId':_0x17a27b,'sessionWebhook':_0x33bc09,'content':_0xe14dfb,'msgType':'markdown'});return;}try{const _0x44c8d7=fs_1['default'][_0x31388c(0x1c7)](_0xf1ee6d);_0x44c8d7['isFile']()?await this['sendDingMessage']({'conversationId':_0x17a27b,'sessionWebhook':_0x33bc09,'content':_0x31388c(0xce)+_0x545e53+'`\x0a最后修改时间:\x20'+utils_ok_1[_0x31388c(0x114)]['mm'](_0x44c8d7[_0x31388c(0x17a)])[_0x31388c(0x1a7)](_0x31388c(0xd7)),'msgType':_0x31388c(0x177)}):await this['sendDingMessage']({'conversationId':_0x17a27b,'sessionWebhook':_0x33bc09,'content':_0x31388c(0x111)+_0x545e53+'`','msgType':'markdown'});return;}catch{}try{const _0x49f9c0=path_1[_0x31388c(0x1cc)][_0x31388c(0x15c)](_0xf1ee6d);fs_1[_0x31388c(0x1cc)][_0x31388c(0x13e)](_0x49f9c0,{'recursive':!![]}),fs_1[_0x31388c(0x1cc)][_0x31388c(0x145)](_0xf1ee6d,'',_0x31388c(0xf5)),await this[_0x31388c(0x13c)]({'conversationId':_0x17a27b,'sessionWebhook':_0x33bc09,'content':_0x31388c(0x14f)+_0x545e53+'`','msgType':_0x31388c(0x177)});}catch(_0x1f3147){await this['sendDingMessage']({'conversationId':_0x17a27b,'sessionWebhook':_0x33bc09,'content':_0x31388c(0xc4)+_0x545e53+_0x31388c(0x181)+(_0x1f3147 instanceof Error?_0x1f3147[_0x31388c(0x19a)]:String(_0x1f3147)),'msgType':_0x31388c(0x177)});}}async['botMsgGetCallback'](_0x1948fb){const _0x3558aa=a2_0x329fca;this[_0x3558aa(0xeb)][_0x3558aa(0x1d0)](_0x1948fb[_0x3558aa(0x133)][_0x3558aa(0xdf)],'');const _0x475d72=JSON[_0x3558aa(0xec)](_0x1948fb[_0x3558aa(0x102)]),{senderNick:_0x537cd9,senderStaffId:_0x5d7c74,conversationId:_0x1f57ec,conversationTitle:_0x5a5c3a,sessionWebhook:_0x405f08,msgtype:_0x50ca60}=_0x475d72,_0x15fc23=_0x475d72[_0x3558aa(0x1ce)]?.['content']?.[_0x3558aa(0x10d)]()??'';this[_0x3558aa(0x19b)](_0x3558aa(0x148)+_0x5a5c3a+'('+_0x1f57ec+_0x3558aa(0x1d3)+_0x537cd9+'('+_0x5d7c74+_0x3558aa(0x195)+_0x50ca60+_0x3558aa(0x17b)+_0x15fc23[_0x3558aa(0x12d)](0x0,0x32));if(!this[_0x3558aa(0x1bb)](_0x5d7c74,_0x1f57ec)){await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'atUserId':_0x5d7c74,'content':_0x3558aa(0x225)});return;}const _0x5e0fc9=this[_0x3558aa(0x1a1)](_0x1f57ec);let _0x5917e8;if(_0x50ca60===_0x3558aa(0xcf)&&_0x475d72[_0x3558aa(0x144)]){const _0x51d65e=this[_0x3558aa(0x205)](_0x1f57ec),_0x45d96c=_0x5e0fc9?.[_0x3558aa(0xf8)]!==![],_0x2ed3b2=await(0x0,image_1[_0x3558aa(0x1e7)])(this,_0x475d72['pictureDownloadCode'],_0x475d72[_0x3558aa(0xcc)],_0x51d65e,_0x45d96c,_0x15fc23||undefined);if(!_0x2ed3b2){await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'atUserId':_0x5d7c74,'content':'⚠️\x20图片下载失败,请重试或使用文字描述'});return;}_0x5917e8=_0x2ed3b2;}else{if(_0x50ca60===_0x3558aa(0x1ad)&&_0x475d72[_0x3558aa(0x140)]?.['richText']){const _0x10eef8=this[_0x3558aa(0x205)](_0x1f57ec),_0x1ebc6d=_0x5e0fc9?.[_0x3558aa(0xf8)]!==![];_0x5917e8=await(0x0,image_1[_0x3558aa(0x135)])(this,_0x475d72[_0x3558aa(0x140)][_0x3558aa(0x1ad)],_0x475d72[_0x3558aa(0xcc)],_0x10eef8,_0x1ebc6d);}else{_0x5917e8=_0x15fc23;if(!_0x5917e8)return;}}if(!_0x5917e8[_0x3558aa(0x125)]('/')&&_0x50ca60==='text'){const _0x4fc697=(0x0,quote_1['extractQuoteInfo'])(_0x475d72);if(_0x4fc697){this['debugLog'](_0x3558aa(0x1ed)+_0x4fc697[_0x3558aa(0x1a5)]);if(_0x4fc697[_0x3558aa(0x1a5)]&&!_0x4fc697[_0x3558aa(0x134)]){const _0x5dadda=await(0x0,messaging_1['fetchQuotedMessage'])(this,_0x4fc697[_0x3558aa(0x1a5)]);if(_0x5dadda)_0x4fc697[_0x3558aa(0x134)]=_0x5dadda;}_0x4fc697[_0x3558aa(0x134)]&&(_0x5917e8=(0x0,quote_1[_0x3558aa(0x1e9)])(_0x5917e8,_0x4fc697));}}const _0x15b2e2=(0x0,commands_1[_0x3558aa(0x217)])(_0x5917e8);if(_0x15b2e2!==null){if(!await this[_0x3558aa(0x1a3)](_0x1f57ec,_0x405f08,_0x5d7c74))return;const _0x41aa3a=_0x5e0fc9,_0x23a5b6=!!(_0x15b2e2[_0x3558aa(0x155)]||_0x15b2e2[_0x3558aa(0x221)]||_0x15b2e2[_0x3558aa(0x21f)]&&_0x15b2e2[_0x3558aa(0x21f)][_0x3558aa(0x1b1)]>0x0||_0x15b2e2[_0x3558aa(0x12a)]||_0x15b2e2[_0x3558aa(0x113)]!==undefined||_0x15b2e2[_0x3558aa(0x1dc)]!==undefined||_0x15b2e2[_0x3558aa(0x1c8)]!==undefined);if(_0x41aa3a&&_0x23a5b6){if(_0x15b2e2[_0x3558aa(0x12a)])_0x41aa3a[_0x3558aa(0x12a)]=_0x15b2e2[_0x3558aa(0x12a)];if(_0x15b2e2[_0x3558aa(0x155)])_0x41aa3a[_0x3558aa(0x155)]=_0x15b2e2[_0x3558aa(0x155)];if(_0x15b2e2[_0x3558aa(0x221)])_0x41aa3a[_0x3558aa(0x221)]=_0x15b2e2[_0x3558aa(0x221)];if(_0x15b2e2[_0x3558aa(0x113)]!==undefined)_0x41aa3a[_0x3558aa(0x113)]=_0x15b2e2[_0x3558aa(0x113)];if(_0x15b2e2[_0x3558aa(0x1dc)]!==undefined)_0x41aa3a['receiveReply']=_0x15b2e2[_0x3558aa(0x1dc)];if(_0x15b2e2['preBash']!==undefined)_0x41aa3a[_0x3558aa(0x1c8)]=_0x15b2e2[_0x3558aa(0x1c8)];if(_0x15b2e2['whiteUserList']&&_0x15b2e2[_0x3558aa(0x21f)][_0x3558aa(0x1b1)]>0x0){_0x41aa3a[_0x3558aa(0x21f)]=_0x15b2e2[_0x3558aa(0x21f)];for(const _0x4843eb of _0x15b2e2[_0x3558aa(0x21f)]){(0x0,session_1[_0x3558aa(0xfa)])(_0x4843eb)&&await(0x0,session_1['resolveUserId'])(this,_0x4843eb);}}(0x0,api_key_manager_1[_0x3558aa(0x1ef)])(this),console[_0x3558aa(0x12e)]('['+(0x0,session_1[_0x3558aa(0x188)])()+_0x3558aa(0x1a8)+(_0x41aa3a[_0x3558aa(0x12a)]||_0x5a5c3a)+'('+_0x1f57ec+')');}else{if(!_0x41aa3a){const _0x2a6ae9={'conversationId':_0x1f57ec,'conversationTitle':_0x15b2e2['conversationTitle']||_0x5a5c3a};if(_0x15b2e2[_0x3558aa(0x155)])_0x2a6ae9['dingToken']=_0x15b2e2[_0x3558aa(0x155)];if(_0x15b2e2[_0x3558aa(0x221)])_0x2a6ae9[_0x3558aa(0x221)]=_0x15b2e2[_0x3558aa(0x221)];if(_0x15b2e2[_0x3558aa(0x113)]!==undefined)_0x2a6ae9[_0x3558aa(0x113)]=_0x15b2e2[_0x3558aa(0x113)];if(_0x15b2e2[_0x3558aa(0x1dc)]!==undefined)_0x2a6ae9[_0x3558aa(0x1dc)]=_0x15b2e2[_0x3558aa(0x1dc)];if(_0x15b2e2[_0x3558aa(0x1c8)]!==undefined)_0x2a6ae9[_0x3558aa(0x1c8)]=_0x15b2e2[_0x3558aa(0x1c8)];if(_0x15b2e2[_0x3558aa(0x21f)]&&_0x15b2e2[_0x3558aa(0x21f)][_0x3558aa(0x1b1)]>0x0){_0x2a6ae9['whiteUserList']=_0x15b2e2[_0x3558aa(0x21f)];for(const _0x57f946 of _0x15b2e2[_0x3558aa(0x21f)]){(0x0,session_1[_0x3558aa(0xfa)])(_0x57f946)&&await(0x0,session_1[_0x3558aa(0x1ec)])(this,_0x57f946);}}this[_0x3558aa(0x1e0)][_0x3558aa(0x19d)][_0x3558aa(0x1c2)](_0x2a6ae9),(0x0,api_key_manager_1[_0x3558aa(0x1ef)])(this),console['log']('['+(0x0,session_1[_0x3558aa(0x188)])()+_0x3558aa(0xc9)+(_0x2a6ae9[_0x3558aa(0x12a)]||_0x5a5c3a)+'('+_0x1f57ec+')');}}const _0x191799=this['getConversationDir'](_0x1f57ec);!fs_1[_0x3558aa(0x1cc)][_0x3558aa(0x167)](_0x191799)&&(fs_1[_0x3558aa(0x1cc)][_0x3558aa(0x13e)](_0x191799,{'recursive':!![]}),console['log']('['+(0x0,session_1['timestamp'])()+_0x3558aa(0xe6)+_0x191799));const _0x45fecf=_0x41aa3a||this['getConversationConfig'](_0x1f57ec),_0x54d797=[_0x41aa3a?_0x3558aa(0x194):_0x3558aa(0x142),_0x3558aa(0x11c)+(_0x45fecf?.['conversationTitle']||_0x5a5c3a||'-'),_0x3558aa(0xd3)+_0x1f57ec];if(_0x45fecf?.[_0x3558aa(0x155)])_0x54d797[_0x3558aa(0x1c2)](_0x3558aa(0x1dd)+_0x45fecf[_0x3558aa(0x155)][_0x3558aa(0x12d)](0x0,0x8)+_0x3558aa(0x18d));else _0x54d797['push']('-\x20**dingToken:**\x20(未指定,\x20使用\x20defaultDingToken)');if(_0x45fecf?.[_0x3558aa(0x221)])_0x54d797[_0x3558aa(0x1c2)](_0x3558aa(0x226)+_0x45fecf[_0x3558aa(0x221)]);if(_0x45fecf?.['atSender']===![])_0x54d797[_0x3558aa(0x1c2)](_0x3558aa(0x1d2));if(_0x45fecf?.[_0x3558aa(0x1dc)]===![])_0x54d797[_0x3558aa(0x1c2)](_0x3558aa(0x1bd));if(_0x45fecf?.[_0x3558aa(0x21f)]?.[_0x3558aa(0x1b1)]){const _0x39c7b5=_0x45fecf[_0x3558aa(0x21f)][_0x3558aa(0x1af)](_0x31849a=>{const _0x5c06d0=_0x3558aa;if((0x0,session_1[_0x5c06d0(0xfa)])(_0x31849a))return _0x31849a;return(0x0,session_1[_0x5c06d0(0x15a)])(this,_0x31849a)||_0x31849a;})[_0x3558aa(0x183)](',\x20');_0x54d797[_0x3558aa(0x1c2)]('-\x20**whiteUserList:**\x20'+_0x39c7b5);}_0x54d797[_0x3558aa(0x1c2)]('\x0a💡\x20可编辑\x20config.json\x20补充更多配置'),_0x54d797[_0x3558aa(0x1c2)](_0x3558aa(0x11b)+_0x191799+'`'),await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x54d797[_0x3558aa(0x183)]('\x0a'),'msgType':_0x3558aa(0x177)});return;}if((0x0,commands_1[_0x3558aa(0x132)])(_0x5917e8)){await this['sendDingMessage']({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':(0x0,commands_1[_0x3558aa(0xcd)])(TOOL_VERSION,this[_0x3558aa(0xd4)](_0x5d7c74)),'msgType':'markdown'});return;}if((0x0,commands_1[_0x3558aa(0xe8)])(_0x5917e8)){await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0xda)+TOOL_VERSION,'msgType':_0x3558aa(0x177)});return;}const _0x342b72=(0x0,commands_1[_0x3558aa(0x16c)])(_0x5917e8);if(_0x342b72){const _0x57fe99=(0x0,commands_1[_0x3558aa(0x1da)])(_0x342b72);_0x57fe99?await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':(0x0,commands_1[_0x3558aa(0x1df)])(_0x57fe99),'msgType':_0x3558aa(0x177)}):await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x121)+_0x342b72+'**\x0a\x0a💡\x20输入\x20`/help`\x20查看所有可用命令','msgType':_0x3558aa(0x177)});return;}if(!_0x5e0fc9){console['log'](_0x3558aa(0x186)+_0x5a5c3a+','+_0x1f57ec);this[_0x3558aa(0xd4)](_0x5d7c74)?await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'atUserId':_0x5d7c74,'content':_0x3558aa(0x12f),'msgType':'markdown'}):await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'atUserId':_0x5d7c74,'content':_0x3558aa(0x21c)+_0x1f57ec+')...'});return;}const _0x188dbf=(0x0,commands_1[_0x3558aa(0x1c0)])(_0x5917e8);if(_0x188dbf!==null){if(!await this[_0x3558aa(0x1a3)](_0x1f57ec,_0x405f08,_0x5d7c74))return;const _0x5e0e2e=_0x188dbf==='all'?null:_0x1f57ec,_0x58f9e7=this['cleanCache'](_0x5e0e2e,!![]),_0x4e1b19=[];_0x4e1b19[_0x3558aa(0x1c2)](_0x3558aa(0xe5));if(_0x58f9e7[_0x3558aa(0x109)]>0x0)_0x4e1b19[_0x3558aa(0x1c2)](_0x3558aa(0x1c3)+_0x58f9e7[_0x3558aa(0x109)]+'\x20个');if(_0x58f9e7[_0x3558aa(0x17f)]>0x0)_0x4e1b19[_0x3558aa(0x1c2)]('-\x20任务目录:\x20'+_0x58f9e7['tasksDeleted']+'\x20个');if(_0x58f9e7[_0x3558aa(0x1ae)]>0x0)_0x4e1b19['push'](_0x3558aa(0x107)+_0x58f9e7[_0x3558aa(0x1ae)]+'\x20个');_0x58f9e7[_0x3558aa(0x109)]===0x0&&_0x58f9e7['tasksDeleted']===0x0&&_0x58f9e7[_0x3558aa(0x1ae)]===0x0&&_0x4e1b19[_0x3558aa(0x1c2)](_0x3558aa(0xdb));_0x4e1b19[_0x3558aa(0x1c2)](_0x3558aa(0x1f5));_0x58f9e7[_0x3558aa(0x101)][_0x3558aa(0x1b1)]>0x0&&_0x4e1b19[_0x3558aa(0x1c2)](_0x3558aa(0x13f)+_0x58f9e7[_0x3558aa(0x101)][_0x3558aa(0x183)](';\x20'));await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x4e1b19['join']('\x0a'),'msgType':_0x3558aa(0x177)});return;}if((0x0,commands_1[_0x3558aa(0xc8)])(_0x5917e8)){if(!await this['requireOwner'](_0x1f57ec,_0x405f08,_0x5d7c74))return;if(!this[_0x3558aa(0x1e0)][_0x3558aa(0x1be)]){await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x1c4),'msgType':_0x3558aa(0x177)});return;}(0x0,api_key_manager_1[_0x3558aa(0x175)])(this);const _0x222de3=this[_0x3558aa(0x1e0)][_0x3558aa(0x1be)][_0x3558aa(0xe4)][_0x3558aa(0x1f0)](_0x3f0af5=>_0x3f0af5['isValid'])['length'];await this['sendDingMessage']({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'✅\x20apiKeyCfg\x20已重置\x0a-\x20有效\x20Key\x20数:\x20'+_0x222de3+'/'+this[_0x3558aa(0x1e0)]['apiKeyCfg'][_0x3558aa(0xe4)][_0x3558aa(0x1b1)]+'\x0a-\x20重置时间:\x20'+(this[_0x3558aa(0x1e0)][_0x3558aa(0x1be)][_0x3558aa(0x13a)]||'-'),'msgType':_0x3558aa(0x177)});return;}const _0x513852=(0x0,commands_1[_0x3558aa(0x213)])(_0x5917e8);if(_0x513852){if(!await this[_0x3558aa(0x1a3)](_0x1f57ec,_0x405f08,_0x5d7c74))return;const _0x24cee6=_0x5e0fc9[_0x3558aa(0x21f)];if(_0x513852[_0x3558aa(0xc6)]===_0x3558aa(0x141)){const _0x2a33a6=_0x24cee6&&_0x24cee6['length']>0x0?_0x24cee6['map'](_0x1cc257=>{const _0x79896f=(0x0,session_1['userIdToPhone'])(this,_0x1cc257);return'-\x20'+(_0x79896f||_0x1cc257);})[_0x3558aa(0x183)]('\x0a'):_0x3558aa(0x180);await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'📋\x20**当前群白名单**\x0a'+_0x2a33a6,'msgType':'markdown'});return;}if(_0x513852[_0x3558aa(0xc6)]===_0x3558aa(0x1e4)){let _0x56c365=_0x513852[_0x3558aa(0x139)];if((0x0,session_1[_0x3558aa(0xfa)])(_0x513852[_0x3558aa(0x139)])){_0x56c365=await(0x0,session_1[_0x3558aa(0x1ec)])(this,_0x513852[_0x3558aa(0x139)]);if(!_0x56c365){await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0xe9)+_0x513852[_0x3558aa(0x139)],'msgType':_0x3558aa(0x177)});return;}}const _0x54714f=_0x24cee6?.[_0x3558aa(0x123)](_0x3fa89f=>(0x0,session_1['resolveToUserId'])(this,_0x3fa89f)===_0x56c365);if(_0x54714f){const _0x1d5881=(0x0,session_1[_0x3558aa(0x15a)])(this,_0x56c365)||_0x56c365;await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'⚠️\x20'+_0x1d5881+_0x3558aa(0x17e),'msgType':_0x3558aa(0x177)});return;}!_0x5e0fc9['whiteUserList']&&(_0x5e0fc9[_0x3558aa(0x21f)]=[]);_0x5e0fc9['whiteUserList'][_0x3558aa(0x1c2)](_0x513852[_0x3558aa(0x139)]),(0x0,api_key_manager_1[_0x3558aa(0x1ef)])(this);const _0x6b1911=_0x5e0fc9['whiteUserList']['map'](_0x4c73a3=>{const _0x1e4975=_0x3558aa,_0x120095=(0x0,session_1['resolveToUserId'])(this,_0x4c73a3);return(0x0,session_1[_0x1e4975(0x15a)])(this,_0x120095)||_0x4c73a3;}),_0x5ceee6=(0x0,session_1[_0x3558aa(0xfa)])(_0x513852[_0x3558aa(0x139)])?_0x513852[_0x3558aa(0x139)]:(0x0,session_1[_0x3558aa(0x15a)])(this,_0x513852[_0x3558aa(0x139)])||_0x513852[_0x3558aa(0x139)];await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'✅\x20已添加\x20'+_0x5ceee6+_0x3558aa(0xe2)+_0x6b1911[_0x3558aa(0x183)](',\x20'),'msgType':_0x3558aa(0x177)});return;}if(_0x513852[_0x3558aa(0xc6)]===_0x3558aa(0x228)){let _0x47542c=_0x513852[_0x3558aa(0x139)];if((0x0,session_1[_0x3558aa(0xfa)])(_0x513852['staffId'])){_0x47542c=await(0x0,session_1[_0x3558aa(0x1ec)])(this,_0x513852[_0x3558aa(0x139)]);if(!_0x47542c){await this['sendDingMessage']({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0xe9)+_0x513852['staffId'],'msgType':_0x3558aa(0x177)});return;}}const _0x5d3065=_0x24cee6?.[_0x3558aa(0x166)](_0x173ede=>(0x0,session_1[_0x3558aa(0x1e3)])(this,_0x173ede)===_0x47542c)??-0x1;if(_0x5d3065<0x0){const _0x5c95fb=(0x0,session_1['userIdToPhone'])(this,_0x47542c)||_0x47542c;await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x1f4)+_0x5c95fb+_0x3558aa(0x207),'msgType':'markdown'});return;}const _0x158ca9=_0x5e0fc9[_0x3558aa(0x21f)][_0x5d3065];_0x5e0fc9[_0x3558aa(0x21f)]['splice'](_0x5d3065,0x1);_0x5e0fc9[_0x3558aa(0x21f)]['length']===0x0&&delete _0x5e0fc9[_0x3558aa(0x21f)];(0x0,api_key_manager_1[_0x3558aa(0x1ef)])(this);const _0x1fbbda=_0x5e0fc9[_0x3558aa(0x21f)]?.['length']?_0x5e0fc9[_0x3558aa(0x21f)][_0x3558aa(0x1af)](_0x22529c=>{const _0x32d02b=_0x3558aa,_0x284139=(0x0,session_1[_0x32d02b(0x1e3)])(this,_0x22529c);return(0x0,session_1['userIdToPhone'])(this,_0x284139)||_0x22529c;})['join'](',\x20'):_0x3558aa(0x13d),_0x5d6656=(0x0,session_1[_0x3558aa(0x15a)])(this,_0x47542c)||_0x158ca9;await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x10c)+_0x5d6656+'\x0a当前白名单:\x20'+_0x1fbbda,'msgType':'markdown'});return;}}const _0x15cd9d=(0x0,commands_1[_0x3558aa(0x223)])(_0x5917e8);if(_0x15cd9d!==null){if(!await this[_0x3558aa(0x1a3)](_0x1f57ec,_0x405f08,_0x5d7c74))return;const _0x37c682=this[_0x3558aa(0x205)](_0x1f57ec),{exec:_0x7223a0}=await Promise['resolve']()[_0x3558aa(0xf4)](()=>__importStar(require('child_process'))),_0x3700cc=process['platform'];try{_0x15cd9d===_0x3558aa(0x117)?(_0x3700cc==='darwin'?_0x7223a0(_0x3558aa(0x138)+_0x37c682+'\x22'):_0x7223a0('explorer\x20\x22'+_0x37c682+'\x22'),await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x150)+_0x37c682+'\x0a```','msgType':'markdown'})):(_0x3700cc===_0x3558aa(0x1bf)?_0x7223a0(_0x3558aa(0x197)+_0x37c682+'\x22'):_0x7223a0('start\x20cmd\x20/k\x20\x22cd\x20/d\x20'+_0x37c682+'\x22',{'shell':_0x3558aa(0x120)}),await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'💻\x20已在终端中打开:\x0a```\x0a'+_0x37c682+_0x3558aa(0x192),'msgType':_0x3558aa(0x177)}));}catch(_0x36e26d){await this['sendDingMessage']({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x20a)+(_0x36e26d instanceof Error?_0x36e26d[_0x3558aa(0x19a)]:String(_0x36e26d)),'msgType':_0x3558aa(0x177)});}return;}const _0x223d93=(0x0,commands_1[_0x3558aa(0x209)])(_0x5917e8);if(_0x223d93){await this[_0x3558aa(0x1ea)](_0x223d93,{'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'senderStaffId':_0x5d7c74,'senderNick':_0x537cd9,'conversationConfig':_0x5e0fc9});return;}if((0x0,commands_1[_0x3558aa(0x11e)])(_0x5917e8)){const _0x1a79db=this[_0x3558aa(0x205)](_0x1f57ec);await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x1cd)+_0x1a79db+'\x0a```','msgType':'markdown'});return;}const _0x49243e=(0x0,commands_1['parseMkdirCommand'])(_0x5917e8);if(_0x49243e!==null){await this[_0x3558aa(0xfd)](_0x1f57ec,_0x405f08,_0x49243e);return;}const _0x3eddb=(0x0,commands_1['parseTouchCommand'])(_0x5917e8);if(_0x3eddb!==null){await this[_0x3558aa(0x20d)](_0x1f57ec,_0x405f08,_0x3eddb);return;}const _0x18a637=(0x0,commands_1['parseRmCommand'])(_0x5917e8);if(_0x18a637!==null){await this['handleRmCommand'](_0x1f57ec,_0x405f08,_0x18a637);return;}const _0x26666c=(0x0,commands_1[_0x3558aa(0x129)])(_0x5917e8);if(_0x26666c!==null){const _0x1ca752=this[_0x3558aa(0x205)](_0x1f57ec),_0x57e216=[];if(this['config'][_0x3558aa(0x1c8)])_0x57e216[_0x3558aa(0x1c2)](this[_0x3558aa(0x1e0)][_0x3558aa(0x1c8)]);if(_0x5e0fc9?.['preBash'])_0x57e216[_0x3558aa(0x1c2)](_0x5e0fc9[_0x3558aa(0x1c8)]);const _0x15b3ba=_0x57e216['length']>0x0?_0x57e216[_0x3558aa(0x183)](_0x3558aa(0x1d8))+_0x3558aa(0x1d8)+_0x26666c:_0x26666c,_0x343eba=this;(0x0,child_process_1[_0x3558aa(0x22a)])(_0x15b3ba,{'cwd':_0x1ca752,'timeout':0x7530,'maxBuffer':0x400*0x400},async(_0x528a32,_0x6292ea,_0x9ccb43)=>{const _0x514858=_0x3558aa;try{let _0x498c69;if(_0x528a32)_0x498c69='❌\x20命令执行失败\x0a```\x0a'+_0x528a32[_0x514858(0x19a)]+'\x0a```',_0x9ccb43&&(_0x498c69+='\x0a\x0a**stderr:**\x0a```\x0a'+_0x343eba['sanitizeOutput'](_0x9ccb43)+_0x514858(0x192));else{const _0x43e793=_0x6292ea||_0x514858(0xea);_0x498c69='✅\x20执行成功\x0a```\x0a'+_0x343eba[_0x514858(0xd5)](_0x43e793)+_0x514858(0x192),_0x9ccb43&&(_0x498c69+=_0x514858(0x165)+_0x343eba[_0x514858(0xd5)](_0x9ccb43)+'\x0a```');}await _0x343eba[_0x514858(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x498c69,'msgType':_0x514858(0x177)});}catch(_0x36b94e){console[_0x514858(0x115)]('[bash]\x20发送消息失败:',_0x36b94e);}});return;}if(/^\/new(?:\s|$)/i[_0x3558aa(0x1b2)](_0x5917e8)){const _0x54d581=this[_0x3558aa(0xf0)](_0x1f57ec);_0x54d581&&(console[_0x3558aa(0x12e)](_0x3558aa(0x16b)+_0x54d581[_0x3558aa(0x169)][_0x3558aa(0x169)][_0x3558aa(0x152)]+_0x3558aa(0x112)+this[_0x3558aa(0x12b)](_0x54d581['session'][_0x3558aa(0x169)])),this['interruptClaudeProcess'](_0x54d581[_0x3558aa(0x169)],'新会话命令中断正在执行的\x20Claude\x20进程'),this[_0x3558aa(0xf1)]['delete'](_0x54d581[_0x3558aa(0x1c1)]),this[_0x3558aa(0x1b4)](_0x54d581[_0x3558aa(0x1c1)]));const _0x5f2113=_0x5917e8[_0x3558aa(0x16a)](/^\/new\s*/i,'')[_0x3558aa(0x10d)]();_0x5f2113?await this[_0x3558aa(0x1b3)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'senderStaffId':_0x5d7c74,'senderNick':_0x537cd9,'message':_0x5f2113,'conversationConfig':_0x5e0fc9}):await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'atUserId':_0x5d7c74,'content':_0x3558aa(0xc7)});return;}const _0x1ae993=(0x0,commands_1[_0x3558aa(0x22b)])(_0x5917e8);if(_0x1ae993!==null&&_0x5e0fc9){let _0x5806f8=_0x1ae993;if(!_0x5806f8){const _0x1e038a=(0x0,session_1[_0x3558aa(0x1fc)])(this,_0x1f57ec);if(!_0x1e038a){await this['sendDingMessage']({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'atUserId':_0x5d7c74,'content':_0x3558aa(0x1fb),'msgType':_0x3558aa(0x177)});return;}_0x5806f8=(0x0,session_1[_0x3558aa(0x12b)])(_0x1e038a);}await this[_0x3558aa(0x156)](_0x1f57ec,_0x405f08,_0x5806f8,_0x5d7c74,_0x5e0fc9);return;}const _0x3f9b5b=(0x0,commands_1['parseLogCommand'])(_0x5917e8);if(_0x3f9b5b!==null){const _0x2b74c7=this[_0x3558aa(0x212)](_0x1f57ec,_0x3f9b5b);_0x2b74c7?await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x157)+_0x3f9b5b+_0x3558aa(0x21b)+_0x2b74c7+_0x3558aa(0x192),'msgType':_0x3558aa(0x177)}):await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x18f)});return;}const _0x29c92a=(0x0,commands_1[_0x3558aa(0x184)])(_0x5917e8);if(_0x29c92a!==null){const _0x376f01=[],_0x444ce7=this[_0x3558aa(0x205)](_0x1f57ec);(_0x29c92a===_0x3558aa(0x204)||_0x29c92a===_0x3558aa(0xd9))&&(_0x376f01[_0x3558aa(0x1c2)](_0x3558aa(0x16d)+(0x0,commands_1[_0x3558aa(0x11d)])(this[_0x3558aa(0x1e0)])),_0x376f01[_0x3558aa(0x1c2)](_0x3558aa(0x119)+(0x0,commands_1[_0x3558aa(0xff)])(_0x5e0fc9,_0x1f57ec,_0x44a96b=>(0x0,session_1[_0x3558aa(0x15a)])(this,_0x44a96b),_0x444ce7)));if(_0x29c92a===_0x3558aa(0x204)||_0x29c92a===_0x3558aa(0x169)){const _0x4efcd8=this[_0x3558aa(0x1aa)](_0x1f57ec);_0x4efcd8?_0x376f01[_0x3558aa(0x1c2)](_0x3558aa(0xf2)+_0x4efcd8):_0x376f01[_0x3558aa(0x1c2)](_0x3558aa(0x122));}(_0x29c92a===_0x3558aa(0x204)||_0x29c92a===_0x3558aa(0x20f))&&_0x376f01[_0x3558aa(0x1c2)](_0x3558aa(0x14d)+this[_0x3558aa(0x1d9)]());await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x376f01[_0x3558aa(0x183)]('\x0a\x0a'),'msgType':_0x3558aa(0x177)});return;}const _0x4cad74=(0x0,commands_1[_0x3558aa(0x1f6)])(_0x5917e8);if(_0x4cad74!==null){const {target:_0x248da7,depth:_0x1be5a5}=_0x4cad74,_0x2ead37=this['getConversationDir'](_0x1f57ec);let _0xa45d5c=_0x2ead37,_0x1ee11f=_0x3558aa(0x15e);if(_0x248da7&&_0x248da7!==_0x3558aa(0x1b8)){if(_0x248da7[_0x3558aa(0x125)]('./')||_0x248da7['startsWith'](_0x3558aa(0xd0))||_0x248da7[_0x3558aa(0x125)]('/')){const _0xef1f37=path_1[_0x3558aa(0x1cc)][_0x3558aa(0x220)](_0x2ead37,_0x248da7);if(fs_1[_0x3558aa(0x1cc)][_0x3558aa(0x167)](_0xef1f37)&&fs_1[_0x3558aa(0x1cc)][_0x3558aa(0x1c7)](_0xef1f37)['isDirectory']()){if(!_0xef1f37[_0x3558aa(0x125)](_0x2ead37)){await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x19f),'msgType':_0x3558aa(0x177)});return;}_0xa45d5c=_0xef1f37,_0x1ee11f=_0x248da7;}else{await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'❌\x20路径不存在或不是目录:\x20**'+_0x248da7+'**','msgType':_0x3558aa(0x177)});return;}}else{const _0x29d998=(0x0,commands_1[_0x3558aa(0xdd)])(_0x2ead37,_0x248da7);if(_0x29d998)_0xa45d5c=_0x29d998,_0x1ee11f=_0x248da7;else{await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'❌\x20未找到名为\x20**'+_0x248da7+_0x3558aa(0x18a),'msgType':_0x3558aa(0x177)});return;}}}const _0xd8eaff=(0x0,commands_1[_0x3558aa(0x218)])(_0xa45d5c,0x0,_0x1be5a5);await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'📂\x20'+_0x1ee11f+_0x3558aa(0x201)+_0x1be5a5+_0x3558aa(0x108)+_0xd8eaff+'\x0a```','msgType':_0x3558aa(0x177)});return;}const _0x1fd54f=(0x0,task_1['parseTaskCancelCommand'])(_0x5917e8);if(_0x1fd54f){const _0x185777=this['cancelTask'](_0x1fd54f,_0x1f57ec);await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x185777,'msgType':_0x3558aa(0x177)});return;}if(_0x5917e8['startsWith'](_0x3558aa(0x1c9))){const _0x40726a=_0x5917e8['substring'](0x6)[_0x3558aa(0x10d)]();_0x40726a&&(await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'atUserId':_0x5d7c74,'content':_0x3558aa(0x10e)}),await this[_0x3558aa(0x1ff)]({'conversationId':_0x1f57ec,'prompt':_0x40726a,'senderStaffId':_0x5d7c74,'senderNickName':_0x537cd9,'sessionWebhook':_0x405f08}));return;}const _0x3ab22d=(0x0,commands_1[_0x3558aa(0xed)])(_0x5917e8);if(_0x3ab22d){const _0x458d19=this['findActiveSession'](_0x1f57ec),_0x4d96a7=_0x458d19?.[_0x3558aa(0x169)][_0x3558aa(0x210)]??[];switch(_0x3ab22d[_0x3558aa(0xc6)]){case _0x3558aa(0x141):{if(_0x4d96a7[_0x3558aa(0x1b1)]===0x0)await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'📭\x20当前无排队消息','msgType':'markdown'});else{const _0x3039ea=_0x4d96a7[_0x3558aa(0x1af)]((_0x241562,_0x451991)=>_0x451991+0x1+_0x3558aa(0x1c5)+(_0x241562[_0x3558aa(0x127)]||_0x241562[_0x3558aa(0x1b0)])+_0x3558aa(0x199)+this['truncateMsg'](_0x241562[_0x3558aa(0x19a)]));await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'📨\x20消息队列\x20('+_0x4d96a7['length']+_0x3558aa(0x211)+_0x3039ea[_0x3558aa(0x183)]('\x0a'),'msgType':_0x3558aa(0x177)});}return;}case _0x3558aa(0xcb):{if(_0x4d96a7[_0x3558aa(0x1b1)]===0x0){await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':'📭\x20当前无排队消息','msgType':_0x3558aa(0x177)});return;}const _0x15d924=Math[_0x3558aa(0xfc)](_0x3ab22d[_0x3558aa(0x137)],_0x4d96a7[_0x3558aa(0x1b1)]),_0x55c65b=_0x4d96a7['splice'](_0x4d96a7[_0x3558aa(0x1b1)]-_0x15d924,_0x15d924),_0x53fad1=_0x55c65b[_0x3558aa(0x1af)]((_0x5558c1,_0x39777b)=>_0x39777b+0x1+_0x3558aa(0x1c5)+(_0x5558c1['senderNick']||_0x5558c1[_0x3558aa(0x1b0)])+_0x3558aa(0x199)+this['truncateMsg'](_0x5558c1[_0x3558aa(0x19a)]));await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x16e)+_0x15d924+'\x20条消息\x0a'+_0x53fad1[_0x3558aa(0x183)]('\x0a'),'msgType':_0x3558aa(0x177)});return;}case'cancelAll':{if(_0x4d96a7[_0x3558aa(0x1b1)]===0x0){await this['sendDingMessage']({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x10b),'msgType':_0x3558aa(0x177)});return;}const _0x52ad6e=_0x4d96a7[_0x3558aa(0x1b1)];_0x4d96a7[_0x3558aa(0x1b1)]=0x0,await this[_0x3558aa(0x13c)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'content':_0x3558aa(0x1e2)+_0x52ad6e+_0x3558aa(0x168),'msgType':_0x3558aa(0x177)});return;}}}await this[_0x3558aa(0x1cb)]({'conversationId':_0x1f57ec,'sessionWebhook':_0x405f08,'senderStaffId':_0x5d7c74,'senderNick':_0x537cd9,'message':_0x5917e8,'conversationConfig':_0x5e0fc9});}async[a2_0x329fca(0x160)](){const _0xb74dfe=a2_0x329fca,_0x18e6ad=Array[_0xb74dfe(0x10a)](this[_0xb74dfe(0x1e0)]['conversations'])?this[_0xb74dfe(0x1e0)][_0xb74dfe(0x19d)]:[],_0x47a90c=this[_0xb74dfe(0x1e0)]['taskHandlerCount']??this[_0xb74dfe(0xe1)],_0x1803ad=_0x18e6ad[_0xb74dfe(0x1b1)]>0x0;console['log']('['+(0x0,session_1[_0xb74dfe(0x188)])()+']\x20钉钉机器人服务启动,clientId:\x20'+this[_0xb74dfe(0x163)]),console[_0xb74dfe(0x12e)]('['+(0x0,session_1[_0xb74dfe(0x188)])()+']\x20群配置:\x20'+_0x18e6ad[_0xb74dfe(0x1af)](_0x5857ab=>_0x5857ab[_0xb74dfe(0x12a)]||_0x5857ab[_0xb74dfe(0x152)])['join'](',\x20')),(0x0,api_key_manager_1[_0xb74dfe(0x162)])(this),await(0x0,session_1[_0xb74dfe(0x227)])(this);this[_0xb74dfe(0x1e0)]['apiKeyCfg']&&((0x0,api_key_manager_1[_0xb74dfe(0x175)])(this),(0x0,api_key_manager_1[_0xb74dfe(0x143)])(this));this['loadActiveSessions'](),this['cronEngine'][_0xb74dfe(0x1fa)]();_0x1803ad&&console[_0xb74dfe(0x12e)]('['+(0x0,session_1[_0xb74dfe(0x188)])()+_0xb74dfe(0xf6)+_0x47a90c);this[_0xb74dfe(0xeb)][_0xb74dfe(0x173)](_0xb74dfe(0x1cf),async _0x3af87e=>{const _0x1cb6a7=_0xb74dfe;await this[_0x1cb6a7(0x1eb)](_0x3af87e);});const _0x31a873=[];if(_0x1803ad)for(let _0x32189f=0x0;_0x32189f<_0x47a90c;_0x32189f++){console[_0xb74dfe(0x12e)]('['+(0x0,session_1[_0xb74dfe(0x188)])()+']\x20启动任务处理器\x20#'+(_0x32189f+0x1)),_0x31a873[_0xb74dfe(0x1c2)](this['runTaskHandlerLoop']()['catch'](_0x116a3d=>console[_0xb74dfe(0x115)](_0xb74dfe(0x20c)+(_0x32189f+0x1)+_0xb74dfe(0x202),_0x116a3d)));}const _0x1c3375=this[_0xb74dfe(0xeb)][_0xb74dfe(0x116)]()[_0xb74dfe(0xde)](_0x57f0dd=>{const _0x1357f8=_0xb74dfe;console['error'](_0x1357f8(0x149),_0x57f0dd),process[_0x1357f8(0x131)](0x1);});await Promise[_0xb74dfe(0x204)]([_0x1c3375,..._0x31a873]);}}exports[a2_0x329fca(0x11f)]=DingClaude;
|
|
1
|
+
'use strict';const a2_0x14d974=a2_0x2a4e;(function(_0x3fb46f,_0xbf5196){const _0x44f3fc=a2_0x2a4e,_0x1639c2=_0x3fb46f();while(!![]){try{const _0x4a50d8=parseInt(_0x44f3fc(0x1da))/0x1*(-parseInt(_0x44f3fc(0xde))/0x2)+-parseInt(_0x44f3fc(0x1ee))/0x3+parseInt(_0x44f3fc(0x115))/0x4*(-parseInt(_0x44f3fc(0x188))/0x5)+-parseInt(_0x44f3fc(0x112))/0x6+-parseInt(_0x44f3fc(0x1f3))/0x7*(parseInt(_0x44f3fc(0x123))/0x8)+parseInt(_0x44f3fc(0x1bc))/0x9+parseInt(_0x44f3fc(0x164))/0xa;if(_0x4a50d8===_0xbf5196)break;else _0x1639c2['push'](_0x1639c2['shift']());}catch(_0x411b8a){_0x1639c2['push'](_0x1639c2['shift']());}}}(a2_0x3f9c,0xa8bcc));function a2_0x2a4e(_0x35dbf7,_0x2bdaf1){_0x35dbf7=_0x35dbf7-0xbb;const _0x3f9c85=a2_0x3f9c();let _0x2a4e57=_0x3f9c85[_0x35dbf7];return _0x2a4e57;}var __createBinding=this&&this[a2_0x14d974(0x218)]||(Object[a2_0x14d974(0x1bf)]?function(_0x4f33fb,_0x5200b1,_0x181e4a,_0x2018d5){const _0x2786bc=a2_0x14d974;if(_0x2018d5===undefined)_0x2018d5=_0x181e4a;var _0x118f5d=Object[_0x2786bc(0x182)](_0x5200b1,_0x181e4a);(!_0x118f5d||(_0x2786bc(0x119)in _0x118f5d?!_0x5200b1[_0x2786bc(0xf0)]:_0x118f5d[_0x2786bc(0x130)]||_0x118f5d[_0x2786bc(0x155)]))&&(_0x118f5d={'enumerable':!![],'get':function(){return _0x5200b1[_0x181e4a];}}),Object[_0x2786bc(0x103)](_0x4f33fb,_0x2018d5,_0x118f5d);}:function(_0x153760,_0x282536,_0x2ae5c1,_0x4086d0){if(_0x4086d0===undefined)_0x4086d0=_0x2ae5c1;_0x153760[_0x4086d0]=_0x282536[_0x2ae5c1];}),__setModuleDefault=this&&this[a2_0x14d974(0x179)]||(Object[a2_0x14d974(0x1bf)]?function(_0x483f33,_0x40c00a){const _0x99cd24=a2_0x14d974;Object['defineProperty'](_0x483f33,_0x99cd24(0x15c),{'enumerable':!![],'value':_0x40c00a});}:function(_0x1e2d56,_0x4b1d85){const _0x13c781=a2_0x14d974;_0x1e2d56[_0x13c781(0x15c)]=_0x4b1d85;}),__importStar=this&&this[a2_0x14d974(0x125)]||(function(){var _0x231b06=function(_0x349098){return _0x231b06=Object['getOwnPropertyNames']||function(_0x45e80b){const _0x103771=a2_0x2a4e;var _0xd8932b=[];for(var _0x3a74db in _0x45e80b)if(Object['prototype'][_0x103771(0xc2)][_0x103771(0x181)](_0x45e80b,_0x3a74db))_0xd8932b[_0xd8932b['length']]=_0x3a74db;return _0xd8932b;},_0x231b06(_0x349098);};return function(_0x154eb1){const _0x542a58=a2_0x2a4e;if(_0x154eb1&&_0x154eb1[_0x542a58(0xf0)])return _0x154eb1;var _0x168be5={};if(_0x154eb1!=null){for(var _0x28c0e7=_0x231b06(_0x154eb1),_0x2c9e8d=0x0;_0x2c9e8d<_0x28c0e7[_0x542a58(0x206)];_0x2c9e8d++)if(_0x28c0e7[_0x2c9e8d]!==_0x542a58(0x15c))__createBinding(_0x168be5,_0x154eb1,_0x28c0e7[_0x2c9e8d]);}return __setModuleDefault(_0x168be5,_0x154eb1),_0x168be5;};}()),__importDefault=this&&this[a2_0x14d974(0x12f)]||function(_0x535caa){const _0x2983b4=a2_0x14d974;return _0x535caa&&_0x535caa[_0x2983b4(0xf0)]?_0x535caa:{'default':_0x535caa};};function a2_0x3f9c(){const _0x418a86=['❌\x20只有机器人\x20owner\x20才能执行此操作','receiveReply','executeClaudeQuery','text','15865WPjDSr',':**\x20','resolveAndValidatePath','❌\x20路径不存在或不是目录:\x20**','sendClaudeResponseToDing','⚠️\x20','###\x20🌐\x20全局核心配置\x0a','-\x20图片文件:\x20','✅\x20已移除\x20','parseMqCommand','add','appendSessionLog','/task\x20','statSync','claudeSettings','handleMkdirCommand','extractQuoteInfo','find','botMsgGetCallback',']\x20注册新群:\x20','start\x20cmd\x20/k\x20\x22cd\x20/d\x20','tasksDeleted','whiteUserList','resetApiKeyCfg','push','parseOpenCommand','session',']\x20创建工作目录:\x20','path','isOwner','Error:\x20DingStreamClient\x20init\x20failed.','processRichTextMessage','parseCommandHelp','task','isDirectory','key','**\x20已暂停','getOneTodoTask','❌\x20路径已存在但不是目录:\x20`','###\x20📝\x20任务队列信息\x0a','📋\x20任务已收到,完成后我会回复','✅\x20已添加\x20','splice','parseRmCommand','findLatestSession','../common','./quote','formatHelpOverview','assistant','switchToSession','messageQueue','exec','3123369loPuVo','resolveToUserId','isMobile','create','sanitizeOutput','format','📂\x20已在文件管理器中打开:\x0a```\x0a','activeSessions','min','列出\x20','**\x0a\x0a💡\x20输入\x20`/help`\x20查看所有可用命令','resetTime','explorer\x20\x22','map','sendDingMessage','dingToken','抱歉,您暂无使用权限,请联系应用机器人owner授权...','truncateMsg','恢复定时任务\x20','层):\x0a```\x0a','useLocalOcr','isValidCronExpression','errors','⚠️\x20图片下载失败,请重试或使用文字描述','rmSync','content','-\x20**群名称:**\x20','atSender','del','\x0a...(输出已截断)','6719yQJPui','writeFileSync','mkdirSync','cancelTask',']\x20启动任务处理器\x20#','socketCallBackResponse','(空,使用全局白名单)','timestamp','parse','debugLog','saveClientConfig','parseClaudeStreamLine','\x20到当前群白名单\x0a当前白名单:\x20','join','getConversationConfig','message','sendCronNoNotifyError','./cron','existsSync','###\x20🤖\x20群配置信息\x0a','3685410KODdYC','delete','create_nl','platform','📂\x20','828569lLnPOZ','./task','⏸️\x20定时任务\x20**','description','apiKeyCfg','创建定时任务:\x20','type','imagesDeleted','getPkgVersion','getSessionDir','preBash','/session.json','\x0a💡\x20可编辑\x20config.json\x20补充更多配置','暂停定时任务\x20','removeJob','trim','utf-8','sessionsDeleted','⏳\x20正在分析定时任务描述...','length','user','-\x20**dingToken:**\x20','`\x0a\x0a💡\x20格式:\x20`分\x20时\x20日\x20月\x20周`,如\x20`0\x209\x20*\x20*\x20*`','\x20不在当前群白名单中','startNewSession','❌\x20未找到命令:\x20**','`\x0a最后修改时间:\x20','finishTask',']\x20群配置:\x20','DEFAULT_TASK_HANDLER_COUNT','connect','startsWith','conversationType','###\x20💬\x20当前会话信息\x0a','defaultDingToken','⚠️\x20该群未注册,请先使用\x20`/cfg`\x20命令注册','conversationConfig','__createBinding','findHistorySession','⚠️\x20无法解析手机号:\x20','robotCode','resume','richText','start','parseResetApiKeyCfgCommand','未找到定时任务:\x20','pictureDownloadCode','getTasksDir','hasOwnProperty','scheduleApiKeyCfgDailyReset','CronEngine','staffId','getOrCreateLogSession','darwin','❌\x20路径超出工作目录范围','收到消息:\x20群=','DEFAULT_SESSION_MAX_CONCURRENCY','cronExpression','-\x20**atSender:**\x20false\x20(不\x20@\x20发送人)','messageId','run','▶️\x20定时任务\x20**','检测到引用消息:\x20quoteMessageId=','root','parseCfgCommand','conversationId','create_cron','getActiveSessionsFile','✅\x20文件创建成功:\x20`','parseVersionCommand','✅\x20目录创建成功:\x20`','./session','**\x20已删除','requireOwnerOrSingleChat','child_process','\x0a\x0a💡\x20你也可以直接指定cron表达式:\x20`/cron\x200\x209\x20*\x20*\x20*\x20任务描述`','292zgLhKc','sanitizeLogContent','/cron\x20','❌\x20当前群未配置\x20dingToken\x20且无客户端级\x20defaultDingToken,\x20定时任务无法主动发送消息,\x20请联系管理员配置','cleanCache',')\x20类型=','unlinkSync','replace','parseCleanCommand','cronEngine','all','❌\x20目录创建失败:\x20`','now','✅\x20群配置已刷新','Fatal\x20error','hasNotifyCapability','🚀\x20请输入您的问题开始新会话','✅\x20已从队尾移除\x20','__esModule','findActiveSession','pause','抱歉,该群的机器人未在服务端注册,请联系应用机器人owner注册(','**\x20的目录','parsePwdCommand','processPictureMessage','cancel','📨\x20消息队列\x20(','[cron]','filter','config',',\x20会话ID=','⚠️\x20目录已存在:\x20`','slice','log','./messaging','parseMkdirCommand','getClientConfig','defineProperty','❌\x20打开失败:\x20','saveActiveSession','sessionDir','markdown','list','getSessionsDir','YYYY-MM-DD\x20HH:mm:ss','❌\x20只有机器人\x20owner\x20才能清除所有群缓存','addJob','dingStreamClient','-\x20**receiveReply:**\x20false\x20(不回复确认消息)','./api-key-manager','listJobs','✅\x20执行成功\x0a```\x0a','4871094xJXMMl','-\x20**会话类型:**\x20','clientSecret','208ulaaOI','parseInfoCommand','substring','当前工作目录','get','quoteText','conversationTitle','handleSessionMessage','picture','formatCronJobInfo','DingClaude','./commands','getClientDir','parseContinueSessionCommand','48kzdqrh','...','__importStar','/cron\x20resume\x20',']\x20[SYSTEM]:\x20创建会话用于记录\x20/cron\x20命令操作\x0a','❌\x20无效的cron表达式:\x20`','❌\x20删除失败:\x20`','-\x20**linkConversationId:**\x20','❌\x20未找到定时任务:\x20','analyzeAndCreate',']\x20钉钉机器人服务启动,clientId:\x20','prompt','__importDefault','writable','-\x20**工作目录:**\x20','✅\x20定时任务\x20**','/v1.0/im/bot/messages/get','isValid','\x0a```','data','**版本:**\x20','./image','⚠️\x20未找到已结束的会话','\x0a-\x20重置时间:\x20','resolveUserId','parseLsCommand','senderStaffId',']\x20任务处理器数量:\x20','loadActiveSessions','formatConversationInfo','requireOwner','formatSessionInfo','`\x0a原因:\x20','getConversationDir','❌\x20只有机器人\x20owner\x20才能操作其他群的配置','then','interruptClaudeProcess','countTodoTask','exit','dateUtil','formatPromptWithQuote','folder','\x0a\x0a**stderr:**\x0a```\x0a','runTaskHandlerLoop','\x20条消息','\x20行日志:\x0a```\x0a','clientId','input','###\x20💬\x20当前会话信息\x0a无活跃会话','\x20&&\x20','configurable','❌\x20路径已存在但不是文件:\x20`','senderNick','job','error','⚠️\x20当前无活跃会话或暂无日志','\x0a💡\x20活跃会话已保留','default','robot','DEFAULT_TASK_QUEUE_SIZE','saveTask','handleCronCommand','resolve','📭\x20当前无排队消息','stringify','42405980WvxIaH','authCheck','handleRmCommand','utils-ok','(无输出)','getSessionId','readSessionLogTail','findSubdirByName','定时任务分析失败:\x20','updateSessionFile','parseCronCommand','(未配置群级白名单,使用全局白名单)','userIdToPhone','(无历史数据)','endSession','**\x20已恢复','./claude-process','resolveAllPhonesInConfig','registerCallbackListener','\x20条消息\x0a','🧹\x20缓存清理完成','__setModuleDefault','some','formatTaskInfo','toggleJob','linkConversationId','open\x20-a\x20Terminal\x20\x22','handleTouchCommand','✅\x20已删除','call','getOwnPropertyDescriptor','conversations'];a2_0x3f9c=function(){return _0x418a86;};return a2_0x3f9c();}Object[a2_0x14d974(0x103)](exports,a2_0x14d974(0xf0),{'value':!![]}),exports[a2_0x14d974(0x11f)]=void 0x0;const child_process_1=require(a2_0x14d974(0xdc)),utils_ok_1=require(a2_0x14d974(0x167)),fs_1=__importDefault(require('fs')),path_1=__importDefault(require(a2_0x14d974(0x1a4))),common_1=require(a2_0x14d974(0x1b5)),quote_1=require(a2_0x14d974(0x1b6)),messaging_1=require(a2_0x14d974(0x100)),image_1=require(a2_0x14d974(0x138)),commands_1=require(a2_0x14d974(0x120)),messaging_2=require('./messaging'),claude_process_1=require(a2_0x14d974(0x174)),session_1=require(a2_0x14d974(0xd9)),task_1=require(a2_0x14d974(0x1f4)),api_key_manager_1=require(a2_0x14d974(0x10f)),cron_1=require(a2_0x14d974(0x1eb)),TOOL_VERSION=(0x0,common_1['projUtil'])()[a2_0x14d974(0x1fb)]();class DingClaude{constructor(_0x3cf962){const _0x874c98=a2_0x14d974;this['resolvedPhones']={},this['activeSessions']=new Map(),this[_0x874c98(0xca)]=0x5,this['DEFAULT_TASK_HANDLER_COUNT']=0x1,this[_0x874c98(0x15e)]=0x32,this[_0x874c98(0x1ca)]=_0x2032ef=>(0x0,messaging_2[_0x874c98(0x1ca)])(this,_0x2032ef),this[_0x874c98(0x18c)]=(_0x1b8877,_0x7399ca,_0x1175f3,_0x1609f5)=>(0x0,messaging_2[_0x874c98(0x18c)])(this,_0x1b8877,_0x7399ca,_0x1175f3,_0x1609f5),this[_0x874c98(0x1e5)]=claude_process_1[_0x874c98(0x1e5)],this[_0x874c98(0x147)]=(_0x53435c,_0x43640)=>(0x0,claude_process_1['interruptClaudeProcess'])(_0x53435c,_0x43640),this[_0x874c98(0x186)]=(_0x4ec1d5,_0xbdd15f,_0x26577c)=>(0x0,claude_process_1[_0x874c98(0x186)])(this,_0x4ec1d5,_0xbdd15f,_0x26577c),this[_0x874c98(0x121)]=()=>(0x0,session_1[_0x874c98(0x121)])(this),this[_0x874c98(0x102)]=()=>(0x0,session_1['getClientConfig'])(this),this[_0x874c98(0x165)]=(_0x50cd39,_0x5d64a6)=>(0x0,session_1[_0x874c98(0x165)])(this,_0x50cd39,_0x5d64a6),this['isOwner']=_0x54df67=>(0x0,session_1[_0x874c98(0x1a5)])(this,_0x54df67),this[_0x874c98(0x1e3)]=(_0x3f81d5,..._0x520bbc)=>(0x0,session_1[_0x874c98(0x1e3)])(this,_0x3f81d5,..._0x520bbc),this['hashConversationId']=_0x104537=>(0x0,session_1['hashConversationId'])(this,_0x104537),this[_0x874c98(0x1e8)]=_0x37ad7c=>(0x0,session_1[_0x874c98(0x1e8)])(this,_0x37ad7c),this[_0x874c98(0x144)]=_0x16e3ba=>(0x0,session_1[_0x874c98(0x144)])(this,_0x16e3ba),this[_0x874c98(0x109)]=_0x26cf61=>(0x0,session_1[_0x874c98(0x109)])(this,_0x26cf61),this[_0x874c98(0xc1)]=_0x2d9182=>(0x0,session_1['getTasksDir'])(this,_0x2d9182),this['getSessionDir']=_0x312e4d=>(0x0,session_1[_0x874c98(0x1fc)])(this,_0x312e4d),this['getSessionId']=session_1[_0x874c98(0x169)],this[_0x874c98(0x142)]=_0x8bb070=>(0x0,session_1[_0x874c98(0x142)])(this,_0x8bb070),this[_0x874c98(0x16a)]=(_0x326f6c,_0x48d223)=>(0x0,session_1[_0x874c98(0x16a)])(this,_0x326f6c,_0x48d223),this['findActiveSession']=_0x429f4f=>(0x0,session_1[_0x874c98(0xf1)])(this,_0x429f4f),this['findHistorySession']=(_0xc86e2e,_0x73f332)=>(0x0,session_1[_0x874c98(0x219)])(this,_0xc86e2e,_0x73f332),this[_0x874c98(0x1b4)]=_0x384619=>(0x0,session_1[_0x874c98(0x1b4)])(this,_0x384619),this[_0x874c98(0x16d)]=(_0x400e63,_0x1cb8e2)=>(0x0,session_1[_0x874c98(0x16d)])(this,_0x400e63,_0x1cb8e2),this[_0x874c98(0x193)]=session_1[_0x874c98(0x193)],this[_0x874c98(0xd5)]=_0x1f50c3=>(0x0,session_1[_0x874c98(0xd5)])(this,_0x1f50c3),this[_0x874c98(0x105)]=_0x23524f=>(0x0,session_1[_0x874c98(0x105)])(this,_0x23524f),this[_0x874c98(0x13f)]=()=>(0x0,session_1[_0x874c98(0x13f)])(this),this[_0x874c98(0x172)]=(_0x56b9c9,_0x4c2756)=>(0x0,session_1['endSession'])(this,_0x56b9c9,_0x4c2756),this['switchToSession']=(_0x1c90c1,_0x1a1e29,_0x3f48ab,_0x47baef,_0x17469c)=>(0x0,session_1[_0x874c98(0x1b9)])(this,_0x1c90c1,_0x1a1e29,_0x3f48ab,_0x47baef,_0x17469c),this[_0x874c98(0x20b)]=_0x266c35=>(0x0,session_1[_0x874c98(0x20b)])(this,_0x266c35),this[_0x874c98(0x11c)]=_0x262f0c=>(0x0,session_1['handleSessionMessage'])(this,_0x262f0c),this['cleanCache']=(_0x16fa62,_0xfb6016=!![])=>(0x0,session_1[_0x874c98(0xe2)])(this,_0x16fa62,_0xfb6016),this[_0x874c98(0x17b)]=()=>(0x0,task_1[_0x874c98(0x17b)])(this),this[_0x874c98(0x1dd)]=(_0x47ab98,_0xed19dc)=>(0x0,task_1[_0x874c98(0x1dd)])(this,_0x47ab98,_0xed19dc),this[_0x874c98(0x148)]=()=>(0x0,task_1[_0x874c98(0x148)])(this),this[_0x874c98(0x1ad)]=()=>(0x0,task_1[_0x874c98(0x1ad)])(this),this[_0x874c98(0x20e)]=_0x4a05c2=>(0x0,task_1[_0x874c98(0x20e)])(this,_0x4a05c2),this['handleTask']=()=>(0x0,task_1['handleTask'])(this),this[_0x874c98(0x14e)]=()=>(0x0,task_1['runTaskHandlerLoop'])(this),this[_0x874c98(0x15f)]=_0x5dcd79=>(0x0,task_1[_0x874c98(0x15f)])(this,_0x5dcd79),this[_0x874c98(0x151)]=_0x3cf962,this['config']=(0x0,session_1[_0x874c98(0x102)])(this);try{this[_0x874c98(0x10d)]=new utils_ok_1['DingStreamClient']({'clientId':_0x3cf962,'clientSecret':this['config'][_0x874c98(0x114)],'keepAlive':!![],'debug':this['config']['debug']??![]});}catch(_0x405ab7){console[_0x874c98(0x159)](_0x874c98(0x1a6),_0x405ab7),process[_0x874c98(0x149)](0x1);}this['cronEngine']=new cron_1[(_0x874c98(0xc4))](this);}async[a2_0x14d974(0x141)](_0x2694b8,_0x231ae6,_0x34383f){const _0x4641d8=a2_0x14d974;if(!this[_0x4641d8(0x1a5)](_0x34383f))return await this[_0x4641d8(0x1ca)]({'conversationId':_0x2694b8,'sessionWebhook':_0x231ae6,'content':_0x4641d8(0x184),'msgType':_0x4641d8(0x107)}),![];return!![];}async[a2_0x14d974(0xdb)](_0x5d41a5,_0x3fd229,_0x168301,_0x2f756e){const _0x3a5e5d=a2_0x14d974;if(this['isOwner'](_0x168301))return!![];if(_0x2f756e?.['conversationType']==='1')return!![];return await this[_0x3a5e5d(0x1ca)]({'conversationId':_0x5d41a5,'sessionWebhook':_0x3fd229,'content':'❌\x20只有机器人\x20owner\x20才能执行此操作','msgType':_0x3a5e5d(0x107)}),![];}async[a2_0x14d974(0x160)](_0x4600a4,_0x4e14cc){const _0x5d8d3d=a2_0x14d974,{conversationId:_0x5cf7d0,sessionWebhook:_0x16f8ef,senderStaffId:_0xe6b131,senderNick:_0xf8bf89,conversationConfig:_0x5f0c7a}=_0x4e14cc;switch(_0x4600a4[_0x5d8d3d(0x1f9)]){case _0x5d8d3d(0x108):{const _0x33e286=await this[_0x5d8d3d(0xc6)](_0x5cf7d0,_0x16f8ef,_0xe6b131,_0xf8bf89,_0x5f0c7a,!![]),_0x12bab0=this['cronEngine'][_0x5d8d3d(0x110)](_0x5cf7d0);_0x33e286[_0x5d8d3d(0x106)]&&(this[_0x5d8d3d(0x193)](_0x33e286['sessionDir'],_0x5d8d3d(0x207),'/cron\x20list'),this[_0x5d8d3d(0x193)](_0x33e286[_0x5d8d3d(0x106)],'assistant',_0x5d8d3d(0x1c5)+_0x12bab0[_0x5d8d3d(0x206)]+'\x20个定时任务'));await this['sendDingMessage']({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':(0x0,cron_1['formatCronJobList'])(_0x12bab0),'msgType':_0x5d8d3d(0x107)});return;}case _0x5d8d3d(0x1ef):{const _0x20366e=this[_0x5d8d3d(0xe7)][_0x5d8d3d(0x201)](_0x4600a4['id']),_0x2ef058=await this['getOrCreateLogSession'](_0x5cf7d0,_0x16f8ef,_0xe6b131,_0xf8bf89,_0x5f0c7a);_0x2ef058['sessionDir']&&(this['appendSessionLog'](_0x2ef058[_0x5d8d3d(0x106)],_0x5d8d3d(0x207),'/cron\x20delete\x20'+_0x4600a4['id']),this[_0x5d8d3d(0x193)](_0x2ef058[_0x5d8d3d(0x106)],_0x5d8d3d(0x1b8),_0x20366e?'删除定时任务\x20'+_0x4600a4['id']:'未找到定时任务:\x20'+_0x4600a4['id']));await this['sendDingMessage']({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':_0x20366e?_0x5d8d3d(0x132)+_0x4600a4['id']+_0x5d8d3d(0xda):'❌\x20未找到定时任务:\x20'+_0x4600a4['id'],'msgType':_0x5d8d3d(0x107)});return;}case _0x5d8d3d(0xf2):{const _0x2248aa=this[_0x5d8d3d(0xe7)][_0x5d8d3d(0x17c)](_0x4600a4['id'],![]),_0x3d196a=await this['getOrCreateLogSession'](_0x5cf7d0,_0x16f8ef,_0xe6b131,_0xf8bf89,_0x5f0c7a);_0x3d196a['sessionDir']&&(this[_0x5d8d3d(0x193)](_0x3d196a[_0x5d8d3d(0x106)],_0x5d8d3d(0x207),'/cron\x20pause\x20'+_0x4600a4['id']),this[_0x5d8d3d(0x193)](_0x3d196a[_0x5d8d3d(0x106)],_0x5d8d3d(0x1b8),_0x2248aa?_0x5d8d3d(0x200)+_0x4600a4['id']:_0x5d8d3d(0xbf)+_0x4600a4['id']));await this[_0x5d8d3d(0x1ca)]({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':_0x2248aa?_0x5d8d3d(0x1f5)+_0x4600a4['id']+_0x5d8d3d(0x1ac):_0x5d8d3d(0x12b)+_0x4600a4['id'],'msgType':'markdown'});return;}case _0x5d8d3d(0xbb):{const _0x58c9e2=this['cronEngine']['toggleJob'](_0x4600a4['id'],!![]),_0x443e79=await this[_0x5d8d3d(0xc6)](_0x5cf7d0,_0x16f8ef,_0xe6b131,_0xf8bf89,_0x5f0c7a);_0x443e79[_0x5d8d3d(0x106)]&&(this[_0x5d8d3d(0x193)](_0x443e79[_0x5d8d3d(0x106)],'user',_0x5d8d3d(0x126)+_0x4600a4['id']),this['appendSessionLog'](_0x443e79[_0x5d8d3d(0x106)],_0x5d8d3d(0x1b8),_0x58c9e2?_0x5d8d3d(0x1ce)+_0x4600a4['id']:_0x5d8d3d(0xbf)+_0x4600a4['id']));await this[_0x5d8d3d(0x1ca)]({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':_0x58c9e2?_0x5d8d3d(0xcf)+_0x4600a4['id']+_0x5d8d3d(0x173):_0x5d8d3d(0x12b)+_0x4600a4['id'],'msgType':'markdown'});return;}case _0x5d8d3d(0xd4):{if(!(0x0,cron_1[_0x5d8d3d(0x1d1)])(_0x4600a4['cronExpression'])){await this[_0x5d8d3d(0x1ca)]({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':_0x5d8d3d(0x128)+_0x4600a4[_0x5d8d3d(0xcb)]+_0x5d8d3d(0x209),'msgType':_0x5d8d3d(0x107)});return;}if(!this[_0x5d8d3d(0xed)](_0x4e14cc['conversationConfig'])){await this['sendCronNoNotifyError'](_0x5cf7d0,_0x16f8ef);return;}const _0x9053c=this[_0x5d8d3d(0xe7)][_0x5d8d3d(0x10c)]({'conversationId':_0x5cf7d0,'cronExpression':_0x4600a4[_0x5d8d3d(0xcb)],'description':this['sanitizeLogContent'](_0x4600a4[_0x5d8d3d(0x12e)][_0x5d8d3d(0x117)](0x0,0x32)),'prompt':_0x4600a4[_0x5d8d3d(0x12e)],'senderStaffId':_0xe6b131,'senderNick':_0xf8bf89}),_0x9d3515=await this[_0x5d8d3d(0xc6)](_0x5cf7d0,_0x16f8ef,_0xe6b131,_0xf8bf89,_0x5f0c7a);_0x9d3515[_0x5d8d3d(0x106)]&&(this[_0x5d8d3d(0x193)](_0x9d3515[_0x5d8d3d(0x106)],_0x5d8d3d(0x207),'/cron\x20'+_0x4600a4[_0x5d8d3d(0xcb)]+'\x20'+this['sanitizeLogContent'](_0x4600a4[_0x5d8d3d(0x12e)])),this[_0x5d8d3d(0x193)](_0x9d3515[_0x5d8d3d(0x106)],_0x5d8d3d(0x1b8),'创建定时任务:\x20'+_0x9053c['id']+'\x20['+_0x9053c[_0x5d8d3d(0xcb)]+']\x20'+_0x9053c[_0x5d8d3d(0x1f6)]));await this[_0x5d8d3d(0x1ca)]({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':(0x0,cron_1[_0x5d8d3d(0x11e)])(_0x9053c),'msgType':'markdown'});return;}case _0x5d8d3d(0x1f0):{if(!this['hasNotifyCapability'](_0x4e14cc[_0x5d8d3d(0x217)])){await this['sendCronNoNotifyError'](_0x5cf7d0,_0x16f8ef);return;}await this['sendDingMessage']({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':_0x5d8d3d(0x205)});const _0x3c7a12=await this['cronEngine'][_0x5d8d3d(0x12c)](_0x5cf7d0,_0x4600a4[_0x5d8d3d(0x152)],_0xe6b131,_0xf8bf89),_0x1cb36f=await this[_0x5d8d3d(0xc6)](_0x5cf7d0,_0x16f8ef,_0xe6b131,_0xf8bf89,_0x5f0c7a);_0x3c7a12[_0x5d8d3d(0x158)]?(_0x1cb36f[_0x5d8d3d(0x106)]&&(this[_0x5d8d3d(0x193)](_0x1cb36f[_0x5d8d3d(0x106)],'user',_0x5d8d3d(0xe0)+this[_0x5d8d3d(0xdf)](_0x4600a4[_0x5d8d3d(0x152)])),this[_0x5d8d3d(0x193)](_0x1cb36f[_0x5d8d3d(0x106)],_0x5d8d3d(0x1b8),_0x5d8d3d(0x1f8)+_0x3c7a12[_0x5d8d3d(0x158)]['id']+'\x20['+_0x3c7a12[_0x5d8d3d(0x158)][_0x5d8d3d(0xcb)]+']\x20'+_0x3c7a12['job'][_0x5d8d3d(0x1f6)])),await this[_0x5d8d3d(0x1ca)]({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':(0x0,cron_1['formatCronJobInfo'])(_0x3c7a12[_0x5d8d3d(0x158)]),'msgType':'markdown'})):(_0x1cb36f[_0x5d8d3d(0x106)]&&(this[_0x5d8d3d(0x193)](_0x1cb36f[_0x5d8d3d(0x106)],_0x5d8d3d(0x207),_0x5d8d3d(0xe0)+this[_0x5d8d3d(0xdf)](_0x4600a4['input'])),this[_0x5d8d3d(0x193)](_0x1cb36f['sessionDir'],_0x5d8d3d(0x1b8),_0x5d8d3d(0x16c)+_0x3c7a12[_0x5d8d3d(0x159)])),await this['sendDingMessage']({'conversationId':_0x5cf7d0,'sessionWebhook':_0x16f8ef,'content':'❌\x20定时任务分析失败:\x20'+_0x3c7a12[_0x5d8d3d(0x159)]+_0x5d8d3d(0xdd),'msgType':_0x5d8d3d(0x107)}));return;}}}[a2_0x14d974(0xdf)](_0x5b791a){const _0x23666d=a2_0x14d974;return _0x5b791a[_0x23666d(0xe5)](/\n/g,'\x5cn')[_0x23666d(0xe5)](/\r/g,'\x5cr');}[a2_0x14d974(0x1c0)](_0x273832){const _0x24a4e4=a2_0x14d974,_0x314433=_0x273832[_0x24a4e4(0xe5)](/\r\n/g,'\x0a'),_0x7d30a1=0x1f40;if(_0x314433[_0x24a4e4(0x206)]>_0x7d30a1)return _0x314433[_0x24a4e4(0x117)](0x0,_0x7d30a1)+_0x24a4e4(0x1d9);return _0x314433;}[a2_0x14d974(0x1cd)](_0x4bffee,_0x1c3b92=0x64){const _0x5957f9=a2_0x14d974,_0x5de864=_0x4bffee['replace'](/\n/g,'\x20')[_0x5957f9(0x202)]();return _0x5de864[_0x5957f9(0x206)]>_0x1c3b92?_0x5de864[_0x5957f9(0xfe)](0x0,_0x1c3b92)+_0x5957f9(0x124):_0x5de864;}async[a2_0x14d974(0xc6)](_0x788b67,_0x1f87ad,_0x971d5b,_0x43ab7d,_0x499649,_0x270a85=![]){const _0x579054=a2_0x14d974,_0xd3323c=this[_0x579054(0xf1)](_0x788b67);if(_0xd3323c){const _0x279861=this[_0x579054(0x1fc)](_0xd3323c[_0x579054(0x1a2)]['session']);return{'sessionDir':_0x279861,'isNew':![]};}if(_0x270a85)return{'sessionDir':null,'isNew':![]};const _0x9ace19=Date[_0x579054(0xea)](),_0x34c815={'conversationId':_0x788b67,'sessionWebhook':_0x1f87ad,'startTime':_0x9ace19,'startTimeStr':utils_ok_1[_0x579054(0x14a)]['mm'](_0x9ace19)[_0x579054(0x1c1)]('YYYY-MM-DD-HH-mm-ss'),'startStaffId':_0x971d5b,'startNickName':_0x579054(0xf9)+_0x43ab7d},_0x373d5b=this[_0x579054(0x1fc)](_0x34c815);return fs_1[_0x579054(0x15c)][_0x579054(0x1dc)](_0x373d5b,{'recursive':!![]}),fs_1[_0x579054(0x15c)]['writeFileSync'](_0x373d5b+_0x579054(0x1fe),JSON[_0x579054(0x163)](_0x34c815,null,0x2),_0x579054(0x203)),fs_1[_0x579054(0x15c)]['appendFileSync'](_0x373d5b+'/session.log','['+(0x0,session_1['timestamp'])()+_0x579054(0x127),_0x579054(0x203)),{'sessionDir':_0x373d5b,'isNew':!![]};}['hasNotifyCapability'](_0x2b7fb5){const _0x57ecc9=a2_0x14d974;return!!(_0x2b7fb5[_0x57ecc9(0x1cb)]||this[_0x57ecc9(0xfb)][_0x57ecc9(0x215)]);}async[a2_0x14d974(0x1ea)](_0xb95715,_0x2e7d94){const _0x3f9c39=a2_0x14d974;await this[_0x3f9c39(0x1ca)]({'conversationId':_0xb95715,'sessionWebhook':_0x2e7d94,'content':_0x3f9c39(0xe1),'msgType':_0x3f9c39(0x107)});}[a2_0x14d974(0x18a)](_0x57e14a,_0x35d3b9){const _0x3df5b4=a2_0x14d974,_0x1c3291=this['getConversationDir'](_0x57e14a);if(_0x35d3b9[_0x3df5b4(0x212)]('/'))return{'absolutePath':'','error':'❌\x20路径不能使用绝对路径(不能以\x20/\x20开头)'};const _0x4e9c56=path_1[_0x3df5b4(0x15c)]['resolve'](_0x1c3291,_0x35d3b9);if(!_0x4e9c56[_0x3df5b4(0x212)](_0x1c3291))return{'absolutePath':'','error':'❌\x20路径超出工作目录范围'};return{'absolutePath':_0x4e9c56};}async[a2_0x14d974(0x197)](_0x37871d,_0x5415c2,_0xafffcb){const _0x4735d5=a2_0x14d974,{absolutePath:_0x310a98,error:_0x53904d}=this[_0x4735d5(0x18a)](_0x37871d,_0xafffcb);if(_0x53904d){await this['sendDingMessage']({'conversationId':_0x37871d,'sessionWebhook':_0x5415c2,'content':_0x53904d,'msgType':'markdown'});return;}try{const _0x492cc3=fs_1[_0x4735d5(0x15c)]['statSync'](_0x310a98);_0x492cc3[_0x4735d5(0x1aa)]()?await this[_0x4735d5(0x1ca)]({'conversationId':_0x37871d,'sessionWebhook':_0x5415c2,'content':_0x4735d5(0xfd)+_0xafffcb+'`','msgType':_0x4735d5(0x107)}):await this[_0x4735d5(0x1ca)]({'conversationId':_0x37871d,'sessionWebhook':_0x5415c2,'content':_0x4735d5(0x1ae)+_0xafffcb+'`','msgType':_0x4735d5(0x107)});return;}catch{}try{fs_1[_0x4735d5(0x15c)][_0x4735d5(0x1dc)](_0x310a98,{'recursive':!![]}),await this[_0x4735d5(0x1ca)]({'conversationId':_0x37871d,'sessionWebhook':_0x5415c2,'content':_0x4735d5(0xd8)+_0xafffcb+'`','msgType':'markdown'});}catch(_0x4f5d7e){await this[_0x4735d5(0x1ca)]({'conversationId':_0x37871d,'sessionWebhook':_0x5415c2,'content':_0x4735d5(0xe9)+_0xafffcb+_0x4735d5(0x143)+(_0x4f5d7e instanceof Error?_0x4f5d7e[_0x4735d5(0x1e9)]:String(_0x4f5d7e)),'msgType':'markdown'});}}async[a2_0x14d974(0x166)](_0x4e133b,_0x34653e,_0x4c95c1){const _0x2a3cdb=a2_0x14d974,{absolutePath:_0x3a8665,error:_0x2d2162}=this['resolveAndValidatePath'](_0x4e133b,_0x4c95c1);if(_0x2d2162){await this['sendDingMessage']({'conversationId':_0x4e133b,'sessionWebhook':_0x34653e,'content':_0x2d2162,'msgType':_0x2a3cdb(0x107)});return;}let _0xb0af84;try{_0xb0af84=fs_1[_0x2a3cdb(0x15c)]['statSync'](_0x3a8665);}catch{await this[_0x2a3cdb(0x1ca)]({'conversationId':_0x4e133b,'sessionWebhook':_0x34653e,'content':'❌\x20路径不存在:\x20`'+_0x4c95c1+'`','msgType':_0x2a3cdb(0x107)});return;}const _0x1fa7d0=_0xb0af84[_0x2a3cdb(0x1aa)]();try{_0x1fa7d0?fs_1[_0x2a3cdb(0x15c)][_0x2a3cdb(0x1d4)](_0x3a8665,{'recursive':!![],'force':!![]}):fs_1[_0x2a3cdb(0x15c)][_0x2a3cdb(0xe4)](_0x3a8665),await this['sendDingMessage']({'conversationId':_0x4e133b,'sessionWebhook':_0x34653e,'content':_0x2a3cdb(0x180)+(_0x1fa7d0?'目录':'文件')+':\x20`'+_0x4c95c1+'`','msgType':_0x2a3cdb(0x107)});}catch(_0xaa5cfb){await this[_0x2a3cdb(0x1ca)]({'conversationId':_0x4e133b,'sessionWebhook':_0x34653e,'content':_0x2a3cdb(0x129)+_0x4c95c1+_0x2a3cdb(0x143)+(_0xaa5cfb instanceof Error?_0xaa5cfb[_0x2a3cdb(0x1e9)]:String(_0xaa5cfb)),'msgType':_0x2a3cdb(0x107)});}}async[a2_0x14d974(0x17f)](_0x9cdf15,_0x5ee30d,_0xccec8f){const _0x8e9b9=a2_0x14d974,{absolutePath:_0x50011e,error:_0x46e130}=this[_0x8e9b9(0x18a)](_0x9cdf15,_0xccec8f);if(_0x46e130){await this[_0x8e9b9(0x1ca)]({'conversationId':_0x9cdf15,'sessionWebhook':_0x5ee30d,'content':_0x46e130,'msgType':'markdown'});return;}try{const _0x2ee6ac=fs_1['default'][_0x8e9b9(0x195)](_0x50011e);_0x2ee6ac['isFile']()?await this[_0x8e9b9(0x1ca)]({'conversationId':_0x9cdf15,'sessionWebhook':_0x5ee30d,'content':'⚠️\x20文件已存在:\x20`'+_0xccec8f+_0x8e9b9(0x20d)+utils_ok_1[_0x8e9b9(0x14a)]['mm'](_0x2ee6ac['mtime'])['format'](_0x8e9b9(0x10a)),'msgType':_0x8e9b9(0x107)}):await this[_0x8e9b9(0x1ca)]({'conversationId':_0x9cdf15,'sessionWebhook':_0x5ee30d,'content':_0x8e9b9(0x156)+_0xccec8f+'`','msgType':_0x8e9b9(0x107)});return;}catch{}try{const _0x4db11c=path_1[_0x8e9b9(0x15c)]['dirname'](_0x50011e);fs_1[_0x8e9b9(0x15c)]['mkdirSync'](_0x4db11c,{'recursive':!![]}),fs_1[_0x8e9b9(0x15c)][_0x8e9b9(0x1db)](_0x50011e,'',_0x8e9b9(0x203)),await this[_0x8e9b9(0x1ca)]({'conversationId':_0x9cdf15,'sessionWebhook':_0x5ee30d,'content':_0x8e9b9(0xd6)+_0xccec8f+'`','msgType':_0x8e9b9(0x107)});}catch(_0x25a57d){await this[_0x8e9b9(0x1ca)]({'conversationId':_0x9cdf15,'sessionWebhook':_0x5ee30d,'content':'❌\x20文件创建失败:\x20`'+_0xccec8f+'`\x0a原因:\x20'+(_0x25a57d instanceof Error?_0x25a57d['message']:String(_0x25a57d)),'msgType':_0x8e9b9(0x107)});}}async['botMsgGetCallback'](_0x172dce){const _0x2c959c=a2_0x14d974;this[_0x2c959c(0x10d)][_0x2c959c(0x1df)](_0x172dce['headers'][_0x2c959c(0xcd)],'');const _0x87096e=JSON[_0x2c959c(0x1e2)](_0x172dce[_0x2c959c(0x136)]),{senderNick:_0x1f50b0,senderStaffId:_0x2feb3d,conversationId:_0x27df03,conversationTitle:_0x51594d,sessionWebhook:_0x11e179,msgtype:_0x89fd99,conversationType:_0x379be9}=_0x87096e,_0x57d3f9=_0x87096e[_0x2c959c(0x187)]?.[_0x2c959c(0x1d5)]?.[_0x2c959c(0x202)]()??'';this[_0x2c959c(0x1e3)](_0x2c959c(0xc9)+_0x51594d+'('+_0x27df03+'),\x20发送者='+_0x1f50b0+'('+_0x2feb3d+'),\x20类型='+_0x89fd99+',\x20内容='+_0x57d3f9[_0x2c959c(0x117)](0x0,0x32));if(!this[_0x2c959c(0x165)](_0x2feb3d,_0x27df03)){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'atUserId':_0x2feb3d,'content':_0x2c959c(0x1cc)});return;}const _0x5dca14=this[_0x2c959c(0x1e8)](_0x27df03);let _0xc2e69e;if(_0x89fd99===_0x2c959c(0x11d)&&_0x87096e[_0x2c959c(0xc0)]){const _0x216353=this[_0x2c959c(0x144)](_0x27df03),_0x91e903=_0x5dca14?.[_0x2c959c(0x1d0)]!==![],_0xb8b046=await(0x0,image_1[_0x2c959c(0xf6)])(this,_0x87096e[_0x2c959c(0xc0)],_0x87096e['robotCode'],_0x216353,_0x91e903,_0x57d3f9||undefined);if(!_0xb8b046){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'atUserId':_0x2feb3d,'content':_0x2c959c(0x1d3)});return;}_0xc2e69e=_0xb8b046;}else{if(_0x89fd99===_0x2c959c(0xbc)&&_0x87096e[_0x2c959c(0x1d5)]?.['richText']){const _0x224ef3=this[_0x2c959c(0x144)](_0x27df03),_0x5d0e4d=_0x5dca14?.[_0x2c959c(0x1d0)]!==![];_0xc2e69e=await(0x0,image_1[_0x2c959c(0x1a7)])(this,_0x87096e[_0x2c959c(0x1d5)][_0x2c959c(0xbc)],_0x87096e[_0x2c959c(0x21b)],_0x224ef3,_0x5d0e4d);}else{_0xc2e69e=_0x57d3f9;if(!_0xc2e69e)return;}}if(!_0xc2e69e['startsWith']('/')&&_0x89fd99===_0x2c959c(0x187)){const _0x31f202=(0x0,quote_1[_0x2c959c(0x198)])(_0x87096e);if(_0x31f202){this[_0x2c959c(0x1e3)](_0x2c959c(0xd0)+_0x31f202['quoteMessageId']);if(_0x31f202['quoteMessageId']&&!_0x31f202['quoteText']){const _0x4c3d50=await(0x0,messaging_1['fetchQuotedMessage'])(this,_0x31f202['quoteMessageId']);if(_0x4c3d50)_0x31f202[_0x2c959c(0x11a)]=_0x4c3d50;}_0x31f202['quoteText']&&(_0xc2e69e=(0x0,quote_1[_0x2c959c(0x14b)])(_0xc2e69e,_0x31f202));}}const _0x461b33=(0x0,commands_1[_0x2c959c(0xd2)])(_0xc2e69e);if(_0x461b33!==null){if(_0x461b33[_0x2c959c(0xd3)]&&_0x5dca14?.['conversationType']!=='1'&&!this[_0x2c959c(0x1a5)](_0x2feb3d)){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x145),'msgType':_0x2c959c(0x107)});return;}if(!await this[_0x2c959c(0xdb)](_0x27df03,_0x11e179,_0x2feb3d,_0x5dca14))return;const _0x5e76ad=_0x461b33[_0x2c959c(0xd3)]||_0x27df03,_0x5bed7f=_0x5e76ad!==_0x27df03,_0x5499b0=_0x5bed7f?this[_0x2c959c(0xfb)][_0x2c959c(0x183)][_0x2c959c(0x199)](_0x9c8da4=>_0x9c8da4[_0x2c959c(0xd3)]===_0x5e76ad):_0x5dca14,_0x28cf45=!!(_0x461b33[_0x2c959c(0x1cb)]||_0x461b33[_0x2c959c(0x17d)]||_0x461b33['whiteUserList']&&_0x461b33['whiteUserList']['length']>0x0||_0x461b33['conversationTitle']||_0x461b33[_0x2c959c(0x1d7)]!==undefined||_0x461b33['receiveReply']!==undefined||_0x461b33[_0x2c959c(0x1fd)]!==undefined);if(_0x5499b0&&_0x28cf45){if(_0x461b33[_0x2c959c(0x11b)])_0x5499b0[_0x2c959c(0x11b)]=_0x461b33['conversationTitle'];if(_0x379be9&&!_0x5bed7f)_0x5499b0[_0x2c959c(0x213)]=_0x379be9;if(_0x461b33[_0x2c959c(0x1cb)])_0x5499b0[_0x2c959c(0x1cb)]=_0x461b33[_0x2c959c(0x1cb)];if(_0x461b33['linkConversationId'])_0x5499b0[_0x2c959c(0x17d)]=_0x461b33[_0x2c959c(0x17d)];if(_0x461b33[_0x2c959c(0x1d7)]!==undefined)_0x5499b0[_0x2c959c(0x1d7)]=_0x461b33[_0x2c959c(0x1d7)];if(_0x461b33[_0x2c959c(0x185)]!==undefined)_0x5499b0[_0x2c959c(0x185)]=_0x461b33[_0x2c959c(0x185)];if(_0x461b33[_0x2c959c(0x1fd)]!==undefined)_0x5499b0['preBash']=_0x461b33[_0x2c959c(0x1fd)];if(_0x461b33[_0x2c959c(0x19e)]&&_0x461b33[_0x2c959c(0x19e)][_0x2c959c(0x206)]>0x0){_0x5499b0[_0x2c959c(0x19e)]=_0x461b33[_0x2c959c(0x19e)];for(const _0x1f419d of _0x461b33[_0x2c959c(0x19e)]){(0x0,session_1[_0x2c959c(0x1be)])(_0x1f419d)&&await(0x0,session_1[_0x2c959c(0x13b)])(this,_0x1f419d);}}(0x0,api_key_manager_1[_0x2c959c(0x1e4)])(this),console[_0x2c959c(0xff)]('['+(0x0,session_1[_0x2c959c(0x1e1)])()+']\x20刷新群配置:\x20'+(_0x5499b0[_0x2c959c(0x11b)]||_0x5e76ad)+'('+_0x5e76ad+')');}else{if(!_0x5499b0){const _0x3319d4={'conversationId':_0x5e76ad,'conversationType':_0x5bed7f?'1':_0x379be9,'conversationTitle':_0x461b33[_0x2c959c(0x11b)]||(_0x5bed7f?'':_0x51594d)};if(_0x461b33['dingToken'])_0x3319d4[_0x2c959c(0x1cb)]=_0x461b33[_0x2c959c(0x1cb)];if(_0x461b33[_0x2c959c(0x17d)])_0x3319d4[_0x2c959c(0x17d)]=_0x461b33[_0x2c959c(0x17d)];if(_0x461b33[_0x2c959c(0x1d7)]!==undefined)_0x3319d4[_0x2c959c(0x1d7)]=_0x461b33[_0x2c959c(0x1d7)];if(_0x461b33['receiveReply']!==undefined)_0x3319d4[_0x2c959c(0x185)]=_0x461b33[_0x2c959c(0x185)];if(_0x461b33[_0x2c959c(0x1fd)]!==undefined)_0x3319d4[_0x2c959c(0x1fd)]=_0x461b33[_0x2c959c(0x1fd)];if(_0x461b33[_0x2c959c(0x19e)]&&_0x461b33[_0x2c959c(0x19e)][_0x2c959c(0x206)]>0x0){_0x3319d4[_0x2c959c(0x19e)]=_0x461b33[_0x2c959c(0x19e)];for(const _0x255474 of _0x461b33[_0x2c959c(0x19e)]){(0x0,session_1[_0x2c959c(0x1be)])(_0x255474)&&await(0x0,session_1[_0x2c959c(0x13b)])(this,_0x255474);}}this[_0x2c959c(0xfb)]['conversations'][_0x2c959c(0x1a0)](_0x3319d4),(0x0,api_key_manager_1[_0x2c959c(0x1e4)])(this),console[_0x2c959c(0xff)]('['+(0x0,session_1[_0x2c959c(0x1e1)])()+_0x2c959c(0x19b)+(_0x3319d4['conversationTitle']||_0x5e76ad)+'('+_0x5e76ad+_0x2c959c(0xe3)+(_0x3319d4['conversationType']||'-'));}}const _0x44c819=this[_0x2c959c(0x144)](_0x5e76ad);!fs_1[_0x2c959c(0x15c)][_0x2c959c(0x1ec)](_0x44c819)&&(fs_1[_0x2c959c(0x15c)][_0x2c959c(0x1dc)](_0x44c819,{'recursive':!![]}),console['log']('['+(0x0,session_1[_0x2c959c(0x1e1)])()+_0x2c959c(0x1a3)+_0x44c819));const _0x450e60=_0x5499b0||this[_0x2c959c(0x1e8)](_0x5e76ad),_0x482191=[_0x5499b0?_0x2c959c(0xeb):'✅\x20群已注册',_0x2c959c(0x1d6)+(_0x450e60?.[_0x2c959c(0x11b)]||_0x5e76ad),'-\x20**群ID:**\x20'+_0x5e76ad];if(_0x450e60?.[_0x2c959c(0x213)])_0x482191[_0x2c959c(0x1a0)](_0x2c959c(0x113)+(_0x450e60['conversationType']==='1'?'单聊':_0x450e60[_0x2c959c(0x213)]==='2'?'群聊':_0x450e60['conversationType']));if(_0x450e60?.[_0x2c959c(0x1cb)])_0x482191[_0x2c959c(0x1a0)](_0x2c959c(0x208)+_0x450e60[_0x2c959c(0x1cb)][_0x2c959c(0x117)](0x0,0x8)+'...');else _0x482191['push']('-\x20**dingToken:**\x20(未指定,\x20使用\x20defaultDingToken)');if(_0x450e60?.[_0x2c959c(0x17d)])_0x482191[_0x2c959c(0x1a0)](_0x2c959c(0x12a)+_0x450e60[_0x2c959c(0x17d)]);if(_0x450e60?.[_0x2c959c(0x1d7)]===![])_0x482191[_0x2c959c(0x1a0)](_0x2c959c(0xcc));if(_0x450e60?.[_0x2c959c(0x185)]===![])_0x482191[_0x2c959c(0x1a0)](_0x2c959c(0x10e));if(_0x450e60?.[_0x2c959c(0x19e)]?.[_0x2c959c(0x206)]){const _0x4e4b64=_0x450e60[_0x2c959c(0x19e)][_0x2c959c(0x1c9)](_0x23af90=>{if((0x0,session_1['isMobile'])(_0x23af90))return _0x23af90;return(0x0,session_1['userIdToPhone'])(this,_0x23af90)||_0x23af90;})[_0x2c959c(0x1e7)](',\x20');_0x482191[_0x2c959c(0x1a0)]('-\x20**whiteUserList:**\x20'+_0x4e4b64);}_0x482191[_0x2c959c(0x1a0)](_0x2c959c(0x131)+_0x44c819),_0x482191[_0x2c959c(0x1a0)](_0x2c959c(0x1ff)),await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x482191[_0x2c959c(0x1e7)]('\x0a'),'msgType':_0x2c959c(0x107)});return;}if((0x0,commands_1['parseHelpCommand'])(_0xc2e69e)){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':(0x0,commands_1[_0x2c959c(0x1b7)])(TOOL_VERSION,this['isOwner'](_0x2feb3d)),'msgType':_0x2c959c(0x107)});return;}if((0x0,commands_1[_0x2c959c(0xd7)])(_0xc2e69e)){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x137)+TOOL_VERSION,'msgType':_0x2c959c(0x107)});return;}const _0x10a22f=(0x0,commands_1[_0x2c959c(0x1a8)])(_0xc2e69e);if(_0x10a22f){const _0x5cf1f5=(0x0,commands_1['getCommandByName'])(_0x10a22f);_0x5cf1f5?await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':(0x0,commands_1['formatCommandHelp'])(_0x5cf1f5),'msgType':_0x2c959c(0x107)}):await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x20c)+_0x10a22f+_0x2c959c(0x1c6),'msgType':_0x2c959c(0x107)});return;}if(!_0x5dca14){console['log']('未注册的机器人,群:'+_0x51594d+','+_0x27df03);this[_0x2c959c(0x1a5)](_0x2feb3d)?await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'atUserId':_0x2feb3d,'content':_0x2c959c(0x216),'msgType':_0x2c959c(0x107)}):await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'atUserId':_0x2feb3d,'content':_0x2c959c(0xf3)+_0x27df03+')...'});return;}const _0x9dd00c=(0x0,commands_1[_0x2c959c(0xe6)])(_0xc2e69e);if(_0x9dd00c!==null){if(_0x9dd00c===_0x2c959c(0xe8)&&_0x5dca14?.[_0x2c959c(0x213)]!=='1'&&!this['isOwner'](_0x2feb3d)){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x10b),'msgType':_0x2c959c(0x107)});return;}if(!await this[_0x2c959c(0xdb)](_0x27df03,_0x11e179,_0x2feb3d,_0x5dca14))return;const _0x11a374=_0x9dd00c==='all'?null:_0x27df03,_0x8feb66=this[_0x2c959c(0xe2)](_0x11a374,!![]),_0x1f331e=[];_0x1f331e[_0x2c959c(0x1a0)](_0x2c959c(0x178));if(_0x8feb66['sessionsDeleted']>0x0)_0x1f331e[_0x2c959c(0x1a0)]('-\x20会话目录:\x20'+_0x8feb66[_0x2c959c(0x204)]+'\x20个');if(_0x8feb66[_0x2c959c(0x19d)]>0x0)_0x1f331e['push']('-\x20任务目录:\x20'+_0x8feb66['tasksDeleted']+'\x20个');if(_0x8feb66[_0x2c959c(0x1fa)]>0x0)_0x1f331e[_0x2c959c(0x1a0)](_0x2c959c(0x18f)+_0x8feb66['imagesDeleted']+'\x20个');_0x8feb66[_0x2c959c(0x204)]===0x0&&_0x8feb66[_0x2c959c(0x19d)]===0x0&&_0x8feb66[_0x2c959c(0x1fa)]===0x0&&_0x1f331e['push'](_0x2c959c(0x171));_0x1f331e[_0x2c959c(0x1a0)](_0x2c959c(0x15b));_0x8feb66[_0x2c959c(0x1d2)][_0x2c959c(0x206)]>0x0&&_0x1f331e[_0x2c959c(0x1a0)]('\x0a⚠️\x20错误:\x20'+_0x8feb66[_0x2c959c(0x1d2)][_0x2c959c(0x1e7)](';\x20'));await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x1f331e[_0x2c959c(0x1e7)]('\x0a'),'msgType':_0x2c959c(0x107)});return;}if((0x0,commands_1[_0x2c959c(0xbe)])(_0xc2e69e)){if(!await this['requireOwner'](_0x27df03,_0x11e179,_0x2feb3d))return;if(!this[_0x2c959c(0xfb)][_0x2c959c(0x1f7)]){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'⚠️\x20未配置\x20apiKeyCfg,无需重置','msgType':_0x2c959c(0x107)});return;}(0x0,api_key_manager_1['resetApiKeyCfg'])(this);const _0x259ea4=this[_0x2c959c(0xfb)][_0x2c959c(0x1f7)][_0x2c959c(0x196)][_0x2c959c(0xfa)](_0x3e9b7a=>_0x3e9b7a[_0x2c959c(0x134)])[_0x2c959c(0x206)];await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'✅\x20apiKeyCfg\x20已重置\x0a-\x20有效\x20Key\x20数:\x20'+_0x259ea4+'/'+this[_0x2c959c(0xfb)][_0x2c959c(0x1f7)]['claudeSettings'][_0x2c959c(0x206)]+_0x2c959c(0x13a)+(this['config'][_0x2c959c(0x1f7)][_0x2c959c(0x1c7)]||'-'),'msgType':'markdown'});return;}const _0x5d2aa7=(0x0,commands_1['parseAuthCommand'])(_0xc2e69e);if(_0x5d2aa7){if(!await this[_0x2c959c(0x141)](_0x27df03,_0x11e179,_0x2feb3d))return;const _0x5467aa=_0x5dca14[_0x2c959c(0x19e)];if(_0x5d2aa7['type']===_0x2c959c(0x108)){const _0x18ff26=_0x5467aa&&_0x5467aa[_0x2c959c(0x206)]>0x0?_0x5467aa[_0x2c959c(0x1c9)](_0x17b764=>{const _0x2d1900=_0x2c959c,_0x1d5ebd=(0x0,session_1[_0x2d1900(0x170)])(this,_0x17b764);return'-\x20'+(_0x1d5ebd||_0x17b764);})[_0x2c959c(0x1e7)]('\x0a'):_0x2c959c(0x16f);await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'📋\x20**当前群白名单**\x0a'+_0x18ff26,'msgType':_0x2c959c(0x107)});return;}if(_0x5d2aa7[_0x2c959c(0x1f9)]===_0x2c959c(0x192)){let _0x59f1b8=_0x5d2aa7[_0x2c959c(0xc5)];if((0x0,session_1[_0x2c959c(0x1be)])(_0x5d2aa7['staffId'])){_0x59f1b8=await(0x0,session_1[_0x2c959c(0x13b)])(this,_0x5d2aa7[_0x2c959c(0xc5)]);if(!_0x59f1b8){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x21a)+_0x5d2aa7['staffId'],'msgType':_0x2c959c(0x107)});return;}}const _0x5877d1=_0x5467aa?.[_0x2c959c(0x17a)](_0x51b8fe=>(0x0,session_1[_0x2c959c(0x1bd)])(this,_0x51b8fe)===_0x59f1b8);if(_0x5877d1){const _0x4ad9b7=(0x0,session_1[_0x2c959c(0x170)])(this,_0x59f1b8)||_0x59f1b8;await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x18d)+_0x4ad9b7+'\x20已在当前群白名单中','msgType':_0x2c959c(0x107)});return;}!_0x5dca14[_0x2c959c(0x19e)]&&(_0x5dca14['whiteUserList']=[]);_0x5dca14['whiteUserList'][_0x2c959c(0x1a0)](_0x5d2aa7['staffId']),(0x0,api_key_manager_1[_0x2c959c(0x1e4)])(this);const _0x1b5ac4=_0x5dca14[_0x2c959c(0x19e)][_0x2c959c(0x1c9)](_0x176507=>{const _0x51f1dd=_0x2c959c,_0x45b7d6=(0x0,session_1[_0x51f1dd(0x1bd)])(this,_0x176507);return(0x0,session_1['userIdToPhone'])(this,_0x45b7d6)||_0x176507;}),_0x5bbfee=(0x0,session_1[_0x2c959c(0x1be)])(_0x5d2aa7['staffId'])?_0x5d2aa7['staffId']:(0x0,session_1['userIdToPhone'])(this,_0x5d2aa7[_0x2c959c(0xc5)])||_0x5d2aa7[_0x2c959c(0xc5)];await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x1b1)+_0x5bbfee+_0x2c959c(0x1e6)+_0x1b5ac4['join'](',\x20'),'msgType':_0x2c959c(0x107)});return;}if(_0x5d2aa7['type']===_0x2c959c(0x1d8)){let _0xd7b528=_0x5d2aa7[_0x2c959c(0xc5)];if((0x0,session_1[_0x2c959c(0x1be)])(_0x5d2aa7['staffId'])){_0xd7b528=await(0x0,session_1[_0x2c959c(0x13b)])(this,_0x5d2aa7['staffId']);if(!_0xd7b528){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x21a)+_0x5d2aa7[_0x2c959c(0xc5)],'msgType':_0x2c959c(0x107)});return;}}const _0x4eb44f=_0x5467aa?.['findIndex'](_0x451963=>(0x0,session_1[_0x2c959c(0x1bd)])(this,_0x451963)===_0xd7b528)??-0x1;if(_0x4eb44f<0x0){const _0x5e4daf=(0x0,session_1[_0x2c959c(0x170)])(this,_0xd7b528)||_0xd7b528;await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x18d)+_0x5e4daf+_0x2c959c(0x20a),'msgType':_0x2c959c(0x107)});return;}const _0x2cc79f=_0x5dca14['whiteUserList'][_0x4eb44f];_0x5dca14['whiteUserList'][_0x2c959c(0x1b2)](_0x4eb44f,0x1);_0x5dca14[_0x2c959c(0x19e)][_0x2c959c(0x206)]===0x0&&delete _0x5dca14[_0x2c959c(0x19e)];(0x0,api_key_manager_1[_0x2c959c(0x1e4)])(this);const _0x34d2e8=_0x5dca14[_0x2c959c(0x19e)]?.['length']?_0x5dca14[_0x2c959c(0x19e)]['map'](_0x5951f4=>{const _0x509004=_0x2c959c,_0x28c09c=(0x0,session_1['resolveToUserId'])(this,_0x5951f4);return(0x0,session_1[_0x509004(0x170)])(this,_0x28c09c)||_0x5951f4;})[_0x2c959c(0x1e7)](',\x20'):_0x2c959c(0x1e0),_0x4f8d82=(0x0,session_1['userIdToPhone'])(this,_0xd7b528)||_0x2cc79f;await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x190)+_0x4f8d82+'\x0a当前白名单:\x20'+_0x34d2e8,'msgType':_0x2c959c(0x107)});return;}}const _0x2f4cc5=(0x0,commands_1[_0x2c959c(0x1a1)])(_0xc2e69e);if(_0x2f4cc5!==null){if(!await this[_0x2c959c(0x141)](_0x27df03,_0x11e179,_0x2feb3d))return;const _0x47d915=this[_0x2c959c(0x144)](_0x27df03),{exec:_0x286483}=await Promise[_0x2c959c(0x161)]()[_0x2c959c(0x146)](()=>__importStar(require(_0x2c959c(0xdc)))),_0x432645=process[_0x2c959c(0x1f1)];try{_0x2f4cc5===_0x2c959c(0x14c)?(_0x432645===_0x2c959c(0xc7)?_0x286483('open\x20\x22'+_0x47d915+'\x22'):_0x286483(_0x2c959c(0x1c8)+_0x47d915+'\x22'),await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x1c2)+_0x47d915+_0x2c959c(0x135),'msgType':_0x2c959c(0x107)})):(_0x432645===_0x2c959c(0xc7)?_0x286483(_0x2c959c(0x17e)+_0x47d915+'\x22'):_0x286483(_0x2c959c(0x19c)+_0x47d915+'\x22',{'shell':'cmd.exe'}),await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'💻\x20已在终端中打开:\x0a```\x0a'+_0x47d915+'\x0a```','msgType':_0x2c959c(0x107)}));}catch(_0x3a835c){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x104)+(_0x3a835c instanceof Error?_0x3a835c[_0x2c959c(0x1e9)]:String(_0x3a835c)),'msgType':_0x2c959c(0x107)});}return;}const _0x3cc099=(0x0,commands_1[_0x2c959c(0x16e)])(_0xc2e69e);if(_0x3cc099){await this[_0x2c959c(0x160)](_0x3cc099,{'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'senderStaffId':_0x2feb3d,'senderNick':_0x1f50b0,'conversationConfig':_0x5dca14});return;}if((0x0,commands_1[_0x2c959c(0xf5)])(_0xc2e69e)){const _0x1d049b=this[_0x2c959c(0x144)](_0x27df03);await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'📂\x20当前工作目录:\x0a```\x0a'+_0x1d049b+'\x0a```','msgType':_0x2c959c(0x107)});return;}const _0x58bd1b=(0x0,commands_1[_0x2c959c(0x101)])(_0xc2e69e);if(_0x58bd1b!==null){await this[_0x2c959c(0x197)](_0x27df03,_0x11e179,_0x58bd1b);return;}const _0x163ecc=(0x0,commands_1['parseTouchCommand'])(_0xc2e69e);if(_0x163ecc!==null){await this[_0x2c959c(0x17f)](_0x27df03,_0x11e179,_0x163ecc);return;}const _0x3c9645=(0x0,commands_1[_0x2c959c(0x1b3)])(_0xc2e69e);if(_0x3c9645!==null){await this[_0x2c959c(0x166)](_0x27df03,_0x11e179,_0x3c9645);return;}const _0x4e7c1e=(0x0,commands_1['parseBashCommand'])(_0xc2e69e);if(_0x4e7c1e!==null){const _0x10bef4=this[_0x2c959c(0x144)](_0x27df03),_0x22d124=[];if(this[_0x2c959c(0xfb)][_0x2c959c(0x1fd)])_0x22d124['push'](this[_0x2c959c(0xfb)]['preBash']);if(_0x5dca14?.[_0x2c959c(0x1fd)])_0x22d124[_0x2c959c(0x1a0)](_0x5dca14['preBash']);const _0x17369f=_0x22d124[_0x2c959c(0x206)]>0x0?_0x22d124[_0x2c959c(0x1e7)](_0x2c959c(0x154))+_0x2c959c(0x154)+_0x4e7c1e:_0x4e7c1e,_0x210d90=this;(0x0,child_process_1[_0x2c959c(0x1bb)])(_0x17369f,{'cwd':_0x10bef4,'timeout':0x7530,'maxBuffer':0x400*0x400},async(_0x4febf4,_0x3d3a36,_0x17fd69)=>{const _0x5d85d5=_0x2c959c;try{let _0xe9524;if(_0x4febf4)_0xe9524='❌\x20命令执行失败\x0a```\x0a'+_0x4febf4[_0x5d85d5(0x1e9)]+_0x5d85d5(0x135),_0x17fd69&&(_0xe9524+=_0x5d85d5(0x14d)+_0x210d90[_0x5d85d5(0x1c0)](_0x17fd69)+_0x5d85d5(0x135));else{const _0x1933dd=_0x3d3a36||_0x5d85d5(0x168);_0xe9524=_0x5d85d5(0x111)+_0x210d90[_0x5d85d5(0x1c0)](_0x1933dd)+_0x5d85d5(0x135),_0x17fd69&&(_0xe9524+=_0x5d85d5(0x14d)+_0x210d90[_0x5d85d5(0x1c0)](_0x17fd69)+_0x5d85d5(0x135));}await _0x210d90[_0x5d85d5(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0xe9524,'msgType':_0x5d85d5(0x107)});}catch(_0xaa05e8){console[_0x5d85d5(0x159)]('[bash]\x20发送消息失败:',_0xaa05e8);}});return;}if(/^\/new(?:\s|$)/i['test'](_0xc2e69e)){const _0x587b28=this[_0x2c959c(0xf1)](_0x27df03);_0x587b28&&(console[_0x2c959c(0xff)]('收到新会话命令,结束旧会话:\x20群='+_0x587b28[_0x2c959c(0x1a2)]['session']['conversationId']+_0x2c959c(0xfc)+this[_0x2c959c(0x169)](_0x587b28[_0x2c959c(0x1a2)][_0x2c959c(0x1a2)])),this[_0x2c959c(0x147)](_0x587b28[_0x2c959c(0x1a2)],'新会话命令中断正在执行的\x20Claude\x20进程'),this[_0x2c959c(0x1c3)][_0x2c959c(0x1ef)](_0x587b28[_0x2c959c(0x1ab)]),this[_0x2c959c(0x105)](_0x587b28[_0x2c959c(0x1ab)]));const _0x2dea11=_0xc2e69e['replace'](/^\/new\s*/i,'')[_0x2c959c(0x202)]();_0x2dea11?await this['startNewSession']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'senderStaffId':_0x2feb3d,'senderNick':_0x1f50b0,'message':_0x2dea11,'conversationConfig':_0x5dca14}):await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'atUserId':_0x2feb3d,'content':_0x2c959c(0xee)});return;}const _0x26d605=(0x0,commands_1[_0x2c959c(0x122)])(_0xc2e69e);if(_0x26d605!==null&&_0x5dca14){let _0x544aa6=_0x26d605;if(!_0x544aa6){const _0xefe528=(0x0,session_1[_0x2c959c(0x1b4)])(this,_0x27df03);if(!_0xefe528){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'atUserId':_0x2feb3d,'content':_0x2c959c(0x139),'msgType':'markdown'});return;}_0x544aa6=(0x0,session_1[_0x2c959c(0x169)])(_0xefe528);}await this[_0x2c959c(0x1b9)](_0x27df03,_0x11e179,_0x544aa6,_0x2feb3d,_0x5dca14);return;}const _0x4a0af8=(0x0,commands_1['parseLogCommand'])(_0xc2e69e);if(_0x4a0af8!==null){const _0x147726=this[_0x2c959c(0x16a)](_0x27df03,_0x4a0af8);_0x147726?await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'📋\x20最近\x20'+_0x4a0af8+_0x2c959c(0x150)+_0x147726+_0x2c959c(0x135),'msgType':_0x2c959c(0x107)}):await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x15a)});return;}const _0x401dd9=(0x0,commands_1[_0x2c959c(0x116)])(_0xc2e69e);if(_0x401dd9!==null){const _0x26389c=[],_0x25b2fa=this[_0x2c959c(0x144)](_0x27df03);(_0x401dd9===_0x2c959c(0xe8)||_0x401dd9===_0x2c959c(0x15d))&&(_0x26389c[_0x2c959c(0x1a0)](_0x2c959c(0x18e)+(0x0,commands_1['formatGlobalConfig'])(this[_0x2c959c(0xfb)])),_0x26389c[_0x2c959c(0x1a0)](_0x2c959c(0x1ed)+(0x0,commands_1[_0x2c959c(0x140)])(_0x5dca14,_0x27df03,_0x558781=>(0x0,session_1[_0x2c959c(0x170)])(this,_0x558781),_0x25b2fa)));if(_0x401dd9===_0x2c959c(0xe8)||_0x401dd9==='session'){const _0x5330ed=this['formatSessionInfo'](_0x27df03);_0x5330ed?_0x26389c['push'](_0x2c959c(0x214)+_0x5330ed):_0x26389c[_0x2c959c(0x1a0)](_0x2c959c(0x153));}(_0x401dd9===_0x2c959c(0xe8)||_0x401dd9===_0x2c959c(0x1a9))&&_0x26389c[_0x2c959c(0x1a0)](_0x2c959c(0x1af)+this[_0x2c959c(0x17b)]());await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x26389c[_0x2c959c(0x1e7)]('\x0a\x0a'),'msgType':_0x2c959c(0x107)});return;}const _0x45b15d=(0x0,commands_1[_0x2c959c(0x13c)])(_0xc2e69e);if(_0x45b15d!==null){const {target:_0xbd1c31,depth:_0x67c09}=_0x45b15d,_0x434a24=this[_0x2c959c(0x144)](_0x27df03);let _0x4847cf=_0x434a24,_0x406cb0=_0x2c959c(0x118);if(_0xbd1c31&&_0xbd1c31!==_0x2c959c(0xd1)){if(_0xbd1c31[_0x2c959c(0x212)]('./')||_0xbd1c31[_0x2c959c(0x212)]('../')||_0xbd1c31[_0x2c959c(0x212)]('/')){const _0x1863b5=path_1['default'][_0x2c959c(0x161)](_0x434a24,_0xbd1c31);if(fs_1[_0x2c959c(0x15c)][_0x2c959c(0x1ec)](_0x1863b5)&&fs_1[_0x2c959c(0x15c)]['statSync'](_0x1863b5)[_0x2c959c(0x1aa)]()){if(!_0x1863b5[_0x2c959c(0x212)](_0x434a24)){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0xc8),'msgType':_0x2c959c(0x107)});return;}_0x4847cf=_0x1863b5,_0x406cb0=_0xbd1c31;}else{await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x18b)+_0xbd1c31+'**','msgType':_0x2c959c(0x107)});return;}}else{const _0x5e14e5=(0x0,commands_1[_0x2c959c(0x16b)])(_0x434a24,_0xbd1c31);if(_0x5e14e5)_0x4847cf=_0x5e14e5,_0x406cb0=_0xbd1c31;else{await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'❌\x20未找到名为\x20**'+_0xbd1c31+_0x2c959c(0xf4),'msgType':_0x2c959c(0x107)});return;}}}const _0x449de4=(0x0,commands_1['getDirectoryStructure'])(_0x4847cf,0x0,_0x67c09);await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x1f2)+_0x406cb0+'\x20(展开'+_0x67c09+_0x2c959c(0x1cf)+_0x449de4+'\x0a```','msgType':_0x2c959c(0x107)});return;}const _0x119282=(0x0,task_1['parseTaskCancelCommand'])(_0xc2e69e);if(_0x119282){const _0x856f8a=this[_0x2c959c(0x1dd)](_0x119282,_0x27df03);await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x856f8a,'msgType':_0x2c959c(0x107)});return;}if(_0xc2e69e['startsWith'](_0x2c959c(0x194))){const _0x317a40=_0xc2e69e[_0x2c959c(0x117)](0x6)['trim']();_0x317a40&&(await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'atUserId':_0x2feb3d,'content':_0x2c959c(0x1b0)}),await this[_0x2c959c(0x15f)]({'conversationId':_0x27df03,'prompt':_0x317a40,'senderStaffId':_0x2feb3d,'senderNickName':_0x1f50b0,'sessionWebhook':_0x11e179}));return;}const _0x147b2f=(0x0,commands_1[_0x2c959c(0x191)])(_0xc2e69e);if(_0x147b2f){const _0x57051c=this[_0x2c959c(0xf1)](_0x27df03),_0x7e3cd6=_0x57051c?.[_0x2c959c(0x1a2)][_0x2c959c(0x1ba)]??[];switch(_0x147b2f[_0x2c959c(0x1f9)]){case _0x2c959c(0x108):{if(_0x7e3cd6[_0x2c959c(0x206)]===0x0)await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x162),'msgType':_0x2c959c(0x107)});else{const _0x5c533f=_0x7e3cd6['map']((_0x50c6be,_0x97177b)=>_0x97177b+0x1+'.\x20**'+(_0x50c6be[_0x2c959c(0x157)]||_0x50c6be[_0x2c959c(0x13d)])+_0x2c959c(0x189)+this[_0x2c959c(0x1cd)](_0x50c6be['message']));await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0xf8)+_0x7e3cd6[_0x2c959c(0x206)]+'\x20条)\x0a'+_0x5c533f[_0x2c959c(0x1e7)]('\x0a'),'msgType':'markdown'});}return;}case _0x2c959c(0xf7):{if(_0x7e3cd6[_0x2c959c(0x206)]===0x0){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x162),'msgType':'markdown'});return;}const _0x25610e=Math[_0x2c959c(0x1c4)](_0x147b2f['count'],_0x7e3cd6[_0x2c959c(0x206)]),_0x4b6ff1=_0x7e3cd6[_0x2c959c(0x1b2)](_0x7e3cd6[_0x2c959c(0x206)]-_0x25610e,_0x25610e),_0x586333=_0x4b6ff1[_0x2c959c(0x1c9)]((_0x59ccd2,_0x5e6276)=>_0x5e6276+0x1+'.\x20**'+(_0x59ccd2[_0x2c959c(0x157)]||_0x59ccd2[_0x2c959c(0x13d)])+_0x2c959c(0x189)+this[_0x2c959c(0x1cd)](_0x59ccd2[_0x2c959c(0x1e9)]));await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0xef)+_0x25610e+_0x2c959c(0x177)+_0x586333[_0x2c959c(0x1e7)]('\x0a'),'msgType':'markdown'});return;}case'cancelAll':{if(_0x7e3cd6[_0x2c959c(0x206)]===0x0){await this[_0x2c959c(0x1ca)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':_0x2c959c(0x162),'msgType':'markdown'});return;}const _0x132331=_0x7e3cd6[_0x2c959c(0x206)];_0x7e3cd6[_0x2c959c(0x206)]=0x0,await this['sendDingMessage']({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'content':'✅\x20已清空消息队列,共移除\x20'+_0x132331+_0x2c959c(0x14f),'msgType':_0x2c959c(0x107)});return;}}}await this[_0x2c959c(0x11c)]({'conversationId':_0x27df03,'sessionWebhook':_0x11e179,'senderStaffId':_0x2feb3d,'senderNick':_0x1f50b0,'message':_0xc2e69e,'conversationConfig':_0x5dca14});}async[a2_0x14d974(0xce)](){const _0x40c9f1=a2_0x14d974,_0x55bea3=Array['isArray'](this[_0x40c9f1(0xfb)]['conversations'])?this[_0x40c9f1(0xfb)][_0x40c9f1(0x183)]:[],_0x212d22=this[_0x40c9f1(0xfb)]['taskHandlerCount']??this[_0x40c9f1(0x210)],_0x3ebc21=_0x55bea3[_0x40c9f1(0x206)]>0x0;console[_0x40c9f1(0xff)]('['+(0x0,session_1['timestamp'])()+_0x40c9f1(0x12d)+this[_0x40c9f1(0x151)]),console[_0x40c9f1(0xff)]('['+(0x0,session_1[_0x40c9f1(0x1e1)])()+_0x40c9f1(0x20f)+_0x55bea3[_0x40c9f1(0x1c9)](_0x208aeb=>_0x208aeb[_0x40c9f1(0x11b)]||_0x208aeb[_0x40c9f1(0xd3)])[_0x40c9f1(0x1e7)](',\x20')),(0x0,api_key_manager_1['startupCheck'])(this),await(0x0,session_1[_0x40c9f1(0x175)])(this);this['config']['apiKeyCfg']&&((0x0,api_key_manager_1[_0x40c9f1(0x19f)])(this),(0x0,api_key_manager_1[_0x40c9f1(0xc3)])(this));this['loadActiveSessions'](),this['cronEngine'][_0x40c9f1(0xbd)]();_0x3ebc21&&console[_0x40c9f1(0xff)]('['+(0x0,session_1[_0x40c9f1(0x1e1)])()+_0x40c9f1(0x13e)+_0x212d22);this['dingStreamClient'][_0x40c9f1(0x176)](_0x40c9f1(0x133),async _0x324e66=>{const _0xe594eb=_0x40c9f1;await this[_0xe594eb(0x19a)](_0x324e66);});const _0xbfe829=[];if(_0x3ebc21)for(let _0x2180c2=0x0;_0x2180c2<_0x212d22;_0x2180c2++){console[_0x40c9f1(0xff)]('['+(0x0,session_1[_0x40c9f1(0x1e1)])()+_0x40c9f1(0x1de)+(_0x2180c2+0x1)),_0xbfe829['push'](this[_0x40c9f1(0x14e)]()['catch'](_0x4b7691=>console[_0x40c9f1(0x159)]('任务处理器\x20#'+(_0x2180c2+0x1)+'\x20错误:',_0x4b7691)));}const _0x2340ba=this[_0x40c9f1(0x10d)][_0x40c9f1(0x211)]()['catch'](_0x374f6d=>{const _0x1dbcac=_0x40c9f1;console[_0x1dbcac(0x159)](_0x1dbcac(0xec),_0x374f6d),process[_0x1dbcac(0x149)](0x1);});await Promise[_0x40c9f1(0xe8)]([_0x2340ba,..._0xbfe829]);}}exports[a2_0x14d974(0x11f)]=DingClaude;
|