@lovrabet/lovrabet-cli 2.3.0 → 2.3.1-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 (178) 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/app-config/get.js +1 -1
  10. package/lib/commands/app-config/index.js +1 -1
  11. package/lib/commands/artifact/index.js +1 -1
  12. package/lib/commands/auth/device.js +1 -1
  13. package/lib/commands/auth/index.js +1 -1
  14. package/lib/commands/auth/prompt.js +1 -1
  15. package/lib/commands/bff/detail.js +1 -1
  16. package/lib/commands/bff/exec.js +1 -1
  17. package/lib/commands/bff/index.js +1 -1
  18. package/lib/commands/cli-skill/index.js +1 -1
  19. package/lib/commands/common/config-policy.js +1 -1
  20. package/lib/commands/common/constraints.js +1 -1
  21. package/lib/commands/common/flags.js +1 -1
  22. package/lib/commands/common/local-file.js +1 -1
  23. package/lib/commands/config/definitions.js +1 -1
  24. package/lib/commands/config/init.d.ts +1 -1
  25. package/lib/commands/config/init.js +1 -1
  26. package/lib/commands/config/shared.js +1 -1
  27. package/lib/commands/data/index.js +1 -1
  28. package/lib/commands/dataset/detail.js +1 -1
  29. package/lib/commands/dataset/index.js +1 -1
  30. package/lib/commands/dataset/list.js +1 -1
  31. package/lib/commands/dataset/sdk-doc.js +1 -1
  32. package/lib/commands/doctor.js +1 -1
  33. package/lib/commands/file/index.js +1 -1
  34. package/lib/commands/init.js +1 -1
  35. package/lib/commands/kb/index.js +1 -1
  36. package/lib/commands/logs/index.js +1 -1
  37. package/lib/commands/notification/config-list.js +1 -1
  38. package/lib/commands/notification/index.js +1 -1
  39. package/lib/commands/notification/shared.js +1 -1
  40. package/lib/commands/ocr/index.js +1 -1
  41. package/lib/commands/permit/dataset-get.js +1 -1
  42. package/lib/commands/permit/dataset-set.js +1 -1
  43. package/lib/commands/permit/index.js +1 -1
  44. package/lib/commands/permit/page-get.js +1 -1
  45. package/lib/commands/permit/page-set.js +1 -1
  46. package/lib/commands/permit/role-menus-set.js +1 -1
  47. package/lib/commands/permit/role-menus.js +1 -1
  48. package/lib/commands/permit/shared.js +1 -1
  49. package/lib/commands/personal-bff/index.js +1 -1
  50. package/lib/commands/registry.js +1 -1
  51. package/lib/commands/role/create.js +1 -1
  52. package/lib/commands/role/delete.js +1 -1
  53. package/lib/commands/role/detail.js +1 -1
  54. package/lib/commands/role/index.js +1 -1
  55. package/lib/commands/role/list.js +1 -1
  56. package/lib/commands/role/shared.js +1 -1
  57. package/lib/commands/role/update.js +1 -1
  58. package/lib/commands/role/user-add.js +1 -1
  59. package/lib/commands/role/user-remove.js +1 -1
  60. package/lib/commands/schedule/index.js +1 -1
  61. package/lib/commands/schema.js +1 -1
  62. package/lib/commands/service/dynamic.js +1 -1
  63. package/lib/commands/service/function-name-adapter.js +1 -1
  64. package/lib/commands/service/index.js +1 -1
  65. package/lib/commands/service/registry.js +1 -1
  66. package/lib/commands/skill/commands/create.js +1 -1
  67. package/lib/commands/skill/commands/diagram.js +1 -1
  68. package/lib/commands/skill/commands/install.js +1 -1
  69. package/lib/commands/skill/commands/list.js +1 -1
  70. package/lib/commands/skill/commands/push.js +1 -1
  71. package/lib/commands/skill/commands/validate.js +1 -1
  72. package/lib/commands/skill/diagram.js +1 -1
  73. package/lib/commands/skill/flags.js +1 -1
  74. package/lib/commands/skill/index.js +1 -1
  75. package/lib/commands/skill/manifest-helpers.js +1 -1
  76. package/lib/commands/skill/push-execute.js +1 -1
  77. package/lib/commands/skill/push-flow-helpers.js +1 -1
  78. package/lib/commands/skill/push-retarget.js +1 -1
  79. package/lib/commands/skill/scopes.js +1 -1
  80. package/lib/commands/skill/summary.js +1 -1
  81. package/lib/commands/skill/templates.js +1 -1
  82. package/lib/commands/skill/validate.js +1 -1
  83. package/lib/commands/sql/detail.js +1 -1
  84. package/lib/commands/sql/exec.js +1 -1
  85. package/lib/commands/sql/index.js +1 -1
  86. package/lib/commands/update.js +1 -1
  87. package/lib/commands/user-account/bind.js +1 -1
  88. package/lib/commands/user-account/index.js +1 -1
  89. package/lib/commands/workspace/index.js +1 -1
  90. package/lib/config/domain-config.d.ts +1 -1
  91. package/lib/config/domain-config.js +1 -1
  92. package/lib/config/schema.d.ts +1 -1
  93. package/lib/config/schema.js +1 -1
  94. package/lib/constant/app.js +1 -1
  95. package/lib/constant/auth-mode.js +1 -1
  96. package/lib/constant/cli.js +1 -1
  97. package/lib/constant/defaults.js +1 -1
  98. package/lib/constant/distribution.js +1 -1
  99. package/lib/constant/domain.d.ts +6 -3
  100. package/lib/constant/domain.js +1 -1
  101. package/lib/constant/env.js +1 -1
  102. package/lib/constant/output.js +1 -1
  103. package/lib/constant/product.js +1 -1
  104. package/lib/constant/region.js +1 -1
  105. package/lib/constant/risk.js +1 -1
  106. package/lib/constant/url.js +1 -1
  107. package/lib/context.js +1 -1
  108. package/lib/core/api-client.d.ts +0 -16
  109. package/lib/core/api-client.js +1 -1
  110. package/lib/core/db-resolver.js +1 -1
  111. package/lib/core/kb-search-client.d.ts +30 -0
  112. package/lib/core/kb-search-client.js +1 -0
  113. package/lib/core/sdk-client.js +1 -1
  114. package/lib/errors.js +1 -1
  115. package/lib/framework/build-all-flags.js +1 -1
  116. package/lib/framework/dryrun.js +1 -1
  117. package/lib/framework/flags.js +1 -1
  118. package/lib/framework/help.js +1 -1
  119. package/lib/framework/index.js +1 -1
  120. package/lib/framework/output.js +1 -1
  121. package/lib/framework/preparse.js +1 -1
  122. package/lib/framework/rate-limit.js +1 -1
  123. package/lib/framework/raw-flags.js +1 -1
  124. package/lib/framework/response.js +1 -1
  125. package/lib/framework/runner-confirmation.js +1 -1
  126. package/lib/framework/runner-error.js +1 -1
  127. package/lib/framework/runner.js +1 -1
  128. package/lib/framework/schema-export.js +1 -1
  129. package/lib/framework/service-order.js +1 -1
  130. package/lib/framework/types.d.ts +2 -0
  131. package/lib/framework/types.js +1 -1
  132. package/lib/generated/build-info.d.ts +4 -4
  133. package/lib/generated/build-info.js +1 -1
  134. package/lib/help.js +1 -1
  135. package/lib/postinstall.js +1 -1
  136. package/lib/runtime/confirmation.js +1 -1
  137. package/lib/runtime/event.js +1 -1
  138. package/lib/runtime/index.js +1 -1
  139. package/lib/runtime/queue.js +1 -1
  140. package/lib/runtime/resolve.js +1 -1
  141. package/lib/skills/builtin-skill.js +1 -1
  142. package/lib/skills/npx-skills-add.js +1 -1
  143. package/lib/skills/runtime-skill-sync/constants.js +1 -1
  144. package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
  145. package/lib/skills/runtime-skill-sync/hashing.js +1 -1
  146. package/lib/skills/runtime-skill-sync/install-target.js +1 -1
  147. package/lib/skills/runtime-skill-sync/links.js +1 -1
  148. package/lib/skills/runtime-skill-sync/list-local.js +1 -1
  149. package/lib/skills/runtime-skill-sync/local-files.js +1 -1
  150. package/lib/skills/runtime-skill-sync/materialize.js +1 -1
  151. package/lib/skills/runtime-skill-sync/metadata.js +1 -1
  152. package/lib/skills/runtime-skill-sync/paths.js +1 -1
  153. package/lib/skills/runtime-skill-sync/push.js +1 -1
  154. package/lib/skills/runtime-skill-sync/scopes.js +1 -1
  155. package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
  156. package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
  157. package/lib/skills/runtime-skill-sync.js +1 -1
  158. package/lib/skills/skill-presence.js +1 -1
  159. package/lib/utils/access-key-redaction.js +1 -1
  160. package/lib/utils/apply-jq-filter.js +1 -1
  161. package/lib/utils/cli-version-check.js +1 -1
  162. package/lib/utils/cli-version-policy.js +1 -1
  163. package/lib/utils/logger.js +1 -1
  164. package/lib/utils/lossless-json.js +1 -1
  165. package/lib/utils/params.js +1 -1
  166. package/lib/utils/platform.js +1 -1
  167. package/lib/utils/update-notice.js +1 -1
  168. package/lib/utils/version.js +1 -1
  169. package/lib/utils/write-cli-side-channel.js +1 -1
  170. package/package.json +1 -1
  171. package/skills/lovrabet/SKILL.md +3 -2
  172. package/skills/lovrabet/guides/sql-and-bff-workflow.md +1 -1
  173. package/skills/lovrabet/references/lovrabet-config-commands.md +7 -6
  174. package/skills/lovrabet/references/lovrabet-config.md +9 -8
  175. package/skills/lovrabet/references/lovrabet-doctor.md +2 -0
  176. package/skills/lovrabet/references/lovrabet-kb-workflow.md +3 -1
  177. package/skills/lovrabet/references/lovrabet-personal-bff-workflow.md +32 -0
  178. package/skills/lovrabet.manifest.json +3 -3
@@ -1 +1 @@
1
- const a26_0x5783a0=a26_0x2add;(function(_0x4a1b1c,_0x565030){const _0x54aab8=a26_0x2add,_0x36cfb4=_0x4a1b1c();while(!![]){try{const _0xc907e7=parseInt(_0x54aab8(0xc2))/0x1+-parseInt(_0x54aab8(0x89))/0x2*(parseInt(_0x54aab8(0x9f))/0x3)+-parseInt(_0x54aab8(0xc1))/0x4+-parseInt(_0x54aab8(0x91))/0x5*(parseInt(_0x54aab8(0x93))/0x6)+parseInt(_0x54aab8(0xb9))/0x7+parseInt(_0x54aab8(0xbc))/0x8+parseInt(_0x54aab8(0xad))/0x9*(parseInt(_0x54aab8(0xcf))/0xa);if(_0xc907e7===_0x565030)break;else _0x36cfb4['push'](_0x36cfb4['shift']());}catch(_0x2e1555){_0x36cfb4['push'](_0x36cfb4['shift']());}}}(a26_0x2f54,0x54e55));import{getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';function a26_0x2add(_0x528644,_0x3b0aac){_0x528644=_0x528644-0x87;const _0x2f5440=a26_0x2f54();let _0x2addf3=_0x2f5440[_0x528644];return _0x2addf3;}function normalizeField(_0x3e43c9){const _0x49d766=a26_0x2add;if(_0x3e43c9['deleted'])return null;const _0x556e47=Boolean(_0x3e43c9[_0x49d766(0xb2)]!==undefined||_0x3e43c9['doType']!==undefined);let _0x5c7739={};if(!_0x556e47&&typeof _0x3e43c9[_0x49d766(0x87)]===_0x49d766(0x8f))try{_0x5c7739=JSON[_0x49d766(0x94)](_0x3e43c9[_0x49d766(0x87)]);}catch{}const _0x241e52=_0x556e47?_0x3e43c9[_0x49d766(0xb7)]:_0x3e43c9[_0x49d766(0xc5)],_0x5414cb=_0x556e47?_0x3e43c9[_0x49d766(0xb2)]:_0x3e43c9['name'],_0x378cef=_0x556e47?_0x3e43c9[_0x49d766(0xcb)]:_0x3e43c9[_0x49d766(0xc8)]||_0x3e43c9[_0x49d766(0x9a)],_0x2309f5=_0x556e47?_0x3e43c9[_0x49d766(0xa6)]===!![]:_0x5c7739[_0x49d766(0xa6)]===!![],_0x50de22=_0x556e47?_0x3e43c9[_0x49d766(0xbb)]===!![]:_0x5c7739[_0x49d766(0xbb)]===!![],_0x31e71b=_0x556e47?_0x3e43c9[_0x49d766(0xc6)]??null:_0x5c7739[_0x49d766(0xc6)]??null,_0x2443f7={'name':_0x241e52,'displayName':_0x5414cb||_0x241e52,'type':_0x378cef,'dbType':_0x3e43c9[_0x49d766(0xa4)],'pk':_0x2309f5,'required':_0x50de22,'description':_0x3e43c9[_0x49d766(0xd2)]||undefined};return Array[_0x49d766(0x88)](_0x31e71b)&&_0x31e71b[_0x49d766(0xa3)]>0x0&&(_0x2443f7[_0x49d766(0xc6)]=_0x31e71b),_0x2443f7;}function parseJsonMaybe(_0x1b7922){const _0xb8c8c5=a26_0x2add;if(typeof _0x1b7922!==_0xb8c8c5(0x8f))return _0x1b7922;try{return JSON['parse'](_0x1b7922);}catch{return _0x1b7922;}}function normalizeOperationEntry(_0x1405f6,_0x11f760){const _0x45232c=a26_0x2add;if(!_0x11f760||typeof _0x11f760!==_0x45232c(0xc7))return null;if(!_0x11f760[_0x45232c(0xab)]||!_0x11f760[_0x45232c(0x8a)])return null;const _0x12a9f8={'name':_0x1405f6,'method':_0x11f760['method'],'path':_0x11f760[_0x45232c(0x8a)]};if(_0x11f760[_0x45232c(0x97)])_0x12a9f8['host']=_0x11f760[_0x45232c(0x97)];if(_0x11f760[_0x45232c(0xb5)]!=null)_0x12a9f8[_0x45232c(0xb5)]=parseJsonMaybe(_0x11f760[_0x45232c(0xb5)]);if(_0x11f760[_0x45232c(0x9e)]!=null)_0x12a9f8[_0x45232c(0x9e)]=parseJsonMaybe(_0x11f760[_0x45232c(0x9e)]);if(_0x11f760['beforeScriptId']!=null)_0x12a9f8['beforeScriptId']=_0x11f760[_0x45232c(0xa8)];if(_0x11f760[_0x45232c(0x9d)]!=null)_0x12a9f8[_0x45232c(0x9d)]=_0x11f760[_0x45232c(0x9d)];if(Array[_0x45232c(0x88)](_0x11f760[_0x45232c(0xc9)]))_0x12a9f8[_0x45232c(0xc9)]=_0x11f760['requestFields'];if(Array['isArray'](_0x11f760[_0x45232c(0xd6)]))_0x12a9f8[_0x45232c(0xd6)]=_0x11f760[_0x45232c(0xd6)];return _0x12a9f8;}function summarizeDbtable(_0x341f2b){const _0x4145b4=a26_0x2add,_0x5607af={},_0x57e20c=[_0x4145b4(0xb6),'dbName',_0x4145b4(0x96),_0x4145b4(0xbd),_0x4145b4(0xa6),_0x4145b4(0x90),_0x4145b4(0xa5),_0x4145b4(0xd1),_0x4145b4(0xca),'creatorIdField',_0x4145b4(0xa7),_0x4145b4(0x9b),_0x4145b4(0x8b),_0x4145b4(0xb8),_0x4145b4(0x9c)];for(const _0x2bcf70 of _0x57e20c){if(_0x341f2b[_0x2bcf70]!==undefined)_0x5607af[_0x2bcf70]=_0x341f2b[_0x2bcf70];}return typeof _0x5607af['allFields']===_0x4145b4(0x8f)&&_0x5607af['allFields'][_0x4145b4(0xa3)]>0x0&&(_0x5607af[_0x4145b4(0xb1)]=_0x5607af[_0x4145b4(0x90)][_0x4145b4(0xc4)](',')[_0x4145b4(0xa2)](_0xfef2ae=>_0xfef2ae['trim']())[_0x4145b4(0xaa)](Boolean)),_0x5607af;}function normalizeRelatedPages(_0x2d9c20){const _0x2b83bf=a26_0x2add;if(!Array[_0x2b83bf(0x88)](_0x2d9c20))return[];return _0x2d9c20['filter'](_0x1d881e=>_0x1d881e&&typeof _0x1d881e===_0x2b83bf(0xc7))[_0x2b83bf(0xa2)](_0x45c645=>({'id':_0x45c645['id'],'type':_0x45c645[_0x2b83bf(0xc8)],'code':_0x45c645[_0x2b83bf(0xc5)],'title':_0x45c645[_0x2b83bf(0xb4)],'deleted':_0x45c645[_0x2b83bf(0x95)]===!![]}));}function a26_0x2f54(){const _0x1fcb6c=['responseBody','217599nUcPFP','dbName','Get\x20dataset\x20detail\x20including\x20fields,\x20relations,\x20and\x20operations','map','length','dbType','logicField','pkField','creatorNameField','beforeScriptId','properties','filter','method','operations','34047fJskts','fields','sourceType','push','allFieldNames','displayName','relatedPageInfoList','title','requestBody','dbId','name','labelField','482769CzBmle','doVersion','required','45664IAzJCY','datasetKey','dbtableConfig','relations','appCode','872692CTiMHI','448654JRtplG','entries','split','code','options','object','type','requestFields','updateTimeField','doType','source','indexes','trim','2530JEbPBn','detail','createTimeField','description','columnCodeListWithDeleted','read','formatRules','responseFields','extend','isArray','10GshGct','path','modifierNameField','str','validateRules','dataset','string','allFields','895GoWYqv','modelCode','18498lsJqNn','parse','deleted','tableName','host','find','tableComment','dataType','modifierIdField','dblinkInfoDTO','afterScriptId'];a26_0x2f54=function(){return _0x1fcb6c;};return a26_0x2f54();}function normalizeFallbackFieldName(_0x403183,_0x4187ab){const _0x477096=a26_0x2add,_0x1009c6=_0x403183[_0x477096(0xce)]();if(!_0x1009c6)return null;return{'name':_0x1009c6,'displayName':_0x1009c6,'type':undefined,'dbType':undefined,'pk':_0x1009c6===_0x4187ab,'required':![],'description':undefined};}async function loadListFieldFallback(_0x279784,_0x291d60){const _0xe0567a=a26_0x2add;if(!_0x279784||!_0x291d60)return[];try{const _0x1f5073=await listDatasets(_0x279784,{'code':_0x291d60}),_0x98ea16=_0x1f5073[_0xe0567a(0x98)](_0x5b1833=>_0x5b1833[_0xe0567a(0xc5)]===_0x291d60)??_0x1f5073[0x0],_0x4b54c1=_0x98ea16?.[_0xe0567a(0xbe)]??{},_0x50cbd9=typeof _0x4b54c1[_0xe0567a(0x90)]==='string'?_0x4b54c1['allFields'][_0xe0567a(0xc4)](','):[];return _0x50cbd9[_0xe0567a(0xa2)](_0x2f7759=>normalizeFallbackFieldName(_0x2f7759,_0x4b54c1['pkField']))[_0xe0567a(0xaa)](_0x3a1c1f=>_0x3a1c1f!==null);}catch{return[];}}export const datasetDetail={'service':a26_0x5783a0(0x8e),'command':a26_0x5783a0(0xd0),'description':a26_0x5783a0(0xa1),'risk':a26_0x5783a0(0xd4),'flags':[CODE_FLAG],async 'execute'(_0x7d97ff){const _0x3e6d48=a26_0x5783a0,_0xfc9ce5=await getDatasetDetail(_0x7d97ff[_0x3e6d48(0x8c)](_0x3e6d48(0xc5))),_0xd35303=Array[_0x3e6d48(0x88)](_0xfc9ce5[_0x3e6d48(0xae)])?_0xfc9ce5['fields']:Array[_0x3e6d48(0x88)](_0xfc9ce5[_0x3e6d48(0xa9)])?_0xfc9ce5[_0x3e6d48(0xa9)]:[];let _0x56f755=_0xd35303[_0x3e6d48(0xa2)](_0x24ae5e=>normalizeField(_0x24ae5e))[_0x3e6d48(0xaa)](_0x4e6b16=>_0x4e6b16!==null);_0x56f755[_0x3e6d48(0xa3)]===0x0&&(_0x56f755=await loadListFieldFallback(_0x7d97ff[_0x3e6d48(0xc0)],_0x7d97ff['str'](_0x3e6d48(0xc5))));const _0x5dcb47=_0xfc9ce5[_0x3e6d48(0xac)]??{},_0x3933b5=[];for(const [_0x46e316,_0x9f09ce]of Object[_0x3e6d48(0xc3)](_0x5dcb47)){const _0x1f84b6=normalizeOperationEntry(_0x46e316,_0x9f09ce);if(_0x1f84b6)_0x3933b5[_0x3e6d48(0xb0)](_0x1f84b6);}const _0x5536cb=_0xfc9ce5[_0x3e6d48(0xbe)]??{},_0x4b2fdd=_0xfc9ce5[_0x3e6d48(0x8e)]??{},_0x176ba7=_0x5536cb[_0x3e6d48(0xb6)]!=null?{'id':_0x5536cb[_0x3e6d48(0xb6)],'name':_0x5536cb[_0x3e6d48(0xa0)]??null}:undefined;let _0x341da1;return typeof _0xfc9ce5[_0x3e6d48(0x87)]==='string'&&(_0x341da1=parseJsonMaybe(_0xfc9ce5[_0x3e6d48(0x87)])),{'ok':!![],'data':{'id':_0xfc9ce5['modelId']??_0xfc9ce5['id'],'name':_0xfc9ce5[_0x3e6d48(0xb7)],'code':_0xfc9ce5[_0x3e6d48(0x92)]||_0xfc9ce5[_0x3e6d48(0xc5)],'doVersion':_0xfc9ce5[_0x3e6d48(0xba)],'description':_0xfc9ce5[_0x3e6d48(0xd2)]||_0x4b2fdd[_0x3e6d48(0x99)]||undefined,'source':_0xfc9ce5[_0x3e6d48(0xcc)]||_0x4b2fdd[_0x3e6d48(0xaf)],'table':_0x5536cb[_0x3e6d48(0x96)]||_0x4b2fdd[_0x3e6d48(0x96)],'datasetKey':_0x5536cb[_0x3e6d48(0xbd)],'pk':_0x5536cb['pkField'],'db':_0x176ba7,'dbtable':summarizeDbtable(_0x5536cb),'fields':_0x56f755,'operations':_0x3933b5,'indexes':Array[_0x3e6d48(0x88)](_0x4b2fdd['indexes'])?_0x4b2fdd[_0x3e6d48(0xcd)]:[],'relations':_0xfc9ce5[_0x3e6d48(0xbf)]??null,'relatedPages':normalizeRelatedPages(_0xfc9ce5[_0x3e6d48(0xb3)]),...Array[_0x3e6d48(0x88)](_0xfc9ce5[_0x3e6d48(0xd3)])?{'columnCodeListWithDeleted':_0xfc9ce5[_0x3e6d48(0xd3)]}:{},'formatRules':Array[_0x3e6d48(0x88)](_0xfc9ce5[_0x3e6d48(0xd5)])?_0xfc9ce5[_0x3e6d48(0xd5)]:[],'validateRules':Array[_0x3e6d48(0x88)](_0xfc9ce5[_0x3e6d48(0x8d)])?_0xfc9ce5[_0x3e6d48(0x8d)]:[],..._0x341da1!==undefined?{'extend':_0x341da1}:{},'stats':{'fieldCount':_0x56f755[_0x3e6d48(0xa3)],'operationCount':_0x3933b5[_0x3e6d48(0xa3)]}}};}};
1
+ const a26_0x5a4151=a26_0x3979;(function(_0x3525b9,_0x10f29c){const _0x59e6da=a26_0x3979,_0x289cd9=_0x3525b9();while(!![]){try{const _0x31acd0=parseInt(_0x59e6da(0x18f))/0x1+-parseInt(_0x59e6da(0x155))/0x2*(-parseInt(_0x59e6da(0x15e))/0x3)+-parseInt(_0x59e6da(0x14e))/0x4*(-parseInt(_0x59e6da(0x16c))/0x5)+parseInt(_0x59e6da(0x178))/0x6+parseInt(_0x59e6da(0x168))/0x7+-parseInt(_0x59e6da(0x169))/0x8+-parseInt(_0x59e6da(0x183))/0x9;if(_0x31acd0===_0x10f29c)break;else _0x289cd9['push'](_0x289cd9['shift']());}catch(_0xfd228){_0x289cd9['push'](_0x289cd9['shift']());}}}(a26_0x35ef,0xa67e2));import{getDatasetDetail,listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';function normalizeField(_0x10eaeb){const _0xb2d81d=a26_0x3979;if(_0x10eaeb[_0xb2d81d(0x14a)])return null;const _0x26fee6=Boolean(_0x10eaeb[_0xb2d81d(0x176)]!==undefined||_0x10eaeb[_0xb2d81d(0x16e)]!==undefined);let _0x10fee2={};if(!_0x26fee6&&typeof _0x10eaeb[_0xb2d81d(0x152)]===_0xb2d81d(0x15c))try{_0x10fee2=JSON[_0xb2d81d(0x174)](_0x10eaeb[_0xb2d81d(0x152)]);}catch{}const _0x5622b2=_0x26fee6?_0x10eaeb[_0xb2d81d(0x188)]:_0x10eaeb[_0xb2d81d(0x166)],_0x3950ac=_0x26fee6?_0x10eaeb[_0xb2d81d(0x176)]:_0x10eaeb[_0xb2d81d(0x188)],_0xcbeace=_0x26fee6?_0x10eaeb[_0xb2d81d(0x16e)]:_0x10eaeb[_0xb2d81d(0x157)]||_0x10eaeb[_0xb2d81d(0x189)],_0x2b02b7=_0x26fee6?_0x10eaeb[_0xb2d81d(0x151)]===!![]:_0x10fee2[_0xb2d81d(0x151)]===!![],_0xa658de=_0x26fee6?_0x10eaeb[_0xb2d81d(0x167)]===!![]:_0x10fee2['required']===!![],_0x2c3fcf=_0x26fee6?_0x10eaeb['options']??null:_0x10fee2[_0xb2d81d(0x154)]??null,_0x13b0d6={'name':_0x5622b2,'displayName':_0x3950ac||_0x5622b2,'type':_0xcbeace,'dbType':_0x10eaeb[_0xb2d81d(0x177)],'pk':_0x2b02b7,'required':_0xa658de,'description':_0x10eaeb[_0xb2d81d(0x170)]||undefined};return Array[_0xb2d81d(0x156)](_0x2c3fcf)&&_0x2c3fcf[_0xb2d81d(0x192)]>0x0&&(_0x13b0d6['options']=_0x2c3fcf),_0x13b0d6;}function parseJsonMaybe(_0x464319){const _0x5583b5=a26_0x3979;if(typeof _0x464319!==_0x5583b5(0x15c))return _0x464319;try{return JSON[_0x5583b5(0x174)](_0x464319);}catch{return _0x464319;}}function normalizeOperationEntry(_0x12f396,_0x48cd1f){const _0x3730f4=a26_0x3979;if(!_0x48cd1f||typeof _0x48cd1f!==_0x3730f4(0x16a))return null;if(!_0x48cd1f['method']||!_0x48cd1f[_0x3730f4(0x17a)])return null;const _0x127ed4={'name':_0x12f396,'method':_0x48cd1f[_0x3730f4(0x17e)],'path':_0x48cd1f['path']};if(_0x48cd1f['host'])_0x127ed4[_0x3730f4(0x190)]=_0x48cd1f[_0x3730f4(0x190)];if(_0x48cd1f[_0x3730f4(0x153)]!=null)_0x127ed4['requestBody']=parseJsonMaybe(_0x48cd1f[_0x3730f4(0x153)]);if(_0x48cd1f['responseBody']!=null)_0x127ed4['responseBody']=parseJsonMaybe(_0x48cd1f['responseBody']);if(_0x48cd1f[_0x3730f4(0x191)]!=null)_0x127ed4['beforeScriptId']=_0x48cd1f[_0x3730f4(0x191)];if(_0x48cd1f[_0x3730f4(0x187)]!=null)_0x127ed4['afterScriptId']=_0x48cd1f[_0x3730f4(0x187)];if(Array['isArray'](_0x48cd1f[_0x3730f4(0x15f)]))_0x127ed4[_0x3730f4(0x15f)]=_0x48cd1f[_0x3730f4(0x15f)];if(Array[_0x3730f4(0x156)](_0x48cd1f[_0x3730f4(0x16b)]))_0x127ed4['responseFields']=_0x48cd1f[_0x3730f4(0x16b)];return _0x127ed4;}function summarizeDbtable(_0x7a7d51){const _0x17922d=a26_0x3979,_0x14deea={},_0x38c905=['dbId',_0x17922d(0x18a),'tableName',_0x17922d(0x15a),'pkField','allFields','logicField',_0x17922d(0x17b),_0x17922d(0x184),_0x17922d(0x186),'creatorNameField',_0x17922d(0x14d),_0x17922d(0x180),_0x17922d(0x17d),'dblinkInfoDTO'];for(const _0x197ea0 of _0x38c905){if(_0x7a7d51[_0x197ea0]!==undefined)_0x14deea[_0x197ea0]=_0x7a7d51[_0x197ea0];}return typeof _0x14deea[_0x17922d(0x179)]==='string'&&_0x14deea[_0x17922d(0x179)][_0x17922d(0x192)]>0x0&&(_0x14deea[_0x17922d(0x173)]=_0x14deea[_0x17922d(0x179)][_0x17922d(0x15d)](',')['map'](_0x1a36ad=>_0x1a36ad['trim']())[_0x17922d(0x14c)](Boolean)),_0x14deea;}function a26_0x35ef(){const _0x3e61c4=['dbtableConfig','176184WTPrAA','host','beforeScriptId','length','sourceType','modelCode','operations','deleted','tableName','filter','modifierIdField','52ZFREJl','tableComment','dataset','pkField','extend','requestBody','options','814NMpdaF','isArray','type','title','source','datasetKey','properties','string','split','6306HiCSfp','requestFields','indexes','formatRules','dbId','Get\x20dataset\x20detail\x20including\x20fields,\x20relations,\x20and\x20operations','detail','relatedPageInfoList','code','required','8376081EJtxbB','8045960JJTjXP','object','responseFields','69010LBemHM','columnCodeListWithDeleted','doType','push','description','doVersion','find','allFieldNames','parse','modelId','displayName','dbType','680412cDhvYI','allFields','path','createTimeField','validateRules','labelField','method','read','modifierNameField','relations','appCode','7500690lADqZn','updateTimeField','str','creatorIdField','afterScriptId','name','dataType','dbName','map','entries','trim'];a26_0x35ef=function(){return _0x3e61c4;};return a26_0x35ef();}function a26_0x3979(_0x5b3ff6,_0x12651c){_0x5b3ff6=_0x5b3ff6-0x14a;const _0x35ef39=a26_0x35ef();let _0x397959=_0x35ef39[_0x5b3ff6];return _0x397959;}function normalizeRelatedPages(_0x4c3630){const _0x491fe2=a26_0x3979;if(!Array[_0x491fe2(0x156)](_0x4c3630))return[];return _0x4c3630[_0x491fe2(0x14c)](_0x2b0f0b=>_0x2b0f0b&&typeof _0x2b0f0b===_0x491fe2(0x16a))[_0x491fe2(0x18b)](_0x4b36f1=>({'id':_0x4b36f1['id'],'type':_0x4b36f1[_0x491fe2(0x157)],'code':_0x4b36f1[_0x491fe2(0x166)],'title':_0x4b36f1[_0x491fe2(0x158)],'deleted':_0x4b36f1[_0x491fe2(0x14a)]===!![]}));}function normalizeFallbackFieldName(_0x16d980,_0x5125a1){const _0x3453f8=a26_0x3979,_0x2d83d6=_0x16d980[_0x3453f8(0x18d)]();if(!_0x2d83d6)return null;return{'name':_0x2d83d6,'displayName':_0x2d83d6,'type':undefined,'dbType':undefined,'pk':_0x2d83d6===_0x5125a1,'required':![],'description':undefined};}async function loadListFieldFallback(_0x3247e9,_0x404cf1){const _0x58b215=a26_0x3979;if(!_0x3247e9||!_0x404cf1)return[];try{const _0x202ef9=await listDatasets(_0x3247e9,{'code':_0x404cf1}),_0x202aa0=_0x202ef9[_0x58b215(0x172)](_0x37cfbc=>_0x37cfbc[_0x58b215(0x166)]===_0x404cf1)??_0x202ef9[0x0],_0x556c02=_0x202aa0?.['dbtableConfig']??{},_0x10c914=typeof _0x556c02['allFields']===_0x58b215(0x15c)?_0x556c02[_0x58b215(0x179)][_0x58b215(0x15d)](','):[];return _0x10c914[_0x58b215(0x18b)](_0x24e915=>normalizeFallbackFieldName(_0x24e915,_0x556c02['pkField']))[_0x58b215(0x14c)](_0x44c621=>_0x44c621!==null);}catch{return[];}}export const datasetDetail={'service':a26_0x5a4151(0x150),'command':a26_0x5a4151(0x164),'description':a26_0x5a4151(0x163),'risk':a26_0x5a4151(0x17f),'flags':[CODE_FLAG],async 'execute'(_0x2a1cb5){const _0x3acc0d=a26_0x5a4151,_0x55e1b4=await getDatasetDetail(_0x2a1cb5['str']('code')),_0x1e2b6f=Array['isArray'](_0x55e1b4['fields'])?_0x55e1b4['fields']:Array[_0x3acc0d(0x156)](_0x55e1b4['properties'])?_0x55e1b4[_0x3acc0d(0x15b)]:[];let _0x46c3b3=_0x1e2b6f[_0x3acc0d(0x18b)](_0x2bb4c9=>normalizeField(_0x2bb4c9))['filter'](_0x5b5807=>_0x5b5807!==null);_0x46c3b3[_0x3acc0d(0x192)]===0x0&&(_0x46c3b3=await loadListFieldFallback(_0x2a1cb5[_0x3acc0d(0x182)],_0x2a1cb5[_0x3acc0d(0x185)](_0x3acc0d(0x166))));const _0x43b3eb=_0x55e1b4[_0x3acc0d(0x195)]??{},_0x3fb252=[];for(const [_0x516a17,_0x35bc8d]of Object[_0x3acc0d(0x18c)](_0x43b3eb)){const _0x10055f=normalizeOperationEntry(_0x516a17,_0x35bc8d);if(_0x10055f)_0x3fb252[_0x3acc0d(0x16f)](_0x10055f);}const _0x379206=_0x55e1b4[_0x3acc0d(0x18e)]??{},_0x1bee05=_0x55e1b4['dataset']??{},_0x2f3470=_0x379206[_0x3acc0d(0x162)]!=null?{'id':_0x379206[_0x3acc0d(0x162)],'name':_0x379206[_0x3acc0d(0x18a)]??null}:undefined;let _0x19e0d5;return typeof _0x55e1b4[_0x3acc0d(0x152)]===_0x3acc0d(0x15c)&&(_0x19e0d5=parseJsonMaybe(_0x55e1b4[_0x3acc0d(0x152)])),{'ok':!![],'data':{'id':_0x55e1b4[_0x3acc0d(0x175)]??_0x55e1b4['id'],'name':_0x55e1b4['name'],'code':_0x55e1b4[_0x3acc0d(0x194)]||_0x55e1b4[_0x3acc0d(0x166)],'doVersion':_0x55e1b4[_0x3acc0d(0x171)],'description':_0x55e1b4[_0x3acc0d(0x170)]||_0x1bee05[_0x3acc0d(0x14f)]||undefined,'source':_0x55e1b4[_0x3acc0d(0x159)]||_0x1bee05[_0x3acc0d(0x193)],'table':_0x379206[_0x3acc0d(0x14b)]||_0x1bee05[_0x3acc0d(0x14b)],'datasetKey':_0x379206[_0x3acc0d(0x15a)],'pk':_0x379206[_0x3acc0d(0x151)],'db':_0x2f3470,'dbtable':summarizeDbtable(_0x379206),'fields':_0x46c3b3,'operations':_0x3fb252,'indexes':Array[_0x3acc0d(0x156)](_0x1bee05[_0x3acc0d(0x160)])?_0x1bee05[_0x3acc0d(0x160)]:[],'relations':_0x55e1b4[_0x3acc0d(0x181)]??null,'relatedPages':normalizeRelatedPages(_0x55e1b4[_0x3acc0d(0x165)]),...Array[_0x3acc0d(0x156)](_0x55e1b4[_0x3acc0d(0x16d)])?{'columnCodeListWithDeleted':_0x55e1b4['columnCodeListWithDeleted']}:{},'formatRules':Array['isArray'](_0x55e1b4[_0x3acc0d(0x161)])?_0x55e1b4[_0x3acc0d(0x161)]:[],'validateRules':Array[_0x3acc0d(0x156)](_0x55e1b4[_0x3acc0d(0x17c)])?_0x55e1b4[_0x3acc0d(0x17c)]:[],..._0x19e0d5!==undefined?{'extend':_0x19e0d5}:{},'stats':{'fieldCount':_0x46c3b3[_0x3acc0d(0x192)],'operationCount':_0x3fb252['length']}}};}};
@@ -1 +1 @@
1
- function a27_0x1337(_0x55462d,_0x13895a){_0x55462d=_0x55462d-0x9b;const _0x50777d=a27_0x5077();let _0x133748=_0x50777d[_0x55462d];return _0x133748;}(function(_0x2f2bfb,_0x37ace3){const _0x211f42=a27_0x1337,_0x2938a5=_0x2f2bfb();while(!![]){try{const _0x49798c=parseInt(_0x211f42(0x9e))/0x1+parseInt(_0x211f42(0x9d))/0x2+parseInt(_0x211f42(0xa4))/0x3*(parseInt(_0x211f42(0x9c))/0x4)+-parseInt(_0x211f42(0xa2))/0x5+parseInt(_0x211f42(0xa1))/0x6+parseInt(_0x211f42(0xa3))/0x7*(parseInt(_0x211f42(0x9f))/0x8)+-parseInt(_0x211f42(0x9b))/0x9*(parseInt(_0x211f42(0xa0))/0xa);if(_0x49798c===_0x37ace3)break;else _0x2938a5['push'](_0x2938a5['shift']());}catch(_0x45e284){_0x2938a5['push'](_0x2938a5['shift']());}}}(a27_0x5077,0xdb505));import{datasetList}from'../../commands/dataset/list.js';import{datasetDetail}from'../../commands/dataset/detail.js';import{datasetSdkDoc}from'../../commands/dataset/sdk-doc.js';export const datasetDefinitions=[datasetList,datasetDetail,datasetSdkDoc];function a27_0x5077(){const _0x5ac665=['603hxWqpW','4CpqnGb','720666kmCfgg','1600792FEbYlx','136EQqJIO','97210dWylyn','3623160PJPBpn','7833905bjlDse','56168BZOmrN','1245012GVfIiJ'];a27_0x5077=function(){return _0x5ac665;};return a27_0x5077();}
1
+ (function(_0x29b522,_0xbb6092){const _0x440d53=a27_0x1d38,_0x34b03c=_0x29b522();while(!![]){try{const _0xb0f6d6=-parseInt(_0x440d53(0xd9))/0x1*(-parseInt(_0x440d53(0xe1))/0x2)+-parseInt(_0x440d53(0xde))/0x3*(-parseInt(_0x440d53(0xe2))/0x4)+-parseInt(_0x440d53(0xdc))/0x5+parseInt(_0x440d53(0xe0))/0x6+-parseInt(_0x440d53(0xdb))/0x7*(-parseInt(_0x440d53(0xda))/0x8)+parseInt(_0x440d53(0xdf))/0x9+-parseInt(_0x440d53(0xdd))/0xa;if(_0xb0f6d6===_0xbb6092)break;else _0x34b03c['push'](_0x34b03c['shift']());}catch(_0x14e6fd){_0x34b03c['push'](_0x34b03c['shift']());}}}(a27_0x3a72,0x3c6b9));import{datasetList}from'../../commands/dataset/list.js';function a27_0x1d38(_0xbfb9fd,_0x1e5626){_0xbfb9fd=_0xbfb9fd-0xd9;const _0x3a723b=a27_0x3a72();let _0x1d3846=_0x3a723b[_0xbfb9fd];return _0x1d3846;}function a27_0x3a72(){const _0x99499=['26PWnsCA','69928wMwFqH','238rFuPUF','1929735uJqwAa','6431700kwsasL','174381DcMyHh','4042467oZFYjI','858150pBfJpi','2958QAPYdx','24ioYgEA'];a27_0x3a72=function(){return _0x99499;};return a27_0x3a72();}import{datasetDetail}from'../../commands/dataset/detail.js';import{datasetSdkDoc}from'../../commands/dataset/sdk-doc.js';export const datasetDefinitions=[datasetList,datasetDetail,datasetSdkDoc];
@@ -1 +1 @@
1
- const a28_0x4bbc48=a28_0x14cf;function a28_0x14cf(_0x103ba1,_0x46dca8){_0x103ba1=_0x103ba1-0x7d;const _0x213666=a28_0x2136();let _0x14cf18=_0x213666[_0x103ba1];return _0x14cf18;}(function(_0x13cb8a,_0x1e6c60){const _0x2d0a75=a28_0x14cf,_0x2ee9b7=_0x13cb8a();while(!![]){try{const _0x1a1f1e=parseInt(_0x2d0a75(0x86))/0x1*(-parseInt(_0x2d0a75(0x9b))/0x2)+parseInt(_0x2d0a75(0x82))/0x3+parseInt(_0x2d0a75(0x83))/0x4*(-parseInt(_0x2d0a75(0x8e))/0x5)+-parseInt(_0x2d0a75(0x96))/0x6+parseInt(_0x2d0a75(0x85))/0x7*(parseInt(_0x2d0a75(0x93))/0x8)+-parseInt(_0x2d0a75(0x99))/0x9*(-parseInt(_0x2d0a75(0x87))/0xa)+parseInt(_0x2d0a75(0x88))/0xb*(parseInt(_0x2d0a75(0x81))/0xc);if(_0x1a1f1e===_0x1e6c60)break;else _0x2ee9b7['push'](_0x2ee9b7['shift']());}catch(_0x4b2d57){_0x2ee9b7['push'](_0x2ee9b7['shift']());}}}(a28_0x2136,0x26084));import{listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';export const datasetList={'service':'dataset','command':a28_0x4bbc48(0x8a),'description':a28_0x4bbc48(0x90),'risk':'read','flags':[{'name':a28_0x4bbc48(0x8d),'type':a28_0x4bbc48(0x7f),'description':a28_0x4bbc48(0x95)},{...CODE_FLAG,'required':![],'description':a28_0x4bbc48(0x7e)}],async 'execute'(_0x400017){const _0x28b507=a28_0x4bbc48,_0x544e9f=_0x400017[_0x28b507(0x97)]('name'),_0x553eea=_0x400017[_0x28b507(0x97)](_0x28b507(0x92)),_0x244f90=await listDatasets(_0x400017[_0x28b507(0x7d)],{..._0x544e9f&&{'name':_0x544e9f},..._0x553eea&&{'code':_0x553eea}});return{'ok':!![],'data':{'total':_0x244f90[_0x28b507(0x89)],'datasets':_0x244f90[_0x28b507(0x80)](_0x1fbcef=>{const _0x5c9196=_0x28b507,_0x1179d1=_0x1fbcef[_0x5c9196(0x98)]??{};return{'id':_0x1fbcef['id'],'code':_0x1fbcef[_0x5c9196(0x92)],'name':_0x1fbcef[_0x5c9196(0x8d)],'source':_0x1fbcef[_0x5c9196(0x9a)],'description':_0x1fbcef[_0x5c9196(0x8f)],'table':_0x1179d1['tableName'],'datasetKey':_0x1179d1[_0x5c9196(0x8b)],'pk':_0x1179d1[_0x5c9196(0x84)],'fields':_0x1179d1[_0x5c9196(0x8c)]?_0x1179d1[_0x5c9196(0x8c)][_0x5c9196(0x91)](',')[_0x5c9196(0x80)](_0x440cf7=>_0x440cf7[_0x5c9196(0x94)]()):[]};})}};}};function a28_0x2136(){const _0x19327b=['Filter\x20by\x20dataset\x20name\x20(server-side\x20fuzzy\x20match)','1317930knTeVm','str','dbtableConfig','851490IEshTt','source','19996XpPdWn','appCode','Filter\x20by\x20dataset\x20code\x20(server-side\x20exact\x20match)','string','map','732UjCNgS','175005JLSkfD','4ifrbYK','pkField','7YqGuaD','2KmJVHb','20NINXYA','31625qCydOE','length','list','datasetKey','allFields','name','335380GfRChY','description','List\x20datasets\x20in\x20the\x20app\x20(supports\x20server-side\x20name/code\x20filtering)','split','code','316616DPUBJH','trim'];a28_0x2136=function(){return _0x19327b;};return a28_0x2136();}
1
+ const a28_0x50af79=a28_0x3002;function a28_0x34be(){const _0x28b972=['11430BoKTzg','1744318qSsxek','read','Filter\x20by\x20dataset\x20name\x20(server-side\x20fuzzy\x20match)','382809JavVum','datasetKey','pkField','str','dbtableConfig','462099CocWGZ','map','5126156UMQDIx','source','42OBFkFH','168ugpPFH','Filter\x20by\x20dataset\x20code\x20(server-side\x20exact\x20match)','code','540692vPZsMe','allFields','dataset','name','list','description','tableName','3970mEkWOa','List\x20datasets\x20in\x20the\x20app\x20(supports\x20server-side\x20name/code\x20filtering)','500605jyqbIi'];a28_0x34be=function(){return _0x28b972;};return a28_0x34be();}function a28_0x3002(_0x3e10df,_0x25beef){_0x3e10df=_0x3e10df-0x1b2;const _0x34be9d=a28_0x34be();let _0x3002c1=_0x34be9d[_0x3e10df];return _0x3002c1;}(function(_0x3d41eb,_0x4ccf5b){const _0x43ccd7=a28_0x3002,_0x401cc0=_0x3d41eb();while(!![]){try{const _0x4f98ff=parseInt(_0x43ccd7(0x1c9))/0x1+parseInt(_0x43ccd7(0x1be))/0x2+parseInt(_0x43ccd7(0x1b6))/0x3+-parseInt(_0x43ccd7(0x1b8))/0x4+parseInt(_0x43ccd7(0x1c7))/0x5*(parseInt(_0x43ccd7(0x1ba))/0x6)+-parseInt(_0x43ccd7(0x1cc))/0x7*(parseInt(_0x43ccd7(0x1bb))/0x8)+-parseInt(_0x43ccd7(0x1c8))/0x9*(-parseInt(_0x43ccd7(0x1c5))/0xa);if(_0x4f98ff===_0x4ccf5b)break;else _0x401cc0['push'](_0x401cc0['shift']());}catch(_0x26a212){_0x401cc0['push'](_0x401cc0['shift']());}}}(a28_0x34be,0xe6698));import{listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';export const datasetList={'service':a28_0x50af79(0x1c0),'command':a28_0x50af79(0x1c2),'description':a28_0x50af79(0x1c6),'risk':a28_0x50af79(0x1ca),'flags':[{'name':a28_0x50af79(0x1c1),'type':'string','description':a28_0x50af79(0x1cb)},{...CODE_FLAG,'required':![],'description':a28_0x50af79(0x1bc)}],async 'execute'(_0x2f161f){const _0x5855e0=a28_0x50af79,_0x2cd5c4=_0x2f161f[_0x5855e0(0x1b4)](_0x5855e0(0x1c1)),_0x4807b1=_0x2f161f[_0x5855e0(0x1b4)](_0x5855e0(0x1bd)),_0x3e871d=await listDatasets(_0x2f161f['appCode'],{..._0x2cd5c4&&{'name':_0x2cd5c4},..._0x4807b1&&{'code':_0x4807b1}});return{'ok':!![],'data':{'total':_0x3e871d['length'],'datasets':_0x3e871d['map'](_0x5bdac9=>{const _0x251537=_0x5855e0,_0x493859=_0x5bdac9[_0x251537(0x1b5)]??{};return{'id':_0x5bdac9['id'],'code':_0x5bdac9[_0x251537(0x1bd)],'name':_0x5bdac9['name'],'source':_0x5bdac9[_0x251537(0x1b9)],'description':_0x5bdac9[_0x251537(0x1c3)],'table':_0x493859[_0x251537(0x1c4)],'datasetKey':_0x493859[_0x251537(0x1b2)],'pk':_0x493859[_0x251537(0x1b3)],'fields':_0x493859[_0x251537(0x1bf)]?_0x493859['allFields']['split'](',')[_0x251537(0x1b7)](_0x3c0f4a=>_0x3c0f4a['trim']()):[]};})}};}};
@@ -1 +1 @@
1
- const a29_0x47e192=a29_0x53b3;(function(_0x358776,_0xa3a90f){const _0x8d5000=a29_0x53b3,_0x3ba656=_0x358776();while(!![]){try{const _0x65624a=-parseInt(_0x8d5000(0x14b))/0x1+parseInt(_0x8d5000(0x146))/0x2+parseInt(_0x8d5000(0x14a))/0x3+parseInt(_0x8d5000(0x141))/0x4+-parseInt(_0x8d5000(0x14d))/0x5+-parseInt(_0x8d5000(0x150))/0x6*(parseInt(_0x8d5000(0x145))/0x7)+parseInt(_0x8d5000(0x14e))/0x8;if(_0x65624a===_0xa3a90f)break;else _0x3ba656['push'](_0x3ba656['shift']());}catch(_0x520d40){_0x3ba656['push'](_0x3ba656['shift']());}}}(a29_0x46c3,0x212c6));import{getDatasetSdkUsageDoc}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';const DEFAULT_MARKDOWN=a29_0x47e192(0x144);export function formatDatasetSdkMarkdown(_0x4a7cc4){const _0x579e1a=a29_0x47e192,_0xe988ec=typeof _0x4a7cc4===_0x579e1a(0x151)?_0x4a7cc4[_0x579e1a(0x14c)]():'';return _0xe988ec||DEFAULT_MARKDOWN;}function a29_0x46c3(){const _0x3211f4=['401040sZdkNH','code','read','Dataset\x20code\x20(32\x20characters).\x20Numeric\x20dataset\x20IDs\x20are\x20not\x20accepted.','453318kQJrmB','257833MCCFlH','trim','1303230AbmShu','2499344zvdoYp','appCode','6VQYEGH','string','564076bgYaBE','Get\x20SDK\x20usage\x20markdown\x20for\x20a\x20dataset\x20code','str','#\x20Dataset\x20SDK\x20Usage\x20Documentation\x0a\x0aNo\x20SDK\x20usage\x20documentation\x20is\x20available.','1054942sdqYYi'];a29_0x46c3=function(){return _0x3211f4;};return a29_0x46c3();}function a29_0x53b3(_0x1f5b3f,_0x4da524){_0x1f5b3f=_0x1f5b3f-0x141;const _0x46c377=a29_0x46c3();let _0x53b376=_0x46c377[_0x1f5b3f];return _0x53b376;}export const datasetSdkDoc={'service':'dataset','command':'sdk-doc','description':a29_0x47e192(0x142),'risk':a29_0x47e192(0x148),'flags':[{...CODE_FLAG,'description':a29_0x47e192(0x149)}],async 'execute'(_0x28293a){const _0x428ead=a29_0x47e192,_0x562ec1=_0x28293a[_0x428ead(0x143)](_0x428ead(0x147)),_0x193a4d=await getDatasetSdkUsageDoc(_0x562ec1,_0x28293a['appCode']);return{'ok':!![],'data':{'code':_0x562ec1,'appCode':_0x28293a[_0x428ead(0x14f)],'markdown':formatDatasetSdkMarkdown(_0x193a4d)}};}};
1
+ const a29_0xd5f91c=a29_0x460c;(function(_0x1ed9ce,_0x151ed9){const _0x1dc479=a29_0x460c,_0x197d07=_0x1ed9ce();while(!![]){try{const _0x18039f=-parseInt(_0x1dc479(0x1c3))/0x1+-parseInt(_0x1dc479(0x1c0))/0x2+parseInt(_0x1dc479(0x1b5))/0x3+parseInt(_0x1dc479(0x1b8))/0x4+parseInt(_0x1dc479(0x1bc))/0x5*(parseInt(_0x1dc479(0x1ba))/0x6)+-parseInt(_0x1dc479(0x1c2))/0x7+parseInt(_0x1dc479(0x1be))/0x8;if(_0x18039f===_0x151ed9)break;else _0x197d07['push'](_0x197d07['shift']());}catch(_0x171d96){_0x197d07['push'](_0x197d07['shift']());}}}(a29_0x5f57,0x21504));import{getDatasetSdkUsageDoc}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';function a29_0x460c(_0x134765,_0xe4afdd){_0x134765=_0x134765-0x1b5;const _0x5f57d0=a29_0x5f57();let _0x460c0f=_0x5f57d0[_0x134765];return _0x460c0f;}const DEFAULT_MARKDOWN=a29_0xd5f91c(0x1bf);export function formatDatasetSdkMarkdown(_0x1a98bf){const _0x31f56e=a29_0xd5f91c,_0x27b047=typeof _0x1a98bf===_0x31f56e(0x1b9)?_0x1a98bf['trim']():'';return _0x27b047||DEFAULT_MARKDOWN;}export const datasetSdkDoc={'service':'dataset','command':a29_0xd5f91c(0x1bb),'description':a29_0xd5f91c(0x1c1),'risk':'read','flags':[{...CODE_FLAG,'description':a29_0xd5f91c(0x1b7)}],async 'execute'(_0x39c89a){const _0x4dff4f=a29_0xd5f91c,_0xda5cc2=_0x39c89a[_0x4dff4f(0x1bd)](_0x4dff4f(0x1b6)),_0x297f83=await getDatasetSdkUsageDoc(_0xda5cc2,_0x39c89a[_0x4dff4f(0x1c4)]);return{'ok':!![],'data':{'code':_0xda5cc2,'appCode':_0x39c89a['appCode'],'markdown':formatDatasetSdkMarkdown(_0x297f83)}};}};function a29_0x5f57(){const _0x46c20c=['#\x20Dataset\x20SDK\x20Usage\x20Documentation\x0a\x0aNo\x20SDK\x20usage\x20documentation\x20is\x20available.','270586xuTqlS','Get\x20SDK\x20usage\x20markdown\x20for\x20a\x20dataset\x20code','623714XXROuC','122713obBAza','appCode','583935aKZoat','code','Dataset\x20code\x20(32\x20characters).\x20Numeric\x20dataset\x20IDs\x20are\x20not\x20accepted.','322068KepzqU','string','456AmQVyf','sdk-doc','12635IxMInT','str','130768tvxnEb'];a29_0x5f57=function(){return _0x46c20c;};return a29_0x5f57();}
@@ -1 +1 @@
1
- const a30_0xe2a714=a30_0x4fe7;(function(_0x1a54bf,_0x122c19){const _0x3766fe=a30_0x4fe7,_0x596645=_0x1a54bf();while(!![]){try{const _0x29edbe=-parseInt(_0x3766fe(0x1d7))/0x1*(parseInt(_0x3766fe(0x1d1))/0x2)+-parseInt(_0x3766fe(0x1db))/0x3*(parseInt(_0x3766fe(0x1c5))/0x4)+-parseInt(_0x3766fe(0x1a3))/0x5+parseInt(_0x3766fe(0x1f7))/0x6+-parseInt(_0x3766fe(0x1fd))/0x7*(parseInt(_0x3766fe(0x1ca))/0x8)+-parseInt(_0x3766fe(0x1fc))/0x9+parseInt(_0x3766fe(0x1f0))/0xa;if(_0x29edbe===_0x122c19)break;else _0x596645['push'](_0x596645['shift']());}catch(_0x536bae){_0x596645['push'](_0x596645['shift']());}}}(a30_0x25f2,0x9ec89));import a30_0x2dee60 from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';function a30_0x25f2(){const _0x3c2de4=['riskLevel','(unnamed)','locale','length','raw','1716480uQFFqT','platform','Diagnose\x20CLI\x20configuration\x20and\x20environment','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','registryPath','bold','green','\x20\x20skillDomain:\x20\x20\x20\x20\x20','\x20\x20app\x20locale:\x20\x20\x20\x20\x20\x20','version','installedPath','source','missing','⚠\x20Empty\x20(treated\x20as\x20{})','region','\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20','\x20\x20API\x20Endpoints','\x20\x20Merged\x20Config','repeat','padEnd','Global','Project','\x20\x20Config\x20JSON','\x20\x20Installed\x20Path:\x20\x20','✓\x20Loaded','\x20\x20Skill\x20Version:\x20\x20\x20','(none)','accessKey','commandCount','message','ignored\x20in\x20','(removed\x20—\x20cookie\x20auth\x20disabled)','gray','global','4MXmtZK','serviceCode','pageSize','status','path','11816kgfGUm','globalConfig','prototype','\x20config\x20delete\x20inherit','\x20\x20Built-in\x20Skill','inherit','\x20Imported\x20from:\x20','2ZTyDxU','state','\x20\x20Reason:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','(not\x20found)','currentApp','349814BFYdkz','call','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','✓\x20current','950043AAuSbK','join','\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','name','✗\x20Invalid\x20JSON','\x20\x20Auth','\x20doctor','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','✓\x20Valid\x20JSON','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','\x20config\x20delete\x20inherit\x20--global','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','filter','\x20\x20Repair\x20global:\x20\x20\x20\x20','hasOwnProperty','read','reason','verbose','services','\x20\x20Legacy\x20inherit:\x20\x20\x20','(missing)','29302130QgrlTQ','\x20\x20Repair:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20currentApp:\x20\x20\x20\x20\x20\x20','check','projectConfig','\x20\x20Session\x20check:\x20\x20\x20','49470BKWcAU','ClientAk','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','format','doctor','2545128kyLNTQ','4718HXuDTU','\x20\x20─','(set,\x20length=','(not\x20set)','arch','empty','\x20config','\x20\x20Package\x20Version:\x20','serviceCount','repairCommand','\x20\x20Registry:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20(accessKey)','red','skillVersion','log','\x20\x20Config\x20Files','\x20\x20Services:\x20\x20\x20\x20\x20\x20\x20\x20','yellow','✗\x20Invalid','project','appCode','\x20\x20userDomain:\x20\x20\x20\x20\x20\x20','current','(default:\x20','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'];a30_0x25f2=function(){return _0x3c2de4;};return a30_0x25f2();}import{getCliVersion}from'../utils/version.js';import{getApiDomain,getKbDomain,getRuntimeDomain,getSkillDomain,getUserDomain}from'../constant/domain.js';import{normalizeLovrabetRegion}from'../constant/region.js';import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile,loadRawConfigLayers}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';function a30_0x4fe7(_0x59c961,_0x245cab){_0x59c961=_0x59c961-0x1a1;const _0x25f220=a30_0x25f2();let _0x4fe766=_0x25f220[_0x59c961];return _0x4fe766;}import{inspectServiceRegistry}from'../commands/service/registry.js';import{inspectBuiltinSkill}from'../skills/builtin-skill.js';async function execute(_0x33c72c){const _0xb9c425=a30_0x4fe7,_0x2a7bcc=getCliVersion(),_0x31c526=buildConfigFromFlags({});await initGlobalEnvironment(_0x31c526),console[_0xb9c425(0x20c)](),console[_0xb9c425(0x20c)](a30_0x2dee60['bold'](CLI_BIN_NAME+_0xb9c425(0x1e1))),console[_0xb9c425(0x20c)](a30_0x2dee60['gray']('─'['repeat'](0x32))),console[_0xb9c425(0x20c)](_0xb9c425(0x1f9)+_0x2a7bcc),console[_0xb9c425(0x20c)](_0xb9c425(0x1dd)+process[_0xb9c425(0x1ac)]),console[_0xb9c425(0x20c)]('\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0xb9c425(0x1a4)]+'\x20'+process[_0xb9c425(0x201)]);const _0x84692d=inspectBuiltinSkill();console['log'](),console[_0xb9c425(0x20c)](a30_0x2dee60[_0xb9c425(0x1a8)](_0xb9c425(0x1ce))),console['log'](a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1fe)[_0xb9c425(0x1b5)](0x1e))),console[_0xb9c425(0x20c)]('\x20\x20State:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x84692d[_0xb9c425(0x1d2)]===_0xb9c425(0x214)?a30_0x2dee60['green'](_0xb9c425(0x1da)):a30_0x2dee60[_0xb9c425(0x20a)]('✗\x20'+_0x84692d[_0xb9c425(0x1d2)]))),console[_0xb9c425(0x20c)](_0xb9c425(0x204)+_0x84692d['packageVersion']),console[_0xb9c425(0x20c)](_0xb9c425(0x1bc)+(_0x84692d[_0xb9c425(0x20b)]||a30_0x2dee60[_0xb9c425(0x1c3)]('(missing)'))),console[_0xb9c425(0x20c)](_0xb9c425(0x1ba)+(_0x84692d[_0xb9c425(0x1ad)]||a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1d5))));_0x84692d[_0xb9c425(0x1d2)]!==_0xb9c425(0x214)&&console[_0xb9c425(0x20c)](_0xb9c425(0x1f1)+_0x84692d[_0xb9c425(0x206)]);_0x84692d[_0xb9c425(0x1eb)]&&console[_0xb9c425(0x20c)](_0xb9c425(0x1d3)+_0x84692d[_0xb9c425(0x1eb)]);console[_0xb9c425(0x20c)](),console[_0xb9c425(0x20c)](a30_0x2dee60[_0xb9c425(0x1a8)](_0xb9c425(0x20d))),console['log'](a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1fe)[_0xb9c425(0x1b5)](0x1e)));const _0x3477d8=getGlobalConfigPath(),_0x35520c=getProjectConfigPath();console['log']('\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x3477d8||a30_0x2dee60['gray'](_0xb9c425(0x1d5)))),console[_0xb9c425(0x20c)]('\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20'+(_0x35520c||a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1d5)))),console['log'](),console['log'](a30_0x2dee60[_0xb9c425(0x1a8)](_0xb9c425(0x1b9))),console['log'](a30_0x2dee60[_0xb9c425(0x1c3)]('\x20\x20─'[_0xb9c425(0x1b5)](0x1e)));const _0x4012a1=(_0x61ac39,_0x552562)=>{const _0x377640=_0xb9c425;if(!_0x552562){console[_0x377640(0x20c)]('\x20\x20'+_0x61ac39[_0x377640(0x1b6)](0x11)+'\x20'+a30_0x2dee60['gray']('(no\x20file)'));return;}const _0x461b0d=inspectCliConfigJsonFile(_0x552562);if(_0x461b0d[_0x377640(0x1c8)]==='ok')console[_0x377640(0x20c)]('\x20\x20'+_0x61ac39[_0x377640(0x1b6)](0x11)+'\x20'+a30_0x2dee60[_0x377640(0x1a9)](_0x377640(0x1e3)));else{if(_0x461b0d['status']===_0x377640(0x202))console[_0x377640(0x20c)]('\x20\x20'+_0x61ac39[_0x377640(0x1b6)](0x11)+'\x20'+a30_0x2dee60[_0x377640(0x20f)](_0x377640(0x1b0)));else _0x461b0d['status']==='missing'?console[_0x377640(0x20c)]('\x20\x20'+_0x61ac39[_0x377640(0x1b6)](0x11)+'\x20'+a30_0x2dee60[_0x377640(0x1c3)](_0x377640(0x1ef))):(console[_0x377640(0x20c)]('\x20\x20'+_0x61ac39[_0x377640(0x1b6)](0x11)+'\x20'+a30_0x2dee60[_0x377640(0x20a)](_0x377640(0x1df))),console[_0x377640(0x20c)]('\x20\x20'+''['padEnd'](0x11)+'\x20'+a30_0x2dee60[_0x377640(0x20a)](_0x461b0d[_0x377640(0x1c0)])));}};_0x4012a1(_0xb9c425(0x1b7),_0x3477d8),_0x4012a1(_0xb9c425(0x1b8),_0x35520c);const _0x310631=loadRawConfigLayers(),_0xf1125b=[Object[_0xb9c425(0x1cc)][_0xb9c425(0x1e9)][_0xb9c425(0x1d8)](_0x310631[_0xb9c425(0x1cb)],_0xb9c425(0x1cf))?_0xb9c425(0x1c4):null,Object[_0xb9c425(0x1cc)][_0xb9c425(0x1e9)][_0xb9c425(0x1d8)](_0x310631[_0xb9c425(0x1f5)],'inherit')?'project':null][_0xb9c425(0x1e7)](Boolean);_0xf1125b[_0xb9c425(0x1a1)]>0x0&&(console['log'](_0xb9c425(0x1ee)+a30_0x2dee60[_0xb9c425(0x20f)](_0xb9c425(0x1c1)+_0xf1125b[_0xb9c425(0x1dc)]('\x20+\x20')+_0xb9c425(0x203))),_0xf1125b['includes'](_0xb9c425(0x211))&&console[_0xb9c425(0x20c)]('\x20\x20Repair\x20project:\x20\x20\x20'+CLI_BIN_NAME+_0xb9c425(0x1cd)),_0xf1125b['includes'](_0xb9c425(0x1c4))&&console[_0xb9c425(0x20c)](_0xb9c425(0x1e8)+CLI_BIN_NAME+_0xb9c425(0x1e5)));console[_0xb9c425(0x20c)](),console['log'](a30_0x2dee60[_0xb9c425(0x1a8)](_0xb9c425(0x1b4))),console[_0xb9c425(0x20c)](a30_0x2dee60[_0xb9c425(0x1c3)]('\x20\x20─'[_0xb9c425(0x1b5)](0x1e))),console[_0xb9c425(0x20c)](_0xb9c425(0x1f2)+(_0x31c526[_0xb9c425(0x212)]||a30_0x2dee60[_0xb9c425(0x20a)](_0xb9c425(0x200)))),console[_0xb9c425(0x20c)](_0xb9c425(0x216)+_0x31c526['env']),console[_0xb9c425(0x20c)]('\x20\x20region:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+normalizeLovrabetRegion(_0x31c526[_0xb9c425(0x1a2)][_0xb9c425(0x1b1)])),console[_0xb9c425(0x20c)](_0xb9c425(0x1ab)+_0x31c526[_0xb9c425(0x219)]),console[_0xb9c425(0x20c)](_0xb9c425(0x1a6)+(_0x31c526['defaultApp']||a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1bd)))),console['log'](_0xb9c425(0x1f3)+(_0x31c526[_0xb9c425(0x1d6)]||a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1bd)))),console[_0xb9c425(0x20c)](_0xb9c425(0x1e2)+(_0x31c526[_0xb9c425(0x1fa)]||a30_0x2dee60['gray'](_0xb9c425(0x215)+DEFAULT_CONFIG_VALUES['format']+')'))),console[_0xb9c425(0x20c)](_0xb9c425(0x1e4)+(_0x31c526[_0xb9c425(0x1c7)]??a30_0x2dee60[_0xb9c425(0x1c3)]('(default)'))),console['log'](_0xb9c425(0x1e6)+_0x31c526[_0xb9c425(0x217)]),console[_0xb9c425(0x20c)](_0xb9c425(0x1d4)+_0x31c526[_0xb9c425(0x1ec)]),console[_0xb9c425(0x20c)]('\x20\x20auth\x20(effective):\x20'+AUTH_MODE[_0xb9c425(0x1f8)]),console[_0xb9c425(0x20c)](_0xb9c425(0x1b2)+(_0x31c526['accessKey']?a30_0x2dee60[_0xb9c425(0x1a9)](_0xb9c425(0x1ff)+_0x31c526[_0xb9c425(0x1be)][_0xb9c425(0x1a1)]+')'):a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1bd)))),console[_0xb9c425(0x20c)](),console['log'](a30_0x2dee60['bold'](_0xb9c425(0x1b3))),console['log'](a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1fe)[_0xb9c425(0x1b5)](0x1e))),console['log'](_0xb9c425(0x1d9)+getApiDomain()),console['log'](_0xb9c425(0x213)+getUserDomain()),console[_0xb9c425(0x20c)]('\x20\x20runtimeDomain:\x20\x20\x20'+getRuntimeDomain()),console[_0xb9c425(0x20c)](_0xb9c425(0x1aa)+getSkillDomain()),console['log']('\x20\x20kbDomain:\x20\x20\x20\x20\x20\x20\x20\x20'+getKbDomain()),console[_0xb9c425(0x20c)](),console[_0xb9c425(0x20c)](a30_0x2dee60[_0xb9c425(0x1a8)]('\x20\x20Service\x20Tree')),console[_0xb9c425(0x20c)](a30_0x2dee60['gray']('\x20\x20─'[_0xb9c425(0x1b5)](0x1e)));const _0x1d9762=inspectServiceRegistry();console[_0xb9c425(0x20c)](_0xb9c425(0x207)+_0x1d9762[_0xb9c425(0x1a7)]),console[_0xb9c425(0x20c)]('\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+formatServiceRegistryStatus(_0x1d9762)),console['log'](_0xb9c425(0x20e)+_0x1d9762[_0xb9c425(0x205)]),console[_0xb9c425(0x20c)]('\x20\x20Commands:\x20\x20\x20\x20\x20\x20\x20\x20'+_0x1d9762[_0xb9c425(0x1bf)]);for(const _0x5eed5f of _0x1d9762[_0xb9c425(0x1ed)]){console[_0xb9c425(0x20c)]('\x20\x20'+(_0x5eed5f[_0xb9c425(0x1c6)]+':')['padEnd'](0x11)+'\x20'+(_0x5eed5f[_0xb9c425(0x1de)]||a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x218)))+'\x20('+_0x5eed5f[_0xb9c425(0x1bf)]+'\x20commands)'),console['log']('\x20\x20'+''[_0xb9c425(0x1b6)](0x11)+_0xb9c425(0x1d0)+_0x5eed5f[_0xb9c425(0x1ae)][_0xb9c425(0x1c9)]);}return console[_0xb9c425(0x20c)](),console[_0xb9c425(0x20c)](a30_0x2dee60[_0xb9c425(0x1a8)](_0xb9c425(0x1e0))),console[_0xb9c425(0x20c)](a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1fe)['repeat'](0x1e))),console['log'](_0xb9c425(0x208)+a30_0x2dee60[_0xb9c425(0x1a9)](AUTH_MODE['ClientAk']+_0xb9c425(0x209))),console[_0xb9c425(0x20c)](_0xb9c425(0x1f6)+a30_0x2dee60[_0xb9c425(0x1c3)](_0xb9c425(0x1c2))),console['log'](),{'ok':!![]};}function formatServiceRegistryStatus(_0x3ca502){const _0xa3c5f2=a30_0x4fe7;if(_0x3ca502[_0xa3c5f2(0x1c8)]==='ok')return a30_0x2dee60[_0xa3c5f2(0x1a9)](_0xa3c5f2(0x1bb));if(_0x3ca502['status']===_0xa3c5f2(0x1af))return a30_0x2dee60[_0xa3c5f2(0x1c3)](_0xa3c5f2(0x1d5));if(_0x3ca502[_0xa3c5f2(0x1c8)]===_0xa3c5f2(0x202))return a30_0x2dee60[_0xa3c5f2(0x20f)]('⚠\x20Empty');return a30_0x2dee60[_0xa3c5f2(0x20a)](_0xa3c5f2(0x210)+(_0x3ca502[_0xa3c5f2(0x1c0)]?':\x20'+_0x3ca502[_0xa3c5f2(0x1c0)]:''));}export const doctorDefinition={'service':a30_0xe2a714(0x1fb),'command':a30_0xe2a714(0x1f4),'description':a30_0xe2a714(0x1a5),'risk':a30_0xe2a714(0x1ea),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
1
+ const a30_0x1f92b2=a30_0x40f1;(function(_0x431fe0,_0x481e91){const _0x1ce00b=a30_0x40f1,_0x1d8cda=_0x431fe0();while(!![]){try{const _0x16dfd7=parseInt(_0x1ce00b(0x174))/0x1*(parseInt(_0x1ce00b(0x14e))/0x2)+parseInt(_0x1ce00b(0x178))/0x3+-parseInt(_0x1ce00b(0x18c))/0x4*(-parseInt(_0x1ce00b(0x180))/0x5)+parseInt(_0x1ce00b(0x167))/0x6*(parseInt(_0x1ce00b(0x19b))/0x7)+parseInt(_0x1ce00b(0x137))/0x8+parseInt(_0x1ce00b(0x13a))/0x9+-parseInt(_0x1ce00b(0x168))/0xa;if(_0x16dfd7===_0x481e91)break;else _0x1d8cda['push'](_0x1d8cda['shift']());}catch(_0xa555fb){_0x1d8cda['push'](_0x1d8cda['shift']());}}}(a30_0x331e,0x26c7e));import a30_0x1e26c0 from'chalk';function a30_0x331e(){const _0x2e69c9=['repairCommand','\x20\x20Registry:\x20\x20\x20\x20\x20\x20\x20\x20','✓\x20Loaded','current','\x20\x20Legacy\x20inherit:\x20\x20\x20','\x20commands)','\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20','length','locale','gray','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','globalConfig','\x20\x20auth\x20(effective):\x20','doctor','hasOwnProperty','message','version','500370tgfbQb','8135020gUiTqg','prototype','\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','missing','(unnamed)','\x20config\x20delete\x20inherit','\x20\x20Services:\x20\x20\x20\x20\x20\x20\x20\x20','green','installedPath','skillVersion','(missing)','\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20','33685UCTOeg','\x20\x20Package\x20Version:\x20','pageSize','(no\x20file)','104151dxUGoU','\x20\x20Config\x20Files','serviceCount','⚠\x20Empty\x20(treated\x20as\x20{})','(not\x20set)','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','⚠\x20Empty','verbose','10YNDvCS','\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','empty','bold','services','✗\x20Invalid\x20JSON','call','(not\x20registered)','arch','raw','path','join','615764QkcwWx','\x20\x20State:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','Diagnose\x20CLI\x20configuration\x20and\x20environment','status','padEnd','\x20\x20Repair\x20global:\x20\x20\x20\x20','commandCount','serviceCode','(default)','defaultApp','yellow','(not\x20found)','(none)','\x20\x20Status:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Auth','7nwLlth','reason','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','✗\x20Invalid','log','\x20\x20kbDomain:\x20\x20\x20\x20\x20\x20\x20\x20','accessKey','\x20\x20Installed\x20Path:\x20\x20','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','global','\x20\x20Service\x20Tree','red','\x20\x20kbSearchDomain:\x20\x20','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','env','registryPath','currentApp','1182240JJqGbo','\x20+\x20','name','1768176rRukbc','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','inherit','\x20\x20Built-in\x20Skill','state','Global','read','\x20\x20app\x20locale:\x20\x20\x20\x20\x20\x20','check','ignored\x20in\x20','projectConfig','project','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20Imported\x20from:\x20','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','ClientAk','\x20\x20Config\x20JSON','format','region','\x20\x20Skill\x20Version:\x20\x20\x20','12cbshNu','includes','\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','(set,\x20length=','\x20\x20API\x20Endpoints','\x20\x20region:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20─','repeat'];a30_0x331e=function(){return _0x2e69c9;};return a30_0x331e();}import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{getCliVersion}from'../utils/version.js';function a30_0x40f1(_0x69e04d,_0x4f01f9){_0x69e04d=_0x69e04d-0x127;const _0x331e96=a30_0x331e();let _0x40f1ad=_0x331e96[_0x69e04d];return _0x40f1ad;}import{getApiDomain,getKbDomain,getKbSearchDomain,getRuntimeDomain,getSkillDomain,getUserDomain}from'../constant/domain.js';import{normalizeLovrabetRegion}from'../constant/region.js';import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile,loadRawConfigLayers}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';import{inspectServiceRegistry}from'../commands/service/registry.js';import{inspectBuiltinSkill}from'../skills/builtin-skill.js';async function execute(_0x33188b){const _0x12bbb1=a30_0x40f1,_0x2d6622=getCliVersion(),_0x518ca8=buildConfigFromFlags({});await initGlobalEnvironment(_0x518ca8),console[_0x12bbb1(0x128)](),console[_0x12bbb1(0x128)](a30_0x1e26c0['bold'](CLI_BIN_NAME+'\x20doctor')),console['log'](a30_0x1e26c0['gray']('─'['repeat'](0x32))),console['log'](_0x12bbb1(0x131)+_0x2d6622),console[_0x12bbb1(0x128)](_0x12bbb1(0x150)+process[_0x12bbb1(0x166)]),console[_0x12bbb1(0x128)](_0x12bbb1(0x15c)+process['platform']+'\x20'+process[_0x12bbb1(0x188)]);const _0x4a265c=inspectBuiltinSkill();console['log'](),console[_0x12bbb1(0x128)](a30_0x1e26c0['bold'](_0x12bbb1(0x13d))),console[_0x12bbb1(0x128)](a30_0x1e26c0['gray']('\x20\x20─'[_0x12bbb1(0x155)](0x1e))),console[_0x12bbb1(0x128)](_0x12bbb1(0x18d)+(_0x4a265c[_0x12bbb1(0x13e)]===_0x12bbb1(0x159)?a30_0x1e26c0[_0x12bbb1(0x16f)]('✓\x20current'):a30_0x1e26c0[_0x12bbb1(0x12f)]('✗\x20'+_0x4a265c[_0x12bbb1(0x13e)]))),console[_0x12bbb1(0x128)](_0x12bbb1(0x175)+_0x4a265c['packageVersion']),console[_0x12bbb1(0x128)](_0x12bbb1(0x14d)+(_0x4a265c[_0x12bbb1(0x171)]||a30_0x1e26c0[_0x12bbb1(0x15f)]('(missing)'))),console['log'](_0x12bbb1(0x12b)+(_0x4a265c[_0x12bbb1(0x170)]||a30_0x1e26c0[_0x12bbb1(0x15f)]('(not\x20found)')));_0x4a265c['state']!=='current'&&console['log']('\x20\x20Repair:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x4a265c[_0x12bbb1(0x156)]);_0x4a265c[_0x12bbb1(0x19c)]&&console[_0x12bbb1(0x128)]('\x20\x20Reason:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x4a265c[_0x12bbb1(0x19c)]);console[_0x12bbb1(0x128)](),console[_0x12bbb1(0x128)](a30_0x1e26c0[_0x12bbb1(0x183)](_0x12bbb1(0x179))),console['log'](a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x154)[_0x12bbb1(0x155)](0x1e)));const _0x342a12=getGlobalConfigPath(),_0x2ddc87=getProjectConfigPath();console[_0x12bbb1(0x128)](_0x12bbb1(0x16a)+(_0x342a12||a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x197)))),console[_0x12bbb1(0x128)](_0x12bbb1(0x133)+(_0x2ddc87||a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x197)))),console[_0x12bbb1(0x128)](),console[_0x12bbb1(0x128)](a30_0x1e26c0[_0x12bbb1(0x183)](_0x12bbb1(0x14a))),console['log'](a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x154)[_0x12bbb1(0x155)](0x1e)));const _0x56bbec=(_0x1460f0,_0x3df178)=>{const _0x861460=_0x12bbb1;if(!_0x3df178){console[_0x861460(0x128)]('\x20\x20'+_0x1460f0[_0x861460(0x190)](0x11)+'\x20'+a30_0x1e26c0['gray'](_0x861460(0x177)));return;}const _0x715cd1=inspectCliConfigJsonFile(_0x3df178);if(_0x715cd1[_0x861460(0x18f)]==='ok')console[_0x861460(0x128)]('\x20\x20'+_0x1460f0[_0x861460(0x190)](0x11)+'\x20'+a30_0x1e26c0['green']('✓\x20Valid\x20JSON'));else{if(_0x715cd1[_0x861460(0x18f)]===_0x861460(0x182))console[_0x861460(0x128)]('\x20\x20'+_0x1460f0[_0x861460(0x190)](0x11)+'\x20'+a30_0x1e26c0[_0x861460(0x196)](_0x861460(0x17b)));else _0x715cd1[_0x861460(0x18f)]===_0x861460(0x16b)?console[_0x861460(0x128)]('\x20\x20'+_0x1460f0[_0x861460(0x190)](0x11)+'\x20'+a30_0x1e26c0[_0x861460(0x15f)](_0x861460(0x172))):(console[_0x861460(0x128)]('\x20\x20'+_0x1460f0[_0x861460(0x190)](0x11)+'\x20'+a30_0x1e26c0[_0x861460(0x12f)](_0x861460(0x185))),console[_0x861460(0x128)]('\x20\x20'+''['padEnd'](0x11)+'\x20'+a30_0x1e26c0[_0x861460(0x12f)](_0x715cd1[_0x861460(0x165)])));}};_0x56bbec(_0x12bbb1(0x13f),_0x342a12),_0x56bbec('Project',_0x2ddc87);const _0x40db8a=loadRawConfigLayers(),_0x2617b5=[Object[_0x12bbb1(0x169)][_0x12bbb1(0x164)][_0x12bbb1(0x186)](_0x40db8a[_0x12bbb1(0x161)],_0x12bbb1(0x13c))?_0x12bbb1(0x12d):null,Object['prototype'][_0x12bbb1(0x164)][_0x12bbb1(0x186)](_0x40db8a[_0x12bbb1(0x144)],'inherit')?_0x12bbb1(0x145):null]['filter'](Boolean);_0x2617b5['length']>0x0&&(console[_0x12bbb1(0x128)](_0x12bbb1(0x15a)+a30_0x1e26c0[_0x12bbb1(0x196)](_0x12bbb1(0x143)+_0x2617b5[_0x12bbb1(0x18b)](_0x12bbb1(0x138))+'\x20config')),_0x2617b5[_0x12bbb1(0x14f)](_0x12bbb1(0x145))&&console['log']('\x20\x20Repair\x20project:\x20\x20\x20'+CLI_BIN_NAME+_0x12bbb1(0x16d)),_0x2617b5[_0x12bbb1(0x14f)](_0x12bbb1(0x12d))&&console['log'](_0x12bbb1(0x191)+CLI_BIN_NAME+'\x20config\x20delete\x20inherit\x20--global'));console['log'](),console[_0x12bbb1(0x128)](a30_0x1e26c0['bold']('\x20\x20Merged\x20Config')),console[_0x12bbb1(0x128)](a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x154)[_0x12bbb1(0x155)](0x1e))),console[_0x12bbb1(0x128)](_0x12bbb1(0x17d)+(_0x518ca8['appCode']||a30_0x1e26c0[_0x12bbb1(0x12f)](_0x12bbb1(0x17c)))),console[_0x12bbb1(0x128)](_0x12bbb1(0x148)+_0x518ca8[_0x12bbb1(0x134)]),console[_0x12bbb1(0x128)](_0x12bbb1(0x153)+normalizeLovrabetRegion(_0x518ca8[_0x12bbb1(0x189)][_0x12bbb1(0x14c)])),console[_0x12bbb1(0x128)](_0x12bbb1(0x141)+_0x518ca8[_0x12bbb1(0x15e)]),console[_0x12bbb1(0x128)](_0x12bbb1(0x132)+(_0x518ca8[_0x12bbb1(0x195)]||a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x198)))),console[_0x12bbb1(0x128)]('\x20\x20currentApp:\x20\x20\x20\x20\x20\x20'+(_0x518ca8[_0x12bbb1(0x136)]||a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x198)))),console[_0x12bbb1(0x128)](_0x12bbb1(0x13b)+(_0x518ca8[_0x12bbb1(0x14b)]||a30_0x1e26c0[_0x12bbb1(0x15f)]('(default:\x20'+DEFAULT_CONFIG_VALUES['format']+')'))),console['log'](_0x12bbb1(0x160)+(_0x518ca8[_0x12bbb1(0x176)]??a30_0x1e26c0['gray'](_0x12bbb1(0x194)))),console[_0x12bbb1(0x128)](_0x12bbb1(0x19d)+_0x518ca8['riskLevel']),console[_0x12bbb1(0x128)](_0x12bbb1(0x146)+_0x518ca8[_0x12bbb1(0x17f)]),console['log'](_0x12bbb1(0x162)+AUTH_MODE[_0x12bbb1(0x149)]),console[_0x12bbb1(0x128)](_0x12bbb1(0x173)+(_0x518ca8[_0x12bbb1(0x12a)]?a30_0x1e26c0['green'](_0x12bbb1(0x151)+_0x518ca8[_0x12bbb1(0x12a)][_0x12bbb1(0x15d)]+')'):a30_0x1e26c0['gray']('(none)'))),console['log'](),console[_0x12bbb1(0x128)](a30_0x1e26c0['bold'](_0x12bbb1(0x152))),console[_0x12bbb1(0x128)](a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x154)[_0x12bbb1(0x155)](0x1e))),console[_0x12bbb1(0x128)](_0x12bbb1(0x12c)+getApiDomain()),console[_0x12bbb1(0x128)]('\x20\x20userDomain:\x20\x20\x20\x20\x20\x20'+getUserDomain()),console['log']('\x20\x20runtimeDomain:\x20\x20\x20'+getRuntimeDomain()),console['log']('\x20\x20skillDomain:\x20\x20\x20\x20\x20'+getSkillDomain()),console[_0x12bbb1(0x128)](_0x12bbb1(0x129)+getKbDomain());try{console[_0x12bbb1(0x128)]('\x20\x20kbSearchDomain:\x20\x20'+getKbSearchDomain());}catch{console[_0x12bbb1(0x128)](_0x12bbb1(0x130)+a30_0x1e26c0[_0x12bbb1(0x196)](_0x12bbb1(0x187)));}console[_0x12bbb1(0x128)](),console[_0x12bbb1(0x128)](a30_0x1e26c0['bold'](_0x12bbb1(0x12e))),console[_0x12bbb1(0x128)](a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x154)['repeat'](0x1e)));const _0x306f65=inspectServiceRegistry();console['log'](_0x12bbb1(0x157)+_0x306f65[_0x12bbb1(0x135)]),console['log'](_0x12bbb1(0x199)+formatServiceRegistryStatus(_0x306f65)),console[_0x12bbb1(0x128)](_0x12bbb1(0x16e)+_0x306f65[_0x12bbb1(0x17a)]),console[_0x12bbb1(0x128)]('\x20\x20Commands:\x20\x20\x20\x20\x20\x20\x20\x20'+_0x306f65[_0x12bbb1(0x192)]);for(const _0x4d458b of _0x306f65[_0x12bbb1(0x184)]){console['log']('\x20\x20'+(_0x4d458b[_0x12bbb1(0x193)]+':')[_0x12bbb1(0x190)](0x11)+'\x20'+(_0x4d458b[_0x12bbb1(0x139)]||a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x16c)))+'\x20('+_0x4d458b['commandCount']+_0x12bbb1(0x15b)),console['log']('\x20\x20'+''['padEnd'](0x11)+_0x12bbb1(0x147)+_0x4d458b['source'][_0x12bbb1(0x18a)]);}return console[_0x12bbb1(0x128)](),console['log'](a30_0x1e26c0[_0x12bbb1(0x183)](_0x12bbb1(0x19a))),console[_0x12bbb1(0x128)](a30_0x1e26c0[_0x12bbb1(0x15f)](_0x12bbb1(0x154)['repeat'](0x1e))),console[_0x12bbb1(0x128)](_0x12bbb1(0x181)+a30_0x1e26c0['green'](AUTH_MODE[_0x12bbb1(0x149)]+'\x20(accessKey)')),console[_0x12bbb1(0x128)]('\x20\x20Session\x20check:\x20\x20\x20'+a30_0x1e26c0[_0x12bbb1(0x15f)]('(removed\x20—\x20cookie\x20auth\x20disabled)')),console['log'](),{'ok':!![]};}function formatServiceRegistryStatus(_0xa6095f){const _0x23e519=a30_0x40f1;if(_0xa6095f[_0x23e519(0x18f)]==='ok')return a30_0x1e26c0['green'](_0x23e519(0x158));if(_0xa6095f[_0x23e519(0x18f)]===_0x23e519(0x16b))return a30_0x1e26c0[_0x23e519(0x15f)](_0x23e519(0x197));if(_0xa6095f['status']===_0x23e519(0x182))return a30_0x1e26c0['yellow'](_0x23e519(0x17e));return a30_0x1e26c0[_0x23e519(0x12f)](_0x23e519(0x127)+(_0xa6095f[_0x23e519(0x165)]?':\x20'+_0xa6095f[_0x23e519(0x165)]:''));}export const doctorDefinition={'service':a30_0x1f92b2(0x163),'command':a30_0x1f92b2(0x142),'description':a30_0x1f92b2(0x18e),'risk':a30_0x1f92b2(0x140),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
@@ -1 +1 @@
1
- const a31_0x2390ad=a31_0x3ca3;(function(_0x25a79c,_0x20d64e){const _0x320c60=a31_0x3ca3,_0x282b01=_0x25a79c();while(!![]){try{const _0x14e699=-parseInt(_0x320c60(0x12c))/0x1+-parseInt(_0x320c60(0x11c))/0x2*(parseInt(_0x320c60(0x122))/0x3)+-parseInt(_0x320c60(0x139))/0x4+-parseInt(_0x320c60(0x138))/0x5+-parseInt(_0x320c60(0x129))/0x6*(-parseInt(_0x320c60(0x13d))/0x7)+parseInt(_0x320c60(0x136))/0x8+parseInt(_0x320c60(0x11d))/0x9;if(_0x14e699===_0x20d64e)break;else _0x282b01['push'](_0x282b01['shift']());}catch(_0x1c549a){_0x282b01['push'](_0x282b01['shift']());}}}(a31_0x4e13,0x1fa5a));import{requireRuntimeUploadFile}from'../../commands/common/local-file.js';function a31_0x3ca3(_0x4eb0da,_0x2b716c){_0x4eb0da=_0x4eb0da-0x11b;const _0x4e1313=a31_0x4e13();let _0x3ca34c=_0x4e1313[_0x4eb0da];return _0x3ca34c;}import{queryRuntimeFileUrl,uploadRuntimeFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const FILE_FLAG={'name':'file','type':a31_0x2390ad(0x120),'required':!![],'description':a31_0x2390ad(0x127)},FILEPATH_FLAG={'name':a31_0x2390ad(0x12e),'type':'string','required':!![],'description':a31_0x2390ad(0x135)},DOWNLOAD_FLAG={'name':'download','type':a31_0x2390ad(0x132),'description':'Return\x20a\x20short-lived\x20download\x20URL\x20instead\x20of\x20a\x20short-lived\x20preview\x20URL'},LONG_TERM_FLAG={'name':'long-term','type':a31_0x2390ad(0x132),'description':a31_0x2390ad(0x13b)};function requireFilePath(_0x490d05){const _0x1cc173=a31_0x2390ad,_0x7425cf=_0x490d05['trim']();if(!_0x7425cf)throw CliErrors[_0x1cc173(0x130)](_0x1cc173(0x133));return _0x7425cf;}function a31_0x4e13(){const _0x54979f=['validation','download','boolean','filePath\x20is\x20required.','Uploaded\x20file:\x20','Runtime\x20filePath\x20returned\x20by\x20file\x20upload;\x20store\x20it\x20in\x20file\x20fields\x20and\x20durable\x20data','1800776zHOrQU','appCode','1235060NIIHZa','527464CBGqAh','path','Return\x20a\x203-year\x20URL\x20for\x20URL-only\x20content\x20embedding\x20such\x20as\x20rich\x20text,\x20Markdown,\x20or\x20HTML','query-url','52472KkYDQC','POST','2Psfakn','3819249diZYqd','build','Preview:\x20upload\x20','string','filePath','539229JTHZAN','str','read','bool','File','Path\x20to\x20the\x20local\x20file\x20to\x20upload','file','156dcyUZw','\x20to\x20runtime\x20app\x20','.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','156107erBZod','body','filepath','Query\x20a\x20short-lived\x20URL\x20for\x20preview,\x20download,\x20OCR,\x20or\x20immediate\x20access'];a31_0x4e13=function(){return _0x54979f;};return a31_0x4e13();}const fileUpload={'service':a31_0x2390ad(0x128),'command':'upload','description':'Upload\x20a\x20local\x20file\x20and\x20return\x20filePath\x20for\x20durable\x20references','risk':a31_0x2390ad(0x124),'flags':[FILE_FLAG],async 'dryRun'(_0x2f8d1c){const _0x449103=a31_0x2390ad,_0x1ab1c8=requireRuntimeUploadFile(_0x2f8d1c[_0x449103(0x123)](_0x449103(0x128)),_0x449103(0x126));return dryRun(_0x449103(0x11b),'/client/uploadFile')[_0x449103(0x12d)]({'appCode':_0x2f8d1c['appCode'],'multipart':{'file':_0x1ab1c8}})['description'](_0x449103(0x11f)+_0x1ab1c8[_0x449103(0x13a)]+_0x449103(0x12a)+_0x2f8d1c[_0x449103(0x137)])[_0x449103(0x11e)]();},async 'execute'(_0x2e5010){const _0x5c2b28=a31_0x2390ad,_0x5b90fb=requireRuntimeUploadFile(_0x2e5010[_0x5c2b28(0x123)](_0x5c2b28(0x128)),_0x5c2b28(0x126)),_0x414d8a=await uploadRuntimeFile(_0x2e5010[_0x5c2b28(0x137)],_0x5b90fb[_0x5c2b28(0x13a)]);return{'ok':!![],'data':_0x414d8a,'message':_0x414d8a[_0x5c2b28(0x121)]?_0x5c2b28(0x134)+_0x414d8a[_0x5c2b28(0x121)]+_0x5c2b28(0x12b):'Uploaded\x20file.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.'};}},fileQueryUrl={'service':'file','command':a31_0x2390ad(0x13c),'description':a31_0x2390ad(0x12f),'risk':'read','flags':[FILEPATH_FLAG,DOWNLOAD_FLAG,LONG_TERM_FLAG],async 'execute'(_0x124e16){const _0x34e131=a31_0x2390ad,_0x218940=requireFilePath(_0x124e16[_0x34e131(0x123)](_0x34e131(0x12e))),_0x5ac770=await queryRuntimeFileUrl(_0x218940,{'download':_0x124e16[_0x34e131(0x125)](_0x34e131(0x131)),'longTerm':_0x124e16['bool']('long-term')});return{'ok':!![],'data':_0x5ac770};}};export const fileDefinitions=[fileUpload,fileQueryUrl];
1
+ const a31_0x58893e=a31_0x5cc0;(function(_0x381d1b,_0x58f6f4){const _0x414135=a31_0x5cc0,_0x2040ad=_0x381d1b();while(!![]){try{const _0x4f4d8d=-parseInt(_0x414135(0x183))/0x1*(-parseInt(_0x414135(0x174))/0x2)+parseInt(_0x414135(0x169))/0x3*(-parseInt(_0x414135(0x16f))/0x4)+parseInt(_0x414135(0x177))/0x5*(parseInt(_0x414135(0x175))/0x6)+parseInt(_0x414135(0x176))/0x7+parseInt(_0x414135(0x17d))/0x8+parseInt(_0x414135(0x17c))/0x9+-parseInt(_0x414135(0x167))/0xa*(parseInt(_0x414135(0x179))/0xb);if(_0x4f4d8d===_0x58f6f4)break;else _0x2040ad['push'](_0x2040ad['shift']());}catch(_0x17a872){_0x2040ad['push'](_0x2040ad['shift']());}}}(a31_0xa0ae,0xa0f14));import{requireRuntimeUploadFile}from'../../commands/common/local-file.js';function a31_0x5cc0(_0x2f7cb0,_0x367cff){_0x2f7cb0=_0x2f7cb0-0x161;const _0xa0ae6c=a31_0xa0ae();let _0x5cc0d3=_0xa0ae6c[_0x2f7cb0];return _0x5cc0d3;}import{queryRuntimeFileUrl,uploadRuntimeFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const FILE_FLAG={'name':a31_0x58893e(0x17f),'type':'string','required':!![],'description':a31_0x58893e(0x173)},FILEPATH_FLAG={'name':'filepath','type':'string','required':!![],'description':'Runtime\x20filePath\x20returned\x20by\x20file\x20upload;\x20store\x20it\x20in\x20file\x20fields\x20and\x20durable\x20data'},DOWNLOAD_FLAG={'name':a31_0x58893e(0x16c),'type':'boolean','description':'Return\x20a\x20short-lived\x20download\x20URL\x20instead\x20of\x20a\x20short-lived\x20preview\x20URL'},LONG_TERM_FLAG={'name':a31_0x58893e(0x17a),'type':a31_0x58893e(0x184),'description':a31_0x58893e(0x166)};function requireFilePath(_0x31b02d){const _0x4cd100=a31_0x58893e,_0xa2e09c=_0x31b02d[_0x4cd100(0x163)]();if(!_0xa2e09c)throw CliErrors['validation']('filePath\x20is\x20required.');return _0xa2e09c;}function a31_0xa0ae(){const _0x3bf380=['filepath','Path\x20to\x20the\x20local\x20file\x20to\x20upload','302wVYNco','6XAoSwd','3954804rKWAFn','5332110CyOTob','Preview:\x20upload\x20','4279TCfDZt','long-term','filePath','9663336FmbuQk','5672888mNQCPQ','upload','file','build','\x20to\x20runtime\x20app\x20','Uploaded\x20file.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','2166wrosMO','boolean','.\x20Store\x20filePath\x20for\x20durable\x20references;\x20use\x20file\x20query-url\x20for\x20short-lived\x20access.','bool','trim','appCode','/client/uploadFile','Return\x20a\x203-year\x20URL\x20for\x20URL-only\x20content\x20embedding\x20such\x20as\x20rich\x20text,\x20Markdown,\x20or\x20HTML','58210etASNk','path','54YSVRoh','read','query-url','download','str','body','181708EvpvTJ','File','Query\x20a\x20short-lived\x20URL\x20for\x20preview,\x20download,\x20OCR,\x20or\x20immediate\x20access'];a31_0xa0ae=function(){return _0x3bf380;};return a31_0xa0ae();}const fileUpload={'service':a31_0x58893e(0x17f),'command':a31_0x58893e(0x17e),'description':'Upload\x20a\x20local\x20file\x20and\x20return\x20filePath\x20for\x20durable\x20references','risk':a31_0x58893e(0x16a),'flags':[FILE_FLAG],async 'dryRun'(_0x477e23){const _0x35c102=a31_0x58893e,_0x25557a=requireRuntimeUploadFile(_0x477e23[_0x35c102(0x16d)]('file'),_0x35c102(0x170));return dryRun('POST',_0x35c102(0x165))[_0x35c102(0x16e)]({'appCode':_0x477e23['appCode'],'multipart':{'file':_0x25557a}})['description'](_0x35c102(0x178)+_0x25557a['path']+_0x35c102(0x181)+_0x477e23[_0x35c102(0x164)])[_0x35c102(0x180)]();},async 'execute'(_0x13e682){const _0x3cebf8=a31_0x58893e,_0x1089ac=requireRuntimeUploadFile(_0x13e682[_0x3cebf8(0x16d)]('file'),'File'),_0x29388a=await uploadRuntimeFile(_0x13e682['appCode'],_0x1089ac[_0x3cebf8(0x168)]);return{'ok':!![],'data':_0x29388a,'message':_0x29388a[_0x3cebf8(0x17b)]?'Uploaded\x20file:\x20'+_0x29388a['filePath']+_0x3cebf8(0x161):_0x3cebf8(0x182)};}},fileQueryUrl={'service':a31_0x58893e(0x17f),'command':a31_0x58893e(0x16b),'description':a31_0x58893e(0x171),'risk':a31_0x58893e(0x16a),'flags':[FILEPATH_FLAG,DOWNLOAD_FLAG,LONG_TERM_FLAG],async 'execute'(_0x21a573){const _0x45c8d8=a31_0x58893e,_0x5ac0f9=requireFilePath(_0x21a573[_0x45c8d8(0x16d)](_0x45c8d8(0x172))),_0x505419=await queryRuntimeFileUrl(_0x5ac0f9,{'download':_0x21a573[_0x45c8d8(0x162)](_0x45c8d8(0x16c)),'longTerm':_0x21a573[_0x45c8d8(0x162)](_0x45c8d8(0x17a))});return{'ok':!![],'data':_0x505419};}};export const fileDefinitions=[fileUpload,fileQueryUrl];
@@ -1 +1 @@
1
- const a32_0xd89d25=a32_0x2f1f;(function(_0x1e8521,_0x52a475){const _0x162505=a32_0x2f1f,_0x47728f=_0x1e8521();while(!![]){try{const _0x79615a=parseInt(_0x162505(0xdc))/0x1+-parseInt(_0x162505(0xe2))/0x2*(-parseInt(_0x162505(0xca))/0x3)+parseInt(_0x162505(0xdb))/0x4+-parseInt(_0x162505(0xe4))/0x5+parseInt(_0x162505(0xf1))/0x6+-parseInt(_0x162505(0xf0))/0x7*(parseInt(_0x162505(0xd5))/0x8)+-parseInt(_0x162505(0xcc))/0x9*(parseInt(_0x162505(0xed))/0xa);if(_0x79615a===_0x52a475)break;else _0x47728f['push'](_0x47728f['shift']());}catch(_0x2e782c){_0x47728f['push'](_0x47728f['shift']());}}}(a32_0x4b21,0xec864));function a32_0x2f1f(_0x5317c0,_0x5ccbd9){_0x5317c0=_0x5317c0-0xc6;const _0x4b217d=a32_0x4b21();let _0x2f1f37=_0x4b217d[_0x5317c0];return _0x2f1f37;}import{existsSync,readFileSync}from'node:fs';import{resolve,isAbsolute}from'node:path';import{CliErrors}from'../errors.js';function a32_0x4b21(){const _0x48b7c8=['Legacy\x20/\x20multi-app\x20.rabetbase.json\x20is\x20no\x20longer\x20supported\x20for\x20import.','2567240IRgJtU','995866YpDkOr','defaultApp','Provide\x20--appcode\x20<code>\x20or\x20use\x20an\x20upgraded\x20.rabetbase.json\x20with\x20top-level\x20appcode.\x20Legacy\x20files\x20must\x20be\x20upgraded\x20first\x20with\x20`rabetbase\x20project\x20upgrade`.','join','\x20\x20default:\x20','Override\x20imported\x20default\x20env','348520YJqIXf','object','144775DkRGAF','Invalid\x20env\x20\x22','entries','global','Skip\x20confirmation\x20when\x20overwriting','boolean','Source\x20file\x20not\x20found:\x20',')\x20instead\x20of\x20project','parse','10iVLboz','Run\x20`rabetbase\x20project\x20upgrade`\x20first,\x20then\x20retry\x20`lovrabet\x20app\x20import`.','log','9282763NhfgJH','6930270fjEOPC','file','message','apps','Write\x20to\x20global\x20(~/','6VVGYkn','Failed\x20to\x20parse\x20source\x20file:\x20','7356357TyTITR','project','env','validation','Import\x20from\x20a\x20.rabetbase.json\x20file\x20path','yes','string','riskLevel','Imported\x20from\x20','8ZdAXLZ','app','appcode','utf8','newConfigFileName'];a32_0x4b21=function(){return _0x48b7c8;};return a32_0x4b21();}import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../constant/env.js';import{IMPORTABLE_RUNTIME_CONFIG_KEYS}from'../config/schema.js';import{resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../context.js';import{PRODUCT_CONFIG}from'../constant/product.js';export const appImportFlagDefs=[{'name':a32_0xd89d25(0xc6),'type':a32_0xd89d25(0xd2),'description':a32_0xd89d25(0xd0),'required':!![]},{'name':'appcode','type':a32_0xd89d25(0xd2),'description':'Override\x20imported\x20default\x20appcode'},{'name':'env','type':a32_0xd89d25(0xd2),'description':a32_0xd89d25(0xe1),'enum':[...RUNTIME_ENV_VALUES]},{'name':a32_0xd89d25(0xe7),'type':'boolean','description':a32_0xd89d25(0xc9)+PRODUCT_CONFIG[a32_0xd89d25(0xd9)]+a32_0xd89d25(0xeb),'default':![]},{'name':'yes','type':a32_0xd89d25(0xe9),'description':a32_0xd89d25(0xe8),'default':![]}];export async function runAppImport(_0x1363cb){const _0x5bfb80=a32_0xd89d25,_0x353f90=_0x1363cb['global']?_0x5bfb80(0xe7):_0x5bfb80(0xcd),_0x1110ab=resolveWriteConfigPath(_0x353f90);await runFromImport(_0x1363cb,_0x1110ab);}async function runFromImport(_0x205906,_0x574a12){const _0x4d1810=a32_0xd89d25,_0x20f7c5=resolveFilePath(_0x205906[_0x4d1810(0xc6)]);if(!existsSync(_0x20f7c5))throw CliErrors[_0x4d1810(0xcf)](_0x4d1810(0xea)+_0x20f7c5);const _0x5a0ffb=readSourceFile(_0x20f7c5),_0x1a5178=convertToRuntimeConfig(_0x5a0ffb);_0x205906['appcode']&&(_0x1a5178[_0x4d1810(0xd7)]=String(_0x205906[_0x4d1810(0xd7)]));_0x205906[_0x4d1810(0xce)]&&(_0x1a5178[_0x4d1810(0xce)]=resolveImportEnv(_0x205906));if(!_0x1a5178['appcode'])throw CliErrors[_0x4d1810(0xcf)]('Source\x20file\x20does\x20not\x20contain\x20an\x20importable\x20appcode.',_0x4d1810(0xde));await writeImportConfig(_0x574a12,_0x1a5178,_0x205906),console[_0x4d1810(0xef)](_0x4d1810(0xd4)+_0x20f7c5),console[_0x4d1810(0xef)]('\x20\x20config:\x20\x20'+_0x574a12),console[_0x4d1810(0xef)]('\x20\x20appcode:\x20'+_0x1a5178['appcode']);if(_0x1a5178[_0x4d1810(0xdd)])console[_0x4d1810(0xef)](_0x4d1810(0xe0)+_0x1a5178['defaultApp']);}function convertToRuntimeConfig(_0x1724fd){const _0x384f40=a32_0xd89d25;if(_0x1724fd[_0x384f40(0xc8)]&&typeof _0x1724fd[_0x384f40(0xc8)]===_0x384f40(0xe3))throw CliErrors[_0x384f40(0xcf)](_0x384f40(0xda),_0x384f40(0xee));const _0x292525={};for(const _0x4caa10 of IMPORTABLE_RUNTIME_CONFIG_KEYS){_0x1724fd[_0x4caa10]!==undefined&&(_0x292525[_0x4caa10]=_0x1724fd[_0x4caa10]);}return!_0x292525[_0x384f40(0xd3)]&&(_0x292525[_0x384f40(0xd3)]=DEFAULT_CONFIG_VALUES[_0x384f40(0xd3)]),_0x292525;}async function writeImportConfig(_0x3a012a,_0xf16109,_0x18fcd3){const _0x502252=a32_0xd89d25;let _0x34b1bf={};existsSync(_0x3a012a)&&!_0x18fcd3[_0x502252(0xd1)]&&(_0x34b1bf=readConfigFile(_0x3a012a));for(const [_0x39c023,_0x2e7b35]of Object[_0x502252(0xe6)](_0xf16109)){_0x2e7b35!==undefined&&(_0x34b1bf[_0x39c023]=_0x2e7b35);}if(_0x34b1bf[_0x502252(0xd6)])delete _0x34b1bf['app'];writeConfigFile(_0x3a012a,_0x34b1bf);}function resolveFilePath(_0x54f1f3){return isAbsolute(_0x54f1f3)?_0x54f1f3:resolve(process['cwd'](),_0x54f1f3);}function readSourceFile(_0x177af1){const _0x5eb599=a32_0xd89d25;try{const _0x84175=readFileSync(_0x177af1,{'encoding':_0x5eb599(0xd8)});return JSON[_0x5eb599(0xec)](_0x84175);}catch(_0x58c8d8){throw CliErrors[_0x5eb599(0xcf)](_0x5eb599(0xcb)+_0x58c8d8[_0x5eb599(0xc7)]);}}function resolveImportEnv(_0x45d8fc){const _0x4be52a=a32_0xd89d25,_0x3ffe01=_0x45d8fc['env'];if(_0x3ffe01===undefined||_0x3ffe01==='')return DEFAULT_CONFIG_VALUES['env'];if(!RUNTIME_ENV_VALUES['includes'](_0x3ffe01))throw CliErrors[_0x4be52a(0xcf)](_0x4be52a(0xe5)+_0x3ffe01+'\x22.\x20Allowed:\x20'+RUNTIME_ENV_VALUES[_0x4be52a(0xdf)](',\x20'));return _0x3ffe01;}
1
+ const a32_0xd783aa=a32_0x22da;(function(_0xa0223c,_0x3c018c){const _0x2dd19d=a32_0x22da,_0x4c355b=_0xa0223c();while(!![]){try{const _0xb58d51=-parseInt(_0x2dd19d(0x124))/0x1*(parseInt(_0x2dd19d(0x12e))/0x2)+parseInt(_0x2dd19d(0x115))/0x3*(parseInt(_0x2dd19d(0x133))/0x4)+-parseInt(_0x2dd19d(0x137))/0x5*(parseInt(_0x2dd19d(0x10b))/0x6)+parseInt(_0x2dd19d(0x11e))/0x7+parseInt(_0x2dd19d(0x135))/0x8+parseInt(_0x2dd19d(0x11a))/0x9*(-parseInt(_0x2dd19d(0x12a))/0xa)+-parseInt(_0x2dd19d(0x12c))/0xb*(-parseInt(_0x2dd19d(0x134))/0xc);if(_0xb58d51===_0x3c018c)break;else _0x4c355b['push'](_0x4c355b['shift']());}catch(_0x280660){_0x4c355b['push'](_0x4c355b['shift']());}}}(a32_0x350e,0x33bdf));import{existsSync,readFileSync}from'node:fs';function a32_0x22da(_0x2b8f76,_0x137ed8){_0x2b8f76=_0x2b8f76-0x10b;const _0x350ead=a32_0x350e();let _0x22da54=_0x350ead[_0x2b8f76];return _0x22da54;}function a32_0x350e(){const _0x19c0c4=['validation','\x20\x20config:\x20\x20','Imported\x20from\x20','1012959MqugDg','entries','utf8','env','1393854AJSZCo','project','Legacy\x20/\x20multi-app\x20.rabetbase.json\x20is\x20no\x20longer\x20supported\x20for\x20import.','Invalid\x20env\x20\x22','yes','file','1eYWTFw','log','Import\x20from\x20a\x20.rabetbase.json\x20file\x20path','Run\x20`rabetbase\x20project\x20upgrade`\x20first,\x20then\x20retry\x20`lovrabet\x20app\x20import`.','join','Failed\x20to\x20parse\x20source\x20file:\x20','30qCiXZB','newConfigFileName','11ByzsDN','string','532522VNIAHl','includes','\x20\x20default:\x20','Override\x20imported\x20default\x20appcode','global','1696wKusnN','5933364jfKtFr','96368iWJsqb','Skip\x20confirmation\x20when\x20overwriting','527910oEIqNe','\x22.\x20Allowed:\x20','defaultApp','6yPqjMd',')\x20instead\x20of\x20project','message','appcode','apps','riskLevel','app','Source\x20file\x20not\x20found:\x20','Provide\x20--appcode\x20<code>\x20or\x20use\x20an\x20upgraded\x20.rabetbase.json\x20with\x20top-level\x20appcode.\x20Legacy\x20files\x20must\x20be\x20upgraded\x20first\x20with\x20`rabetbase\x20project\x20upgrade`.','parse','1527tgkDmI','boolean'];a32_0x350e=function(){return _0x19c0c4;};return a32_0x350e();}import{resolve,isAbsolute}from'node:path';import{CliErrors}from'../errors.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../constant/env.js';import{IMPORTABLE_RUNTIME_CONFIG_KEYS}from'../config/schema.js';import{resolveWriteConfigPath,readConfigFile,writeConfigFile}from'../context.js';import{PRODUCT_CONFIG}from'../constant/product.js';export const appImportFlagDefs=[{'name':a32_0xd783aa(0x123),'type':a32_0xd783aa(0x12d),'description':a32_0xd783aa(0x126),'required':!![]},{'name':a32_0xd783aa(0x10e),'type':a32_0xd783aa(0x12d),'description':a32_0xd783aa(0x131)},{'name':a32_0xd783aa(0x11d),'type':'string','description':'Override\x20imported\x20default\x20env','enum':[...RUNTIME_ENV_VALUES]},{'name':'global','type':a32_0xd783aa(0x116),'description':'Write\x20to\x20global\x20(~/'+PRODUCT_CONFIG[a32_0xd783aa(0x12b)]+a32_0xd783aa(0x10c),'default':![]},{'name':a32_0xd783aa(0x122),'type':a32_0xd783aa(0x116),'description':a32_0xd783aa(0x136),'default':![]}];export async function runAppImport(_0x3dad4e){const _0x4f0a05=a32_0xd783aa,_0x56d4ff=_0x3dad4e['global']?_0x4f0a05(0x132):_0x4f0a05(0x11f),_0x7a1df5=resolveWriteConfigPath(_0x56d4ff);await runFromImport(_0x3dad4e,_0x7a1df5);}async function runFromImport(_0x472b95,_0x310432){const _0x5889c8=a32_0xd783aa,_0x5da3d7=resolveFilePath(_0x472b95[_0x5889c8(0x123)]);if(!existsSync(_0x5da3d7))throw CliErrors[_0x5889c8(0x117)](_0x5889c8(0x112)+_0x5da3d7);const _0x433362=readSourceFile(_0x5da3d7),_0x3897ff=convertToRuntimeConfig(_0x433362);_0x472b95[_0x5889c8(0x10e)]&&(_0x3897ff['appcode']=String(_0x472b95['appcode']));_0x472b95[_0x5889c8(0x11d)]&&(_0x3897ff['env']=resolveImportEnv(_0x472b95));if(!_0x3897ff[_0x5889c8(0x10e)])throw CliErrors[_0x5889c8(0x117)]('Source\x20file\x20does\x20not\x20contain\x20an\x20importable\x20appcode.',_0x5889c8(0x113));await writeImportConfig(_0x310432,_0x3897ff,_0x472b95),console[_0x5889c8(0x125)](_0x5889c8(0x119)+_0x5da3d7),console[_0x5889c8(0x125)](_0x5889c8(0x118)+_0x310432),console[_0x5889c8(0x125)]('\x20\x20appcode:\x20'+_0x3897ff[_0x5889c8(0x10e)]);if(_0x3897ff[_0x5889c8(0x139)])console['log'](_0x5889c8(0x130)+_0x3897ff[_0x5889c8(0x139)]);}function convertToRuntimeConfig(_0x33f7a0){const _0x5e6170=a32_0xd783aa;if(_0x33f7a0[_0x5e6170(0x10f)]&&typeof _0x33f7a0[_0x5e6170(0x10f)]==='object')throw CliErrors[_0x5e6170(0x117)](_0x5e6170(0x120),_0x5e6170(0x127));const _0x893170={};for(const _0x5dbc62 of IMPORTABLE_RUNTIME_CONFIG_KEYS){_0x33f7a0[_0x5dbc62]!==undefined&&(_0x893170[_0x5dbc62]=_0x33f7a0[_0x5dbc62]);}return!_0x893170[_0x5e6170(0x110)]&&(_0x893170[_0x5e6170(0x110)]=DEFAULT_CONFIG_VALUES[_0x5e6170(0x110)]),_0x893170;}async function writeImportConfig(_0x513397,_0x24c54e,_0x23c12a){const _0x16fae6=a32_0xd783aa;let _0x1b8edc={};existsSync(_0x513397)&&!_0x23c12a[_0x16fae6(0x122)]&&(_0x1b8edc=readConfigFile(_0x513397));for(const [_0x44c02a,_0x43f0b8]of Object[_0x16fae6(0x11b)](_0x24c54e)){_0x43f0b8!==undefined&&(_0x1b8edc[_0x44c02a]=_0x43f0b8);}if(_0x1b8edc['app'])delete _0x1b8edc[_0x16fae6(0x111)];writeConfigFile(_0x513397,_0x1b8edc);}function resolveFilePath(_0x247b59){return isAbsolute(_0x247b59)?_0x247b59:resolve(process['cwd'](),_0x247b59);}function readSourceFile(_0xe798dd){const _0x3832af=a32_0xd783aa;try{const _0x51b99c=readFileSync(_0xe798dd,{'encoding':_0x3832af(0x11c)});return JSON[_0x3832af(0x114)](_0x51b99c);}catch(_0x145b23){throw CliErrors['validation'](_0x3832af(0x129)+_0x145b23[_0x3832af(0x10d)]);}}function resolveImportEnv(_0x1b6ea3){const _0x77e638=a32_0xd783aa,_0x2d5148=_0x1b6ea3['env'];if(_0x2d5148===undefined||_0x2d5148==='')return DEFAULT_CONFIG_VALUES[_0x77e638(0x11d)];if(!RUNTIME_ENV_VALUES[_0x77e638(0x12f)](_0x2d5148))throw CliErrors[_0x77e638(0x117)](_0x77e638(0x121)+_0x2d5148+_0x77e638(0x138)+RUNTIME_ENV_VALUES[_0x77e638(0x128)](',\x20'));return _0x2d5148;}
@@ -1 +1 @@
1
- function a33_0xe607(){const _0x2f9fe9=['Path\x20to\x20a\x20local\x20UTF-8\x20text\x20or\x20Markdown\x20file','verbose','Preview:\x20create\x20personal\x20knowledge-base\x20entry\x20\x22','string','isFinite','/client/knowledge-base/personal/create','scope','Personal\x20knowledge-base\x20entry\x20title','content','search','--topk\x20must\x20be\x20a\x20positive\x20number.','Maximum\x20number\x20of\x20search\x20hits\x20to\x20return','map','str','updateTime','topk','createTime','Update\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','ragStatus','title','bool','flag','appCode','query','1278875ENBczE','9294soMXpm','File\x20path\x20is\x20required.','write','POST','isFile','309191PttGLv','4239496JVuFwz','create','validation','/client/knowledge-base/personal/','utf8','length','3027270mdGrJo','Search\x20query\x20for\x20visible\x20company\x20and\x20personal\x20knowledge','list','docId','file','Search\x20visible\x20company\x20and\x20personal\x20knowledge\x20base\x20content','1328732Auptpz','Updated\x20KB\x20entry\x20','9TcNfYV','userId','336fXTDrs','trim','File\x20is\x20not\x20a\x20regular\x20file:\x20','3379663dWqgRo','Personal\x20knowledge-base\x20entry\x20ID','weightedScore','update','Created\x20KB\x20entry\x20','build','metadata','version','body','File\x20not\x20found:\x20','description','Create\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','num','Show\x20one\x20personal\x20knowledge-base\x20entry\x20by\x20id','ragErrorMessage','read'];a33_0xe607=function(){return _0x2f9fe9;};return a33_0xe607();}const a33_0x115f9b=a33_0x40e3;(function(_0x346f15,_0x4c4619){const _0x9a9598=a33_0x40e3,_0x593242=_0x346f15();while(!![]){try{const _0x341a19=parseInt(_0x9a9598(0x154))/0x1+parseInt(_0x9a9598(0x165))/0x2*(parseInt(_0x9a9598(0x14f))/0x3)+-parseInt(_0x9a9598(0x161))/0x4+parseInt(_0x9a9598(0x14e))/0x5+-parseInt(_0x9a9598(0x15b))/0x6+-parseInt(_0x9a9598(0x168))/0x7+-parseInt(_0x9a9598(0x155))/0x8*(-parseInt(_0x9a9598(0x163))/0x9);if(_0x341a19===_0x4c4619)break;else _0x593242['push'](_0x593242['shift']());}catch(_0x21f3b3){_0x593242['push'](_0x593242['shift']());}}}(a33_0xe607,0x48396));import{existsSync,readFileSync,statSync}from'node:fs';import{createPersonalKnowledgeBaseItem,getPersonalKnowledgeBaseItem,listPersonalKnowledgeBaseItems,searchKnowledgeBase,updatePersonalKnowledgeBaseItem}from'../../core/api-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';function a33_0x40e3(_0x23db5b,_0x52d31b){_0x23db5b=_0x23db5b-0x137;const _0xe607be=a33_0xe607();let _0x40e3a3=_0xe607be[_0x23db5b];return _0x40e3a3;}const TITLE_FLAG={'name':a33_0x115f9b(0x149),'type':a33_0x115f9b(0x139),'required':!![],'description':a33_0x115f9b(0x13d)},FILE_FLAG={'name':a33_0x115f9b(0x15f),'type':a33_0x115f9b(0x139),'required':!![],'description':a33_0x115f9b(0x178)},QUERY_FLAG={'name':a33_0x115f9b(0x14d),'type':'string','required':!![],'description':a33_0x115f9b(0x15c)},TOPK_FLAG={'name':'topk','type':'number','description':a33_0x115f9b(0x141)};function readKnowledgeFile(_0x4cddd1){const _0x19a4b8=a33_0x115f9b;if(!_0x4cddd1)throw CliErrors[_0x19a4b8(0x157)](_0x19a4b8(0x150));if(!existsSync(_0x4cddd1))throw CliErrors[_0x19a4b8(0x157)](_0x19a4b8(0x171)+_0x4cddd1);if(!statSync(_0x4cddd1)[_0x19a4b8(0x153)]())throw CliErrors[_0x19a4b8(0x157)](_0x19a4b8(0x167)+_0x4cddd1);return readFileSync(_0x4cddd1,_0x19a4b8(0x159));}function summarizePersonalItem(_0x5f51ab){const _0x359fd7=a33_0x115f9b;return{'id':_0x5f51ab['id'],'title':_0x5f51ab[_0x359fd7(0x149)],'version':_0x5f51ab[_0x359fd7(0x16f)],'ragStatus':_0x5f51ab[_0x359fd7(0x148)],'ragErrorMessage':_0x5f51ab[_0x359fd7(0x176)],'updateTime':_0x5f51ab[_0x359fd7(0x144)]};}function detailPersonalItem(_0x31373e){const _0x15b52d=a33_0x115f9b;return{'id':_0x31373e['id'],'appCode':_0x31373e[_0x15b52d(0x14c)],'scope':_0x31373e['scope'],'userId':_0x31373e[_0x15b52d(0x164)],'title':_0x31373e['title'],'content':_0x31373e[_0x15b52d(0x13e)]??'','version':_0x31373e[_0x15b52d(0x16f)],'ragStatus':_0x31373e['ragStatus'],'ragErrorMessage':_0x31373e[_0x15b52d(0x176)],'createTime':_0x31373e[_0x15b52d(0x146)],'updateTime':_0x31373e[_0x15b52d(0x144)]};}function summarizeSearchHit(_0x8313e1){const _0x311dfc=a33_0x115f9b;return{'scope':_0x8313e1[_0x311dfc(0x13c)],'title':_0x8313e1['title'],'docId':_0x8313e1[_0x311dfc(0x15e)],'score':_0x8313e1['score'],'weightedScore':_0x8313e1[_0x311dfc(0x16a)],'content':_0x8313e1['content'],'metadata':_0x8313e1[_0x311dfc(0x16e)]};}function readTopK(_0x5e4317){const _0x42d1b5=a33_0x115f9b,_0x3f5d1a=_0x5e4317[_0x42d1b5(0x14b)](_0x42d1b5(0x145));if(_0x3f5d1a===undefined||_0x3f5d1a===null||_0x3f5d1a==='')return undefined;const _0x14bfcc=_0x5e4317[_0x42d1b5(0x174)](_0x42d1b5(0x145));if(!Number[_0x42d1b5(0x13a)](_0x14bfcc)||_0x14bfcc<0x1)throw CliErrors[_0x42d1b5(0x157)](_0x42d1b5(0x140));return _0x14bfcc;}const kbList={'service':'kb','command':a33_0x115f9b(0x15d),'description':'List\x20personal\x20knowledge-base\x20entries\x20for\x20the\x20current\x20app','risk':a33_0x115f9b(0x177),'flags':[VERBOSE_FLAG],async 'execute'(_0x850bb1){const _0x29923d=a33_0x115f9b,_0x3ded7a=await listPersonalKnowledgeBaseItems(_0x850bb1[_0x29923d(0x14c)]);if(_0x850bb1[_0x29923d(0x14a)](_0x29923d(0x137)))return{'ok':!![],'data':{'total':_0x3ded7a[_0x29923d(0x15a)],'items':_0x3ded7a}};return{'ok':!![],'data':{'total':_0x3ded7a[_0x29923d(0x15a)],'items':_0x3ded7a[_0x29923d(0x142)](summarizePersonalItem)}};}},kbDetail={'service':'kb','command':'detail','description':a33_0x115f9b(0x175),'risk':a33_0x115f9b(0x177),'flags':[{...ID_FLAG,'description':a33_0x115f9b(0x169)}],async 'execute'(_0x47ed38){const _0x59c885=a33_0x115f9b,_0x5e47a0=await getPersonalKnowledgeBaseItem(_0x47ed38[_0x59c885(0x174)]('id'),_0x47ed38[_0x59c885(0x14c)]);return{'ok':!![],'data':detailPersonalItem(_0x5e47a0)};}},kbCreate={'service':'kb','command':a33_0x115f9b(0x156),'description':a33_0x115f9b(0x173),'risk':a33_0x115f9b(0x151),'confirmationDescription':'Saves\x20local\x20file\x20content\x20as\x20a\x20personal\x20knowledge-base\x20entry\x20and\x20starts\x20retrieval\x20sync.','flags':[TITLE_FLAG,FILE_FLAG],async 'execute'(_0x202f06){const _0x53d09c=a33_0x115f9b,_0x5a2447=_0x202f06[_0x53d09c(0x143)](_0x53d09c(0x149)),_0x2df734=readKnowledgeFile(_0x202f06['str'](_0x53d09c(0x15f))),_0x171527=await createPersonalKnowledgeBaseItem(_0x202f06[_0x53d09c(0x14c)],{'title':_0x5a2447,'content':_0x2df734});return{'ok':!![],'data':summarizePersonalItem(_0x171527),'message':_0x53d09c(0x16c)+_0x171527['id']+'\x20('+_0x171527[_0x53d09c(0x149)]+')'};},async 'dryRun'(_0x330eb2){const _0x2f498e=a33_0x115f9b,_0x3f1ef4=_0x330eb2['str']('title'),_0x6c4124=readKnowledgeFile(_0x330eb2[_0x2f498e(0x143)]('file'));return dryRun(_0x2f498e(0x152),_0x2f498e(0x13b))['body']({'appCode':_0x330eb2[_0x2f498e(0x14c)],'title':_0x3f1ef4,'content':_0x6c4124})[_0x2f498e(0x172)](_0x2f498e(0x138)+_0x3f1ef4+'\x22')[_0x2f498e(0x16d)]();}},kbUpdate={'service':'kb','command':a33_0x115f9b(0x16b),'description':a33_0x115f9b(0x147),'risk':'write','confirmationDescription':'Replaces\x20the\x20personal\x20knowledge-base\x20entry\x20body\x20with\x20local\x20file\x20content\x20and\x20triggers\x20retrieval\x20sync.','flags':[{...ID_FLAG,'description':'Personal\x20knowledge-base\x20entry\x20ID'},{...TITLE_FLAG,'required':![],'description':'Override\x20the\x20existing\x20entry\x20title'},FILE_FLAG],async 'execute'(_0x34a9c4){const _0x175df4=a33_0x115f9b,_0x259f1c=_0x34a9c4['num']('id'),_0x4c146b=readKnowledgeFile(_0x34a9c4[_0x175df4(0x143)]('file')),_0x5c80bf=_0x34a9c4[_0x175df4(0x143)](_0x175df4(0x149))||(await getPersonalKnowledgeBaseItem(_0x259f1c,_0x34a9c4[_0x175df4(0x14c)]))[_0x175df4(0x149)],_0x3d3b6b=await updatePersonalKnowledgeBaseItem(_0x259f1c,_0x34a9c4['appCode'],{'title':_0x5c80bf,'content':_0x4c146b});return{'ok':!![],'data':summarizePersonalItem(_0x3d3b6b),'message':_0x175df4(0x162)+_0x3d3b6b['id']+'\x20('+_0x3d3b6b['title']+')'};},async 'dryRun'(_0x16884c){const _0x56a4c1=a33_0x115f9b,_0x5193cf=_0x16884c['num']('id'),_0x213760=readKnowledgeFile(_0x16884c[_0x56a4c1(0x143)](_0x56a4c1(0x15f))),_0x12ff68=_0x16884c[_0x56a4c1(0x143)](_0x56a4c1(0x149))||(await getPersonalKnowledgeBaseItem(_0x5193cf,_0x16884c[_0x56a4c1(0x14c)]))['title'];return dryRun('POST',_0x56a4c1(0x158)+_0x5193cf+'/update')[_0x56a4c1(0x170)]({'appCode':_0x16884c[_0x56a4c1(0x14c)],'title':_0x12ff68,'content':_0x213760})[_0x56a4c1(0x172)]('Preview:\x20update\x20personal\x20knowledge-base\x20entry\x20'+_0x5193cf)['build']();}},kbSearch={'service':'kb','command':a33_0x115f9b(0x13f),'description':a33_0x115f9b(0x160),'risk':a33_0x115f9b(0x177),'flags':[QUERY_FLAG,TOPK_FLAG],async 'validate'(_0x213cf2){const _0x25c1f2=a33_0x115f9b;if(!_0x213cf2[_0x25c1f2(0x143)](_0x25c1f2(0x14d))[_0x25c1f2(0x166)]())throw CliErrors[_0x25c1f2(0x157)]('Search\x20query\x20is\x20required.');readTopK(_0x213cf2);},async 'execute'(_0x3dd87d){const _0xa5475b=a33_0x115f9b,_0x5a9e47=_0x3dd87d['str']('query')[_0xa5475b(0x166)](),_0x5375d1=readTopK(_0x3dd87d),_0x1586b8=await searchKnowledgeBase(_0x3dd87d['appCode'],{'query':_0x5a9e47,'topK':_0x5375d1});return{'ok':!![],'data':{'total':_0x1586b8[_0xa5475b(0x15a)],'hits':_0x1586b8[_0xa5475b(0x142)](summarizeSearchHit)}};}};export const kbDefinitions=[kbList,kbDetail,kbCreate,kbUpdate,kbSearch];
1
+ function a33_0x4406(){const _0x544b4e=['File\x20not\x20found:\x20','detail','237985GMdNbz','read','bool','accessKey','body','2369481VSFIEC','version','5pgThsV','100iDGImv','Search\x20query\x20for\x20visible\x20public,\x20company,\x20and\x20personal\x20knowledge','ragStatus','Show\x20one\x20personal\x20knowledge-base\x20entry\x20by\x20id','topk','updateTime','5215134mHXImH','create','1830728ktutYw','Update\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','4BXZStD','length','description','95150iMgkyJ','trim','Maximum\x20number\x20of\x20search\x20hits\x20to\x20return','617579wJKefP','title','--topk\x20must\x20be\x20an\x20integer\x20from\x201\x20through\x2050.','Override\x20the\x20existing\x20entry\x20title','verbose','Create\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','validation','signal','Search\x20query\x20is\x20required.','File\x20is\x20not\x20a\x20regular\x20file:\x20','file','Updated\x20KB\x20entry\x20','21KvmbFn','scope','string','List\x20personal\x20knowledge-base\x20entries\x20for\x20the\x20current\x20app','File\x20path\x20is\x20required.','createTime','query','Preview:\x20create\x20personal\x20knowledge-base\x20entry\x20\x22','userId','Personal\x20knowledge-base\x20entry\x20ID','Personal\x20knowledge-base\x20entry\x20title','str','/update','2408508PQSvTa','list','Preview:\x20update\x20personal\x20knowledge-base\x20entry\x20','Replaces\x20the\x20personal\x20knowledge-base\x20entry\x20body\x20with\x20local\x20file\x20content\x20and\x20triggers\x20retrieval\x20sync.','POST','ragErrorMessage','map','number','isSafeInteger','flag','appCode','Search\x20visible\x20public,\x20company,\x20and\x20personal\x20knowledge','write','Saves\x20local\x20file\x20content\x20as\x20a\x20personal\x20knowledge-base\x20entry\x20and\x20starts\x20retrieval\x20sync.','num'];a33_0x4406=function(){return _0x544b4e;};return a33_0x4406();}const a33_0x340849=a33_0x3053;(function(_0x5bf8ba,_0x69a880){const _0x412d1f=a33_0x3053,_0x440d49=_0x5bf8ba();while(!![]){try{const _0x2e69b5=-parseInt(_0x412d1f(0x130))/0x1+parseInt(_0x412d1f(0x12d))/0x2+-parseInt(_0x412d1f(0x11d))/0x3*(-parseInt(_0x412d1f(0x12a))/0x4)+parseInt(_0x412d1f(0x11f))/0x5*(parseInt(_0x412d1f(0x126))/0x6)+parseInt(_0x412d1f(0x13c))/0x7*(-parseInt(_0x412d1f(0x128))/0x8)+parseInt(_0x412d1f(0x149))/0x9+-parseInt(_0x412d1f(0x120))/0xa*(parseInt(_0x412d1f(0x118))/0xb);if(_0x2e69b5===_0x69a880)break;else _0x440d49['push'](_0x440d49['shift']());}catch(_0x4fedf5){_0x440d49['push'](_0x440d49['shift']());}}}(a33_0x4406,0x6ec77));import{existsSync,readFileSync,statSync}from'node:fs';import{createPersonalKnowledgeBaseItem,getPersonalKnowledgeBaseItem,listPersonalKnowledgeBaseItems,updatePersonalKnowledgeBaseItem}from'../../core/api-client.js';function a33_0x3053(_0x8a1db7,_0x4d24f2){_0x8a1db7=_0x8a1db7-0x10f;const _0x4406cb=a33_0x4406();let _0x305370=_0x4406cb[_0x8a1db7];return _0x305370;}import{searchRuntimeKnowledge}from'../../core/kb-search-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const TITLE_FLAG={'name':a33_0x340849(0x131),'type':'string','required':!![],'description':a33_0x340849(0x146)},FILE_FLAG={'name':a33_0x340849(0x13a),'type':a33_0x340849(0x13e),'required':!![],'description':'Path\x20to\x20a\x20local\x20UTF-8\x20text\x20or\x20Markdown\x20file'},QUERY_FLAG={'name':a33_0x340849(0x142),'type':a33_0x340849(0x13e),'required':!![],'description':a33_0x340849(0x121)},TOPK_FLAG={'name':a33_0x340849(0x124),'type':a33_0x340849(0x150),'description':a33_0x340849(0x12f)};function readKnowledgeFile(_0x72ce39){const _0x40413e=a33_0x340849;if(!_0x72ce39)throw CliErrors['validation'](_0x40413e(0x140));if(!existsSync(_0x72ce39))throw CliErrors['validation'](_0x40413e(0x116)+_0x72ce39);if(!statSync(_0x72ce39)['isFile']())throw CliErrors['validation'](_0x40413e(0x139)+_0x72ce39);return readFileSync(_0x72ce39,'utf8');}function summarizePersonalItem(_0x363b01){const _0x2e1d09=a33_0x340849;return{'id':_0x363b01['id'],'title':_0x363b01[_0x2e1d09(0x131)],'version':_0x363b01[_0x2e1d09(0x11e)],'ragStatus':_0x363b01[_0x2e1d09(0x122)],'ragErrorMessage':_0x363b01[_0x2e1d09(0x14e)],'updateTime':_0x363b01[_0x2e1d09(0x125)]};}function detailPersonalItem(_0x589223){const _0x4758d4=a33_0x340849;return{'id':_0x589223['id'],'appCode':_0x589223['appCode'],'scope':_0x589223[_0x4758d4(0x13d)],'userId':_0x589223[_0x4758d4(0x144)],'title':_0x589223[_0x4758d4(0x131)],'content':_0x589223['content']??'','version':_0x589223['version'],'ragStatus':_0x589223[_0x4758d4(0x122)],'ragErrorMessage':_0x589223[_0x4758d4(0x14e)],'createTime':_0x589223[_0x4758d4(0x141)],'updateTime':_0x589223[_0x4758d4(0x125)]};}function readTopK(_0x472220){const _0x9f2e7c=a33_0x340849,_0x281901=_0x472220[_0x9f2e7c(0x110)](_0x9f2e7c(0x124));if(_0x281901===undefined||_0x281901===null||_0x281901==='')return undefined;const _0x2d5bcb=_0x472220[_0x9f2e7c(0x115)](_0x9f2e7c(0x124));if(!Number[_0x9f2e7c(0x10f)](_0x2d5bcb)||_0x2d5bcb<0x1||_0x2d5bcb>0x32)throw CliErrors[_0x9f2e7c(0x136)](_0x9f2e7c(0x132));return _0x2d5bcb;}const kbList={'service':'kb','command':a33_0x340849(0x14a),'description':a33_0x340849(0x13f),'risk':a33_0x340849(0x119),'flags':[VERBOSE_FLAG],async 'execute'(_0x888569){const _0x3a0dfd=a33_0x340849,_0x235f29=await listPersonalKnowledgeBaseItems(_0x888569[_0x3a0dfd(0x111)]);if(_0x888569[_0x3a0dfd(0x11a)](_0x3a0dfd(0x134)))return{'ok':!![],'data':{'total':_0x235f29[_0x3a0dfd(0x12b)],'items':_0x235f29}};return{'ok':!![],'data':{'total':_0x235f29[_0x3a0dfd(0x12b)],'items':_0x235f29[_0x3a0dfd(0x14f)](summarizePersonalItem)}};}},kbDetail={'service':'kb','command':a33_0x340849(0x117),'description':a33_0x340849(0x123),'risk':a33_0x340849(0x119),'flags':[{...ID_FLAG,'description':a33_0x340849(0x145)}],async 'execute'(_0x1f1e93){const _0x2e60eb=a33_0x340849,_0x2cf593=await getPersonalKnowledgeBaseItem(_0x1f1e93[_0x2e60eb(0x115)]('id'),_0x1f1e93['appCode']);return{'ok':!![],'data':detailPersonalItem(_0x2cf593)};}},kbCreate={'service':'kb','command':a33_0x340849(0x127),'description':a33_0x340849(0x135),'risk':'write','confirmationDescription':a33_0x340849(0x114),'flags':[TITLE_FLAG,FILE_FLAG],async 'execute'(_0x496701){const _0x3ca344=a33_0x340849,_0x54d48c=_0x496701['str'](_0x3ca344(0x131)),_0x454498=readKnowledgeFile(_0x496701[_0x3ca344(0x147)](_0x3ca344(0x13a))),_0x3f1604=await createPersonalKnowledgeBaseItem(_0x496701[_0x3ca344(0x111)],{'title':_0x54d48c,'content':_0x454498});return{'ok':!![],'data':summarizePersonalItem(_0x3f1604),'message':'Created\x20KB\x20entry\x20'+_0x3f1604['id']+'\x20('+_0x3f1604[_0x3ca344(0x131)]+')'};},async 'dryRun'(_0x3a4d86){const _0x146340=a33_0x340849,_0x6f7e44=_0x3a4d86[_0x146340(0x147)](_0x146340(0x131)),_0x18b702=readKnowledgeFile(_0x3a4d86[_0x146340(0x147)](_0x146340(0x13a)));return dryRun('POST','/client/knowledge-base/personal/create')['body']({'appCode':_0x3a4d86[_0x146340(0x111)],'title':_0x6f7e44,'content':_0x18b702})[_0x146340(0x12c)](_0x146340(0x143)+_0x6f7e44+'\x22')['build']();}},kbUpdate={'service':'kb','command':'update','description':a33_0x340849(0x129),'risk':a33_0x340849(0x113),'confirmationDescription':a33_0x340849(0x14c),'flags':[{...ID_FLAG,'description':a33_0x340849(0x145)},{...TITLE_FLAG,'required':![],'description':a33_0x340849(0x133)},FILE_FLAG],async 'execute'(_0xdcb00a){const _0xa21e76=a33_0x340849,_0x23411c=_0xdcb00a[_0xa21e76(0x115)]('id'),_0xa6bafd=readKnowledgeFile(_0xdcb00a['str'](_0xa21e76(0x13a))),_0xa7e7e7=_0xdcb00a[_0xa21e76(0x147)]('title')||(await getPersonalKnowledgeBaseItem(_0x23411c,_0xdcb00a[_0xa21e76(0x111)]))[_0xa21e76(0x131)],_0x15def2=await updatePersonalKnowledgeBaseItem(_0x23411c,_0xdcb00a[_0xa21e76(0x111)],{'title':_0xa7e7e7,'content':_0xa6bafd});return{'ok':!![],'data':summarizePersonalItem(_0x15def2),'message':_0xa21e76(0x13b)+_0x15def2['id']+'\x20('+_0x15def2['title']+')'};},async 'dryRun'(_0x13fc4d){const _0x2721ea=a33_0x340849,_0x3fdb2a=_0x13fc4d[_0x2721ea(0x115)]('id'),_0x1dff0b=readKnowledgeFile(_0x13fc4d[_0x2721ea(0x147)](_0x2721ea(0x13a))),_0x5f3996=_0x13fc4d[_0x2721ea(0x147)](_0x2721ea(0x131))||(await getPersonalKnowledgeBaseItem(_0x3fdb2a,_0x13fc4d[_0x2721ea(0x111)]))[_0x2721ea(0x131)];return dryRun(_0x2721ea(0x14d),'/client/knowledge-base/personal/'+_0x3fdb2a+_0x2721ea(0x148))[_0x2721ea(0x11c)]({'appCode':_0x13fc4d[_0x2721ea(0x111)],'title':_0x5f3996,'content':_0x1dff0b})['description'](_0x2721ea(0x14b)+_0x3fdb2a)['build']();}},kbSearch={'service':'kb','command':'search','description':a33_0x340849(0x112),'risk':'read','flags':[QUERY_FLAG,TOPK_FLAG],async 'validate'(_0xb34ebb){const _0x3e873e=a33_0x340849;if(!_0xb34ebb[_0x3e873e(0x147)](_0x3e873e(0x142))[_0x3e873e(0x12e)]())throw CliErrors['validation'](_0x3e873e(0x138));readTopK(_0xb34ebb);},async 'execute'(_0x28a9e0){const _0x2c3dbb=a33_0x340849,_0x658b3d=_0x28a9e0[_0x2c3dbb(0x147)](_0x2c3dbb(0x142))[_0x2c3dbb(0x12e)](),_0x287061=readTopK(_0x28a9e0),_0x2cfc5c=await searchRuntimeKnowledge({'appCode':_0x28a9e0[_0x2c3dbb(0x111)],'accessKey':_0x28a9e0[_0x2c3dbb(0x11b)]??'','query':_0x658b3d,..._0x287061!==undefined?{'topK':_0x287061}:{},'signal':_0x28a9e0[_0x2c3dbb(0x137)]});return{'ok':!![],'data':_0x2cfc5c};}};export const kbDefinitions=[kbList,kbDetail,kbCreate,kbUpdate,kbSearch];
@@ -1 +1 @@
1
- const a34_0x288cbd=a34_0x2895;function a34_0x2895(_0x147213,_0x1bc49f){_0x147213=_0x147213-0x115;const _0x2eedad=a34_0x2eed();let _0x289524=_0x2eedad[_0x147213];return _0x289524;}(function(_0x533126,_0x3afe86){const _0x4e6800=a34_0x2895,_0x34f2c6=_0x533126();while(!![]){try{const _0x3c3d8d=parseInt(_0x4e6800(0x12b))/0x1*(parseInt(_0x4e6800(0x118))/0x2)+parseInt(_0x4e6800(0x11e))/0x3*(parseInt(_0x4e6800(0x117))/0x4)+-parseInt(_0x4e6800(0x116))/0x5*(-parseInt(_0x4e6800(0x11b))/0x6)+-parseInt(_0x4e6800(0x121))/0x7*(-parseInt(_0x4e6800(0x120))/0x8)+-parseInt(_0x4e6800(0x133))/0x9*(parseInt(_0x4e6800(0x122))/0xa)+-parseInt(_0x4e6800(0x11f))/0xb+-parseInt(_0x4e6800(0x119))/0xc*(parseInt(_0x4e6800(0x12c))/0xd);if(_0x3c3d8d===_0x3afe86)break;else _0x34f2c6['push'](_0x34f2c6['shift']());}catch(_0x514a9e){_0x34f2c6['push'](_0x34f2c6['shift']());}}}(a34_0x2eed,0x34baf));import{logger}from'../../utils/logger.js';import{CLI_DISPLAY_NAME}from'../../constant/cli.js';function printLogs(_0x224f40){const _0x46227f=a34_0x2895;if(_0x224f40[_0x46227f(0x11d)]===0x0){console[_0x46227f(0x12e)]('*\x20No\x20logs\x20found');return;}console[_0x46227f(0x12e)]('*\x20'+CLI_DISPLAY_NAME+'\x20logs:\x0a'),_0x224f40[_0x46227f(0x127)]((_0x2a8b92,_0x35ec54)=>{const _0x9a91ea=_0x46227f,_0x5ed9f4=new Date(_0x2a8b92[_0x9a91ea(0x130)])[_0x9a91ea(0x125)](_0x9a91ea(0x11c)),_0x2cf6a6=_0x2a8b92[_0x9a91ea(0x123)]===_0x9a91ea(0x11a)?'√':_0x2a8b92[_0x9a91ea(0x123)]===_0x9a91ea(0x126)?'×':_0x2a8b92[_0x9a91ea(0x123)]==='warn'?'!':'i';console[_0x9a91ea(0x12e)](_0x35ec54+0x1+'.\x20'+_0x2cf6a6+'\x20['+_0x2a8b92['command']+']\x20'+_0x2a8b92['message']),console['log'](_0x9a91ea(0x12a)+_0x5ed9f4),_0x2a8b92[_0x9a91ea(0x129)]&&console[_0x9a91ea(0x12e)](_0x9a91ea(0x134)+_0x2a8b92['duration']+'ms'),_0x2a8b92[_0x9a91ea(0x115)]&&Object[_0x9a91ea(0x131)](_0x2a8b92[_0x9a91ea(0x115)])['length']>0x0&&console[_0x9a91ea(0x12e)](_0x9a91ea(0x12d)+JSON['stringify'](_0x2a8b92[_0x9a91ea(0x115)],null,0x2)),console[_0x9a91ea(0x12e)]('');});}export const logsDefinitions=[{'service':a34_0x288cbd(0x124),'command':'show','description':a34_0x288cbd(0x12f),'risk':a34_0x288cbd(0x132),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x2730d2){const _0x57fb74=a34_0x288cbd;return printLogs(logger[_0x57fb74(0x128)]()),{'ok':!![]};}}];function a34_0x2eed(){const _0x3ebdf7=['level','logs','toLocaleString','error','forEach','readLogs','duration','\x20\x20\x20Time:\x20','20qrRchO','1983397tOmhCu','\x20\x20\x20Details:\x20','log','View\x20command\x20history\x20logs','timestamp','keys','read','9IvjDhH','\x20\x20\x20Duration:\x20','details','36445icuWqQ','164048JjWSRz','25678kcdYCv','12OcWpcF','success','120LChDFO','en-US','length','24ezBWGF','2255495MSFJiv','855944FFwDaS','7ZZkrOd','2640520pzktHg'];a34_0x2eed=function(){return _0x3ebdf7;};return a34_0x2eed();}
1
+ const a34_0x1436a6=a34_0xf2dc;(function(_0x5ec8d8,_0x5ee88a){const _0x4cb514=a34_0xf2dc,_0x59665d=_0x5ec8d8();while(!![]){try{const _0x13f6fa=-parseInt(_0x4cb514(0x7a))/0x1+-parseInt(_0x4cb514(0x6d))/0x2*(-parseInt(_0x4cb514(0x6a))/0x3)+parseInt(_0x4cb514(0x80))/0x4+parseInt(_0x4cb514(0x7f))/0x5*(parseInt(_0x4cb514(0x79))/0x6)+-parseInt(_0x4cb514(0x6b))/0x7+parseInt(_0x4cb514(0x71))/0x8*(-parseInt(_0x4cb514(0x76))/0x9)+-parseInt(_0x4cb514(0x7c))/0xa;if(_0x13f6fa===_0x5ee88a)break;else _0x59665d['push'](_0x59665d['shift']());}catch(_0x15c9ba){_0x59665d['push'](_0x59665d['shift']());}}}(a34_0x50f8,0x57460));import{logger}from'../../utils/logger.js';import{CLI_DISPLAY_NAME}from'../../constant/cli.js';function a34_0xf2dc(_0x16937e,_0x1f2b57){_0x16937e=_0x16937e-0x67;const _0x50f82c=a34_0x50f8();let _0xf2dca3=_0x50f82c[_0x16937e];return _0xf2dca3;}function a34_0x50f8(){const _0x362eba=['forEach','42ByqpBB','32980uTaiLn','*\x20No\x20logs\x20found','909270xPtcbV','details','\x20\x20\x20Details:\x20','400380TVJsVj','555376DSkTKy','show','toLocaleString','success','463737Lvfzhf','4363114goOuJF','duration','6LHQxBG','warn','log','length','5312HcvjGV','\x20\x20\x20Time:\x20','message','View\x20command\x20history\x20logs','level','792cLlCie','read'];a34_0x50f8=function(){return _0x362eba;};return a34_0x50f8();}function printLogs(_0x288c3e){const _0xeb6591=a34_0xf2dc;if(_0x288c3e['length']===0x0){console['log'](_0xeb6591(0x7b));return;}console[_0xeb6591(0x6f)]('*\x20'+CLI_DISPLAY_NAME+'\x20logs:\x0a'),_0x288c3e[_0xeb6591(0x78)]((_0x280533,_0x3d91bf)=>{const _0x30e515=_0xeb6591,_0x2b76dc=new Date(_0x280533['timestamp'])[_0x30e515(0x68)]('en-US'),_0x5f4e12=_0x280533[_0x30e515(0x75)]===_0x30e515(0x69)?'√':_0x280533[_0x30e515(0x75)]==='error'?'×':_0x280533[_0x30e515(0x75)]===_0x30e515(0x6e)?'!':'i';console[_0x30e515(0x6f)](_0x3d91bf+0x1+'.\x20'+_0x5f4e12+'\x20['+_0x280533['command']+']\x20'+_0x280533[_0x30e515(0x73)]),console[_0x30e515(0x6f)](_0x30e515(0x72)+_0x2b76dc),_0x280533[_0x30e515(0x6c)]&&console[_0x30e515(0x6f)]('\x20\x20\x20Duration:\x20'+_0x280533['duration']+'ms'),_0x280533['details']&&Object['keys'](_0x280533['details'])[_0x30e515(0x70)]>0x0&&console[_0x30e515(0x6f)](_0x30e515(0x7e)+JSON['stringify'](_0x280533[_0x30e515(0x7d)],null,0x2)),console[_0x30e515(0x6f)]('');});}export const logsDefinitions=[{'service':'logs','command':a34_0x1436a6(0x67),'description':a34_0x1436a6(0x74),'risk':a34_0x1436a6(0x77),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x16459c){return printLogs(logger['readLogs']()),{'ok':!![]};}}];
@@ -1 +1 @@
1
- const a35_0x2f4b93=a35_0x470b;(function(_0x423623,_0x45b485){const _0x19aaff=a35_0x470b,_0x1c640c=_0x423623();while(!![]){try{const _0x17436e=parseInt(_0x19aaff(0x1ad))/0x1*(-parseInt(_0x19aaff(0x1a6))/0x2)+-parseInt(_0x19aaff(0x1a4))/0x3+-parseInt(_0x19aaff(0x1a9))/0x4*(parseInt(_0x19aaff(0x1b0))/0x5)+-parseInt(_0x19aaff(0x1b1))/0x6+parseInt(_0x19aaff(0x1a3))/0x7+-parseInt(_0x19aaff(0x1af))/0x8+-parseInt(_0x19aaff(0x1aa))/0x9*(-parseInt(_0x19aaff(0x1ac))/0xa);if(_0x17436e===_0x45b485)break;else _0x1c640c['push'](_0x1c640c['shift']());}catch(_0x5f11ae){_0x1c640c['push'](_0x1c640c['shift']());}}}(a35_0x3b2d,0x3e348));import{listNotificationChannelConfigs}from'../../core/api-client.js';function a35_0x470b(_0x109b90,_0x1295b8){_0x109b90=_0x109b90-0x1a1;const _0x3b2dab=a35_0x3b2d();let _0x470b26=_0x3b2dab[_0x109b90];return _0x470b26;}import{NOTIFICATION_CHANNEL_TYPES,projectNotificationListConfig,readNotificationChannelType}from'../../commands/notification/shared.js';function a35_0x3b2d(){const _0x29ecb4=['4219983sVJZQR','EMAIL','20HpGGFF','302aFBjqP','appCode','634872NfZscG','848110FyqcuF','1970334uzNWzt','Notification\x20channel\x20type','length','config-list','string','notification','3101938kyjQnZ','585312hpzbvH','read','2342HDPnnA','List\x20app-level\x20notification\x20configs\x20and\x20their\x20configCode\x20values','map','4PSjxMM'];a35_0x3b2d=function(){return _0x29ecb4;};return a35_0x3b2d();}export const notificationConfigList={'service':a35_0x2f4b93(0x1a2),'command':a35_0x2f4b93(0x1b4),'description':a35_0x2f4b93(0x1a7),'risk':a35_0x2f4b93(0x1a5),'flags':[{'name':'type','type':a35_0x2f4b93(0x1a1),'description':a35_0x2f4b93(0x1b2),'enum':NOTIFICATION_CHANNEL_TYPES,'default':a35_0x2f4b93(0x1ab)}],async 'validate'(_0x150d43){readNotificationChannelType(_0x150d43);},async 'execute'(_0x16055b){const _0x16c9e3=a35_0x2f4b93,_0x354b52=readNotificationChannelType(_0x16055b),_0x5a4fc8=await listNotificationChannelConfigs(_0x16055b[_0x16c9e3(0x1ae)],_0x354b52),_0x1c0105=_0x5a4fc8[_0x16c9e3(0x1a8)](projectNotificationListConfig);return{'ok':!![],'data':{'appCode':_0x16055b[_0x16c9e3(0x1ae)],'channelType':_0x354b52,'count':_0x1c0105[_0x16c9e3(0x1b3)],'configs':_0x1c0105},'message':'Found\x20'+_0x1c0105[_0x16c9e3(0x1b3)]+'\x20'+_0x354b52+'\x20notification\x20config(s)'};}};
1
+ const a35_0x7b1374=a35_0x2488;function a35_0x2488(_0x3d385c,_0x159065){_0x3d385c=_0x3d385c-0xcb;const _0x505764=a35_0x5057();let _0x248807=_0x505764[_0x3d385c];return _0x248807;}(function(_0x51f8ae,_0x2199ef){const _0x17a57b=a35_0x2488,_0x3ee626=_0x51f8ae();while(!![]){try{const _0x469bca=parseInt(_0x17a57b(0xdf))/0x1*(parseInt(_0x17a57b(0xdb))/0x2)+parseInt(_0x17a57b(0xdc))/0x3*(-parseInt(_0x17a57b(0xde))/0x4)+-parseInt(_0x17a57b(0xd3))/0x5*(parseInt(_0x17a57b(0xd0))/0x6)+-parseInt(_0x17a57b(0xe4))/0x7*(-parseInt(_0x17a57b(0xcf))/0x8)+-parseInt(_0x17a57b(0xcc))/0x9*(-parseInt(_0x17a57b(0xd8))/0xa)+-parseInt(_0x17a57b(0xe2))/0xb*(parseInt(_0x17a57b(0xd7))/0xc)+-parseInt(_0x17a57b(0xe0))/0xd*(-parseInt(_0x17a57b(0xce))/0xe);if(_0x469bca===_0x2199ef)break;else _0x3ee626['push'](_0x3ee626['shift']());}catch(_0x509320){_0x3ee626['push'](_0x3ee626['shift']());}}}(a35_0x5057,0xc0f76));import{listNotificationChannelConfigs}from'../../core/api-client.js';import{NOTIFICATION_CHANNEL_TYPES,projectNotificationListConfig,readNotificationChannelType}from'../../commands/notification/shared.js';function a35_0x5057(){const _0x40d5b5=['7487662bhrJyY','appCode','737hgFYvZ','EMAIL','626017isbSoD','read','18LwffGU','config-list','28MtznEH','80etJxDO','12pjOuma','type','length','1973810ntjzbk','Found\x20','\x20notification\x20config(s)','Notification\x20channel\x20type','260652sXFhOU','4372110JtTeNg','string','notification','64VsFIPK','69669elbxEn','map','148MVgFfk','30431CtXxmT'];a35_0x5057=function(){return _0x40d5b5;};return a35_0x5057();}export const notificationConfigList={'service':a35_0x7b1374(0xda),'command':a35_0x7b1374(0xcd),'description':'List\x20app-level\x20notification\x20configs\x20and\x20their\x20configCode\x20values','risk':a35_0x7b1374(0xcb),'flags':[{'name':a35_0x7b1374(0xd1),'type':a35_0x7b1374(0xd9),'description':a35_0x7b1374(0xd6),'enum':NOTIFICATION_CHANNEL_TYPES,'default':a35_0x7b1374(0xe3)}],async 'validate'(_0x3368da){readNotificationChannelType(_0x3368da);},async 'execute'(_0x133287){const _0x43c8cb=a35_0x7b1374,_0x27f7cd=readNotificationChannelType(_0x133287),_0xd48c4b=await listNotificationChannelConfigs(_0x133287['appCode'],_0x27f7cd),_0x161baa=_0xd48c4b[_0x43c8cb(0xdd)](projectNotificationListConfig);return{'ok':!![],'data':{'appCode':_0x133287[_0x43c8cb(0xe1)],'channelType':_0x27f7cd,'count':_0x161baa[_0x43c8cb(0xd2)],'configs':_0x161baa},'message':_0x43c8cb(0xd4)+_0x161baa[_0x43c8cb(0xd2)]+'\x20'+_0x27f7cd+_0x43c8cb(0xd5)};}};
@@ -1 +1 @@
1
- function a36_0x2a24(_0x595235,_0x103d7f){_0x595235=_0x595235-0xa7;const _0x5b62b5=a36_0x5b62();let _0x2a2486=_0x5b62b5[_0x595235];return _0x2a2486;}(function(_0x38e264,_0x9845b2){const _0x2fe734=a36_0x2a24,_0xa42f2c=_0x38e264();while(!![]){try{const _0x3e72c9=parseInt(_0x2fe734(0xad))/0x1+parseInt(_0x2fe734(0xa8))/0x2*(parseInt(_0x2fe734(0xb0))/0x3)+parseInt(_0x2fe734(0xac))/0x4+-parseInt(_0x2fe734(0xaa))/0x5*(-parseInt(_0x2fe734(0xa7))/0x6)+parseInt(_0x2fe734(0xae))/0x7*(parseInt(_0x2fe734(0xab))/0x8)+-parseInt(_0x2fe734(0xa9))/0x9+-parseInt(_0x2fe734(0xaf))/0xa;if(_0x3e72c9===_0x9845b2)break;else _0xa42f2c['push'](_0xa42f2c['shift']());}catch(_0xeb4f69){_0xa42f2c['push'](_0xa42f2c['shift']());}}}(a36_0x5b62,0x1cf91));import{notificationConfigList}from'../../commands/notification/config-list.js';function a36_0x5b62(){const _0x5ab8f8=['4580acKagF','1270024mTZoPK','368732SzDQLT','221606CjZTUW','7VuCQev','4307170ulPSfo','4083jvIEiP','216JjOYIx','218Qslwfz','940293XRHfzn'];a36_0x5b62=function(){return _0x5ab8f8;};return a36_0x5b62();}export const notificationDefinitions=[notificationConfigList];
1
+ (function(_0x3e2b4c,_0x541c94){const _0x3af7c0=a36_0x1c50,_0x60a815=_0x3e2b4c();while(!![]){try{const _0x3d2932=parseInt(_0x3af7c0(0x1f2))/0x1*(parseInt(_0x3af7c0(0x1f4))/0x2)+-parseInt(_0x3af7c0(0x1f7))/0x3+parseInt(_0x3af7c0(0x1f3))/0x4*(parseInt(_0x3af7c0(0x1f9))/0x5)+-parseInt(_0x3af7c0(0x1f8))/0x6+-parseInt(_0x3af7c0(0x1f5))/0x7+-parseInt(_0x3af7c0(0x1f6))/0x8+parseInt(_0x3af7c0(0x1f1))/0x9;if(_0x3d2932===_0x541c94)break;else _0x60a815['push'](_0x60a815['shift']());}catch(_0x4a138a){_0x60a815['push'](_0x60a815['shift']());}}}(a36_0x21ee,0x67dd4));import{notificationConfigList}from'../../commands/notification/config-list.js';function a36_0x1c50(_0x4b2cfd,_0x4c84bd){_0x4b2cfd=_0x4b2cfd-0x1f1;const _0x21ee64=a36_0x21ee();let _0x1c50d6=_0x21ee64[_0x4b2cfd];return _0x1c50d6;}export const notificationDefinitions=[notificationConfigList];function a36_0x21ee(){const _0x2a89aa=['2955162oyeJOM','5kCEuxU','11528685SznFjp','3asjkXa','84668OvtkRk','374954ksVqFf','895895ZWAaxm','745520SaTHNI','2176299aNNVgU'];a36_0x21ee=function(){return _0x2a89aa;};return a36_0x21ee();}
@@ -1 +1 @@
1
- function a37_0x4a57(_0x5c2626,_0x4185f8){_0x5c2626=_0x5c2626-0x151;const _0xed3eed=a37_0xed3e();let _0x4a57f3=_0xed3eed[_0x5c2626];return _0x4a57f3;}const a37_0x1fbedf=a37_0x4a57;(function(_0x29541d,_0x1e1c16){const _0x4f9f0a=a37_0x4a57,_0x53821e=_0x29541d();while(!![]){try{const _0x193569=parseInt(_0x4f9f0a(0x176))/0x1*(-parseInt(_0x4f9f0a(0x174))/0x2)+parseInt(_0x4f9f0a(0x16b))/0x3*(-parseInt(_0x4f9f0a(0x158))/0x4)+parseInt(_0x4f9f0a(0x15d))/0x5+parseInt(_0x4f9f0a(0x170))/0x6*(parseInt(_0x4f9f0a(0x159))/0x7)+parseInt(_0x4f9f0a(0x16d))/0x8*(parseInt(_0x4f9f0a(0x16a))/0x9)+parseInt(_0x4f9f0a(0x169))/0xa+-parseInt(_0x4f9f0a(0x173))/0xb*(parseInt(_0x4f9f0a(0x151))/0xc);if(_0x193569===_0x1e1c16)break;else _0x53821e['push'](_0x53821e['shift']());}catch(_0x2e4c4b){_0x53821e['push'](_0x53821e['shift']());}}}(a37_0xed3e,0xac89a));import{CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=[a37_0x1fbedf(0x16f),a37_0x1fbedf(0x153),a37_0x1fbedf(0x165),'WECOM',a37_0x1fbedf(0x160)];export function readNotificationChannelType(_0x560c22){const _0xc2370d=a37_0x1fbedf,_0x3722e1=_0x560c22[_0xc2370d(0x15b)](_0xc2370d(0x155))['trim']()||'EMAIL';if(!NOTIFICATION_CHANNEL_TYPES[_0xc2370d(0x162)](_0x3722e1))throw CliErrors[_0xc2370d(0x164)](_0xc2370d(0x16e)+_0x3722e1,_0xc2370d(0x15f)+NOTIFICATION_CHANNEL_TYPES[_0xc2370d(0x171)](',\x20')+'.');return _0x3722e1;}export function projectNotificationListConfig(_0x34bdfd,_0x24973c){const _0x5cde5f=a37_0x1fbedf,_0x3d6530=requireResponseObject(_0x34bdfd,_0x24973c);return{'id':normalizeNullableId(_0x3d6530['id'],_0x24973c),'configCode':requireResponseString(_0x3d6530[_0x5cde5f(0x152)],_0x5cde5f(0x152),_0x24973c),'configName':requireResponseString(_0x3d6530[_0x5cde5f(0x168)],_0x5cde5f(0x168),_0x24973c),'channelType':requireResponseString(_0x3d6530['channelType'],_0x5cde5f(0x154),_0x24973c),'description':normalizeNullableString(_0x3d6530[_0x5cde5f(0x167)]),'createTime':normalizeNullableString(_0x3d6530[_0x5cde5f(0x166)]),'updateTime':normalizeNullableString(_0x3d6530['updateTime'])};}function requireResponseObject(_0x2b808e,_0x1560ac){const _0x20d775=a37_0x1fbedf;if(typeof _0x2b808e!==_0x20d775(0x163)||_0x2b808e===null||Array[_0x20d775(0x15e)](_0x2b808e))throw CliErrors['apiError']('Invalid\x20notification\x20config\x20response.','Item\x20'+(_0x1560ac+0x1)+_0x20d775(0x16c));return _0x2b808e;}function requireResponseString(_0x22c70f,_0x3508fe,_0x14a47e){const _0x16fcac=a37_0x1fbedf;if(typeof _0x22c70f!==_0x16fcac(0x175)||!_0x22c70f[_0x16fcac(0x157)]())throw CliErrors[_0x16fcac(0x156)](_0x16fcac(0x15c),'Item\x20'+(_0x14a47e+0x1)+'\x20is\x20missing\x20required\x20field\x20\x22'+_0x3508fe+'\x22.');return _0x22c70f[_0x16fcac(0x157)]();}function normalizeNullableString(_0x4baa3b){const _0xce26e2=a37_0x1fbedf;return typeof _0x4baa3b==='string'&&_0x4baa3b[_0xce26e2(0x157)]()?_0x4baa3b[_0xce26e2(0x157)]():null;}function a37_0xed3e(){const _0xa419fb=['object','validation','DINGTALK','createTime','description','configName','13316770WBRkZr','27NgTKkY','177HCWIKi','\x20must\x20be\x20an\x20object.','204520eXFDLB','Invalid\x20--type:\x20','EMAIL','6635598zezZXI','join','Item\x20','3487qcjQso','73026EpWmSd','string','14DEaRZW','35928WznoHX','configCode','FEISHU','channelType','type','apiError','trim','84228svduzS','7NjhDlb','test','str','Invalid\x20notification\x20config\x20response.','4475260dlOXQL','isArray','Allowed\x20values:\x20','WEBHOOK','number','includes'];a37_0xed3e=function(){return _0xa419fb;};return a37_0xed3e();}function normalizeNullableId(_0x237a24,_0x516306){const _0x39f7ea=a37_0x1fbedf;if(_0x237a24===undefined||_0x237a24===null)return null;if(typeof _0x237a24===_0x39f7ea(0x161)&&Number['isSafeInteger'](_0x237a24))return _0x237a24;if(typeof _0x237a24==='string'&&/^-?\d+$/[_0x39f7ea(0x15a)](_0x237a24[_0x39f7ea(0x157)]()))return _0x237a24[_0x39f7ea(0x157)]();throw CliErrors[_0x39f7ea(0x156)](_0x39f7ea(0x15c),_0x39f7ea(0x172)+(_0x516306+0x1)+'\x20has\x20invalid\x20field\x20\x22id\x22.');}
1
+ const a37_0x3b3dd5=a37_0x3063;function a37_0x33e0(){const _0x3eb1b5=['WEBHOOK','DINGTALK','1SBTxep','60wyzCRi','\x20is\x20missing\x20required\x20field\x20\x22','735146RHMGPA','createTime','2959548IttYqo','channelType','6661065RWMSZz','6COrKWR','validation','WECOM','configCode','4660560pAiQPG','string','Invalid\x20notification\x20config\x20response.','36NehJXR','143yJnXoR','updateTime','EMAIL','configName','\x20must\x20be\x20an\x20object.','7AawoML','1072912YBSrbM','type','apiError','str','isArray','trim','1110244sQISlv','Allowed\x20values:\x20','2344155OdmvRS','Item\x20'];a37_0x33e0=function(){return _0x3eb1b5;};return a37_0x33e0();}(function(_0x12a235,_0x52d330){const _0x2f2d03=a37_0x3063,_0x37a8cc=_0x12a235();while(!![]){try{const _0x1ea648=parseInt(_0x2f2d03(0x1ba))/0x1*(-parseInt(_0x2f2d03(0x1bd))/0x2)+parseInt(_0x2f2d03(0x1c2))/0x3*(-parseInt(_0x2f2d03(0x1b4))/0x4)+-parseInt(_0x2f2d03(0x1c1))/0x5+parseInt(_0x2f2d03(0x1bf))/0x6*(-parseInt(_0x2f2d03(0x1ad))/0x7)+-parseInt(_0x2f2d03(0x1ae))/0x8*(-parseInt(_0x2f2d03(0x1c9))/0x9)+parseInt(_0x2f2d03(0x1bb))/0xa*(-parseInt(_0x2f2d03(0x1b6))/0xb)+-parseInt(_0x2f2d03(0x1c6))/0xc*(-parseInt(_0x2f2d03(0x1ca))/0xd);if(_0x1ea648===_0x52d330)break;else _0x37a8cc['push'](_0x37a8cc['shift']());}catch(_0x1c2e61){_0x37a8cc['push'](_0x37a8cc['shift']());}}}(a37_0x33e0,0xbee10));import{CliErrors}from'../../errors.js';function a37_0x3063(_0x1c10a9,_0x1855df){_0x1c10a9=_0x1c10a9-0x1ad;const _0x33e057=a37_0x33e0();let _0x306304=_0x33e057[_0x1c10a9];return _0x306304;}export const NOTIFICATION_CHANNEL_TYPES=[a37_0x3b3dd5(0x1cc),'FEISHU',a37_0x3b3dd5(0x1b9),a37_0x3b3dd5(0x1c4),a37_0x3b3dd5(0x1b8)];export function readNotificationChannelType(_0x12c066){const _0x3b2b00=a37_0x3b3dd5,_0x34c008=_0x12c066[_0x3b2b00(0x1b1)](_0x3b2b00(0x1af))[_0x3b2b00(0x1b3)]()||'EMAIL';if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x34c008))throw CliErrors[_0x3b2b00(0x1c3)]('Invalid\x20--type:\x20'+_0x34c008,_0x3b2b00(0x1b5)+NOTIFICATION_CHANNEL_TYPES['join'](',\x20')+'.');return _0x34c008;}export function projectNotificationListConfig(_0x5751d7,_0x45770f){const _0x11e9db=a37_0x3b3dd5,_0x149764=requireResponseObject(_0x5751d7,_0x45770f);return{'id':normalizeNullableId(_0x149764['id'],_0x45770f),'configCode':requireResponseString(_0x149764[_0x11e9db(0x1c5)],_0x11e9db(0x1c5),_0x45770f),'configName':requireResponseString(_0x149764[_0x11e9db(0x1cd)],'configName',_0x45770f),'channelType':requireResponseString(_0x149764[_0x11e9db(0x1c0)],'channelType',_0x45770f),'description':normalizeNullableString(_0x149764['description']),'createTime':normalizeNullableString(_0x149764[_0x11e9db(0x1be)]),'updateTime':normalizeNullableString(_0x149764[_0x11e9db(0x1cb)])};}function requireResponseObject(_0x3337ab,_0x5ed05a){const _0xd7c736=a37_0x3b3dd5;if(typeof _0x3337ab!=='object'||_0x3337ab===null||Array[_0xd7c736(0x1b2)](_0x3337ab))throw CliErrors[_0xd7c736(0x1b0)](_0xd7c736(0x1c8),_0xd7c736(0x1b7)+(_0x5ed05a+0x1)+_0xd7c736(0x1ce));return _0x3337ab;}function requireResponseString(_0x485cba,_0x2b0b27,_0x12d21d){const _0x48e4fa=a37_0x3b3dd5;if(typeof _0x485cba!==_0x48e4fa(0x1c7)||!_0x485cba[_0x48e4fa(0x1b3)]())throw CliErrors['apiError'](_0x48e4fa(0x1c8),_0x48e4fa(0x1b7)+(_0x12d21d+0x1)+_0x48e4fa(0x1bc)+_0x2b0b27+'\x22.');return _0x485cba[_0x48e4fa(0x1b3)]();}function normalizeNullableString(_0x5aa54d){const _0xa6843f=a37_0x3b3dd5;return typeof _0x5aa54d===_0xa6843f(0x1c7)&&_0x5aa54d[_0xa6843f(0x1b3)]()?_0x5aa54d[_0xa6843f(0x1b3)]():null;}function normalizeNullableId(_0x4abf58,_0x538c20){const _0x91d0fe=a37_0x3b3dd5;if(_0x4abf58===undefined||_0x4abf58===null)return null;if(typeof _0x4abf58==='number'&&Number['isSafeInteger'](_0x4abf58))return _0x4abf58;if(typeof _0x4abf58===_0x91d0fe(0x1c7)&&/^-?\d+$/['test'](_0x4abf58[_0x91d0fe(0x1b3)]()))return _0x4abf58[_0x91d0fe(0x1b3)]();throw CliErrors[_0x91d0fe(0x1b0)]('Invalid\x20notification\x20config\x20response.',_0x91d0fe(0x1b7)+(_0x538c20+0x1)+'\x20has\x20invalid\x20field\x20\x22id\x22.');}
@@ -1 +1 @@
1
- const a38_0x5cb132=a38_0x574c;function a38_0x574c(_0x4ab8b3,_0x102f31){_0x4ab8b3=_0x4ab8b3-0x19f;const _0xcf5d50=a38_0xcf5d();let _0x574c2d=_0xcf5d50[_0x4ab8b3];return _0x574c2d;}(function(_0x12b3fd,_0x1aed80){const _0x1ffc69=a38_0x574c,_0x2912b4=_0x12b3fd();while(!![]){try{const _0x3e9dc2=parseInt(_0x1ffc69(0x1d3))/0x1*(-parseInt(_0x1ffc69(0x1cf))/0x2)+parseInt(_0x1ffc69(0x1c5))/0x3+-parseInt(_0x1ffc69(0x1bc))/0x4*(-parseInt(_0x1ffc69(0x1ba))/0x5)+-parseInt(_0x1ffc69(0x1a9))/0x6*(-parseInt(_0x1ffc69(0x1a6))/0x7)+parseInt(_0x1ffc69(0x1c7))/0x8*(parseInt(_0x1ffc69(0x1d2))/0x9)+-parseInt(_0x1ffc69(0x1c9))/0xa*(-parseInt(_0x1ffc69(0x1b0))/0xb)+-parseInt(_0x1ffc69(0x1c8))/0xc;if(_0x3e9dc2===_0x1aed80)break;else _0x2912b4['push'](_0x2912b4['shift']());}catch(_0x1ae541){_0x2912b4['push'](_0x2912b4['shift']());}}}(a38_0xcf5d,0x2664a));import{requireRuntimeUploadFile}from'../../commands/common/local-file.js';import{queryRuntimeFileUrl,recognizeRuntimeOcr,uploadRuntimeFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const SUPPORTED_SCENES=[a38_0x5cb132(0x1a1),'general',a38_0x5cb132(0x1a4),a38_0x5cb132(0x1c2)],SCENE_TO_LEGACY_TYPE={'invoice':a38_0x5cb132(0x1ca),'general':'General','form':'Table','idCard':a38_0x5cb132(0x1b9)},SCENE_FLAG={'name':a38_0x5cb132(0x1b6),'type':'string','required':!![],'enum':[...SUPPORTED_SCENES],'description':'OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard'},IMAGE_FILE_FLAG={'name':'image-file','type':a38_0x5cb132(0x1a2),'description':a38_0x5cb132(0x1d0)},IMAGE_URL_FLAG={'name':a38_0x5cb132(0x1a0),'type':a38_0x5cb132(0x1a2),'description':'Publicly\x20accessible\x20image\x20or\x20file\x20URL'};function normalizeScene(_0x58fbfa){const _0x110a93=a38_0x5cb132,_0x5cd1b5=_0x58fbfa['trim']()[_0x110a93(0x1b4)]();if(_0x5cd1b5===_0x110a93(0x1ad))return'idCard';if(_0x5cd1b5===_0x110a93(0x1a1)||_0x5cd1b5==='general'||_0x5cd1b5==='form')return _0x5cd1b5;throw CliErrors[_0x110a93(0x1bf)]('Unsupported\x20OCR\x20scene:\x20'+_0x58fbfa+_0x110a93(0x1b7)+SUPPORTED_SCENES['join'](',\x20'));}function selectedInputs(_0x5370dd){const _0x58fb45=a38_0x5cb132,_0x3bf933=_0x5370dd[_0x58fb45(0x1be)](_0x58fb45(0x1cb))['trim'](),_0x2265a8=_0x5370dd['str'](_0x58fb45(0x1a0))[_0x58fb45(0x1b8)]();return{'imageFile':_0x3bf933,'imageUrl':_0x2265a8,'count':[_0x3bf933,_0x2265a8][_0x58fb45(0x1b2)](Boolean)[_0x58fb45(0x1d4)]};}function validateInputSelection(_0x231f74){const _0x2ab8e0=a38_0x5cb132,_0x70c05e=selectedInputs(_0x231f74);if(_0x70c05e[_0x2ab8e0(0x1bb)]!==0x1)throw CliErrors[_0x2ab8e0(0x1bf)](_0x2ab8e0(0x1a8));return _0x70c05e;}function a38_0xcf5d(){const _0x5c2351=['Invoice','image-file','imageUrl','\x20OCR\x20from\x20URL','POST','10LBnLJv','Local\x20image\x20or\x20PDF\x20file;\x20current\x20backend\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','File\x20upload\x20response\x20missing\x20filePath.','1170783SaxVQb','27383blOZiR','length','fileUrl','image-url','invoice','string','/client/ocr','form','/client/uploadFile','371PuTYPs','description','Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.','29382eUAcok','/client/queryFileUrl','appCode','build','idcard','ocr','body','1032977bdQPMC','imageFile','filter','read','toLowerCase','recognize','scene','.\x20Supported\x20scenes:\x20','trim','IdCard','1016300yqTvNT','count','4hsSsGX','apiError','str','validation','\x20OCR','filePath','idCard','<fileUrl\x20returned\x20by\x20/client/queryFileUrl>','File\x20URL\x20response\x20missing\x20fileUrl.','754365cZoTEH','<filePath\x20returned\x20by\x20/client/uploadFile>','16TscVLM','9289968PqwqCw','10FrsiiQ'];a38_0xcf5d=function(){return _0x5c2351;};return a38_0xcf5d();}function withScene(_0x1b4446,_0x2c9205,_0x3ef186){const _0x4dcceb=a38_0x5cb132;return{..._0x1b4446,'scene':_0x2c9205,..._0x3ef186?{'sourceFile':{'fileName':_0x3ef186['fileName'],'filePath':_0x3ef186[_0x4dcceb(0x1c1)]}}:{}};}const ocrRecognize={'service':a38_0x5cb132(0x1ae),'command':a38_0x5cb132(0x1b5),'description':'Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','risk':a38_0x5cb132(0x1b3),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x158afd){const _0x55359a=a38_0x5cb132,_0x266473=normalizeScene(_0x158afd[_0x55359a(0x1be)]('scene')),_0x4571f4=SCENE_TO_LEGACY_TYPE[_0x266473],_0x5b7105=validateInputSelection(_0x158afd);if(_0x5b7105['imageUrl'])return dryRun('POST',_0x55359a(0x1a3))[_0x55359a(0x1af)]({'appCode':_0x158afd['appCode'],'url':_0x5b7105['imageUrl'],'type':_0x4571f4})[_0x55359a(0x1a7)]('Preview:\x20recognize\x20'+_0x266473+_0x55359a(0x1cd))[_0x55359a(0x1ac)]();const _0x54bc36=requireRuntimeUploadFile(_0x5b7105[_0x55359a(0x1b1)],'image-file');return dryRun(_0x55359a(0x1ce),_0x55359a(0x1a5))[_0x55359a(0x1af)]({'steps':[{'method':_0x55359a(0x1ce),'url':_0x55359a(0x1a5),'body':{'appCode':_0x158afd['appCode'],'multipart':{'file':_0x54bc36}}},{'method':_0x55359a(0x1ce),'url':_0x55359a(0x1aa),'body':{'filePath':_0x55359a(0x1c6),'downloadFlag':![]}},{'method':_0x55359a(0x1ce),'url':'/client/ocr','body':{'appCode':_0x158afd['appCode'],'url':_0x55359a(0x1c3),'type':_0x4571f4}}]})['description']('Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20'+_0x266473+_0x55359a(0x1c0))[_0x55359a(0x1ac)]();},async 'execute'(_0x18ef6d){const _0x3a56de=a38_0x5cb132,_0x555562=normalizeScene(_0x18ef6d['str']('scene')),_0x349c5f=SCENE_TO_LEGACY_TYPE[_0x555562],_0x5a6485=validateInputSelection(_0x18ef6d);if(_0x5a6485[_0x3a56de(0x1cc)]){const _0x153b99=await recognizeRuntimeOcr(_0x18ef6d['appCode'],{'url':_0x5a6485[_0x3a56de(0x1cc)],'type':_0x349c5f});return{'ok':!![],'data':withScene(_0x153b99,_0x555562)};}const _0x57d34e=requireRuntimeUploadFile(_0x5a6485['imageFile'],'image-file'),_0x30e0e1=await uploadRuntimeFile(_0x18ef6d[_0x3a56de(0x1ab)],_0x57d34e['path']);if(!_0x30e0e1[_0x3a56de(0x1c1)])throw CliErrors['apiError'](_0x3a56de(0x1d1));const _0x47cea9=await queryRuntimeFileUrl(_0x30e0e1[_0x3a56de(0x1c1)],{'download':![]});if(!_0x47cea9[_0x3a56de(0x19f)])throw CliErrors[_0x3a56de(0x1bd)](_0x3a56de(0x1c4));const _0x182b08=await recognizeRuntimeOcr(_0x18ef6d['appCode'],{'url':_0x47cea9[_0x3a56de(0x19f)],'type':_0x349c5f});return{'ok':!![],'data':withScene(_0x182b08,_0x555562,_0x30e0e1)};}};export const ocrDefinitions=[ocrRecognize];
1
+ const a38_0xc5a996=a38_0x5af7;(function(_0x2a6001,_0x5e26a1){const _0x5c4619=a38_0x5af7,_0x32ab7f=_0x2a6001();while(!![]){try{const _0x23eeab=-parseInt(_0x5c4619(0x1cf))/0x1*(parseInt(_0x5c4619(0x1c3))/0x2)+parseInt(_0x5c4619(0x1a6))/0x3+parseInt(_0x5c4619(0x1b7))/0x4*(parseInt(_0x5c4619(0x1a2))/0x5)+-parseInt(_0x5c4619(0x1ae))/0x6+-parseInt(_0x5c4619(0x1a5))/0x7*(parseInt(_0x5c4619(0x1a0))/0x8)+parseInt(_0x5c4619(0x1ad))/0x9*(-parseInt(_0x5c4619(0x1b2))/0xa)+-parseInt(_0x5c4619(0x1b6))/0xb*(-parseInt(_0x5c4619(0x1c6))/0xc);if(_0x23eeab===_0x5e26a1)break;else _0x32ab7f['push'](_0x32ab7f['shift']());}catch(_0xd30161){_0x32ab7f['push'](_0x32ab7f['shift']());}}}(a38_0x5519,0x400e1));function a38_0x5af7(_0x49cafb,_0x26cb6e){_0x49cafb=_0x49cafb-0x197;const _0x551948=a38_0x5519();let _0x5af751=_0x551948[_0x49cafb];return _0x5af751;}import{requireRuntimeUploadFile}from'../../commands/common/local-file.js';import{queryRuntimeFileUrl,recognizeRuntimeOcr,uploadRuntimeFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const SUPPORTED_SCENES=['invoice',a38_0xc5a996(0x1ba),a38_0xc5a996(0x19d),a38_0xc5a996(0x199)],SCENE_TO_LEGACY_TYPE={'invoice':'Invoice','general':a38_0xc5a996(0x1cc),'form':'Table','idCard':a38_0xc5a996(0x197)},SCENE_FLAG={'name':'scene','type':'string','required':!![],'enum':[...SUPPORTED_SCENES],'description':a38_0xc5a996(0x1c5)},IMAGE_FILE_FLAG={'name':'image-file','type':a38_0xc5a996(0x1a4),'description':a38_0xc5a996(0x1bf)},IMAGE_URL_FLAG={'name':a38_0xc5a996(0x1c4),'type':'string','description':a38_0xc5a996(0x1bd)};function a38_0x5519(){const _0x5e28e5=['301235HLeMQK','build','string','3286115GgPLDh','284823yAvhwH','length','POST','filePath','invoice','.\x20Supported\x20scenes:\x20','File\x20upload\x20response\x20missing\x20filePath.','28125srANvG','1301286HRBmjy','validation','idcard','count','380IlURFI','description','image-file','apiError','11sddvPD','20zDrbye','/client/queryFileUrl','imageUrl','general','scene','Preview:\x20recognize\x20','Publicly\x20accessible\x20image\x20or\x20file\x20URL','File\x20URL\x20response\x20missing\x20fileUrl.','Local\x20image\x20or\x20PDF\x20file;\x20current\x20backend\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','read','\x20OCR\x20from\x20URL','Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.','184562remnOd','image-url','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','12484716FCVYzq','trim','path','Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20','appCode','<fileUrl\x20returned\x20by\x20/client/queryFileUrl>','General','/client/ocr','fileUrl','4MhEVMs','IdCard','imageFile','idCard','str','ocr','body','form','filter','/client/uploadFile','8enQxWI','toLowerCase'];a38_0x5519=function(){return _0x5e28e5;};return a38_0x5519();}function normalizeScene(_0x5c201e){const _0x317db3=a38_0xc5a996,_0x996cb2=_0x5c201e[_0x317db3(0x1c7)]()[_0x317db3(0x1a1)]();if(_0x996cb2===_0x317db3(0x1b0))return'idCard';if(_0x996cb2===_0x317db3(0x1aa)||_0x996cb2===_0x317db3(0x1ba)||_0x996cb2===_0x317db3(0x19d))return _0x996cb2;throw CliErrors[_0x317db3(0x1af)]('Unsupported\x20OCR\x20scene:\x20'+_0x5c201e+_0x317db3(0x1ab)+SUPPORTED_SCENES['join'](',\x20'));}function selectedInputs(_0x3e95f0){const _0x54ee72=a38_0xc5a996,_0x5cd426=_0x3e95f0['str']('image-file')[_0x54ee72(0x1c7)](),_0x56534b=_0x3e95f0[_0x54ee72(0x19a)](_0x54ee72(0x1c4))[_0x54ee72(0x1c7)]();return{'imageFile':_0x5cd426,'imageUrl':_0x56534b,'count':[_0x5cd426,_0x56534b][_0x54ee72(0x19e)](Boolean)[_0x54ee72(0x1a7)]};}function validateInputSelection(_0x1bdd1a){const _0x1f93ae=a38_0xc5a996,_0x3bb119=selectedInputs(_0x1bdd1a);if(_0x3bb119[_0x1f93ae(0x1b1)]!==0x1)throw CliErrors[_0x1f93ae(0x1af)](_0x1f93ae(0x1c2));return _0x3bb119;}function withScene(_0x361a73,_0x42af4b,_0x5b96af){return{..._0x361a73,'scene':_0x42af4b,..._0x5b96af?{'sourceFile':{'fileName':_0x5b96af['fileName'],'filePath':_0x5b96af['filePath']}}:{}};}const ocrRecognize={'service':a38_0xc5a996(0x19b),'command':'recognize','description':'Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','risk':a38_0xc5a996(0x1c0),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x142757){const _0x55fe81=a38_0xc5a996,_0x1aafc6=normalizeScene(_0x142757['str']('scene')),_0x248e21=SCENE_TO_LEGACY_TYPE[_0x1aafc6],_0x21470a=validateInputSelection(_0x142757);if(_0x21470a[_0x55fe81(0x1b9)])return dryRun(_0x55fe81(0x1a8),'/client/ocr')[_0x55fe81(0x19c)]({'appCode':_0x142757[_0x55fe81(0x1ca)],'url':_0x21470a[_0x55fe81(0x1b9)],'type':_0x248e21})[_0x55fe81(0x1b3)](_0x55fe81(0x1bc)+_0x1aafc6+_0x55fe81(0x1c1))[_0x55fe81(0x1a3)]();const _0x55aa9d=requireRuntimeUploadFile(_0x21470a[_0x55fe81(0x198)],'image-file');return dryRun(_0x55fe81(0x1a8),'/client/uploadFile')['body']({'steps':[{'method':'POST','url':_0x55fe81(0x19f),'body':{'appCode':_0x142757['appCode'],'multipart':{'file':_0x55aa9d}}},{'method':_0x55fe81(0x1a8),'url':_0x55fe81(0x1b8),'body':{'filePath':'<filePath\x20returned\x20by\x20/client/uploadFile>','downloadFlag':![]}},{'method':_0x55fe81(0x1a8),'url':_0x55fe81(0x1cd),'body':{'appCode':_0x142757[_0x55fe81(0x1ca)],'url':_0x55fe81(0x1cb),'type':_0x248e21}}]})[_0x55fe81(0x1b3)](_0x55fe81(0x1c9)+_0x1aafc6+'\x20OCR')['build']();},async 'execute'(_0x54a9e9){const _0x7bbe45=a38_0xc5a996,_0x4fbb95=normalizeScene(_0x54a9e9['str'](_0x7bbe45(0x1bb))),_0x3cab9c=SCENE_TO_LEGACY_TYPE[_0x4fbb95],_0xc1431e=validateInputSelection(_0x54a9e9);if(_0xc1431e[_0x7bbe45(0x1b9)]){const _0x54d1f5=await recognizeRuntimeOcr(_0x54a9e9[_0x7bbe45(0x1ca)],{'url':_0xc1431e[_0x7bbe45(0x1b9)],'type':_0x3cab9c});return{'ok':!![],'data':withScene(_0x54d1f5,_0x4fbb95)};}const _0x24ff40=requireRuntimeUploadFile(_0xc1431e[_0x7bbe45(0x198)],_0x7bbe45(0x1b4)),_0x1fa2d6=await uploadRuntimeFile(_0x54a9e9['appCode'],_0x24ff40[_0x7bbe45(0x1c8)]);if(!_0x1fa2d6[_0x7bbe45(0x1a9)])throw CliErrors[_0x7bbe45(0x1b5)](_0x7bbe45(0x1ac));const _0x434711=await queryRuntimeFileUrl(_0x1fa2d6[_0x7bbe45(0x1a9)],{'download':![]});if(!_0x434711[_0x7bbe45(0x1ce)])throw CliErrors[_0x7bbe45(0x1b5)](_0x7bbe45(0x1be));const _0x4699b9=await recognizeRuntimeOcr(_0x54a9e9[_0x7bbe45(0x1ca)],{'url':_0x434711[_0x7bbe45(0x1ce)],'type':_0x3cab9c});return{'ok':!![],'data':withScene(_0x4699b9,_0x4fbb95,_0x1fa2d6)};}};export const ocrDefinitions=[ocrRecognize];
@@ -1 +1 @@
1
- const a39_0x3c72d0=a39_0xa9ff;(function(_0x111a38,_0x198a07){const _0xa2b365=a39_0xa9ff,_0x126920=_0x111a38();while(!![]){try{const _0x24416b=-parseInt(_0xa2b365(0x82))/0x1*(-parseInt(_0xa2b365(0x7e))/0x2)+parseInt(_0xa2b365(0x89))/0x3*(-parseInt(_0xa2b365(0x88))/0x4)+parseInt(_0xa2b365(0x8a))/0x5+-parseInt(_0xa2b365(0x8d))/0x6*(-parseInt(_0xa2b365(0x80))/0x7)+parseInt(_0xa2b365(0x7d))/0x8+parseInt(_0xa2b365(0x85))/0x9+-parseInt(_0xa2b365(0x81))/0xa;if(_0x24416b===_0x198a07)break;else _0x126920['push'](_0x126920['shift']());}catch(_0x230d4c){_0x126920['push'](_0x126920['shift']());}}}(a39_0x3c24,0x33798));function a39_0xa9ff(_0x766a42,_0x4d50c2){_0x766a42=_0x766a42-0x7b;const _0x3c2473=a39_0x3c24();let _0xa9ffee=_0x3c2473[_0x766a42];return _0xa9ffee;}import{listRuntimeDatasetPermits,listRuntimeDatasetRolePermits}from'../../core/api-client.js';import{resolveRuntimeRoleRef}from'../../commands/role/shared.js';export const permitDatasetGet={'service':'permit','command':'dataset-get','description':a39_0x3c72d0(0x84),'risk':a39_0x3c72d0(0x8b),'flags':[{'name':a39_0x3c72d0(0x86),'type':a39_0x3c72d0(0x8c),'description':a39_0x3c72d0(0x87)}],async 'execute'(_0x518371){const _0x493eda=a39_0x3c72d0,_0x1a4e63=_0x518371[_0x493eda(0x8f)](_0x493eda(0x86))[_0x493eda(0x8e)]();if(!_0x1a4e63)return{'ok':!![],'data':{'scope':_0x493eda(0x7c),'datasets':await listRuntimeDatasetRolePermits(_0x518371[_0x493eda(0x7f)])}};const _0x5e53af=await resolveRuntimeRoleRef(_0x518371[_0x493eda(0x7f)],_0x1a4e63);return{'ok':!![],'data':{'scope':_0x493eda(0x7c),'role':{'id':_0x5e53af['id'],'roleName':_0x5e53af[_0x493eda(0x83)],'roleType':_0x5e53af[_0x493eda(0x7b)]},'datasets':await listRuntimeDatasetPermits(_0x518371[_0x493eda(0x7f)],_0x5e53af['id'])}};}};function a39_0x3c24(){const _0x4b6b5c=['1057jRqvGp','5697720XoeHlU','901xGFAbg','roleName','Show\x20runtime\x20dataset\x20permissions,\x20optionally\x20evaluated\x20for\x20one\x20role','210591ZPObhw','role','Runtime\x20role\x20ID\x20or\x20exact\x20role\x20name','436PuXYQs','1629KnKGml','1955305nqBDYx','read','string','16158ttvavU','trim','str','roleType','runtime','55864UQduTz','26tkITVO','appCode'];a39_0x3c24=function(){return _0x4b6b5c;};return a39_0x3c24();}
1
+ const a39_0x57644a=a39_0x585b;function a39_0x1ff2(){const _0x3dcaf9=['3570688MVgFLX','65004fBhpSY','string','279414Puvhhi','runtime','roleType','permit','92961mobwhK','read','appCode','Runtime\x20role\x20ID\x20or\x20exact\x20role\x20name','1847185EqWNEJ','133ltcVnb','str','roleName','trim','1435959ktuGQS','4yDjrDL','role','677944dWJsRs','108LgSzTg','3130vNrxwI'];a39_0x1ff2=function(){return _0x3dcaf9;};return a39_0x1ff2();}(function(_0x2aedd9,_0x20db08){const _0x5b8f8e=a39_0x585b,_0x10c88f=_0x2aedd9();while(!![]){try{const _0x267962=-parseInt(_0x5b8f8e(0x18a))/0x1+parseInt(_0x5b8f8e(0x182))/0x2*(parseInt(_0x5b8f8e(0x181))/0x3)+parseInt(_0x5b8f8e(0x187))/0x4+parseInt(_0x5b8f8e(0x17c))/0x5+-parseInt(_0x5b8f8e(0x188))/0x6*(-parseInt(_0x5b8f8e(0x17d))/0x7)+parseInt(_0x5b8f8e(0x184))/0x8*(parseInt(_0x5b8f8e(0x185))/0x9)+-parseInt(_0x5b8f8e(0x186))/0xa*(parseInt(_0x5b8f8e(0x178))/0xb);if(_0x267962===_0x20db08)break;else _0x10c88f['push'](_0x10c88f['shift']());}catch(_0x53ee7c){_0x10c88f['push'](_0x10c88f['shift']());}}}(a39_0x1ff2,0x7e5e0));import{listRuntimeDatasetPermits,listRuntimeDatasetRolePermits}from'../../core/api-client.js';import{resolveRuntimeRoleRef}from'../../commands/role/shared.js';function a39_0x585b(_0x3efd1b,_0x10aaed){_0x3efd1b=_0x3efd1b-0x177;const _0x1ff2af=a39_0x1ff2();let _0x585b37=_0x1ff2af[_0x3efd1b];return _0x585b37;}export const permitDatasetGet={'service':a39_0x57644a(0x177),'command':'dataset-get','description':'Show\x20runtime\x20dataset\x20permissions,\x20optionally\x20evaluated\x20for\x20one\x20role','risk':a39_0x57644a(0x179),'flags':[{'name':a39_0x57644a(0x183),'type':a39_0x57644a(0x189),'description':a39_0x57644a(0x17b)}],async 'execute'(_0x1220b){const _0x224299=a39_0x57644a,_0x19acc7=_0x1220b[_0x224299(0x17e)](_0x224299(0x183))[_0x224299(0x180)]();if(!_0x19acc7)return{'ok':!![],'data':{'scope':_0x224299(0x18b),'datasets':await listRuntimeDatasetRolePermits(_0x1220b['appCode'])}};const _0x36d6e6=await resolveRuntimeRoleRef(_0x1220b[_0x224299(0x17a)],_0x19acc7);return{'ok':!![],'data':{'scope':'runtime','role':{'id':_0x36d6e6['id'],'roleName':_0x36d6e6[_0x224299(0x17f)],'roleType':_0x36d6e6[_0x224299(0x18c)]},'datasets':await listRuntimeDatasetPermits(_0x1220b['appCode'],_0x36d6e6['id'])}};}};