@lovrabet/lovrabet-cli 2.1.8-beta.1 → 2.1.8-beta.2
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/lib/cli.js +1 -1
- package/lib/commands/api-doc/index.js +1 -1
- package/lib/commands/app/cache.js +1 -1
- package/lib/commands/app/definitions.js +1 -1
- package/lib/commands/app/eligibility.js +1 -1
- package/lib/commands/app/mock-loader.js +1 -1
- package/lib/commands/app/remote-source.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/artifact/index.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/auth/prompt.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/exec.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/common/config-policy.js +1 -1
- package/lib/commands/common/constraints.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/config/definitions.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/data/index.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/sdk-doc.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/init.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/personal-bff/index.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/service/dynamic.js +1 -1
- package/lib/commands/service/index.js +1 -1
- package/lib/commands/service/registry.js +1 -1
- package/lib/commands/skill/commands/create.js +1 -1
- package/lib/commands/skill/commands/install.js +1 -1
- package/lib/commands/skill/commands/list.js +1 -1
- package/lib/commands/skill/commands/push.js +1 -1
- package/lib/commands/skill/commands/validate.js +1 -1
- package/lib/commands/skill/flags.js +1 -1
- package/lib/commands/skill/index.js +1 -1
- package/lib/commands/skill/manifest-helpers.js +1 -1
- package/lib/commands/skill/push-execute.js +1 -1
- package/lib/commands/skill/push-flow-helpers.js +1 -1
- package/lib/commands/skill/push-retarget.js +1 -1
- package/lib/commands/skill/scopes.js +1 -1
- package/lib/commands/skill/summary.js +1 -1
- package/lib/commands/skill/templates.js +1 -1
- package/lib/commands/skill/validate.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/update.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/app.js +1 -1
- package/lib/constant/auth-mode.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/distribution.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/product.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/url.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/sdk-client.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/dryrun.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/preparse.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-confirmation.js +1 -1
- package/lib/framework/runner-error.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/service-order.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.js +1 -1
- package/lib/help.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/runtime-skill-sync/constants.js +1 -1
- package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
- package/lib/skills/runtime-skill-sync/hashing.js +1 -1
- package/lib/skills/runtime-skill-sync/links.js +1 -1
- package/lib/skills/runtime-skill-sync/list-local.js +1 -1
- package/lib/skills/runtime-skill-sync/local-files.js +1 -1
- package/lib/skills/runtime-skill-sync/materialize.js +1 -1
- package/lib/skills/runtime-skill-sync/metadata.js +1 -1
- package/lib/skills/runtime-skill-sync/paths.js +1 -1
- package/lib/skills/runtime-skill-sync/push.js +1 -1
- package/lib/skills/runtime-skill-sync/scopes.js +1 -1
- package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
- package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
- package/lib/skills/runtime-skill-sync.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
package/lib/core/api-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_0x3e8e41,_0x3016bc){const _0x5ccf4b=a74_0x1d8d,_0x1ac640=_0x3e8e41();while(!![]){try{const _0x91c51b=-parseInt(_0x5ccf4b(0xf5))/0x1*(parseInt(_0x5ccf4b(0x178))/0x2)+-parseInt(_0x5ccf4b(0x12a))/0x3+-parseInt(_0x5ccf4b(0xec))/0x4*(-parseInt(_0x5ccf4b(0x166))/0x5)+-parseInt(_0x5ccf4b(0x111))/0x6*(-parseInt(_0x5ccf4b(0x13e))/0x7)+-parseInt(_0x5ccf4b(0x106))/0x8+-parseInt(_0x5ccf4b(0x12c))/0x9*(parseInt(_0x5ccf4b(0x114))/0xa)+parseInt(_0x5ccf4b(0x169))/0xb*(parseInt(_0x5ccf4b(0x142))/0xc);if(_0x91c51b===_0x3016bc)break;else _0x1ac640['push'](_0x1ac640['shift']());}catch(_0x177c92){_0x1ac640['push'](_0x1ac640['shift']());}}}(a74_0x4af0,0xd34f4));import{readFile}from'node:fs/promises';import{basename}from'node:path';import{getApiDomain,getRuntimeDomain,getSkillHubDomain}from'../constant/domain.js';import{PRODUCT_CONFIG}from'../constant/product.js';import{CliErrors}from'../errors.js';import{extractList}from'../framework/response.js';let _activeAK;export function setActiveAK(_0x58b5e0){_activeAK=_0x58b5e0||undefined;}export function clearActiveAK(){_activeAK=undefined;}async function apiRequest(_0x3b110f,_0x37a237={}){const _0x366035=a74_0x1d8d,{method:method='GET',body:_0xc6fc0f,headers:headers={},timeout:timeout=0x7530}=_0x37a237,_0x5b2ef3=_activeAK,_0x32df5e=getRuntimeDomain();if(!_0x5b2ef3)throw CliErrors[_0x366035(0x173)](_0x366035(0x118)+PRODUCT_CONFIG[_0x366035(0x109)]+'.');const _0x5e9ce7=''+_0x32df5e+_0x3b110f,_0x4db661={'X-User-AK':_0x5b2ef3},_0x174ee3=new AbortController(),_0x2bd6a7=setTimeout(()=>_0x174ee3[_0x366035(0x129)](),timeout);try{const _0x4f5607=await fetch(_0x5e9ce7,{'method':method,'headers':{'Content-Type':_0x366035(0x11d),'X-Invoke-Source':PRODUCT_CONFIG[_0x366035(0x15b)],..._0x4db661,...headers},'body':_0xc6fc0f?JSON['stringify'](_0xc6fc0f):undefined,'signal':_0x174ee3[_0x366035(0xf9)]});let _0x13b1bc;try{_0x13b1bc=await _0x4f5607[_0x366035(0x127)]();}catch{throw CliErrors[_0x366035(0xfa)]('API\x20returned\x20non-JSON\x20response\x20(HTTP\x20'+_0x4f5607['status']+')',_0x4f5607['status']>=0x190?_0x366035(0x11c):undefined);}if(!_0x4f5607['ok']||_0x13b1bc[_0x366035(0x12f)]===![])throw CliErrors[_0x366035(0xfa)](_0x13b1bc['errorMsg']||_0x13b1bc[_0x366035(0x102)]||'API\x20error:\x20'+_0x4f5607['status'],_0x13b1bc[_0x366035(0x170)]?_0x366035(0x13d)+_0x13b1bc[_0x366035(0x170)]:undefined);return _0x13b1bc;}catch(_0x5ce043){if(_0x5ce043 instanceof Error&&_0x5ce043[_0x366035(0x128)]===_0x366035(0x16b))throw CliErrors[_0x366035(0xfa)](_0x366035(0xf2)+_0x5e9ce7);throw _0x5ce043;}finally{clearTimeout(_0x2bd6a7);}}async function apiBinaryRequest(_0x37115e,_0x766ce0={}){const _0x598574=a74_0x1d8d,{method:method=_0x598574(0x172),headers:headers={},timeout:timeout=0x7530}=_0x766ce0,_0x2298a6=_activeAK,_0x281561=getRuntimeDomain();if(!_0x2298a6)throw CliErrors[_0x598574(0x173)]('Configure\x20accessKey\x20in\x20'+PRODUCT_CONFIG['newConfigFileName']+'.');const _0x4df161=''+_0x281561+_0x37115e,_0x4a0fbb=new AbortController(),_0x226a83=setTimeout(()=>_0x4a0fbb[_0x598574(0x129)](),timeout);try{const _0x1a75b6=await fetch(_0x4df161,{'method':method,'headers':{'X-Invoke-Source':PRODUCT_CONFIG[_0x598574(0x15b)],'X-User-AK':_0x2298a6,...headers},'signal':_0x4a0fbb[_0x598574(0xf9)]});if(!_0x1a75b6['ok']){let _0x279de2;try{const _0x10b3b7=await _0x1a75b6[_0x598574(0x127)]();_0x279de2=_0x10b3b7[_0x598574(0x16c)]||_0x10b3b7[_0x598574(0x102)]||_0x10b3b7['errorCode'];}catch{_0x279de2=await _0x1a75b6['text']()[_0x598574(0x11a)](()=>undefined);}throw CliErrors[_0x598574(0xfa)](_0x279de2||_0x598574(0x133)+_0x1a75b6[_0x598574(0xf4)],_0x598574(0x123)+_0x4df161);}return Buffer['from'](await _0x1a75b6[_0x598574(0xfe)]());}catch(_0x54bc07){if(_0x54bc07 instanceof Error&&_0x54bc07[_0x598574(0x128)]===_0x598574(0x16b))throw CliErrors[_0x598574(0xfa)](_0x598574(0xf2)+_0x4df161);throw _0x54bc07;}finally{clearTimeout(_0x226a83);}}async function apiFormRequest(_0x1b127e,_0xbdb99a,_0x57ed86={}){const _0x8ef2f0=a74_0x1d8d,{timeout:timeout=0x7530}=_0x57ed86,_0x25d7fa=_activeAK,_0x1d8dd5=getRuntimeDomain();if(!_0x25d7fa)throw CliErrors['authRequired'](_0x8ef2f0(0x118)+PRODUCT_CONFIG[_0x8ef2f0(0x109)]+'.');const _0x531c33=''+_0x1d8dd5+_0x1b127e,_0x37c1c0=new AbortController(),_0x5581e7=setTimeout(()=>_0x37c1c0[_0x8ef2f0(0x129)](),timeout);try{const _0x4d16ed=await fetch(_0x531c33,{'method':_0x8ef2f0(0x15d),'headers':{'X-Invoke-Source':PRODUCT_CONFIG[_0x8ef2f0(0x15b)],'X-User-AK':_0x25d7fa},'body':_0xbdb99a,'signal':_0x37c1c0['signal']});let _0x158770;try{_0x158770=await _0x4d16ed[_0x8ef2f0(0x127)]();}catch{throw CliErrors['apiError']('API\x20returned\x20non-JSON\x20response\x20(HTTP\x20'+_0x4d16ed[_0x8ef2f0(0xf4)]+')',_0x4d16ed[_0x8ef2f0(0xf4)]>=0x190?_0x8ef2f0(0x11c):undefined);}if(!_0x4d16ed['ok']||_0x158770[_0x8ef2f0(0x12f)]===![])throw CliErrors[_0x8ef2f0(0xfa)](_0x158770[_0x8ef2f0(0x16c)]||_0x158770[_0x8ef2f0(0x102)]||_0x8ef2f0(0x133)+_0x4d16ed[_0x8ef2f0(0xf4)],_0x158770[_0x8ef2f0(0x170)]?_0x8ef2f0(0x13d)+_0x158770['errorCode']:undefined);return _0x158770;}catch(_0x40db7b){if(_0x40db7b instanceof Error&&_0x40db7b[_0x8ef2f0(0x128)]===_0x8ef2f0(0x16b))throw CliErrors[_0x8ef2f0(0xfa)]('Request\x20timeout:\x20'+_0x531c33);throw _0x40db7b;}finally{clearTimeout(_0x5581e7);}}async function toolboxRequest(_0x5cb09a,_0x49dc27,_0x4e4b14={}){const _0x306492=a74_0x1d8d,{method:method='GET',headers:headers={},timeout:timeout=0x7530}=_0x4e4b14,_0x33d6ff=_activeAK;if(!_0x33d6ff)throw CliErrors[_0x306492(0x173)]('Configure\x20accessKey\x20in\x20'+PRODUCT_CONFIG[_0x306492(0x109)]+'.');const _0x2a42d9=getApiDomain()[_0x306492(0x149)](/\/$/,''),_0xe9334c=new URL(_0x5cb09a,_0x2a42d9+'/api/node-toolbox/');if(_0x49dc27)for(const [_0x2dd0dd,_0x47294d]of Object['entries'](_0x49dc27)){_0x47294d!==undefined&&_0x47294d!==null&&_0xe9334c[_0x306492(0x12b)]['set'](_0x2dd0dd,String(_0x47294d));}const _0x51a388=new AbortController(),_0x261839=setTimeout(()=>_0x51a388['abort'](),timeout);try{const _0x153174=await fetch(_0xe9334c,{'method':method,'headers':{'Content-Type':_0x306492(0x11d),'X-Invoke-Source':PRODUCT_CONFIG[_0x306492(0x15b)],'X-User-AK':_0x33d6ff,...headers},'signal':_0x51a388[_0x306492(0xf9)]});let _0x43adc2;try{_0x43adc2=await _0x153174['json']();}catch{throw CliErrors['apiError']('Toolbox\x20returned\x20non-JSON\x20response\x20(HTTP\x20'+_0x153174[_0x306492(0xf4)]+')',_0x153174[_0x306492(0xf4)]>=0x190?_0x306492(0x11c):undefined);}if(!_0x153174['ok']){const _0x26ee36=_0x43adc2&&typeof _0x43adc2===_0x306492(0x110)?_0x43adc2:{};throw CliErrors[_0x306492(0xfa)](_0x26ee36['errorMsg']||_0x26ee36[_0x306492(0x102)]||_0x306492(0xf3)+_0x153174['status'],_0x26ee36[_0x306492(0x170)]?'Toolbox\x20error\x20code:\x20'+_0x26ee36[_0x306492(0x170)]:undefined);}if(_0x43adc2&&typeof _0x43adc2===_0x306492(0x110)&&_0x306492(0x12f)in _0x43adc2&&typeof _0x43adc2['success']===_0x306492(0x159)){const _0x1dc462=_0x43adc2;if(!_0x1dc462[_0x306492(0x12f)])throw CliErrors['apiError'](_0x1dc462[_0x306492(0x16c)]||_0x1dc462[_0x306492(0x102)]||_0x306492(0x119),_0x1dc462[_0x306492(0x170)]?_0x306492(0x179)+_0x1dc462[_0x306492(0x170)]:undefined);return _0x1dc462[_0x306492(0x15a)];}return _0x43adc2;}catch(_0x55a619){if(_0x55a619 instanceof Error&&_0x55a619['name']==='AbortError')throw CliErrors[_0x306492(0xfa)](_0x306492(0xf2)+_0xe9334c[_0x306492(0xf8)]());throw _0x55a619;}finally{clearTimeout(_0x261839);}}async function skillHubJsonRequest(_0x4ef288,_0x4c28e={}){const _0x246cff=a74_0x1d8d,{method:method=_0x246cff(0x172),query:_0x12495d,body:_0x3f2b46,headers:headers={},timeout:timeout=0x7530,allowNotFound:allowNotFound=![]}=_0x4c28e,_0x4b6398=_activeAK;if(!_0x4b6398)throw CliErrors[_0x246cff(0x173)](_0x246cff(0x118)+PRODUCT_CONFIG[_0x246cff(0x109)]+'.');const _0x46ed8e=getSkillHubDomain()['replace'](/\/$/,''),_0x23d162=new URL(_0x4ef288,_0x46ed8e+'/');if(_0x12495d)for(const [_0x5e68fe,_0x1233a8]of Object[_0x246cff(0xfd)](_0x12495d)){_0x1233a8!==undefined&&_0x1233a8!==null&&_0x23d162['searchParams'][_0x246cff(0x14e)](_0x5e68fe,String(_0x1233a8));}const _0x1055fa=new AbortController(),_0x32e9c5=setTimeout(()=>_0x1055fa[_0x246cff(0x129)](),timeout);try{const _0xe28883=await fetch(_0x23d162['toString'](),{'method':method,'headers':{'Accept':_0x246cff(0x11d),'X-Invoke-Source':PRODUCT_CONFIG[_0x246cff(0x15b)],'X-User-AK':_0x4b6398,...headers},'body':_0x3f2b46,'signal':_0x1055fa[_0x246cff(0xf9)]});let _0xbf6f26;try{_0xbf6f26=await _0xe28883[_0x246cff(0x127)]();}catch{if(allowNotFound&&_0xe28883['status']===0x194)return undefined;throw CliErrors[_0x246cff(0xfa)](_0x246cff(0x14b)+_0xe28883[_0x246cff(0xf4)]+')',_0xe28883['status']>=0x190?_0x246cff(0x11c):undefined);}if(allowNotFound&&isSkillHubNotFoundResponse(_0xe28883[_0x246cff(0xf4)],_0xbf6f26))return undefined;const _0x3ab346=!_0xe28883['ok']||_0xbf6f26?.['success']===![]||typeof _0xbf6f26?.[_0x246cff(0x124)]==='number'&&_0xbf6f26['code']>=0x190;if(_0x3ab346)throw CliErrors[_0x246cff(0xfa)](_0xbf6f26?.[_0x246cff(0x16c)]||_0xbf6f26?.[_0x246cff(0x102)]||_0xbf6f26?.['msg']||_0x246cff(0x125)+_0xe28883['status'],_0xbf6f26?.[_0x246cff(0x170)]?_0x246cff(0x167)+_0xbf6f26[_0x246cff(0x170)]:undefined);return _0xbf6f26?.[_0x246cff(0x15a)]??_0xbf6f26;}catch(_0x23a61d){if(_0x23a61d instanceof Error&&_0x23a61d[_0x246cff(0x128)]===_0x246cff(0x16b))throw CliErrors[_0x246cff(0xfa)](_0x246cff(0xf2)+_0x23d162['toString']());throw _0x23a61d;}finally{clearTimeout(_0x32e9c5);}}function isSkillHubNotFoundResponse(_0x532962,_0x403d0f){const _0x3974cf=a74_0x1d8d;if(_0x532962===0x194||_0x403d0f?.[_0x3974cf(0x124)]===0x194)return!![];if(_0x532962!==0x190&&_0x403d0f?.[_0x3974cf(0x124)]!==0x190)return![];const _0x8b8efb=[_0x403d0f?.[_0x3974cf(0x115)],_0x403d0f?.[_0x3974cf(0x102)],_0x403d0f?.[_0x3974cf(0x16c)],_0x403d0f?.[_0x3974cf(0x103)]][_0x3974cf(0x141)](_0x7293b6=>typeof _0x7293b6===_0x3974cf(0x132))[_0x3974cf(0x101)]('\x20');return/skill not found\b/i[_0x3974cf(0x11f)](_0x8b8efb);}async function skillHubBinaryRequest(_0x47c625,_0xb91a3={}){const _0x13ad05=a74_0x1d8d,{query:_0x24ab08,headers:headers={},timeout:timeout=0x7530}=_0xb91a3,_0xf3db06=_activeAK;if(!_0xf3db06)throw CliErrors[_0x13ad05(0x173)]('Configure\x20accessKey\x20in\x20'+PRODUCT_CONFIG[_0x13ad05(0x109)]+'.');const _0x58e106=getSkillHubDomain()['replace'](/\/$/,''),_0x2675bf=new URL(_0x47c625,_0x58e106+'/');if(_0x24ab08)for(const [_0x1e4243,_0x4f7ec2]of Object['entries'](_0x24ab08)){_0x4f7ec2!==undefined&&_0x4f7ec2!==null&&_0x2675bf[_0x13ad05(0x12b)][_0x13ad05(0x14e)](_0x1e4243,String(_0x4f7ec2));}const _0x489615=new AbortController(),_0x5013c6=setTimeout(()=>_0x489615[_0x13ad05(0x129)](),timeout);try{const _0x44b4e1=await fetch(_0x2675bf[_0x13ad05(0xf8)](),{'method':'GET','headers':{'Accept':_0x13ad05(0x14f),'X-Invoke-Source':PRODUCT_CONFIG[_0x13ad05(0x15b)],'X-User-AK':_0xf3db06,...headers},'signal':_0x489615['signal']});if(!_0x44b4e1['ok']){let _0x2be1f3;try{const _0x574ff3=await _0x44b4e1[_0x13ad05(0x127)]();_0x2be1f3=_0x574ff3['errorMsg']||_0x574ff3[_0x13ad05(0x102)]||_0x574ff3[_0x13ad05(0x115)]||_0x574ff3[_0x13ad05(0x170)];}catch{_0x2be1f3=await _0x44b4e1[_0x13ad05(0x153)]()[_0x13ad05(0x11a)](()=>undefined);}throw CliErrors['apiError'](_0x2be1f3||_0x13ad05(0x125)+_0x44b4e1[_0x13ad05(0xf4)],_0x13ad05(0x123)+_0x2675bf[_0x13ad05(0xf8)]());}return Buffer[_0x13ad05(0x104)](await _0x44b4e1['arrayBuffer']());}catch(_0x2481b5){if(_0x2481b5 instanceof Error&&_0x2481b5[_0x13ad05(0x128)]==='AbortError')throw CliErrors[_0x13ad05(0xfa)]('Request\x20timeout:\x20'+_0x2675bf[_0x13ad05(0xf8)]());throw _0x2481b5;}finally{clearTimeout(_0x5013c6);}}export async function getBffScriptInfo(_0x49a909){const _0x1e448e=a74_0x1d8d,_0x212d2b=await apiRequest(_0x1e448e(0x12d)+_0x49a909);if(!_0x212d2b['data'])throw CliErrors[_0x1e448e(0x174)](_0x1e448e(0xfc)+_0x49a909);return _0x212d2b[_0x1e448e(0x15a)];}export async function getSqlQueryInfo(_0x1524b8,_0x159c59){const _0x3d4015=a74_0x1d8d,_0x260052=await apiRequest('/client/sql/query',{'method':_0x3d4015(0x15d),'body':{'appCode':_0x1524b8,'currentPage':0x1,'pageSize':0x1,'sqlCode':_0x159c59}}),_0x37dfcb=_0x260052[_0x3d4015(0x15a)],_0x2fd7e5=_0x37dfcb&&typeof _0x37dfcb===_0x3d4015(0x110)&&_0x3d4015(0x16d)in _0x37dfcb?_0x37dfcb[_0x3d4015(0x16d)]?.[0x0]:_0x37dfcb&&typeof _0x37dfcb===_0x3d4015(0x110)&&'sqlCode'in _0x37dfcb?_0x37dfcb:undefined;if(!_0x2fd7e5)throw CliErrors['validation']('SQL\x20query\x20not\x20found:\x20'+_0x159c59);return _0x2fd7e5;}function isRemoteAppItem(_0x320e05){const _0x3dceec=a74_0x1d8d;return!!_0x320e05&&typeof _0x320e05===_0x3dceec(0x110)&&typeof _0x320e05[_0x3dceec(0x16e)]==='string'&&typeof _0x320e05[_0x3dceec(0x11b)]===_0x3dceec(0x132);}function extractRemoteAppItems(_0x1fc033){const _0x24db78=a74_0x1d8d;if(Array[_0x24db78(0x13a)](_0x1fc033))return _0x1fc033[_0x24db78(0x141)](isRemoteAppItem);if(!_0x1fc033||typeof _0x1fc033!=='object')throw CliErrors[_0x24db78(0xfa)](_0x24db78(0x163));const _0x1ed638=_0x1fc033;if(Array[_0x24db78(0x13a)](_0x1ed638[_0x24db78(0x16d)]))return _0x1ed638['tableData'][_0x24db78(0x141)](isRemoteAppItem);if(_0x1ed638[_0x24db78(0x15a)]&&typeof _0x1ed638[_0x24db78(0x15a)]===_0x24db78(0x110)){const _0x2f3aa0=_0x1ed638[_0x24db78(0x15a)];if(Array[_0x24db78(0x13a)](_0x2f3aa0['tableData']))return _0x2f3aa0[_0x24db78(0x16d)][_0x24db78(0x141)](isRemoteAppItem);}throw CliErrors[_0x24db78(0xfa)]('Invalid\x20app\x20list\x20response:\x20missing\x20data.tableData.');}export async function getMyApps(){const _0x3d57a8=a74_0x1d8d,_0x46ac07=await apiRequest(_0x3d57a8(0x158));return extractRemoteAppItems(_0x46ac07[_0x3d57a8(0x15a)]);}export async function getLoginUserInfo(){const _0x52b2f4=a74_0x1d8d,_0x102c22=await apiRequest(_0x52b2f4(0x13f));if(!_0x102c22[_0x52b2f4(0x15a)]||typeof _0x102c22[_0x52b2f4(0x15a)]!=='object'||Array[_0x52b2f4(0x13a)](_0x102c22[_0x52b2f4(0x15a)]))throw CliErrors[_0x52b2f4(0xfa)](_0x52b2f4(0x164));return _0x102c22[_0x52b2f4(0x15a)];}export async function listDatasets(_0x574eb7,_0x1b71d4){const _0x178ea8=a74_0x1d8d,_0x13f24b=await apiRequest(_0x178ea8(0x152),{'method':_0x178ea8(0x15d),'body':{'appCode':_0x574eb7,..._0x1b71d4?.[_0x178ea8(0x124)]&&{'code':_0x1b71d4['code']},..._0x1b71d4?.['name']&&{'name':_0x1b71d4['name']}}});return extractList(_0x13f24b[_0x178ea8(0x15a)]);}function a74_0x4af0(){const _0x3ce680=['packageBase64','json','name','abort','2627766mrIOLC','searchParams','9PGYckC','/client/bff/query/','visibility','success','/api/cli/v1/skills/','resolvedVersion','string','API\x20error:\x20','skillCode','PRIVATE','/client/artifact/','company','Missing\x20Skill\x20package\x20payload.','NAMESPACE_ONLY','isArray','skillName','/client/artifact/create','API\x20error\x20code:\x20','7ZOhGRy','/client/user/loginUserInfo','undefined','filter','47334924ZUPdzp','/client/knowledge-base/search','topK','/update','trim','tags','/client/runtime-bff/personal/list?appCode=','replace','/client/queryFileUrl','SkillHub\x20returned\x20non-JSON\x20response\x20(HTTP\x20','content','warnings','set','application/octet-stream','namespace','Artifact\x20not\x20found:\x20id=','/client/dataset/list','text','/client/runtime-bff/personal/','base64','headlineVersion','toLowerCase','/client/app/my-apps','boolean','data','invokeSource','/client/uploadFile','POST','/client/artifact/list?','summary','append','resolvedSlug','/client/knowledge-base/personal/','Invalid\x20app\x20list\x20response:\x20expected\x20object\x20or\x20array.','Invalid\x20login\x20user\x20info\x20response:\x20expected\x20object.','displayName','235FhjHhZ','SkillHub\x20error\x20code:\x20','?appCode=','11qlumkb','/download','AbortError','errorMsg','tableData','appCode','download','errorCode','App\x20config\x20not\x20found:\x20key=','GET','authRequired','validation','version','/skills','favorite','18CDoDNk','Toolbox\x20error\x20code:\x20','70976GFppoS','/versions/','all','type','errors','scope','Request\x20timeout:\x20','Toolbox\x20API\x20error:\x20','status','182047xHTXbb','description','/publish/validate','toString','signal','apiError','query','BFF\x20script\x20not\x20found:\x20id=','entries','arrayBuffer','file','skill','join','message','error','from','artifactType','8213680rtmBzo','/client/ocr','personal','newConfigFileName','map','publishedVersion','items','markdown','slug','source','object','3363858umTdLu','values','application/zip','9326090QhpuWR','msg','valid','/api/v1/skills/','Configure\x20accessKey\x20in\x20','Toolbox\x20API\x20error','catch','appName','Check\x20your\x20credentials\x20and\x20try\x20again.','application/json','confirmWarnings','test','/client/knowledge-base/personal/list?appCode=','Knowledge-base\x20entry\x20not\x20found:\x20id=','effective','Download\x20failed:\x20','code','SkillHub\x20API\x20error:\x20'];a74_0x4af0=function(){return _0x3ce680;};return a74_0x4af0();}export async function getDatasetDetail(_0x31616d){const _0x502211=a74_0x1d8d,_0x251142=await apiRequest('/client/dataset/get-driven-data?code='+encodeURIComponent(_0x31616d));return _0x251142[_0x502211(0x15a)];}export async function getDatasetSdkUsageDoc(_0x5566ef,_0xa40b6d){const _0x43fa49=a74_0x1d8d,_0x1a057c=await toolboxRequest('api-doc-generator',{'datasetCode':_0x5566ef,'appCode':_0xa40b6d});return typeof _0x1a057c?.['markdown']===_0x43fa49(0x132)?_0x1a057c[_0x43fa49(0x10d)]:'';}export async function uploadRuntimeFile(_0xc1fdbf,_0x1b5ecc){const _0x4d5183=a74_0x1d8d,_0xf52c=await readFile(_0x1b5ecc),_0x4b334=new FormData();_0x4b334[_0x4d5183(0x160)]('appCode',_0xc1fdbf),_0x4b334[_0x4d5183(0x160)](_0x4d5183(0xff),new Blob([new Uint8Array(_0xf52c)]),basename(_0x1b5ecc));const _0x15e688=await apiFormRequest(_0x4d5183(0x15c),_0x4b334);return _0x15e688[_0x4d5183(0x15a)];}export async function queryRuntimeFileUrl(_0x28b3a1,_0x285cef={}){const _0x4a2dab=a74_0x1d8d,_0x18d28a=await apiRequest(_0x4a2dab(0x14a),{'method':_0x4a2dab(0x15d),'body':{'filePath':_0x28b3a1,'downloadFlag':_0x285cef[_0x4a2dab(0x16f)]??![]}});return _0x18d28a[_0x4a2dab(0x15a)];}export async function recognizeRuntimeOcr(_0x5da5df,_0x1fe68){const _0x35d818=a74_0x1d8d,_0x46bc4e=await apiRequest(_0x35d818(0x107),{'method':_0x35d818(0x15d),'body':{'appCode':_0x5da5df,'url':_0x1fe68['url'],'type':_0x1fe68[_0x35d818(0xef)]}});return _0x46bc4e['data'];}export async function getRuntimeAppConfigByKey(_0x170b1a,_0x265479){const _0x439758=a74_0x1d8d,_0x28c8b9=new URLSearchParams({'appCode':_0x170b1a,'key':_0x265479}),_0x3e8523=await apiRequest('/client/app-config/getByKey?'+_0x28c8b9[_0x439758(0xf8)]());if(!_0x3e8523[_0x439758(0x15a)])throw CliErrors[_0x439758(0x174)](_0x439758(0x171)+_0x265479);return _0x3e8523[_0x439758(0x15a)];}export async function listRuntimeArtifacts(_0x4441ee,_0x30cbfc){const _0x1d2617=a74_0x1d8d,_0x51a0af=new URLSearchParams({'appCode':_0x4441ee});if(_0x30cbfc?.[_0x1d2617(0x105)])_0x51a0af[_0x1d2617(0x14e)](_0x1d2617(0x105),_0x30cbfc[_0x1d2617(0x105)]);if(_0x30cbfc?.[_0x1d2617(0x10f)])_0x51a0af[_0x1d2617(0x14e)]('source',_0x30cbfc[_0x1d2617(0x10f)]);if(_0x30cbfc?.[_0x1d2617(0x177)]!==undefined)_0x51a0af[_0x1d2617(0x14e)]('favorite',String(_0x30cbfc[_0x1d2617(0x177)]));const _0x20c472=await apiRequest(_0x1d2617(0x15e)+_0x51a0af[_0x1d2617(0xf8)]());return Array[_0x1d2617(0x13a)](_0x20c472[_0x1d2617(0x15a)])?_0x20c472[_0x1d2617(0x15a)]:[];}export async function getRuntimeArtifact(_0x275506,_0x3e99de){const _0xc7176c=a74_0x1d8d,_0x1195ac=await apiRequest('/client/artifact/'+_0x275506+_0xc7176c(0x168)+encodeURIComponent(_0x3e99de));if(!_0x1195ac[_0xc7176c(0x15a)])throw CliErrors['validation'](_0xc7176c(0x151)+_0x275506);return _0x1195ac[_0xc7176c(0x15a)];}export async function createRuntimeArtifact(_0x44a63a,_0x2c416e){const _0x1b266f=a74_0x1d8d,_0xea60fa=await apiRequest(_0x1b266f(0x13c),{'method':'POST','body':{'appCode':_0x44a63a,..._0x2c416e}});return _0xea60fa['data'];}export async function updateRuntimeArtifact(_0x14ecce,_0x209600,_0x1d8e74){const _0x5b7f53=a74_0x1d8d,_0x42bc63=await apiRequest(_0x5b7f53(0x136)+_0x14ecce+_0x5b7f53(0x145),{'method':_0x5b7f53(0x15d),'body':{'appCode':_0x209600,..._0x1d8e74}});return _0x42bc63[_0x5b7f53(0x15a)];}export async function listPersonalBffs(_0x3876d0){const _0x4e8273=a74_0x1d8d,_0x47c96d=await apiRequest(_0x4e8273(0x148)+encodeURIComponent(_0x3876d0));return Array[_0x4e8273(0x13a)](_0x47c96d[_0x4e8273(0x15a)])?_0x47c96d['data']:[];}export async function getPersonalBff(_0x3f2686,_0x2f8112){const _0x271abe=a74_0x1d8d,_0xbdb357=await apiRequest(_0x271abe(0x154)+_0x3f2686+_0x271abe(0x168)+encodeURIComponent(_0x2f8112));if(!_0xbdb357[_0x271abe(0x15a)])throw CliErrors[_0x271abe(0x174)]('Personal\x20BFF\x20not\x20found:\x20id='+_0x3f2686);return _0xbdb357['data'];}export async function createPersonalBff(_0x43484b,_0x1717a3){const _0x4a1bdb=a74_0x1d8d,_0x17ba46=await apiRequest('/client/runtime-bff/personal/create',{'method':_0x4a1bdb(0x15d),'body':{'appCode':_0x43484b,..._0x1717a3}});return _0x17ba46[_0x4a1bdb(0x15a)];}export async function updatePersonalBff(_0xdbadf5,_0x306809,_0x2dadfe){const _0x55a345=a74_0x1d8d,_0x1b003f=await apiRequest('/client/runtime-bff/personal/'+_0xdbadf5+_0x55a345(0x145),{'method':'POST','body':{'appCode':_0x306809,..._0x2dadfe}});return _0x1b003f['data'];}export async function executePersonalBff(_0x4bd3f9,_0x571a3d,_0x54705b){const _0xa81ce5=a74_0x1d8d,_0x1437ea=await apiRequest(_0xa81ce5(0x154)+_0x4bd3f9+'/execute?appCode='+encodeURIComponent(_0x571a3d),{'method':_0xa81ce5(0x15d),'body':_0x54705b});return _0x1437ea[_0xa81ce5(0x15a)];}function a74_0x1d8d(_0x23891f,_0x4b4924){_0x23891f=_0x23891f-0xec;const _0x4af0ee=a74_0x4af0();let _0x1d8d9b=_0x4af0ee[_0x23891f];return _0x1d8d9b;}export async function listPersonalKnowledgeBaseItems(_0x20a354){const _0x4fd8e2=a74_0x1d8d,_0x1020e7=await apiRequest(_0x4fd8e2(0x120)+encodeURIComponent(_0x20a354));return Array[_0x4fd8e2(0x13a)](_0x1020e7[_0x4fd8e2(0x15a)])?_0x1020e7['data']:[];}export async function getPersonalKnowledgeBaseItem(_0x3efa33,_0x100d02){const _0x60cbe1=a74_0x1d8d,_0x36fdfb=await apiRequest(_0x60cbe1(0x162)+_0x3efa33+_0x60cbe1(0x168)+encodeURIComponent(_0x100d02));if(!_0x36fdfb[_0x60cbe1(0x15a)])throw CliErrors['validation'](_0x60cbe1(0x121)+_0x3efa33);return _0x36fdfb['data'];}export async function createPersonalKnowledgeBaseItem(_0x3d7d1b,_0x33ee29){const _0xc3d132=a74_0x1d8d,_0x37e7b9=await apiRequest('/client/knowledge-base/personal/create',{'method':_0xc3d132(0x15d),'body':{'appCode':_0x3d7d1b,..._0x33ee29}});return _0x37e7b9[_0xc3d132(0x15a)];}export async function updatePersonalKnowledgeBaseItem(_0x2baffb,_0x53a0ec,_0x29c49c){const _0x416319=a74_0x1d8d,_0x20f48e=await apiRequest(_0x416319(0x162)+_0x2baffb+_0x416319(0x145),{'method':_0x416319(0x15d),'body':{'appCode':_0x53a0ec,..._0x29c49c}});return _0x20f48e[_0x416319(0x15a)];}export async function searchKnowledgeBase(_0x3b8b02,_0x470735){const _0x1ed585=a74_0x1d8d,_0x446abb=await apiRequest(_0x1ed585(0x143),{'method':'POST','body':{'appCode':_0x3b8b02,'query':_0x470735[_0x1ed585(0xfb)],..._0x470735[_0x1ed585(0x144)]!==undefined?{'topK':_0x470735['topK']}:{}}});return Array['isArray'](_0x446abb[_0x1ed585(0x15a)])?_0x446abb[_0x1ed585(0x15a)]:[];}export async function getRuntimeSkillByCode(_0x4cf535,_0x28f140){const _0x562705=a74_0x1d8d,_0x4d3d43=await skillHubJsonRequest(_0x562705(0x117)+encodeURIComponent(_0x4cf535)+'/'+encodeURIComponent(_0x28f140),{'allowNotFound':!![]});return _0x4d3d43?skillHubRuntimeDetailToRuntimeSkill(_0x4d3d43):undefined;}export async function listRuntimeSkills(_0x38308e){const _0x2c455a=a74_0x1d8d,_0x1ecc85=await skillHubJsonRequest('/api/runtime/v1/namespaces/'+encodeURIComponent(_0x38308e[_0x2c455a(0x16e)])+_0x2c455a(0x176),{'query':{'page':0x0,'size':0xc8}});return normalizeSkillHubRuntimeListResponse(_0x38308e[_0x2c455a(0x16e)],_0x1ecc85,_0x38308e[_0x2c455a(0xf1)]??_0x2c455a(0xee),_0x38308e['code']);}export async function listPersonalRuntimeSkills(_0x12b2eb){const _0x23a8bc=a74_0x1d8d;return(await listRuntimeSkills({'appCode':_0x12b2eb,'scope':_0x23a8bc(0x108)}))['personal'];}export async function listCompanyRuntimeSkills(_0x51f6e4){const _0x17095b=a74_0x1d8d;return(await listRuntimeSkills({'appCode':_0x51f6e4,'scope':'company'}))[_0x17095b(0x137)];}export async function listVisibleRuntimeSkills(_0x3e4300){const _0x114e63=a74_0x1d8d;return(await listRuntimeSkills({'appCode':_0x3e4300,'scope':_0x114e63(0xee)}))['effective'];}export async function createPersonalRuntimeSkill(_0x1723b9,_0xd1c5db){const _0x53266e=a74_0x1d8d;return publishRuntimeSkill(_0x1723b9,_0xd1c5db,{'visibility':_0x53266e(0x135)});}export async function updatePersonalRuntimeSkill(_0x27688d,_0xb14f87,_0x546c40){const _0xf0180e=a74_0x1d8d;return publishRuntimeSkill(_0xb14f87,{..._0x546c40,'skillCode':_0x546c40[_0xf0180e(0x134)]??_0x27688d},{'visibility':_0xf0180e(0x135)});}export async function publishCompanyRuntimeSkill(_0x401c6d,_0x5c0369,_0x4464a0={}){const _0x43f60c=a74_0x1d8d;return publishRuntimeSkill(_0x401c6d,_0x5c0369,{'visibility':_0x43f60c(0x139),'confirmWarnings':_0x4464a0[_0x43f60c(0x11e)]});}export async function validateRuntimeSkillPublish(_0x152015,_0x567ef9,_0x3b03b3){const _0xce4d95=a74_0x1d8d,_0x3ee1b9=buildRuntimeSkillPublishForm(_0x567ef9,_0x3b03b3['visibility']),_0x1fe1c9=await skillHubJsonRequest('/api/cli/v1/skills/'+encodeURIComponent(_0x152015)+_0xce4d95(0xf7),{'method':_0xce4d95(0x15d),'body':_0x3ee1b9});return{'valid':_0x1fe1c9[_0xce4d95(0x116)]===!![],'errors':Array[_0xce4d95(0x13a)](_0x1fe1c9[_0xce4d95(0xf0)])?_0x1fe1c9[_0xce4d95(0xf0)]:[],'warnings':Array[_0xce4d95(0x13a)](_0x1fe1c9[_0xce4d95(0x14d)])?_0x1fe1c9[_0xce4d95(0x14d)]:[],'resolvedSlug':_0x1fe1c9[_0xce4d95(0x161)],'resolvedVersion':_0x1fe1c9[_0xce4d95(0x131)]};}export async function downloadRuntimeSkillPackage(_0x58e6a9,_0x1823cf,_0x3ee489,_0x39caf6){const _0x1d5a81=a74_0x1d8d;void _0x58e6a9;const _0x5e7cb6=_0x39caf6?_0x1d5a81(0x130)+encodeURIComponent(_0x3ee489)+'/'+encodeURIComponent(_0x1823cf)+_0x1d5a81(0xed)+encodeURIComponent(_0x39caf6)+_0x1d5a81(0x16a):_0x1d5a81(0x130)+encodeURIComponent(_0x3ee489)+'/'+encodeURIComponent(_0x1823cf)+'/download';return skillHubBinaryRequest(_0x5e7cb6);}async function publishRuntimeSkill(_0x1d7dc3,_0x2161e0,_0x4c0af0){const _0x2a65dd=a74_0x1d8d,_0x2332a2=buildRuntimeSkillPublishForm(_0x2161e0,_0x4c0af0['visibility']),_0xb6bd34=await skillHubJsonRequest(_0x2a65dd(0x130)+encodeURIComponent(_0x1d7dc3)+'/publish',{'method':'POST','query':{'confirmWarnings':_0x4c0af0[_0x2a65dd(0x11e)]===!![]?!![]:undefined},'body':_0x2332a2});return{'appCode':_0xb6bd34[_0x2a65dd(0x150)]??_0x1d7dc3,'skillCode':_0xb6bd34[_0x2a65dd(0x10e)]??_0x2161e0[_0x2a65dd(0x134)]??'','skillName':_0x2161e0[_0x2a65dd(0x13b)]??_0xb6bd34[_0x2a65dd(0x10e)]??_0x2161e0[_0x2a65dd(0x134)],'description':_0x2161e0[_0x2a65dd(0xf6)],'scope':skillHubVisibilityToScope(_0xb6bd34[_0x2a65dd(0x12e)]??_0x4c0af0[_0x2a65dd(0x12e)])??_0x2a65dd(0x108),'version':_0xb6bd34['version']??_0x2161e0['version'],'tags':_0x2161e0[_0x2a65dd(0x147)],'content':_0x2161e0[_0x2a65dd(0x14c)]};}function buildRuntimeSkillPublishForm(_0x248a3e,_0x5d8d9d){const _0x4eb295=a74_0x1d8d,_0x2b4f28=new FormData();return _0x2b4f28[_0x4eb295(0x14e)](_0x4eb295(0xff),runtimeSkillPackageFile(_0x248a3e)),_0x2b4f28[_0x4eb295(0x14e)]('visibility',_0x5d8d9d),_0x2b4f28;}function runtimeSkillPackageFile(_0x3ee0fd){const _0x1d2399=a74_0x1d8d;if(!_0x3ee0fd[_0x1d2399(0x126)])throw CliErrors[_0x1d2399(0x174)](_0x1d2399(0x138));const _0x59c1a4=Buffer[_0x1d2399(0x104)](_0x3ee0fd[_0x1d2399(0x126)],_0x1d2399(0x155)),_0x588c1d=new Blob([_0x59c1a4],{'type':'application/zip'}),_0x3a5101=(_0x3ee0fd[_0x1d2399(0x134)]||_0x1d2399(0x100))+'.zip';if(typeof File!==_0x1d2399(0x140))return new File([_0x588c1d],_0x3a5101,{'type':_0x1d2399(0x113)});return _0x588c1d;}function normalizeSkillHubRuntimeListResponse(_0x1c2f2a,_0x24228d,_0xb3210a,_0xa7ebdd){const _0x1193a7=a74_0x1d8d,_0x200eff=Array[_0x1193a7(0x13a)](_0x24228d)?_0x24228d:Array[_0x1193a7(0x13a)](_0x24228d?.[_0x1193a7(0x10c)])?_0x24228d['items']:[],_0x1fce0f=_0xa7ebdd?.['trim'](),_0x3c77c7=_0x200eff[_0x1193a7(0x141)](_0x238117=>!_0x1fce0f||_0x238117[_0x1193a7(0x10e)]===_0x1fce0f)[_0x1193a7(0x10a)](skillHubRuntimeItemToRuntimeSkill)['filter'](_0x2e75ac=>Boolean(_0x2e75ac)),_0x135ba0=_0x3c77c7[_0x1193a7(0x141)](_0x4c035d=>_0x4c035d[_0x1193a7(0xf1)]===_0x1193a7(0x108)),_0x5df30b=_0x3c77c7[_0x1193a7(0x141)](_0x581d0c=>_0x581d0c[_0x1193a7(0xf1)]===_0x1193a7(0x137));return{'appCode':_0x1c2f2a,'personal':_0xb3210a===_0x1193a7(0x137)?[]:_0x135ba0,'company':_0xb3210a==='personal'?[]:_0x5df30b,'effective':buildEffectiveRuntimeSkills(_0x135ba0,_0x5df30b,_0xb3210a)};}function skillHubRuntimeItemToRuntimeSkill(_0x2df50a){const _0x218487=a74_0x1d8d,_0x4bd86f=_0x2df50a['slug']?.[_0x218487(0x146)](),_0x4b607b=skillHubVisibilityToScope(_0x2df50a[_0x218487(0x12e)]);if(!_0x4bd86f||!_0x4b607b)return undefined;return{'id':_0x2df50a['id'],'appCode':_0x2df50a['namespace'],'skillCode':_0x4bd86f,'skillName':_0x2df50a[_0x218487(0x165)]??_0x4bd86f,'description':_0x2df50a['summary'],'scope':_0x4b607b,'version':skillHubRuntimeItemVersion(_0x2df50a),'status':_0x2df50a['status']};}function skillHubRuntimeDetailToRuntimeSkill(_0x2e0995){const _0x2d9c24=a74_0x1d8d,_0x4508be=_0x2e0995[_0x2d9c24(0x10e)]?.['trim']();if(!_0x4508be)return undefined;return{'id':_0x2e0995['id'],'appCode':_0x2e0995[_0x2d9c24(0x150)],'skillCode':_0x4508be,'skillName':_0x2e0995[_0x2d9c24(0x165)]??_0x4508be,'description':_0x2e0995[_0x2d9c24(0x15f)],'scope':skillHubVisibilityToScope(_0x2e0995[_0x2d9c24(0x12e)])??_0x2e0995[_0x2d9c24(0x12e)]?.[_0x2d9c24(0x157)](),'version':skillHubRuntimeItemVersion(_0x2e0995),'status':_0x2e0995[_0x2d9c24(0xf4)]};}function skillHubVisibilityToScope(_0x59ffbd){const _0x5e878d=a74_0x1d8d;if(_0x59ffbd===_0x5e878d(0x135))return _0x5e878d(0x108);if(_0x59ffbd===_0x5e878d(0x139))return _0x5e878d(0x137);return undefined;}function skillHubRuntimeItemVersion(_0x36e410){const _0x436f01=a74_0x1d8d;return _0x36e410[_0x436f01(0x10b)]?.['version']??_0x36e410[_0x436f01(0x156)]?.[_0x436f01(0x175)]??_0x36e410['ownerPreviewVersion']?.['version'];}function buildEffectiveRuntimeSkills(_0x34327e,_0x48a7b6,_0x251c4){const _0x4c5d30=a74_0x1d8d;if(_0x251c4==='personal')return _0x34327e;if(_0x251c4===_0x4c5d30(0x137))return _0x48a7b6;const _0x2c9e3b=new Map();for(const _0x5cfa0d of _0x48a7b6){_0x2c9e3b[_0x4c5d30(0x14e)](_0x5cfa0d[_0x4c5d30(0x134)],_0x5cfa0d);}for(const _0x551d40 of _0x34327e){_0x2c9e3b[_0x4c5d30(0x14e)](_0x551d40['skillCode'],_0x551d40);}return Array[_0x4c5d30(0x104)](_0x2c9e3b[_0x4c5d30(0x112)]());}function normalizeRuntimeSkillListResponse(_0x3978cd,_0x31f5a0){const _0x3bef17=a74_0x1d8d;if(Array['isArray'](_0x31f5a0)){const _0x1c74ae=_0x31f5a0[_0x3bef17(0x141)](_0x336d9e=>_0x336d9e[_0x3bef17(0xf1)]===_0x3bef17(0x108)),_0x56c1b8=_0x31f5a0[_0x3bef17(0x141)](_0xe72849=>_0xe72849[_0x3bef17(0xf1)]===_0x3bef17(0x137));return{'appCode':_0x3978cd,'personal':_0x1c74ae,'company':_0x56c1b8,'effective':[..._0x56c1b8,..._0x1c74ae]};}return{'appCode':_0x31f5a0?.[_0x3bef17(0x16e)]??_0x3978cd,'personal':Array['isArray'](_0x31f5a0?.[_0x3bef17(0x108)])?_0x31f5a0[_0x3bef17(0x108)]:[],'company':Array[_0x3bef17(0x13a)](_0x31f5a0?.['company'])?_0x31f5a0[_0x3bef17(0x137)]:[],'effective':Array[_0x3bef17(0x13a)](_0x31f5a0?.[_0x3bef17(0x122)])?_0x31f5a0[_0x3bef17(0x122)]:[]};}
|
|
1
|
+
(function(_0x1efa4f,_0x5db400){const _0x35e074=a74_0x1964,_0x17597c=_0x1efa4f();while(!![]){try{const _0x477087=-parseInt(_0x35e074(0x19b))/0x1*(-parseInt(_0x35e074(0x136))/0x2)+-parseInt(_0x35e074(0x154))/0x3+-parseInt(_0x35e074(0x138))/0x4+parseInt(_0x35e074(0x186))/0x5*(parseInt(_0x35e074(0x16f))/0x6)+parseInt(_0x35e074(0x152))/0x7+-parseInt(_0x35e074(0x190))/0x8+-parseInt(_0x35e074(0x140))/0x9*(-parseInt(_0x35e074(0x16d))/0xa);if(_0x477087===_0x5db400)break;else _0x17597c['push'](_0x17597c['shift']());}catch(_0x1121d3){_0x17597c['push'](_0x17597c['shift']());}}}(a74_0x440c,0x7b9c6));import{readFile}from'node:fs/promises';import{basename}from'node:path';import{getApiDomain,getRuntimeDomain,getSkillHubDomain}from'../constant/domain.js';import{PRODUCT_CONFIG}from'../constant/product.js';import{CliErrors}from'../errors.js';import{extractList}from'../framework/response.js';let _activeAK;export function setActiveAK(_0x1e90d7){_activeAK=_0x1e90d7||undefined;}export function clearActiveAK(){_activeAK=undefined;}async function apiRequest(_0x1019e6,_0x499895={}){const _0x242fed=a74_0x1964,{method:method=_0x242fed(0x191),body:_0x5a76fe,headers:headers={},timeout:timeout=0x7530}=_0x499895,_0x64e5ce=_activeAK,_0xa61aa0=getRuntimeDomain();if(!_0x64e5ce)throw CliErrors[_0x242fed(0x12c)](_0x242fed(0x197)+PRODUCT_CONFIG[_0x242fed(0x135)]+'.');const _0x528310=''+_0xa61aa0+_0x1019e6,_0x4dfdb3={'X-User-AK':_0x64e5ce},_0x55fc10=new AbortController(),_0x4bbca3=setTimeout(()=>_0x55fc10[_0x242fed(0x15b)](),timeout);try{const _0x4d07c0=await fetch(_0x528310,{'method':method,'headers':{'Content-Type':'application/json','X-Invoke-Source':PRODUCT_CONFIG[_0x242fed(0x175)],..._0x4dfdb3,...headers},'body':_0x5a76fe?JSON[_0x242fed(0x164)](_0x5a76fe):undefined,'signal':_0x55fc10[_0x242fed(0x13b)]});let _0x37f1fd;try{_0x37f1fd=await _0x4d07c0[_0x242fed(0x128)]();}catch{throw CliErrors[_0x242fed(0x16c)](_0x242fed(0x14f)+_0x4d07c0[_0x242fed(0x163)]+')',_0x4d07c0[_0x242fed(0x163)]>=0x190?_0x242fed(0x14b):undefined);}if(!_0x4d07c0['ok']||_0x37f1fd[_0x242fed(0x177)]===![])throw CliErrors[_0x242fed(0x16c)](_0x37f1fd[_0x242fed(0x124)]||_0x37f1fd['message']||_0x242fed(0x161)+_0x4d07c0[_0x242fed(0x163)],_0x37f1fd[_0x242fed(0x159)]?_0x242fed(0x178)+_0x37f1fd[_0x242fed(0x159)]:undefined);return _0x37f1fd;}catch(_0x127d2d){if(_0x127d2d instanceof Error&&_0x127d2d[_0x242fed(0x18a)]===_0x242fed(0x198))throw CliErrors['apiError'](_0x242fed(0x194)+_0x528310);throw _0x127d2d;}finally{clearTimeout(_0x4bbca3);}}async function apiBinaryRequest(_0x44e9d9,_0x3e3585={}){const _0x2379b6=a74_0x1964,{method:method=_0x2379b6(0x191),headers:headers={},timeout:timeout=0x7530}=_0x3e3585,_0x1faf58=_activeAK,_0x41e890=getRuntimeDomain();if(!_0x1faf58)throw CliErrors[_0x2379b6(0x12c)]('Configure\x20accessKey\x20in\x20'+PRODUCT_CONFIG[_0x2379b6(0x135)]+'.');const _0x48878b=''+_0x41e890+_0x44e9d9,_0x1bc691=new AbortController(),_0x1bfbae=setTimeout(()=>_0x1bc691[_0x2379b6(0x15b)](),timeout);try{const _0x18cb1e=await fetch(_0x48878b,{'method':method,'headers':{'X-Invoke-Source':PRODUCT_CONFIG[_0x2379b6(0x175)],'X-User-AK':_0x1faf58,...headers},'signal':_0x1bc691['signal']});if(!_0x18cb1e['ok']){let _0x8df32c;try{const _0x54c231=await _0x18cb1e[_0x2379b6(0x128)]();_0x8df32c=_0x54c231[_0x2379b6(0x124)]||_0x54c231[_0x2379b6(0x126)]||_0x54c231[_0x2379b6(0x159)];}catch{_0x8df32c=await _0x18cb1e[_0x2379b6(0x174)]()['catch'](()=>undefined);}throw CliErrors['apiError'](_0x8df32c||_0x2379b6(0x161)+_0x18cb1e[_0x2379b6(0x163)],_0x2379b6(0x17e)+_0x48878b);}return Buffer[_0x2379b6(0x14d)](await _0x18cb1e[_0x2379b6(0x16b)]());}catch(_0x1afe79){if(_0x1afe79 instanceof Error&&_0x1afe79[_0x2379b6(0x18a)]===_0x2379b6(0x198))throw CliErrors[_0x2379b6(0x16c)](_0x2379b6(0x194)+_0x48878b);throw _0x1afe79;}finally{clearTimeout(_0x1bfbae);}}async function apiFormRequest(_0x1e2315,_0x5ed4f9,_0x40ca3c={}){const _0x2c5bcb=a74_0x1964,{timeout:timeout=0x7530}=_0x40ca3c,_0x2b8331=_activeAK,_0x4bea7c=getRuntimeDomain();if(!_0x2b8331)throw CliErrors['authRequired'](_0x2c5bcb(0x197)+PRODUCT_CONFIG['newConfigFileName']+'.');const _0x445bc4=''+_0x4bea7c+_0x1e2315,_0xf56227=new AbortController(),_0x562af7=setTimeout(()=>_0xf56227[_0x2c5bcb(0x15b)](),timeout);try{const _0x3d879b=await fetch(_0x445bc4,{'method':_0x2c5bcb(0x149),'headers':{'X-Invoke-Source':PRODUCT_CONFIG[_0x2c5bcb(0x175)],'X-User-AK':_0x2b8331},'body':_0x5ed4f9,'signal':_0xf56227['signal']});let _0x3d0771;try{_0x3d0771=await _0x3d879b['json']();}catch{throw CliErrors[_0x2c5bcb(0x16c)]('API\x20returned\x20non-JSON\x20response\x20(HTTP\x20'+_0x3d879b[_0x2c5bcb(0x163)]+')',_0x3d879b[_0x2c5bcb(0x163)]>=0x190?_0x2c5bcb(0x14b):undefined);}if(!_0x3d879b['ok']||_0x3d0771[_0x2c5bcb(0x177)]===![])throw CliErrors['apiError'](_0x3d0771[_0x2c5bcb(0x124)]||_0x3d0771['message']||_0x2c5bcb(0x161)+_0x3d879b[_0x2c5bcb(0x163)],_0x3d0771['errorCode']?_0x2c5bcb(0x178)+_0x3d0771['errorCode']:undefined);return _0x3d0771;}catch(_0x4a90ba){if(_0x4a90ba instanceof Error&&_0x4a90ba[_0x2c5bcb(0x18a)]===_0x2c5bcb(0x198))throw CliErrors[_0x2c5bcb(0x16c)]('Request\x20timeout:\x20'+_0x445bc4);throw _0x4a90ba;}finally{clearTimeout(_0x562af7);}}async function toolboxRequest(_0x47f585,_0x5ead2a,_0x30929c={}){const _0x3f832e=a74_0x1964,{method:method=_0x3f832e(0x191),headers:headers={},timeout:timeout=0x7530}=_0x30929c,_0x3c9101=_activeAK;if(!_0x3c9101)throw CliErrors[_0x3f832e(0x12c)](_0x3f832e(0x197)+PRODUCT_CONFIG['newConfigFileName']+'.');const _0x2da5d5=getApiDomain()['replace'](/\/$/,''),_0xf12a02=new URL(_0x47f585,_0x2da5d5+'/api/node-toolbox/');if(_0x5ead2a)for(const [_0x154e9f,_0xc26ba1]of Object[_0x3f832e(0x15a)](_0x5ead2a)){_0xc26ba1!==undefined&&_0xc26ba1!==null&&_0xf12a02[_0x3f832e(0x14a)][_0x3f832e(0x160)](_0x154e9f,String(_0xc26ba1));}const _0x1e0895=new AbortController(),_0xe7995d=setTimeout(()=>_0x1e0895[_0x3f832e(0x15b)](),timeout);try{const _0x7c10a7=await fetch(_0xf12a02,{'method':method,'headers':{'Content-Type':_0x3f832e(0x181),'X-Invoke-Source':PRODUCT_CONFIG[_0x3f832e(0x175)],'X-User-AK':_0x3c9101,...headers},'signal':_0x1e0895[_0x3f832e(0x13b)]});let _0x563adb;try{_0x563adb=await _0x7c10a7[_0x3f832e(0x128)]();}catch{throw CliErrors['apiError']('Toolbox\x20returned\x20non-JSON\x20response\x20(HTTP\x20'+_0x7c10a7[_0x3f832e(0x163)]+')',_0x7c10a7[_0x3f832e(0x163)]>=0x190?_0x3f832e(0x14b):undefined);}if(!_0x7c10a7['ok']){const _0xe456f0=_0x563adb&&typeof _0x563adb===_0x3f832e(0x158)?_0x563adb:{};throw CliErrors[_0x3f832e(0x16c)](_0xe456f0[_0x3f832e(0x124)]||_0xe456f0[_0x3f832e(0x126)]||'Toolbox\x20API\x20error:\x20'+_0x7c10a7['status'],_0xe456f0[_0x3f832e(0x159)]?_0x3f832e(0x172)+_0xe456f0[_0x3f832e(0x159)]:undefined);}if(_0x563adb&&typeof _0x563adb==='object'&&_0x3f832e(0x177)in _0x563adb&&typeof _0x563adb[_0x3f832e(0x177)]===_0x3f832e(0x189)){const _0x15d33b=_0x563adb;if(!_0x15d33b['success'])throw CliErrors[_0x3f832e(0x16c)](_0x15d33b[_0x3f832e(0x124)]||_0x15d33b[_0x3f832e(0x126)]||'Toolbox\x20API\x20error',_0x15d33b[_0x3f832e(0x159)]?_0x3f832e(0x172)+_0x15d33b[_0x3f832e(0x159)]:undefined);return _0x15d33b['data'];}return _0x563adb;}catch(_0x326c69){if(_0x326c69 instanceof Error&&_0x326c69[_0x3f832e(0x18a)]===_0x3f832e(0x198))throw CliErrors[_0x3f832e(0x16c)](_0x3f832e(0x194)+_0xf12a02['toString']());throw _0x326c69;}finally{clearTimeout(_0xe7995d);}}async function skillHubJsonRequest(_0x1851bb,_0x5ef288={}){const _0x35f48f=a74_0x1964,{method:method=_0x35f48f(0x191),query:_0x327671,body:_0x1c6fab,headers:headers={},timeout:timeout=0x7530,allowNotFound:allowNotFound=![]}=_0x5ef288,_0x502f4c=_activeAK;if(!_0x502f4c)throw CliErrors[_0x35f48f(0x12c)](_0x35f48f(0x197)+PRODUCT_CONFIG[_0x35f48f(0x135)]+'.');const _0x757934=getSkillHubDomain()['replace'](/\/$/,''),_0x29cd42=new URL(_0x1851bb,_0x757934+'/');if(_0x327671)for(const [_0x445cb4,_0x6622df]of Object[_0x35f48f(0x15a)](_0x327671)){_0x6622df!==undefined&&_0x6622df!==null&&_0x29cd42[_0x35f48f(0x14a)]['set'](_0x445cb4,String(_0x6622df));}const _0x3bf227=new AbortController(),_0x42cb94=setTimeout(()=>_0x3bf227[_0x35f48f(0x15b)](),timeout);try{const _0x1dd259=await fetch(_0x29cd42[_0x35f48f(0x150)](),{'method':method,'headers':{'Accept':_0x35f48f(0x181),'X-Invoke-Source':PRODUCT_CONFIG['invokeSource'],'X-User-AK':_0x502f4c,...headers},'body':_0x1c6fab,'signal':_0x3bf227[_0x35f48f(0x13b)]});let _0x19828e;try{_0x19828e=await _0x1dd259[_0x35f48f(0x128)]();}catch{if(allowNotFound&&_0x1dd259[_0x35f48f(0x163)]===0x194)return undefined;throw CliErrors['apiError'](_0x35f48f(0x157)+_0x1dd259[_0x35f48f(0x163)]+')',_0x1dd259[_0x35f48f(0x163)]>=0x190?_0x35f48f(0x14b):undefined);}if(allowNotFound&&isSkillHubNotFoundResponse(_0x1dd259['status'],_0x19828e))return undefined;const _0x3c0b26=!_0x1dd259['ok']||_0x19828e?.['success']===![]||typeof _0x19828e?.[_0x35f48f(0x153)]===_0x35f48f(0x156)&&_0x19828e['code']>=0x190;if(_0x3c0b26)throw CliErrors[_0x35f48f(0x16c)](_0x19828e?.[_0x35f48f(0x124)]||_0x19828e?.[_0x35f48f(0x126)]||_0x19828e?.[_0x35f48f(0x18b)]||_0x35f48f(0x13d)+_0x1dd259['status'],_0x19828e?.[_0x35f48f(0x159)]?_0x35f48f(0x173)+_0x19828e['errorCode']:undefined);return _0x19828e?.[_0x35f48f(0x131)]??_0x19828e;}catch(_0x170231){if(_0x170231 instanceof Error&&_0x170231[_0x35f48f(0x18a)]===_0x35f48f(0x198))throw CliErrors['apiError'](_0x35f48f(0x194)+_0x29cd42[_0x35f48f(0x150)]());throw _0x170231;}finally{clearTimeout(_0x42cb94);}}function isSkillHubNotFoundResponse(_0x5790e3,_0x1e3b5b){const _0x38dcb5=a74_0x1964;if(_0x5790e3===0x194||_0x1e3b5b?.[_0x38dcb5(0x153)]===0x194)return!![];if(_0x5790e3!==0x190&&_0x1e3b5b?.[_0x38dcb5(0x153)]!==0x190)return![];const _0x5e5e0a=[_0x1e3b5b?.['msg'],_0x1e3b5b?.[_0x38dcb5(0x126)],_0x1e3b5b?.[_0x38dcb5(0x124)],_0x1e3b5b?.['error']][_0x38dcb5(0x195)](_0x1ab29d=>typeof _0x1ab29d===_0x38dcb5(0x1a2))[_0x38dcb5(0x16e)]('\x20');return/skill not found\b/i[_0x38dcb5(0x176)](_0x5e5e0a);}async function skillHubBinaryRequest(_0x3c7ed8,_0x8ba54={}){const _0x527cdf=a74_0x1964,{query:_0x36ee18,headers:headers={},timeout:timeout=0x7530}=_0x8ba54,_0x177f6d=_activeAK;if(!_0x177f6d)throw CliErrors['authRequired'](_0x527cdf(0x197)+PRODUCT_CONFIG[_0x527cdf(0x135)]+'.');const _0x590306=getSkillHubDomain()[_0x527cdf(0x171)](/\/$/,''),_0x2133c3=new URL(_0x3c7ed8,_0x590306+'/');if(_0x36ee18)for(const [_0x535ced,_0x43b022]of Object[_0x527cdf(0x15a)](_0x36ee18)){_0x43b022!==undefined&&_0x43b022!==null&&_0x2133c3['searchParams'][_0x527cdf(0x160)](_0x535ced,String(_0x43b022));}const _0x3432c3=new AbortController(),_0x1d4a20=setTimeout(()=>_0x3432c3[_0x527cdf(0x15b)](),timeout);try{const _0x4cf8d8=await fetch(_0x2133c3['toString'](),{'method':_0x527cdf(0x191),'headers':{'Accept':_0x527cdf(0x12a),'X-Invoke-Source':PRODUCT_CONFIG[_0x527cdf(0x175)],'X-User-AK':_0x177f6d,...headers},'signal':_0x3432c3[_0x527cdf(0x13b)]});if(!_0x4cf8d8['ok']){let _0x4a31f7;try{const _0x39a5b7=await _0x4cf8d8['json']();_0x4a31f7=_0x39a5b7[_0x527cdf(0x124)]||_0x39a5b7[_0x527cdf(0x126)]||_0x39a5b7[_0x527cdf(0x18b)]||_0x39a5b7['errorCode'];}catch{_0x4a31f7=await _0x4cf8d8['text']()['catch'](()=>undefined);}throw CliErrors['apiError'](_0x4a31f7||_0x527cdf(0x13d)+_0x4cf8d8[_0x527cdf(0x163)],_0x527cdf(0x17e)+_0x2133c3[_0x527cdf(0x150)]());}return Buffer[_0x527cdf(0x14d)](await _0x4cf8d8['arrayBuffer']());}catch(_0x493d84){if(_0x493d84 instanceof Error&&_0x493d84[_0x527cdf(0x18a)]===_0x527cdf(0x198))throw CliErrors[_0x527cdf(0x16c)](_0x527cdf(0x194)+_0x2133c3['toString']());throw _0x493d84;}finally{clearTimeout(_0x1d4a20);}}export async function getBffScriptInfo(_0x30d07d){const _0x55ece2=a74_0x1964,_0xbfab3=await apiRequest('/client/bff/query/'+_0x30d07d);if(!_0xbfab3[_0x55ece2(0x131)])throw CliErrors[_0x55ece2(0x143)](_0x55ece2(0x165)+_0x30d07d);return _0xbfab3[_0x55ece2(0x131)];}export async function getSqlQueryInfo(_0x20158c,_0x1bee51){const _0x53a002=a74_0x1964,_0x420da0=await apiRequest(_0x53a002(0x17a),{'method':_0x53a002(0x149),'body':{'appCode':_0x20158c,'currentPage':0x1,'pageSize':0x1,'sqlCode':_0x1bee51}}),_0x4fd2ca=_0x420da0[_0x53a002(0x131)],_0x28a13e=_0x4fd2ca&&typeof _0x4fd2ca==='object'&&_0x53a002(0x134)in _0x4fd2ca?_0x4fd2ca['tableData']?.[0x0]:_0x4fd2ca&&typeof _0x4fd2ca===_0x53a002(0x158)&&_0x53a002(0x148)in _0x4fd2ca?_0x4fd2ca:undefined;if(!_0x28a13e)throw CliErrors[_0x53a002(0x143)](_0x53a002(0x18c)+_0x1bee51);return _0x28a13e;}function isRemoteAppItem(_0x42c6f9){const _0x3b4177=a74_0x1964;return!!_0x42c6f9&&typeof _0x42c6f9===_0x3b4177(0x158)&&typeof _0x42c6f9[_0x3b4177(0x11e)]===_0x3b4177(0x1a2)&&typeof _0x42c6f9[_0x3b4177(0x188)]===_0x3b4177(0x1a2);}function extractRemoteAppItems(_0x520123){const _0x229c0b=a74_0x1964;if(Array[_0x229c0b(0x16a)](_0x520123))return _0x520123['filter'](isRemoteAppItem);if(!_0x520123||typeof _0x520123!==_0x229c0b(0x158))throw CliErrors[_0x229c0b(0x16c)](_0x229c0b(0x1a1));const _0x3cee0b=_0x520123;if(Array['isArray'](_0x3cee0b[_0x229c0b(0x134)]))return _0x3cee0b[_0x229c0b(0x134)][_0x229c0b(0x195)](isRemoteAppItem);if(_0x3cee0b[_0x229c0b(0x131)]&&typeof _0x3cee0b[_0x229c0b(0x131)]===_0x229c0b(0x158)){const _0x4c5bde=_0x3cee0b[_0x229c0b(0x131)];if(Array[_0x229c0b(0x16a)](_0x4c5bde[_0x229c0b(0x134)]))return _0x4c5bde[_0x229c0b(0x134)]['filter'](isRemoteAppItem);}throw CliErrors[_0x229c0b(0x16c)](_0x229c0b(0x11d));}export async function getMyApps(){const _0x389644=a74_0x1964,_0x43f2d6=await apiRequest('/client/app/my-apps');return extractRemoteAppItems(_0x43f2d6[_0x389644(0x131)]);}export async function getLoginUserInfo(){const _0x191bcc=a74_0x1964,_0x5abb23=await apiRequest(_0x191bcc(0x151));if(!_0x5abb23[_0x191bcc(0x131)]||typeof _0x5abb23[_0x191bcc(0x131)]!==_0x191bcc(0x158)||Array[_0x191bcc(0x16a)](_0x5abb23[_0x191bcc(0x131)]))throw CliErrors[_0x191bcc(0x16c)](_0x191bcc(0x119));return _0x5abb23[_0x191bcc(0x131)];}export async function listDatasets(_0x2982ea,_0x5b4140){const _0x19fedc=a74_0x1964,_0x13c6ea=await apiRequest(_0x19fedc(0x183),{'method':_0x19fedc(0x149),'body':{'appCode':_0x2982ea,..._0x5b4140?.[_0x19fedc(0x153)]&&{'code':_0x5b4140[_0x19fedc(0x153)]},..._0x5b4140?.['name']&&{'name':_0x5b4140['name']}}});return extractList(_0x13c6ea[_0x19fedc(0x131)]);}export async function getDatasetDetail(_0x53a2ba){const _0x5e9f72=a74_0x1964,_0x1b6ad8=await apiRequest(_0x5e9f72(0x196)+encodeURIComponent(_0x53a2ba));return _0x1b6ad8[_0x5e9f72(0x131)];}export async function getDatasetSdkUsageDoc(_0x3bda2c,_0x33c89){const _0x21857a=a74_0x1964,_0x54a345=await toolboxRequest(_0x21857a(0x122),{'datasetCode':_0x3bda2c,'appCode':_0x33c89});return typeof _0x54a345?.[_0x21857a(0x18e)]===_0x21857a(0x1a2)?_0x54a345[_0x21857a(0x18e)]:'';}export async function uploadRuntimeFile(_0x434c03,_0x6c03c0){const _0xc039ea=a74_0x1964,_0x4e0bce=await readFile(_0x6c03c0),_0x5d8922=new FormData();_0x5d8922[_0xc039ea(0x167)](_0xc039ea(0x11e),_0x434c03),_0x5d8922[_0xc039ea(0x167)](_0xc039ea(0x187),new Blob([new Uint8Array(_0x4e0bce)]),basename(_0x6c03c0));const _0x476a99=await apiFormRequest(_0xc039ea(0x166),_0x5d8922);return _0x476a99['data'];}export async function queryRuntimeFileUrl(_0x498ca2,_0x20749a={}){const _0x221b5e=a74_0x1964,_0x114e41=await apiRequest('/client/queryFileUrl',{'method':'POST','body':{'filePath':_0x498ca2,'downloadFlag':_0x20749a[_0x221b5e(0x142)]??![]}});return _0x114e41[_0x221b5e(0x131)];}export async function recognizeRuntimeOcr(_0x1927d,_0x3c60c7){const _0x53f408=a74_0x1964,_0x235f7b=await apiRequest('/client/ocr',{'method':_0x53f408(0x149),'body':{'appCode':_0x1927d,'url':_0x3c60c7[_0x53f408(0x17b)],'type':_0x3c60c7['type']}});return _0x235f7b[_0x53f408(0x131)];}export async function getRuntimeAppConfigByKey(_0x32e0eb,_0x1ddaea){const _0x976726=a74_0x1964,_0x580242=new URLSearchParams({'appCode':_0x32e0eb,'key':_0x1ddaea}),_0x9c32c8=await apiRequest(_0x976726(0x121)+_0x580242['toString']());if(!_0x9c32c8[_0x976726(0x131)])throw CliErrors[_0x976726(0x143)]('App\x20config\x20not\x20found:\x20key='+_0x1ddaea);return _0x9c32c8[_0x976726(0x131)];}export async function listRuntimeArtifacts(_0x5cec5e,_0xa38bd3){const _0x22aecb=a74_0x1964,_0x58c674=new URLSearchParams({'appCode':_0x5cec5e});if(_0xa38bd3?.[_0x22aecb(0x123)])_0x58c674[_0x22aecb(0x160)](_0x22aecb(0x123),_0xa38bd3[_0x22aecb(0x123)]);if(_0xa38bd3?.[_0x22aecb(0x11b)])_0x58c674[_0x22aecb(0x160)]('source',_0xa38bd3[_0x22aecb(0x11b)]);if(_0xa38bd3?.[_0x22aecb(0x19c)]!==undefined)_0x58c674[_0x22aecb(0x160)](_0x22aecb(0x19c),String(_0xa38bd3['favorite']));const _0x31be82=await apiRequest(_0x22aecb(0x14c)+_0x58c674['toString']());return Array[_0x22aecb(0x16a)](_0x31be82[_0x22aecb(0x131)])?_0x31be82[_0x22aecb(0x131)]:[];}export async function getRuntimeArtifact(_0xb7e00,_0x121e92){const _0x3721e4=a74_0x1964,_0x4c50a4=await apiRequest('/client/artifact/'+_0xb7e00+_0x3721e4(0x15f)+encodeURIComponent(_0x121e92));if(!_0x4c50a4[_0x3721e4(0x131)])throw CliErrors['validation']('Artifact\x20not\x20found:\x20id='+_0xb7e00);return _0x4c50a4[_0x3721e4(0x131)];}function a74_0x1964(_0x20b1c8,_0x4c7b66){_0x20b1c8=_0x20b1c8-0x119;const _0x440c53=a74_0x440c();let _0x1964c3=_0x440c53[_0x20b1c8];return _0x1964c3;}export async function createRuntimeArtifact(_0x375977,_0x497a78){const _0x19e83e=a74_0x1964,_0x8e5278=await apiRequest(_0x19e83e(0x15d),{'method':_0x19e83e(0x149),'body':{'appCode':_0x375977,..._0x497a78}});return _0x8e5278[_0x19e83e(0x131)];}export async function updateRuntimeArtifact(_0xf6f0c6,_0x522b6c,_0x17a723){const _0x3eaa4a=a74_0x1964,_0x48ba0b=await apiRequest(_0x3eaa4a(0x184)+_0xf6f0c6+'/update',{'method':'POST','body':{'appCode':_0x522b6c,..._0x17a723}});return _0x48ba0b[_0x3eaa4a(0x131)];}export async function listPersonalBffs(_0xa0603c){const _0x3e2957=a74_0x1964,_0x377d88=await apiRequest(_0x3e2957(0x18d)+encodeURIComponent(_0xa0603c));return Array[_0x3e2957(0x16a)](_0x377d88['data'])?_0x377d88['data']:[];}export async function getPersonalBff(_0x3fe333,_0x36ebb6){const _0x196763=a74_0x1964,_0xeb68bb=await apiRequest(_0x196763(0x11f)+_0x3fe333+_0x196763(0x15f)+encodeURIComponent(_0x36ebb6));if(!_0xeb68bb[_0x196763(0x131)])throw CliErrors[_0x196763(0x143)](_0x196763(0x12e)+_0x3fe333);return _0xeb68bb[_0x196763(0x131)];}export async function createPersonalBff(_0x181a12,_0x3ad804){const _0x473e2c=a74_0x1964,_0x344d0a=await apiRequest(_0x473e2c(0x18f),{'method':_0x473e2c(0x149),'body':{'appCode':_0x181a12,..._0x3ad804}});return _0x344d0a[_0x473e2c(0x131)];}export async function updatePersonalBff(_0x1fc776,_0x2b9f10,_0x195b1c){const _0xef0693=a74_0x1964,_0x254aae=await apiRequest(_0xef0693(0x11f)+_0x1fc776+'/update',{'method':_0xef0693(0x149),'body':{'appCode':_0x2b9f10,..._0x195b1c}});return _0x254aae['data'];}export async function executePersonalBff(_0x609e2a,_0x1fff39,_0x1f2eda){const _0x50f9d5=a74_0x1964,_0x26862c=await apiRequest(_0x50f9d5(0x11f)+_0x609e2a+'/execute?appCode='+encodeURIComponent(_0x1fff39),{'method':_0x50f9d5(0x149),'body':_0x1f2eda});return _0x26862c[_0x50f9d5(0x131)];}export async function listPersonalKnowledgeBaseItems(_0x334b36){const _0x29242b=a74_0x1964,_0xcb4a6e=await apiRequest(_0x29242b(0x139)+encodeURIComponent(_0x334b36));return Array['isArray'](_0xcb4a6e[_0x29242b(0x131)])?_0xcb4a6e[_0x29242b(0x131)]:[];}export async function getPersonalKnowledgeBaseItem(_0x3b30e5,_0x2cc85d){const _0x1e1d24=a74_0x1964,_0xdda36f=await apiRequest('/client/knowledge-base/personal/'+_0x3b30e5+_0x1e1d24(0x15f)+encodeURIComponent(_0x2cc85d));if(!_0xdda36f[_0x1e1d24(0x131)])throw CliErrors[_0x1e1d24(0x143)](_0x1e1d24(0x120)+_0x3b30e5);return _0xdda36f['data'];}export async function createPersonalKnowledgeBaseItem(_0x174ec6,_0x476697){const _0x47a4d6=a74_0x1964,_0x197c2d=await apiRequest(_0x47a4d6(0x19f),{'method':_0x47a4d6(0x149),'body':{'appCode':_0x174ec6,..._0x476697}});return _0x197c2d['data'];}export async function updatePersonalKnowledgeBaseItem(_0x8888fc,_0xfd8f14,_0x15dd48){const _0x19d825=a74_0x1964,_0xfd6f2f=await apiRequest(_0x19d825(0x162)+_0x8888fc+_0x19d825(0x19d),{'method':_0x19d825(0x149),'body':{'appCode':_0xfd8f14,..._0x15dd48}});return _0xfd6f2f[_0x19d825(0x131)];}export async function searchKnowledgeBase(_0x5d0fd8,_0x161fa8){const _0x282a01=a74_0x1964,_0x53442d=await apiRequest(_0x282a01(0x17f),{'method':'POST','body':{'appCode':_0x5d0fd8,'query':_0x161fa8['query'],..._0x161fa8[_0x282a01(0x12f)]!==undefined?{'topK':_0x161fa8[_0x282a01(0x12f)]}:{}}});return Array['isArray'](_0x53442d[_0x282a01(0x131)])?_0x53442d[_0x282a01(0x131)]:[];}export async function getRuntimeSkillByCode(_0x5c4dc9,_0x5cb1df){const _0x502de0=await skillHubJsonRequest('/api/v1/skills/'+encodeURIComponent(_0x5c4dc9)+'/'+encodeURIComponent(_0x5cb1df),{'allowNotFound':!![]});return _0x502de0?skillHubRuntimeDetailToRuntimeSkill(_0x502de0):undefined;}export async function listRuntimeSkills(_0x2ac864){const _0x2f61b4=a74_0x1964,_0x5e1d3d=await skillHubJsonRequest(_0x2f61b4(0x13c)+encodeURIComponent(_0x2ac864[_0x2f61b4(0x11e)])+_0x2f61b4(0x15e),{'query':{'page':0x0,'size':0xc8}});return normalizeSkillHubRuntimeListResponse(_0x2ac864[_0x2f61b4(0x11e)],_0x5e1d3d,_0x2ac864[_0x2f61b4(0x1a3)]??_0x2f61b4(0x168),_0x2ac864[_0x2f61b4(0x153)]);}export async function listPersonalRuntimeSkills(_0x3aed3c){const _0x53aa88=a74_0x1964;return(await listRuntimeSkills({'appCode':_0x3aed3c,'scope':_0x53aa88(0x185)}))['personal'];}export async function listCompanyRuntimeSkills(_0x1b3e94){const _0x512f16=a74_0x1964;return(await listRuntimeSkills({'appCode':_0x1b3e94,'scope':_0x512f16(0x145)}))[_0x512f16(0x145)];}export async function listVisibleRuntimeSkills(_0x5e3781){const _0x1f38e1=a74_0x1964;return(await listRuntimeSkills({'appCode':_0x5e3781,'scope':'all'}))[_0x1f38e1(0x182)];}export async function createPersonalRuntimeSkill(_0x3e0258,_0x394146){return publishRuntimeSkill(_0x3e0258,_0x394146,{'visibility':'PRIVATE'});}export async function updatePersonalRuntimeSkill(_0x5e222c,_0x5e428c,_0x1eacdf){const _0x4a8cf8=a74_0x1964;return publishRuntimeSkill(_0x5e428c,{..._0x1eacdf,'skillCode':_0x1eacdf[_0x4a8cf8(0x125)]??_0x5e222c},{'visibility':_0x4a8cf8(0x13f)});}export async function publishCompanyRuntimeSkill(_0x11dedc,_0x594769,_0x5953c6={}){const _0x9f5c16=a74_0x1964;return publishRuntimeSkill(_0x11dedc,_0x594769,{'visibility':_0x9f5c16(0x19e),'confirmWarnings':_0x5953c6[_0x9f5c16(0x179)]});}export async function validateRuntimeSkillPublish(_0x4a6acf,_0x1d70a1,_0x41cb48){const _0x547c59=a74_0x1964,_0x3ab87a=buildRuntimeSkillPublishForm(_0x1d70a1,_0x41cb48[_0x547c59(0x12b)]),_0x3c31a9=await skillHubJsonRequest(_0x547c59(0x170)+encodeURIComponent(_0x4a6acf)+_0x547c59(0x141),{'method':_0x547c59(0x149),'body':_0x3ab87a});return{'valid':_0x3c31a9[_0x547c59(0x192)]===!![],'errors':Array[_0x547c59(0x16a)](_0x3c31a9[_0x547c59(0x17d)])?_0x3c31a9[_0x547c59(0x17d)]:[],'warnings':Array[_0x547c59(0x16a)](_0x3c31a9[_0x547c59(0x199)])?_0x3c31a9[_0x547c59(0x199)]:[],'resolvedSlug':_0x3c31a9[_0x547c59(0x15c)],'resolvedVersion':_0x3c31a9['resolvedVersion']};}export async function downloadRuntimeSkillPackage(_0xed7682,_0x110083,_0x1e254f,_0x1caa3a){const _0x558fed=a74_0x1964;void _0xed7682;const _0x13e9c4=_0x1caa3a?_0x558fed(0x170)+encodeURIComponent(_0x1e254f)+'/'+encodeURIComponent(_0x110083)+'/versions/'+encodeURIComponent(_0x1caa3a)+'/download':_0x558fed(0x170)+encodeURIComponent(_0x1e254f)+'/'+encodeURIComponent(_0x110083)+'/download';return skillHubBinaryRequest(_0x13e9c4);}function a74_0x440c(){const _0xc64e8d=['text','invokeSource','test','success','API\x20error\x20code:\x20','confirmWarnings','/client/sql/query','url','values','errors','Download\x20failed:\x20','/client/knowledge-base/search','content','application/json','effective','/client/dataset/list','/client/artifact/','personal','998405ySHkzY','file','appName','boolean','name','msg','SQL\x20query\x20not\x20found:\x20','/client/runtime-bff/personal/list?appCode=','markdown','/client/runtime-bff/personal/create','7271512kVDDNe','GET','valid','version','Request\x20timeout:\x20','filter','/client/dataset/get-driven-data?code=','Configure\x20accessKey\x20in\x20','AbortError','warnings','skill','22kQJqZI','favorite','/update','NAMESPACE_ONLY','/client/knowledge-base/personal/create','summary','Invalid\x20app\x20list\x20response:\x20expected\x20object\x20or\x20array.','string','scope','Invalid\x20login\x20user\x20info\x20response:\x20expected\x20object.','slug','source','/publish','Invalid\x20app\x20list\x20response:\x20missing\x20data.tableData.','appCode','/client/runtime-bff/personal/','Knowledge-base\x20entry\x20not\x20found:\x20id=','/client/app-config/getByKey?','api-doc-generator','artifactType','errorMsg','skillCode','message','Missing\x20Skill\x20package\x20payload.','json','items','application/octet-stream','visibility','authRequired','namespace','Personal\x20BFF\x20not\x20found:\x20id=','topK','displayName','data','tags','skillName','tableData','newConfigFileName','19016bZWcdA','base64','3626276iZnwSC','/client/knowledge-base/personal/list?appCode=','.zip','signal','/api/runtime/v1/namespaces/','SkillHub\x20API\x20error:\x20','trim','PRIVATE','232092jZzHYn','/publish/validate','download','validation','map','company','ownerPreviewVersion','description','sqlCode','POST','searchParams','Check\x20your\x20credentials\x20and\x20try\x20again.','/client/artifact/list?','from','application/zip','API\x20returned\x20non-JSON\x20response\x20(HTTP\x20','toString','/client/user/loginUserInfo','6587707fELHEM','code','795780UMtpKy','packageBase64','number','SkillHub\x20returned\x20non-JSON\x20response\x20(HTTP\x20','object','errorCode','entries','abort','resolvedSlug','/client/artifact/create','/skills','?appCode=','set','API\x20error:\x20','/client/knowledge-base/personal/','status','stringify','BFF\x20script\x20not\x20found:\x20id=','/client/uploadFile','append','all','toLowerCase','isArray','arrayBuffer','apiError','170qOMzhi','join','30iDNitn','/api/cli/v1/skills/','replace','Toolbox\x20error\x20code:\x20','SkillHub\x20error\x20code:\x20'];a74_0x440c=function(){return _0xc64e8d;};return a74_0x440c();}async function publishRuntimeSkill(_0x620c29,_0x2abeea,_0x14a7d3){const _0x3bc877=a74_0x1964,_0x3fcb18=buildRuntimeSkillPublishForm(_0x2abeea,_0x14a7d3[_0x3bc877(0x12b)]),_0x26f3eb=await skillHubJsonRequest(_0x3bc877(0x170)+encodeURIComponent(_0x620c29)+_0x3bc877(0x11c),{'method':'POST','query':{'confirmWarnings':_0x14a7d3['confirmWarnings']===!![]?!![]:undefined},'body':_0x3fcb18});return{'appCode':_0x26f3eb[_0x3bc877(0x12d)]??_0x620c29,'skillCode':_0x26f3eb[_0x3bc877(0x11a)]??_0x2abeea[_0x3bc877(0x125)]??'','skillName':_0x2abeea[_0x3bc877(0x133)]??_0x26f3eb['slug']??_0x2abeea[_0x3bc877(0x125)],'description':_0x2abeea[_0x3bc877(0x147)],'scope':skillHubVisibilityToScope(_0x26f3eb[_0x3bc877(0x12b)]??_0x14a7d3['visibility'])??_0x3bc877(0x185),'version':_0x26f3eb['version']??_0x2abeea['version'],'tags':_0x2abeea[_0x3bc877(0x132)],'content':_0x2abeea[_0x3bc877(0x180)]};}function buildRuntimeSkillPublishForm(_0x2c271a,_0x3b347b){const _0x598ea=a74_0x1964,_0x23dc76=new FormData();return _0x23dc76[_0x598ea(0x160)](_0x598ea(0x187),runtimeSkillPackageFile(_0x2c271a)),_0x2c271a['skillName']?.[_0x598ea(0x13e)]()&&_0x23dc76[_0x598ea(0x160)]('displayName',_0x2c271a[_0x598ea(0x133)][_0x598ea(0x13e)]()),_0x23dc76[_0x598ea(0x160)](_0x598ea(0x12b),_0x3b347b),_0x23dc76;}function runtimeSkillPackageFile(_0x515079){const _0xfa78a3=a74_0x1964;if(!_0x515079[_0xfa78a3(0x155)])throw CliErrors[_0xfa78a3(0x143)](_0xfa78a3(0x127));const _0x5f06b8=Buffer['from'](_0x515079[_0xfa78a3(0x155)],_0xfa78a3(0x137)),_0x1753c2=new Blob([_0x5f06b8],{'type':_0xfa78a3(0x14e)}),_0x2726db=(_0x515079[_0xfa78a3(0x125)]||_0xfa78a3(0x19a))+_0xfa78a3(0x13a);if(typeof File!=='undefined')return new File([_0x1753c2],_0x2726db,{'type':_0xfa78a3(0x14e)});return _0x1753c2;}function normalizeSkillHubRuntimeListResponse(_0x91f65c,_0x3fc8eb,_0x507cd8,_0x580b14){const _0x450140=a74_0x1964,_0x4da067=Array[_0x450140(0x16a)](_0x3fc8eb)?_0x3fc8eb:Array[_0x450140(0x16a)](_0x3fc8eb?.[_0x450140(0x129)])?_0x3fc8eb['items']:[],_0x12baa8=_0x580b14?.[_0x450140(0x13e)](),_0x465471=_0x4da067['filter'](_0x17b191=>!_0x12baa8||_0x17b191['slug']===_0x12baa8)[_0x450140(0x144)](skillHubRuntimeItemToRuntimeSkill)['filter'](_0xfcd4b2=>Boolean(_0xfcd4b2)),_0xbf03fc=_0x465471[_0x450140(0x195)](_0x2fb516=>_0x2fb516[_0x450140(0x1a3)]==='personal'),_0x3b6f4b=_0x465471[_0x450140(0x195)](_0x54db44=>_0x54db44['scope']===_0x450140(0x145));return{'appCode':_0x91f65c,'personal':_0x507cd8===_0x450140(0x145)?[]:_0xbf03fc,'company':_0x507cd8===_0x450140(0x185)?[]:_0x3b6f4b,'effective':buildEffectiveRuntimeSkills(_0xbf03fc,_0x3b6f4b,_0x507cd8)};}function skillHubRuntimeItemToRuntimeSkill(_0x158795){const _0x359ffe=a74_0x1964,_0x3596f4=_0x158795[_0x359ffe(0x11a)]?.[_0x359ffe(0x13e)](),_0x2414c1=skillHubVisibilityToScope(_0x158795[_0x359ffe(0x12b)]);if(!_0x3596f4||!_0x2414c1)return undefined;return{'id':_0x158795['id'],'appCode':_0x158795[_0x359ffe(0x12d)],'skillCode':_0x3596f4,'skillName':_0x158795[_0x359ffe(0x130)]??_0x3596f4,'description':_0x158795[_0x359ffe(0x1a0)],'scope':_0x2414c1,'version':skillHubRuntimeItemVersion(_0x158795),'status':_0x158795[_0x359ffe(0x163)]};}function skillHubRuntimeDetailToRuntimeSkill(_0x1ced44){const _0x288fdf=a74_0x1964,_0x411fe4=_0x1ced44['slug']?.[_0x288fdf(0x13e)]();if(!_0x411fe4)return undefined;return{'id':_0x1ced44['id'],'appCode':_0x1ced44[_0x288fdf(0x12d)],'skillCode':_0x411fe4,'skillName':_0x1ced44[_0x288fdf(0x130)]??_0x411fe4,'description':_0x1ced44[_0x288fdf(0x1a0)],'scope':skillHubVisibilityToScope(_0x1ced44[_0x288fdf(0x12b)])??_0x1ced44[_0x288fdf(0x12b)]?.[_0x288fdf(0x169)](),'version':skillHubRuntimeItemVersion(_0x1ced44),'status':_0x1ced44['status']};}function skillHubVisibilityToScope(_0x2264b7){const _0x24f78d=a74_0x1964;if(_0x2264b7==='PRIVATE')return _0x24f78d(0x185);if(_0x2264b7===_0x24f78d(0x19e))return'company';return undefined;}function skillHubRuntimeItemVersion(_0x4bd7fd){const _0x4d7a04=a74_0x1964;return _0x4bd7fd['publishedVersion']?.[_0x4d7a04(0x193)]??_0x4bd7fd['headlineVersion']?.[_0x4d7a04(0x193)]??_0x4bd7fd[_0x4d7a04(0x146)]?.['version'];}function buildEffectiveRuntimeSkills(_0x2a9579,_0xb68cee,_0xe1e4d5){const _0x5cfd2a=a74_0x1964;if(_0xe1e4d5===_0x5cfd2a(0x185))return _0x2a9579;if(_0xe1e4d5===_0x5cfd2a(0x145))return _0xb68cee;const _0x1aa39c=new Map();for(const _0x1ec6ee of _0xb68cee){_0x1aa39c[_0x5cfd2a(0x160)](_0x1ec6ee[_0x5cfd2a(0x125)],_0x1ec6ee);}for(const _0x4ea06d of _0x2a9579){_0x1aa39c[_0x5cfd2a(0x160)](_0x4ea06d[_0x5cfd2a(0x125)],_0x4ea06d);}return Array[_0x5cfd2a(0x14d)](_0x1aa39c[_0x5cfd2a(0x17c)]());}function normalizeRuntimeSkillListResponse(_0x295838,_0x1b0149){const _0x18ff1c=a74_0x1964;if(Array[_0x18ff1c(0x16a)](_0x1b0149)){const _0x47e748=_0x1b0149[_0x18ff1c(0x195)](_0x4add37=>_0x4add37[_0x18ff1c(0x1a3)]===_0x18ff1c(0x185)),_0x15f9d8=_0x1b0149[_0x18ff1c(0x195)](_0x456f2f=>_0x456f2f[_0x18ff1c(0x1a3)]===_0x18ff1c(0x145));return{'appCode':_0x295838,'personal':_0x47e748,'company':_0x15f9d8,'effective':[..._0x15f9d8,..._0x47e748]};}return{'appCode':_0x1b0149?.[_0x18ff1c(0x11e)]??_0x295838,'personal':Array[_0x18ff1c(0x16a)](_0x1b0149?.[_0x18ff1c(0x185)])?_0x1b0149[_0x18ff1c(0x185)]:[],'company':Array['isArray'](_0x1b0149?.[_0x18ff1c(0x145)])?_0x1b0149[_0x18ff1c(0x145)]:[],'effective':Array[_0x18ff1c(0x16a)](_0x1b0149?.[_0x18ff1c(0x182)])?_0x1b0149[_0x18ff1c(0x182)]:[]};}
|
package/lib/core/db-resolver.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x24219e,_0x384d23){const _0x4b9184=a75_0xe124,_0x386a21=_0x24219e();while(!![]){try{const _0x218b2b=parseInt(_0x4b9184(0x1d1))/0x1+-parseInt(_0x4b9184(0x1d3))/0x2*(parseInt(_0x4b9184(0x1de))/0x3)+-parseInt(_0x4b9184(0x1dd))/0x4+-parseInt(_0x4b9184(0x1da))/0x5*(-parseInt(_0x4b9184(0x1ce))/0x6)+-parseInt(_0x4b9184(0x1d9))/0x7+-parseInt(_0x4b9184(0x1d5))/0x8*(parseInt(_0x4b9184(0x1d8))/0x9)+parseInt(_0x4b9184(0x1d0))/0xa*(parseInt(_0x4b9184(0x1d7))/0xb);if(_0x218b2b===_0x384d23)break;else _0x386a21['push'](_0x386a21['shift']());}catch(_0x4591f3){_0x386a21['push'](_0x386a21['shift']());}}}(a75_0x3730,0x1c575));import{listDatasets}from'../core/api-client.js';const cache=new Map();export async function listDatabases(_0x21248f){const _0x161b6b=a75_0xe124;if(cache[_0x161b6b(0x1db)](_0x21248f))return cache[_0x161b6b(0x1dc)](_0x21248f);const _0x205df8=await listDatasets(_0x21248f),_0x160e63=new Map();for(const _0x36c831 of _0x205df8){const _0xd07beb=_0x36c831['dbtableConfig'];_0xd07beb?.[_0x161b6b(0x1d4)]!=null&&_0x160e63[_0x161b6b(0x1d2)](_0xd07beb[_0x161b6b(0x1d4)],_0xd07beb['dbName']??'db-'+_0xd07beb['dbId']);}const _0xd1692a=[..._0x160e63['entries']()]['map'](([_0x2f3f99,_0x149933])=>({'dbId':_0x2f3f99,'dbName':_0x149933}));return cache[_0x161b6b(0x1d2)](_0x21248f,_0xd1692a),_0xd1692a;}function a75_0x3730(){const _0x57347e=['find','11GLuERP','1854cqjpJG','288932MjBOBg','10DFfPKX','has','get','509676jtQjTg','1701UPbspE','442302PCyAsb','dbName','3081110cONquk','98012KOdkDW','set','406pyEWyN','dbId','5968GMAJWj'];a75_0x3730=function(){return _0x57347e;};return a75_0x3730();}function a75_0xe124(_0x228201,_0x1caaad){_0x228201=_0x228201-0x1ce;const _0x37303f=a75_0x3730();let _0xe12483=_0x37303f[_0x228201];return _0xe12483;}export async function getDbName(_0x4aa61b,_0x104ba0){const _0x19490b=a75_0xe124;try{const _0x515c7c=await listDatabases(_0x4aa61b);return _0x515c7c[_0x19490b(0x1d6)](_0x7cc668=>_0x7cc668['dbId']===_0x104ba0)?.[_0x19490b(0x1cf)];}catch{return undefined;}}
|
package/lib/core/sdk-client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x18a09a,_0x592479){const _0x434c4b=a76_0x3646,_0x383473=_0x18a09a();while(!![]){try{const _0x2b046f=-parseInt(_0x434c4b(0x138))/0x1+parseInt(_0x434c4b(0x139))/0x2+-parseInt(_0x434c4b(0x14c))/0x3+parseInt(_0x434c4b(0x14d))/0x4*(parseInt(_0x434c4b(0x13c))/0x5)+-parseInt(_0x434c4b(0x15a))/0x6+parseInt(_0x434c4b(0x13e))/0x7*(-parseInt(_0x434c4b(0x14a))/0x8)+parseInt(_0x434c4b(0x141))/0x9*(parseInt(_0x434c4b(0x152))/0xa);if(_0x2b046f===_0x592479)break;else _0x383473['push'](_0x383473['shift']());}catch(_0x175a4c){_0x383473['push'](_0x383473['shift']());}}}(a76_0x414b,0x83642));import{createClient}from'@lovrabet/sdk';import{PRODUCT_CONFIG}from'../constant/product.js';import{CliErrors}from'../errors.js';import{parseBatchCreateItemsFromParams}from'../utils/params.js';function a76_0x414b(){const _0x4f51ea=['invokeSource','6104ltmTAk','delete\x20requires\x20\x22id\x22\x20in\x20--params,\x20e.g.\x20\x27{\x22id\x22:123}\x27','batchCreate','324SwHwtM','models','map','object','validation','appCode','aggregate','\x22.\x20','data\x20aggregate\x20--params.aggregate[','40XOEztG','delete','714453WmHJmf','892sNeAvl','function','env','trim','getOne','77800tXThXu','update\x20requires\x20\x22id\x22\x20in\x20--params,\x20e.g.\x20\x27{\x22id\x22:123,\x22name\x22:\x22new\x22}\x27','Available:\x20filter,\x20getOne,\x20create,\x20batchCreate,\x20update,\x20delete,\x20aggregate.','field','update','accessKey','authMode','isArray','2849496VAJfSv','106808CYparL','1178560CKjcxS','execute','sql','11055GTtGlh'];a76_0x414b=function(){return _0x4f51ea;};return a76_0x414b();}let _client;export function initSdkClient(_0x161243){const _0x2c1d67=a76_0x3646;_client=createClient({'appCode':_0x161243[_0x2c1d67(0x146)],'env':_0x161243[_0x2c1d67(0x14f)],'authMode':_0x161243[_0x2c1d67(0x158)],..._0x161243[_0x2c1d67(0x157)]?{'accessKey':_0x161243[_0x2c1d67(0x157)]}:{},'options':{'timeout':0x7530,'headers':{'X-Invoke-Source':PRODUCT_CONFIG[_0x2c1d67(0x13d)]}}});}function ensureClient(){if(!_client)throw new Error('SDK\x20client\x20not\x20initialized.\x20Call\x20initSdkClient()\x20first.');return _client;}function normalizeAggregateParams(_0x1701ad){const _0x32f9de=a76_0x3646,_0x4c4103=_0x1701ad[_0x32f9de(0x147)];if(_0x4c4103===undefined)return _0x1701ad;if(!Array[_0x32f9de(0x159)](_0x4c4103))throw CliErrors[_0x32f9de(0x145)]('data\x20aggregate\x20--params.aggregate\x20must\x20be\x20an\x20array.');return{..._0x1701ad,'aggregate':_0x4c4103[_0x32f9de(0x143)]((_0x3d41d6,_0x5066eb)=>{const _0x965c80=_0x32f9de;if(!_0x3d41d6||typeof _0x3d41d6!==_0x965c80(0x144)||Array[_0x965c80(0x159)](_0x3d41d6))throw CliErrors[_0x965c80(0x145)]('data\x20aggregate\x20--params.aggregate['+_0x5066eb+']\x20must\x20be\x20an\x20object.');const _0x330214=_0x3d41d6['column']??_0x3d41d6[_0x965c80(0x155)];if(typeof _0x330214!=='string'||_0x330214[_0x965c80(0x150)]()==='')throw CliErrors['validation'](_0x965c80(0x149)+_0x5066eb+']\x20requires\x20\x22column\x22;\x20\x22field\x22\x20is\x20accepted\x20only\x20as\x20a\x20deprecated\x20alias.');const _0x503934={..._0x3d41d6,'column':_0x330214};return delete _0x503934[_0x965c80(0x155)],_0x503934;})};}function a76_0x3646(_0x12fa15,_0x409da7){_0x12fa15=_0x12fa15-0x138;const _0x414b05=a76_0x414b();let _0x364613=_0x414b05[_0x12fa15];return _0x364613;}export async function executeData(_0x262e6a,_0x779acf,_0x5f0cb9){const _0x4a3fa2=a76_0x3646,_0x111c8a=ensureClient(),_0x52b28a='dataset_'+_0x262e6a,_0x3c9856=_0x111c8a[_0x4a3fa2(0x142)][_0x52b28a];if(!_0x3c9856||typeof _0x3c9856[_0x779acf]!==_0x4a3fa2(0x14e))throw new Error('SDK\x20model\x20does\x20not\x20support\x20operation\x20\x22'+_0x779acf+_0x4a3fa2(0x148)+_0x4a3fa2(0x154));if(_0x779acf===_0x4a3fa2(0x140))return _0x3c9856[_0x4a3fa2(0x140)](parseBatchCreateItemsFromParams(_0x5f0cb9));const _0x505369=_0x5f0cb9!==undefined&&_0x5f0cb9!==null&&!Array[_0x4a3fa2(0x159)](_0x5f0cb9)?_0x5f0cb9:{};switch(_0x779acf){case _0x4a3fa2(0x151):{const _0x2302e1=_0x505369['id'];if(_0x2302e1===undefined||_0x2302e1===null)throw new Error('getOne\x20requires\x20\x22id\x22\x20in\x20--params,\x20e.g.\x20\x27{\x22id\x22:123}\x27');return _0x3c9856['getOne'](_0x2302e1);}case _0x4a3fa2(0x156):{const {id:_0x2fd062,..._0x1e0baa}=_0x505369;if(_0x2fd062===undefined||_0x2fd062===null)throw new Error(_0x4a3fa2(0x153));return _0x3c9856[_0x4a3fa2(0x156)](_0x2fd062,_0x1e0baa);}case'delete':{const _0x270c21=_0x505369['id'];if(_0x270c21===undefined||_0x270c21===null)throw new Error(_0x4a3fa2(0x13f));return _0x3c9856[_0x4a3fa2(0x14b)](_0x270c21);}case _0x4a3fa2(0x147):return _0x3c9856[_0x4a3fa2(0x147)](normalizeAggregateParams(_0x505369));default:return _0x3c9856[_0x779acf](_0x505369);}}export async function executeSdkSql(_0x2e4825,_0x1b819){const _0x2e3a24=a76_0x3646,_0x4d82b2=ensureClient();return _0x4d82b2[_0x2e3a24(0x13b)][_0x2e3a24(0x13a)]({'sqlCode':_0x2e4825,'params':_0x1b819});}export async function executeSdkBff(_0x32493b,_0x269d1b){const _0x1dbfa5=a76_0x3646,_0x4e19e6=ensureClient();return _0x4e19e6['bff'][_0x1dbfa5(0x13a)]({'scriptName':_0x32493b,'params':_0x269d1b});}
|
package/lib/errors.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a77_0x27ad15=a77_0x2a9d;(function(_0x7ac84c,_0x4db834){const _0x34b2cf=a77_0x2a9d,_0x2be61d=_0x7ac84c();while(!![]){try{const _0x535675=-parseInt(_0x34b2cf(0x1d6))/0x1+-parseInt(_0x34b2cf(0x1cc))/0x2*(-parseInt(_0x34b2cf(0x1d9))/0x3)+-parseInt(_0x34b2cf(0x1d2))/0x4+-parseInt(_0x34b2cf(0x1d4))/0x5*(-parseInt(_0x34b2cf(0x1ca))/0x6)+parseInt(_0x34b2cf(0x1d3))/0x7*(-parseInt(_0x34b2cf(0x1da))/0x8)+parseInt(_0x34b2cf(0x1ce))/0x9*(-parseInt(_0x34b2cf(0x1cd))/0xa)+parseInt(_0x34b2cf(0x1d1))/0xb;if(_0x535675===_0x4db834)break;else _0x2be61d['push'](_0x2be61d['shift']());}catch(_0x21565a){_0x2be61d['push'](_0x2be61d['shift']());}}}(a77_0x505b,0xb6170));import{CliError,createCliErrors}from'@lovrabet/cli-framework';function a77_0x2a9d(_0xb6cdc8,_0x4a318e){_0xb6cdc8=_0xb6cdc8-0x1ca;const _0x505b55=a77_0x505b();let _0x2a9de3=_0x505b55[_0xb6cdc8];return _0x2a9de3;}import{CLI_BIN_NAME}from'./constant/cli.js';import{PRODUCT_CONFIG}from'./constant/product.js';function a77_0x505b(){const _0x254d1e=['683977tuDrfZ','157905HVhyeo','newConfigFileName','507772eLWJBQ','\x20auth\x20login`.','\x20or\x20run\x20`','3VEIUfp','104kuyinR','210QwqzpH','Set\x20appcode\x20via\x20--appcode\x20or\x20','2449446VVOqzS','18770lbQMEl','4959PwshmW','\x20file.','Configure\x20accessKey\x20in\x20','21102906LxKlvK','2761688TarDsL'];a77_0x505b=function(){return _0x254d1e;};return a77_0x505b();}export{CliError};export const CliErrors=createCliErrors({'cliBinName':CLI_BIN_NAME,'authRequiredHint':a77_0x27ad15(0x1d0)+PRODUCT_CONFIG[a77_0x27ad15(0x1d5)]+a77_0x27ad15(0x1d8)+CLI_BIN_NAME+a77_0x27ad15(0x1d7),'configMissingHint':a77_0x27ad15(0x1cb)+PRODUCT_CONFIG['newConfigFileName']+'.','notInProjectHint':'Run\x20this\x20command\x20inside\x20a\x20directory\x20with\x20a\x20'+PRODUCT_CONFIG[a77_0x27ad15(0x1d5)]+a77_0x27ad15(0x1cf)});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a78_0x4865(_0x157f06,_0x4ce887){_0x157f06=_0x157f06-0x1b7;var _0x102aef=a78_0x102a();var _0x4865a5=_0x102aef[_0x157f06];return _0x4865a5;}(function(_0x1fcb70,_0x564587){var _0xac57f9=a78_0x4865,_0x4ec1cc=_0x1fcb70();while(!![]){try{var _0x15627e=parseInt(_0xac57f9(0x1bc))/0x1*(parseInt(_0xac57f9(0x1c0))/0x2)+-parseInt(_0xac57f9(0x1be))/0x3+parseInt(_0xac57f9(0x1b8))/0x4+-parseInt(_0xac57f9(0x1bd))/0x5+parseInt(_0xac57f9(0x1bf))/0x6*(parseInt(_0xac57f9(0x1bb))/0x7)+-parseInt(_0xac57f9(0x1ba))/0x8*(-parseInt(_0xac57f9(0x1b9))/0x9)+-parseInt(_0xac57f9(0x1b7))/0xa;if(_0x15627e===_0x564587)break;else _0x4ec1cc['push'](_0x4ec1cc['shift']());}catch(_0x26940b){_0x4ec1cc['push'](_0x4ec1cc['shift']());}}}(a78_0x102a,0x1b56d));function a78_0x102a(){var _0x5daeab=['2528PEEABN','84049wvGIKF','58dSgAfM','778505mKCyQv','520143tgGxwz','96AzFUCV','7274ClgXXw','2711420VTaGKs','642508CjZTzy','4230NKIVFO'];a78_0x102a=function(){return _0x5daeab;};return a78_0x102a();}import{DEFAULT_COMMAND_OUTPUT_FORMAT}from'../constant/defaults.js';import{buildAllFlags as a78_0x2e9d39}from'@lovrabet/cli-framework';export function buildAllFlags(_0x39838d){return a78_0x2e9d39(_0x39838d,{'defaultOutputFormat':DEFAULT_COMMAND_OUTPUT_FORMAT});}
|
package/lib/framework/dryrun.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3cf084,_0x1209ba){const _0x5597a9=a79_0x4318,_0x46c586=_0x3cf084();while(!![]){try{const _0x2d933a=parseInt(_0x5597a9(0x168))/0x1+-parseInt(_0x5597a9(0x166))/0x2*(parseInt(_0x5597a9(0x163))/0x3)+parseInt(_0x5597a9(0x165))/0x4+parseInt(_0x5597a9(0x15e))/0x5+parseInt(_0x5597a9(0x160))/0x6+parseInt(_0x5597a9(0x167))/0x7+parseInt(_0x5597a9(0x164))/0x8*(-parseInt(_0x5597a9(0x15f))/0x9);if(_0x2d933a===_0x1209ba)break;else _0x46c586['push'](_0x46c586['shift']());}catch(_0x1fb678){_0x46c586['push'](_0x46c586['shift']());}}}(a79_0x339c,0xd722a));function a79_0x4318(_0x955969,_0x4e73af){_0x955969=_0x955969-0x15e;const _0x339c3b=a79_0x339c();let _0x431821=_0x339c3b[_0x955969];return _0x431821;}function a79_0x339c(){const _0x9d1aee=['27OeZFrx','51328YHQitK','4759368mRKqMF','238006DixAfF','455385fKnpMc','1628238bpfreL','7941350cnbqaa','3771ADYrmX','1014720XqQSfM','body','description'];a79_0x339c=function(){return _0x9d1aee;};return a79_0x339c();}export function dryRun(_0x45c02f,_0x2af362){const _0x55ad54={'method':_0x45c02f,'url':_0x2af362},_0x53b447={'body'(_0xb60b75){const _0x52fb06=a79_0x4318;return _0x55ad54[_0x52fb06(0x161)]=_0xb60b75,_0x53b447;},'description'(_0x2448f3){const _0x24e557=a79_0x4318;return _0x55ad54[_0x24e557(0x162)]=_0x2448f3,_0x53b447;},'build'(){return{..._0x55ad54};}};return _0x53b447;}
|
package/lib/framework/flags.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a80_0x3833(){const _0x39916a=['validateFlags','parseFlags','140774ovnnpo','1669720TYpegB','125816CQLOrv','7PpotLS','3MWpgNP','985236HMbDsO','66gPNPvD','250346uUTeXO','102155vBYHke','18zskohu','8918525EFXsjI'];a80_0x3833=function(){return _0x39916a;};return a80_0x3833();}const a80_0x15c8b0=a80_0x5252;function a80_0x5252(_0x11e5f4,_0x247d9d){_0x11e5f4=_0x11e5f4-0xf4;const _0x383312=a80_0x3833();let _0x52524e=_0x383312[_0x11e5f4];return _0x52524e;}(function(_0xceb983,_0x2e2e37){const _0x1a6cbc=a80_0x5252,_0x19ba8d=_0xceb983();while(!![]){try{const _0x258230=parseInt(_0x1a6cbc(0xf4))/0x1+-parseInt(_0x1a6cbc(0xfa))/0x2*(parseInt(_0x1a6cbc(0xfe))/0x3)+parseInt(_0x1a6cbc(0xff))/0x4+-parseInt(_0x1a6cbc(0xf5))/0x5*(-parseInt(_0x1a6cbc(0x100))/0x6)+-parseInt(_0x1a6cbc(0xfd))/0x7*(-parseInt(_0x1a6cbc(0xfc))/0x8)+-parseInt(_0x1a6cbc(0xf6))/0x9*(-parseInt(_0x1a6cbc(0xfb))/0xa)+-parseInt(_0x1a6cbc(0xf7))/0xb;if(_0x258230===_0x2e2e37)break;else _0x19ba8d['push'](_0x19ba8d['shift']());}catch(_0x5c3c6f){_0x19ba8d['push'](_0x19ba8d['shift']());}}}(a80_0x3833,0x2e5d1));import{createFlagHelpers}from'@lovrabet/cli-framework';import{CliErrors}from'../errors.js';const helpers=createFlagHelpers(CliErrors);export const parseFlags=helpers[a80_0x15c8b0(0xf9)];export const validateFlags=helpers[a80_0x15c8b0(0xf8)];
|
package/lib/framework/help.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x1d50ea,_0x341958){const _0x3d4374=a81_0x1609,_0x32cb6a=_0x1d50ea();while(!![]){try{const _0x558373=-parseInt(_0x3d4374(0xaf))/0x1*(parseInt(_0x3d4374(0xb2))/0x2)+-parseInt(_0x3d4374(0xb1))/0x3+-parseInt(_0x3d4374(0xa8))/0x4*(parseInt(_0x3d4374(0xb5))/0x5)+-parseInt(_0x3d4374(0xa7))/0x6+-parseInt(_0x3d4374(0xa6))/0x7*(-parseInt(_0x3d4374(0xae))/0x8)+parseInt(_0x3d4374(0xa0))/0x9*(-parseInt(_0x3d4374(0xad))/0xa)+parseInt(_0x3d4374(0xb0))/0xb;if(_0x558373===_0x341958)break;else _0x32cb6a['push'](_0x32cb6a['shift']());}catch(_0x25a8f9){_0x32cb6a['push'](_0x32cb6a['shift']());}}}(a81_0x1b5c,0x582a8));import{createHelpGenerators}from'@lovrabet/cli-framework';import{buildAllFlags}from'../framework/build-all-flags.js';function a81_0x1b5c(){const _0x51919f=['\x20or\x20--appcode).','newConfigFileName','has','718850jvWPmi','4098456cPOqRc','10CrPAjO','17354469GtAwgS','765021TkVrOY','97256hiWofL','service','generateServiceHelp','2275nBBnJA','9hTedsF','generateCommandHelp','map','get','Requires\x20appcode\x20(set\x20via\x20','filter','7CYUJPF','2510226NmRFyN','4372pVYlFk','generateFullHelp'];a81_0x1b5c=function(){return _0x51919f;};return a81_0x1b5c();}import{insertDynamicServicesAfterServiceTree}from'../framework/service-order.js';import{serviceRegistry,serviceGroups,getServiceEntry}from'../commands/registry.js';import{getDynamicServiceDefinitions,getDynamicServiceEntry,listDynamicServiceEntries}from'../commands/service/dynamic.js';import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';import{PRODUCT_CONFIG}from'../constant/product.js';function createGenerators(){const _0x47566c=a81_0x1609;return createHelpGenerators({'cliBinName':CLI_BIN_NAME,'cliDisplayName':CLI_DISPLAY_NAME,'globalFlags':GLOBAL_FLAGS,'serviceRegistry':insertDynamicServicesAfterServiceTree(serviceRegistry,safeListDynamicServiceEntries()),'getServiceEntry':getAnyServiceEntry,'getServiceDefinitions':getAnyServiceDefinitions,'buildAllFlags':buildAllFlags,'appPrerequisiteText':_0x47566c(0xa4)+PRODUCT_CONFIG[_0x47566c(0xab)]+_0x47566c(0xaa)});}export function generateCommandHelp(_0x13d1cd){const _0x80f52a=a81_0x1609;return createGenerators()[_0x80f52a(0xa1)](_0x13d1cd);}export function generateServiceHelp(_0xf0eca6){const _0xe343d0=a81_0x1609;return createGenerators()[_0xe343d0(0xb4)](_0xf0eca6);}function a81_0x1609(_0x4e3257,_0x4d23a2){_0x4e3257=_0x4e3257-0xa0;const _0x1b5c6a=a81_0x1b5c();let _0x160998=_0x1b5c6a[_0x4e3257];return _0x160998;}export function generateFullHelp(){const _0x27f6df=a81_0x1609;return createGenerators()[_0x27f6df(0xa9)]();}function getAnyServiceEntry(_0x1665f1){const _0x81df7d=getServiceEntry(_0x1665f1);if(_0x81df7d)return _0x81df7d;try{return getDynamicServiceEntry(_0x1665f1);}catch{return undefined;}}function getAnyServiceDefinitions(_0x2bb072){const _0x5a66d1=a81_0x1609,_0xa0d792=serviceGroups[_0x5a66d1(0xa3)](_0x2bb072);if(_0xa0d792)return _0xa0d792;try{return getDynamicServiceDefinitions(_0x2bb072);}catch{return undefined;}}function safeListDynamicServiceEntries(){const _0x5c14f3=a81_0x1609,_0x3b07c7=new Set(serviceRegistry[_0x5c14f3(0xa2)](_0x429354=>_0x429354[_0x5c14f3(0xb3)]));try{return listDynamicServiceEntries()[_0x5c14f3(0xa5)](_0x335a74=>!_0x3b07c7[_0x5c14f3(0xac)](_0x335a74[_0x5c14f3(0xb3)]));}catch{return[];}}
|
package/lib/framework/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x18fdb7,_0x1d2762){var _0x458672=a82_0x59f7,_0xebdb0=_0x18fdb7();while(!![]){try{var _0x202d57=-parseInt(_0x458672(0x133))/0x1+parseInt(_0x458672(0x12d))/0x2*(parseInt(_0x458672(0x12e))/0x3)+-parseInt(_0x458672(0x12f))/0x4*(-parseInt(_0x458672(0x130))/0x5)+parseInt(_0x458672(0x12b))/0x6*(parseInt(_0x458672(0x131))/0x7)+parseInt(_0x458672(0x134))/0x8+parseInt(_0x458672(0x132))/0x9+-parseInt(_0x458672(0x12c))/0xa;if(_0x202d57===_0x1d2762)break;else _0xebdb0['push'](_0xebdb0['shift']());}catch(_0x1d782b){_0xebdb0['push'](_0xebdb0['shift']());}}}(a82_0x47a7,0x18f36));export{runCommand}from'../framework/runner.js';export{parseFlags,validateFlags}from'../framework/flags.js';export{formatOutput}from'../framework/output.js';export{generateCommandHelp,generateServiceHelp,generateFullHelp}from'../framework/help.js';export{extractList,extractPaging}from'../framework/response.js';export{dryRun}from'../framework/dryrun.js';function a82_0x59f7(_0x4965d2,_0x374a6a){_0x4965d2=_0x4965d2-0x12b;var _0x47a7c0=a82_0x47a7();var _0x59f70f=_0x47a7c0[_0x4965d2];return _0x59f70f;}export{riskLevelOrder,isValidFormat}from'../framework/types.js';function a82_0x47a7(){var _0x5f2a14=['70468oCnVfX','20JGInXF','700LcdZiu','1190790suyXBG','188847DPNVNc','1470544UvEPbX','1878HkMdRV','1445990sXPGqg','1044jryCdE','102NPokwO'];a82_0x47a7=function(){return _0x5f2a14;};return a82_0x47a7();}
|
package/lib/framework/output.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x4eee85,_0x50161d){const _0x5b8d98=a83_0x4ad6,_0x435c33=_0x4eee85();while(!![]){try{const _0x2cd7cc=parseInt(_0x5b8d98(0x14b))/0x1*(parseInt(_0x5b8d98(0x147))/0x2)+-parseInt(_0x5b8d98(0x144))/0x3*(-parseInt(_0x5b8d98(0x14f))/0x4)+parseInt(_0x5b8d98(0x149))/0x5*(-parseInt(_0x5b8d98(0x143))/0x6)+-parseInt(_0x5b8d98(0x146))/0x7+parseInt(_0x5b8d98(0x151))/0x8+-parseInt(_0x5b8d98(0x148))/0x9*(-parseInt(_0x5b8d98(0x14a))/0xa)+-parseInt(_0x5b8d98(0x142))/0xb;if(_0x2cd7cc===_0x50161d)break;else _0x435c33['push'](_0x435c33['shift']());}catch(_0x52d0f2){_0x435c33['push'](_0x435c33['shift']());}}}(a83_0x57fc,0x496b0));import{createFormatOutput,resolveBundledJqPaths}from'@lovrabet/cli-framework';function a83_0x4ad6(_0x2c9304,_0x164f75){_0x2c9304=_0x2c9304-0x142;const _0x57fcc9=a83_0x57fc();let _0x4ad68b=_0x57fcc9[_0x2c9304];return _0x4ad68b;}import{CliErrors}from'../errors.js';const baseFormatOutput=createFormatOutput({'cliErrors':CliErrors,'jqBinaryResolverOptions':{'bundledJqPaths':resolveBundledJqPaths()}});function a83_0x57fc(){const _0x37fc85=['6467967XVumaG','3095292GstRab','15SuPnYg','format','363566PtAauh','695146SwpCxO','9XLQktR','5rhhmNX','4220150XUydAJ','1aeOMbX','_notice','update','pretty','276856DtHLXN','message','2727032OAnODB'];a83_0x57fc=function(){return _0x37fc85;};return a83_0x57fc();}export function formatOutput(_0x22dcab,_0x5b12c4){const _0x4eab80=a83_0x4ad6,_0x3ff27e=_0x22dcab[_0x4eab80(0x14c)],{_notice:_0x1b62d7,..._0xd8a4fb}=_0x22dcab;void _0x1b62d7,baseFormatOutput(_0xd8a4fb,_0x5b12c4),_0x5b12c4[_0x4eab80(0x145)]===_0x4eab80(0x14e)&&printPrettyNotice(_0x3ff27e);}function printPrettyNotice(_0x5bee58){const _0x3ba1e1=a83_0x4ad6;if(!_0x5bee58?.[_0x3ba1e1(0x14d)])return;console['error'](_0x5bee58[_0x3ba1e1(0x14d)][_0x3ba1e1(0x150)]+'\x20('+_0x5bee58[_0x3ba1e1(0x14d)]['url']+')');}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x596e24,_0x4782f9){const _0x290244=a84_0x2b52,_0x4d6979=_0x596e24();while(!![]){try{const _0x427859=-parseInt(_0x290244(0x1c9))/0x1+parseInt(_0x290244(0x1c2))/0x2*(parseInt(_0x290244(0x1c5))/0x3)+parseInt(_0x290244(0x1d6))/0x4+parseInt(_0x290244(0x1d9))/0x5*(parseInt(_0x290244(0x1df))/0x6)+parseInt(_0x290244(0x1c0))/0x7+parseInt(_0x290244(0x1c7))/0x8*(-parseInt(_0x290244(0x1bf))/0x9)+parseInt(_0x290244(0x1bc))/0xa*(-parseInt(_0x290244(0x1da))/0xb);if(_0x427859===_0x4782f9)break;else _0x4d6979['push'](_0x4d6979['shift']());}catch(_0xf18fbe){_0x4d6979['push'](_0x4d6979['shift']());}}}(a84_0x3ec6,0x9f21e));function toKebab(_0xdbad2b){const _0x197c87=a84_0x2b52;return _0xdbad2b['replace'](/_/g,'-')['replace'](/-([A-Z]+)/g,(_0x2b016e,_0x438c43)=>'-'+_0x438c43['toLowerCase']())[_0x197c87(0x1b8)](/([a-z0-9])([A-Z])/g,(_0x2018fb,_0x373b45,_0x2f9d75)=>_0x373b45+'-'+_0x2f9d75)[_0x197c87(0x1de)]();}function a84_0x3ec6(){const _0x2deea9=['has','keys','boolean','app','nonInteractive','get','corrected','dryRun','2929972DeVhWL','yes','name','5nanJXo','121kKcicw','push','sticky','slice','toLowerCase','7285674HqCTCC','env','replace','string','global','alias','317010ADiGsJ','help','set','9FWqybt','1506855aeInIe','entries','18jHrBtB','indexOf','length','50586gDPKNp','number','7714296eTamCj','dry-run','348991xNFijZ','type','non-interactive','add','original'];a84_0x3ec6=function(){return _0x2deea9;};return a84_0x3ec6();}function buildKnownFlags(_0x63b8cd){const _0x4da68b=a84_0x2b52,_0x39397b=new Set();for(const _0x3c895a of _0x63b8cd){_0x39397b[_0x4da68b(0x1cc)](_0x3c895a[_0x4da68b(0x1d8)]),_0x39397b['add'](toCamelCase(_0x3c895a['name']));}for(const _0x418e9a of[_0x4da68b(0x1c8),_0x4da68b(0x1d5),_0x4da68b(0x1d7),'format']){_0x39397b[_0x4da68b(0x1cc)](_0x418e9a);}for(const _0x5b7002 of[_0x4da68b(0x1bd),_0x4da68b(0x1e0),'appcode',_0x4da68b(0x1d1),_0x4da68b(0x1d2),_0x4da68b(0x1cb),'ci',_0x4da68b(0x1ba),'version']){_0x39397b[_0x4da68b(0x1cc)](_0x5b7002);}return _0x39397b;}function buildFlagTypeMap(_0x5c3003){const _0x404ef2=a84_0x2b52,_0x2792cb=new Map();for(const _0x4b98dc of _0x5c3003){_0x2792cb[_0x404ef2(0x1be)](_0x4b98dc[_0x404ef2(0x1d8)],_0x4b98dc[_0x404ef2(0x1ca)]),_0x2792cb['set'](toCamelCase(_0x4b98dc['name']),_0x4b98dc[_0x404ef2(0x1ca)]);}return _0x2792cb;}function toCamelCase(_0x32af8e){const _0x2eeec0=a84_0x2b52;return _0x32af8e[_0x2eeec0(0x1b8)](/-([a-z])/g,(_0x4a44b8,_0x5ab917)=>_0x5ab917['toUpperCase']());}function aliasHandler(_0x5e6925,_0x4a2e93){const _0x260a56=a84_0x2b52,_0x53bcc1=[];for(const _0x2873a0 of Object[_0x260a56(0x1cf)](_0x5e6925)){if(_0x4a2e93[_0x260a56(0x1ce)](_0x2873a0))continue;const _0x1c1826=toKebab(_0x2873a0);_0x1c1826!==_0x2873a0&&_0x4a2e93[_0x260a56(0x1ce)](_0x1c1826)&&_0x53bcc1[_0x260a56(0x1db)]({'original':_0x2873a0,'corrected':_0x1c1826,'handler':_0x260a56(0x1bb)});}return _0x53bcc1;}function stickyHandler(_0x34a06b,_0x468222,_0x115c26){const _0x59ff72=a84_0x2b52,_0x5d2aed=[];for(const [_0x44ab13,_0x1a4490]of Object[_0x59ff72(0x1c1)](_0x34a06b)){if(_0x1a4490!==!![])continue;for(let _0x2a5b8e=_0x44ab13[_0x59ff72(0x1c4)]-0x1;_0x2a5b8e>0x0;_0x2a5b8e--){const _0x4cc4e3=_0x44ab13[_0x59ff72(0x1dd)](0x0,_0x2a5b8e),_0xfedbbe=_0x44ab13[_0x59ff72(0x1dd)](_0x2a5b8e),_0x21afd0=toKebab(_0x4cc4e3),_0x221473=toCamelCase(_0x4cc4e3),_0x266fa5=_0x468222[_0x59ff72(0x1ce)](_0x4cc4e3)?_0x4cc4e3:_0x468222[_0x59ff72(0x1ce)](_0x21afd0)?_0x21afd0:_0x468222[_0x59ff72(0x1ce)](_0x221473)?_0x221473:null;if(!_0x266fa5)continue;const _0x47ae82=_0x115c26[_0x59ff72(0x1d3)](_0x266fa5)??_0x59ff72(0x1b9);let _0x50ad3e;if(_0x47ae82==='number'){const _0x25381b=Number(_0xfedbbe);if(isNaN(_0x25381b)||_0xfedbbe==='')continue;_0x50ad3e=_0x25381b;}else{if(_0x47ae82===_0x59ff72(0x1d0))continue;else{if(_0xfedbbe==='')continue;_0x50ad3e=_0xfedbbe;}}_0x5d2aed['push']({'original':_0x44ab13,'corrected':_0x266fa5+'='+_0x50ad3e,'handler':_0x59ff72(0x1dc)});break;}}return _0x5d2aed;}function a84_0x2b52(_0x132a12,_0xd30db6){_0x132a12=_0x132a12-0x1b8;const _0x3ec65c=a84_0x3ec6();let _0x2b52c1=_0x3ec65c[_0x132a12];return _0x2b52c1;}export function correctFlags(_0x1122bf,_0x454277){const _0x21a493=a84_0x2b52,_0x1c232d=buildKnownFlags(_0x454277),_0x5bd797=buildFlagTypeMap(_0x454277),_0x79ed60=aliasHandler(_0x1122bf,_0x1c232d),_0x2471bf=stickyHandler(_0x1122bf,_0x1c232d,_0x5bd797),_0x51b5b4=[..._0x79ed60,..._0x2471bf];if(_0x51b5b4[_0x21a493(0x1c4)]===0x0)return{'flags':_0x1122bf,'corrections':[]};const _0x4cb20f={..._0x1122bf},_0xb5e083=new Set();for(const _0x529e4e of _0x79ed60){_0x4cb20f[_0x529e4e[_0x21a493(0x1d4)]]=_0x1122bf[_0x529e4e[_0x21a493(0x1cd)]],_0xb5e083[_0x21a493(0x1cc)](_0x529e4e[_0x21a493(0x1cd)]);}for(const _0x3169b3 of _0x2471bf){const _0x55f242=_0x3169b3[_0x21a493(0x1d4)][_0x21a493(0x1c3)]('='),_0x1ebb63=_0x3169b3['corrected'][_0x21a493(0x1dd)](0x0,_0x55f242),_0x1e86cc=_0x3169b3[_0x21a493(0x1d4)][_0x21a493(0x1dd)](_0x55f242+0x1),_0x3dfb8b=_0x5bd797[_0x21a493(0x1d3)](_0x1ebb63)??_0x21a493(0x1b9);_0x3dfb8b===_0x21a493(0x1c6)?_0x4cb20f[_0x1ebb63]=Number(_0x1e86cc):_0x4cb20f[_0x1ebb63]=_0x1e86cc,_0xb5e083['add'](_0x3169b3['original']);}for(const _0x456dff of _0xb5e083){delete _0x4cb20f[_0x456dff];}return{'flags':_0x4cb20f,'corrections':_0x51b5b4};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
function a85_0x5c9d(_0x52db55,_0x4e065a){_0x52db55=_0x52db55-0x140;var _0xf4e8e=a85_0xf4e8();var _0x5c9d1f=_0xf4e8e[_0x52db55];return _0x5c9d1f;}function a85_0xf4e8(){var _0x51aa5c=['5467910YDylxI','14331WKfejl','21CaOJmW','180XwdxNx','48473579NVVeAW','954548LSiPUn','9369450rJGHCh','148405vGqRxT','7OvQOPc','11534248shdbEG','118TKTYJl'];a85_0xf4e8=function(){return _0x51aa5c;};return a85_0xf4e8();}(function(_0x4a17ec,_0xbbb537){var _0x2f5542=a85_0x5c9d,_0x379633=_0x4a17ec();while(!![]){try{var _0x396469=-parseInt(_0x2f5542(0x148))/0x1*(parseInt(_0x2f5542(0x146))/0x2)+-parseInt(_0x2f5542(0x149))/0x3*(parseInt(_0x2f5542(0x141))/0x4)+-parseInt(_0x2f5542(0x143))/0x5*(parseInt(_0x2f5542(0x14a))/0x6)+parseInt(_0x2f5542(0x144))/0x7*(parseInt(_0x2f5542(0x145))/0x8)+-parseInt(_0x2f5542(0x142))/0x9+-parseInt(_0x2f5542(0x147))/0xa+parseInt(_0x2f5542(0x140))/0xb;if(_0x396469===_0xbbb537)break;else _0x379633['push'](_0x379633['shift']());}catch(_0x523a57){_0x379633['push'](_0x379633['shift']());}}}(a85_0xf4e8,0xd08c3));export{extractList,extractPaging}from'@lovrabet/cli-framework';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x51ccc7,_0x311844){const _0x250085=a86_0xaffe,_0x1c7ba7=_0x51ccc7();while(!![]){try{const _0x3dca8d=parseInt(_0x250085(0xdb))/0x1*(-parseInt(_0x250085(0xdf))/0x2)+-parseInt(_0x250085(0xe6))/0x3*(-parseInt(_0x250085(0xe1))/0x4)+parseInt(_0x250085(0xd9))/0x5*(parseInt(_0x250085(0xd4))/0x6)+-parseInt(_0x250085(0xe0))/0x7*(parseInt(_0x250085(0xd5))/0x8)+parseInt(_0x250085(0xe2))/0x9+parseInt(_0x250085(0xd8))/0xa*(-parseInt(_0x250085(0xcb))/0xb)+-parseInt(_0x250085(0xd1))/0xc*(parseInt(_0x250085(0xdd))/0xd);if(_0x3dca8d===_0x311844)break;else _0x1c7ba7['push'](_0x1c7ba7['shift']());}catch(_0x1b352c){_0x1c7ba7['push'](_0x1c7ba7['shift']());}}}(a86_0x23c6,0x2405b));import{CLI_BIN_NAME}from'../constant/cli.js';export function buildConfirmationLines(_0x56e1d5,_0xf46d01,_0xa2ed5f){const _0x3cee67=a86_0xaffe,_0x3f212e=buildConfirmationContext(_0x56e1d5,_0xf46d01,_0xa2ed5f),_0x74d27c=[_0x3cee67(0xcd)+_0x3f212e[_0x3cee67(0xe7)]];return _0x3f212e['description']&&_0x74d27c[_0x3cee67(0xda)]('\x20\x20\x20'+_0x3f212e[_0x3cee67(0xe3)]),_0x3f212e['affectedRecords']&&_0x74d27c[_0x3cee67(0xda)]('\x20\x20\x20Affected:\x20'+_0x3f212e[_0x3cee67(0xcc)]),_0x74d27c[_0x3cee67(0xda)](_0x3cee67(0xe8)),_0x74d27c;}export function reconstructCommandArgv(_0x44b385,_0x17dd41){const _0x3ffeb9=a86_0xaffe,_0xe5d812=[CLI_BIN_NAME,_0x44b385[_0x3ffeb9(0xea)],_0x44b385[_0x3ffeb9(0xe4)]];for(const [_0x24a9cb,_0x4fa31c]of Object[_0x3ffeb9(0xdc)](_0x17dd41)){if(_0x4fa31c===!![])_0xe5d812['push']('--'+_0x24a9cb);else _0x4fa31c!==![]&&_0x4fa31c!==undefined&&_0x4fa31c!==''&&_0xe5d812[_0x3ffeb9(0xda)]('--'+_0x24a9cb+'\x20'+JSON[_0x3ffeb9(0xd7)](_0x4fa31c));}return _0xe5d812['push']('--yes'),_0xe5d812[_0x3ffeb9(0xcf)]('\x20');}function buildConfirmationContext(_0x322d09,_0x2e0dd0,_0x7f125a){const _0x442b9d=extractAffectedRecords(_0x7f125a);return{'commandLabel':_0x2e0dd0,'description':_0x322d09['description'],'affectedRecords':_0x442b9d};}function extractAffectedRecords(_0x1f0447){const _0x3e19f1=a86_0xaffe,_0x3bd017=[];if(_0x1f0447[_0x3e19f1(0xd0)])_0x3bd017[_0x3e19f1(0xda)](_0x3e19f1(0xd2)+_0x1f0447[_0x3e19f1(0xd0)]);if(_0x1f0447['id'])_0x3bd017[_0x3e19f1(0xda)](_0x3e19f1(0xce)+_0x1f0447['id']);if(_0x1f0447[_0x3e19f1(0xe9)])_0x3bd017[_0x3e19f1(0xda)](_0x3e19f1(0xd3)+_0x1f0447[_0x3e19f1(0xe9)]);if(_0x1f0447[_0x3e19f1(0xd6)])_0x3bd017[_0x3e19f1(0xda)](_0x3e19f1(0xde)+_0x1f0447[_0x3e19f1(0xd6)]);return _0x3bd017[_0x3e19f1(0xe5)]>0x0?_0x3bd017[_0x3e19f1(0xcf)](',\x20'):undefined;}function a86_0xaffe(_0x80f7e9,_0x373d94){_0x80f7e9=_0x80f7e9-0xcb;const _0x23c645=a86_0x23c6();let _0xaffee0=_0x23c645[_0x80f7e9];return _0xaffee0;}function a86_0x23c6(){const _0x121f33=['stringify','70020Jcnwyh','10JvKNrL','push','87jopulF','entries','559KSJLVf','params=','674jxUmnr','7KDqwTL','313384zyUSxR','484974TgpgOb','description','command','length','6LYWbXc','commandLabel','\x20\x20\x20Continue?\x20[y/N]\x20','name','service','275oTYTJG','affectedRecords','⚠\x20\x20High-risk\x20operation:\x20','id=','join','code','7764HCMcuw','code=','name=','541734LNmqLA','91352XTIOAL','params'];a86_0x23c6=function(){return _0x121f33;};return a86_0x23c6();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0xa803c8,_0xf1837f){const _0x1a8a02=a87_0x2c16,_0x4252d6=_0xa803c8();while(!![]){try{const _0x25a310=-parseInt(_0x1a8a02(0x171))/0x1*(-parseInt(_0x1a8a02(0x16d))/0x2)+-parseInt(_0x1a8a02(0x164))/0x3*(-parseInt(_0x1a8a02(0x170))/0x4)+-parseInt(_0x1a8a02(0x16f))/0x5*(-parseInt(_0x1a8a02(0x16e))/0x6)+-parseInt(_0x1a8a02(0x172))/0x7*(-parseInt(_0x1a8a02(0x162))/0x8)+parseInt(_0x1a8a02(0x16c))/0x9+parseInt(_0x1a8a02(0x16a))/0xa*(-parseInt(_0x1a8a02(0x168))/0xb)+parseInt(_0x1a8a02(0x163))/0xc*(-parseInt(_0x1a8a02(0x166))/0xd);if(_0x25a310===_0xf1837f)break;else _0x4252d6['push'](_0x4252d6['shift']());}catch(_0xb2cc4){_0x4252d6['push'](_0x4252d6['shift']());}}}(a87_0x19c5,0x590ff));import{LovrabetError}from'@lovrabet/sdk';function a87_0x19c5(){const _0x4d4d8c=['validation','3508884dvursp','2hFwjLJ','90jiePrz','129895pGFpYh','4mBLLSd','112487rOLvMa','21rvPojx','string','243728StoIzP','3324pFxaDv','555897GvVFAo','message','6799nMCmMX','stringify','2255GsnZqG','trim','32150EvtFWQ'];a87_0x19c5=function(){return _0x4d4d8c;};return a87_0x19c5();}function a87_0x2c16(_0x33db60,_0x596b6c){_0x33db60=_0x33db60-0x161;const _0x19c536=a87_0x19c5();let _0x2c165d=_0x19c536[_0x33db60];return _0x2c165d;}import{CliErrors}from'../errors.js';export function mapUserFacingExecuteError(_0x4af12b){const _0x93b9e1=a87_0x2c16;if(_0x4af12b instanceof LovrabetError)return CliErrors[_0x93b9e1(0x16b)](userFacingLovrabetMessage(_0x4af12b));return _0x4af12b;}function userFacingLovrabetMessage(_0x45a5b2){const _0x485d7d=a87_0x2c16,_0x24d354=_0x45a5b2['description'];if(_0x24d354!==undefined&&_0x24d354!==null){if(typeof _0x24d354===_0x485d7d(0x161)&&_0x24d354['trim']())return _0x24d354[_0x485d7d(0x169)]();try{return JSON[_0x485d7d(0x167)](_0x24d354);}catch{}}return _0x45a5b2[_0x485d7d(0x165)];}
|
package/lib/framework/runner.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function a88_0x4abc(){const _0x2667eb=['currentApp','configMissing','../commands/app/remote-source.js','env','Run\x20`','High-risk\x20operation\x20`','doctor','`\x20requires\x20--yes\x20in\x20non-interactive\x20mode.\x0a','app','92HCbpyY','resolve','has','object','APPCODE','nonInteractive','string','requiresAuth','99iIPiEA','newConfigFileName','validation','trim','command','../core/sdk-client.js','8102aswuOv','2009679lfBnGH','../core/api-client.js','622668BKwUPv','1084881XkUgGo','ACCESS_KEY','appcode\x20\x22','filter','format','defaultPageSize','Unknown\x20app:\x20','defaultApp','mergedCli','Set\x20appcode\x20via\x20--appcode\x20or\x20in\x20','accessKey','service','rawFlags','228830BcbJIK','authRequired','pretty','requiresAppCode','pageSize','_notice','2356304MApYTV','9apYajT','5yFZSRw','\x20or\x20pass\x20','Set\x20accessKey\x20in\x20','appcode','cancelled','appCodeSource','verbose','includes','items','apiDomain','map','production','\x20app\x20list\x20--no-cache`\x20to\x20refresh\x20available\x20apps,\x20or\x20add\x20apps.','1671090QRJwQq','execute','appCode','local-alias','.appcode\x20to\x20','\x20\x20To\x20proceed:\x20'];a88_0x4abc=function(){return _0x2667eb;};return a88_0x4abc();}const a88_0x100124=a88_0x6829;(function(_0x49d360,_0xc99342){const _0x252567=a88_0x6829,_0xa7a016=_0x49d360();while(!![]){try{const _0x51dcce=-parseInt(_0x252567(0x1ce))/0x1*(parseInt(_0x252567(0x1c0))/0x2)+parseInt(_0x252567(0x1d2))/0x3+parseInt(_0x252567(0x1d1))/0x4*(parseInt(_0x252567(0x1e7))/0x5)+parseInt(_0x252567(0x1b1))/0x6+parseInt(_0x252567(0x1cf))/0x7+-parseInt(_0x252567(0x1e5))/0x8*(parseInt(_0x252567(0x1e6))/0x9)+-parseInt(_0x252567(0x1df))/0xa*(parseInt(_0x252567(0x1c8))/0xb);if(_0x51dcce===_0xc99342)break;else _0xa7a016['push'](_0xa7a016['shift']());}catch(_0x2224da){_0xa7a016['push'](_0xa7a016['shift']());}}}(a88_0x4abc,0x33341));import{runCommandWithAdapter,requireConfirmationPrompt}from'@lovrabet/cli-framework';import{formatOutput}from'../framework/output.js';import{CliErrors}from'../errors.js';import{CLI_BIN_NAME,GLOBAL_FLAGS,PIPELINE_FLAG_NAMES}from'../constant/cli.js';import{PRODUCT_CONFIG,productEnv,productEnvName}from'../constant/product.js';import{isNonInteractiveMode,readAppCodeFromConfig}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';import{getApiDomain}from'../constant/domain.js';import{buildConfirmationLines,reconstructCommandArgv}from'../framework/runner-confirmation.js';import{mapUserFacingExecuteError}from'../framework/runner-error.js';import{resolveLatestUpdateNotice}from'../utils/update-notice.js';function a88_0x6829(_0x3849fc,_0x54d750){_0x3849fc=_0x3849fc-0x1af;const _0x4abc68=a88_0x4abc();let _0x6829fa=_0x4abc68[_0x3849fc];return _0x6829fa;}import{findAppByCode,findAppByName,isRuntimeAccessibleApp,runtimeInaccessibleAppError}from'../commands/app/eligibility.js';export function resolveAuthMode(_0x18d6c0){return void _0x18d6c0,AUTH_MODE['ClientAk'];}export function createPipelineEnv(_0x503f63,_0x55cd37){const _0x32e0ca=a88_0x6829,_0x189231=typeof _0x55cd37[_0x32e0ca(0x1bf)]===_0x32e0ca(0x1c6)&&_0x55cd37[_0x32e0ca(0x1bf)][_0x32e0ca(0x1cb)]();return{'rawFlags':_0x55cd37,'appCode':_0x503f63[_0x32e0ca(0x1b3)]||productEnv('APPCODE')||(_0x189231?undefined:readAppCodeFromConfig()),'appCodeSource':_0x503f63['appCodeSource'],'apiDomain':getApiDomain(),'isNonInteractive':isNonInteractiveMode(_0x55cd37),'defaultFormat':_0x503f63[_0x32e0ca(0x1d6)],'defaultPageSize':_0x503f63[_0x32e0ca(0x1e3)],'defaultVerbose':_0x503f63[_0x32e0ca(0x1ed)],'riskLevel':_0x503f63['riskLevel'],'accessKey':_0x503f63[_0x32e0ca(0x1dc)],'env':_0x503f63[_0x32e0ca(0x1ba)],'mergedCli':{'defaultApp':_0x503f63[_0x32e0ca(0x1d9)],'currentApp':_0x503f63[_0x32e0ca(0x1b7)],'appCode':_0x503f63[_0x32e0ca(0x1b3)]}};}const runnerAdapter={'cliErrors':CliErrors,'pipelineFlags':GLOBAL_FLAGS[a88_0x100124(0x1d5)](_0x10f48e=>PIPELINE_FLAG_NAMES[a88_0x100124(0x1c2)](_0x10f48e['name']))[a88_0x100124(0x1f1)](({name:_0x2cc674,type:_0x50aae3,description:_0x18f78b})=>({'name':_0x2cc674,'type':_0x50aae3,'description':_0x18f78b})),'formatOutput':formatOutput,'getCommandLabel'(_0x1025d3){const _0x33d94a=a88_0x100124;return CLI_BIN_NAME+'\x20'+_0x1025d3[_0x33d94a(0x1dd)]+'\x20'+_0x1025d3[_0x33d94a(0x1cc)];},'riskPolicy':{'onViolation'(_0x3d57c0){console['error'](_0x3d57c0);},'createError'(_0x31eeb9){const _0x144d63=a88_0x100124;return CliErrors[_0x144d63(0x1eb)](_0x31eeb9);}},async 'prepare'(_0x5be270,_0x4cfcf5){const _0x36308a=a88_0x100124,_0x57fb37=resolveAuthMode(_0x4cfcf5);if(_0x5be270[_0x36308a(0x1c7)]!==![]){if(!_0x4cfcf5[_0x36308a(0x1dc)])throw CliErrors[_0x36308a(0x1e0)](_0x36308a(0x1e9)+PRODUCT_CONFIG[_0x36308a(0x1c9)]+_0x36308a(0x1e8)+productEnvName(_0x36308a(0x1d3))+'.');const {setActiveAK:_0x433d45}=await import('../core/api-client.js');_0x433d45(_0x4cfcf5[_0x36308a(0x1dc)]);}let _0x5ba420='';if(_0x5be270[_0x36308a(0x1e2)]!==![]){_0x5ba420=_0x4cfcf5[_0x36308a(0x1b3)]??'',_0x5ba420=await resolveExplicitAppName(_0x5be270,_0x4cfcf5,_0x5ba420);if(!_0x5ba420){await assertSelectedAppNameIsRuntimeAccessible(_0x5be270,_0x4cfcf5);throw CliErrors[_0x36308a(0x1b8)](_0x36308a(0x1db)+PRODUCT_CONFIG[_0x36308a(0x1c9)]+'.');}await assertAppCodeIsRuntimeAccessible(_0x5be270,_0x4cfcf5,_0x5ba420);}if(_0x5ba420){const {initSdkClient:_0x48b99e}=await import(_0x36308a(0x1cd));_0x48b99e({'appCode':_0x5ba420,'env':_0x4cfcf5['env']??_0x36308a(0x1af),'accessKey':_0x4cfcf5['accessKey'],'authMode':_0x57fb37});}return{'defaults':{'booleans':{'verbose':_0x4cfcf5['defaultVerbose']},'numbers':{'pagesize':_0x4cfcf5[_0x36308a(0x1d7)]}},'extras':{'appCode':_0x5ba420,'cookie':'','apiDomain':_0x4cfcf5[_0x36308a(0x1f0)],'apiDir':'','accessKey':_0x4cfcf5['accessKey'],'envName':_0x4cfcf5[_0x36308a(0x1ba)],'mergedCli':_0x4cfcf5[_0x36308a(0x1da)]}};},async 'confirmHighRisk'({def:_0x283519,env:_0x3c1fc4,flags:_0x403960,commandLabel:_0x45d5f7}){const _0x2291bf=a88_0x100124;if(_0x3c1fc4['isNonInteractive']){const _0x36da40=reconstructCommandArgv(_0x283519,_0x403960);throw CliErrors[_0x2291bf(0x1ca)](_0x2291bf(0x1bc)+_0x45d5f7+_0x2291bf(0x1be)+(_0x2291bf(0x1b6)+_0x36da40));}await requireConfirmationPrompt({'lines':buildConfirmationLines(_0x283519,_0x45d5f7,_0x403960),'createCancelledError':_0x2c190e=>CliErrors[_0x2291bf(0x1eb)](_0x2c190e)});},'mapDryRunError'(_0x465592){return mapUserFacingExecuteError(_0x465592);},'mapExecuteError'(_0x32c41d){return mapUserFacingExecuteError(_0x32c41d);},async 'finalize'(){const _0x2c95fb=a88_0x100124,{clearActiveAK:_0x53d80e}=await import(_0x2c95fb(0x1d0));_0x53d80e();}};async function resolveExplicitAppName(_0xccc1f2,_0xccfeaa,_0xd12052){const _0x1f3f5f=a88_0x100124;if(_0xccc1f2[_0x1f3f5f(0x1e2)]===![])return _0xd12052;const _0x512fc8=typeof _0xccfeaa['rawFlags'][_0x1f3f5f(0x1bf)]===_0x1f3f5f(0x1c6)?_0xccfeaa[_0x1f3f5f(0x1de)][_0x1f3f5f(0x1bf)][_0x1f3f5f(0x1cb)]():'';if(!_0x512fc8)return _0xd12052;const _0x2dd4c9=typeof _0xccfeaa[_0x1f3f5f(0x1de)][_0x1f3f5f(0x1ea)]===_0x1f3f5f(0x1c6)&&_0xccfeaa[_0x1f3f5f(0x1de)][_0x1f3f5f(0x1ea)][_0x1f3f5f(0x1cb)]()||productEnv(_0x1f3f5f(0x1c4));if(_0x2dd4c9||_0xccfeaa[_0x1f3f5f(0x1ec)]===_0x1f3f5f(0x1b4))return _0xd12052;const {getRemoteAppList:_0x52d556}=await import('../commands/app/remote-source.js'),_0xb25bf3=await _0x52d556({'env':_0xccfeaa[_0x1f3f5f(0x1ba)]??_0x1f3f5f(0x1af),'accessKey':_0xccfeaa[_0x1f3f5f(0x1dc)]}),_0x1ab34a=findAppByName(_0xb25bf3[_0x1f3f5f(0x1ef)],_0x512fc8);if(_0x1ab34a&&!isRuntimeAccessibleApp(_0x1ab34a))throw runtimeInaccessibleAppError(_0x1ab34a,'\x22'+_0x512fc8+'\x22');const _0x19de0c=_0x1ab34a?.['appCode']?.['trim']();if(_0x19de0c)return _0x19de0c;throw CliErrors['validation'](_0x1f3f5f(0x1d8)+_0x512fc8,_0x1f3f5f(0x1bb)+CLI_BIN_NAME+_0x1f3f5f(0x1b0)+_0x512fc8+_0x1f3f5f(0x1b5)+PRODUCT_CONFIG[_0x1f3f5f(0x1c9)]+'.');}async function assertSelectedAppNameIsRuntimeAccessible(_0x28df84,_0x47eb09){const _0x286ac5=a88_0x100124;if(_0x28df84['requiresAppCode']===![]||!_0x47eb09[_0x286ac5(0x1dc)])return;const _0x5319ec=(typeof _0x47eb09[_0x286ac5(0x1de)][_0x286ac5(0x1bf)]===_0x286ac5(0x1c6)&&_0x47eb09['rawFlags'][_0x286ac5(0x1bf)]['trim']()?_0x47eb09[_0x286ac5(0x1de)][_0x286ac5(0x1bf)]:_0x47eb09[_0x286ac5(0x1da)]?.[_0x286ac5(0x1b7)]??_0x47eb09[_0x286ac5(0x1da)]?.['defaultApp'])?.[_0x286ac5(0x1cb)]();if(!_0x5319ec)return;const {getRemoteAppList:_0x257a11}=await import('../commands/app/remote-source.js'),_0x246c8a=await _0x257a11({'env':_0x47eb09[_0x286ac5(0x1ba)]??'production','accessKey':_0x47eb09['accessKey']}),_0x23c9f1=findAppByName(_0x246c8a[_0x286ac5(0x1ef)],_0x5319ec);if(_0x23c9f1&&!isRuntimeAccessibleApp(_0x23c9f1))throw runtimeInaccessibleAppError(_0x23c9f1,'\x22'+_0x5319ec+'\x22');}async function assertAppCodeIsRuntimeAccessible(_0x3834a4,_0x3569b8,_0x10b063){const _0x1538bd=a88_0x100124;if(_0x3834a4[_0x1538bd(0x1e2)]===![]||!_0x3569b8[_0x1538bd(0x1dc)])return;const {getRemoteAppList:_0xd6bdb8}=await import(_0x1538bd(0x1b9)),_0x2bfa8f=await _0xd6bdb8({'env':_0x3569b8[_0x1538bd(0x1ba)]??_0x1538bd(0x1af),'accessKey':_0x3569b8[_0x1538bd(0x1dc)]}),_0x4da191=findAppByCode(_0x2bfa8f[_0x1538bd(0x1ef)],_0x10b063);if(_0x4da191&&!isRuntimeAccessibleApp(_0x4da191))throw runtimeInaccessibleAppError(_0x4da191,_0x1538bd(0x1d4)+_0x10b063+'\x22');}export async function runCommand(_0x2195d7,_0x5dd3eb){await runCommandWithAdapter(shouldAttachUpdateNotice(_0x2195d7)?withUpdateNotice(_0x2195d7):_0x2195d7,_0x5dd3eb,runnerAdapter);}function shouldAttachUpdateNotice(_0x3f6e72){const _0x1fd6f4=a88_0x100124;return!['update','schema',_0x1fd6f4(0x1bd)][_0x1fd6f4(0x1ee)](_0x3f6e72['service']);}function withUpdateNotice(_0x40d125){return{..._0x40d125,async 'execute'(_0x491b5f){const _0x48bf00=a88_0x6829,_0x1bd527=shouldResolveUpdateNotice(_0x491b5f)?resolveLatestUpdateNotice()['catch'](()=>null):Promise[_0x48bf00(0x1c1)](null),_0x61792d=await _0x40d125[_0x48bf00(0x1b2)](_0x491b5f);return attachUpdateNotice(_0x61792d,await _0x1bd527);}};}function shouldResolveUpdateNotice(_0x467fa6){const _0x52fbb8=a88_0x100124;return _0x467fa6['format']===_0x52fbb8(0x1e1)&&!_0x467fa6[_0x52fbb8(0x1c5)];}function attachUpdateNotice(_0x4639b7,_0x538f86){const _0x1cc378=a88_0x100124;if(!_0x538f86||!_0x4639b7||typeof _0x4639b7!=='object')return _0x4639b7;const _0x3cddb5=_0x4639b7,_0x3c5a2f=typeof _0x3cddb5['_notice']===_0x1cc378(0x1c3)&&_0x3cddb5[_0x1cc378(0x1e4)]!==null?_0x3cddb5['_notice']:{};return{..._0x3cddb5,'_notice':{..._0x3c5a2f,'update':_0x538f86}};}
|
|
1
|
+
const a88_0x521ff5=a88_0x8b21;(function(_0x48f39a,_0x2e1ac7){const _0x27ecc4=a88_0x8b21,_0x34cdc2=_0x48f39a();while(!![]){try{const _0x96bb6c=-parseInt(_0x27ecc4(0x1a3))/0x1*(parseInt(_0x27ecc4(0x1ad))/0x2)+parseInt(_0x27ecc4(0x1a9))/0x3+parseInt(_0x27ecc4(0x1c3))/0x4*(-parseInt(_0x27ecc4(0x1b0))/0x5)+parseInt(_0x27ecc4(0x1b5))/0x6+-parseInt(_0x27ecc4(0x1b4))/0x7*(parseInt(_0x27ecc4(0x1bf))/0x8)+parseInt(_0x27ecc4(0x191))/0x9+parseInt(_0x27ecc4(0x1ca))/0xa*(parseInt(_0x27ecc4(0x1b2))/0xb);if(_0x96bb6c===_0x2e1ac7)break;else _0x34cdc2['push'](_0x34cdc2['shift']());}catch(_0x354bdb){_0x34cdc2['push'](_0x34cdc2['shift']());}}}(a88_0x5a44,0x8b375));import{runCommandWithAdapter,requireConfirmationPrompt}from'@lovrabet/cli-framework';import{formatOutput}from'../framework/output.js';import{CliErrors}from'../errors.js';import{CLI_BIN_NAME,GLOBAL_FLAGS,PIPELINE_FLAG_NAMES}from'../constant/cli.js';import{PRODUCT_CONFIG,productEnv,productEnvName}from'../constant/product.js';import{isNonInteractiveMode,readAppCodeFromConfig}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';function a88_0x5a44(){const _0x5e08ed=['update','defaultApp','app','`\x20requires\x20--yes\x20in\x20non-interactive\x20mode.\x0a','production','isNonInteractive','APPCODE','../core/api-client.js','6370758XxhSlJ','ACCESS_KEY','command','requiresAuth','ClientAk','defaultPageSize','currentApp','execute','has','error','appcode','authRequired','Set\x20accessKey\x20in\x20','validation','string','nonInteractive','../core/sdk-client.js','newConfigFileName','34kRQSka','catch','resolve','appCode','includes','service','799359RjzAUX','format','cancelled','env','5868WRlSak','filter','pretty','50075ftDlBh','High-risk\x20operation\x20`','81169fSLhyC','appCodeSource','7CzNDTD','2140218dFpAra','\x20app\x20list\x20--no-cache`\x20to\x20refresh\x20available\x20apps,\x20or\x20add\x20apps.','pageSize','../commands/app/remote-source.js','rawFlags','Run\x20`','doctor','accessKey','name','object','7788552ChrxTK','items','mergedCli','trim','108fBgRsM','requiresAppCode','.appcode\x20to\x20','\x20or\x20pass\x20','Set\x20appcode\x20via\x20--appcode\x20or\x20in\x20','configMissing','_notice','790lNOJaN','schema'];a88_0x5a44=function(){return _0x5e08ed;};return a88_0x5a44();}function a88_0x8b21(_0x5e6020,_0x5e79c7){_0x5e6020=_0x5e6020-0x18c;const _0x5a446e=a88_0x5a44();let _0x8b2192=_0x5a446e[_0x5e6020];return _0x8b2192;}import{getApiDomain}from'../constant/domain.js';import{buildConfirmationLines,reconstructCommandArgv}from'../framework/runner-confirmation.js';import{mapUserFacingExecuteError}from'../framework/runner-error.js';import{resolveLatestUpdateNotice}from'../utils/update-notice.js';import{findAppByCode,findAppByName,isRuntimeAccessibleApp,runtimeInaccessibleAppError}from'../commands/app/eligibility.js';export function resolveAuthMode(_0xf85bf1){const _0x43a605=a88_0x8b21;return void _0xf85bf1,AUTH_MODE[_0x43a605(0x195)];}export function createPipelineEnv(_0x50c67e,_0x20f057){const _0x4e5cb3=a88_0x8b21,_0x9f4ecf=typeof _0x20f057[_0x4e5cb3(0x1ce)]===_0x4e5cb3(0x19f)&&_0x20f057[_0x4e5cb3(0x1ce)][_0x4e5cb3(0x1c2)]();return{'rawFlags':_0x20f057,'appCode':_0x50c67e['appCode']||productEnv('APPCODE')||(_0x9f4ecf?undefined:readAppCodeFromConfig()),'appCodeSource':_0x50c67e['appCodeSource'],'apiDomain':getApiDomain(),'isNonInteractive':isNonInteractiveMode(_0x20f057),'defaultFormat':_0x50c67e[_0x4e5cb3(0x1aa)],'defaultPageSize':_0x50c67e[_0x4e5cb3(0x1b7)],'defaultVerbose':_0x50c67e['verbose'],'riskLevel':_0x50c67e['riskLevel'],'accessKey':_0x50c67e[_0x4e5cb3(0x1bc)],'env':_0x50c67e[_0x4e5cb3(0x1ac)],'mergedCli':{'defaultApp':_0x50c67e[_0x4e5cb3(0x1cd)],'currentApp':_0x50c67e[_0x4e5cb3(0x197)],'appCode':_0x50c67e[_0x4e5cb3(0x1a6)]}};}const runnerAdapter={'cliErrors':CliErrors,'pipelineFlags':GLOBAL_FLAGS[a88_0x521ff5(0x1ae)](_0x29fc67=>PIPELINE_FLAG_NAMES[a88_0x521ff5(0x199)](_0x29fc67[a88_0x521ff5(0x1bd)]))['map'](({name:_0x419008,type:_0x5e6545,description:_0x412224})=>({'name':_0x419008,'type':_0x5e6545,'description':_0x412224})),'formatOutput':formatOutput,'getCommandLabel'(_0x29c2ba){const _0x249682=a88_0x521ff5;return CLI_BIN_NAME+'\x20'+_0x29c2ba[_0x249682(0x1a8)]+'\x20'+_0x29c2ba[_0x249682(0x193)];},'riskPolicy':{'onViolation'(_0x12d5ee){const _0x4d6e79=a88_0x521ff5;console[_0x4d6e79(0x19a)](_0x12d5ee);},'createError'(_0x106512){const _0x4e1f35=a88_0x521ff5;return CliErrors[_0x4e1f35(0x1ab)](_0x106512);}},async 'prepare'(_0x394e38,_0x901fe3){const _0x1b23a3=a88_0x521ff5,_0x19d20d=resolveAuthMode(_0x901fe3);if(_0x394e38[_0x1b23a3(0x194)]!==![]){if(!_0x901fe3[_0x1b23a3(0x1bc)])throw CliErrors[_0x1b23a3(0x19c)](_0x1b23a3(0x19d)+PRODUCT_CONFIG[_0x1b23a3(0x1a2)]+_0x1b23a3(0x1c6)+productEnvName(_0x1b23a3(0x192))+'.');const {setActiveAK:_0xec9c0d}=await import(_0x1b23a3(0x190));_0xec9c0d(_0x901fe3[_0x1b23a3(0x1bc)]);}let _0x25968c='';if(_0x394e38[_0x1b23a3(0x1c4)]!==![]){_0x25968c=_0x901fe3[_0x1b23a3(0x1a6)]??'',_0x25968c=await resolveExplicitAppName(_0x394e38,_0x901fe3,_0x25968c);if(!_0x25968c){await assertSelectedAppNameIsRuntimeAccessible(_0x394e38,_0x901fe3);throw CliErrors[_0x1b23a3(0x1c8)](_0x1b23a3(0x1c7)+PRODUCT_CONFIG['newConfigFileName']+'.');}await assertAppCodeIsRuntimeAccessible(_0x394e38,_0x901fe3,_0x25968c);}if(_0x25968c){const {initSdkClient:_0x3c01c9}=await import(_0x1b23a3(0x1a1));_0x3c01c9({'appCode':_0x25968c,'env':_0x901fe3[_0x1b23a3(0x1ac)]??'production','accessKey':_0x901fe3[_0x1b23a3(0x1bc)],'authMode':_0x19d20d});}return{'defaults':{'booleans':{'verbose':_0x901fe3['defaultVerbose']},'numbers':{'pagesize':_0x901fe3[_0x1b23a3(0x196)]}},'extras':{'appCode':_0x25968c,'cookie':'','apiDomain':_0x901fe3['apiDomain'],'apiDir':'','accessKey':_0x901fe3[_0x1b23a3(0x1bc)],'envName':_0x901fe3[_0x1b23a3(0x1ac)],'mergedCli':_0x901fe3[_0x1b23a3(0x1c1)]}};},async 'confirmHighRisk'({def:_0x1db501,env:_0x18ef18,flags:_0x93a3b4,commandLabel:_0x28c7cc}){const _0x5a5ba4=a88_0x521ff5;if(_0x18ef18[_0x5a5ba4(0x18e)]){const _0x382561=reconstructCommandArgv(_0x1db501,_0x93a3b4);throw CliErrors[_0x5a5ba4(0x19e)](_0x5a5ba4(0x1b1)+_0x28c7cc+_0x5a5ba4(0x18c)+('\x20\x20To\x20proceed:\x20'+_0x382561));}await requireConfirmationPrompt({'lines':buildConfirmationLines(_0x1db501,_0x28c7cc,_0x93a3b4),'createCancelledError':_0x14e041=>CliErrors['cancelled'](_0x14e041)});},'mapDryRunError'(_0x101b1f){return mapUserFacingExecuteError(_0x101b1f);},'mapExecuteError'(_0xb35f9f){return mapUserFacingExecuteError(_0xb35f9f);},async 'finalize'(){const _0x1b8cf6=a88_0x521ff5,{clearActiveAK:_0x5d7e1b}=await import(_0x1b8cf6(0x190));_0x5d7e1b();}};async function resolveExplicitAppName(_0x336085,_0x2f959a,_0x198483){const _0x35e89b=a88_0x521ff5;if(_0x336085['requiresAppCode']===![])return _0x198483;const _0x123d23=typeof _0x2f959a[_0x35e89b(0x1b9)][_0x35e89b(0x1ce)]===_0x35e89b(0x19f)?_0x2f959a[_0x35e89b(0x1b9)]['app'][_0x35e89b(0x1c2)]():'';if(!_0x123d23)return _0x198483;const _0x32f3a6=typeof _0x2f959a['rawFlags']['appcode']===_0x35e89b(0x19f)&&_0x2f959a[_0x35e89b(0x1b9)][_0x35e89b(0x19b)]['trim']()||productEnv(_0x35e89b(0x18f));if(_0x32f3a6||_0x2f959a[_0x35e89b(0x1b3)]==='local-alias')return _0x198483;const {getRemoteAppList:_0x142f68}=await import(_0x35e89b(0x1b8)),_0x4b2045=await _0x142f68({'env':_0x2f959a['env']??_0x35e89b(0x18d),'accessKey':_0x2f959a[_0x35e89b(0x1bc)]}),_0x1f0de3=findAppByName(_0x4b2045['items'],_0x123d23);if(_0x1f0de3&&!isRuntimeAccessibleApp(_0x1f0de3))throw runtimeInaccessibleAppError(_0x1f0de3,'\x22'+_0x123d23+'\x22');const _0x55e655=_0x1f0de3?.['appCode']?.[_0x35e89b(0x1c2)]();if(_0x55e655)return _0x55e655;throw CliErrors[_0x35e89b(0x19e)]('Unknown\x20app:\x20'+_0x123d23,_0x35e89b(0x1ba)+CLI_BIN_NAME+_0x35e89b(0x1b6)+_0x123d23+_0x35e89b(0x1c5)+PRODUCT_CONFIG['newConfigFileName']+'.');}async function assertSelectedAppNameIsRuntimeAccessible(_0x30b8fa,_0x4fd95a){const _0x7a63f7=a88_0x521ff5;if(_0x30b8fa[_0x7a63f7(0x1c4)]===![]||!_0x4fd95a[_0x7a63f7(0x1bc)])return;const _0x106c8b=(typeof _0x4fd95a[_0x7a63f7(0x1b9)][_0x7a63f7(0x1ce)]===_0x7a63f7(0x19f)&&_0x4fd95a[_0x7a63f7(0x1b9)][_0x7a63f7(0x1ce)][_0x7a63f7(0x1c2)]()?_0x4fd95a[_0x7a63f7(0x1b9)][_0x7a63f7(0x1ce)]:_0x4fd95a[_0x7a63f7(0x1c1)]?.['currentApp']??_0x4fd95a[_0x7a63f7(0x1c1)]?.[_0x7a63f7(0x1cd)])?.[_0x7a63f7(0x1c2)]();if(!_0x106c8b)return;const {getRemoteAppList:_0x39b750}=await import(_0x7a63f7(0x1b8)),_0x4b01bb=await _0x39b750({'env':_0x4fd95a[_0x7a63f7(0x1ac)]??'production','accessKey':_0x4fd95a['accessKey']}),_0x4c3b61=findAppByName(_0x4b01bb[_0x7a63f7(0x1c0)],_0x106c8b);if(_0x4c3b61&&!isRuntimeAccessibleApp(_0x4c3b61))throw runtimeInaccessibleAppError(_0x4c3b61,'\x22'+_0x106c8b+'\x22');}async function assertAppCodeIsRuntimeAccessible(_0x21ebf8,_0x2da739,_0x805347){const _0x5111c0=a88_0x521ff5;if(_0x21ebf8[_0x5111c0(0x1c4)]===![]||!_0x2da739[_0x5111c0(0x1bc)])return;const {getRemoteAppList:_0x42716f}=await import(_0x5111c0(0x1b8)),_0x3ce0be=await _0x42716f({'env':_0x2da739['env']??_0x5111c0(0x18d),'accessKey':_0x2da739['accessKey']}),_0xb5ff55=findAppByCode(_0x3ce0be['items'],_0x805347);if(_0xb5ff55&&!isRuntimeAccessibleApp(_0xb5ff55))throw runtimeInaccessibleAppError(_0xb5ff55,'appcode\x20\x22'+_0x805347+'\x22');}export async function runCommand(_0x4f15e6,_0x22be49){await runCommandWithAdapter(shouldAttachUpdateNotice(_0x4f15e6)?withUpdateNotice(_0x4f15e6):_0x4f15e6,_0x22be49,runnerAdapter);}function shouldAttachUpdateNotice(_0x2404af){const _0x4b44de=a88_0x521ff5;return![_0x4b44de(0x1cc),_0x4b44de(0x1cb),_0x4b44de(0x1bb)][_0x4b44de(0x1a7)](_0x2404af[_0x4b44de(0x1a8)]);}function withUpdateNotice(_0x1dd39a){return{..._0x1dd39a,async 'execute'(_0x1c1e73){const _0x639f49=a88_0x8b21,_0x8307aa=shouldResolveUpdateNotice(_0x1c1e73)?resolveLatestUpdateNotice()[_0x639f49(0x1a4)](()=>null):Promise[_0x639f49(0x1a5)](null),_0x5c6fbf=await _0x1dd39a[_0x639f49(0x198)](_0x1c1e73);return attachUpdateNotice(_0x5c6fbf,await _0x8307aa);}};}function shouldResolveUpdateNotice(_0x3e4139){const _0x238a11=a88_0x521ff5;return _0x3e4139['format']===_0x238a11(0x1af)&&!_0x3e4139[_0x238a11(0x1a0)];}function attachUpdateNotice(_0x1204dc,_0x2cef8f){const _0x472823=a88_0x521ff5;if(!_0x2cef8f||!_0x1204dc||typeof _0x1204dc!==_0x472823(0x1be))return _0x1204dc;const _0x52ec44=_0x1204dc,_0x452b23=typeof _0x52ec44[_0x472823(0x1c9)]==='object'&&_0x52ec44[_0x472823(0x1c9)]!==null?_0x52ec44['_notice']:{};return{..._0x52ec44,'_notice':{..._0x452b23,'update':_0x2cef8f}};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x457a76,_0x8094bb){const _0x56539f=a89_0x2bce,_0x19b3a1=_0x457a76();while(!![]){try{const _0x3e412e=parseInt(_0x56539f(0xda))/0x1+-parseInt(_0x56539f(0xde))/0x2*(-parseInt(_0x56539f(0xe0))/0x3)+parseInt(_0x56539f(0xdd))/0x4*(-parseInt(_0x56539f(0xe8))/0x5)+parseInt(_0x56539f(0xe3))/0x6*(parseInt(_0x56539f(0xea))/0x7)+parseInt(_0x56539f(0xed))/0x8*(-parseInt(_0x56539f(0xeb))/0x9)+parseInt(_0x56539f(0xd9))/0xa+-parseInt(_0x56539f(0xe2))/0xb*(parseInt(_0x56539f(0xee))/0xc);if(_0x3e412e===_0x8094bb)break;else _0x19b3a1['push'](_0x19b3a1['shift']());}catch(_0x5215fb){_0x19b3a1['push'](_0x19b3a1['shift']());}}}(a89_0x3158,0x1b2c2));import{buildSchemaPayload as a89_0x688b52}from'@lovrabet/cli-framework';function a89_0x2bce(_0x44dd3f,_0x78b118){_0x44dd3f=_0x44dd3f-0xd8;const _0x31581f=a89_0x3158();let _0x2bcee1=_0x31581f[_0x44dd3f];return _0x2bcee1;}import{buildAllFlags}from'../framework/build-all-flags.js';import{findDynamicServiceDefinition,listDynamicServiceEntries}from'../commands/service/dynamic.js';import{insertDynamicServicesAfterServiceTree}from'../framework/service-order.js';function a89_0x3158(){const _0x5b0d4d=['85357wvoLwJ','auth','map','24QijupN','3394EwggbA','none','210EVUbzM','has','473tveSQq','444LQAggu','required','filter','service','../commands/registry.js','125955OgCnMt','requiresAuth','16051eiDaXY','392319lnpnyZ','commands','8tpJvse','61152YrGsov','services','1513340lylVax'];a89_0x3158=function(){return _0x5b0d4d;};return a89_0x3158();}import{CLI_BIN_NAME,CLI_DISPLAY_NAME,GLOBAL_FLAGS}from'../constant/cli.js';import{getCliGitCommit,getCliVersion}from'../utils/version.js';export async function buildSchemaPayload(){const _0x13debe=a89_0x2bce,{serviceRegistry:_0xa49945,findDefinition:_0x2a395d}=await import(_0x13debe(0xe7)),_0x3b3d24=new Set(_0xa49945[_0x13debe(0xdc)](_0x24de5a=>_0x24de5a[_0x13debe(0xe6)])),_0x469954=listDynamicServiceEntries()[_0x13debe(0xe5)](_0x3e0d80=>!_0x3b3d24[_0x13debe(0xe1)](_0x3e0d80[_0x13debe(0xe6)])),_0x2a2058=a89_0x688b52({'cliBinName':CLI_BIN_NAME,'cliDisplayName':CLI_DISPLAY_NAME,'cliVersion':getCliVersion(),'gitCommit':getCliGitCommit(),'globalFlags':GLOBAL_FLAGS,'serviceRegistry':insertDynamicServicesAfterServiceTree(_0xa49945,_0x469954),'buildAllFlags':buildAllFlags,'findDefinition':(_0x48f359,_0x15eead)=>_0x2a395d(_0x48f359,_0x15eead)??findDynamicServiceDefinition(_0x48f359,_0x15eead)});return normalizeSchemaPayload(_0x2a2058);}function normalizeSchemaPayload(_0x2b2e0e){const _0x431fea=a89_0x2bce;return{..._0x2b2e0e,'schemaVersion':0x2,'services':_0x2b2e0e[_0x431fea(0xd8)][_0x431fea(0xdc)](_0x1ea13b=>({..._0x1ea13b,'commands':_0x1ea13b[_0x431fea(0xec)][_0x431fea(0xdc)](normalizeSchemaCommand)}))};}function normalizeSchemaCommand(_0x16fbe7){const _0x3533f5=a89_0x2bce,_0x3af712=_0x16fbe7;return{..._0x16fbe7,'auth':_0x3af712[_0x3533f5(0xdb)]??(_0x16fbe7[_0x3533f5(0xe9)]?_0x3533f5(0xe4):_0x3533f5(0xdf))};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
(function(_0x3d95d6,_0x376988){const _0x57cf2f=a90_0x59a2,_0x1c0700=_0x3d95d6();while(!![]){try{const _0x1f2c22=parseInt(_0x57cf2f(0x17b))/0x1+parseInt(_0x57cf2f(0x17e))/0x2*(-parseInt(_0x57cf2f(0x180))/0x3)+-parseInt(_0x57cf2f(0x17f))/0x4+parseInt(_0x57cf2f(0x178))/0x5*(parseInt(_0x57cf2f(0x179))/0x6)+-parseInt(_0x57cf2f(0x17d))/0x7*(parseInt(_0x57cf2f(0x17c))/0x8)+-parseInt(_0x57cf2f(0x175))/0x9+parseInt(_0x57cf2f(0x177))/0xa*(-parseInt(_0x57cf2f(0x17a))/0xb);if(_0x1f2c22===_0x376988)break;else _0x1c0700['push'](_0x1c0700['shift']());}catch(_0x197551){_0x1c0700['push'](_0x1c0700['shift']());}}}(a90_0x6615,0xc0345));export function insertDynamicServicesAfterServiceTree(_0x21b099,_0xb9f174){const _0xa4fd4c=a90_0x59a2;if(_0xb9f174[_0xa4fd4c(0x176)]===0x0)return[..._0x21b099];const _0xc2fac3=_0x21b099['findIndex'](_0x464181=>_0x464181[_0xa4fd4c(0x174)]===_0xa4fd4c(0x174));if(_0xc2fac3<0x0)return[..._0x21b099,..._0xb9f174];return[..._0x21b099[_0xa4fd4c(0x173)](0x0,_0xc2fac3+0x1),..._0xb9f174,..._0x21b099['slice'](_0xc2fac3+0x1)];}function a90_0x59a2(_0x56be74,_0x511ffc){_0x56be74=_0x56be74-0x173;const _0x6615ab=a90_0x6615();let _0x59a215=_0x6615ab[_0x56be74];return _0x59a215;}function a90_0x6615(){const _0x3ef072=['2709968DoREHs','21TNlPsG','1113646wsdlEe','1252212wZXcpZ','3vDchZU','slice','service','1633680tSyCTu','length','1087110YNEVOO','40025wqWyci','1146Gvlcbk','22kGTXZX','1543370XSkHIy'];a90_0x6615=function(){return _0x3ef072;};return a90_0x6615();}
|
package/lib/framework/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(
|
|
1
|
+
(function(_0x9688bc,_0x99d554){var _0x7392f1=a91_0x1dd0,_0x37e1f5=_0x9688bc();while(!![]){try{var _0x562c60=parseInt(_0x7392f1(0x6d))/0x1*(parseInt(_0x7392f1(0x73))/0x2)+-parseInt(_0x7392f1(0x76))/0x3+-parseInt(_0x7392f1(0x71))/0x4*(-parseInt(_0x7392f1(0x72))/0x5)+parseInt(_0x7392f1(0x6e))/0x6+parseInt(_0x7392f1(0x74))/0x7+-parseInt(_0x7392f1(0x75))/0x8*(-parseInt(_0x7392f1(0x6c))/0x9)+parseInt(_0x7392f1(0x70))/0xa*(-parseInt(_0x7392f1(0x6f))/0xb);if(_0x562c60===_0x99d554)break;else _0x37e1f5['push'](_0x37e1f5['shift']());}catch(_0x2a18a3){_0x37e1f5['push'](_0x37e1f5['shift']());}}}(a91_0x1818,0x82df5));function a91_0x1dd0(_0x4d475e,_0x576d34){_0x4d475e=_0x4d475e-0x6c;var _0x181850=a91_0x1818();var _0x1dd0a6=_0x181850[_0x4d475e];return _0x1dd0a6;}export{riskLevelOrder,normalizeLegacyOutputFormat,isValidFormat}from'@lovrabet/cli-framework';function a91_0x1818(){var _0x549183=['5MkTXQZ','1001636ZdQjoV','4455605vBuNql','47848QnupbH','1935930lRnvQz','873djciSz','1OgmeJu','6295698mlrNiI','256982ljnQIt','730VyXlXG','480064yvGuRc'];a91_0x1818=function(){return _0x549183;};return a91_0x1818();}
|