@lovrabet/lovrabet-cli 2.1.2 → 2.1.3-beta.1

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.
Files changed (108) hide show
  1. package/lib/cli.js +1 -1
  2. package/lib/commands/api-doc/index.js +1 -1
  3. package/lib/commands/app/cache.js +1 -1
  4. package/lib/commands/app/definitions.js +1 -1
  5. package/lib/commands/app/eligibility.js +1 -1
  6. package/lib/commands/app/mock-loader.js +1 -1
  7. package/lib/commands/app/remote-source.js +1 -1
  8. package/lib/commands/app/shared.js +1 -1
  9. package/lib/commands/artifact/index.js +1 -1
  10. package/lib/commands/auth/index.js +1 -1
  11. package/lib/commands/auth/prompt.js +1 -1
  12. package/lib/commands/bff/detail.js +1 -1
  13. package/lib/commands/bff/exec.js +1 -1
  14. package/lib/commands/bff/index.js +1 -1
  15. package/lib/commands/cli-skill/index.js +1 -1
  16. package/lib/commands/common/config-policy.js +1 -1
  17. package/lib/commands/common/constraints.js +1 -1
  18. package/lib/commands/common/flags.js +1 -1
  19. package/lib/commands/config/definitions.js +1 -1
  20. package/lib/commands/config/shared.js +1 -1
  21. package/lib/commands/data/index.js +1 -1
  22. package/lib/commands/dataset/detail.js +1 -1
  23. package/lib/commands/dataset/index.js +1 -1
  24. package/lib/commands/dataset/list.js +1 -1
  25. package/lib/commands/dataset/sdk-doc.js +1 -1
  26. package/lib/commands/doctor.js +1 -1
  27. package/lib/commands/init.js +1 -1
  28. package/lib/commands/kb/index.js +1 -1
  29. package/lib/commands/logs/index.js +1 -1
  30. package/lib/commands/personal-bff/index.js +1 -1
  31. package/lib/commands/registry.js +1 -1
  32. package/lib/commands/schema.js +1 -1
  33. package/lib/commands/service/dynamic.js +1 -1
  34. package/lib/commands/service/index.js +1 -1
  35. package/lib/commands/service/registry.js +1 -1
  36. package/lib/commands/skill/commands/create.js +1 -0
  37. package/lib/commands/skill/commands/install.js +1 -0
  38. package/lib/commands/skill/commands/list.js +1 -0
  39. package/lib/commands/skill/commands/push.js +1 -0
  40. package/lib/commands/skill/commands/validate.js +1 -0
  41. package/lib/commands/skill/flags.js +1 -0
  42. package/lib/commands/skill/index.js +1 -1
  43. package/lib/commands/skill/manifest-helpers.js +1 -0
  44. package/lib/commands/skill/scopes.js +1 -0
  45. package/lib/commands/skill/summary.js +1 -0
  46. package/lib/commands/skill/templates.js +1 -1
  47. package/lib/commands/skill/validate.js +1 -1
  48. package/lib/commands/sql/detail.js +1 -1
  49. package/lib/commands/sql/exec.js +1 -1
  50. package/lib/commands/sql/index.js +1 -1
  51. package/lib/commands/update.js +1 -1
  52. package/lib/commands/workspace/index.js +1 -1
  53. package/lib/config/schema.js +1 -1
  54. package/lib/constant/app.js +1 -1
  55. package/lib/constant/auth-mode.js +1 -1
  56. package/lib/constant/cli.js +1 -1
  57. package/lib/constant/defaults.js +1 -1
  58. package/lib/constant/distribution.js +1 -1
  59. package/lib/constant/domain.js +1 -1
  60. package/lib/constant/env.js +1 -1
  61. package/lib/constant/output.js +1 -1
  62. package/lib/constant/product.js +1 -1
  63. package/lib/constant/risk.js +1 -1
  64. package/lib/constant/url.js +1 -1
  65. package/lib/context.js +1 -1
  66. package/lib/core/api-client.js +1 -1
  67. package/lib/core/db-resolver.js +1 -1
  68. package/lib/core/sdk-client.js +1 -1
  69. package/lib/errors.js +1 -1
  70. package/lib/framework/build-all-flags.js +1 -1
  71. package/lib/framework/dryrun.js +1 -1
  72. package/lib/framework/flags.js +1 -1
  73. package/lib/framework/help.js +1 -1
  74. package/lib/framework/index.js +1 -1
  75. package/lib/framework/output.js +1 -1
  76. package/lib/framework/preparse.js +1 -1
  77. package/lib/framework/response.js +1 -1
  78. package/lib/framework/runner-confirmation.js +1 -1
  79. package/lib/framework/runner-error.js +1 -1
  80. package/lib/framework/runner.js +1 -1
  81. package/lib/framework/schema-export.js +1 -1
  82. package/lib/framework/types.js +1 -1
  83. package/lib/generated/build-info.js +1 -1
  84. package/lib/help.js +1 -1
  85. package/lib/skills/npx-skills-add.js +1 -1
  86. package/lib/skills/runtime-skill-sync/constants.js +1 -0
  87. package/lib/skills/runtime-skill-sync/fs-utils.js +1 -0
  88. package/lib/skills/runtime-skill-sync/hashing.js +1 -0
  89. package/lib/skills/runtime-skill-sync/links.js +1 -0
  90. package/lib/skills/runtime-skill-sync/list-local.js +1 -0
  91. package/lib/skills/runtime-skill-sync/local-files.js +1 -0
  92. package/lib/skills/runtime-skill-sync/materialize.js +1 -0
  93. package/lib/skills/runtime-skill-sync/metadata.js +1 -0
  94. package/lib/skills/runtime-skill-sync/paths.js +1 -0
  95. package/lib/skills/runtime-skill-sync/push.js +1 -0
  96. package/lib/skills/runtime-skill-sync/scopes.js +1 -0
  97. package/lib/skills/runtime-skill-sync/types.js +1 -0
  98. package/lib/skills/runtime-skill-sync/zip-codec.js +1 -0
  99. package/lib/skills/runtime-skill-sync/zip-package.js +1 -0
  100. package/lib/skills/runtime-skill-sync.js +1 -1
  101. package/lib/utils/apply-jq-filter.js +1 -1
  102. package/lib/utils/logger.js +1 -1
  103. package/lib/utils/params.js +1 -1
  104. package/lib/utils/platform.js +1 -1
  105. package/lib/utils/update-notice.js +1 -1
  106. package/lib/utils/version.js +1 -1
  107. package/lib/utils/write-cli-side-channel.js +1 -1
  108. package/package.json +4 -1
package/lib/cli.js CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- (function(_0x267235,_0x1c7411){const _0x7fc836=a0_0x2829,_0xc475=_0x267235();while(!![]){try{const _0x29c7db=parseInt(_0x7fc836(0xa9))/0x1+parseInt(_0x7fc836(0xa6))/0x2+-parseInt(_0x7fc836(0xc1))/0x3*(-parseInt(_0x7fc836(0xb0))/0x4)+parseInt(_0x7fc836(0xc2))/0x5*(parseInt(_0x7fc836(0xac))/0x6)+-parseInt(_0x7fc836(0xa7))/0x7*(parseInt(_0x7fc836(0xc0))/0x8)+parseInt(_0x7fc836(0xb9))/0x9*(-parseInt(_0x7fc836(0xa2))/0xa)+-parseInt(_0x7fc836(0xaa))/0xb;if(_0x29c7db===_0x1c7411)break;else _0xc475['push'](_0xc475['shift']());}catch(_0xa67af1){_0xc475['push'](_0xc475['shift']());}}}(a0_0x8e56,0xcf477));import{jsx as a0_0x5c34dd}from'react/jsx-runtime';import a0_0x3ed35c from'meow';import{render}from'ink';import{Help}from'./help.js';import{CliError,CliErrors}from'./errors.js';import{buildConfigFromFlags,initGlobalEnvironment}from'./context.js';import{isKnownService,getServiceEntry,findDefinition,getAllDefinitions}from'./commands/registry.js';import{generateDynamicServiceHelp,resolveDynamicServiceCommand}from'./commands/service/dynamic.js';function a0_0x2829(_0x28dc30,_0x15c4a1){_0x28dc30=_0x28dc30-0x9b;const _0x8e5604=a0_0x8e56();let _0x28293d=_0x8e5604[_0x28dc30];return _0x28293d;}import{runCommand,createPipelineEnv}from'./framework/runner.js';import{generateCommandHelp,generateServiceHelp,generateFullHelp}from'./framework/help.js';import{buildMeowFlags}from'./constant/cli.js';import{getCliVersionDisplay}from'./utils/version.js';function a0_0x8e56(){const _0x703969=['defaultCommand','length','9179577yPxNHt','[preparse]\x20','error','ExitPromptError','name','flatMap','handler','407072RVckSF','15945OBPfrn','886955RuGnBf','definition','input','flags','log','ERR_STREAM_DESTROYED','exitCode','args','Hint:\x20','help',':\x20--','original','10HEYZSt','stderr','corrected','code','1060262IkxhxH','7pIjEXw','Unexpected\x20error:','1304694djVMCY','12986776iifNvk','slice','18ctmnJm','cancelled','unknownCommand','message','552mFDGnp','\x0aCancelled.\x0a','exit','hint','write','assign','\x20->\x20--'];a0_0x8e56=function(){return _0x703969;};return a0_0x8e56();}const helpText=generateFullHelp(),cli=a0_0x3ed35c(helpText,{'importMeta':import.meta,'flags':buildMeowFlags(),'version':getCliVersionDisplay()});void main()['catch'](handleError);async function main(){try{await run();}catch(_0x46304a){handleError(_0x46304a);}}async function run(){const _0x520d97=a0_0x2829;let _0x2148bd=cli['input'][0x0],_0x1cd0a6=cli[_0x520d97(0xc4)][0x1];const _0x4e0999=cli['flags'];try{const {correctFlags:_0x511860}=await import('./framework/preparse.js'),_0x5a6c5b=getAllDefinitions()[_0x520d97(0xbe)](_0x134dfd=>_0x134dfd[_0x520d97(0xc5)]??[]),{flags:_0x79065f,corrections:_0x3aa6aa}=_0x511860(_0x4e0999,_0x5a6c5b);if(_0x3aa6aa[_0x520d97(0xb8)]>0x0){for(const _0x32d8a7 of _0x3aa6aa){process[_0x520d97(0xa3)][_0x520d97(0xb4)](_0x520d97(0xba)+_0x32d8a7[_0x520d97(0xbf)]+_0x520d97(0xa0)+_0x32d8a7[_0x520d97(0xa1)]+_0x520d97(0xb6)+_0x32d8a7[_0x520d97(0xa4)]+'\x0a');}Object[_0x520d97(0xb5)](_0x4e0999,_0x79065f);}}catch{}if(!_0x2148bd){const {waitUntilExit:_0xddd691}=render(a0_0x5c34dd(Help,{}));await _0xddd691();return;}if(!isKnownService(_0x2148bd)){const _0x310fc1=resolveDynamicServiceCommand(cli['input'],_0x4e0999);if(_0x310fc1){if(_0x4e0999[_0x520d97(0x9f)]){console['log'](generateCommandHelp(_0x310fc1[_0x520d97(0xc3)]));return;}Object[_0x520d97(0xb5)](_0x4e0999,_0x310fc1[_0x520d97(0xc5)]);const _0x240ab1=buildConfigFromFlags(_0x4e0999);await initGlobalEnvironment(_0x240ab1);const _0x557d8b=createPipelineEnv(_0x240ab1,_0x4e0999);_0x557d8b[_0x520d97(0x9d)]=_0x310fc1[_0x520d97(0x9d)],await runCommand(_0x310fc1[_0x520d97(0xc3)],_0x557d8b);return;}if(_0x4e0999[_0x520d97(0x9f)]){const _0x1693e5=generateDynamicServiceHelp(_0x2148bd);if(_0x1693e5){console[_0x520d97(0xc6)](_0x1693e5);return;}}const {waitUntilExit:_0x527f51}=render(a0_0x5c34dd(Help,{}));await _0x527f51();return;}const _0x2062df=getServiceEntry(_0x2148bd);if(!_0x1cd0a6){if(_0x4e0999[_0x520d97(0x9f)]){console['log'](generateServiceHelp(_0x2148bd));return;}if(_0x2062df[_0x520d97(0xb7)])_0x1cd0a6=_0x2062df['defaultCommand'];else{console[_0x520d97(0xc6)](generateServiceHelp(_0x2148bd));return;}}const _0x2fb0a5=findDefinition(_0x2148bd,_0x1cd0a6);!_0x2fb0a5&&(console[_0x520d97(0xc6)](generateServiceHelp(_0x2148bd)),handleError(CliErrors[_0x520d97(0xae)](_0x2148bd+'\x20'+_0x1cd0a6)));if(_0x4e0999[_0x520d97(0x9f)]){console[_0x520d97(0xc6)](generateCommandHelp(_0x2fb0a5));return;}const _0x2cad80=buildConfigFromFlags(_0x4e0999);await initGlobalEnvironment(_0x2cad80);const _0x356026=createPipelineEnv(_0x2cad80,_0x4e0999);_0x356026[_0x520d97(0x9d)]=cli[_0x520d97(0xc4)][_0x520d97(0xab)](0x2),await runCommand(_0x2fb0a5,_0x356026);}function handleError(_0x528240){const _0x3cfe65=a0_0x2829;if(_0x528240 instanceof CliError){_0x528240[_0x3cfe65(0xa5)]===_0x3cfe65(0xad)&&(process[_0x3cfe65(0xa3)]['write']('\x0aCancelled.\x0a'),process[_0x3cfe65(0xb2)](0x0));console[_0x3cfe65(0xbb)]('Error:\x20'+_0x528240[_0x3cfe65(0xaf)]);if(_0x528240[_0x3cfe65(0xb3)])console[_0x3cfe65(0xbb)](_0x3cfe65(0x9e)+_0x528240[_0x3cfe65(0xb3)]);process[_0x3cfe65(0xb2)](_0x528240[_0x3cfe65(0x9c)]);}isUserCancellation(_0x528240)&&(process[_0x3cfe65(0xa3)][_0x3cfe65(0xb4)](_0x3cfe65(0xb1)),process[_0x3cfe65(0xb2)](0x0)),console[_0x3cfe65(0xbb)](_0x3cfe65(0xa8),_0x528240),process[_0x3cfe65(0xb2)](0x1);}function isUserCancellation(_0x15adf6){const _0xe42d1=a0_0x2829;if(!(_0x15adf6 instanceof Error))return![];if(_0x15adf6[_0xe42d1(0xbd)]===_0xe42d1(0xbc))return!![];if(_0x15adf6['code']==='ERR_USE_AFTER_CLOSE')return!![];if(_0x15adf6[_0xe42d1(0xa5)]===_0xe42d1(0x9b))return!![];return![];}
2
+ const a0_0x30f8f4=a0_0x220b;(function(_0x16d999,_0x709180){const _0x1443a4=a0_0x220b,_0x35b2f2=_0x16d999();while(!![]){try{const _0x39a7a1=-parseInt(_0x1443a4(0x168))/0x1*(parseInt(_0x1443a4(0x185))/0x2)+-parseInt(_0x1443a4(0x181))/0x3+-parseInt(_0x1443a4(0x173))/0x4*(-parseInt(_0x1443a4(0x188))/0x5)+-parseInt(_0x1443a4(0x18a))/0x6*(-parseInt(_0x1443a4(0x17d))/0x7)+parseInt(_0x1443a4(0x177))/0x8+-parseInt(_0x1443a4(0x180))/0x9*(-parseInt(_0x1443a4(0x176))/0xa)+parseInt(_0x1443a4(0x17f))/0xb;if(_0x39a7a1===_0x709180)break;else _0x35b2f2['push'](_0x35b2f2['shift']());}catch(_0x7f2cdf){_0x35b2f2['push'](_0x35b2f2['shift']());}}}(a0_0x468a,0x5631e));import{jsx as a0_0x258010}from'react/jsx-runtime';import a0_0x249af1 from'meow';function a0_0x468a(){const _0x3b052e=['cancelled','write','args','7rtbVDX','Hint:\x20','355454tFrNCk','195012toglLp','660327IQLOqv','length','\x20->\x20--','assign','32842uwslMA','flatMap','defaultCommand','3415stoeFR','message','1183170HyATLy','log','catch','original','Error:\x20','definition','ERR_STREAM_DESTROYED','handler','stderr','19lNdkOc',':\x20--','ExitPromptError','unknownCommand','ERR_USE_AFTER_CLOSE','exit','input','error','hint','name','code','2808eGwZBJ','./framework/preparse.js','help','80SuNDtU','22744aQpBVp','flags','corrected'];a0_0x468a=function(){return _0x3b052e;};return a0_0x468a();}import{render}from'ink';function a0_0x220b(_0x434252,_0x411b7d){_0x434252=_0x434252-0x168;const _0x468af8=a0_0x468a();let _0x220ba4=_0x468af8[_0x434252];return _0x220ba4;}import{Help}from'./help.js';import{CliError,CliErrors}from'./errors.js';import{buildConfigFromFlags,initGlobalEnvironment}from'./context.js';import{isKnownService,getServiceEntry,findDefinition,getAllDefinitions}from'./commands/registry.js';import{generateDynamicServiceHelp,resolveDynamicServiceCommand}from'./commands/service/dynamic.js';import{runCommand,createPipelineEnv}from'./framework/runner.js';import{generateCommandHelp,generateServiceHelp,generateFullHelp}from'./framework/help.js';import{buildMeowFlags}from'./constant/cli.js';import{getCliVersionDisplay}from'./utils/version.js';const helpText=generateFullHelp(),cli=a0_0x249af1(helpText,{'importMeta':import.meta,'flags':buildMeowFlags(),'version':getCliVersionDisplay()});void main()[a0_0x30f8f4(0x18c)](handleError);async function main(){try{await run();}catch(_0xf4c7f5){handleError(_0xf4c7f5);}}async function run(){const _0x25c425=a0_0x30f8f4;let _0x31d014=cli[_0x25c425(0x16e)][0x0],_0x235eae=cli['input'][0x1];const _0x6ec15a=cli['flags'];try{const {correctFlags:_0x3183cb}=await import(_0x25c425(0x174)),_0x21fe81=getAllDefinitions()[_0x25c425(0x186)](_0x22e9dd=>_0x22e9dd['flags']??[]),{flags:_0x4ec31a,corrections:_0x572225}=_0x3183cb(_0x6ec15a,_0x21fe81);if(_0x572225[_0x25c425(0x182)]>0x0){for(const _0x18761a of _0x572225){process[_0x25c425(0x192)][_0x25c425(0x17b)]('[preparse]\x20'+_0x18761a[_0x25c425(0x191)]+_0x25c425(0x169)+_0x18761a[_0x25c425(0x18d)]+_0x25c425(0x183)+_0x18761a[_0x25c425(0x179)]+'\x0a');}Object[_0x25c425(0x184)](_0x6ec15a,_0x4ec31a);}}catch{}if(!_0x31d014){const {waitUntilExit:_0x59a606}=render(a0_0x258010(Help,{}));await _0x59a606();return;}if(!isKnownService(_0x31d014)){const _0x38ae55=resolveDynamicServiceCommand(cli[_0x25c425(0x16e)],_0x6ec15a);if(_0x38ae55){if(_0x6ec15a[_0x25c425(0x175)]){console[_0x25c425(0x18b)](generateCommandHelp(_0x38ae55[_0x25c425(0x18f)]));return;}Object[_0x25c425(0x184)](_0x6ec15a,_0x38ae55[_0x25c425(0x178)]);const _0x378ab5=buildConfigFromFlags(_0x6ec15a);await initGlobalEnvironment(_0x378ab5);const _0xf4c20c=createPipelineEnv(_0x378ab5,_0x6ec15a);_0xf4c20c[_0x25c425(0x17c)]=_0x38ae55[_0x25c425(0x17c)],await runCommand(_0x38ae55[_0x25c425(0x18f)],_0xf4c20c);return;}if(_0x6ec15a[_0x25c425(0x175)]){const _0x5324a8=generateDynamicServiceHelp(_0x31d014);if(_0x5324a8){console['log'](_0x5324a8);return;}}const {waitUntilExit:_0x4a66de}=render(a0_0x258010(Help,{}));await _0x4a66de();return;}const _0x4d636a=getServiceEntry(_0x31d014);if(!_0x235eae){if(_0x6ec15a[_0x25c425(0x175)]){console['log'](generateServiceHelp(_0x31d014));return;}if(_0x4d636a[_0x25c425(0x187)])_0x235eae=_0x4d636a['defaultCommand'];else{console[_0x25c425(0x18b)](generateServiceHelp(_0x31d014));return;}}const _0x27e503=findDefinition(_0x31d014,_0x235eae);!_0x27e503&&(console[_0x25c425(0x18b)](generateServiceHelp(_0x31d014)),handleError(CliErrors[_0x25c425(0x16b)](_0x31d014+'\x20'+_0x235eae)));if(_0x6ec15a[_0x25c425(0x175)]){console['log'](generateCommandHelp(_0x27e503));return;}const _0x22752b=buildConfigFromFlags(_0x6ec15a);await initGlobalEnvironment(_0x22752b);const _0x598a09=createPipelineEnv(_0x22752b,_0x6ec15a);_0x598a09['args']=cli['input']['slice'](0x2),await runCommand(_0x27e503,_0x598a09);}function handleError(_0x21925e){const _0x26821e=a0_0x30f8f4;if(_0x21925e instanceof CliError){_0x21925e[_0x26821e(0x172)]===_0x26821e(0x17a)&&(process[_0x26821e(0x192)][_0x26821e(0x17b)]('\x0aCancelled.\x0a'),process[_0x26821e(0x16d)](0x0));console[_0x26821e(0x16f)](_0x26821e(0x18e)+_0x21925e[_0x26821e(0x189)]);if(_0x21925e[_0x26821e(0x170)])console[_0x26821e(0x16f)](_0x26821e(0x17e)+_0x21925e[_0x26821e(0x170)]);process[_0x26821e(0x16d)](_0x21925e['exitCode']);}isUserCancellation(_0x21925e)&&(process[_0x26821e(0x192)]['write']('\x0aCancelled.\x0a'),process[_0x26821e(0x16d)](0x0)),console['error']('Unexpected\x20error:',_0x21925e),process[_0x26821e(0x16d)](0x1);}function isUserCancellation(_0x28ce26){const _0x40c4eb=a0_0x30f8f4;if(!(_0x28ce26 instanceof Error))return![];if(_0x28ce26[_0x40c4eb(0x171)]===_0x40c4eb(0x16a))return!![];if(_0x28ce26['code']===_0x40c4eb(0x16c))return!![];if(_0x28ce26[_0x40c4eb(0x172)]===_0x40c4eb(0x190))return!![];return![];}
@@ -1 +1 @@
1
- const a1_0x1a6a50=a1_0x426e;function a1_0x426e(_0x3b4e61,_0x5d7166){_0x3b4e61=_0x3b4e61-0x7f;const _0x3362a8=a1_0x3362();let _0x426e70=_0x3362a8[_0x3b4e61];return _0x426e70;}(function(_0x1943db,_0x3599f7){const _0x31fdc3=a1_0x426e,_0x2b0e2b=_0x1943db();while(!![]){try{const _0x1c2940=parseInt(_0x31fdc3(0xa8))/0x1*(-parseInt(_0x31fdc3(0x9f))/0x2)+parseInt(_0x31fdc3(0xee))/0x3+-parseInt(_0x31fdc3(0xb7))/0x4*(-parseInt(_0x31fdc3(0xf1))/0x5)+-parseInt(_0x31fdc3(0xe4))/0x6+-parseInt(_0x31fdc3(0xa3))/0x7*(-parseInt(_0x31fdc3(0xd5))/0x8)+parseInt(_0x31fdc3(0xc1))/0x9*(parseInt(_0x31fdc3(0xe6))/0xa)+-parseInt(_0x31fdc3(0xc3))/0xb*(-parseInt(_0x31fdc3(0xc4))/0xc);if(_0x1c2940===_0x3599f7)break;else _0x2b0e2b['push'](_0x2b0e2b['shift']());}catch(_0x12a26a){_0x2b0e2b['push'](_0x2b0e2b['shift']());}}}(a1_0x3362,0xf22c8));import{CliErrors}from'../../errors.js';const CATEGORY_FLAG={'name':a1_0x1a6a50(0xa1),'type':a1_0x1a6a50(0xc0),'description':'Filter\x20docs\x20by\x20category,\x20for\x20example\x20dataset'},KEYWORD_FLAG={'name':a1_0x1a6a50(0xdf),'type':'string','description':a1_0x1a6a50(0x88)},DOC_CODE_FLAG={'name':a1_0x1a6a50(0x84),'type':'string','required':!![],'description':a1_0x1a6a50(0xa5)},DOCS=[{'code':a1_0x1a6a50(0xe9),'category':a1_0x1a6a50(0xce),'title':a1_0x1a6a50(0xed),'method':a1_0x1a6a50(0x91),'path':a1_0x1a6a50(0x98),'summary':a1_0x1a6a50(0xac),'whenToUse':a1_0x1a6a50(0xaf),'pathParams':[],'queryParams':[],'bodySchema':a1_0x1a6a50(0x89),'responseHighlights':[a1_0x1a6a50(0xec),'paging.totalCount\x20gives\x20total\x20rows'],'examples':[a1_0x1a6a50(0x9e)],'notes':[a1_0x1a6a50(0xb9)],'markdown':[a1_0x1a6a50(0xf5),'',a1_0x1a6a50(0xa9)]['join']('\x0a')},{'code':'dataset_detail','category':a1_0x1a6a50(0xce),'title':a1_0x1a6a50(0xb1),'method':a1_0x1a6a50(0xba),'path':a1_0x1a6a50(0xc9),'summary':'获取数据集详情','whenToUse':a1_0x1a6a50(0xde),'pathParams':[],'queryParams':[{'name':a1_0x1a6a50(0x84),'description':a1_0x1a6a50(0xa4)}],'bodySchema':a1_0x1a6a50(0xb4),'responseHighlights':[a1_0x1a6a50(0xc6),a1_0x1a6a50(0xca)],'examples':[a1_0x1a6a50(0x85)],'notes':[a1_0x1a6a50(0xcf)],'markdown':[a1_0x1a6a50(0xe0),'',a1_0x1a6a50(0x8a)]['join']('\x0a')},{'code':a1_0x1a6a50(0xad),'category':a1_0x1a6a50(0xce),'title':a1_0x1a6a50(0xaa),'method':'POST','path':a1_0x1a6a50(0x9a),'summary':'条件过滤查询数据','whenToUse':a1_0x1a6a50(0xe1),'pathParams':[{'name':a1_0x1a6a50(0xf3),'description':'Current\x20app\x20code'},{'name':a1_0x1a6a50(0xc5),'description':a1_0x1a6a50(0xa4)}],'queryParams':[],'bodySchema':a1_0x1a6a50(0xb8),'responseHighlights':[a1_0x1a6a50(0xcd),a1_0x1a6a50(0x95)],'examples':['lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22currentPage\x22:1,\x22pageSize\x22:5}\x27'],'notes':['Use\x20read-only\x20data\x20commands\x20before\x20writing\x20Artifacts\x20that\x20display\x20real\x20data.'],'markdown':['##\x20Filter\x20dataset\x20data','','Use\x20`where`,\x20`select`,\x20`orderBy`,\x20`currentPage`,\x20and\x20`pageSize`\x20to\x20inspect\x20live\x20data\x20shape.'][a1_0x1a6a50(0xb3)]('\x0a')},{'code':a1_0x1a6a50(0x9c),'category':'dataset','title':a1_0x1a6a50(0xf0),'method':a1_0x1a6a50(0x91),'path':'/api/{appCode}/{datasetCode}/aggregate','summary':'聚合查询数据集数据','whenToUse':'需要按\x20groupBy\x20分组并做\x20count、sum、avg、max、min\x20等聚合统计时使用','pathParams':[{'name':a1_0x1a6a50(0xf3),'description':a1_0x1a6a50(0xe2)},{'name':a1_0x1a6a50(0xc5),'description':a1_0x1a6a50(0xa4)}],'queryParams':[],'bodySchema':a1_0x1a6a50(0xf8),'responseHighlights':[a1_0x1a6a50(0x9d),a1_0x1a6a50(0xe5)],'examples':[a1_0x1a6a50(0xbb)],'notes':[a1_0x1a6a50(0xb5),a1_0x1a6a50(0xd2)],'markdown':[a1_0x1a6a50(0xa0),'',a1_0x1a6a50(0xdd)][a1_0x1a6a50(0xb3)]('\x0a')},{'code':'dataset_data_get_one','category':a1_0x1a6a50(0xce),'title':a1_0x1a6a50(0xd9),'method':a1_0x1a6a50(0x91),'path':a1_0x1a6a50(0x87),'summary':a1_0x1a6a50(0x86),'whenToUse':'已经知道记录\x20id,需要按数据集读取单条业务数据时使用','pathParams':[{'name':a1_0x1a6a50(0xf3),'description':a1_0x1a6a50(0xe2)},{'name':a1_0x1a6a50(0xc5),'description':a1_0x1a6a50(0xa4)}],'queryParams':[],'bodySchema':a1_0x1a6a50(0xd0),'responseHighlights':[a1_0x1a6a50(0xf7)],'examples':[a1_0x1a6a50(0xe8)],'notes':['Prefer\x20`filter`\x20when\x20the\x20record\x20id\x20is\x20unknown.'],'markdown':a1_0x1a6a50(0x7f)},{'code':'dataset_data_create','category':a1_0x1a6a50(0xce),'title':a1_0x1a6a50(0x81),'method':a1_0x1a6a50(0x91),'path':a1_0x1a6a50(0xc8),'summary':'创建数据','whenToUse':a1_0x1a6a50(0x8f),'pathParams':[{'name':a1_0x1a6a50(0xf3),'description':a1_0x1a6a50(0xe2)},{'name':a1_0x1a6a50(0xc5),'description':a1_0x1a6a50(0xa4)}],'queryParams':[],'bodySchema':a1_0x1a6a50(0xa7),'responseHighlights':[a1_0x1a6a50(0xd8)],'examples':[a1_0x1a6a50(0xb6)],'notes':[a1_0x1a6a50(0xcb)],'markdown':a1_0x1a6a50(0x92)},{'code':a1_0x1a6a50(0xea),'category':'bf','title':a1_0x1a6a50(0xf6),'method':a1_0x1a6a50(0xba),'path':a1_0x1a6a50(0xf4),'summary':a1_0x1a6a50(0x99),'whenToUse':a1_0x1a6a50(0xd4),'pathParams':[{'name':'appCode','description':'Current\x20app\x20code'}],'queryParams':[],'bodySchema':a1_0x1a6a50(0xb4),'responseHighlights':[a1_0x1a6a50(0x82)],'examples':[a1_0x1a6a50(0xc7)],'notes':[a1_0x1a6a50(0x8b)],'markdown':'##\x20List\x20BF\x20endpoint\x20functions\x0a\x0aDiscover\x20executable\x20endpoint\x20functions.'},{'code':a1_0x1a6a50(0xae),'category':'bf','title':a1_0x1a6a50(0xd6),'method':a1_0x1a6a50(0x91),'path':a1_0x1a6a50(0xd7),'summary':'执行指定\x20BF\x20函数','whenToUse':a1_0x1a6a50(0xa6),'pathParams':[{'name':a1_0x1a6a50(0xf3),'description':a1_0x1a6a50(0xe2)},{'name':'scriptName','description':a1_0x1a6a50(0xd3)}],'queryParams':[],'bodySchema':a1_0x1a6a50(0xeb),'responseHighlights':['Returns\x20script\x20business\x20payload'],'examples':[a1_0x1a6a50(0xbf)],'notes':[a1_0x1a6a50(0xbd)],'markdown':'##\x20Execute\x20BF\x20endpoint\x20function\x0a\x0aExecute\x20a\x20known\x20endpoint\x20script.'},{'code':'custom_sql_execute','category':'custom_sql','title':a1_0x1a6a50(0xb2),'method':'POST','path':a1_0x1a6a50(0x8e),'summary':a1_0x1a6a50(0x96),'whenToUse':a1_0x1a6a50(0xbe),'pathParams':[],'queryParams':[],'bodySchema':a1_0x1a6a50(0x97),'responseHighlights':[a1_0x1a6a50(0x8d)],'examples':[a1_0x1a6a50(0xef)],'notes':['Use\x20`lovrabet\x20sql\x20detail`\x20before\x20execution.'],'markdown':a1_0x1a6a50(0x8c)}];function entrySummary(_0x99dac0){const _0x4143f4=a1_0x1a6a50;return{'code':_0x99dac0['code'],'category':_0x99dac0[_0x4143f4(0xa1)],'method':_0x99dac0[_0x4143f4(0x9b)],'path':_0x99dac0[_0x4143f4(0xe3)],'summary':_0x99dac0[_0x4143f4(0xda)],'whenToUse':_0x99dac0[_0x4143f4(0xd1)]};}export function listApiDocEntries(_0xf5d9d={}){const _0xd75550=a1_0x1a6a50,_0xabf31b=String(_0xf5d9d[_0xd75550(0xa1)]||'')[_0xd75550(0xc2)](),_0x1f5503=String(_0xf5d9d[_0xd75550(0xdf)]||'')[_0xd75550(0xc2)]()[_0xd75550(0x83)]();return DOCS[_0xd75550(0x93)](_0x208267=>{const _0xc40e7c=_0xd75550;if(_0xabf31b&&_0x208267[_0xc40e7c(0xa1)]!==_0xabf31b)return![];if(!_0x1f5503)return!![];return[_0x208267[_0xc40e7c(0x84)],_0x208267['category'],_0x208267[_0xc40e7c(0x9b)],_0x208267[_0xc40e7c(0xe3)],_0x208267[_0xc40e7c(0xda)],_0x208267[_0xc40e7c(0xd1)],_0x208267['title']][_0xc40e7c(0xb3)]('\x20')[_0xc40e7c(0x83)]()[_0xc40e7c(0x94)](_0x1f5503);})[_0xd75550(0xf2)](entrySummary);}export function getApiDocDetail(_0x99dc6e){const _0xa4cd8c=a1_0x1a6a50,_0x35dd24=DOCS[_0xa4cd8c(0xab)](_0x34f5b3=>_0x34f5b3[_0xa4cd8c(0x84)]===_0x99dc6e);if(!_0x35dd24)throw CliErrors[_0xa4cd8c(0xdc)](_0xa4cd8c(0xb0)+_0x99dc6e);return{..._0x35dd24};}const apiDocList={'service':a1_0x1a6a50(0x90),'command':a1_0x1a6a50(0xcc),'description':a1_0x1a6a50(0x80),'risk':a1_0x1a6a50(0xa2),'requiresAppCode':![],'flags':[CATEGORY_FLAG,KEYWORD_FLAG],async 'execute'(_0x16ece5){const _0x4983f1=a1_0x1a6a50,_0x4849ca=listApiDocEntries({'category':_0x16ece5[_0x4983f1(0xdb)](_0x4983f1(0xa1)),'keyword':_0x16ece5[_0x4983f1(0xdb)]('keyword')});return{'ok':!![],'data':{'total':_0x4849ca['length'],'items':_0x4849ca}};}},apiDocDetail={'service':a1_0x1a6a50(0x90),'command':a1_0x1a6a50(0xbc),'description':a1_0x1a6a50(0xe7),'risk':a1_0x1a6a50(0xa2),'requiresAppCode':![],'flags':[DOC_CODE_FLAG],async 'execute'(_0x58dc76){const _0xd361cc=a1_0x1a6a50;return{'ok':!![],'data':getApiDocDetail(_0x58dc76[_0xd361cc(0xdb)](_0xd361cc(0x84)))};}};export const apiDocDefinitions=[apiDocList,apiDocDetail];function a1_0x3362(){const _0x17bcfa=['Inspect\x20field\x20names\x20and\x20operation\x20metadata\x20for\x20a\x20known\x20dataset\x20code.','CLI\x20has\x20typed\x20`bff\x20detail`\x20and\x20`bff\x20exec`\x20commands\x20for\x20endpoint\x20scripts.','##\x20Execute\x20custom\x20SQL\x0a\x0aExecute\x20a\x20configured\x20SQL\x20script\x20by\x20sqlCode.','Returns\x20SQL\x20execution\x20payload','/api/custom/executeSql','需要向指定数据集新增一条业务数据时使用','api-doc','POST','##\x20Create\x20dataset\x20record\x0a\x0aCreate\x20one\x20data\x20record\x20in\x20a\x20dataset.','filter','includes','paging\x20contains\x20pagination','执行自定义\x20SQL','{\x22appCode\x22:\x22app-aa63b188\x22,\x22sqlCode\x22:\x22xxxxxxxx-xxxxxxxx\x22,\x22params\x22:{}}','/api/dataset/get-dataset-list-by-app-code','获取应用下可调用的\x20BF\x20函数列表','/api/{appCode}/{datasetCode}/filter','method','dataset_data_aggregate','result\x20rows\x20contain\x20aggregate\x20aliases','lovrabet\x20dataset\x20list\x20--appcode\x20<appCode>\x20--format\x20compress','10156rizVls','##\x20Aggregate\x20dataset\x20data','category','read','17570QsMysC','32-character\x20dataset\x20code','API\x20doc\x20code,\x20for\x20example\x20dataset_list','已经确认目标\x20BF\x20的\x20scriptName,且需要实际调用该\x20ENDPOINT\x20脚本完成业务操作时使用','{\x22fieldName\x22:\x22value\x22}','133LRtCLJ','Use\x20this\x20API\x20or\x20`lovrabet\x20dataset\x20list`\x20to\x20discover\x20available\x20dataset\x20codes\x20before\x20reading\x20data.','Filter\x20dataset\x20data','find','分页获取数据集列表','dataset_data_filter','bf_execute','需要按\x20appCode\x20分页获取运行态数据集列表,并优先收敛可用\x20datasetCode\x20时使用','API\x20doc\x20code\x20not\x20found:\x20','Dataset\x20detail','Execute\x20custom\x20SQL','join','None','Use\x20`having`\x20only\x20for\x20post-aggregation\x20filters.','lovrabet\x20data\x20create\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22name\x22:\x22demo\x22}\x27','132776qBOFfF','{\x22where\x22:{},\x22currentPage\x22:1,\x22pageSize\x22:20}','CLI\x20users\x20should\x20prefer\x20`lovrabet\x20dataset\x20list`\x20for\x20this\x20workflow.','GET','lovrabet\x20data\x20aggregate\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}]}\x27','detail','Script\x20behavior\x20may\x20have\x20side\x20effects;\x20inspect\x20detail\x20first.','已经确认目标\x20sqlCode\x20存在,并需要实际执行该自定义\x20SQL\x20时使用','lovrabet\x20bff\x20exec\x20--name\x20<functionName>\x20--params\x20\x27{}\x27','string','9KiONHJ','trim','9878uEDkqi','384hcnzvO','datasetCode','fields/properties\x20describe\x20data\x20shape','lovrabet\x20bff\x20detail\x20--id\x20<scriptId>\x20--appcode\x20<appCode>','/api/{appCode}/{datasetCode}/create','/api/dataset/getOneByCode?code={datasetCode}','operations\x20describes\x20runtime\x20APIs','This\x20is\x20a\x20write\x20operation;\x20use\x20dry-run\x20when\x20available\x20and\x20safe\x20fixtures\x20for\x20smoke\x20tests.','list','tableData\x20contains\x20records','dataset','If\x20SDK\x20usage\x20is\x20needed,\x20follow\x20with\x20`lovrabet\x20dataset\x20sdk-doc\x20--code\x20<datasetCode>`.','{\x22id\x22:123}','whenToUse','`field`\x20is\x20accepted\x20as\x20a\x20deprecated\x20alias\x20for\x20`column`;\x20new\x20calls\x20should\x20use\x20`column`.','Endpoint\x20function\x20name','需要先确认当前应用有哪些可执行的\x20BF/ENDPOINT\x20函数,以及收敛可用\x20scriptName\x20时使用','1264Fxdcun','Execute\x20BF\x20endpoint\x20function','/api/endpoint/{appCode}/{scriptName}','Returns\x20the\x20created\x20record\x20or\x20backend\x20operation\x20result','Get\x20one\x20dataset\x20record','summary','str','validation','Aggregate\x20supports\x20COUNT,\x20SUM,\x20AVG,\x20MAX,\x20and\x20MIN\x20definitions\x20in\x20the\x20`aggregate`\x20array.','需要按数据集\x20code\x20获取字段、表信息或操作定义时使用','keyword','##\x20Dataset\x20detail','需要携带\x20where、orderBy、分页等条件读取业务数据时使用','Current\x20app\x20code','path','10635684Pgbafs','where\x20filters\x20before\x20aggregation','9854990flxWfM','Show\x20runtime\x20API\x20documentation\x20by\x20code','lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27','dataset_list','bf_function_list','{\x22param\x22:\x22value\x22}','tableData\x20contains\x20dataset\x20id/code/name','List\x20datasets','1406997WvpxlL','lovrabet\x20sql\x20exec\x20--sqlcode\x20<sqlCode>\x20--params\x20\x27{}\x27','Aggregate\x20dataset\x20data','235uqLwHu','map','appCode','/api/endpoint/{appCode}/functions','##\x20List\x20datasets','List\x20BF\x20endpoint\x20functions','Returns\x20one\x20matching\x20business\x20record','{\x22aggregate\x22:[{\x22column\x22:\x20\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}],\x22groupBy\x22:[]}','##\x20Get\x20one\x20dataset\x20record\x0a\x0aRead\x20one\x20record\x20by\x20id.','List\x20available\x20runtime\x20API\x20documentation\x20entries','Create\x20dataset\x20record','Returns\x20endpoint\x20functionName/id/description','toLowerCase','code','lovrabet\x20dataset\x20detail\x20--code\x20<datasetCode>\x20--appcode\x20<appCode>','查询单条数据','/api/{appCode}/{datasetCode}/getOne','Search\x20docs\x20by\x20code,\x20summary,\x20path,\x20or\x20usage\x20text','{\x22appCode\x22:\x22app-aa63b188\x22,\x22currentPage\x22:1,\x22pageSize\x22:100}'];a1_0x3362=function(){return _0x17bcfa;};return a1_0x3362();}
1
+ const a1_0x52d42f=a1_0x7d18;function a1_0x56cc(){const _0x287afc=['includes','read','This\x20is\x20a\x20write\x20operation;\x20use\x20dry-run\x20when\x20available\x20and\x20safe\x20fixtures\x20for\x20smoke\x20tests.','where\x20filters\x20before\x20aggregation','/api/endpoint/{appCode}/functions','条件过滤查询数据','appCode','GET','result\x20rows\x20contain\x20aggregate\x20aliases','Aggregate\x20supports\x20COUNT,\x20SUM,\x20AVG,\x20MAX,\x20and\x20MIN\x20definitions\x20in\x20the\x20`aggregate`\x20array.','datasetCode','29627970aPDtnH','join','Filter\x20docs\x20by\x20category,\x20for\x20example\x20dataset','/api/{appCode}/{datasetCode}/aggregate','summary','tableData\x20contains\x20records','##\x20List\x20BF\x20endpoint\x20functions\x0a\x0aDiscover\x20executable\x20endpoint\x20functions.','已经知道记录\x20id,需要按数据集读取单条业务数据时使用','Returns\x20SQL\x20execution\x20payload','If\x20SDK\x20usage\x20is\x20needed,\x20follow\x20with\x20`lovrabet\x20dataset\x20sdk-doc\x20--code\x20<datasetCode>`.','653378CJwCBk','detail','Show\x20runtime\x20API\x20documentation\x20by\x20code','scriptName','validation','35HeZqsz','需要按\x20appCode\x20分页获取运行态数据集列表,并优先收敛可用\x20datasetCode\x20时使用','{\x22fieldName\x22:\x22value\x22}','/api/dataset/getOneByCode?code={datasetCode}','lovrabet\x20dataset\x20detail\x20--code\x20<datasetCode>\x20--appcode\x20<appCode>','find','Use\x20`lovrabet\x20sql\x20detail`\x20before\x20execution.','API\x20doc\x20code\x20not\x20found:\x20','{\x22aggregate\x22:[{\x22column\x22:\x20\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}],\x22groupBy\x22:[]}','lovrabet\x20data\x20filter\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22currentPage\x22:1,\x22pageSize\x22:5}\x27','bf_execute','Returns\x20endpoint\x20functionName/id/description','{\x22where\x22:{},\x22currentPage\x22:1,\x22pageSize\x22:20}','Script\x20behavior\x20may\x20have\x20side\x20effects;\x20inspect\x20detail\x20first.','Returns\x20one\x20matching\x20business\x20record','dataset','##\x20Execute\x20custom\x20SQL\x0a\x0aExecute\x20a\x20configured\x20SQL\x20script\x20by\x20sqlCode.','lovrabet\x20dataset\x20list\x20--appcode\x20<appCode>\x20--format\x20compress','##\x20Aggregate\x20dataset\x20data','paging\x20contains\x20pagination','List\x20available\x20runtime\x20API\x20documentation\x20entries','需要按\x20groupBy\x20分组并做\x20count、sum、avg、max、min\x20等聚合统计时使用','已经确认目标\x20BF\x20的\x20scriptName,且需要实际调用该\x20ENDPOINT\x20脚本完成业务操作时使用','3ZnjcXb','Execute\x20custom\x20SQL','toLowerCase','tableData\x20contains\x20dataset\x20id/code/name','##\x20Execute\x20BF\x20endpoint\x20function\x0a\x0aExecute\x20a\x20known\x20endpoint\x20script.','查询单条数据','custom_sql_execute','/api/{appCode}/{datasetCode}/getOne','32-character\x20dataset\x20code','执行指定\x20BF\x20函数','770798QAlpGS','dataset_detail','##\x20Dataset\x20detail','{\x22param\x22:\x22value\x22}','{\x22appCode\x22:\x22app-aa63b188\x22,\x22sqlCode\x22:\x22xxxxxxxx-xxxxxxxx\x22,\x22params\x22:{}}','需要先确认当前应用有哪些可执行的\x20BF/ENDPOINT\x20函数,以及收敛可用\x20scriptName\x20时使用','str','lovrabet\x20sql\x20exec\x20--sqlcode\x20<sqlCode>\x20--params\x20\x27{}\x27','filter','Inspect\x20field\x20names\x20and\x20operation\x20metadata\x20for\x20a\x20known\x20dataset\x20code.','Aggregate\x20dataset\x20data','POST','Dataset\x20detail','{\x22id\x22:123}','API\x20doc\x20code,\x20for\x20example\x20dataset_list','Current\x20app\x20code','method','list','Returns\x20the\x20created\x20record\x20or\x20backend\x20operation\x20result','category','CLI\x20users\x20should\x20prefer\x20`lovrabet\x20dataset\x20list`\x20for\x20this\x20workflow.','lovrabet\x20data\x20create\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22name\x22:\x22demo\x22}\x27','whenToUse','custom_sql','969390MXKVpv','api-doc','dataset_data_get_one','需要向指定数据集新增一条业务数据时使用','None','dataset_list','trim','创建数据','lovrabet\x20data\x20aggregate\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22aggregate\x22:[{\x22column\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}]}\x27','`field`\x20is\x20accepted\x20as\x20a\x20deprecated\x20alias\x20for\x20`column`;\x20new\x20calls\x20should\x20use\x20`column`.','title','Use\x20read-only\x20data\x20commands\x20before\x20writing\x20Artifacts\x20that\x20display\x20real\x20data.','聚合查询数据集数据','fields/properties\x20describe\x20data\x20shape','code','##\x20Create\x20dataset\x20record\x0a\x0aCreate\x20one\x20data\x20record\x20in\x20a\x20dataset.','9yItWBR','Endpoint\x20function\x20name','CLI\x20has\x20typed\x20`bff\x20detail`\x20and\x20`bff\x20exec`\x20commands\x20for\x20endpoint\x20scripts.','paging.totalCount\x20gives\x20total\x20rows','Filter\x20dataset\x20data','366803nWHfZG','1514440oNtcRG','List\x20datasets','keyword','operations\x20describes\x20runtime\x20APIs','Use\x20`having`\x20only\x20for\x20post-aggregation\x20filters.','string','/api/custom/executeSql','bf_function_list','已经确认目标\x20sqlCode\x20存在,并需要实际执行该自定义\x20SQL\x20时使用','lovrabet\x20bff\x20detail\x20--id\x20<scriptId>\x20--appcode\x20<appCode>','6014728PjAutW','/api/{appCode}/{datasetCode}/filter'];a1_0x56cc=function(){return _0x287afc;};return a1_0x56cc();}function a1_0x7d18(_0x2bd972,_0xf73846){_0x2bd972=_0x2bd972-0x160;const _0x56cc99=a1_0x56cc();let _0x7d18a1=_0x56cc99[_0x2bd972];return _0x7d18a1;}(function(_0x3965f4,_0x158705){const _0xe26c81=a1_0x7d18,_0x35d512=_0x3965f4();while(!![]){try{const _0x2dec4c=-parseInt(_0xe26c81(0x16f))/0x1+-parseInt(_0xe26c81(0x191))/0x2+parseInt(_0xe26c81(0x1ad))/0x3*(parseInt(_0xe26c81(0x170))/0x4)+parseInt(_0xe26c81(0x196))/0x5*(-parseInt(_0xe26c81(0x1cf))/0x6)+-parseInt(_0xe26c81(0x1b7))/0x7+-parseInt(_0xe26c81(0x17a))/0x8+-parseInt(_0xe26c81(0x16a))/0x9*(-parseInt(_0xe26c81(0x187))/0xa);if(_0x2dec4c===_0x158705)break;else _0x35d512['push'](_0x35d512['shift']());}catch(_0x629cc9){_0x35d512['push'](_0x35d512['shift']());}}}(a1_0x56cc,0x9fe9d));import{CliErrors}from'../../errors.js';const CATEGORY_FLAG={'name':'category','type':a1_0x52d42f(0x175),'description':a1_0x52d42f(0x189)},KEYWORD_FLAG={'name':a1_0x52d42f(0x172),'type':a1_0x52d42f(0x175),'description':'Search\x20docs\x20by\x20code,\x20summary,\x20path,\x20or\x20usage\x20text'},DOC_CODE_FLAG={'name':a1_0x52d42f(0x168),'type':a1_0x52d42f(0x175),'required':!![],'description':a1_0x52d42f(0x1c5)},DOCS=[{'code':a1_0x52d42f(0x1d4),'category':'dataset','title':a1_0x52d42f(0x171),'method':a1_0x52d42f(0x1c2),'path':'/api/dataset/get-dataset-list-by-app-code','summary':'分页获取数据集列表','whenToUse':a1_0x52d42f(0x197),'pathParams':[],'queryParams':[],'bodySchema':'{\x22appCode\x22:\x22app-aa63b188\x22,\x22currentPage\x22:1,\x22pageSize\x22:100}','responseHighlights':[a1_0x52d42f(0x1b0),a1_0x52d42f(0x16d)],'examples':[a1_0x52d42f(0x1a7)],'notes':[a1_0x52d42f(0x1cb)],'markdown':['##\x20List\x20datasets','','Use\x20this\x20API\x20or\x20`lovrabet\x20dataset\x20list`\x20to\x20discover\x20available\x20dataset\x20codes\x20before\x20reading\x20data.'][a1_0x52d42f(0x188)]('\x0a')},{'code':a1_0x52d42f(0x1b8),'category':'dataset','title':a1_0x52d42f(0x1c3),'method':a1_0x52d42f(0x183),'path':a1_0x52d42f(0x199),'summary':'获取数据集详情','whenToUse':'需要按数据集\x20code\x20获取字段、表信息或操作定义时使用','pathParams':[],'queryParams':[{'name':'code','description':a1_0x52d42f(0x1b5)}],'bodySchema':a1_0x52d42f(0x1d3),'responseHighlights':[a1_0x52d42f(0x167),a1_0x52d42f(0x173)],'examples':[a1_0x52d42f(0x19a)],'notes':[a1_0x52d42f(0x190)],'markdown':[a1_0x52d42f(0x1b9),'',a1_0x52d42f(0x1c0)][a1_0x52d42f(0x188)]('\x0a')},{'code':'dataset_data_filter','category':a1_0x52d42f(0x1a5),'title':a1_0x52d42f(0x16e),'method':a1_0x52d42f(0x1c2),'path':a1_0x52d42f(0x17b),'summary':a1_0x52d42f(0x181),'whenToUse':'需要携带\x20where、orderBy、分页等条件读取业务数据时使用','pathParams':[{'name':a1_0x52d42f(0x182),'description':a1_0x52d42f(0x1c6)},{'name':a1_0x52d42f(0x186),'description':a1_0x52d42f(0x1b5)}],'queryParams':[],'bodySchema':a1_0x52d42f(0x1a2),'responseHighlights':[a1_0x52d42f(0x18c),a1_0x52d42f(0x1a9)],'examples':[a1_0x52d42f(0x19f)],'notes':[a1_0x52d42f(0x165)],'markdown':['##\x20Filter\x20dataset\x20data','','Use\x20`where`,\x20`select`,\x20`orderBy`,\x20`currentPage`,\x20and\x20`pageSize`\x20to\x20inspect\x20live\x20data\x20shape.'][a1_0x52d42f(0x188)]('\x0a')},{'code':'dataset_data_aggregate','category':'dataset','title':a1_0x52d42f(0x1c1),'method':a1_0x52d42f(0x1c2),'path':a1_0x52d42f(0x18a),'summary':a1_0x52d42f(0x166),'whenToUse':a1_0x52d42f(0x1ab),'pathParams':[{'name':a1_0x52d42f(0x182),'description':a1_0x52d42f(0x1c6)},{'name':'datasetCode','description':a1_0x52d42f(0x1b5)}],'queryParams':[],'bodySchema':a1_0x52d42f(0x19e),'responseHighlights':[a1_0x52d42f(0x184),a1_0x52d42f(0x17f)],'examples':[a1_0x52d42f(0x162)],'notes':[a1_0x52d42f(0x174),a1_0x52d42f(0x163)],'markdown':[a1_0x52d42f(0x1a8),'',a1_0x52d42f(0x185)][a1_0x52d42f(0x188)]('\x0a')},{'code':a1_0x52d42f(0x1d1),'category':a1_0x52d42f(0x1a5),'title':'Get\x20one\x20dataset\x20record','method':a1_0x52d42f(0x1c2),'path':a1_0x52d42f(0x1b4),'summary':a1_0x52d42f(0x1b2),'whenToUse':a1_0x52d42f(0x18e),'pathParams':[{'name':'appCode','description':'Current\x20app\x20code'},{'name':a1_0x52d42f(0x186),'description':a1_0x52d42f(0x1b5)}],'queryParams':[],'bodySchema':a1_0x52d42f(0x1c4),'responseHighlights':[a1_0x52d42f(0x1a4)],'examples':['lovrabet\x20data\x20getOne\x20--code\x20<datasetCode>\x20--params\x20\x27{\x22id\x22:123}\x27'],'notes':['Prefer\x20`filter`\x20when\x20the\x20record\x20id\x20is\x20unknown.'],'markdown':'##\x20Get\x20one\x20dataset\x20record\x0a\x0aRead\x20one\x20record\x20by\x20id.'},{'code':'dataset_data_create','category':a1_0x52d42f(0x1a5),'title':'Create\x20dataset\x20record','method':'POST','path':'/api/{appCode}/{datasetCode}/create','summary':a1_0x52d42f(0x161),'whenToUse':a1_0x52d42f(0x1d2),'pathParams':[{'name':'appCode','description':a1_0x52d42f(0x1c6)},{'name':a1_0x52d42f(0x186),'description':a1_0x52d42f(0x1b5)}],'queryParams':[],'bodySchema':a1_0x52d42f(0x198),'responseHighlights':[a1_0x52d42f(0x1c9)],'examples':[a1_0x52d42f(0x1cc)],'notes':[a1_0x52d42f(0x17e)],'markdown':a1_0x52d42f(0x169)},{'code':a1_0x52d42f(0x177),'category':'bf','title':'List\x20BF\x20endpoint\x20functions','method':a1_0x52d42f(0x183),'path':a1_0x52d42f(0x180),'summary':'获取应用下可调用的\x20BF\x20函数列表','whenToUse':a1_0x52d42f(0x1bc),'pathParams':[{'name':a1_0x52d42f(0x182),'description':a1_0x52d42f(0x1c6)}],'queryParams':[],'bodySchema':a1_0x52d42f(0x1d3),'responseHighlights':[a1_0x52d42f(0x1a1)],'examples':[a1_0x52d42f(0x179)],'notes':[a1_0x52d42f(0x16c)],'markdown':a1_0x52d42f(0x18d)},{'code':a1_0x52d42f(0x1a0),'category':'bf','title':'Execute\x20BF\x20endpoint\x20function','method':a1_0x52d42f(0x1c2),'path':'/api/endpoint/{appCode}/{scriptName}','summary':a1_0x52d42f(0x1b6),'whenToUse':a1_0x52d42f(0x1ac),'pathParams':[{'name':'appCode','description':a1_0x52d42f(0x1c6)},{'name':a1_0x52d42f(0x194),'description':a1_0x52d42f(0x16b)}],'queryParams':[],'bodySchema':a1_0x52d42f(0x1ba),'responseHighlights':['Returns\x20script\x20business\x20payload'],'examples':['lovrabet\x20bff\x20exec\x20--name\x20<functionName>\x20--params\x20\x27{}\x27'],'notes':[a1_0x52d42f(0x1a3)],'markdown':a1_0x52d42f(0x1b1)},{'code':a1_0x52d42f(0x1b3),'category':a1_0x52d42f(0x1ce),'title':a1_0x52d42f(0x1ae),'method':a1_0x52d42f(0x1c2),'path':a1_0x52d42f(0x176),'summary':'执行自定义\x20SQL','whenToUse':a1_0x52d42f(0x178),'pathParams':[],'queryParams':[],'bodySchema':a1_0x52d42f(0x1bb),'responseHighlights':[a1_0x52d42f(0x18f)],'examples':[a1_0x52d42f(0x1be)],'notes':[a1_0x52d42f(0x19c)],'markdown':a1_0x52d42f(0x1a6)}];function entrySummary(_0x2e7413){const _0x473a7c=a1_0x52d42f;return{'code':_0x2e7413['code'],'category':_0x2e7413[_0x473a7c(0x1ca)],'method':_0x2e7413[_0x473a7c(0x1c7)],'path':_0x2e7413['path'],'summary':_0x2e7413[_0x473a7c(0x18b)],'whenToUse':_0x2e7413[_0x473a7c(0x1cd)]};}export function listApiDocEntries(_0x193ea0={}){const _0x3dbfa0=a1_0x52d42f,_0x34c9a3=String(_0x193ea0[_0x3dbfa0(0x1ca)]||'')[_0x3dbfa0(0x160)](),_0x1c3b12=String(_0x193ea0[_0x3dbfa0(0x172)]||'')['trim']()['toLowerCase']();return DOCS[_0x3dbfa0(0x1bf)](_0x3d7c5f=>{const _0x2c4711=_0x3dbfa0;if(_0x34c9a3&&_0x3d7c5f[_0x2c4711(0x1ca)]!==_0x34c9a3)return![];if(!_0x1c3b12)return!![];return[_0x3d7c5f[_0x2c4711(0x168)],_0x3d7c5f[_0x2c4711(0x1ca)],_0x3d7c5f['method'],_0x3d7c5f['path'],_0x3d7c5f[_0x2c4711(0x18b)],_0x3d7c5f[_0x2c4711(0x1cd)],_0x3d7c5f[_0x2c4711(0x164)]][_0x2c4711(0x188)]('\x20')[_0x2c4711(0x1af)]()[_0x2c4711(0x17c)](_0x1c3b12);})['map'](entrySummary);}export function getApiDocDetail(_0x51f3a3){const _0x99640f=a1_0x52d42f,_0x3b5c91=DOCS[_0x99640f(0x19b)](_0x5253b0=>_0x5253b0['code']===_0x51f3a3);if(!_0x3b5c91)throw CliErrors[_0x99640f(0x195)](_0x99640f(0x19d)+_0x51f3a3);return{..._0x3b5c91};}const apiDocList={'service':a1_0x52d42f(0x1d0),'command':a1_0x52d42f(0x1c8),'description':a1_0x52d42f(0x1aa),'risk':'read','requiresAppCode':![],'flags':[CATEGORY_FLAG,KEYWORD_FLAG],async 'execute'(_0x6b6323){const _0x3c850e=a1_0x52d42f,_0x5bb4c1=listApiDocEntries({'category':_0x6b6323[_0x3c850e(0x1bd)](_0x3c850e(0x1ca)),'keyword':_0x6b6323[_0x3c850e(0x1bd)]('keyword')});return{'ok':!![],'data':{'total':_0x5bb4c1['length'],'items':_0x5bb4c1}};}},apiDocDetail={'service':a1_0x52d42f(0x1d0),'command':a1_0x52d42f(0x192),'description':a1_0x52d42f(0x193),'risk':a1_0x52d42f(0x17d),'requiresAppCode':![],'flags':[DOC_CODE_FLAG],async 'execute'(_0x4b8ac7){const _0x21f077=a1_0x52d42f;return{'ok':!![],'data':getApiDocDetail(_0x4b8ac7['str'](_0x21f077(0x168)))};}};export const apiDocDefinitions=[apiDocList,apiDocDetail];
@@ -1 +1 @@
1
- (function(_0xd53fa1,_0x44afc9){const _0x1c25e3=a2_0x5abf,_0x2dab57=_0xd53fa1();while(!![]){try{const _0x56ff80=parseInt(_0x1c25e3(0x1e1))/0x1+-parseInt(_0x1c25e3(0x1dc))/0x2+parseInt(_0x1c25e3(0x1cc))/0x3*(parseInt(_0x1c25e3(0x1e4))/0x4)+parseInt(_0x1c25e3(0x1da))/0x5*(parseInt(_0x1c25e3(0x1cf))/0x6)+parseInt(_0x1c25e3(0x1d1))/0x7+-parseInt(_0x1c25e3(0x1d9))/0x8+-parseInt(_0x1c25e3(0x1d5))/0x9*(parseInt(_0x1c25e3(0x1dd))/0xa);if(_0x56ff80===_0x44afc9)break;else _0x2dab57['push'](_0x2dab57['shift']());}catch(_0x4454b5){_0x2dab57['push'](_0x2dab57['shift']());}}}(a2_0x221c,0x7ed2b));import{createHash}from'node:crypto';function a2_0x221c(){const _0x5955ef=['371339TDPROK','utf8','digest','12QQSqPE','isArray','items','658551HZTVOd','cache','sha256','18aGNCoX','EPERM','1087723VUHVUA','slice','hex','ak_','126BtmXyf','my-apps.json','find','code','586352DGQnGU','1406245amLWdt','trim','122566tQlPCB','982130SiPOwb','homeDirName','.tmp','stringify'];a2_0x221c=function(){return _0x5955ef;};return a2_0x221c();}import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{homedir}from'node:os';import{dirname,resolve}from'node:path';import{PRODUCT_CONFIG}from'../../constant/product.js';import{isRuntimeAccessibleApp}from'../../commands/app/eligibility.js';function a2_0x5abf(_0x39ed03,_0x43fb96){_0x39ed03=_0x39ed03-0x1cb;const _0x221c3=a2_0x221c();let _0x5abf37=_0x221c3[_0x39ed03];return _0x5abf37;}export function fingerprintAccessKey(_0x4c6d57){const _0x4e29c9=a2_0x5abf,_0x902822=_0x4c6d57[_0x4e29c9(0x1db)](),_0x4f5fd5=_0x902822['slice'](-0x6)||'unknown',_0x3cd46a=createHash(_0x4e29c9(0x1ce))['update'](_0x902822)[_0x4e29c9(0x1e3)](_0x4e29c9(0x1d3))[_0x4e29c9(0x1d2)](0x0,0xc);return _0x4e29c9(0x1d4)+_0x4f5fd5+'_'+_0x3cd46a;}export function getAppCacheFilePath(_0x591f32,_0x5e3c46){const _0x11c0b3=a2_0x5abf;return resolve(homedir(),PRODUCT_CONFIG[_0x11c0b3(0x1de)],_0x11c0b3(0x1cd),_0x591f32,fingerprintAccessKey(_0x5e3c46),_0x11c0b3(0x1d6));}export function readCachedAppList(_0x135612,_0x26b1bd){const _0x2bc100=a2_0x5abf;if(!_0x26b1bd?.['trim']())return null;const _0x2456f9=getAppCacheFilePath(_0x135612,_0x26b1bd);if(!existsSync(_0x2456f9))return null;try{const _0x30ed3b=readFileSync(_0x2456f9,'utf8');if(!_0x30ed3b[_0x2bc100(0x1db)]())return null;const _0xac8ced=JSON['parse'](_0x30ed3b);if(!Array[_0x2bc100(0x1e5)](_0xac8ced[_0x2bc100(0x1cb)]))return null;return _0xac8ced;}catch{return null;}}export function writeCachedAppList(_0x2994f,_0x419b8b,_0x273af3){const _0x12cd4f=a2_0x5abf,_0x1d69a7=getAppCacheFilePath(_0x2994f,_0x419b8b),_0x44de58=dirname(_0x1d69a7);!existsSync(_0x44de58)&&mkdirSync(_0x44de58,{'recursive':!![]});const _0x30fb17=_0x1d69a7+_0x12cd4f(0x1df);try{writeFileSync(_0x30fb17,JSON[_0x12cd4f(0x1e0)](_0x273af3,null,0x2)+'\x0a',{'encoding':_0x12cd4f(0x1e2),'mode':0x180});try{renameSync(_0x30fb17,_0x1d69a7);}catch(_0x4a16b7){if(_0x4a16b7[_0x12cd4f(0x1d8)]===_0x12cd4f(0x1d0)||_0x4a16b7[_0x12cd4f(0x1d8)]==='EXDEV'||_0x4a16b7[_0x12cd4f(0x1d8)]==='EACCES'){writeFileSync(_0x1d69a7,JSON['stringify'](_0x273af3,null,0x2)+'\x0a',{'encoding':_0x12cd4f(0x1e2)});try{unlinkSync(_0x30fb17);}catch{}}else throw _0x4a16b7;}}catch(_0x128df3){try{unlinkSync(_0x30fb17);}catch{}throw _0x128df3;}return _0x1d69a7;}export function resolveCachedAppCode(_0x379d32,_0x1ebb1c,_0x23d2be){const _0x188f70=a2_0x5abf;if(!_0x379d32)return undefined;const _0x1ddedf=readCachedAppList(_0x1ebb1c,_0x23d2be),_0x137617=_0x1ddedf?.[_0x188f70(0x1cb)][_0x188f70(0x1d7)](_0x5dd162=>_0x5dd162['appName']===_0x379d32&&isRuntimeAccessibleApp(_0x5dd162));return _0x137617?.['appCode']?.[_0x188f70(0x1db)]()||undefined;}
1
+ (function(_0x5dc696,_0x48f0c5){const _0xc3641c=a2_0x207c,_0x98eb4c=_0x5dc696();while(!![]){try{const _0x3d8317=-parseInt(_0xc3641c(0x1fa))/0x1+parseInt(_0xc3641c(0x1ee))/0x2+parseInt(_0xc3641c(0x1f5))/0x3*(-parseInt(_0xc3641c(0x203))/0x4)+parseInt(_0xc3641c(0x204))/0x5+parseInt(_0xc3641c(0x1fc))/0x6*(-parseInt(_0xc3641c(0x1f4))/0x7)+parseInt(_0xc3641c(0x209))/0x8+-parseInt(_0xc3641c(0x1f2))/0x9*(parseInt(_0xc3641c(0x1f8))/0xa);if(_0x3d8317===_0x48f0c5)break;else _0x98eb4c['push'](_0x98eb4c['shift']());}catch(_0x21688b){_0x98eb4c['push'](_0x98eb4c['shift']());}}}(a2_0x3167,0xc8c54));import{createHash}from'node:crypto';import{existsSync,mkdirSync,readFileSync,renameSync,unlinkSync,writeFileSync}from'node:fs';import{homedir}from'node:os';import{dirname,resolve}from'node:path';function a2_0x3167(){const _0x1adf16=['11474424MPviyy','.tmp','ak_','isArray','2038900WjRYaX','appCode','parse','sha256','6687XzcFSK','trim','7IcOqSB','68427veQhWv','homeDirName','items','12230zBAIBn','digest','721811AiUusx','utf8','6982314SRkbke','EXDEV','update','code','EACCES','slice','unknown','4ObuORW','5928155CkIrra','my-apps.json','EPERM','stringify','find'];a2_0x3167=function(){return _0x1adf16;};return a2_0x3167();}import{PRODUCT_CONFIG}from'../../constant/product.js';import{isRuntimeAccessibleApp}from'../../commands/app/eligibility.js';export function fingerprintAccessKey(_0x57d6c6){const _0x45ac01=a2_0x207c,_0x4c7e4a=_0x57d6c6['trim'](),_0x5ec1b9=_0x4c7e4a['slice'](-0x6)||_0x45ac01(0x202),_0x51c446=createHash(_0x45ac01(0x1f1))[_0x45ac01(0x1fe)](_0x4c7e4a)[_0x45ac01(0x1f9)]('hex')[_0x45ac01(0x201)](0x0,0xc);return _0x45ac01(0x1ec)+_0x5ec1b9+'_'+_0x51c446;}export function getAppCacheFilePath(_0x5e5bed,_0x299833){const _0x1feeaf=a2_0x207c;return resolve(homedir(),PRODUCT_CONFIG[_0x1feeaf(0x1f6)],'cache',_0x5e5bed,fingerprintAccessKey(_0x299833),_0x1feeaf(0x205));}export function readCachedAppList(_0x2a4e64,_0xcc55ef){const _0x5af930=a2_0x207c;if(!_0xcc55ef?.[_0x5af930(0x1f3)]())return null;const _0x48ce8c=getAppCacheFilePath(_0x2a4e64,_0xcc55ef);if(!existsSync(_0x48ce8c))return null;try{const _0x5e1598=readFileSync(_0x48ce8c,_0x5af930(0x1fb));if(!_0x5e1598['trim']())return null;const _0x5a3ebb=JSON[_0x5af930(0x1f0)](_0x5e1598);if(!Array[_0x5af930(0x1ed)](_0x5a3ebb[_0x5af930(0x1f7)]))return null;return _0x5a3ebb;}catch{return null;}}function a2_0x207c(_0x2d97bb,_0x543592){_0x2d97bb=_0x2d97bb-0x1ec;const _0x31675d=a2_0x3167();let _0x207c1e=_0x31675d[_0x2d97bb];return _0x207c1e;}export function writeCachedAppList(_0x39d3b0,_0xe35e6a,_0x10d702){const _0x938163=a2_0x207c,_0x5be2e3=getAppCacheFilePath(_0x39d3b0,_0xe35e6a),_0x593f4f=dirname(_0x5be2e3);!existsSync(_0x593f4f)&&mkdirSync(_0x593f4f,{'recursive':!![]});const _0x43033f=_0x5be2e3+_0x938163(0x20a);try{writeFileSync(_0x43033f,JSON[_0x938163(0x207)](_0x10d702,null,0x2)+'\x0a',{'encoding':_0x938163(0x1fb),'mode':0x180});try{renameSync(_0x43033f,_0x5be2e3);}catch(_0x3f72ea){if(_0x3f72ea[_0x938163(0x1ff)]===_0x938163(0x206)||_0x3f72ea[_0x938163(0x1ff)]===_0x938163(0x1fd)||_0x3f72ea['code']===_0x938163(0x200)){writeFileSync(_0x5be2e3,JSON[_0x938163(0x207)](_0x10d702,null,0x2)+'\x0a',{'encoding':_0x938163(0x1fb)});try{unlinkSync(_0x43033f);}catch{}}else throw _0x3f72ea;}}catch(_0x457b3d){try{unlinkSync(_0x43033f);}catch{}throw _0x457b3d;}return _0x5be2e3;}export function resolveCachedAppCode(_0x1eaad5,_0x577560,_0x5201ab){const _0x43065c=a2_0x207c;if(!_0x1eaad5)return undefined;const _0x550d21=readCachedAppList(_0x577560,_0x5201ab),_0x1db933=_0x550d21?.[_0x43065c(0x1f7)][_0x43065c(0x208)](_0x451065=>_0x451065['appName']===_0x1eaad5&&isRuntimeAccessibleApp(_0x451065));return _0x1db933?.[_0x43065c(0x1ef)]?.[_0x43065c(0x1f3)]()||undefined;}
@@ -1 +1 @@
1
- const a3_0x197a9c=a3_0x2d89;(function(_0x490b87,_0x3a3225){const _0x174d32=a3_0x2d89,_0x242dbd=_0x490b87();while(!![]){try{const _0x5a5fd4=parseInt(_0x174d32(0x16b))/0x1+-parseInt(_0x174d32(0x148))/0x2*(parseInt(_0x174d32(0x158))/0x3)+-parseInt(_0x174d32(0x136))/0x4*(parseInt(_0x174d32(0x12b))/0x5)+-parseInt(_0x174d32(0x138))/0x6+parseInt(_0x174d32(0x152))/0x7*(-parseInt(_0x174d32(0x147))/0x8)+parseInt(_0x174d32(0x133))/0x9*(parseInt(_0x174d32(0x162))/0xa)+parseInt(_0x174d32(0x178))/0xb;if(_0x5a5fd4===_0x3a3225)break;else _0x242dbd['push'](_0x242dbd['shift']());}catch(_0x25c75f){_0x242dbd['push'](_0x242dbd['shift']());}}}(a3_0x5733,0xeb10d));import{CliErrors}from'../../errors.js';function a3_0x2d89(_0x329d35,_0xf22bab){_0x329d35=_0x329d35-0x120;const _0x5733ee=a3_0x5733();let _0x2d89d8=_0x5733ee[_0x329d35];return _0x2d89d8;}import{initCreateFlagDefs,initImportFlagDefs,runInit,runInitImport}from'../../commands/init.js';import{getEnv,RUNTIME_ENV_VALUES}from'../../constant/env.js';import{buildAppProfileListFields}from'../../config/schema.js';import{CLI_BIN_NAME,readConfig,writeConfig,scopeLabel,enrichAppListItemsWithMergedSelection}from'../../commands/app/shared.js';import{resolveConfigScope,toScopeFlags}from'../../commands/common/config-policy.js';import{filterRuntimeAccessibleApps,findAppByCode,isRuntimeAccessibleApp,runtimeInaccessibleAppError}from'../../commands/app/eligibility.js';const GLOBAL_FLAG={'name':a3_0x197a9c(0x163),'type':a3_0x197a9c(0x126),'description':a3_0x197a9c(0x15c),'default':![]};function a3_0x5733(){const _0x39c95c=['Target\x20environment\x20(default:\x20current\x20env)','Use\x20global\x20config\x20scope','string','local','Use\x20`','defaultApp','read','10XfSZQW','global','Deprecated:\x20use\x20workspace\x20init\x20to\x20bind\x20the\x20current\x20directory\x20to\x20an\x20app','validation','../../context.js','items','appName','Loaded\x20','\x20workspace\x20use\x20--app\x20<name>\x20[--env\x20daily]','12184NncHYd','length','str','no-cache','trim','pull','envName','production','App\x20\x22','entries','isCurrent','Default\x20app\x20candidate\x20set\x20to\x20\x22','projectPath','26760833WVRxpO','join','mergedCli','\x20app\x20','appcode','cachePath','\x22\x20not\x20found.','No\x20cached\x20apps\x20found.','\x20app\x20list`\x20to\x20discover\x20remote\x20apps,\x20or\x20add\x20apps.','boolean','Deprecated:\x20use\x20workspace\x20use\x20to\x20bind\x20the\x20current\x20directory\x20to\x20an\x20app','Import\x20the\x20default\x20app\x20selection\x20from\x20a\x20.rabetbase.json\x20file','No\x20apps\x20found\x20on\x20the\x20platform.','fetchedAt','50145nXIDKW','Read\x20from\x20local\x20cache\x20only','use','source','`\x20instead.','args','env','../../commands/app/remote-source.js','14973399oovGee','i18nInfo','Refresh\x20the\x20local\x20app\x20cache\x20from\x20the\x20platform','32zAnKhc','app','2853504yXLtBf','enableI18n','\x20app\x20use\x20<name>\x20[--global]','bool','init','appOwnerName','list','from','find','Filter\x20by\x20environment\x20(default:\x20current\x20env)','map','accessKey','\x20cached\x20app(s)\x20for\x20env=\x22','push','raw','6326296BPSrNu','2016958IAIzsP','isArray','\x20workspace\x20init\x20--appcode\x20<code>\x20[--env\x20daily]','Read\x20app\x20list\x20from\x20local\x20cache\x20only','\x20app(s)\x20for\x20env=\x22','filter','Remote\x20app\x20name\x20to\x20activate','include-unpublished','remote','Refreshed\x20app\x20cache\x20with\x20','14EuLlYc','name','appCode','../../commands/app/cache.js','warn','nonInteractive','3CjwddT','Missing\x20app\x20name.','Force\x20remote\x20fetch\x20and\x20refresh\x20local\x20cache'];a3_0x5733=function(){return _0x39c95c;};return a3_0x5733();}function collectFlags(_0x204f27,_0x1d7b83){const _0x31bb1e=a3_0x197a9c,_0x5ee2e0={};for(const _0x55e21c of _0x1d7b83){const _0x4c687f=_0x55e21c['type']===_0x31bb1e(0x126)?_0x204f27[_0x31bb1e(0x13b)](_0x55e21c[_0x31bb1e(0x153)]):_0x204f27[_0x31bb1e(0x16d)](_0x55e21c[_0x31bb1e(0x153)]);if(_0x4c687f!==''&&_0x4c687f!==![])_0x5ee2e0[_0x55e21c[_0x31bb1e(0x153)]]=_0x4c687f;}if(_0x204f27[_0x31bb1e(0x157)])_0x5ee2e0['nonInteractive']=!![];return _0x5ee2e0;}function normalizeLanguages(_0x520856){const _0x2aa14c=a3_0x197a9c;if(!Array[_0x2aa14c(0x149)](_0x520856))return[];return _0x520856[_0x2aa14c(0x14d)](_0x391db3=>typeof _0x391db3===_0x2aa14c(0x15d))['map'](_0x2de3d1=>_0x2de3d1['trim']())[_0x2aa14c(0x14d)](Boolean);}function buildRemoteAppI18nFields(_0x51a391){const _0x32407f=a3_0x197a9c,_0x3be8fb=normalizeLanguages(_0x51a391['i18nInfo']?.['langs']);return{'enableI18n':typeof _0x51a391[_0x32407f(0x139)]===_0x32407f(0x126)?_0x51a391[_0x32407f(0x139)]:null,'languages':_0x3be8fb,'i18nInfo':_0x51a391[_0x32407f(0x134)]?{..._0x51a391['i18nInfo'],'langs':_0x3be8fb[_0x32407f(0x16c)]?_0x3be8fb:null}:null};}const initDef={'service':a3_0x197a9c(0x137),'command':a3_0x197a9c(0x13c),'description':a3_0x197a9c(0x164),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':initCreateFlagDefs,async 'execute'(_0x3341b9){const _0x2301b8=a3_0x197a9c;return warnDeprecatedAppCommand('init',CLI_BIN_NAME+_0x2301b8(0x14a)),await runInit(collectFlags(_0x3341b9,initCreateFlagDefs)),{'ok':!![]};}},listDef={'service':a3_0x197a9c(0x137),'command':a3_0x197a9c(0x13e),'description':'List\x20apps\x20available\x20to\x20the\x20current\x20access\x20key','risk':a3_0x197a9c(0x161),'requiresAuth':!![],'requiresAppCode':![],'hasFormat':!![],'flags':[{'name':a3_0x197a9c(0x131),'type':a3_0x197a9c(0x15d),'description':a3_0x197a9c(0x141),'enum':[...RUNTIME_ENV_VALUES]},{'name':a3_0x197a9c(0x15e),'type':a3_0x197a9c(0x126),'description':a3_0x197a9c(0x14b),'default':![]},{'name':a3_0x197a9c(0x16e),'type':a3_0x197a9c(0x126),'description':a3_0x197a9c(0x15a),'default':![]},{'name':a3_0x197a9c(0x14f),'type':a3_0x197a9c(0x126),'description':'Include\x20unpublished\x20apps\x20for\x20diagnostics','default':![]}],async 'execute'(_0x2475bc){const _0x51408c=a3_0x197a9c,_0x5bcdba=_0x2475bc['str'](_0x51408c(0x131))||_0x2475bc[_0x51408c(0x171)]||getEnv()||_0x51408c(0x172),_0x53eb9e=_0x2475bc[_0x51408c(0x13b)](_0x51408c(0x15e)),_0x390e16=_0x2475bc[_0x51408c(0x13b)]('no-cache'),_0x4f9419=_0x2475bc[_0x51408c(0x13b)](_0x51408c(0x14f)),{readRawConfigWithLayers:_0xa2182d,resolveDefaultAppSource:_0x44adbf,getLocalAppAliases:_0x5c0ac2}=await import(_0x51408c(0x166)),{getRemoteAppList:_0x1d90d1}=await import(_0x51408c(0x132)),{config:_0x55b3cf,layers:_0x5a713f}=_0xa2182d(),_0x5c733c=_0x44adbf(_0x5a713f),{defaultApp:_0x1c0ac5}=_0x55b3cf,_0x2b5e8a=await _0x1d90d1({'env':_0x5bcdba,'accessKey':_0x2475bc[_0x51408c(0x143)],'localOnly':_0x53eb9e,'noCache':_0x390e16}),_0x1b3df9=_0x4f9419?_0x2b5e8a[_0x51408c(0x167)]:filterRuntimeAccessibleApps(_0x2b5e8a[_0x51408c(0x167)]),_0xce6ad1=_0x2b5e8a[_0x51408c(0x167)]['length']-_0x1b3df9['length'],_0xea81b4=_0x1b3df9[_0x51408c(0x142)](_0x4cefa4=>{const _0xaffa65=_0x51408c;return{'name':_0x4cefa4[_0xaffa65(0x168)],'appcode':_0x4cefa4['appCode'],'named':!![],'definedIn':_0xaffa65(0x150),'isDefault':_0x4cefa4[_0xaffa65(0x168)]===_0x1c0ac5,...buildAppProfileListFields(_0x5bcdba),...buildRemoteAppI18nFields(_0x4cefa4),'source':_0x2b5e8a[_0xaffa65(0x12e)],'owner':_0x4cefa4[_0xaffa65(0x13d)]??null,'status':_0x4cefa4['appPublishStatus']??null,'cachedAt':_0x2b5e8a[_0xaffa65(0x12a)]};}),_0x2394f7=_0x5c0ac2(_0x55b3cf);let _0x5e0e3f=0x0;for(const [_0x372f07,_0x38b37d]of Object[_0x51408c(0x174)](_0x2394f7)){const _0x2683bf=typeof _0x38b37d[_0x51408c(0x121)]==='string'?_0x38b37d['appcode'][_0x51408c(0x16f)]():'';if(!_0x2683bf)continue;const _0x3d0b36=findAppByCode(_0x2b5e8a[_0x51408c(0x167)],_0x2683bf);if(!_0x4f9419&&_0x3d0b36&&!isRuntimeAccessibleApp(_0x3d0b36))continue;_0x5e0e3f+=0x1,_0xea81b4[_0x51408c(0x145)]({'name':_0x372f07,'appcode':_0x2683bf,'named':!![],'definedIn':'local','isDefault':_0x372f07===_0x1c0ac5,...buildAppProfileListFields(_0x5bcdba),'source':'config','owner':null,'status':null,'cachedAt':null});}enrichAppListItemsWithMergedSelection(_0xea81b4,_0x2475bc[_0x51408c(0x17a)]);const _0x582e2c=_0xea81b4[_0x51408c(0x140)](_0x545853=>_0x545853[_0x51408c(0x175)]===!![]),_0x44b197=_0x1c0ac5??_0x582e2c?.['name']??null,_0x3ef7ca={'env':_0x5bcdba,'source':_0x2b5e8a[_0x51408c(0x12e)],'fetchedAt':_0x2b5e8a[_0x51408c(0x12a)],'cachePath':_0x2b5e8a[_0x51408c(0x122)],'globalPath':_0x5a713f['globalPath']??null,'projectPath':_0x5a713f[_0x51408c(0x177)]??null,'defaultApp':_0x44b197,'defaultAppSource':_0x1c0ac5!=null?_0x5c733c:null,'localAliasCount':_0x5e0e3f,'remoteTotal':_0x2b5e8a[_0x51408c(0x167)][_0x51408c(0x16c)],'hiddenUnpublishedCount':_0xce6ad1,'includeUnpublished':_0x4f9419};if(_0xea81b4[_0x51408c(0x16c)]===0x0)return{'ok':!![],'data':{'items':_0xea81b4,'meta':_0x3ef7ca},'message':_0x2b5e8a[_0x51408c(0x12e)]==='cache'?_0x51408c(0x124):_0x51408c(0x129)};return{'ok':!![],'data':{'items':_0xea81b4,'meta':_0x3ef7ca}};}},pullDef={'service':a3_0x197a9c(0x137),'command':a3_0x197a9c(0x170),'description':a3_0x197a9c(0x135),'risk':'write','requiresAuth':!![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':'env','type':a3_0x197a9c(0x15d),'description':a3_0x197a9c(0x15b),'enum':[...RUNTIME_ENV_VALUES]},{'name':a3_0x197a9c(0x15e),'type':a3_0x197a9c(0x126),'description':a3_0x197a9c(0x12c),'default':![]},{'name':a3_0x197a9c(0x16e),'type':a3_0x197a9c(0x126),'description':'Force\x20remote\x20fetch\x20and\x20refresh\x20local\x20cache','default':![]}],async 'execute'(_0x554718){const _0x230413=a3_0x197a9c,_0x43e7f9=_0x554718[_0x230413(0x16d)](_0x230413(0x131))||_0x554718[_0x230413(0x171)]||getEnv()||_0x230413(0x172),_0x18196f=_0x554718[_0x230413(0x13b)](_0x230413(0x15e)),_0x4a9a44=_0x554718[_0x230413(0x13b)](_0x230413(0x16e)),{getRemoteAppList:_0x342e97}=await import(_0x230413(0x132)),_0x5e42cb=await _0x342e97({'env':_0x43e7f9,'accessKey':_0x554718[_0x230413(0x143)],'localOnly':_0x18196f,'noCache':_0x4a9a44});return{'ok':!![],'data':{'total':_0x5e42cb['items'][_0x230413(0x16c)],'env':_0x43e7f9,'source':_0x5e42cb[_0x230413(0x12e)],'fetchedAt':_0x5e42cb['fetchedAt'],'cachePath':_0x5e42cb[_0x230413(0x122)]},'message':_0x5e42cb[_0x230413(0x12e)]==='cache'?_0x230413(0x169)+_0x5e42cb[_0x230413(0x167)][_0x230413(0x16c)]+_0x230413(0x144)+_0x43e7f9+'\x22.':_0x230413(0x151)+_0x5e42cb['items'][_0x230413(0x16c)]+_0x230413(0x14c)+_0x43e7f9+'\x22.'};}},useDef={'service':a3_0x197a9c(0x137),'command':'use','description':a3_0x197a9c(0x127),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'args':[{'name':a3_0x197a9c(0x153),'description':a3_0x197a9c(0x14e),'required':!![]}],'flags':[GLOBAL_FLAG],async 'validate'(_0x1795cf){const _0x1f85ae=a3_0x197a9c;if(!_0x1795cf[_0x1f85ae(0x130)][0x0])throw CliErrors[_0x1f85ae(0x165)]('Missing\x20app\x20name.','Usage:\x20'+CLI_BIN_NAME+_0x1f85ae(0x13a));},async 'execute'(_0x3eaa3d){const _0x3bccee=a3_0x197a9c;warnDeprecatedAppCommand(_0x3bccee(0x12d),CLI_BIN_NAME+_0x3bccee(0x16a));const _0x58fe8f=_0x3eaa3d[_0x3bccee(0x130)][0x0];if(!_0x58fe8f)throw CliErrors[_0x3bccee(0x165)](_0x3bccee(0x159),'Usage:\x20'+CLI_BIN_NAME+'\x20app\x20use\x20<name>\x20[--global]');const {buildConfigFromFlags:_0x42fcd5,resolveLocalAppAliasCode:_0x39dbeb}=await import(_0x3bccee(0x166)),{readCachedAppList:_0x5e849d}=await import(_0x3bccee(0x155)),_0x3e357e=_0x3eaa3d['str'](_0x3bccee(0x131)),_0x32d67e=_0x42fcd5(_0x3e357e?{'env':_0x3e357e}:{}),_0x3a460d=_0x5e849d(_0x32d67e['env'],_0x32d67e[_0x3bccee(0x143)]),_0x41aade=_0x3a460d?.[_0x3bccee(0x167)][_0x3bccee(0x140)](_0x3aa151=>_0x3aa151['appName']===_0x58fe8f),_0x4200ba=_0x39dbeb(_0x32d67e[_0x3bccee(0x146)]??{},_0x58fe8f);if(_0x41aade&&!isRuntimeAccessibleApp(_0x41aade))throw runtimeInaccessibleAppError(_0x41aade,'\x22'+_0x58fe8f+'\x22');if(_0x4200ba){const _0x485c48=_0x3a460d?.[_0x3bccee(0x167)][_0x3bccee(0x140)](_0x42ee64=>_0x42ee64[_0x3bccee(0x154)]?.[_0x3bccee(0x16f)]()===_0x4200ba);if(_0x485c48&&!isRuntimeAccessibleApp(_0x485c48))throw runtimeInaccessibleAppError(_0x485c48,'\x22'+_0x58fe8f+'\x22');}if(!_0x41aade&&!_0x4200ba&&_0x32d67e[_0x3bccee(0x160)]!==_0x58fe8f){const _0x3c8a7d=[..._0x3a460d?.['items'][_0x3bccee(0x142)](_0x2cf3c2=>_0x2cf3c2[_0x3bccee(0x168)])??[]],_0x4e310b=_0x3c8a7d[_0x3bccee(0x16c)]===0x0?_0x3bccee(0x15f)+CLI_BIN_NAME+_0x3bccee(0x125)+_0x58fe8f+'.appcode\x20to\x20.lovrabet.json.':'Available\x20remote\x20apps:\x20'+Array[_0x3bccee(0x13f)](new Set(_0x3c8a7d))[_0x3bccee(0x179)](',\x20')+'.\x20Local\x20aliases\x20can\x20be\x20added\x20under\x20apps.<alias>.appcode.';throw CliErrors['validation'](_0x3bccee(0x173)+_0x58fe8f+_0x3bccee(0x123),_0x4e310b);}const _0x47de31=_0x3eaa3d['bool'](_0x3bccee(0x163));let _0x4f0b84;if(_0x47de31)_0x4f0b84={'global':!![]};else{const {isInProject:_0x432928}=await import(_0x3bccee(0x166)),_0x13be11=_0x432928();_0x4f0b84=toScopeFlags(resolveConfigScope({'explicitGlobal':![],'policy':'project-default','inProject':_0x13be11}));}const _0x5f1c70=readConfig(_0x4f0b84);return _0x5f1c70['defaultApp']=_0x58fe8f,writeConfig(_0x5f1c70,_0x4f0b84),{'ok':!![],'message':_0x3bccee(0x176)+_0x58fe8f+'\x22'+scopeLabel(_0x4f0b84)+'.'};}};function warnDeprecatedAppCommand(_0x37bc48,_0x503065){const _0x593781=a3_0x197a9c;console[_0x593781(0x156)](CLI_BIN_NAME+_0x593781(0x120)+_0x37bc48+'\x20is\x20deprecated.\x20Use\x20`'+_0x503065+_0x593781(0x12f));}const importDef={'service':a3_0x197a9c(0x137),'command':'import','description':a3_0x197a9c(0x128),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':initImportFlagDefs,async 'execute'(_0x40f987){return await runInitImport(collectFlags(_0x40f987,initImportFlagDefs)),{'ok':!![]};}};export const appDefinitions=[initDef,listDef,pullDef,useDef,importDef];
1
+ const a3_0x20eea3=a3_0x54ae;function a3_0x54ae(_0x10a744,_0x4a6443){_0x10a744=_0x10a744-0xc7;const _0x1ffb64=a3_0x1ffb();let _0x54ae70=_0x1ffb64[_0x10a744];return _0x54ae70;}(function(_0x5a752e,_0x5b6ce1){const _0x5b7cec=a3_0x54ae,_0x2c96fc=_0x5a752e();while(!![]){try{const _0x2c7bfd=parseInt(_0x5b7cec(0xda))/0x1*(-parseInt(_0x5b7cec(0xe2))/0x2)+-parseInt(_0x5b7cec(0xf2))/0x3+parseInt(_0x5b7cec(0xf3))/0x4*(parseInt(_0x5b7cec(0x10a))/0x5)+-parseInt(_0x5b7cec(0xf1))/0x6+-parseInt(_0x5b7cec(0xef))/0x7+parseInt(_0x5b7cec(0xcb))/0x8*(-parseInt(_0x5b7cec(0xd1))/0x9)+parseInt(_0x5b7cec(0xec))/0xa*(parseInt(_0x5b7cec(0x115))/0xb);if(_0x2c7bfd===_0x5b6ce1)break;else _0x2c96fc['push'](_0x2c96fc['shift']());}catch(_0x323125){_0x2c96fc['push'](_0x2c96fc['shift']());}}}(a3_0x1ffb,0x9d8a7));import{CliErrors}from'../../errors.js';import{initCreateFlagDefs,initImportFlagDefs,runInit,runInitImport}from'../../commands/init.js';import{getEnv,RUNTIME_ENV_VALUES}from'../../constant/env.js';import{buildAppProfileListFields}from'../../config/schema.js';import{CLI_BIN_NAME,readConfig,writeConfig,scopeLabel,enrichAppListItemsWithMergedSelection}from'../../commands/app/shared.js';import{resolveConfigScope,toScopeFlags}from'../../commands/common/config-policy.js';import{filterRuntimeAccessibleApps,findAppByCode,isRuntimeAccessibleApp,runtimeInaccessibleAppError}from'../../commands/app/eligibility.js';function a3_0x1ffb(){const _0x571400=['remote','str','\x20app(s)\x20for\x20env=\x22','appcode','\x20is\x20deprecated.\x20Use\x20`','nonInteractive','fetchedAt','No\x20apps\x20found\x20on\x20the\x20platform.','pull','Remote\x20app\x20name\x20to\x20activate','cachePath','production','\x20cached\x20app(s)\x20for\x20env=\x22','validation','Import\x20the\x20default\x20app\x20selection\x20from\x20a\x20.rabetbase.json\x20file','Deprecated:\x20use\x20workspace\x20init\x20to\x20bind\x20the\x20current\x20directory\x20to\x20an\x20app','warn','.appcode\x20to\x20.lovrabet.json.','filter','projectPath','local','Missing\x20app\x20name.','10HfuNsT','accessKey','isArray','cache','find','read','langs','import','app','appName','enableI18n','26767609aJDugq','List\x20apps\x20available\x20to\x20the\x20current\x20access\x20key','Force\x20remote\x20fetch\x20and\x20refresh\x20local\x20cache','write','map','Refresh\x20the\x20local\x20app\x20cache\x20from\x20the\x20platform','bool','Read\x20from\x20local\x20cache\x20only','Filter\x20by\x20environment\x20(default:\x20current\x20env)','Usage:\x20','Deprecated:\x20use\x20workspace\x20use\x20to\x20bind\x20the\x20current\x20directory\x20to\x20an\x20app','\x20app\x20list`\x20to\x20discover\x20remote\x20apps,\x20or\x20add\x20apps.','init','No\x20cached\x20apps\x20found.','source','string','64lkGvWs','isCurrent','type','Default\x20app\x20candidate\x20set\x20to\x20\x22','.\x20Local\x20aliases\x20can\x20be\x20added\x20under\x20apps.<alias>.appcode.','Read\x20app\x20list\x20from\x20local\x20cache\x20only','1128213xMcTTB','items','\x20app\x20use\x20<name>\x20[--global]','push','entries','Use\x20global\x20config\x20scope','trim','include-unpublished','defaultApp','777zBLBqN','\x22\x20not\x20found.','../../context.js','env','from','App\x20\x22','no-cache','name','780MiWCzb','global','Loaded\x20','envName','project-default','boolean','config','appCode','mergedCli','length','10gXjSWI','globalPath','../../commands/app/remote-source.js','6226381JZmZmf','Available\x20remote\x20apps:\x20','3118758LmAfHi','677778QxlCAZ','2305912kKgOLo'];a3_0x1ffb=function(){return _0x571400;};return a3_0x1ffb();}const GLOBAL_FLAG={'name':a3_0x20eea3(0xe3),'type':a3_0x20eea3(0xe7),'description':a3_0x20eea3(0xd6),'default':![]};function collectFlags(_0x310a63,_0x127075){const _0x243947=a3_0x20eea3,_0x44ca25={};for(const _0x50180b of _0x127075){const _0x465fbd=_0x50180b[_0x243947(0xcd)]===_0x243947(0xe7)?_0x310a63[_0x243947(0x11b)](_0x50180b[_0x243947(0xe1)]):_0x310a63['str'](_0x50180b['name']);if(_0x465fbd!==''&&_0x465fbd!==![])_0x44ca25[_0x50180b['name']]=_0x465fbd;}if(_0x310a63[_0x243947(0xf9)])_0x44ca25[_0x243947(0xf9)]=!![];return _0x44ca25;}function normalizeLanguages(_0x2fe396){const _0x2edb4d=a3_0x20eea3;if(!Array[_0x2edb4d(0x10c)](_0x2fe396))return[];return _0x2fe396['filter'](_0x37c646=>typeof _0x37c646===_0x2edb4d(0xca))[_0x2edb4d(0x119)](_0xa772d8=>_0xa772d8[_0x2edb4d(0xd7)]())[_0x2edb4d(0x106)](Boolean);}function buildRemoteAppI18nFields(_0x5bfe27){const _0x2adeee=a3_0x20eea3,_0x1e2593=normalizeLanguages(_0x5bfe27['i18nInfo']?.[_0x2adeee(0x110)]);return{'enableI18n':typeof _0x5bfe27[_0x2adeee(0x114)]===_0x2adeee(0xe7)?_0x5bfe27[_0x2adeee(0x114)]:null,'languages':_0x1e2593,'i18nInfo':_0x5bfe27['i18nInfo']?{..._0x5bfe27['i18nInfo'],'langs':_0x1e2593[_0x2adeee(0xeb)]?_0x1e2593:null}:null};}const initDef={'service':a3_0x20eea3(0x112),'command':a3_0x20eea3(0xc7),'description':a3_0x20eea3(0x103),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':initCreateFlagDefs,async 'execute'(_0xf5af71){const _0x28debb=a3_0x20eea3;return warnDeprecatedAppCommand(_0x28debb(0xc7),CLI_BIN_NAME+'\x20workspace\x20init\x20--appcode\x20<code>\x20[--env\x20daily]'),await runInit(collectFlags(_0xf5af71,initCreateFlagDefs)),{'ok':!![]};}},listDef={'service':'app','command':'list','description':a3_0x20eea3(0x116),'risk':a3_0x20eea3(0x10f),'requiresAuth':!![],'requiresAppCode':![],'hasFormat':!![],'flags':[{'name':a3_0x20eea3(0xdd),'type':'string','description':a3_0x20eea3(0x11d),'enum':[...RUNTIME_ENV_VALUES]},{'name':'local','type':a3_0x20eea3(0xe7),'description':a3_0x20eea3(0xd0),'default':![]},{'name':a3_0x20eea3(0xe0),'type':a3_0x20eea3(0xe7),'description':a3_0x20eea3(0x117),'default':![]},{'name':'include-unpublished','type':a3_0x20eea3(0xe7),'description':'Include\x20unpublished\x20apps\x20for\x20diagnostics','default':![]}],async 'execute'(_0x439b14){const _0x5704f8=a3_0x20eea3,_0xc669fc=_0x439b14[_0x5704f8(0xf5)](_0x5704f8(0xdd))||_0x439b14[_0x5704f8(0xe5)]||getEnv()||_0x5704f8(0xff),_0x2894db=_0x439b14['bool']('local'),_0x4ecc0c=_0x439b14[_0x5704f8(0x11b)](_0x5704f8(0xe0)),_0x1a859f=_0x439b14[_0x5704f8(0x11b)](_0x5704f8(0xd8)),{readRawConfigWithLayers:_0x498438,resolveDefaultAppSource:_0x2f5de8,getLocalAppAliases:_0x4cf038}=await import('../../context.js'),{getRemoteAppList:_0x34d0be}=await import(_0x5704f8(0xee)),{config:_0x154f49,layers:_0x30795e}=_0x498438(),_0x10ea62=_0x2f5de8(_0x30795e),{defaultApp:_0x34c56d}=_0x154f49,_0x1cc1ef=await _0x34d0be({'env':_0xc669fc,'accessKey':_0x439b14[_0x5704f8(0x10b)],'localOnly':_0x2894db,'noCache':_0x4ecc0c}),_0x3e136e=_0x1a859f?_0x1cc1ef[_0x5704f8(0xd2)]:filterRuntimeAccessibleApps(_0x1cc1ef[_0x5704f8(0xd2)]),_0x4458fd=_0x1cc1ef[_0x5704f8(0xd2)][_0x5704f8(0xeb)]-_0x3e136e[_0x5704f8(0xeb)],_0x5362e5=_0x3e136e['map'](_0x3ad58d=>{const _0x48473d=_0x5704f8;return{'name':_0x3ad58d[_0x48473d(0x113)],'appcode':_0x3ad58d[_0x48473d(0xe9)],'named':!![],'definedIn':_0x48473d(0xf4),'isDefault':_0x3ad58d[_0x48473d(0x113)]===_0x34c56d,...buildAppProfileListFields(_0xc669fc),...buildRemoteAppI18nFields(_0x3ad58d),'source':_0x1cc1ef[_0x48473d(0xc9)],'owner':_0x3ad58d['appOwnerName']??null,'status':_0x3ad58d['appPublishStatus']??null,'cachedAt':_0x1cc1ef[_0x48473d(0xfa)]};}),_0x137791=_0x4cf038(_0x154f49);let _0x2aeb58=0x0;for(const [_0x507139,_0x3ce2ae]of Object[_0x5704f8(0xd5)](_0x137791)){const _0x21171f=typeof _0x3ce2ae[_0x5704f8(0xf7)]==='string'?_0x3ce2ae[_0x5704f8(0xf7)]['trim']():'';if(!_0x21171f)continue;const _0x991b15=findAppByCode(_0x1cc1ef[_0x5704f8(0xd2)],_0x21171f);if(!_0x1a859f&&_0x991b15&&!isRuntimeAccessibleApp(_0x991b15))continue;_0x2aeb58+=0x1,_0x5362e5[_0x5704f8(0xd4)]({'name':_0x507139,'appcode':_0x21171f,'named':!![],'definedIn':_0x5704f8(0x108),'isDefault':_0x507139===_0x34c56d,...buildAppProfileListFields(_0xc669fc),'source':_0x5704f8(0xe8),'owner':null,'status':null,'cachedAt':null});}enrichAppListItemsWithMergedSelection(_0x5362e5,_0x439b14[_0x5704f8(0xea)]);const _0x16cb47=_0x5362e5[_0x5704f8(0x10e)](_0x39ea03=>_0x39ea03[_0x5704f8(0xcc)]===!![]),_0x3d929d=_0x34c56d??_0x16cb47?.[_0x5704f8(0xe1)]??null,_0x2f4fd5={'env':_0xc669fc,'source':_0x1cc1ef[_0x5704f8(0xc9)],'fetchedAt':_0x1cc1ef[_0x5704f8(0xfa)],'cachePath':_0x1cc1ef[_0x5704f8(0xfe)],'globalPath':_0x30795e[_0x5704f8(0xed)]??null,'projectPath':_0x30795e[_0x5704f8(0x107)]??null,'defaultApp':_0x3d929d,'defaultAppSource':_0x34c56d!=null?_0x10ea62:null,'localAliasCount':_0x2aeb58,'remoteTotal':_0x1cc1ef[_0x5704f8(0xd2)][_0x5704f8(0xeb)],'hiddenUnpublishedCount':_0x4458fd,'includeUnpublished':_0x1a859f};if(_0x5362e5[_0x5704f8(0xeb)]===0x0)return{'ok':!![],'data':{'items':_0x5362e5,'meta':_0x2f4fd5},'message':_0x1cc1ef[_0x5704f8(0xc9)]===_0x5704f8(0x10d)?_0x5704f8(0xc8):_0x5704f8(0xfb)};return{'ok':!![],'data':{'items':_0x5362e5,'meta':_0x2f4fd5}};}},pullDef={'service':a3_0x20eea3(0x112),'command':a3_0x20eea3(0xfc),'description':a3_0x20eea3(0x11a),'risk':a3_0x20eea3(0x118),'requiresAuth':!![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':a3_0x20eea3(0xdd),'type':a3_0x20eea3(0xca),'description':'Target\x20environment\x20(default:\x20current\x20env)','enum':[...RUNTIME_ENV_VALUES]},{'name':a3_0x20eea3(0x108),'type':a3_0x20eea3(0xe7),'description':a3_0x20eea3(0x11c),'default':![]},{'name':a3_0x20eea3(0xe0),'type':a3_0x20eea3(0xe7),'description':a3_0x20eea3(0x117),'default':![]}],async 'execute'(_0x3317ff){const _0x494230=a3_0x20eea3,_0x5649d9=_0x3317ff['str'](_0x494230(0xdd))||_0x3317ff[_0x494230(0xe5)]||getEnv()||_0x494230(0xff),_0x40792e=_0x3317ff['bool'](_0x494230(0x108)),_0x590642=_0x3317ff[_0x494230(0x11b)](_0x494230(0xe0)),{getRemoteAppList:_0x4b18b2}=await import(_0x494230(0xee)),_0x326cd4=await _0x4b18b2({'env':_0x5649d9,'accessKey':_0x3317ff[_0x494230(0x10b)],'localOnly':_0x40792e,'noCache':_0x590642});return{'ok':!![],'data':{'total':_0x326cd4[_0x494230(0xd2)][_0x494230(0xeb)],'env':_0x5649d9,'source':_0x326cd4['source'],'fetchedAt':_0x326cd4[_0x494230(0xfa)],'cachePath':_0x326cd4[_0x494230(0xfe)]},'message':_0x326cd4['source']===_0x494230(0x10d)?_0x494230(0xe4)+_0x326cd4[_0x494230(0xd2)][_0x494230(0xeb)]+_0x494230(0x100)+_0x5649d9+'\x22.':'Refreshed\x20app\x20cache\x20with\x20'+_0x326cd4[_0x494230(0xd2)]['length']+_0x494230(0xf6)+_0x5649d9+'\x22.'};}},useDef={'service':a3_0x20eea3(0x112),'command':'use','description':a3_0x20eea3(0x11f),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'args':[{'name':a3_0x20eea3(0xe1),'description':a3_0x20eea3(0xfd),'required':!![]}],'flags':[GLOBAL_FLAG],async 'validate'(_0x44d6e1){const _0x236b62=a3_0x20eea3;if(!_0x44d6e1['args'][0x0])throw CliErrors[_0x236b62(0x101)](_0x236b62(0x109),'Usage:\x20'+CLI_BIN_NAME+'\x20app\x20use\x20<name>\x20[--global]');},async 'execute'(_0x2e78d8){const _0x392fb7=a3_0x20eea3;warnDeprecatedAppCommand('use',CLI_BIN_NAME+'\x20workspace\x20use\x20--app\x20<name>\x20[--env\x20daily]');const _0x9da030=_0x2e78d8['args'][0x0];if(!_0x9da030)throw CliErrors[_0x392fb7(0x101)]('Missing\x20app\x20name.',_0x392fb7(0x11e)+CLI_BIN_NAME+_0x392fb7(0xd3));const {buildConfigFromFlags:_0xe85a16,resolveLocalAppAliasCode:_0x4e7493}=await import(_0x392fb7(0xdc)),{readCachedAppList:_0x49861f}=await import('../../commands/app/cache.js'),_0x513d88=_0x2e78d8['str']('env'),_0x2b72f0=_0xe85a16(_0x513d88?{'env':_0x513d88}:{}),_0x48ed39=_0x49861f(_0x2b72f0[_0x392fb7(0xdd)],_0x2b72f0[_0x392fb7(0x10b)]),_0xe21b8e=_0x48ed39?.[_0x392fb7(0xd2)][_0x392fb7(0x10e)](_0x1dbb6d=>_0x1dbb6d['appName']===_0x9da030),_0x2d57eb=_0x4e7493(_0x2b72f0['raw']??{},_0x9da030);if(_0xe21b8e&&!isRuntimeAccessibleApp(_0xe21b8e))throw runtimeInaccessibleAppError(_0xe21b8e,'\x22'+_0x9da030+'\x22');if(_0x2d57eb){const _0x5cba20=_0x48ed39?.[_0x392fb7(0xd2)]['find'](_0x2635b0=>_0x2635b0[_0x392fb7(0xe9)]?.[_0x392fb7(0xd7)]()===_0x2d57eb);if(_0x5cba20&&!isRuntimeAccessibleApp(_0x5cba20))throw runtimeInaccessibleAppError(_0x5cba20,'\x22'+_0x9da030+'\x22');}if(!_0xe21b8e&&!_0x2d57eb&&_0x2b72f0[_0x392fb7(0xd9)]!==_0x9da030){const _0x5191b2=[..._0x48ed39?.[_0x392fb7(0xd2)]['map'](_0x47e3ed=>_0x47e3ed[_0x392fb7(0x113)])??[]],_0xc30dea=_0x5191b2[_0x392fb7(0xeb)]===0x0?'Use\x20`'+CLI_BIN_NAME+_0x392fb7(0x120)+_0x9da030+_0x392fb7(0x105):_0x392fb7(0xf0)+Array[_0x392fb7(0xde)](new Set(_0x5191b2))['join'](',\x20')+_0x392fb7(0xcf);throw CliErrors[_0x392fb7(0x101)](_0x392fb7(0xdf)+_0x9da030+_0x392fb7(0xdb),_0xc30dea);}const _0x3a820=_0x2e78d8[_0x392fb7(0x11b)](_0x392fb7(0xe3));let _0x3297b2;if(_0x3a820)_0x3297b2={'global':!![]};else{const {isInProject:_0x4e6a16}=await import(_0x392fb7(0xdc)),_0x3d89ba=_0x4e6a16();_0x3297b2=toScopeFlags(resolveConfigScope({'explicitGlobal':![],'policy':_0x392fb7(0xe6),'inProject':_0x3d89ba}));}const _0x501b72=readConfig(_0x3297b2);return _0x501b72[_0x392fb7(0xd9)]=_0x9da030,writeConfig(_0x501b72,_0x3297b2),{'ok':!![],'message':_0x392fb7(0xce)+_0x9da030+'\x22'+scopeLabel(_0x3297b2)+'.'};}};function warnDeprecatedAppCommand(_0x502f46,_0x398603){const _0x3086d3=a3_0x20eea3;console[_0x3086d3(0x104)](CLI_BIN_NAME+'\x20app\x20'+_0x502f46+_0x3086d3(0xf8)+_0x398603+'`\x20instead.');}const importDef={'service':a3_0x20eea3(0x112),'command':a3_0x20eea3(0x111),'description':a3_0x20eea3(0x102),'risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':initImportFlagDefs,async 'execute'(_0xa5ebd5){return await runInitImport(collectFlags(_0xa5ebd5,initImportFlagDefs)),{'ok':!![]};}};export const appDefinitions=[initDef,listDef,pullDef,useDef,importDef];
@@ -1 +1 @@
1
- (function(_0x27838c,_0x40b3d2){const _0x47601b=a4_0x5911,_0x505d71=_0x27838c();while(!![]){try{const _0x172048=-parseInt(_0x47601b(0x81))/0x1+parseInt(_0x47601b(0x7f))/0x2+parseInt(_0x47601b(0x87))/0x3*(-parseInt(_0x47601b(0x84))/0x4)+-parseInt(_0x47601b(0x8e))/0x5*(parseInt(_0x47601b(0x8c))/0x6)+parseInt(_0x47601b(0x7c))/0x7*(-parseInt(_0x47601b(0x7e))/0x8)+-parseInt(_0x47601b(0x85))/0x9+parseInt(_0x47601b(0x79))/0xa;if(_0x172048===_0x40b3d2)break;else _0x505d71['push'](_0x505d71['shift']());}catch(_0x43ef37){_0x505d71['push'](_0x505d71['shift']());}}}(a4_0x31a9,0x19c82));import{CLI_BIN_NAME}from'../../constant/cli.js';import{RUNTIME_ACCESSIBLE_APP_STATUS}from'../../constant/app.js';function a4_0x5911(_0x16f1d5,_0x430d59){_0x16f1d5=_0x16f1d5-0x79;const _0x31a948=a4_0x31a9();let _0x591139=_0x31a948[_0x16f1d5];return _0x591139;}import{CliErrors}from'../../errors.js';export function normalizeAppPublishStatus(_0x3c8caa){const _0xd1e74e=a4_0x5911;if(typeof _0x3c8caa!==_0xd1e74e(0x90))return null;const _0x559b49=_0x3c8caa[_0xd1e74e(0x8b)]();return _0x559b49?_0x559b49[_0xd1e74e(0x8a)]():null;}export function isRuntimeAccessibleApp(_0x16743f){const _0x320f79=a4_0x5911;return normalizeAppPublishStatus(_0x16743f[_0x320f79(0x88)])===RUNTIME_ACCESSIBLE_APP_STATUS;}export function filterRuntimeAccessibleApps(_0x4ae1ce){const _0x5971c1=a4_0x5911;return _0x4ae1ce[_0x5971c1(0x7b)](isRuntimeAccessibleApp);}export function findAppByName(_0x22ea06,_0x4adf26){const _0x45cb2a=a4_0x5911;return _0x22ea06[_0x45cb2a(0x82)](_0x36a360=>_0x36a360['appName']===_0x4adf26);}function a4_0x31a9(){const _0x3c3402=['.\x20Publish\x20the\x20app\x20before\x20using\x20','toUpperCase','trim','444084QLMffS','Current\x20status:\x20','5UPHrkT','App\x20','string','3838400KVbDZv','\x20is\x20not\x20available\x20for\x20runtime\x20AI\x20access.','filter','28161gxGVEb','validation','136dgpSMJ','387124ZhbOIH','UNKNOWN','81660Tymisu','find','\x20dataset/data/sql/bff\x20commands,\x20or\x20choose\x20a\x20published\x20app.','32344mZajdz','992457sXfAJf','appCode','51BcbCpb','appPublishStatus'];a4_0x31a9=function(){return _0x3c3402;};return a4_0x31a9();}export function findAppByCode(_0x189154,_0x3b0637){const _0x49c5ab=a4_0x5911,_0x1bd554=_0x3b0637[_0x49c5ab(0x8b)]();if(!_0x1bd554)return undefined;return _0x189154[_0x49c5ab(0x82)](_0x40187f=>_0x40187f[_0x49c5ab(0x86)]?.[_0x49c5ab(0x8b)]()===_0x1bd554);}export function runtimeInaccessibleAppError(_0x4a12f6,_0x9cd047){const _0x32d55b=a4_0x5911,_0x5f4912=normalizeAppPublishStatus(_0x4a12f6[_0x32d55b(0x88)])??_0x32d55b(0x80);return CliErrors[_0x32d55b(0x7d)](_0x32d55b(0x8f)+_0x9cd047+_0x32d55b(0x7a),_0x32d55b(0x8d)+_0x5f4912+_0x32d55b(0x89)+CLI_BIN_NAME+_0x32d55b(0x83));}
1
+ (function(_0x4b1518,_0x3fd6aa){const _0x3f72c4=a4_0x3a05,_0x251686=_0x4b1518();while(!![]){try{const _0x42ad05=-parseInt(_0x3f72c4(0x1c1))/0x1+-parseInt(_0x3f72c4(0x1c4))/0x2+-parseInt(_0x3f72c4(0x1cd))/0x3+parseInt(_0x3f72c4(0x1bb))/0x4+parseInt(_0x3f72c4(0x1c6))/0x5*(parseInt(_0x3f72c4(0x1cb))/0x6)+parseInt(_0x3f72c4(0x1c2))/0x7+parseInt(_0x3f72c4(0x1c9))/0x8;if(_0x42ad05===_0x3fd6aa)break;else _0x251686['push'](_0x251686['shift']());}catch(_0x1122cb){_0x251686['push'](_0x251686['shift']());}}}(a4_0x106c,0xdd409));import{CLI_BIN_NAME}from'../../constant/cli.js';import{RUNTIME_ACCESSIBLE_APP_STATUS}from'../../constant/app.js';import{CliErrors}from'../../errors.js';export function normalizeAppPublishStatus(_0x5d50c0){const _0x1fb497=a4_0x3a05;if(typeof _0x5d50c0!==_0x1fb497(0x1c8))return null;const _0x61d510=_0x5d50c0[_0x1fb497(0x1ba)]();return _0x61d510?_0x61d510[_0x1fb497(0x1c0)]():null;}function a4_0x3a05(_0x1a5360,_0x5ac4d9){_0x1a5360=_0x1a5360-0x1ba;const _0x106cdc=a4_0x106c();let _0x3a052c=_0x106cdc[_0x1a5360];return _0x3a052c;}export function isRuntimeAccessibleApp(_0x4ca04a){return normalizeAppPublishStatus(_0x4ca04a['appPublishStatus'])===RUNTIME_ACCESSIBLE_APP_STATUS;}export function filterRuntimeAccessibleApps(_0x4e50fc){const _0x3b95cd=a4_0x3a05;return _0x4e50fc[_0x3b95cd(0x1be)](isRuntimeAccessibleApp);}export function findAppByName(_0x273730,_0x3e2cd5){const _0x5a47b9=a4_0x3a05;return _0x273730[_0x5a47b9(0x1bc)](_0x4d7f38=>_0x4d7f38['appName']===_0x3e2cd5);}export function findAppByCode(_0x3ed27b,_0x23911e){const _0xf38ceb=a4_0x3a05,_0x13fef6=_0x23911e[_0xf38ceb(0x1ba)]();if(!_0x13fef6)return undefined;return _0x3ed27b['find'](_0x258f89=>_0x258f89[_0xf38ceb(0x1ca)]?.[_0xf38ceb(0x1ba)]()===_0x13fef6);}function a4_0x106c(){const _0x235edd=['validation','3190624HdAYpS','\x20is\x20not\x20available\x20for\x20runtime\x20AI\x20access.','15Jzdcxn','.\x20Publish\x20the\x20app\x20before\x20using\x20','string','362056HqjWoi','appCode','3448212LliXQK','Current\x20status:\x20','2891904OIFQkZ','trim','6252532LOFuGj','find','App\x20','filter','UNKNOWN','toUpperCase','126851UFxbvS','1819188fwwpPk'];a4_0x106c=function(){return _0x235edd;};return a4_0x106c();}export function runtimeInaccessibleAppError(_0x4411ca,_0x51206c){const _0x28c722=a4_0x3a05,_0x3ce4d0=normalizeAppPublishStatus(_0x4411ca['appPublishStatus'])??_0x28c722(0x1bf);return CliErrors[_0x28c722(0x1c3)](_0x28c722(0x1bd)+_0x51206c+_0x28c722(0x1c5),_0x28c722(0x1cc)+_0x3ce4d0+_0x28c722(0x1c7)+CLI_BIN_NAME+'\x20dataset/data/sql/bff\x20commands,\x20or\x20choose\x20a\x20published\x20app.');}
@@ -1 +1 @@
1
- (function(_0x1bf86c,_0x4305a8){const _0x4e5456=a5_0x5e20,_0x5b3a04=_0x1bf86c();while(!![]){try{const _0x13011c=parseInt(_0x4e5456(0x9f))/0x1*(-parseInt(_0x4e5456(0xa8))/0x2)+parseInt(_0x4e5456(0x9a))/0x3*(-parseInt(_0x4e5456(0xa0))/0x4)+-parseInt(_0x4e5456(0xa5))/0x5+parseInt(_0x4e5456(0xa6))/0x6+-parseInt(_0x4e5456(0xa2))/0x7*(-parseInt(_0x4e5456(0xa4))/0x8)+parseInt(_0x4e5456(0xa9))/0x9+parseInt(_0x4e5456(0x98))/0xa;if(_0x13011c===_0x4305a8)break;else _0x5b3a04['push'](_0x5b3a04['shift']());}catch(_0x28f768){_0x5b3a04['push'](_0x5b3a04['shift']());}}}(a5_0x48c5,0x4d9c6));import{fileURLToPath}from'url';import{dirname,join}from'path';import{readFileSync}from'fs';function a5_0x5e20(_0x48398f,_0xa1371c){_0x48398f=_0x48398f-0x98;const _0x48c588=a5_0x48c5();let _0x5e2019=_0x48c588[_0x48398f];return _0x5e2019;}function a5_0x48c5(){const _0x564a21=['data','201418BNeQqF','3727584ayzhtp','8874800NpflVD','parse','1006770RXzLXh','Mock\x20API\x20error:\x20','tableData','../../../mock/app-list.json','errorCode','6bnUnkL','4egUVyG','errorMsg','7GLxcnq','success','2817272stjblk','2779705fboUqu','959184trMKQJ'];a5_0x48c5=function(){return _0x564a21;};return a5_0x48c5();}const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function loadMockAppList(){const _0x44d237=a5_0x5e20,_0x5bb519=join(__dirname,_0x44d237(0x9d)),_0x20c13d=readFileSync(_0x5bb519,'utf-8');return JSON[_0x44d237(0x99)](_0x20c13d);}let _cached=null;export function getMockAppList(){return!_cached&&(_cached=loadMockAppList()),_cached;}export function getMockRemoteAppItems(){const _0x2b359a=a5_0x5e20,_0x4866b0=getMockAppList();if(!_0x4866b0[_0x2b359a(0xa3)])throw new Error(_0x2b359a(0x9b)+_0x4866b0[_0x2b359a(0xa1)]+'\x20('+_0x4866b0[_0x2b359a(0x9e)]+')');return _0x4866b0[_0x2b359a(0xa7)][_0x2b359a(0x9c)];}
1
+ (function(_0x8dd2b9,_0xec0e63){const _0x4b61ba=a5_0x1e6c,_0x1e27be=_0x8dd2b9();while(!![]){try{const _0x378aaa=-parseInt(_0x4b61ba(0x14c))/0x1*(-parseInt(_0x4b61ba(0x142))/0x2)+-parseInt(_0x4b61ba(0x148))/0x3*(-parseInt(_0x4b61ba(0x144))/0x4)+parseInt(_0x4b61ba(0x154))/0x5*(-parseInt(_0x4b61ba(0x147))/0x6)+parseInt(_0x4b61ba(0x151))/0x7*(-parseInt(_0x4b61ba(0x155))/0x8)+parseInt(_0x4b61ba(0x146))/0x9*(parseInt(_0x4b61ba(0x150))/0xa)+parseInt(_0x4b61ba(0x14e))/0xb*(-parseInt(_0x4b61ba(0x14a))/0xc)+parseInt(_0x4b61ba(0x153))/0xd;if(_0x378aaa===_0xec0e63)break;else _0x1e27be['push'](_0x1e27be['shift']());}catch(_0x1e7d2b){_0x1e27be['push'](_0x1e27be['shift']());}}}(a5_0x414a,0x4cf8a));import{fileURLToPath}from'url';import{dirname,join}from'path';import{readFileSync}from'fs';const __filename=fileURLToPath(import.meta.url),__dirname=dirname(__filename);function loadMockAppList(){const _0x63505e=a5_0x1e6c,_0xd13ab9=join(__dirname,_0x63505e(0x14d)),_0xe8a8ba=readFileSync(_0xd13ab9,_0x63505e(0x143));return JSON['parse'](_0xe8a8ba);}function a5_0x414a(){const _0xd4f6c2=['2021484FDcldC','Mock\x20API\x20error:\x20','71uNOXNB','../../../mock/app-list.json','33mvserO','data','220EtINYe','20601DtBhgG','tableData','5121246iFHCpQ','20alsgvQ','1416DUkIEf','4938UUnxZZ','utf-8','12ZyXfVn','success','127593kEFglE','175992uZQQCb','577749QAAjDv','errorMsg'];a5_0x414a=function(){return _0xd4f6c2;};return a5_0x414a();}function a5_0x1e6c(_0x520b9d,_0x9b0127){_0x520b9d=_0x520b9d-0x142;const _0x414a42=a5_0x414a();let _0x1e6c5a=_0x414a42[_0x520b9d];return _0x1e6c5a;}let _cached=null;export function getMockAppList(){return!_cached&&(_cached=loadMockAppList()),_cached;}export function getMockRemoteAppItems(){const _0x4b13db=a5_0x1e6c,_0x4f0fb0=getMockAppList();if(!_0x4f0fb0[_0x4b13db(0x145)])throw new Error(_0x4b13db(0x14b)+_0x4f0fb0[_0x4b13db(0x149)]+'\x20('+_0x4f0fb0['errorCode']+')');return _0x4f0fb0[_0x4b13db(0x14f)][_0x4b13db(0x152)];}
@@ -1 +1 @@
1
- (function(_0x4d95c0,_0x5501a8){const _0x3c6fb9=a6_0x5be3,_0x311a7d=_0x4d95c0();while(!![]){try{const _0x13f8ce=-parseInt(_0x3c6fb9(0x1c9))/0x1*(-parseInt(_0x3c6fb9(0x1ce))/0x2)+parseInt(_0x3c6fb9(0x1c0))/0x3*(-parseInt(_0x3c6fb9(0x1ca))/0x4)+-parseInt(_0x3c6fb9(0x1c1))/0x5+parseInt(_0x3c6fb9(0x1c7))/0x6*(parseInt(_0x3c6fb9(0x1c3))/0x7)+parseInt(_0x3c6fb9(0x1cb))/0x8+-parseInt(_0x3c6fb9(0x1d1))/0x9*(-parseInt(_0x3c6fb9(0x1c6))/0xa)+-parseInt(_0x3c6fb9(0x1cd))/0xb;if(_0x13f8ce===_0x5501a8)break;else _0x311a7d['push'](_0x311a7d['shift']());}catch(_0xd85afa){_0x311a7d['push'](_0x311a7d['shift']());}}}(a6_0x314b,0x5806b));import{getMyApps}from'../../core/api-client.js';import{getMockRemoteAppItems}from'../../commands/app/mock-loader.js';import{getAppCacheFilePath,readCachedAppList,writeCachedAppList}from'../../commands/app/cache.js';function a6_0x314b(){const _0x28ef68=['trim','9kZImIC','items','18qhtBnj','17765AHkgFJ','remote','560fqfhjK','APP_LIST_SOURCE','cache','5077100JlZcbQ','30486FbfBEZ','toLowerCase','580amnRjm','217348DgWcZQ','2358144jhkUZJ','toISOString','9911528xFucdT','1318fpptRU','fetchedAt'];a6_0x314b=function(){return _0x28ef68;};return a6_0x314b();}function a6_0x5be3(_0x2b229a,_0x1e6335){_0x2b229a=_0x2b229a-0x1bf;const _0x314bc5=a6_0x314b();let _0x5be30a=_0x314bc5[_0x2b229a];return _0x5be30a;}import{productEnv}from'../../constant/product.js';export function shouldUseMockRemoteApps(){const _0x369ce6=a6_0x5be3,_0x2847f6=(productEnv(_0x369ce6(0x1c4))||'')[_0x369ce6(0x1d0)]()[_0x369ce6(0x1c8)]();return _0x2847f6==='mock';}export async function getRemoteAppItems(){if(shouldUseMockRemoteApps())return getMockRemoteAppItems();return getMyApps();}export async function getRemoteAppList(_0x378f6c){const _0x403dc0=a6_0x5be3,{env:_0x3bc679,accessKey:_0x3f1ce7,localOnly:localOnly=![],noCache:noCache=![]}=_0x378f6c,_0xee8a5a=readCachedAppList(_0x3bc679,_0x3f1ce7),_0x2626a7=_0x3f1ce7?.[_0x403dc0(0x1d0)]()?getAppCacheFilePath(_0x3bc679,_0x3f1ce7):null;if(localOnly)return{'items':_0xee8a5a?.[_0x403dc0(0x1bf)]??[],'source':'cache','fetchedAt':_0xee8a5a?.[_0x403dc0(0x1cf)]??null,'cachePath':_0x2626a7};try{const _0x34caa8=await getRemoteAppItems(),_0x2fd20d=shouldUseMockRemoteApps()?'mock':_0x403dc0(0x1c2),_0x2ccef4=new Date()[_0x403dc0(0x1cc)](),_0x59f198=_0x3f1ce7?.[_0x403dc0(0x1d0)]()?writeCachedAppList(_0x3bc679,_0x3f1ce7,{'env':_0x3bc679,'fetchedAt':_0x2ccef4,'source':_0x2fd20d,'items':_0x34caa8}):null;return{'items':_0x34caa8,'source':_0x2fd20d,'fetchedAt':_0x2ccef4,'cachePath':_0x59f198};}catch(_0x4f0aa4){if(!noCache&&_0xee8a5a)return{'items':_0xee8a5a[_0x403dc0(0x1bf)],'source':_0x403dc0(0x1c5),'fetchedAt':_0xee8a5a[_0x403dc0(0x1cf)],'cachePath':_0x2626a7};throw _0x4f0aa4;}}
1
+ function a6_0x2774(_0x5e1dd6,_0x372673){_0x5e1dd6=_0x5e1dd6-0x110;const _0x530a72=a6_0x530a();let _0x27747e=_0x530a72[_0x5e1dd6];return _0x27747e;}(function(_0x56471b,_0x493416){const _0x778399=a6_0x2774,_0x6348d8=_0x56471b();while(!![]){try{const _0x7123fd=parseInt(_0x778399(0x11d))/0x1*(-parseInt(_0x778399(0x116))/0x2)+parseInt(_0x778399(0x11e))/0x3+parseInt(_0x778399(0x113))/0x4*(parseInt(_0x778399(0x111))/0x5)+parseInt(_0x778399(0x112))/0x6+parseInt(_0x778399(0x119))/0x7+-parseInt(_0x778399(0x117))/0x8+parseInt(_0x778399(0x11c))/0x9*(-parseInt(_0x778399(0x120))/0xa);if(_0x7123fd===_0x493416)break;else _0x6348d8['push'](_0x6348d8['shift']());}catch(_0x58b247){_0x6348d8['push'](_0x6348d8['shift']());}}}(a6_0x530a,0x6a5b7));import{getMyApps}from'../../core/api-client.js';import{getMockRemoteAppItems}from'../../commands/app/mock-loader.js';import{getAppCacheFilePath,readCachedAppList,writeCachedAppList}from'../../commands/app/cache.js';import{productEnv}from'../../constant/product.js';function a6_0x530a(){const _0x1a11c1=['4264416TonAbA','mock','4283538lcxmFI','fetchedAt','items','9asWxJG','131uVEnbn','2448318NUpHCU','trim','8474770yWmFDk','APP_LIST_SOURCE','toLowerCase','449560dTjYlO','1885974gEKsnL','4ZjlMzc','cache','toISOString','246OvCnhK'];a6_0x530a=function(){return _0x1a11c1;};return a6_0x530a();}export function shouldUseMockRemoteApps(){const _0x1a6556=a6_0x2774,_0x115614=(productEnv(_0x1a6556(0x121))||'')['trim']()[_0x1a6556(0x110)]();return _0x115614===_0x1a6556(0x118);}export async function getRemoteAppItems(){if(shouldUseMockRemoteApps())return getMockRemoteAppItems();return getMyApps();}export async function getRemoteAppList(_0x1a15ae){const _0x39a5ca=a6_0x2774,{env:_0x22ea9e,accessKey:_0x38d596,localOnly:localOnly=![],noCache:noCache=![]}=_0x1a15ae,_0x2ca436=readCachedAppList(_0x22ea9e,_0x38d596),_0x2b8cea=_0x38d596?.['trim']()?getAppCacheFilePath(_0x22ea9e,_0x38d596):null;if(localOnly)return{'items':_0x2ca436?.[_0x39a5ca(0x11b)]??[],'source':_0x39a5ca(0x114),'fetchedAt':_0x2ca436?.[_0x39a5ca(0x11a)]??null,'cachePath':_0x2b8cea};try{const _0x5ca2a2=await getRemoteAppItems(),_0x1c4f4c=shouldUseMockRemoteApps()?_0x39a5ca(0x118):'remote',_0x39965c=new Date()[_0x39a5ca(0x115)](),_0x4a1fbc=_0x38d596?.[_0x39a5ca(0x11f)]()?writeCachedAppList(_0x22ea9e,_0x38d596,{'env':_0x22ea9e,'fetchedAt':_0x39965c,'source':_0x1c4f4c,'items':_0x5ca2a2}):null;return{'items':_0x5ca2a2,'source':_0x1c4f4c,'fetchedAt':_0x39965c,'cachePath':_0x4a1fbc};}catch(_0x3aba9e){if(!noCache&&_0x2ca436)return{'items':_0x2ca436[_0x39a5ca(0x11b)],'source':_0x39a5ca(0x114),'fetchedAt':_0x2ca436[_0x39a5ca(0x11a)],'cachePath':_0x2b8cea};throw _0x3aba9e;}}
@@ -1 +1 @@
1
- (function(_0x39b289,_0x4572a3){const _0x254bcc=a7_0x1878,_0x3d5a8f=_0x39b289();while(!![]){try{const _0x42dc6a=-parseInt(_0x254bcc(0x128))/0x1*(parseInt(_0x254bcc(0x134))/0x2)+-parseInt(_0x254bcc(0x130))/0x3+-parseInt(_0x254bcc(0x133))/0x4*(-parseInt(_0x254bcc(0x12a))/0x5)+parseInt(_0x254bcc(0x129))/0x6*(-parseInt(_0x254bcc(0x135))/0x7)+parseInt(_0x254bcc(0x13a))/0x8*(-parseInt(_0x254bcc(0x131))/0x9)+parseInt(_0x254bcc(0x12e))/0xa+parseInt(_0x254bcc(0x132))/0xb*(parseInt(_0x254bcc(0x12f))/0xc);if(_0x42dc6a===_0x4572a3)break;else _0x3d5a8f['push'](_0x3d5a8f['shift']());}catch(_0x2eb8f8){_0x3d5a8f['push'](_0x3d5a8f['shift']());}}}(a7_0x3fc3,0x8d5c0));function a7_0x3fc3(){const _0x2e309a=['defaultApp','definedIn','trim','named','appcode','397303BPBhte','2918688pyayTj','30hkFMzy','project','appCode','currentApp','5644450XFPpTE','666012DNjFJN','265560EyMRWx','15012AtHxkX','352BPGfKI','87692lCkXkT','2THkeRA','7keLzjA','local','name','find','isCurrent','4416vpUxtL','global'];a7_0x3fc3=function(){return _0x2e309a;};return a7_0x3fc3();}function a7_0x1878(_0x18fff0,_0x15965c){_0x18fff0=_0x18fff0-0x128;const _0x3fc316=a7_0x3fc3();let _0x18785e=_0x3fc316[_0x18fff0];return _0x18785e;}import{CLI_BIN_NAME}from'../../constant/cli.js';import{formatScopeLabel}from'../../commands/common/config-policy.js';export{CLI_BIN_NAME};export function enrichAppListItemsWithMergedSelection(_0x59a5f4,_0x4cda69){const _0x5e2efe=a7_0x1878;if(!_0x4cda69)return;const _0x58f2ff=!!(_0x4cda69[_0x5e2efe(0x12d)]??_0x4cda69[_0x5e2efe(0x13c)]);for(const _0x1eeabe of _0x59a5f4){_0x1eeabe[_0x5e2efe(0x139)]=![];}const _0x401fdd=_0x4cda69['appCode']!=null?String(_0x4cda69[_0x5e2efe(0x12c)])[_0x5e2efe(0x13e)]():'';if(_0x58f2ff){const _0x3f04c7=_0x4cda69['currentApp']??_0x4cda69[_0x5e2efe(0x13c)];if(_0x3f04c7){const _0x244e84=_0x59a5f4[_0x5e2efe(0x138)](_0x299b55=>_0x299b55['named']===!![]&&_0x299b55[_0x5e2efe(0x137)]===_0x3f04c7&&_0x299b55[_0x5e2efe(0x13d)]===_0x5e2efe(0x136)),_0x49ffaf=_0x244e84??_0x59a5f4['find'](_0x30e2a2=>_0x30e2a2[_0x5e2efe(0x13f)]===!![]&&_0x30e2a2[_0x5e2efe(0x137)]===_0x3f04c7);_0x49ffaf&&(_0x49ffaf[_0x5e2efe(0x139)]=!![]);}return;}if(!_0x401fdd)return;for(const _0x3b79cd of _0x59a5f4){String(_0x3b79cd[_0x5e2efe(0x140)]??'')[_0x5e2efe(0x13e)]()===_0x401fdd&&(_0x3b79cd['isCurrent']=!![]);}}export{readScopedConfig as readConfig,writeScopedConfig as writeConfig,isInProject}from'../../context.js';export function scopeLabel(_0x15b58c){const _0xecf9f=a7_0x1878;return formatScopeLabel(_0x15b58c[_0xecf9f(0x13b)]?_0xecf9f(0x13b):_0xecf9f(0x12b));}
1
+ (function(_0x3d8c95,_0xaa7262){const _0x5d162=a7_0x2276,_0x34cb44=_0x3d8c95();while(!![]){try{const _0x424ca8=parseInt(_0x5d162(0x1c0))/0x1+-parseInt(_0x5d162(0x1bd))/0x2*(-parseInt(_0x5d162(0x1c4))/0x3)+-parseInt(_0x5d162(0x1b3))/0x4*(parseInt(_0x5d162(0x1c5))/0x5)+parseInt(_0x5d162(0x1c2))/0x6*(parseInt(_0x5d162(0x1be))/0x7)+parseInt(_0x5d162(0x1c1))/0x8+parseInt(_0x5d162(0x1bf))/0x9+-parseInt(_0x5d162(0x1b1))/0xa;if(_0x424ca8===_0xaa7262)break;else _0x34cb44['push'](_0x34cb44['shift']());}catch(_0x18e844){_0x34cb44['push'](_0x34cb44['shift']());}}}(a7_0x2e87,0x934af));import{CLI_BIN_NAME}from'../../constant/cli.js';import{formatScopeLabel}from'../../commands/common/config-policy.js';export{CLI_BIN_NAME};export function enrichAppListItemsWithMergedSelection(_0xe5c854,_0x2bdc6d){const _0x118594=a7_0x2276;if(!_0x2bdc6d)return;const _0xaccd1f=!!(_0x2bdc6d[_0x118594(0x1bb)]??_0x2bdc6d[_0x118594(0x1b8)]);for(const _0x3e9a8c of _0xe5c854){_0x3e9a8c['isCurrent']=![];}const _0x8c1332=_0x2bdc6d[_0x118594(0x1bc)]!=null?String(_0x2bdc6d[_0x118594(0x1bc)])[_0x118594(0x1b2)]():'';if(_0xaccd1f){const _0x295907=_0x2bdc6d['currentApp']??_0x2bdc6d[_0x118594(0x1b8)];if(_0x295907){const _0xc4b164=_0xe5c854['find'](_0x4d6fe1=>_0x4d6fe1[_0x118594(0x1b7)]===!![]&&_0x4d6fe1[_0x118594(0x1c3)]===_0x295907&&_0x4d6fe1[_0x118594(0x1ba)]===_0x118594(0x1b9)),_0x4f3c18=_0xc4b164??_0xe5c854['find'](_0x5b5453=>_0x5b5453[_0x118594(0x1b7)]===!![]&&_0x5b5453['name']===_0x295907);_0x4f3c18&&(_0x4f3c18[_0x118594(0x1b0)]=!![]);}return;}if(!_0x8c1332)return;for(const _0xcc7735 of _0xe5c854){String(_0xcc7735[_0x118594(0x1b5)]??'')[_0x118594(0x1b2)]()===_0x8c1332&&(_0xcc7735[_0x118594(0x1b0)]=!![]);}}function a7_0x2e87(){const _0x270520=['name','610593ZylhEd','5EcUtrL','isCurrent','25342360gJmFNU','trim','432868uIuVaJ','project','appcode','global','named','defaultApp','local','definedIn','currentApp','appCode','6yWcgcR','999593vnkXdj','10304334eKIEcS','220110Oeqzkh','9018688AusBMn','6sSSjyN'];a7_0x2e87=function(){return _0x270520;};return a7_0x2e87();}export{readScopedConfig as readConfig,writeScopedConfig as writeConfig,isInProject}from'../../context.js';function a7_0x2276(_0x2356a5,_0x4bd700){_0x2356a5=_0x2356a5-0x1b0;const _0x2e8792=a7_0x2e87();let _0x2276ac=_0x2e8792[_0x2356a5];return _0x2276ac;}export function scopeLabel(_0x6c9989){const _0x58b085=a7_0x2276;return formatScopeLabel(_0x6c9989[_0x58b085(0x1b6)]?_0x58b085(0x1b6):_0x58b085(0x1b4));}
@@ -1 +1 @@
1
- const a8_0x10fad2=a8_0x4c18;(function(_0x25d1aa,_0x28b7ad){const _0x5c0742=a8_0x4c18,_0x30bf8f=_0x25d1aa();while(!![]){try{const _0x46b49c=-parseInt(_0x5c0742(0x1ab))/0x1+parseInt(_0x5c0742(0x1d2))/0x2+parseInt(_0x5c0742(0x1c1))/0x3+parseInt(_0x5c0742(0x1c6))/0x4*(-parseInt(_0x5c0742(0x1a9))/0x5)+-parseInt(_0x5c0742(0x19d))/0x6+parseInt(_0x5c0742(0x1ca))/0x7*(-parseInt(_0x5c0742(0x1cf))/0x8)+parseInt(_0x5c0742(0x1dc))/0x9;if(_0x46b49c===_0x28b7ad)break;else _0x30bf8f['push'](_0x30bf8f['shift']());}catch(_0x460cb9){_0x30bf8f['push'](_0x30bf8f['shift']());}}}(a8_0x2eda,0x31da4));function a8_0x2eda(){const _0x2bf7f6=['body','Artifact\x20display\x20name','artifactType','lastIndex','createTime','Optional\x20source\x20filter,\x20for\x20example\x20AGENT','Show\x20one\x20Artifact\x20by\x20id','description','5699277EZqXpm','/update','some','Artifact\x20source\x20file\x20is\x20blank.','boolean','deleted','file','File\x20not\x20found:\x20','compiledContent','split','Optional\x20favorite-state\x20filter','filter','updateTime','228774dGGJPJ','antd','File\x20is\x20not\x20a\x20regular\x20file:\x20','--metadata\x20must\x20be\x20a\x20JSON\x20object.','lodash','artifact','num','Update\x20a\x20react_module\x20Artifact\x20from\x20a\x20local\x20source\x20file','appCode','source','react-dom','AGENT','765TwMxnO','react_module\x20must\x20be\x20an\x20embeddable\x20React\x20module,\x20not\x20full\x20HTML\x20or\x20a\x20ReactDOM/createRoot\x20mount\x20entry.','249704RaRWVz','/client/artifact/create','react_module','write','bool','Path\x20to\x20a\x20local\x20UTF-8\x20React\x20module\x20source\x20file','favorite','trim','exec','build','flag','Artifact\x20metadata\x20as\x20JSON\x20object;\x20compiledContent\x20is\x20stripped','.\x20Unsupported:\x20','isArray','verbose','read','join','/client/artifact/','list','map','name','POST','477990VybEqD','includes','Preview:\x20create\x20react_module\x20Artifact','List\x20current-app\x20react_module\x20Artifacts','File\x20path\x20is\x20required.','7408jMHccB','detail','string','metadata','1351BZyFNg','react_module\x20imports\x20are\x20limited\x20to:\x20','Artifact\x20ID','startsWith','length','3440yDPnTx','validation','add','131584kZjoKc','str'];a8_0x2eda=function(){return _0x2bf7f6;};return a8_0x2eda();}import{existsSync,readFileSync,statSync}from'node:fs';import{createRuntimeArtifact,getRuntimeArtifact,listRuntimeArtifacts,updateRuntimeArtifact}from'../../core/api-client.js';function a8_0x4c18(_0x448777,_0x341f1a){_0x448777=_0x448777-0x19d;const _0x2eda32=a8_0x2eda();let _0x4c18f9=_0x2eda32[_0x448777];return _0x4c18f9;}import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const ARTIFACT_TYPE_REACT_MODULE=a8_0x10fad2(0x1ad),ARTIFACT_SOURCE_AGENT=a8_0x10fad2(0x1a8),ALLOWED_REACT_MODULE_IMPORTS=['react',a8_0x10fad2(0x1a7),a8_0x10fad2(0x1a1),'dayjs',a8_0x10fad2(0x19e),'@ant-design/icons'];export const ALLOWED_REACT_MODULE_IMPORTS_TEXT=ALLOWED_REACT_MODULE_IMPORTS['join'](',\x20');const IMPORT_SOURCE_PATTERNS=[/\bimport\s+(?:type\s+)?(?:[^'";]*?\s+from\s+)?["']([^"']+)["']/g,/\bexport\s+(?:type\s+)?[^'";]*?\s+from\s+["']([^"']+)["']/g,/\bimport\s*\(\s*["']([^"']+)["']\s*\)/g,/\brequire\s*\(\s*["']([^"']+)["']\s*\)/g],PAGE_LEVEL_PATTERNS=[/<!doctype\s+html/i,/<\s*html\b/i,/\bcreateRoot\s*\(/,/\bReactDOM\s*\.\s*render\s*\(/,/\bReactDOM\s*\.\s*createRoot\s*\(/],FILE_FLAG={'name':a8_0x10fad2(0x1e2),'type':a8_0x10fad2(0x1c8),'required':!![],'description':a8_0x10fad2(0x1b0)},ARTIFACT_NAME_FLAG={'name':a8_0x10fad2(0x1bf),'type':a8_0x10fad2(0x1c8),'description':a8_0x10fad2(0x1d5)},METADATA_FLAG={'name':a8_0x10fad2(0x1c9),'type':'string','description':a8_0x10fad2(0x1b6)};function isPlainObject(_0x3e8f6b){const _0x3ad7f7=a8_0x10fad2;return typeof _0x3e8f6b==='object'&&_0x3e8f6b!==null&&!Array[_0x3ad7f7(0x1b8)](_0x3e8f6b);}function readSourceFile(_0x20605d){const _0x238277=a8_0x10fad2;if(!_0x20605d)throw CliErrors['validation'](_0x238277(0x1c5));if(!existsSync(_0x20605d))throw CliErrors['validation'](_0x238277(0x1e3)+_0x20605d);if(!statSync(_0x20605d)['isFile']())throw CliErrors['validation'](_0x238277(0x19f)+_0x20605d);const _0x1dee79=readFileSync(_0x20605d,'utf8');return validateReactModuleSource(_0x1dee79),_0x1dee79;}function parseMetadata(_0x17fed8){const _0xfc1f49=a8_0x10fad2;if(!_0x17fed8)return undefined;let _0x40cc57;try{_0x40cc57=JSON['parse'](_0x17fed8);}catch{throw CliErrors[_0xfc1f49(0x1d0)]('Invalid\x20JSON\x20for\x20--metadata:\x20'+_0x17fed8);}if(!isPlainObject(_0x40cc57))throw CliErrors['validation'](_0xfc1f49(0x1a0));const _0x4f2c11={..._0x40cc57};return delete _0x4f2c11[_0xfc1f49(0x1e4)],_0x4f2c11;}function getPackageName(_0xa72780){const _0x1b574e=a8_0x10fad2;if(_0xa72780[_0x1b574e(0x1cd)]('@')){const [_0x47a543,_0x3c3ec2]=_0xa72780[_0x1b574e(0x1e5)]('/');return _0x47a543&&_0x3c3ec2?_0x47a543+'/'+_0x3c3ec2:_0xa72780;}return _0xa72780[_0x1b574e(0x1e5)]('/')[0x0]||_0xa72780;}function validateAllowedImports(_0x1c0640){const _0x21bc41=a8_0x10fad2,_0x5939d2=new Set();for(const _0x2f3471 of IMPORT_SOURCE_PATTERNS){_0x2f3471[_0x21bc41(0x1d7)]=0x0;let _0xa1acf2;while((_0xa1acf2=_0x2f3471[_0x21bc41(0x1b3)](_0x1c0640))!==null){const _0x183021=_0xa1acf2[0x1]?.[_0x21bc41(0x1b2)]();_0x183021&&_0x5939d2[_0x21bc41(0x1d1)](_0x183021);}}const _0x520533=[..._0x5939d2][_0x21bc41(0x1be)](getPackageName)[_0x21bc41(0x1e7)](_0x3d6a73=>!ALLOWED_REACT_MODULE_IMPORTS[_0x21bc41(0x1c2)](_0x3d6a73));if(_0x520533[_0x21bc41(0x1ce)]>0x0)throw CliErrors[_0x21bc41(0x1d0)](_0x21bc41(0x1cb)+ALLOWED_REACT_MODULE_IMPORTS_TEXT+_0x21bc41(0x1b7)+[...new Set(_0x520533)][_0x21bc41(0x1bb)](',\x20'));}export function validateReactModuleSource(_0x237999){const _0x4379ad=a8_0x10fad2;if(!_0x237999[_0x4379ad(0x1b2)]())throw CliErrors[_0x4379ad(0x1d0)](_0x4379ad(0x1df));if(PAGE_LEVEL_PATTERNS[_0x4379ad(0x1de)](_0x277cba=>_0x277cba['test'](_0x237999)))throw CliErrors[_0x4379ad(0x1d0)](_0x4379ad(0x1aa));validateAllowedImports(_0x237999);}function buildArtifactInput(_0x7c8f1){const _0x533e50=a8_0x10fad2,_0x29697a=readSourceFile(_0x7c8f1['str'](_0x533e50(0x1e2))),_0x25bffb=_0x7c8f1[_0x533e50(0x1d3)]('name')[_0x533e50(0x1b2)](),_0x519b2b=parseMetadata(_0x7c8f1[_0x533e50(0x1d3)](_0x533e50(0x1c9)));return{'artifactType':ARTIFACT_TYPE_REACT_MODULE,..._0x25bffb?{'name':_0x25bffb}:{},'content':_0x29697a,..._0x519b2b?{'metadata':_0x519b2b}:{},'source':ARTIFACT_SOURCE_AGENT};}function summarizeArtifact(_0x5d3180){const _0x477a73=a8_0x10fad2;return{'id':_0x5d3180['id'],'name':_0x5d3180[_0x477a73(0x1bf)],'artifactType':_0x5d3180[_0x477a73(0x1d6)],'source':_0x5d3180['source'],'favorite':_0x5d3180[_0x477a73(0x1b1)],'deleted':_0x5d3180[_0x477a73(0x1e1)],'createTime':_0x5d3180[_0x477a73(0x1d8)],'updateTime':_0x5d3180['updateTime']};}function detailArtifact(_0x57e9d9){const _0x488ecc=a8_0x10fad2;return{'id':_0x57e9d9['id'],'appCode':_0x57e9d9[_0x488ecc(0x1a5)],'name':_0x57e9d9[_0x488ecc(0x1bf)],'artifactType':_0x57e9d9[_0x488ecc(0x1d6)],'source':_0x57e9d9['source'],'favorite':_0x57e9d9[_0x488ecc(0x1b1)],'deleted':_0x57e9d9[_0x488ecc(0x1e1)],'content':_0x57e9d9['content']??'','compiledContent':_0x57e9d9[_0x488ecc(0x1e4)],'metadata':_0x57e9d9['metadata']??{},'createTime':_0x57e9d9[_0x488ecc(0x1d8)],'updateTime':_0x57e9d9[_0x488ecc(0x1e8)]};}function readFavoriteFlag(_0x4b3d3a){const _0x1bb03f=a8_0x10fad2,_0x3090c7=_0x4b3d3a[_0x1bb03f(0x1b5)]('favorite');return _0x3090c7===undefined||_0x3090c7===null||_0x3090c7===''?undefined:_0x4b3d3a[_0x1bb03f(0x1af)]('favorite');}const artifactList={'service':a8_0x10fad2(0x1a2),'command':a8_0x10fad2(0x1bd),'description':a8_0x10fad2(0x1c4),'risk':a8_0x10fad2(0x1ba),'flags':[{'name':a8_0x10fad2(0x1a6),'type':a8_0x10fad2(0x1c8),'description':a8_0x10fad2(0x1d9)},{'name':a8_0x10fad2(0x1b1),'type':a8_0x10fad2(0x1e0),'description':a8_0x10fad2(0x1e6)},VERBOSE_FLAG],async 'execute'(_0x44c3d3){const _0x4e004f=a8_0x10fad2,_0x3909a1=await listRuntimeArtifacts(_0x44c3d3[_0x4e004f(0x1a5)],{'artifactType':ARTIFACT_TYPE_REACT_MODULE,..._0x44c3d3['str'](_0x4e004f(0x1a6))?{'source':_0x44c3d3[_0x4e004f(0x1d3)](_0x4e004f(0x1a6))}:{},...readFavoriteFlag(_0x44c3d3)!==undefined?{'favorite':readFavoriteFlag(_0x44c3d3)}:{}});return{'ok':!![],'data':{'total':_0x3909a1['length'],'items':_0x44c3d3['bool'](_0x4e004f(0x1b9))?_0x3909a1:_0x3909a1[_0x4e004f(0x1be)](summarizeArtifact)}};}},artifactDetail={'service':'artifact','command':a8_0x10fad2(0x1c7),'description':a8_0x10fad2(0x1da),'risk':'read','flags':[{...ID_FLAG,'description':a8_0x10fad2(0x1cc)}],async 'execute'(_0x242051){const _0x57813e=a8_0x10fad2,_0x569f96=await getRuntimeArtifact(_0x242051[_0x57813e(0x1a3)]('id'),_0x242051[_0x57813e(0x1a5)]);return{'ok':!![],'data':detailArtifact(_0x569f96)};}},artifactCreate={'service':a8_0x10fad2(0x1a2),'command':'create','description':'Create\x20a\x20react_module\x20Artifact\x20from\x20a\x20local\x20source\x20file','risk':a8_0x10fad2(0x1ae),'flags':[FILE_FLAG,ARTIFACT_NAME_FLAG,METADATA_FLAG],async 'execute'(_0x4aa4fc){const _0x968101=a8_0x10fad2,_0x1d479a=buildArtifactInput(_0x4aa4fc),_0x2daf9a=await createRuntimeArtifact(_0x4aa4fc[_0x968101(0x1a5)],_0x1d479a);return{'ok':!![],'data':detailArtifact(_0x2daf9a),'message':'Created\x20Artifact\x20'+_0x2daf9a['id']+(_0x2daf9a['name']?'\x20('+_0x2daf9a[_0x968101(0x1bf)]+')':'')};},async 'dryRun'(_0x9f6f4d){const _0x3c0dff=a8_0x10fad2,_0x558406=buildArtifactInput(_0x9f6f4d);return dryRun(_0x3c0dff(0x1c0),_0x3c0dff(0x1ac))['body']({'appCode':_0x9f6f4d[_0x3c0dff(0x1a5)],..._0x558406})[_0x3c0dff(0x1db)](_0x3c0dff(0x1c3))[_0x3c0dff(0x1b4)]();}},artifactUpdate={'service':a8_0x10fad2(0x1a2),'command':'update','description':a8_0x10fad2(0x1a4),'risk':a8_0x10fad2(0x1ae),'flags':[{...ID_FLAG,'description':a8_0x10fad2(0x1cc)},FILE_FLAG,ARTIFACT_NAME_FLAG,METADATA_FLAG],async 'execute'(_0x6b7b0f){const _0x529f08=a8_0x10fad2,_0x2e9f6b=_0x6b7b0f['num']('id'),_0x15634d=buildArtifactInput(_0x6b7b0f),_0x1b9048=await updateRuntimeArtifact(_0x2e9f6b,_0x6b7b0f[_0x529f08(0x1a5)],_0x15634d);return{'ok':!![],'data':detailArtifact(_0x1b9048),'message':'Updated\x20Artifact\x20'+_0x1b9048['id']+(_0x1b9048[_0x529f08(0x1bf)]?'\x20('+_0x1b9048[_0x529f08(0x1bf)]+')':'')};},async 'dryRun'(_0x5ad951){const _0x1a6d8=a8_0x10fad2,_0x449542=_0x5ad951['num']('id'),_0x4bd781=buildArtifactInput(_0x5ad951);return dryRun('POST',_0x1a6d8(0x1bc)+_0x449542+_0x1a6d8(0x1dd))[_0x1a6d8(0x1d4)]({'appCode':_0x5ad951[_0x1a6d8(0x1a5)],..._0x4bd781})['description']('Preview:\x20update\x20react_module\x20Artifact\x20'+_0x449542)[_0x1a6d8(0x1b4)]();}};export const artifactDefinitions=[artifactList,artifactDetail,artifactCreate,artifactUpdate];
1
+ const a8_0x66354b=a8_0x5807;(function(_0x350e6c,_0x2518c0){const _0x1d5c20=a8_0x5807,_0x36da98=_0x350e6c();while(!![]){try{const _0x3d882e=parseInt(_0x1d5c20(0x1c6))/0x1+parseInt(_0x1d5c20(0x1d1))/0x2*(-parseInt(_0x1d5c20(0x1d9))/0x3)+parseInt(_0x1d5c20(0x1e9))/0x4*(-parseInt(_0x1d5c20(0x1bd))/0x5)+parseInt(_0x1d5c20(0x1ee))/0x6+-parseInt(_0x1d5c20(0x1d5))/0x7*(-parseInt(_0x1d5c20(0x1c4))/0x8)+-parseInt(_0x1d5c20(0x1f0))/0x9+parseInt(_0x1d5c20(0x1d0))/0xa;if(_0x3d882e===_0x2518c0)break;else _0x36da98['push'](_0x36da98['shift']());}catch(_0x2866d6){_0x36da98['push'](_0x36da98['shift']());}}}(a8_0x5047,0x7cf01));import{existsSync,readFileSync,statSync}from'node:fs';import{createRuntimeArtifact,getRuntimeArtifact,listRuntimeArtifacts,updateRuntimeArtifact}from'../../core/api-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';function a8_0x5807(_0x2c67ad,_0x5ca5eb){_0x2c67ad=_0x2c67ad-0x1b9;const _0x5047a6=a8_0x5047();let _0x5807b2=_0x5047a6[_0x2c67ad];return _0x5807b2;}function a8_0x5047(){const _0x58090c=['update','lodash','POST','deleted','Artifact\x20ID','detail','startsWith','build','some','num','source','boolean','Updated\x20Artifact\x20','parse','compiledContent','write','trim','/update','@ant-design/icons','/client/artifact/create','join','split','15JDNooA','File\x20is\x20not\x20a\x20regular\x20file:\x20','react_module\x20must\x20be\x20an\x20embeddable\x20React\x20module,\x20not\x20full\x20HTML\x20or\x20a\x20ReactDOM/createRoot\x20mount\x20entry.','validation','body','Optional\x20favorite-state\x20filter','list','6118040blVeTk','exec','20162IiwPWX','Create\x20a\x20react_module\x20Artifact\x20from\x20a\x20local\x20source\x20file','File\x20path\x20is\x20required.','/client/artifact/','appCode','lastIndex','updateTime','metadata','favorite','Path\x20to\x20a\x20local\x20UTF-8\x20React\x20module\x20source\x20file','3303550gzPgOS','718vIFjgb','bool','object','string','7yWbwtE','Artifact\x20source\x20file\x20is\x20blank.','File\x20not\x20found:\x20','flag','6081UhoDBe','Update\x20a\x20react_module\x20Artifact\x20from\x20a\x20local\x20source\x20file','react_module','AGENT','isArray','react-dom','map','react_module\x20imports\x20are\x20limited\x20to:\x20','Show\x20one\x20Artifact\x20by\x20id','description','createTime','artifactType','includes','Invalid\x20JSON\x20for\x20--metadata:\x20','antd','Preview:\x20create\x20react_module\x20Artifact','402092yJOLOM','Artifact\x20display\x20name','artifact','name','length','2701536xYfTob','file','220689bCmsQA','read','str'];a8_0x5047=function(){return _0x58090c;};return a8_0x5047();}import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const ARTIFACT_TYPE_REACT_MODULE=a8_0x66354b(0x1db),ARTIFACT_SOURCE_AGENT=a8_0x66354b(0x1dc),ALLOWED_REACT_MODULE_IMPORTS=['react',a8_0x66354b(0x1de),a8_0x66354b(0x1f4),'dayjs',a8_0x66354b(0x1e7),a8_0x66354b(0x1b9)];export const ALLOWED_REACT_MODULE_IMPORTS_TEXT=ALLOWED_REACT_MODULE_IMPORTS['join'](',\x20');const IMPORT_SOURCE_PATTERNS=[/\bimport\s+(?:type\s+)?(?:[^'";]*?\s+from\s+)?["']([^"']+)["']/g,/\bexport\s+(?:type\s+)?[^'";]*?\s+from\s+["']([^"']+)["']/g,/\bimport\s*\(\s*["']([^"']+)["']\s*\)/g,/\brequire\s*\(\s*["']([^"']+)["']\s*\)/g],PAGE_LEVEL_PATTERNS=[/<!doctype\s+html/i,/<\s*html\b/i,/\bcreateRoot\s*\(/,/\bReactDOM\s*\.\s*render\s*\(/,/\bReactDOM\s*\.\s*createRoot\s*\(/],FILE_FLAG={'name':a8_0x66354b(0x1ef),'type':a8_0x66354b(0x1d4),'required':!![],'description':a8_0x66354b(0x1cf)},ARTIFACT_NAME_FLAG={'name':'name','type':a8_0x66354b(0x1d4),'description':a8_0x66354b(0x1ea)},METADATA_FLAG={'name':a8_0x66354b(0x1cd),'type':a8_0x66354b(0x1d4),'description':'Artifact\x20metadata\x20as\x20JSON\x20object;\x20compiledContent\x20is\x20stripped'};function isPlainObject(_0x3dd53a){const _0x53fd8c=a8_0x66354b;return typeof _0x3dd53a===_0x53fd8c(0x1d3)&&_0x3dd53a!==null&&!Array[_0x53fd8c(0x1dd)](_0x3dd53a);}function readSourceFile(_0x32a6ba){const _0x251d0d=a8_0x66354b;if(!_0x32a6ba)throw CliErrors['validation'](_0x251d0d(0x1c8));if(!existsSync(_0x32a6ba))throw CliErrors['validation'](_0x251d0d(0x1d7)+_0x32a6ba);if(!statSync(_0x32a6ba)['isFile']())throw CliErrors[_0x251d0d(0x1c0)](_0x251d0d(0x1be)+_0x32a6ba);const _0x105612=readFileSync(_0x32a6ba,'utf8');return validateReactModuleSource(_0x105612),_0x105612;}function parseMetadata(_0x534ad0){const _0x36ec2f=a8_0x66354b;if(!_0x534ad0)return undefined;let _0x97ba2;try{_0x97ba2=JSON[_0x36ec2f(0x200)](_0x534ad0);}catch{throw CliErrors[_0x36ec2f(0x1c0)](_0x36ec2f(0x1e6)+_0x534ad0);}if(!isPlainObject(_0x97ba2))throw CliErrors[_0x36ec2f(0x1c0)]('--metadata\x20must\x20be\x20a\x20JSON\x20object.');const _0x3178ba={..._0x97ba2};return delete _0x3178ba[_0x36ec2f(0x201)],_0x3178ba;}function getPackageName(_0x36b2c2){const _0x5dc702=a8_0x66354b;if(_0x36b2c2[_0x5dc702(0x1f9)]('@')){const [_0x24b00c,_0x3d2707]=_0x36b2c2[_0x5dc702(0x1bc)]('/');return _0x24b00c&&_0x3d2707?_0x24b00c+'/'+_0x3d2707:_0x36b2c2;}return _0x36b2c2[_0x5dc702(0x1bc)]('/')[0x0]||_0x36b2c2;}function validateAllowedImports(_0x5f3830){const _0x259c80=a8_0x66354b,_0x4c1a4f=new Set();for(const _0x34bc69 of IMPORT_SOURCE_PATTERNS){_0x34bc69[_0x259c80(0x1cb)]=0x0;let _0x16ace3;while((_0x16ace3=_0x34bc69[_0x259c80(0x1c5)](_0x5f3830))!==null){const _0x3a45a0=_0x16ace3[0x1]?.[_0x259c80(0x203)]();_0x3a45a0&&_0x4c1a4f['add'](_0x3a45a0);}}const _0x3dc84f=[..._0x4c1a4f][_0x259c80(0x1df)](getPackageName)['filter'](_0x1d2af0=>!ALLOWED_REACT_MODULE_IMPORTS[_0x259c80(0x1e5)](_0x1d2af0));if(_0x3dc84f[_0x259c80(0x1ed)]>0x0)throw CliErrors[_0x259c80(0x1c0)](_0x259c80(0x1e0)+ALLOWED_REACT_MODULE_IMPORTS_TEXT+'.\x20Unsupported:\x20'+[...new Set(_0x3dc84f)][_0x259c80(0x1bb)](',\x20'));}export function validateReactModuleSource(_0x431062){const _0x3b17a1=a8_0x66354b;if(!_0x431062[_0x3b17a1(0x203)]())throw CliErrors[_0x3b17a1(0x1c0)](_0x3b17a1(0x1d6));if(PAGE_LEVEL_PATTERNS[_0x3b17a1(0x1fb)](_0x40c415=>_0x40c415['test'](_0x431062)))throw CliErrors['validation'](_0x3b17a1(0x1bf));validateAllowedImports(_0x431062);}function buildArtifactInput(_0x8ec845){const _0x3c5feb=a8_0x66354b,_0x6c1cdb=readSourceFile(_0x8ec845[_0x3c5feb(0x1f2)](_0x3c5feb(0x1ef))),_0x5e2167=_0x8ec845[_0x3c5feb(0x1f2)](_0x3c5feb(0x1ec))[_0x3c5feb(0x203)](),_0x405a73=parseMetadata(_0x8ec845['str'](_0x3c5feb(0x1cd)));return{'artifactType':ARTIFACT_TYPE_REACT_MODULE,..._0x5e2167?{'name':_0x5e2167}:{},'content':_0x6c1cdb,..._0x405a73?{'metadata':_0x405a73}:{},'source':ARTIFACT_SOURCE_AGENT};}function summarizeArtifact(_0x1a867f){const _0xe2a8e6=a8_0x66354b;return{'id':_0x1a867f['id'],'name':_0x1a867f[_0xe2a8e6(0x1ec)],'artifactType':_0x1a867f[_0xe2a8e6(0x1e4)],'source':_0x1a867f['source'],'favorite':_0x1a867f[_0xe2a8e6(0x1ce)],'deleted':_0x1a867f[_0xe2a8e6(0x1f6)],'createTime':_0x1a867f[_0xe2a8e6(0x1e3)],'updateTime':_0x1a867f[_0xe2a8e6(0x1cc)]};}function detailArtifact(_0x1d37eb){const _0x3a4418=a8_0x66354b;return{'id':_0x1d37eb['id'],'appCode':_0x1d37eb[_0x3a4418(0x1ca)],'name':_0x1d37eb['name'],'artifactType':_0x1d37eb[_0x3a4418(0x1e4)],'source':_0x1d37eb[_0x3a4418(0x1fd)],'favorite':_0x1d37eb[_0x3a4418(0x1ce)],'deleted':_0x1d37eb[_0x3a4418(0x1f6)],'content':_0x1d37eb['content']??'','compiledContent':_0x1d37eb[_0x3a4418(0x201)],'metadata':_0x1d37eb['metadata']??{},'createTime':_0x1d37eb[_0x3a4418(0x1e3)],'updateTime':_0x1d37eb['updateTime']};}function readFavoriteFlag(_0x1876a3){const _0x1656a0=a8_0x66354b,_0x1ac2b1=_0x1876a3[_0x1656a0(0x1d8)](_0x1656a0(0x1ce));return _0x1ac2b1===undefined||_0x1ac2b1===null||_0x1ac2b1===''?undefined:_0x1876a3['bool'](_0x1656a0(0x1ce));}const artifactList={'service':a8_0x66354b(0x1eb),'command':a8_0x66354b(0x1c3),'description':'List\x20current-app\x20react_module\x20Artifacts','risk':a8_0x66354b(0x1f1),'flags':[{'name':a8_0x66354b(0x1fd),'type':a8_0x66354b(0x1d4),'description':'Optional\x20source\x20filter,\x20for\x20example\x20AGENT'},{'name':a8_0x66354b(0x1ce),'type':a8_0x66354b(0x1fe),'description':a8_0x66354b(0x1c2)},VERBOSE_FLAG],async 'execute'(_0x13d175){const _0xb4ad8c=a8_0x66354b,_0x50b45a=await listRuntimeArtifacts(_0x13d175[_0xb4ad8c(0x1ca)],{'artifactType':ARTIFACT_TYPE_REACT_MODULE,..._0x13d175[_0xb4ad8c(0x1f2)](_0xb4ad8c(0x1fd))?{'source':_0x13d175[_0xb4ad8c(0x1f2)](_0xb4ad8c(0x1fd))}:{},...readFavoriteFlag(_0x13d175)!==undefined?{'favorite':readFavoriteFlag(_0x13d175)}:{}});return{'ok':!![],'data':{'total':_0x50b45a['length'],'items':_0x13d175[_0xb4ad8c(0x1d2)]('verbose')?_0x50b45a:_0x50b45a['map'](summarizeArtifact)}};}},artifactDetail={'service':a8_0x66354b(0x1eb),'command':a8_0x66354b(0x1f8),'description':a8_0x66354b(0x1e1),'risk':a8_0x66354b(0x1f1),'flags':[{...ID_FLAG,'description':a8_0x66354b(0x1f7)}],async 'execute'(_0x54c7e2){const _0x8349bd=a8_0x66354b,_0x3062e2=await getRuntimeArtifact(_0x54c7e2['num']('id'),_0x54c7e2[_0x8349bd(0x1ca)]);return{'ok':!![],'data':detailArtifact(_0x3062e2)};}},artifactCreate={'service':a8_0x66354b(0x1eb),'command':'create','description':a8_0x66354b(0x1c7),'risk':a8_0x66354b(0x202),'flags':[FILE_FLAG,ARTIFACT_NAME_FLAG,METADATA_FLAG],async 'execute'(_0x233cd6){const _0x2549f1=a8_0x66354b,_0xaf95f9=buildArtifactInput(_0x233cd6),_0x243a31=await createRuntimeArtifact(_0x233cd6[_0x2549f1(0x1ca)],_0xaf95f9);return{'ok':!![],'data':detailArtifact(_0x243a31),'message':'Created\x20Artifact\x20'+_0x243a31['id']+(_0x243a31[_0x2549f1(0x1ec)]?'\x20('+_0x243a31[_0x2549f1(0x1ec)]+')':'')};},async 'dryRun'(_0x4635e2){const _0x109db4=a8_0x66354b,_0x844bf9=buildArtifactInput(_0x4635e2);return dryRun(_0x109db4(0x1f5),_0x109db4(0x1ba))[_0x109db4(0x1c1)]({'appCode':_0x4635e2['appCode'],..._0x844bf9})[_0x109db4(0x1e2)](_0x109db4(0x1e8))[_0x109db4(0x1fa)]();}},artifactUpdate={'service':a8_0x66354b(0x1eb),'command':a8_0x66354b(0x1f3),'description':a8_0x66354b(0x1da),'risk':a8_0x66354b(0x202),'flags':[{...ID_FLAG,'description':a8_0x66354b(0x1f7)},FILE_FLAG,ARTIFACT_NAME_FLAG,METADATA_FLAG],async 'execute'(_0x42a743){const _0x535d69=a8_0x66354b,_0x2c6499=_0x42a743['num']('id'),_0x47b9d0=buildArtifactInput(_0x42a743),_0x17e47e=await updateRuntimeArtifact(_0x2c6499,_0x42a743[_0x535d69(0x1ca)],_0x47b9d0);return{'ok':!![],'data':detailArtifact(_0x17e47e),'message':_0x535d69(0x1ff)+_0x17e47e['id']+(_0x17e47e[_0x535d69(0x1ec)]?'\x20('+_0x17e47e['name']+')':'')};},async 'dryRun'(_0x51b048){const _0x42ab73=a8_0x66354b,_0x2543f3=_0x51b048[_0x42ab73(0x1fc)]('id'),_0x186bee=buildArtifactInput(_0x51b048);return dryRun('POST',_0x42ab73(0x1c9)+_0x2543f3+_0x42ab73(0x204))[_0x42ab73(0x1c1)]({'appCode':_0x51b048[_0x42ab73(0x1ca)],..._0x186bee})['description']('Preview:\x20update\x20react_module\x20Artifact\x20'+_0x2543f3)[_0x42ab73(0x1fa)]();}};export const artifactDefinitions=[artifactList,artifactDetail,artifactCreate,artifactUpdate];
@@ -1 +1 @@
1
- const a9_0x93ac11=a9_0x5bbc;(function(_0x12d324,_0x40abed){const _0x37d24f=a9_0x5bbc,_0x5e45cc=_0x12d324();while(!![]){try{const _0x4f4447=parseInt(_0x37d24f(0xa4))/0x1*(-parseInt(_0x37d24f(0x7e))/0x2)+parseInt(_0x37d24f(0xc4))/0x3+-parseInt(_0x37d24f(0xa2))/0x4*(-parseInt(_0x37d24f(0x74))/0x5)+-parseInt(_0x37d24f(0x98))/0x6+-parseInt(_0x37d24f(0x90))/0x7+-parseInt(_0x37d24f(0xb8))/0x8*(-parseInt(_0x37d24f(0x7d))/0x9)+parseInt(_0x37d24f(0xc7))/0xa;if(_0x4f4447===_0x40abed)break;else _0x5e45cc['push'](_0x5e45cc['shift']());}catch(_0x5af968){_0x5e45cc['push'](_0x5e45cc['shift']());}}}(a9_0x4c96,0xe4459));import{readScopedConfig,writeScopedConfig}from'../../context.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{PRODUCT_CONFIG,productEnv,productEnvName}from'../../constant/product.js';import{AUTH_MODE}from'../../constant/auth-mode.js';import{normalizeEnv,isDaily,isDev}from'../../constant/env.js';import{USER_ACCESS_KEY_CREATE_URL}from'../../constant/url.js';function a9_0x5bbc(_0x5f2d73,_0x1dfd94){_0x5f2d73=_0x5f2d73-0x71;const _0x4c96c3=a9_0x4c96();let _0x5bbce9=_0x4c96c3[_0x5f2d73];return _0x5bbce9;}import{CliErrors}from'../../errors.js';import{promptAccessKey,isAbortPrompt}from'../../commands/auth/prompt.js';import{resolveConfigScope,toScopeFlags}from'../../commands/common/config-policy.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';import{getLoginUserInfo}from'../../core/api-client.js';const ACCESS_KEY_PATTERN=/^ak_[A-Za-z0-9]{16,}$/;function showAccessKeyCreateHint(){const _0x10406f=a9_0x5bbc;writeCliSideChannelLine(_0x10406f(0xb2)+PRODUCT_CONFIG[_0x10406f(0x8f)]+':'),writeCliSideChannelLine('\x0a'+USER_ACCESS_KEY_CREATE_URL+'\x0a'),writeCliSideChannelLine('Tip:\x20you\x20can\x20also\x20run:'),writeCliSideChannelLine('\x20\x20'+CLI_BIN_NAME+_0x10406f(0xba));}function a9_0x4c96(){const _0x15a448=['bool','If\x20command\x20execution\x20still\x20fails,\x20run:\x20','Shorthand\x20for\x20--access-key','40NlnZYp','\x20auth\x20login\x20--access-key\x20<ak_xxx>`\x20to\x20save\x20credentials.','\x20auth\x20login\x20--access-key\x20<ak_xxx>','global','string','join','write','Write\x20to\x20global\x20config\x20(default)','Option\x20A:\x20','project','Clear\x20from\x20project\x20config\x20instead\x20of\x20global\x20config','slice','5166333Ldmdjg','\x20Verify:\x20','access-key','512740EPhdtN','No\x20AccessKey\x20found\x20in\x20','Show\x20current\x20authentication\x20status','Auth\x20config\x20reinitialized\x20in\x20','10WDpBtd','\x20auth\x20login\x20--non-interactive`\x20to\x20avoid\x20prompts,\x20or\x20`','newConfigFileName','accessKey','Invalid\x20accessKey\x20format:\x20\x22','\x20(via\x20','Target\x20environment\x20to\x20persist\x20with\x20the\x20new\x20auth\x20config','Then\x20verify\x20with:\x20','\x20config.','1727343PkTbFp','14jQONJD','\x20auth\x20login\x20--access-key\x20<ak_xxx>\x20[--global]','\x20\x20export\x20','cancelled','env','No\x20credentials\x20found.\x20Configure\x20one\x20of\x20the\x20options\x20below:','Auth\x20mode:\x20','length','\x20env\x20var','init','Clear\x20accessKey\x20from\x20config','\x20auth\x20status','Read\x20from\x20project\x20config\x20instead\x20of\x20global\x20config','AccessKey\x20saved\x20to\x20','envName','validation','Fetch\x20current\x20login\x20user\x20info\x20for\x20the\x20active\x20access\x20key','userCenterDisplayName','12957966QRgbBq','AccessKey\x20cleared\x20from\x20','AccessKey\x20(ak_xxx...)','\x20config','isTTY','\x20doctor','stdout','Option\x20B:\x20apps\x20config\x20(','2588178ibeMzt','Read\x20from\x20global\x20config\x20(default)','info','Clear\x20all\x20config\x20in\x20scope\x20and\x20initialize\x20auth\x20from\x20scratch','Write\x20to\x20project\x20config\x20instead\x20of\x20global\x20config','Clear\x20from\x20global\x20config\x20(default)','status','Missing\x20accessKey.','{\x20\x22accessKey\x22:\x20\x22ak_xxx\x22\x20}','str','1605712icuabc','Use\x20`','45482cDGlME','push','ACCESS_KEY','=ak_xxx','logout','auth','trim','\x20scope.','test','Save\x20accessKey\x20to\x20config\x20(global\x20by\x20default;\x20use\x20--project\x20for\x20project\x20config)','boolean','production','nonInteractive','global-default','AccessKey\x20required\x20for\x20login.\x20Create\x20one\x20in\x20','Give\x20the\x20AccessKey\x20to\x20your\x20AI\x20Agent,\x20then\x20run:\x20','stdin'];a9_0x4c96=function(){return _0x15a448;};return a9_0x4c96();}function buildAccessKeySetupGuide(){const _0x5b1cf3=a9_0x5bbc;return[_0x5b1cf3(0xb2)+PRODUCT_CONFIG[_0x5b1cf3(0x8f)]+':',USER_ACCESS_KEY_CREATE_URL,_0x5b1cf3(0xb3)+CLI_BIN_NAME+_0x5b1cf3(0x7f)][_0x5b1cf3(0xbd)]('\x0a');}function canPromptForAccessKey(_0x194930){const _0x4ac954=a9_0x5bbc;return!_0x194930['nonInteractive']&&process[_0x4ac954(0xb4)][_0x4ac954(0x94)]!==![]&&process[_0x4ac954(0x96)][_0x4ac954(0x94)]!==![];}function resolveAuthScopeFlags(_0xce5019){const _0x56ac6a=a9_0x5bbc;return toScopeFlags(resolveConfigScope({'explicitGlobal':_0xce5019[_0x56ac6a(0xb5)](_0x56ac6a(0xbb)),'explicitProject':_0xce5019['bool'](_0x56ac6a(0xc1)),'policy':_0x56ac6a(0xb1)}));}async function resolveAuthWriteInput(_0x749b2d){const _0x9afd3a=a9_0x5bbc;let _0x59662b=(_0x749b2d[_0x9afd3a(0xa1)](_0x9afd3a(0xc6))||_0x749b2d[_0x9afd3a(0xa1)]('ak')||'')[_0x9afd3a(0xaa)]();const _0x1d3a5f=(_0x749b2d['str'](_0x9afd3a(0x82))||'')[_0x9afd3a(0xaa)]();if(!_0x59662b&&canPromptForAccessKey(_0x749b2d))try{showAccessKeyCreateHint(),_0x59662b=await promptAccessKey('');}catch(_0xae81fc){if(isAbortPrompt(_0xae81fc))throw CliErrors[_0x9afd3a(0x81)]();throw _0xae81fc;}if(!_0x59662b)throw CliErrors[_0x9afd3a(0x8d)](_0x9afd3a(0x9f),buildAccessKeySetupGuide());if(!ACCESS_KEY_PATTERN[_0x9afd3a(0xac)](_0x59662b))throw CliErrors[_0x9afd3a(0x8d)](_0x9afd3a(0x78)+_0x59662b+'\x22','Expected:\x20ak_\x20followed\x20by\x2016+\x20alphanumeric\x20chars');if(!_0x1d3a5f)return{'accessKey':_0x59662b};const _0x1a91b7=normalizeEnv(_0x1d3a5f);return{'accessKey':_0x59662b,'env':isDaily(_0x1a91b7)?'daily':isDev(_0x1a91b7)?'development':_0x9afd3a(0xaf)};}export const authDefinitions=[{'service':a9_0x93ac11(0xa9),'command':'login','description':a9_0x93ac11(0xad),'risk':a9_0x93ac11(0xbe),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':a9_0x93ac11(0xc6),'type':a9_0x93ac11(0xbc),'description':'AccessKey\x20(ak_xxx...)'},{'name':'ak','type':'string','description':'Shorthand\x20for\x20--access-key'},{'name':a9_0x93ac11(0xbb),'type':a9_0x93ac11(0xae),'description':a9_0x93ac11(0xbf),'default':!![]},{'name':a9_0x93ac11(0xc1),'type':a9_0x93ac11(0xae),'description':a9_0x93ac11(0x9c),'default':![]}],async 'execute'(_0x251096){const _0x274824=a9_0x93ac11;if(_0x251096[_0x274824(0xb5)]('yes'))throw CliErrors[_0x274824(0x8d)]('`auth\x20login`\x20does\x20not\x20support\x20--yes.',_0x274824(0xa3)+CLI_BIN_NAME+_0x274824(0x75)+CLI_BIN_NAME+_0x274824(0xb9));const _0x2acf28=(_0x251096[_0x274824(0xa1)](_0x274824(0xc6))||_0x251096[_0x274824(0xa1)]('ak')||'')['trim']();if(!_0x2acf28&&_0x251096[_0x274824(0xb0)])return{'ok':!![],'message':buildAccessKeySetupGuide()};const _0x3d4183=await resolveAuthWriteInput(_0x251096),_0x192c82=resolveAuthScopeFlags(_0x251096),_0x397c29=readScopedConfig(_0x192c82);_0x397c29[_0x274824(0x77)]=_0x3d4183[_0x274824(0x77)];_0x3d4183[_0x274824(0x82)]&&(_0x397c29[_0x274824(0x82)]=_0x3d4183['env']);writeScopedConfig(_0x397c29,_0x192c82);const _0x46a482=_0x192c82['global']?_0x274824(0xbb):_0x274824(0xc1),_0x9cf828=_0x397c29['env']?'\x20Current\x20env:\x20'+_0x397c29[_0x274824(0x82)]+'.':'';return{'ok':!![],'message':_0x274824(0x8b)+_0x46a482+'\x20config.'+_0x9cf828+_0x274824(0xc5)+CLI_BIN_NAME+_0x274824(0x89)};}},{'service':a9_0x93ac11(0xa9),'command':a9_0x93ac11(0x87),'description':a9_0x93ac11(0x9b),'risk':a9_0x93ac11(0xbe),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':'access-key','type':'string','description':a9_0x93ac11(0x92)},{'name':'ak','type':a9_0x93ac11(0xbc),'description':a9_0x93ac11(0xb7)},{'name':a9_0x93ac11(0x82),'type':a9_0x93ac11(0xbc),'description':a9_0x93ac11(0x7a)},{'name':a9_0x93ac11(0xbb),'type':'boolean','description':a9_0x93ac11(0xbf),'default':!![]},{'name':a9_0x93ac11(0xc1),'type':a9_0x93ac11(0xae),'description':'Write\x20to\x20project\x20config\x20instead\x20of\x20global\x20config','default':![]}],async 'execute'(_0x1038ec){const _0x36b93a=a9_0x93ac11,_0x49a5c5=await resolveAuthWriteInput(_0x1038ec),_0x24be58=resolveAuthScopeFlags(_0x1038ec),_0xb3e4b={'accessKey':_0x49a5c5[_0x36b93a(0x77)]};_0x49a5c5[_0x36b93a(0x82)]&&(_0xb3e4b['env']=_0x49a5c5[_0x36b93a(0x82)]);writeScopedConfig(_0xb3e4b,_0x24be58);const _0x5979a2=_0x24be58[_0x36b93a(0xbb)]?'global':_0x36b93a(0xc1),_0x4122db=_0xb3e4b[_0x36b93a(0x82)]?'\x20Current\x20env:\x20'+_0xb3e4b[_0x36b93a(0x82)]+'.':'';return{'ok':!![],'message':_0x36b93a(0x73)+_0x5979a2+_0x36b93a(0xab)+_0x4122db+_0x36b93a(0xc5)+CLI_BIN_NAME+_0x36b93a(0x89)};}},{'service':'auth','command':a9_0x93ac11(0xa8),'description':a9_0x93ac11(0x88),'risk':a9_0x93ac11(0xbe),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':'global','type':a9_0x93ac11(0xae),'description':a9_0x93ac11(0x9d),'default':!![]},{'name':a9_0x93ac11(0xc1),'type':a9_0x93ac11(0xae),'description':a9_0x93ac11(0xc2),'default':![]}],async 'execute'(_0x31303f){const _0x497f60=a9_0x93ac11,_0x293ced=resolveAuthScopeFlags(_0x31303f),_0x12b033=readScopedConfig(_0x293ced),_0x473728=!!_0x12b033['accessKey'];delete _0x12b033['accessKey'],writeScopedConfig(_0x12b033,_0x293ced);const _0x493ed0=_0x293ced[_0x497f60(0xbb)]?_0x497f60(0xbb):_0x497f60(0xc1);if(_0x473728)return{'ok':!![],'message':_0x497f60(0x91)+_0x493ed0+_0x497f60(0x7c)};return{'ok':!![],'message':_0x497f60(0x71)+_0x493ed0+'\x20config.\x20Nothing\x20to\x20clear.'};}},{'service':'auth','command':a9_0x93ac11(0x9e),'description':a9_0x93ac11(0x72),'risk':'read','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':'global','type':a9_0x93ac11(0xae),'description':a9_0x93ac11(0x99),'default':!![]},{'name':a9_0x93ac11(0xc1),'type':a9_0x93ac11(0xae),'description':a9_0x93ac11(0x8a),'default':![]}],async 'execute'(_0x13cfe0){const _0x189218=a9_0x93ac11,_0x19489a=resolveAuthScopeFlags(_0x13cfe0),_0x1f1260=readScopedConfig(_0x19489a),_0x3f6904=productEnvName(_0x189218(0xa6)),_0x48953a=productEnv('ACCESS_KEY')||undefined,_0x101b82=_0x1f1260[_0x189218(0x77)]||undefined,_0x4772a9=_0x48953a||_0x101b82,_0x483213=_0x48953a?_0x3f6904+_0x189218(0x86):_0x101b82?(_0x19489a[_0x189218(0xbb)]?_0x189218(0xbb):_0x189218(0xc1))+_0x189218(0x93):null,_0x4c5d72=[_0x189218(0x84)+AUTH_MODE['ClientAk']];if(_0x4772a9){const _0x13d353=_0x4772a9[_0x189218(0x85)]>0x8?''+_0x4772a9[_0x189218(0xc3)](0x0,0x8)+'*'['repeat'](_0x4772a9[_0x189218(0x85)]-0x8):_0x4772a9;_0x4c5d72[_0x189218(0xa5)]('AccessKey:\x20'+_0x13d353+(_0x483213?_0x189218(0x79)+_0x483213+')':''));}return!_0x4772a9&&(_0x4c5d72[_0x189218(0xa5)](''),_0x4c5d72[_0x189218(0xa5)](_0x189218(0x83)),_0x4c5d72['push'](''),_0x4c5d72[_0x189218(0xa5)](_0x189218(0xc0)+CLI_BIN_NAME+'\x20auth\x20login\x20[--global]\x20[--access-key\x20ak_xxx]'),_0x4c5d72[_0x189218(0xa5)](''),_0x4c5d72[_0x189218(0xa5)](_0x189218(0x97)+PRODUCT_CONFIG[_0x189218(0x76)]+')'),_0x4c5d72[_0x189218(0xa5)](_0x189218(0xa0)),_0x4c5d72['push'](''),_0x4c5d72['push']('Option\x20C:\x20environment\x20variable'),_0x4c5d72[_0x189218(0xa5)](_0x189218(0x80)+_0x3f6904+_0x189218(0xa7)),_0x4c5d72[_0x189218(0xa5)](''),_0x4c5d72['push'](_0x189218(0x7b)+CLI_BIN_NAME+_0x189218(0x89)),_0x4c5d72[_0x189218(0xa5)](_0x189218(0xb6)+CLI_BIN_NAME+_0x189218(0x95))),{'ok':!![],'message':_0x4c5d72[_0x189218(0xbd)]('\x0a')};}},{'service':'auth','command':a9_0x93ac11(0x9a),'description':a9_0x93ac11(0x8e),'risk':'read','requiresAuth':!![],'requiresAppCode':![],'hasFormat':!![],'flags':[],async 'execute'(_0x229b2e){const _0xf48a14=a9_0x93ac11,_0x4b7d3e=await getLoginUserInfo();return{'ok':!![],'data':{'user':_0x4b7d3e,'meta':{'env':_0x229b2e[_0xf48a14(0x8c)]??'production'}}};}}];
1
+ const a9_0x23fbd5=a9_0x305b;(function(_0x456c38,_0x301e4b){const _0x4abe22=a9_0x305b,_0x1bdc05=_0x456c38();while(!![]){try{const _0x2fea43=-parseInt(_0x4abe22(0x1bf))/0x1+parseInt(_0x4abe22(0x1c7))/0x2+parseInt(_0x4abe22(0x197))/0x3*(-parseInt(_0x4abe22(0x1cc))/0x4)+-parseInt(_0x4abe22(0x1b9))/0x5*(-parseInt(_0x4abe22(0x19f))/0x6)+-parseInt(_0x4abe22(0x19b))/0x7+-parseInt(_0x4abe22(0x18b))/0x8*(-parseInt(_0x4abe22(0x1af))/0x9)+-parseInt(_0x4abe22(0x1cd))/0xa*(-parseInt(_0x4abe22(0x1de))/0xb);if(_0x2fea43===_0x301e4b)break;else _0x1bdc05['push'](_0x1bdc05['shift']());}catch(_0x1ff518){_0x1bdc05['push'](_0x1bdc05['shift']());}}}(a9_0x50e6,0xb8f99));import{readScopedConfig,writeScopedConfig}from'../../context.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{PRODUCT_CONFIG,productEnv,productEnvName}from'../../constant/product.js';import{AUTH_MODE}from'../../constant/auth-mode.js';import{normalizeEnv,isDaily,isDev}from'../../constant/env.js';import{USER_ACCESS_KEY_CREATE_URL}from'../../constant/url.js';import{CliErrors}from'../../errors.js';import{promptAccessKey,isAbortPrompt}from'../../commands/auth/prompt.js';function a9_0x50e6(){const _0x14b983=['global','Read\x20from\x20global\x20config\x20(default)','stdin','yes','Auth\x20mode:\x20','\x20auth\x20login\x20--access-key\x20<ak_xxx>','trim','test','Then\x20verify\x20with:\x20','read','global-default','Option\x20A:\x20','126LARSzc','\x20env\x20var','access-key','init','isTTY','AccessKey\x20saved\x20to\x20','Shorthand\x20for\x20--access-key','str','Clear\x20accessKey\x20from\x20config','repeat','653305RuymTB','\x20auth\x20login\x20--access-key\x20<ak_xxx>\x20[--global]','No\x20credentials\x20found.\x20Configure\x20one\x20of\x20the\x20options\x20below:','\x20(via\x20','ClientAk','Option\x20B:\x20apps\x20config\x20(','662647PupPRF','info','Write\x20to\x20project\x20config\x20instead\x20of\x20global\x20config','ACCESS_KEY','\x20Current\x20env:\x20','envName','length','push','2931570DbbaQe','Give\x20the\x20AccessKey\x20to\x20your\x20AI\x20Agent,\x20then\x20run:\x20','project','slice','production','138624LfoPsm','230hnBpen','\x20auth\x20login\x20[--global]\x20[--access-key\x20ak_xxx]','\x20auth\x20login\x20--non-interactive`\x20to\x20avoid\x20prompts,\x20or\x20`','Show\x20current\x20authentication\x20status','string','Invalid\x20accessKey\x20format:\x20\x22','validation','boolean','\x20scope.','Clear\x20from\x20project\x20config\x20instead\x20of\x20global\x20config','`auth\x20login`\x20does\x20not\x20support\x20--yes.','Option\x20C:\x20environment\x20variable','join','Read\x20from\x20project\x20config\x20instead\x20of\x20global\x20config','userCenterDisplayName','development','Auth\x20config\x20reinitialized\x20in\x20','929258YqowmW','AccessKey\x20cleared\x20from\x20','No\x20AccessKey\x20found\x20in\x20','AccessKey\x20required\x20for\x20login.\x20Create\x20one\x20in\x20','\x20Verify:\x20','login','Expected:\x20ak_\x20followed\x20by\x2016+\x20alphanumeric\x20chars','70624tWygcw','bool','\x20\x20export\x20','Write\x20to\x20global\x20config\x20(default)','daily','\x20auth\x20status','auth','accessKey','env','Missing\x20accessKey.','\x20config','stdout','84skrCOo','write','Fetch\x20current\x20login\x20user\x20info\x20for\x20the\x20active\x20access\x20key','AccessKey:\x20','8906520aXeUCX','\x20doctor','\x20config.','Clear\x20from\x20global\x20config\x20(default)','6wTinuA','=ak_xxx','\x20config.\x20Nothing\x20to\x20clear.','{\x20\x22accessKey\x22:\x20\x22ak_xxx\x22\x20}'];a9_0x50e6=function(){return _0x14b983;};return a9_0x50e6();}import{resolveConfigScope,toScopeFlags}from'../../commands/common/config-policy.js';import{writeCliSideChannelLine}from'../../utils/write-cli-side-channel.js';import{getLoginUserInfo}from'../../core/api-client.js';const ACCESS_KEY_PATTERN=/^ak_[A-Za-z0-9]{16,}$/;function showAccessKeyCreateHint(){const _0x5ad2f2=a9_0x305b;writeCliSideChannelLine(_0x5ad2f2(0x1e1)+PRODUCT_CONFIG[_0x5ad2f2(0x1db)]+':'),writeCliSideChannelLine('\x0a'+USER_ACCESS_KEY_CREATE_URL+'\x0a'),writeCliSideChannelLine('Tip:\x20you\x20can\x20also\x20run:'),writeCliSideChannelLine('\x20\x20'+CLI_BIN_NAME+_0x5ad2f2(0x1a8));}function a9_0x305b(_0x4276a1,_0xf50679){_0x4276a1=_0x4276a1-0x18b;const _0x50e60e=a9_0x50e6();let _0x305b84=_0x50e60e[_0x4276a1];return _0x305b84;}function buildAccessKeySetupGuide(){const _0x3351f5=a9_0x305b;return['AccessKey\x20required\x20for\x20login.\x20Create\x20one\x20in\x20'+PRODUCT_CONFIG[_0x3351f5(0x1db)]+':',USER_ACCESS_KEY_CREATE_URL,_0x3351f5(0x1c8)+CLI_BIN_NAME+_0x3351f5(0x1ba)][_0x3351f5(0x1d9)]('\x0a');}function canPromptForAccessKey(_0x31116a){const _0x78419f=a9_0x305b;return!_0x31116a['nonInteractive']&&process[_0x78419f(0x1a5)][_0x78419f(0x1b3)]!==![]&&process[_0x78419f(0x196)][_0x78419f(0x1b3)]!==![];}function resolveAuthScopeFlags(_0x149d64){const _0x3f0a70=a9_0x305b;return toScopeFlags(resolveConfigScope({'explicitGlobal':_0x149d64['bool'](_0x3f0a70(0x1a3)),'explicitProject':_0x149d64[_0x3f0a70(0x18c)]('project'),'policy':_0x3f0a70(0x1ad)}));}async function resolveAuthWriteInput(_0x59db4d){const _0x2e250c=a9_0x305b;let _0x5595e9=(_0x59db4d[_0x2e250c(0x1b6)]('access-key')||_0x59db4d[_0x2e250c(0x1b6)]('ak')||'')['trim']();const _0x4c7c44=(_0x59db4d[_0x2e250c(0x1b6)](_0x2e250c(0x193))||'')['trim']();if(!_0x5595e9&&canPromptForAccessKey(_0x59db4d))try{showAccessKeyCreateHint(),_0x5595e9=await promptAccessKey('');}catch(_0x599e50){if(isAbortPrompt(_0x599e50))throw CliErrors['cancelled']();throw _0x599e50;}if(!_0x5595e9)throw CliErrors['validation'](_0x2e250c(0x194),buildAccessKeySetupGuide());if(!ACCESS_KEY_PATTERN[_0x2e250c(0x1aa)](_0x5595e9))throw CliErrors[_0x2e250c(0x1d3)](_0x2e250c(0x1d2)+_0x5595e9+'\x22',_0x2e250c(0x1e4));if(!_0x4c7c44)return{'accessKey':_0x5595e9};const _0x50021a=normalizeEnv(_0x4c7c44);return{'accessKey':_0x5595e9,'env':isDaily(_0x50021a)?_0x2e250c(0x18f):isDev(_0x50021a)?_0x2e250c(0x1dc):_0x2e250c(0x1cb)};}export const authDefinitions=[{'service':a9_0x23fbd5(0x191),'command':a9_0x23fbd5(0x1e3),'description':'Save\x20accessKey\x20to\x20config\x20(global\x20by\x20default;\x20use\x20--project\x20for\x20project\x20config)','risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':a9_0x23fbd5(0x1b1),'type':a9_0x23fbd5(0x1d1),'description':'AccessKey\x20(ak_xxx...)'},{'name':'ak','type':'string','description':a9_0x23fbd5(0x1b5)},{'name':a9_0x23fbd5(0x1a3),'type':a9_0x23fbd5(0x1d4),'description':'Write\x20to\x20global\x20config\x20(default)','default':!![]},{'name':a9_0x23fbd5(0x1c9),'type':a9_0x23fbd5(0x1d4),'description':a9_0x23fbd5(0x1c1),'default':![]}],async 'execute'(_0x154107){const _0x6af906=a9_0x23fbd5;if(_0x154107[_0x6af906(0x18c)](_0x6af906(0x1a6)))throw CliErrors[_0x6af906(0x1d3)](_0x6af906(0x1d7),'Use\x20`'+CLI_BIN_NAME+_0x6af906(0x1cf)+CLI_BIN_NAME+'\x20auth\x20login\x20--access-key\x20<ak_xxx>`\x20to\x20save\x20credentials.');const _0x3b647c=(_0x154107['str'](_0x6af906(0x1b1))||_0x154107['str']('ak')||'')[_0x6af906(0x1a9)]();if(!_0x3b647c&&_0x154107['nonInteractive'])return{'ok':!![],'message':buildAccessKeySetupGuide()};const _0x45f86f=await resolveAuthWriteInput(_0x154107),_0x39f3bf=resolveAuthScopeFlags(_0x154107),_0x4aa29b=readScopedConfig(_0x39f3bf);_0x4aa29b[_0x6af906(0x192)]=_0x45f86f[_0x6af906(0x192)];_0x45f86f[_0x6af906(0x193)]&&(_0x4aa29b[_0x6af906(0x193)]=_0x45f86f[_0x6af906(0x193)]);writeScopedConfig(_0x4aa29b,_0x39f3bf);const _0x5ac01e=_0x39f3bf[_0x6af906(0x1a3)]?'global':_0x6af906(0x1c9),_0x16b1a0=_0x4aa29b[_0x6af906(0x193)]?_0x6af906(0x1c3)+_0x4aa29b[_0x6af906(0x193)]+'.':'';return{'ok':!![],'message':_0x6af906(0x1b4)+_0x5ac01e+'\x20config.'+_0x16b1a0+'\x20Verify:\x20'+CLI_BIN_NAME+'\x20auth\x20status'};}},{'service':'auth','command':a9_0x23fbd5(0x1b2),'description':'Clear\x20all\x20config\x20in\x20scope\x20and\x20initialize\x20auth\x20from\x20scratch','risk':a9_0x23fbd5(0x198),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':a9_0x23fbd5(0x1b1),'type':a9_0x23fbd5(0x1d1),'description':'AccessKey\x20(ak_xxx...)'},{'name':'ak','type':a9_0x23fbd5(0x1d1),'description':'Shorthand\x20for\x20--access-key'},{'name':a9_0x23fbd5(0x193),'type':a9_0x23fbd5(0x1d1),'description':'Target\x20environment\x20to\x20persist\x20with\x20the\x20new\x20auth\x20config'},{'name':a9_0x23fbd5(0x1a3),'type':'boolean','description':a9_0x23fbd5(0x18e),'default':!![]},{'name':a9_0x23fbd5(0x1c9),'type':'boolean','description':a9_0x23fbd5(0x1c1),'default':![]}],async 'execute'(_0x430d01){const _0x4a75f2=a9_0x23fbd5,_0x35a915=await resolveAuthWriteInput(_0x430d01),_0x5f3ddb=resolveAuthScopeFlags(_0x430d01),_0x5742cd={'accessKey':_0x35a915['accessKey']};_0x35a915[_0x4a75f2(0x193)]&&(_0x5742cd[_0x4a75f2(0x193)]=_0x35a915[_0x4a75f2(0x193)]);writeScopedConfig(_0x5742cd,_0x5f3ddb);const _0x364218=_0x5f3ddb[_0x4a75f2(0x1a3)]?'global':'project',_0xa558b8=_0x5742cd[_0x4a75f2(0x193)]?'\x20Current\x20env:\x20'+_0x5742cd[_0x4a75f2(0x193)]+'.':'';return{'ok':!![],'message':_0x4a75f2(0x1dd)+_0x364218+_0x4a75f2(0x1d5)+_0xa558b8+_0x4a75f2(0x1e2)+CLI_BIN_NAME+_0x4a75f2(0x190)};}},{'service':a9_0x23fbd5(0x191),'command':'logout','description':a9_0x23fbd5(0x1b7),'risk':a9_0x23fbd5(0x198),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':'global','type':'boolean','description':a9_0x23fbd5(0x19e),'default':!![]},{'name':a9_0x23fbd5(0x1c9),'type':'boolean','description':a9_0x23fbd5(0x1d6),'default':![]}],async 'execute'(_0x27ffe9){const _0x25e75c=a9_0x23fbd5,_0x283b8f=resolveAuthScopeFlags(_0x27ffe9),_0x560b74=readScopedConfig(_0x283b8f),_0x3df3f3=!!_0x560b74[_0x25e75c(0x192)];delete _0x560b74[_0x25e75c(0x192)],writeScopedConfig(_0x560b74,_0x283b8f);const _0x490dee=_0x283b8f[_0x25e75c(0x1a3)]?_0x25e75c(0x1a3):_0x25e75c(0x1c9);if(_0x3df3f3)return{'ok':!![],'message':_0x25e75c(0x1df)+_0x490dee+_0x25e75c(0x19d)};return{'ok':!![],'message':_0x25e75c(0x1e0)+_0x490dee+_0x25e75c(0x1a1)};}},{'service':a9_0x23fbd5(0x191),'command':'status','description':a9_0x23fbd5(0x1d0),'risk':a9_0x23fbd5(0x1ac),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[{'name':a9_0x23fbd5(0x1a3),'type':'boolean','description':a9_0x23fbd5(0x1a4),'default':!![]},{'name':a9_0x23fbd5(0x1c9),'type':a9_0x23fbd5(0x1d4),'description':a9_0x23fbd5(0x1da),'default':![]}],async 'execute'(_0x466356){const _0xaea113=a9_0x23fbd5,_0x5cf7a4=resolveAuthScopeFlags(_0x466356),_0x483a23=readScopedConfig(_0x5cf7a4),_0x138649=productEnvName(_0xaea113(0x1c2)),_0x5a932d=productEnv(_0xaea113(0x1c2))||undefined,_0x2d1c31=_0x483a23[_0xaea113(0x192)]||undefined,_0x24121f=_0x5a932d||_0x2d1c31,_0x4592f3=_0x5a932d?_0x138649+_0xaea113(0x1b0):_0x2d1c31?(_0x5cf7a4[_0xaea113(0x1a3)]?_0xaea113(0x1a3):'project')+_0xaea113(0x195):null,_0x2f7b3d=[_0xaea113(0x1a7)+AUTH_MODE[_0xaea113(0x1bd)]];if(_0x24121f){const _0x28f619=_0x24121f['length']>0x8?''+_0x24121f[_0xaea113(0x1ca)](0x0,0x8)+'*'[_0xaea113(0x1b8)](_0x24121f[_0xaea113(0x1c5)]-0x8):_0x24121f;_0x2f7b3d[_0xaea113(0x1c6)](_0xaea113(0x19a)+_0x28f619+(_0x4592f3?_0xaea113(0x1bc)+_0x4592f3+')':''));}return!_0x24121f&&(_0x2f7b3d[_0xaea113(0x1c6)](''),_0x2f7b3d['push'](_0xaea113(0x1bb)),_0x2f7b3d[_0xaea113(0x1c6)](''),_0x2f7b3d[_0xaea113(0x1c6)](_0xaea113(0x1ae)+CLI_BIN_NAME+_0xaea113(0x1ce)),_0x2f7b3d[_0xaea113(0x1c6)](''),_0x2f7b3d['push'](_0xaea113(0x1be)+PRODUCT_CONFIG['newConfigFileName']+')'),_0x2f7b3d[_0xaea113(0x1c6)](_0xaea113(0x1a2)),_0x2f7b3d['push'](''),_0x2f7b3d['push'](_0xaea113(0x1d8)),_0x2f7b3d[_0xaea113(0x1c6)](_0xaea113(0x18d)+_0x138649+_0xaea113(0x1a0)),_0x2f7b3d['push'](''),_0x2f7b3d[_0xaea113(0x1c6)](_0xaea113(0x1ab)+CLI_BIN_NAME+_0xaea113(0x190)),_0x2f7b3d[_0xaea113(0x1c6)]('If\x20command\x20execution\x20still\x20fails,\x20run:\x20'+CLI_BIN_NAME+_0xaea113(0x19c))),{'ok':!![],'message':_0x2f7b3d[_0xaea113(0x1d9)]('\x0a')};}},{'service':a9_0x23fbd5(0x191),'command':a9_0x23fbd5(0x1c0),'description':a9_0x23fbd5(0x199),'risk':a9_0x23fbd5(0x1ac),'requiresAuth':!![],'requiresAppCode':![],'hasFormat':!![],'flags':[],async 'execute'(_0x2602c7){const _0x4ab269=a9_0x23fbd5,_0xd47dc7=await getLoginUserInfo();return{'ok':!![],'data':{'user':_0xd47dc7,'meta':{'env':_0x2602c7[_0x4ab269(0x1c4)]??_0x4ab269(0x1cb)}}};}}];
@@ -1 +1 @@
1
- function a10_0x1cf6(_0x5af2a3,_0x4fe22f){_0x5af2a3=_0x5af2a3-0x68;const _0x526902=a10_0x5269();let _0x1cf6bb=_0x526902[_0x5af2a3];return _0x1cf6bb;}(function(_0x20123f,_0x90bf3e){const _0x121c82=a10_0x1cf6,_0x5e368a=_0x20123f();while(!![]){try{const _0x499aa0=-parseInt(_0x121c82(0x6c))/0x1+parseInt(_0x121c82(0x78))/0x2*(parseInt(_0x121c82(0x7e))/0x3)+-parseInt(_0x121c82(0x68))/0x4+parseInt(_0x121c82(0x70))/0x5*(-parseInt(_0x121c82(0x6a))/0x6)+parseInt(_0x121c82(0x74))/0x7*(parseInt(_0x121c82(0x6b))/0x8)+parseInt(_0x121c82(0x6f))/0x9*(-parseInt(_0x121c82(0x7d))/0xa)+parseInt(_0x121c82(0x76))/0xb;if(_0x499aa0===_0x90bf3e)break;else _0x5e368a['push'](_0x5e368a['shift']());}catch(_0x2be3ea){_0x5e368a['push'](_0x5e368a['shift']());}}}(a10_0x5269,0xd7a26));import{createInterface}from'node:readline';class AbortPrompt extends Error{constructor(){const _0x4dcc04=a10_0x1cf6;super(_0x4dcc04(0x6e)),this['name']=_0x4dcc04(0x73);}}function a10_0x5269(){const _0x59c1be=['race','):\x20','stdout','AccessKey\x20(paste\x20ak_...):\x20','4470rnzRzO','3xuLVlT','question','967000kWRITc','once','4042974Zlpwsy','1209976goAnBp','5357DqYFQL','removeListener','User\x20aborted\x20prompt','15993kthCiD','5THXpEg','stdin','close','AbortPrompt','14LPszWW','AccessKey\x20(','16211140nOUvJz','SIGINT','1644518hsxNPG'];a10_0x5269=function(){return _0x59c1be;};return a10_0x5269();}function createSafeRl(){const _0x162286=a10_0x1cf6,_0x311eca=createInterface({'input':process[_0x162286(0x71)],'output':process[_0x162286(0x7b)]});let _0x2eaabf;const _0x22bf51=new Promise((_0x33771e,_0x139245)=>{const _0x4b1377=_0x162286;_0x2eaabf=()=>{const _0x573677=a10_0x1cf6;_0x2eaabf&&(_0x311eca[_0x573677(0x6d)]('SIGINT',_0x2eaabf),_0x2eaabf=undefined);try{_0x311eca[_0x573677(0x72)]();}catch{}_0x139245(new AbortPrompt());},_0x311eca[_0x4b1377(0x69)](_0x4b1377(0x77),_0x2eaabf);}),_0xf0a348=()=>{const _0x516ef8=_0x162286;_0x2eaabf&&(_0x311eca[_0x516ef8(0x6d)](_0x516ef8(0x77),_0x2eaabf),_0x2eaabf=undefined);try{_0x311eca[_0x516ef8(0x72)]();}catch{}};return{'rl':_0x311eca,'abortPromise':_0x22bf51,'disposeSuccess':_0xf0a348};}export async function promptAccessKey(_0x34d62d=''){const _0x445c63=a10_0x1cf6,{rl:_0x218810,abortPromise:_0x338a3c,disposeSuccess:_0x35b729}=createSafeRl(),_0x36dcf2=new Promise(_0x27cc46=>{const _0x470826=a10_0x1cf6,_0x2494e5=_0x34d62d?_0x470826(0x75)+_0x34d62d+_0x470826(0x7a):_0x470826(0x7c);_0x218810[_0x470826(0x7f)](_0x2494e5,_0x9ffeef=>{_0x35b729(),_0x27cc46(_0x9ffeef['trim']()||_0x34d62d);});});return Promise[_0x445c63(0x79)]([_0x36dcf2,_0x338a3c]);}export function isAbortPrompt(_0x3ca81f){const _0x2bb2aa=a10_0x1cf6;return _0x3ca81f instanceof Error&&_0x3ca81f['name']===_0x2bb2aa(0x73);}
1
+ (function(_0x4f9eba,_0x59765d){const _0x5d970c=a10_0x674f,_0x4a0194=_0x4f9eba();while(!![]){try{const _0x308e54=parseInt(_0x5d970c(0x7f))/0x1*(parseInt(_0x5d970c(0x79))/0x2)+parseInt(_0x5d970c(0x6e))/0x3*(-parseInt(_0x5d970c(0x66))/0x4)+parseInt(_0x5d970c(0x7a))/0x5*(-parseInt(_0x5d970c(0x6a))/0x6)+parseInt(_0x5d970c(0x7c))/0x7+parseInt(_0x5d970c(0x75))/0x8+parseInt(_0x5d970c(0x6d))/0x9*(-parseInt(_0x5d970c(0x67))/0xa)+-parseInt(_0x5d970c(0x69))/0xb*(-parseInt(_0x5d970c(0x7e))/0xc);if(_0x308e54===_0x59765d)break;else _0x4a0194['push'](_0x4a0194['shift']());}catch(_0x2929fa){_0x4a0194['push'](_0x4a0194['shift']());}}}(a10_0x23c4,0x37fb2));import{createInterface}from'node:readline';class AbortPrompt extends Error{constructor(){const _0x2d6b81=a10_0x674f;super(_0x2d6b81(0x73)),this[_0x2d6b81(0x72)]=_0x2d6b81(0x68);}}function createSafeRl(){const _0x55f8bf=a10_0x674f,_0x48306e=createInterface({'input':process[_0x55f8bf(0x78)],'output':process[_0x55f8bf(0x70)]});let _0x5bfbe1;const _0x1c61b=new Promise((_0x422967,_0x1f8071)=>{const _0x59cec8=_0x55f8bf;_0x5bfbe1=()=>{const _0x3f51ce=a10_0x674f;_0x5bfbe1&&(_0x48306e[_0x3f51ce(0x6f)](_0x3f51ce(0x7d),_0x5bfbe1),_0x5bfbe1=undefined);try{_0x48306e['close']();}catch{}_0x1f8071(new AbortPrompt());},_0x48306e[_0x59cec8(0x74)]('SIGINT',_0x5bfbe1);}),_0x5c6c5c=()=>{const _0x24f91e=_0x55f8bf;_0x5bfbe1&&(_0x48306e[_0x24f91e(0x6f)](_0x24f91e(0x7d),_0x5bfbe1),_0x5bfbe1=undefined);try{_0x48306e[_0x24f91e(0x7b)]();}catch{}};return{'rl':_0x48306e,'abortPromise':_0x1c61b,'disposeSuccess':_0x5c6c5c};}export async function promptAccessKey(_0x3b5ba2=''){const _0x1f8c23=a10_0x674f,{rl:_0x204461,abortPromise:_0x5c786e,disposeSuccess:_0x15e9d2}=createSafeRl(),_0x60c5ee=new Promise(_0x54fc8f=>{const _0x209f59=a10_0x674f,_0x1a525b=_0x3b5ba2?_0x209f59(0x6b)+_0x3b5ba2+_0x209f59(0x76):_0x209f59(0x71);_0x204461[_0x209f59(0x65)](_0x1a525b,_0xd4d9af=>{const _0x4b13a6=_0x209f59;_0x15e9d2(),_0x54fc8f(_0xd4d9af[_0x4b13a6(0x6c)]()||_0x3b5ba2);});});return Promise[_0x1f8c23(0x77)]([_0x60c5ee,_0x5c786e]);}function a10_0x674f(_0x11681a,_0x4b8231){_0x11681a=_0x11681a-0x65;const _0x23c445=a10_0x23c4();let _0x674f75=_0x23c445[_0x11681a];return _0x674f75;}export function isAbortPrompt(_0x13637e){const _0x2f17ea=a10_0x674f;return _0x13637e instanceof Error&&_0x13637e[_0x2f17ea(0x72)]===_0x2f17ea(0x68);}function a10_0x23c4(){const _0x434c6e=['276KaqiZv','164158wqOFvV','question','1484668tlDceH','740340tVsUZK','AbortPrompt','124619csXLYs','102IFmzpZ','AccessKey\x20(','trim','18PHIQFz','3oLeCUO','removeListener','stdout','AccessKey\x20(paste\x20ak_...):\x20','name','User\x20aborted\x20prompt','once','2164064kjiafz','):\x20','race','stdin','4QnAjYC','107635wSiYqS','close','1785707UltTPb','SIGINT'];a10_0x23c4=function(){return _0x434c6e;};return a10_0x23c4();}
@@ -1 +1 @@
1
- const a11_0xb447d5=a11_0x10f6;(function(_0x21eefa,_0x5329c5){const _0x286371=a11_0x10f6,_0x494885=_0x21eefa();while(!![]){try{const _0xec0081=-parseInt(_0x286371(0xc0))/0x1*(-parseInt(_0x286371(0xc5))/0x2)+-parseInt(_0x286371(0xcd))/0x3+parseInt(_0x286371(0xc7))/0x4+-parseInt(_0x286371(0xc3))/0x5+parseInt(_0x286371(0xbf))/0x6*(-parseInt(_0x286371(0xca))/0x7)+-parseInt(_0x286371(0xd4))/0x8*(-parseInt(_0x286371(0xce))/0x9)+-parseInt(_0x286371(0xd3))/0xa*(-parseInt(_0x286371(0xc9))/0xb);if(_0xec0081===_0x5329c5)break;else _0x494885['push'](_0x494885['shift']());}catch(_0x41f8e1){_0x494885['push'](_0x494885['shift']());}}}(a11_0x50f7,0x7ab4b));function a11_0x50f7(){const _0x119e49=['2250450Dmfjny','31446BdVkxj','description','updatedTime','appCode','read','10yDYIye','152SMnGSg','5526RHLSxx','37473REshdL','Script\x20ID','bool','2248530epijdy','bff','24SvWtYe','(none)','1090064wzFKqf','detail','11298804kcgEll','861dgNcgS','Get\x20BFF\x20script\x20details\x20by\x20ID','createdTime'];a11_0x50f7=function(){return _0x119e49;};return a11_0x50f7();}import{getBffScriptInfo}from'../../core/api-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';function a11_0x10f6(_0x2363c4,_0x542132){_0x2363c4=_0x2363c4-0xbf;const _0x50f74a=a11_0x50f7();let _0x10f691=_0x50f74a[_0x2363c4];return _0x10f691;}export const bffDetail={'service':a11_0xb447d5(0xc4),'command':a11_0xb447d5(0xc8),'description':a11_0xb447d5(0xcb),'risk':a11_0xb447d5(0xd2),'flags':[{...ID_FLAG,'description':a11_0xb447d5(0xc1)},VERBOSE_FLAG],async 'execute'(_0xce27c7){const _0x43a458=a11_0xb447d5,_0xe9ea66=await getBffScriptInfo(_0xce27c7['num']('id')),_0x4f76b5=_0xce27c7[_0x43a458(0xc2)]('verbose');if(_0x4f76b5)return{'ok':!![],'data':_0xe9ea66};return{'ok':!![],'data':{'id':_0xe9ea66['id'],'appCode':_0xe9ea66[_0x43a458(0xd1)],'functionName':_0xe9ea66['functionName']??'','scriptType':_0xe9ea66['scriptType'],'description':_0xe9ea66[_0x43a458(0xcf)]||_0x43a458(0xc6),'createdTime':_0xe9ea66[_0x43a458(0xcc)]??'','updatedTime':_0xe9ea66[_0x43a458(0xd0)]??''}};}};
1
+ function a11_0x1848(){const _0x2dbb34=['207536HDwowW','num','(none)','scriptType','description','5747038ujPMEz','createdTime','read','bool','bff','134912FJJeCN','119PJFDOx','2MhNmCx','10vpjyMh','Get\x20BFF\x20script\x20details\x20by\x20ID','1123374zyYeSG','979308xfuiYQ','updatedTime','functionName','1263921UlKniX','59177EeazDu','5HfZYXI'];a11_0x1848=function(){return _0x2dbb34;};return a11_0x1848();}const a11_0x1a2248=a11_0x4452;(function(_0x2772d,_0x38201a){const _0x12c228=a11_0x4452,_0x3b4589=_0x2772d();while(!![]){try{const _0x34dee2=-parseInt(_0x12c228(0x13e))/0x1+-parseInt(_0x12c228(0x136))/0x2*(parseInt(_0x12c228(0x13d))/0x3)+-parseInt(_0x12c228(0x134))/0x4+-parseInt(_0x12c228(0x13f))/0x5*(parseInt(_0x12c228(0x139))/0x6)+parseInt(_0x12c228(0x135))/0x7*(parseInt(_0x12c228(0x140))/0x8)+parseInt(_0x12c228(0x13a))/0x9*(parseInt(_0x12c228(0x137))/0xa)+parseInt(_0x12c228(0x145))/0xb;if(_0x34dee2===_0x38201a)break;else _0x3b4589['push'](_0x3b4589['shift']());}catch(_0x1d12ba){_0x3b4589['push'](_0x3b4589['shift']());}}}(a11_0x1848,0x5a89b));function a11_0x4452(_0x30fdc2,_0x5d1e6b){_0x30fdc2=_0x30fdc2-0x132;const _0x18483f=a11_0x1848();let _0x4452cd=_0x18483f[_0x30fdc2];return _0x4452cd;}import{getBffScriptInfo}from'../../core/api-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';export const bffDetail={'service':a11_0x1a2248(0x133),'command':'detail','description':a11_0x1a2248(0x138),'risk':a11_0x1a2248(0x147),'flags':[{...ID_FLAG,'description':'Script\x20ID'},VERBOSE_FLAG],async 'execute'(_0x23782e){const _0x537474=a11_0x1a2248,_0x598bb8=await getBffScriptInfo(_0x23782e[_0x537474(0x141)]('id')),_0x3e159a=_0x23782e[_0x537474(0x132)]('verbose');if(_0x3e159a)return{'ok':!![],'data':_0x598bb8};return{'ok':!![],'data':{'id':_0x598bb8['id'],'appCode':_0x598bb8['appCode'],'functionName':_0x598bb8[_0x537474(0x13c)]??'','scriptType':_0x598bb8[_0x537474(0x143)],'description':_0x598bb8[_0x537474(0x144)]||_0x537474(0x142),'createdTime':_0x598bb8[_0x537474(0x146)]??'','updatedTime':_0x598bb8[_0x537474(0x13b)]??''}};}};
@@ -1 +1 @@
1
- const a12_0x413039=a12_0x496d;function a12_0x496d(_0x545d02,_0x2d57fe){_0x545d02=_0x545d02-0x185;const _0x497819=a12_0x4978();let _0x496df5=_0x497819[_0x545d02];return _0x496df5;}(function(_0x5ca6e4,_0x44ee31){const _0x33e0e1=a12_0x496d,_0xb1005d=_0x5ca6e4();while(!![]){try{const _0x128ceb=parseInt(_0x33e0e1(0x196))/0x1+-parseInt(_0x33e0e1(0x18f))/0x2+-parseInt(_0x33e0e1(0x195))/0x3*(parseInt(_0x33e0e1(0x191))/0x4)+parseInt(_0x33e0e1(0x18e))/0x5*(-parseInt(_0x33e0e1(0x197))/0x6)+-parseInt(_0x33e0e1(0x18c))/0x7+-parseInt(_0x33e0e1(0x190))/0x8*(parseInt(_0x33e0e1(0x18d))/0x9)+parseInt(_0x33e0e1(0x185))/0xa*(parseInt(_0x33e0e1(0x194))/0xb);if(_0x128ceb===_0x44ee31)break;else _0xb1005d['push'](_0xb1005d['shift']());}catch(_0x4477c1){_0xb1005d['push'](_0xb1005d['shift']());}}}(a12_0x4978,0x4044e));import{executeSdkBff}from'../../core/sdk-client.js';import{parseJsonParams}from'../../utils/params.js';import{NAME_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';export const bffExec={'service':a12_0x413039(0x187),'command':a12_0x413039(0x193),'description':a12_0x413039(0x186),'risk':'read','flags':[{...NAME_FLAG,'required':!![],'description':a12_0x413039(0x18a)},PARAMS_FLAG],async 'execute'(_0x5d67b8){const _0xa83af=a12_0x413039,_0x466252=parseJsonParams(_0x5d67b8[_0xa83af(0x18b)]('params')),_0x3c57c6=Date[_0xa83af(0x189)](),_0x33ee9b=await executeSdkBff(_0x5d67b8[_0xa83af(0x18b)](_0xa83af(0x188)),_0x466252),_0x21bd61=Date['now']()-_0x3c57c6;return{'ok':!![],'data':{'result':_0x33ee9b,'elapsed':_0x21bd61},'message':_0xa83af(0x192)+_0x21bd61+'ms'};}};function a12_0x4978(){const _0x320641=['1056678RijPzE','10KVHqsf','Execute\x20a\x20BFF\x20script\x20by\x20function\x20name','bff','name','now','BFF\x20function\x20name\x20to\x20execute','str','1138809yPepEG','9nODqBw','10HIqzfH','877944zpxGQg','3540512RlmLdy','44lmaCdK','BFF\x20executed\x20in\x20','exec','19216681fhSwEu','24333kgCzju','1945ssMmoH'];a12_0x4978=function(){return _0x320641;};return a12_0x4978();}
1
+ const a12_0x2dbb1a=a12_0x2214;function a12_0x2214(_0x4e66c3,_0xa9c13){_0x4e66c3=_0x4e66c3-0x169;const _0xb33e66=a12_0xb33e();let _0x221446=_0xb33e66[_0x4e66c3];return _0x221446;}(function(_0x47125f,_0x1f3c46){const _0x22e1da=a12_0x2214,_0xc5fb69=_0x47125f();while(!![]){try{const _0x2b9a58=-parseInt(_0x22e1da(0x16b))/0x1+-parseInt(_0x22e1da(0x172))/0x2+parseInt(_0x22e1da(0x175))/0x3+parseInt(_0x22e1da(0x16a))/0x4*(-parseInt(_0x22e1da(0x170))/0x5)+-parseInt(_0x22e1da(0x17a))/0x6+parseInt(_0x22e1da(0x177))/0x7+parseInt(_0x22e1da(0x16d))/0x8*(parseInt(_0x22e1da(0x16e))/0x9);if(_0x2b9a58===_0x1f3c46)break;else _0xc5fb69['push'](_0xc5fb69['shift']());}catch(_0x5a12b2){_0xc5fb69['push'](_0xc5fb69['shift']());}}}(a12_0xb33e,0xaadca));import{executeSdkBff}from'../../core/sdk-client.js';import{parseJsonParams}from'../../utils/params.js';import{NAME_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';export const bffExec={'service':a12_0x2dbb1a(0x171),'command':a12_0x2dbb1a(0x178),'description':'Execute\x20a\x20BFF\x20script\x20by\x20function\x20name','risk':a12_0x2dbb1a(0x176),'flags':[{...NAME_FLAG,'required':!![],'description':a12_0x2dbb1a(0x173)},PARAMS_FLAG],async 'execute'(_0x3b45af){const _0xb4e2b5=a12_0x2dbb1a,_0x10ecca=parseJsonParams(_0x3b45af[_0xb4e2b5(0x174)](_0xb4e2b5(0x16c))),_0x6ad336=Date[_0xb4e2b5(0x179)](),_0xc4c958=await executeSdkBff(_0x3b45af[_0xb4e2b5(0x174)](_0xb4e2b5(0x16f)),_0x10ecca),_0x15585a=Date['now']()-_0x6ad336;return{'ok':!![],'data':{'result':_0xc4c958,'elapsed':_0x15585a},'message':_0xb4e2b5(0x169)+_0x15585a+'ms'};}};function a12_0xb33e(){const _0x342df7=['params','14577776COMKpk','9QNeDre','name','265dmhumc','bff','1332190pNnFKg','BFF\x20function\x20name\x20to\x20execute','str','2127945AoEgUJ','read','167909baDOsq','exec','now','1322736vFyhXZ','BFF\x20executed\x20in\x20','39188cqtJAp','449882SiCGAQ'];a12_0xb33e=function(){return _0x342df7;};return a12_0xb33e();}
@@ -1 +1 @@
1
- function a13_0x8655(_0x4a148d,_0x2f737a){_0x4a148d=_0x4a148d-0x6e;const _0x4f9202=a13_0x4f92();let _0x86555c=_0x4f9202[_0x4a148d];return _0x86555c;}function a13_0x4f92(){const _0x88014a=['653766zaZxEf','6839693pcHPix','838625AknfuZ','128lppHlK','1709878iSwsKq','43167gZSOGY','11961144ttHxGu','5163765SlchGy'];a13_0x4f92=function(){return _0x88014a;};return a13_0x4f92();}(function(_0x461a38,_0x525cb1){const _0x2ec372=a13_0x8655,_0x46ff68=_0x461a38();while(!![]){try{const _0x7e14fa=parseInt(_0x2ec372(0x75))/0x1+parseInt(_0x2ec372(0x6f))/0x2+-parseInt(_0x2ec372(0x70))/0x3*(-parseInt(_0x2ec372(0x6e))/0x4)+parseInt(_0x2ec372(0x72))/0x5+-parseInt(_0x2ec372(0x73))/0x6+-parseInt(_0x2ec372(0x74))/0x7+-parseInt(_0x2ec372(0x71))/0x8;if(_0x7e14fa===_0x525cb1)break;else _0x46ff68['push'](_0x46ff68['shift']());}catch(_0x564af6){_0x46ff68['push'](_0x46ff68['shift']());}}}(a13_0x4f92,0x93d7a));import{bffDetail}from'../../commands/bff/detail.js';import{bffExec}from'../../commands/bff/exec.js';export const bffDefinitions=[bffDetail,bffExec];
1
+ function a13_0x462c(){const _0x391ba0=['65iexxPx','261010IgvKTc','832257oKdVtx','39174KsUtqU','426664hLGcIJ','258482uAJyne','18AqBPlP','2402PkhZrS','684frjeOe','92856YrWLVB'];a13_0x462c=function(){return _0x391ba0;};return a13_0x462c();}function a13_0x5681(_0x2d84ba,_0x343286){_0x2d84ba=_0x2d84ba-0x9a;const _0x462c99=a13_0x462c();let _0x56817b=_0x462c99[_0x2d84ba];return _0x56817b;}(function(_0xb05dec,_0x48c519){const _0x5a3dd2=a13_0x5681,_0x3fb6fb=_0xb05dec();while(!![]){try{const _0x49c1e9=parseInt(_0x5a3dd2(0x9a))/0x1+parseInt(_0x5a3dd2(0x9e))/0x2*(-parseInt(_0x5a3dd2(0x9f))/0x3)+-parseInt(_0x5a3dd2(0xa0))/0x4*(-parseInt(_0x5a3dd2(0xa1))/0x5)+-parseInt(_0x5a3dd2(0x9d))/0x6*(-parseInt(_0x5a3dd2(0x9c))/0x7)+parseInt(_0x5a3dd2(0x9b))/0x8+-parseInt(_0x5a3dd2(0xa3))/0x9+parseInt(_0x5a3dd2(0xa2))/0xa;if(_0x49c1e9===_0x48c519)break;else _0x3fb6fb['push'](_0x3fb6fb['shift']());}catch(_0x34d2af){_0x3fb6fb['push'](_0x3fb6fb['shift']());}}}(a13_0x462c,0x28403));import{bffDetail}from'../../commands/bff/detail.js';import{bffExec}from'../../commands/bff/exec.js';export const bffDefinitions=[bffDetail,bffExec];
@@ -1 +1 @@
1
- const a14_0x2e0b8a=a14_0x10a5;function a14_0x10a5(_0x366a5b,_0x3de6fd){_0x366a5b=_0x366a5b-0xd2;const _0x4e1a21=a14_0x4e1a();let _0x10a5d0=_0x4e1a21[_0x366a5b];return _0x10a5d0;}function a14_0x4e1a(){const _0x3a5b29=['cli-skill-install','115932LxKxoe','4yylAqA','setLogPath','inherit','388592OPNTuA','1514949kZjPmU','Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx\x20(npx\x20skills\x20add\x20','install','32kiyBJi','info','write','Install\x20the\x20CLI\x20Built-in\x20Skill\x20required\x20by\x20Lovrabet\x20runtime','4893084vPWoQA','59784xjNzaL','11Nuwrfe','109895bZabaT','pipe','log','Skipped\x20npx\x20(','cwd','117aBWdFT','npx\x20skills\x20add\x20failed:\x20','Check\x20network\x20connectivity\x20and\x20try\x20again,\x20or\x20run:\x20npx\x20skills\x20add\x20','Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx.','skipped','../../skills/npx-skills-add.js','\x20-g\x20-y','7284230troByV','unknown','apiError','cli-skill'];a14_0x4e1a=function(){return _0x3a5b29;};return a14_0x4e1a();}(function(_0x1baac6,_0x11b59d){const _0x538e38=a14_0x10a5,_0x36cf83=_0x1baac6();while(!![]){try{const _0x201f15=parseInt(_0x538e38(0xd5))/0x1*(parseInt(_0x538e38(0xd8))/0x2)+-parseInt(_0x538e38(0xd9))/0x3+parseInt(_0x538e38(0xdc))/0x4*(parseInt(_0x538e38(0xe3))/0x5)+parseInt(_0x538e38(0xd4))/0x6+-parseInt(_0x538e38(0xe0))/0x7+-parseInt(_0x538e38(0xe1))/0x8*(parseInt(_0x538e38(0xe8))/0x9)+-parseInt(_0x538e38(0xef))/0xa*(-parseInt(_0x538e38(0xe2))/0xb);if(_0x201f15===_0x11b59d)break;else _0x36cf83['push'](_0x36cf83['shift']());}catch(_0x56524f){_0x36cf83['push'](_0x36cf83['shift']());}}}(a14_0x4e1a,0x61901));import{CliErrors}from'../../errors.js';import{logger}from'../../utils/logger.js';export const cliSkillDefinitions=[{'service':a14_0x2e0b8a(0xd2),'command':a14_0x2e0b8a(0xdb),'description':a14_0x2e0b8a(0xdf),'risk':a14_0x2e0b8a(0xde),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0xe7aa37){const _0x5e2932=a14_0x2e0b8a;logger[_0x5e2932(0xd6)](process[_0x5e2932(0xe7)]()),logger[_0x5e2932(0xdd)](_0x5e2932(0xd3),_0x5e2932(0xeb));const {LOVRABET_SKILL_SOURCE:_0x36ccbc,LOVRABET_SKIP_NPX_SKILLS_ENV:_0x2a73d4,runNpxSkillsAddGlobal:_0x535210}=await import(_0x5e2932(0xed)),_0x4e72a8=_0xe7aa37['nonInteractive']?_0x5e2932(0xe4):_0x5e2932(0xd7);console[_0x5e2932(0xe5)](_0x5e2932(0xda)+_0x36ccbc+'\x20-g\x20-y)...');const _0x32b813=_0x535210(process[_0x5e2932(0xe7)](),_0x36ccbc,{'stdio':_0x4e72a8});if(_0x32b813[_0x5e2932(0xec)])console[_0x5e2932(0xe5)](_0x5e2932(0xe6)+_0x2a73d4+'=1);\x20assuming\x20CLI\x20Built-in\x20Skill\x20is\x20already\x20present.');else{if(_0x32b813['ok'])console[_0x5e2932(0xe5)]('CLI\x20Built-in\x20Skill\x20installed');else throw CliErrors[_0x5e2932(0xf1)](_0x5e2932(0xe9)+(_0x32b813['error']||_0x5e2932(0xf0)),_0x5e2932(0xea)+_0x36ccbc+_0x5e2932(0xee));}return{'ok':!![]};}}];
1
+ const a14_0x4ccd96=a14_0x246f;(function(_0x184510,_0x343cb5){const _0x46556a=a14_0x246f,_0x3f7dd9=_0x184510();while(!![]){try{const _0x17e376=-parseInt(_0x46556a(0x120))/0x1+parseInt(_0x46556a(0x12d))/0x2*(-parseInt(_0x46556a(0x11f))/0x3)+-parseInt(_0x46556a(0x11c))/0x4*(parseInt(_0x46556a(0x118))/0x5)+parseInt(_0x46556a(0x127))/0x6*(parseInt(_0x46556a(0x12e))/0x7)+parseInt(_0x46556a(0x117))/0x8+-parseInt(_0x46556a(0x11d))/0x9+-parseInt(_0x46556a(0x12c))/0xa*(-parseInt(_0x46556a(0x11b))/0xb);if(_0x17e376===_0x343cb5)break;else _0x3f7dd9['push'](_0x3f7dd9['shift']());}catch(_0x1340d3){_0x3f7dd9['push'](_0x3f7dd9['shift']());}}}(a14_0x2525,0x2ba44));import{CliErrors}from'../../errors.js';function a14_0x246f(_0x5595d4,_0x4491f9){_0x5595d4=_0x5595d4-0x117;const _0x252526=a14_0x2525();let _0x246fd7=_0x252526[_0x5595d4];return _0x246fd7;}import{logger}from'../../utils/logger.js';function a14_0x2525(){const _0x500fcc=['npx\x20skills\x20add\x20failed:\x20','Install\x20the\x20CLI\x20Built-in\x20Skill\x20required\x20by\x20Lovrabet\x20runtime','=1);\x20assuming\x20CLI\x20Built-in\x20Skill\x20is\x20already\x20present.','unknown','cli-skill-install','608576nsCFEq','298685TEAoQM','skipped','setLogPath','418WulkBq','20KajXUA','2762784lCCQCS','nonInteractive','422283IBAoby','266494aSnBgu','../../skills/npx-skills-add.js','\x20-g\x20-y','install','inherit','Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx.','write','5418AtAIxW','CLI\x20Built-in\x20Skill\x20installed','Skipped\x20npx\x20(','cwd','Installing\x20CLI\x20Built-in\x20Skill\x20via\x20npx\x20(npx\x20skills\x20add\x20','287610BCVxFm','4dYSeHf','1267IkIuJc','log'];a14_0x2525=function(){return _0x500fcc;};return a14_0x2525();}export const cliSkillDefinitions=[{'service':'cli-skill','command':a14_0x4ccd96(0x123),'description':a14_0x4ccd96(0x131),'risk':a14_0x4ccd96(0x126),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x48d33b){const _0x3f8e40=a14_0x4ccd96;logger[_0x3f8e40(0x11a)](process[_0x3f8e40(0x12a)]()),logger['info'](_0x3f8e40(0x134),_0x3f8e40(0x125));const {LOVRABET_SKILL_SOURCE:_0x5b7d57,LOVRABET_SKIP_NPX_SKILLS_ENV:_0x3ca4a5,runNpxSkillsAddGlobal:_0x48135e}=await import(_0x3f8e40(0x121)),_0x26b680=_0x48d33b[_0x3f8e40(0x11e)]?'pipe':_0x3f8e40(0x124);console[_0x3f8e40(0x12f)](_0x3f8e40(0x12b)+_0x5b7d57+'\x20-g\x20-y)...');const _0x416bc3=_0x48135e(process[_0x3f8e40(0x12a)](),_0x5b7d57,{'stdio':_0x26b680});if(_0x416bc3[_0x3f8e40(0x119)])console[_0x3f8e40(0x12f)](_0x3f8e40(0x129)+_0x3ca4a5+_0x3f8e40(0x132));else{if(_0x416bc3['ok'])console[_0x3f8e40(0x12f)](_0x3f8e40(0x128));else throw CliErrors['apiError'](_0x3f8e40(0x130)+(_0x416bc3['error']||_0x3f8e40(0x133)),'Check\x20network\x20connectivity\x20and\x20try\x20again,\x20or\x20run:\x20npx\x20skills\x20add\x20'+_0x5b7d57+_0x3f8e40(0x122));}return{'ok':!![]};}}];