@lovrabet/lovrabet-cli 2.3.9-beta.1 → 2.3.10-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 (205) 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/approval/index.js +1 -1
  12. package/lib/commands/artifact/index.js +1 -1
  13. package/lib/commands/auth/device.js +1 -1
  14. package/lib/commands/auth/index.d.ts +2 -3
  15. package/lib/commands/auth/index.js +1 -1
  16. package/lib/commands/auth/prompt.js +1 -1
  17. package/lib/commands/bff/detail.js +1 -1
  18. package/lib/commands/bff/exec.js +1 -1
  19. package/lib/commands/bff/index.js +1 -1
  20. package/lib/commands/cli-skill/index.js +1 -1
  21. package/lib/commands/common/config-policy.js +1 -1
  22. package/lib/commands/common/constraints.js +1 -1
  23. package/lib/commands/common/flags.js +1 -1
  24. package/lib/commands/common/local-file.js +1 -1
  25. package/lib/commands/config/definitions.js +1 -1
  26. package/lib/commands/config/init.js +1 -1
  27. package/lib/commands/config/shared.js +1 -1
  28. package/lib/commands/data/import-excel.js +1 -1
  29. package/lib/commands/data/index.js +1 -1
  30. package/lib/commands/dataset/detail.js +1 -1
  31. package/lib/commands/dataset/index.js +1 -1
  32. package/lib/commands/dataset/list.js +1 -1
  33. package/lib/commands/dataset/sdk-doc.js +1 -1
  34. package/lib/commands/doctor.js +1 -1
  35. package/lib/commands/file/index.js +1 -1
  36. package/lib/commands/init.js +1 -1
  37. package/lib/commands/issue/context.js +1 -1
  38. package/lib/commands/issue/index.js +1 -1
  39. package/lib/commands/issue/report.js +1 -1
  40. package/lib/commands/kb/index.js +1 -1
  41. package/lib/commands/logs/index.js +1 -1
  42. package/lib/commands/notification/config-list.js +1 -1
  43. package/lib/commands/notification/index.js +1 -1
  44. package/lib/commands/notification/shared.js +1 -1
  45. package/lib/commands/ocr/index.js +1 -1
  46. package/lib/commands/permit/dataset-get.js +1 -1
  47. package/lib/commands/permit/dataset-set.js +1 -1
  48. package/lib/commands/permit/index.js +1 -1
  49. package/lib/commands/permit/page-get.js +1 -1
  50. package/lib/commands/permit/page-set.js +1 -1
  51. package/lib/commands/permit/role-menus-set.js +1 -1
  52. package/lib/commands/permit/role-menus.js +1 -1
  53. package/lib/commands/permit/shared.js +1 -1
  54. package/lib/commands/personal-bff/index.js +1 -1
  55. package/lib/commands/registry.js +1 -1
  56. package/lib/commands/role/create.js +1 -1
  57. package/lib/commands/role/delete.js +1 -1
  58. package/lib/commands/role/detail.js +1 -1
  59. package/lib/commands/role/index.js +1 -1
  60. package/lib/commands/role/list.js +1 -1
  61. package/lib/commands/role/shared.js +1 -1
  62. package/lib/commands/role/update.js +1 -1
  63. package/lib/commands/role/user-add.js +1 -1
  64. package/lib/commands/role/user-remove.js +1 -1
  65. package/lib/commands/schedule/index.js +1 -1
  66. package/lib/commands/schema.js +1 -1
  67. package/lib/commands/service/dynamic.js +1 -1
  68. package/lib/commands/service/function-name-adapter.js +1 -1
  69. package/lib/commands/service/index.js +1 -1
  70. package/lib/commands/service/registry.js +1 -1
  71. package/lib/commands/skill/commands/create.js +1 -1
  72. package/lib/commands/skill/commands/diagram.js +1 -1
  73. package/lib/commands/skill/commands/install.js +1 -1
  74. package/lib/commands/skill/commands/list.js +1 -1
  75. package/lib/commands/skill/commands/push.js +1 -1
  76. package/lib/commands/skill/commands/validate.js +1 -1
  77. package/lib/commands/skill/diagram.js +1 -1
  78. package/lib/commands/skill/flags.js +1 -1
  79. package/lib/commands/skill/index.js +1 -1
  80. package/lib/commands/skill/manifest-helpers.js +1 -1
  81. package/lib/commands/skill/push-execute.js +1 -1
  82. package/lib/commands/skill/push-flow-helpers.js +1 -1
  83. package/lib/commands/skill/push-retarget.js +1 -1
  84. package/lib/commands/skill/scopes.js +1 -1
  85. package/lib/commands/skill/summary.js +1 -1
  86. package/lib/commands/skill/templates.js +1 -1
  87. package/lib/commands/skill/validate.js +1 -1
  88. package/lib/commands/sql/detail.js +1 -1
  89. package/lib/commands/sql/exec.js +1 -1
  90. package/lib/commands/sql/index.js +1 -1
  91. package/lib/commands/update.js +1 -1
  92. package/lib/commands/user-account/bind.js +1 -1
  93. package/lib/commands/user-account/index.js +1 -1
  94. package/lib/commands/workspace/index.js +1 -1
  95. package/lib/config/domain-config.js +1 -1
  96. package/lib/config/schema.js +1 -1
  97. package/lib/constant/app.js +1 -1
  98. package/lib/constant/auth-mode.js +1 -1
  99. package/lib/constant/cli.js +1 -1
  100. package/lib/constant/defaults.js +1 -1
  101. package/lib/constant/distribution.js +1 -1
  102. package/lib/constant/domain.js +1 -1
  103. package/lib/constant/env.d.ts +5 -6
  104. package/lib/constant/env.js +1 -1
  105. package/lib/constant/output.js +1 -1
  106. package/lib/constant/product.js +1 -1
  107. package/lib/constant/region.js +1 -1
  108. package/lib/constant/risk.js +1 -1
  109. package/lib/constant/url.js +1 -1
  110. package/lib/context.d.ts +3 -13
  111. package/lib/context.js +1 -1
  112. package/lib/core/api-client.js +1 -1
  113. package/lib/core/db-resolver.js +1 -1
  114. package/lib/core/kb-management-client.js +1 -1
  115. package/lib/core/kb-sdk-errors.js +1 -1
  116. package/lib/core/kb-search-client.js +1 -1
  117. package/lib/core/sdk-client.js +1 -1
  118. package/lib/errors.js +1 -1
  119. package/lib/framework/access-error.js +1 -1
  120. package/lib/framework/build-all-flags.js +1 -1
  121. package/lib/framework/dryrun.js +1 -1
  122. package/lib/framework/flags.js +1 -1
  123. package/lib/framework/help.js +1 -1
  124. package/lib/framework/index.js +1 -1
  125. package/lib/framework/output.js +1 -1
  126. package/lib/framework/preparse.js +1 -1
  127. package/lib/framework/rate-limit.js +1 -1
  128. package/lib/framework/raw-flags.js +1 -1
  129. package/lib/framework/response.js +1 -1
  130. package/lib/framework/runner-confirmation.js +1 -1
  131. package/lib/framework/runner-error.js +1 -1
  132. package/lib/framework/runner.d.ts +2 -1
  133. package/lib/framework/runner.js +1 -1
  134. package/lib/framework/schema-export.js +1 -1
  135. package/lib/framework/service-order.js +1 -1
  136. package/lib/framework/types.d.ts +2 -0
  137. package/lib/framework/types.js +1 -1
  138. package/lib/generated/build-info.d.ts +4 -4
  139. package/lib/generated/build-info.js +1 -1
  140. package/lib/generated/official-routing.js +1 -1
  141. package/lib/generated/routing-contract.js +1 -1
  142. package/lib/help.js +1 -1
  143. package/lib/postinstall.js +1 -1
  144. package/lib/runtime/confirmation.js +1 -1
  145. package/lib/runtime/event.js +1 -1
  146. package/lib/runtime/index.js +1 -1
  147. package/lib/runtime/queue.js +1 -1
  148. package/lib/runtime/resolve.js +1 -1
  149. package/lib/services/dataset-import/auto-id-runner.js +1 -1
  150. package/lib/services/dataset-import/excel-reader.js +1 -1
  151. package/lib/services/dataset-import/image-bytes.js +1 -1
  152. package/lib/services/dataset-import/image-ooxml.js +1 -1
  153. package/lib/services/dataset-import/image-runner.js +1 -1
  154. package/lib/services/dataset-import/metadata.js +1 -1
  155. package/lib/services/dataset-import/preview.js +1 -1
  156. package/lib/services/dataset-import/runner.js +1 -1
  157. package/lib/skills/builtin-skill.js +1 -1
  158. package/lib/skills/npx-skills-add.js +1 -1
  159. package/lib/skills/runtime-skill-sync/constants.js +1 -1
  160. package/lib/skills/runtime-skill-sync/fs-utils.js +1 -1
  161. package/lib/skills/runtime-skill-sync/hashing.js +1 -1
  162. package/lib/skills/runtime-skill-sync/install-target.js +1 -1
  163. package/lib/skills/runtime-skill-sync/links.js +1 -1
  164. package/lib/skills/runtime-skill-sync/list-local.js +1 -1
  165. package/lib/skills/runtime-skill-sync/local-files.js +1 -1
  166. package/lib/skills/runtime-skill-sync/materialize.js +1 -1
  167. package/lib/skills/runtime-skill-sync/metadata.js +1 -1
  168. package/lib/skills/runtime-skill-sync/paths.js +1 -1
  169. package/lib/skills/runtime-skill-sync/push.js +1 -1
  170. package/lib/skills/runtime-skill-sync/scopes.js +1 -1
  171. package/lib/skills/runtime-skill-sync/zip-codec.js +1 -1
  172. package/lib/skills/runtime-skill-sync/zip-package.js +1 -1
  173. package/lib/skills/runtime-skill-sync.js +1 -1
  174. package/lib/skills/skill-presence.js +1 -1
  175. package/lib/utils/access-key-redaction.js +1 -1
  176. package/lib/utils/apply-jq-filter.js +1 -1
  177. package/lib/utils/cli-version-check.js +1 -1
  178. package/lib/utils/cli-version-policy.js +1 -1
  179. package/lib/utils/logger.js +1 -1
  180. package/lib/utils/lossless-json.js +1 -1
  181. package/lib/utils/params.js +1 -1
  182. package/lib/utils/positive-safe-integer.js +1 -1
  183. package/lib/utils/redaction.js +1 -1
  184. package/lib/utils/runtime-user-id.js +1 -1
  185. package/lib/utils/update-notice.js +1 -1
  186. package/lib/utils/version.js +1 -1
  187. package/lib/utils/write-cli-side-channel.js +1 -1
  188. package/package.json +1 -1
  189. package/skills/lovrabet/SKILL.md +31 -132
  190. package/skills/lovrabet/guides/app-resolution.md +39 -139
  191. package/skills/lovrabet/guides/dataset-and-data-workflow.md +4 -3
  192. package/skills/lovrabet/guides/development-intent-handoff.md +7 -5
  193. package/skills/lovrabet/guides/sql-and-bff-workflow.md +12 -27
  194. package/skills/lovrabet/guides/troubleshooting.md +11 -31
  195. package/skills/lovrabet/references/dataset-discovery-workflow.md +10 -48
  196. package/skills/lovrabet/references/instant-api-workflow.md +4 -11
  197. package/skills/lovrabet/references/lovrabet-app.md +6 -33
  198. package/skills/lovrabet/references/lovrabet-auth.md +16 -9
  199. package/skills/lovrabet/references/lovrabet-bff-workflow.md +9 -34
  200. package/skills/lovrabet/references/lovrabet-config.md +49 -31
  201. package/skills/lovrabet/references/lovrabet-kb-workflow.md +2 -2
  202. package/skills/lovrabet/references/lovrabet-service-tree.md +11 -9
  203. package/skills/lovrabet/references/lovrabet-sql-workflow.md +9 -34
  204. package/skills/lovrabet/references/lovrabet-workspace.md +12 -11
  205. package/skills/lovrabet.manifest.json +3 -3
@@ -1 +1 @@
1
- const a54_0x1ceae6=a54_0x25a0;(function(_0x4fcbfd,_0x64265b){const _0xd6f11c=a54_0x25a0,_0xbe1a00=_0x4fcbfd();while(!![]){try{const _0x5e582a=-parseInt(_0xd6f11c(0x199))/0x1+-parseInt(_0xd6f11c(0x17e))/0x2+parseInt(_0xd6f11c(0x185))/0x3*(parseInt(_0xd6f11c(0x18b))/0x4)+-parseInt(_0xd6f11c(0x18e))/0x5+parseInt(_0xd6f11c(0x182))/0x6+-parseInt(_0xd6f11c(0x196))/0x7*(parseInt(_0xd6f11c(0x188))/0x8)+-parseInt(_0xd6f11c(0x18c))/0x9*(-parseInt(_0xd6f11c(0x187))/0xa);if(_0x5e582a===_0x64265b)break;else _0xbe1a00['push'](_0xbe1a00['shift']());}catch(_0x4a7f10){_0xbe1a00['push'](_0xbe1a00['shift']());}}}(a54_0x1410,0xcd680));import{createRuntimeAppRole}from'../../core/api-client.js';function a54_0x25a0(_0xce5f9,_0x4d11a0){_0xce5f9=_0xce5f9-0x17d;const _0x141052=a54_0x1410();let _0x25a07c=_0x141052[_0xce5f9];return _0x25a07c;}import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';function a54_0x1410(){const _0xf05e27=['7227366wNGspK','Create\x20a\x20runtime\x20CUSTOM\x20role','description','1929MNBIbK','high-risk-write','20BEiAOz','400zfAufJ','Role\x20name','str','2152VeaRaG','9070443hQHpWX','body','2116120vlJnQk','string','Preview:\x20create\x20a\x20runtime\x20CUSTOM\x20role','create','build','remark','trim','name','195916puPlgR','Creates\x20a\x20custom\x20role\x20in\x20the\x20current\x20runtime\x20app.\x20After\x20creation\x20it\x20can\x20be\x20used\x20for\x20member\x20and\x20resource\x20permissions.','role','635553PnUDcX','--name\x20must\x20not\x20be\x20blank.','533256jiNwJe','/client/permit/role/create','validation','POST'];a54_0x1410=function(){return _0xf05e27;};return a54_0x1410();}import{projectRuntimeRole,readOptionalRuntimeRoleCode,ROLE_CODE_FLAG,runtimeRoleWriteResult}from'../../commands/role/shared.js';function input(_0x3d9a4c){const _0x185fee=a54_0x25a0,_0x3e67a2=_0x3d9a4c[_0x185fee(0x18a)](_0x185fee(0x195))[_0x185fee(0x194)]();if(!_0x3e67a2)throw CliErrors[_0x185fee(0x180)](_0x185fee(0x17d));const _0x161deb=_0x3d9a4c[_0x185fee(0x18a)]('remark')[_0x185fee(0x194)](),_0x442232=readOptionalRuntimeRoleCode(_0x3d9a4c);return{'appCode':_0x3d9a4c['appCode'],'roleName':_0x3e67a2,..._0x442232?{'roleCode':_0x442232}:{},..._0x161deb?{'remark':_0x161deb}:{}};}export const roleCreate={'service':a54_0x1ceae6(0x198),'command':a54_0x1ceae6(0x191),'description':a54_0x1ceae6(0x183),'risk':a54_0x1ceae6(0x186),'confirmationDescription':a54_0x1ceae6(0x197),'flags':[{'name':a54_0x1ceae6(0x195),'type':a54_0x1ceae6(0x18f),'required':!![],'description':a54_0x1ceae6(0x189)},ROLE_CODE_FLAG,{'name':a54_0x1ceae6(0x193),'type':a54_0x1ceae6(0x18f),'description':'Optional\x20role\x20remark'}],async 'validate'(_0x1d1e1c){input(_0x1d1e1c);},async 'dryRun'(_0x41f2eb){const _0x300bb6=a54_0x1ceae6;return dryRun(_0x300bb6(0x181),'/client/permit/role/create')[_0x300bb6(0x18d)]({'roleType':'CUSTOM',...input(_0x41f2eb)})[_0x300bb6(0x184)](_0x300bb6(0x190))[_0x300bb6(0x192)]();},async 'execute'(_0x31cd87){const _0xed0f5f=a54_0x1ceae6,_0x1b67fa=await createRuntimeAppRole(input(_0x31cd87));return{'ok':!![],'data':runtimeRoleWriteResult(_0xed0f5f(0x191),{'roleId':_0x1b67fa['id']},null,projectRuntimeRole(_0x1b67fa),{'method':_0xed0f5f(0x181),'path':_0xed0f5f(0x17f)})};}};
1
+ const a54_0x4d0fe9=a54_0x25c8;function a54_0x2c6a(){const _0x3ccc85=['remark','68spTwpd','4459192VIICUK','10240212iTDnTU','build','Role\x20name','Preview:\x20create\x20a\x20runtime\x20CUSTOM\x20role','320286aSALLC','2201301gZoIqn','15jSusyJ','--name\x20must\x20not\x20be\x20blank.','str','name','Create\x20a\x20runtime\x20CUSTOM\x20role','21916MGqwHl','appCode','161SAJblx','/client/permit/role/create','role','description','trim','CUSTOM','string','POST','11VOYujZ','30xhaqYn','470293edtQFE','95226lmvIiw'];a54_0x2c6a=function(){return _0x3ccc85;};return a54_0x2c6a();}(function(_0x56aada,_0x522c56){const _0x43a046=a54_0x25c8,_0x164a81=_0x56aada();while(!![]){try{const _0x30f3a6=-parseInt(_0x43a046(0x1a6))/0x1+parseInt(_0x43a046(0x1a9))/0x2*(-parseInt(_0x43a046(0x1a7))/0x3)+parseInt(_0x43a046(0x19a))/0x4*(parseInt(_0x43a046(0x195))/0x5)+-parseInt(_0x43a046(0x1af))/0x6*(-parseInt(_0x43a046(0x19c))/0x7)+-parseInt(_0x43a046(0x1aa))/0x8+parseInt(_0x43a046(0x194))/0x9*(parseInt(_0x43a046(0x1a5))/0xa)+-parseInt(_0x43a046(0x1a4))/0xb*(-parseInt(_0x43a046(0x1ab))/0xc);if(_0x30f3a6===_0x522c56)break;else _0x164a81['push'](_0x164a81['shift']());}catch(_0x3a1674){_0x164a81['push'](_0x164a81['shift']());}}}(a54_0x2c6a,0xb0dae));import{createRuntimeAppRole}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';import{projectRuntimeRole,readOptionalRuntimeRoleCode,ROLE_CODE_FLAG,runtimeRoleWriteResult}from'../../commands/role/shared.js';function a54_0x25c8(_0x57c265,_0x1eff25){_0x57c265=_0x57c265-0x194;const _0x2c6a14=a54_0x2c6a();let _0x25c838=_0x2c6a14[_0x57c265];return _0x25c838;}function input(_0x2c8ad3){const _0x45fd50=a54_0x25c8,_0x48047d=_0x2c8ad3[_0x45fd50(0x197)](_0x45fd50(0x198))[_0x45fd50(0x1a0)]();if(!_0x48047d)throw CliErrors['validation'](_0x45fd50(0x196));const _0x4f1db0=_0x2c8ad3[_0x45fd50(0x197)](_0x45fd50(0x1a8))['trim'](),_0xef526f=readOptionalRuntimeRoleCode(_0x2c8ad3);return{'appCode':_0x2c8ad3[_0x45fd50(0x19b)],'roleName':_0x48047d,..._0xef526f?{'roleCode':_0xef526f}:{},..._0x4f1db0?{'remark':_0x4f1db0}:{}};}export const roleCreate={'service':a54_0x4d0fe9(0x19e),'command':'create','description':a54_0x4d0fe9(0x199),'risk':'high-risk-write','confirmationDescription':'Creates\x20a\x20custom\x20role\x20in\x20the\x20current\x20runtime\x20app.\x20After\x20creation\x20it\x20can\x20be\x20used\x20for\x20member\x20and\x20resource\x20permissions.','flags':[{'name':a54_0x4d0fe9(0x198),'type':a54_0x4d0fe9(0x1a2),'required':!![],'description':a54_0x4d0fe9(0x1ad)},ROLE_CODE_FLAG,{'name':a54_0x4d0fe9(0x1a8),'type':a54_0x4d0fe9(0x1a2),'description':'Optional\x20role\x20remark'}],async 'validate'(_0x41cf1c){input(_0x41cf1c);},async 'dryRun'(_0x53bc4d){const _0x21e34a=a54_0x4d0fe9;return dryRun(_0x21e34a(0x1a3),_0x21e34a(0x19d))['body']({'roleType':_0x21e34a(0x1a1),...input(_0x53bc4d)})[_0x21e34a(0x19f)](_0x21e34a(0x1ae))[_0x21e34a(0x1ac)]();},async 'execute'(_0x3db59c){const _0x4ad07f=a54_0x4d0fe9,_0x17f117=await createRuntimeAppRole(input(_0x3db59c));return{'ok':!![],'data':runtimeRoleWriteResult('create',{'roleId':_0x17f117['id']},null,projectRuntimeRole(_0x17f117),{'method':'POST','path':_0x4ad07f(0x19d)})};}};
@@ -1 +1 @@
1
- const a55_0x45d875=a55_0x6e7a;function a55_0x1a0c(){const _0x23fc6=['Delete\x20a\x20runtime\x20CUSTOM\x20role','105TfxrnT','Deletes\x20the\x20custom\x20role\x20in\x20the\x20current\x20runtime\x20app.\x20Membership\x20and\x20permission\x20config\x20for\x20that\x20role\x20may\x20become\x20invalid.','14968LITmfi','/client/permit/role/delete','10458UGLnmI','721683OLMqWG','110lbgzSP','body','appCode','5tbMxyZ','1088LFrAXv','3534AzSdcY','delete','7hapytx','POST','role','143ZgatJI','12754rhpAqY','Preview:\x20delete\x20a\x20runtime\x20CUSTOM\x20role','228612SSVtzB','num','51601CNKxxP'];a55_0x1a0c=function(){return _0x23fc6;};return a55_0x1a0c();}(function(_0x532e2e,_0x523117){const _0x4c05f2=a55_0x6e7a,_0x3e4d39=_0x532e2e();while(!![]){try{const _0xda812f=parseInt(_0x4c05f2(0x1c4))/0x1*(-parseInt(_0x4c05f2(0x1c8))/0x2)+-parseInt(_0x4c05f2(0x1d3))/0x3+parseInt(_0x4c05f2(0x1d0))/0x4*(-parseInt(_0x4c05f2(0x1d7))/0x5)+parseInt(_0x4c05f2(0x1c2))/0x6*(-parseInt(_0x4c05f2(0x1ce))/0x7)+-parseInt(_0x4c05f2(0x1d8))/0x8*(-parseInt(_0x4c05f2(0x1d2))/0x9)+-parseInt(_0x4c05f2(0x1d4))/0xa*(-parseInt(_0x4c05f2(0x1cc))/0xb)+parseInt(_0x4c05f2(0x1ca))/0xc*(parseInt(_0x4c05f2(0x1c7))/0xd);if(_0xda812f===_0x523117)break;else _0x3e4d39['push'](_0x3e4d39['shift']());}catch(_0x39dc86){_0x3e4d39['push'](_0x3e4d39['shift']());}}}(a55_0x1a0c,0x1da49));import{deleteRuntimeAppRole}from'../../core/api-client.js';import{dryRun}from'../../framework/dryrun.js';function a55_0x6e7a(_0xb69a58,_0x152134){_0xb69a58=_0xb69a58-0x1c2;const _0x1a0c0a=a55_0x1a0c();let _0x6e7af3=_0x1a0c0a[_0xb69a58];return _0x6e7af3;}import{assertCustomRuntimeRole,getRuntimeRoleById,projectRuntimeRole,ROLE_ID_FLAG,runtimeRoleWriteResult}from'../../commands/role/shared.js';async function prepare(_0x566366){const _0x424d76=a55_0x6e7a,_0x382fec=await getRuntimeRoleById(_0x566366[_0x424d76(0x1d6)],_0x566366[_0x424d76(0x1cb)]('id'));return assertCustomRuntimeRole(_0x382fec,'delete'),_0x382fec;}export const roleDelete={'service':a55_0x45d875(0x1c6),'command':a55_0x45d875(0x1c3),'description':a55_0x45d875(0x1cd),'risk':'high-risk-write','confirmationDescription':a55_0x45d875(0x1cf),'flags':[ROLE_ID_FLAG],async 'dryRun'(_0x18b799){const _0x15baa5=a55_0x45d875,_0x130170=await prepare(_0x18b799);return dryRun(_0x15baa5(0x1c5),_0x15baa5(0x1d1))[_0x15baa5(0x1d5)]({'id':_0x130170['id']})['description'](_0x15baa5(0x1c9))['build']();},async 'execute'(_0x20c8bb){const _0x1673b2=a55_0x45d875,_0x3355ce=await prepare(_0x20c8bb);return await deleteRuntimeAppRole(_0x3355ce['id']),{'ok':!![],'data':runtimeRoleWriteResult(_0x1673b2(0x1c3),{'roleId':_0x3355ce['id']},projectRuntimeRole(_0x3355ce),null,{'method':_0x1673b2(0x1c5),'path':_0x1673b2(0x1d1)})};}};
1
+ const a55_0x6d73bc=a55_0x3b25;(function(_0x1d64f1,_0x2754cb){const _0x12b560=a55_0x3b25,_0x4f00dd=_0x1d64f1();while(!![]){try{const _0xe7c6c7=parseInt(_0x12b560(0xa5))/0x1*(-parseInt(_0x12b560(0xad))/0x2)+parseInt(_0x12b560(0xb0))/0x3*(parseInt(_0x12b560(0xb2))/0x4)+-parseInt(_0x12b560(0xa8))/0x5+-parseInt(_0x12b560(0x9f))/0x6*(-parseInt(_0x12b560(0x9e))/0x7)+-parseInt(_0x12b560(0xa7))/0x8+parseInt(_0x12b560(0xa2))/0x9*(-parseInt(_0x12b560(0xac))/0xa)+-parseInt(_0x12b560(0xa6))/0xb*(-parseInt(_0x12b560(0xb1))/0xc);if(_0xe7c6c7===_0x2754cb)break;else _0x4f00dd['push'](_0x4f00dd['shift']());}catch(_0x42802f){_0x4f00dd['push'](_0x4f00dd['shift']());}}}(a55_0x5d15,0x6cc10));import{deleteRuntimeAppRole}from'../../core/api-client.js';function a55_0x5d15(){const _0x15d9a1=['role','Delete\x20a\x20runtime\x20CUSTOM\x20role','1OgjChY','9349417xwGbXD','3734816oLXyWP','2498650aQrJrg','Deletes\x20the\x20custom\x20role\x20in\x20the\x20current\x20runtime\x20app.\x20Membership\x20and\x20permission\x20config\x20for\x20that\x20role\x20may\x20become\x20invalid.','build','Preview:\x20delete\x20a\x20runtime\x20CUSTOM\x20role','20SKBujI','763862PQLHBw','num','delete','57711UMjUpI','24CtkhEU','8tvjoxB','1141KOGVvg','11238eFbCAI','POST','appCode','1123641aHFVoi'];a55_0x5d15=function(){return _0x15d9a1;};return a55_0x5d15();}import{dryRun}from'../../framework/dryrun.js';import{assertCustomRuntimeRole,getRuntimeRoleById,projectRuntimeRole,ROLE_ID_FLAG,runtimeRoleWriteResult}from'../../commands/role/shared.js';async function prepare(_0x4e67cd){const _0x2f5c5d=a55_0x3b25,_0x2a97a2=await getRuntimeRoleById(_0x4e67cd[_0x2f5c5d(0xa1)],_0x4e67cd[_0x2f5c5d(0xae)]('id'));return assertCustomRuntimeRole(_0x2a97a2,'delete'),_0x2a97a2;}function a55_0x3b25(_0x55806a,_0x2356e2){_0x55806a=_0x55806a-0x9e;const _0x5d15af=a55_0x5d15();let _0x3b252e=_0x5d15af[_0x55806a];return _0x3b252e;}export const roleDelete={'service':a55_0x6d73bc(0xa3),'command':a55_0x6d73bc(0xaf),'description':a55_0x6d73bc(0xa4),'risk':'high-risk-write','confirmationDescription':a55_0x6d73bc(0xa9),'flags':[ROLE_ID_FLAG],async 'dryRun'(_0x3b696d){const _0x3500c3=a55_0x6d73bc,_0x206d22=await prepare(_0x3b696d);return dryRun('POST','/client/permit/role/delete')['body']({'id':_0x206d22['id']})['description'](_0x3500c3(0xab))[_0x3500c3(0xaa)]();},async 'execute'(_0x4d3165){const _0xd7d19=a55_0x6d73bc,_0x10afae=await prepare(_0x4d3165);return await deleteRuntimeAppRole(_0x10afae['id']),{'ok':!![],'data':runtimeRoleWriteResult(_0xd7d19(0xaf),{'roleId':_0x10afae['id']},projectRuntimeRole(_0x10afae),null,{'method':_0xd7d19(0xa0),'path':'/client/permit/role/delete'})};}};
@@ -1 +1 @@
1
- function a56_0x3761(){const _0x458b23=['2440770LWPDbs','28UQXyVz','805600oCmSaw','appCode','num','role','851342BRhKkJ','read','9dSAaJk','165715edJxxN','370471CjODWp','1920970eBrpBu','11577ULaLwF','7UdoEkM','runtime'];a56_0x3761=function(){return _0x458b23;};return a56_0x3761();}function a56_0x1793(_0x8013ae,_0xbfd834){_0x8013ae=_0x8013ae-0x10d;const _0x376187=a56_0x3761();let _0x1793e5=_0x376187[_0x8013ae];return _0x1793e5;}const a56_0x5de456=a56_0x1793;(function(_0xc8a9ac,_0x2ca068){const _0x2dfa30=a56_0x1793,_0x4951a1=_0xc8a9ac();while(!![]){try{const _0x5a1ebb=parseInt(_0x2dfa30(0x115))/0x1+parseInt(_0x2dfa30(0x111))/0x2+parseInt(_0x2dfa30(0x117))/0x3*(-parseInt(_0x2dfa30(0x11b))/0x4)+-parseInt(_0x2dfa30(0x114))/0x5+-parseInt(_0x2dfa30(0x11a))/0x6*(parseInt(_0x2dfa30(0x118))/0x7)+parseInt(_0x2dfa30(0x10d))/0x8+-parseInt(_0x2dfa30(0x113))/0x9*(parseInt(_0x2dfa30(0x116))/0xa);if(_0x5a1ebb===_0x2ca068)break;else _0x4951a1['push'](_0x4951a1['shift']());}catch(_0x52e318){_0x4951a1['push'](_0x4951a1['shift']());}}}(a56_0x3761,0x3a0e2));import{getRuntimeRoleById,projectRuntimeRole,ROLE_ID_FLAG}from'../../commands/role/shared.js';export const roleDetail={'service':a56_0x5de456(0x110),'command':'detail','description':'Show\x20one\x20runtime\x20role\x20by\x20ID','risk':a56_0x5de456(0x112),'flags':[ROLE_ID_FLAG],async 'execute'(_0x4dfd85){const _0x53d6e1=a56_0x5de456,_0x17ad19=await getRuntimeRoleById(_0x4dfd85[_0x53d6e1(0x10e)],_0x4dfd85[_0x53d6e1(0x10f)]('id'));return{'ok':!![],'data':{'scope':_0x53d6e1(0x119),'role':projectRuntimeRole(_0x17ad19)}};}};
1
+ const a56_0x164437=a56_0x46d0;(function(_0x973af6,_0x4ebd8e){const _0x9a2996=a56_0x46d0,_0x14936c=_0x973af6();while(!![]){try{const _0x159d80=parseInt(_0x9a2996(0x17b))/0x1*(parseInt(_0x9a2996(0x17d))/0x2)+parseInt(_0x9a2996(0x176))/0x3*(parseInt(_0x9a2996(0x177))/0x4)+parseInt(_0x9a2996(0x174))/0x5+parseInt(_0x9a2996(0x182))/0x6+-parseInt(_0x9a2996(0x175))/0x7*(-parseInt(_0x9a2996(0x17f))/0x8)+-parseInt(_0x9a2996(0x173))/0x9+-parseInt(_0x9a2996(0x17c))/0xa*(parseInt(_0x9a2996(0x179))/0xb);if(_0x159d80===_0x4ebd8e)break;else _0x14936c['push'](_0x14936c['shift']());}catch(_0x4be8d5){_0x14936c['push'](_0x14936c['shift']());}}}(a56_0x3090,0x83dad));import{getRuntimeRoleById,projectRuntimeRole,ROLE_ID_FLAG}from'../../commands/role/shared.js';export const roleDetail={'service':'role','command':a56_0x164437(0x178),'description':'Show\x20one\x20runtime\x20role\x20by\x20ID','risk':a56_0x164437(0x181),'flags':[ROLE_ID_FLAG],async 'execute'(_0x326a3b){const _0x238d75=a56_0x164437,_0x180eb7=await getRuntimeRoleById(_0x326a3b[_0x238d75(0x17e)],_0x326a3b[_0x238d75(0x180)]('id'));return{'ok':!![],'data':{'scope':_0x238d75(0x17a),'role':projectRuntimeRole(_0x180eb7)}};}};function a56_0x46d0(_0x4a730d,_0x11d612){_0x4a730d=_0x4a730d-0x173;const _0x3090ca=a56_0x3090();let _0x46d0f7=_0x3090ca[_0x4a730d];return _0x46d0f7;}function a56_0x3090(){const _0x56630d=['read','4586406ePCVSG','4581747ejrFQK','1432270YvkpMh','6164466YEyyyM','4548IcXwRr','2396wtjHAs','detail','23324983wdRxiw','runtime','2tQfqJY','10dZQfyD','330036sMzltv','appCode','8Fhmjzd','num'];a56_0x3090=function(){return _0x56630d;};return a56_0x3090();}
@@ -1 +1 @@
1
- (function(_0x204d82,_0x27163f){const _0x467096=a57_0x2c76,_0xc35d6d=_0x204d82();while(!![]){try{const _0x26091c=parseInt(_0x467096(0x119))/0x1*(-parseInt(_0x467096(0x10f))/0x2)+parseInt(_0x467096(0x116))/0x3*(-parseInt(_0x467096(0x118))/0x4)+parseInt(_0x467096(0x112))/0x5*(-parseInt(_0x467096(0x10d))/0x6)+-parseInt(_0x467096(0x113))/0x7*(-parseInt(_0x467096(0x110))/0x8)+-parseInt(_0x467096(0x117))/0x9*(-parseInt(_0x467096(0x114))/0xa)+-parseInt(_0x467096(0x10e))/0xb*(-parseInt(_0x467096(0x111))/0xc)+parseInt(_0x467096(0x115))/0xd;if(_0x26091c===_0x27163f)break;else _0xc35d6d['push'](_0xc35d6d['shift']());}catch(_0x354da9){_0xc35d6d['push'](_0xc35d6d['shift']());}}}(a57_0x4a8b,0xeee7b));import{roleList}from'../../commands/role/list.js';import{roleDetail}from'../../commands/role/detail.js';function a57_0x2c76(_0x3b4f07,_0x45ab6c){_0x3b4f07=_0x3b4f07-0x10d;const _0x4a8ba6=a57_0x4a8b();let _0x2c767e=_0x4a8ba6[_0x3b4f07];return _0x2c767e;}import{roleCreate}from'../../commands/role/create.js';function a57_0x4a8b(){const _0x4ac334=['25604865KXtvai','6zoDUxb','3375gFHmZc','3849784OYEOJc','1XZaTIM','19212DOTiwK','55nYLFoz','3309810ceEWyR','1232680ijLDnk','521292wsNlYM','545FLbZmU','77ZEJZcd','27350PaGToY'];a57_0x4a8b=function(){return _0x4ac334;};return a57_0x4a8b();}import{roleUpdate}from'../../commands/role/update.js';import{roleDelete}from'../../commands/role/delete.js';import{roleUserAdd}from'../../commands/role/user-add.js';import{roleUserRemove}from'../../commands/role/user-remove.js';export const roleDefinitions=[roleList,roleDetail,roleCreate,roleUpdate,roleDelete,roleUserAdd,roleUserRemove];
1
+ (function(_0x194b21,_0x30b61f){const _0x3ebe47=a57_0x5bad,_0x2aa016=_0x194b21();while(!![]){try{const _0x380f40=-parseInt(_0x3ebe47(0xaa))/0x1+-parseInt(_0x3ebe47(0xab))/0x2*(-parseInt(_0x3ebe47(0xac))/0x3)+parseInt(_0x3ebe47(0xa6))/0x4*(parseInt(_0x3ebe47(0xa8))/0x5)+-parseInt(_0x3ebe47(0xad))/0x6*(parseInt(_0x3ebe47(0xae))/0x7)+-parseInt(_0x3ebe47(0xa7))/0x8*(parseInt(_0x3ebe47(0xa9))/0x9)+-parseInt(_0x3ebe47(0xa5))/0xa+-parseInt(_0x3ebe47(0xb0))/0xb*(-parseInt(_0x3ebe47(0xaf))/0xc);if(_0x380f40===_0x30b61f)break;else _0x2aa016['push'](_0x2aa016['shift']());}catch(_0x4b447c){_0x2aa016['push'](_0x2aa016['shift']());}}}(a57_0x31f4,0x2f2b6));import{roleList}from'../../commands/role/list.js';import{roleDetail}from'../../commands/role/detail.js';import{roleCreate}from'../../commands/role/create.js';function a57_0x5bad(_0x4244ff,_0x4795cf){_0x4244ff=_0x4244ff-0xa5;const _0x31f426=a57_0x31f4();let _0x5bad38=_0x31f426[_0x4244ff];return _0x5bad38;}import{roleUpdate}from'../../commands/role/update.js';import{roleDelete}from'../../commands/role/delete.js';import{roleUserAdd}from'../../commands/role/user-add.js';import{roleUserRemove}from'../../commands/role/user-remove.js';export const roleDefinitions=[roleList,roleDetail,roleCreate,roleUpdate,roleDelete,roleUserAdd,roleUserRemove];function a57_0x31f4(){const _0x55787c=['18TENlLv','227175JElLRo','616RcIako','654SkcGLU','618riEwSn','12194DkQZXB','61920pXszsu','1056HPnEfZ','176100TkLtyp','308sFpglO','721904YKHsTr','15285BXsaZb'];a57_0x31f4=function(){return _0x55787c;};return a57_0x31f4();}
@@ -1 +1 @@
1
- function a58_0x47a3(_0x4d03c8,_0x168508){_0x4d03c8=_0x4d03c8-0x7b;const _0x7c0f4b=a58_0x7c0f();let _0x47a340=_0x7c0f4b[_0x4d03c8];return _0x47a340;}const a58_0x8cc7c5=a58_0x47a3;(function(_0x1e52a8,_0xa2912){const _0x19bfae=a58_0x47a3,_0x1279b2=_0x1e52a8();while(!![]){try{const _0x3e3832=-parseInt(_0x19bfae(0x95))/0x1*(parseInt(_0x19bfae(0xa1))/0x2)+parseInt(_0x19bfae(0x98))/0x3*(-parseInt(_0x19bfae(0x96))/0x4)+parseInt(_0x19bfae(0x9d))/0x5+-parseInt(_0x19bfae(0x9a))/0x6+parseInt(_0x19bfae(0x84))/0x7+parseInt(_0x19bfae(0x7c))/0x8*(-parseInt(_0x19bfae(0x97))/0x9)+parseInt(_0x19bfae(0x90))/0xa;if(_0x3e3832===_0xa2912)break;else _0x1279b2['push'](_0x1279b2['shift']());}catch(_0x4b9f6e){_0x1279b2['push'](_0x1279b2['shift']());}}}(a58_0x7c0f,0xc9f93));import{listRuntimeAppRoles}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{listAllRuntimeRoles,projectRuntimeRole,RUNTIME_ROLE_TYPES}from'../../commands/role/shared.js';function a58_0x7c0f(){const _0x3b7b66=['Fuzzy\x20role-name\x20filter','num','--page\x20must\x20be\x20a\x20positive\x20integer.','filter','28971910HESdAA','--pagesize\x20must\x20be\x20an\x20integer\x20from\x201\x20to\x20100.','roleType','Invalid\x20runtime\x20role\x20type:\x20','List\x20runtime\x20roles\x20for\x20the\x20current\x20app','5138GMLQPH','27212kQmdut','1737LVvmcB','438uSVrSH','items','5786718DfUnEi','includes','string','6390395iHxBmw','name','str','pagesize','494kNHeJE','role','runtime','isSafeInteger','40280LJmCmJ','read','appCode','map','toUpperCase','slice','list','length','5953815WLIuDz','type','paging','validation','number','page','Page\x20number','Page\x20size\x20from\x201\x20to\x20100'];a58_0x7c0f=function(){return _0x3b7b66;};return a58_0x7c0f();}export const roleList={'service':a58_0x8cc7c5(0xa2),'command':a58_0x8cc7c5(0x82),'description':a58_0x8cc7c5(0x94),'risk':a58_0x8cc7c5(0x7d),'flags':[{'name':'type','type':a58_0x8cc7c5(0x9c),'enum':RUNTIME_ROLE_TYPES,'description':'Runtime\x20role\x20type'},{'name':a58_0x8cc7c5(0x9e),'type':a58_0x8cc7c5(0x9c),'description':a58_0x8cc7c5(0x8c)},{'name':a58_0x8cc7c5(0x89),'type':a58_0x8cc7c5(0x88),'default':0x1,'description':a58_0x8cc7c5(0x8a)},{'name':a58_0x8cc7c5(0xa0),'type':a58_0x8cc7c5(0x88),'default':0x64,'description':a58_0x8cc7c5(0x8b)}],async 'validate'(_0x4e1a60){const _0x5046f8=a58_0x8cc7c5,_0xb4c4d3=_0x4e1a60[_0x5046f8(0x9f)](_0x5046f8(0x85))[_0x5046f8(0x80)]();if(_0xb4c4d3&&!RUNTIME_ROLE_TYPES[_0x5046f8(0x9b)](_0xb4c4d3))throw CliErrors[_0x5046f8(0x87)](_0x5046f8(0x93)+_0xb4c4d3+'.');const _0x20f69e=_0x4e1a60[_0x5046f8(0x8d)]('page',0x1),_0xd04b97=_0x4e1a60[_0x5046f8(0x8d)](_0x5046f8(0xa0),0x64);if(!Number[_0x5046f8(0x7b)](_0x20f69e)||_0x20f69e<0x1)throw CliErrors[_0x5046f8(0x87)](_0x5046f8(0x8e));if(!Number[_0x5046f8(0x7b)](_0xd04b97)||_0xd04b97<0x1||_0xd04b97>0x64)throw CliErrors[_0x5046f8(0x87)](_0x5046f8(0x91));},async 'execute'(_0x5758df){const _0x3aaa36=a58_0x8cc7c5,_0x486ff9=_0x5758df[_0x3aaa36(0x9f)](_0x3aaa36(0x85))['toUpperCase'](),_0xf8e3bf=_0x5758df['str'](_0x3aaa36(0x9e))['trim'](),_0x30c54d=_0x5758df['num']('page',0x1),_0x1af07f=_0x5758df[_0x3aaa36(0x8d)](_0x3aaa36(0xa0),0x64);if(_0x486ff9){const _0x266a99=(await listAllRuntimeRoles(_0x5758df[_0x3aaa36(0x7e)],{..._0xf8e3bf?{'roleName':_0xf8e3bf}:{}}))[_0x3aaa36(0x8f)](_0x5dccc1=>_0x5dccc1[_0x3aaa36(0x92)]===_0x486ff9),_0x176b74=(_0x30c54d-0x1)*_0x1af07f;return{'ok':!![],'data':{'scope':_0x3aaa36(0xa3),'roles':_0x266a99[_0x3aaa36(0x81)](_0x176b74,_0x176b74+_0x1af07f)[_0x3aaa36(0x7f)](projectRuntimeRole),'paging':{'currentPage':_0x30c54d,'pageSize':_0x1af07f,'totalCount':_0x266a99[_0x3aaa36(0x83)]}}};}const _0x1cfc6c=await listRuntimeAppRoles(_0x5758df[_0x3aaa36(0x7e)],{..._0xf8e3bf?{'roleName':_0xf8e3bf}:{},'currentPage':_0x30c54d,'pageSize':_0x1af07f});return{'ok':!![],'data':{'scope':_0x3aaa36(0xa3),'roles':_0x1cfc6c[_0x3aaa36(0x99)][_0x3aaa36(0x7f)](projectRuntimeRole),'paging':_0x1cfc6c[_0x3aaa36(0x86)]}};}};
1
+ function a58_0x3e89(_0x204338,_0x423a9f){_0x204338=_0x204338-0xfa;const _0x12d33f=a58_0x12d3();let _0x3e8928=_0x12d33f[_0x204338];return _0x3e8928;}const a58_0x17dfa6=a58_0x3e89;(function(_0xe972e2,_0x317f11){const _0x3a9288=a58_0x3e89,_0x4082f3=_0xe972e2();while(!![]){try{const _0x54daf0=-parseInt(_0x3a9288(0x10f))/0x1*(parseInt(_0x3a9288(0x102))/0x2)+-parseInt(_0x3a9288(0x11a))/0x3+parseInt(_0x3a9288(0x109))/0x4+parseInt(_0x3a9288(0x10a))/0x5+parseInt(_0x3a9288(0x104))/0x6+parseInt(_0x3a9288(0x114))/0x7+parseInt(_0x3a9288(0x116))/0x8*(-parseInt(_0x3a9288(0x107))/0x9);if(_0x54daf0===_0x317f11)break;else _0x4082f3['push'](_0x4082f3['shift']());}catch(_0x4afbdb){_0x4082f3['push'](_0x4082f3['shift']());}}}(a58_0x12d3,0x515df));import{listRuntimeAppRoles}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{listAllRuntimeRoles,projectRuntimeRole,RUNTIME_ROLE_TYPES}from'../../commands/role/shared.js';function a58_0x12d3(){const _0x134c9a=['type','271064OEWSfK','roleType','Invalid\x20runtime\x20role\x20type:\x20','runtime','17157JFxgEF','Page\x20size\x20from\x201\x20to\x20100','num','validation','number','items','read','Page\x20number','Fuzzy\x20role-name\x20filter','str','pagesize','slice','404vVXpPF','isSafeInteger','2980848ywwmeh','trim','map','225Wucvnz','--page\x20must\x20be\x20a\x20positive\x20integer.','1046200TEnyMl','1037900DSrWVu','appCode','filter','page','string','496uieNaG','includes','List\x20runtime\x20roles\x20for\x20the\x20current\x20app','name','toUpperCase','2242289JsETtx'];a58_0x12d3=function(){return _0x134c9a;};return a58_0x12d3();}export const roleList={'service':'role','command':'list','description':a58_0x17dfa6(0x111),'risk':a58_0x17dfa6(0xfc),'flags':[{'name':a58_0x17dfa6(0x115),'type':a58_0x17dfa6(0x10e),'enum':RUNTIME_ROLE_TYPES,'description':'Runtime\x20role\x20type'},{'name':a58_0x17dfa6(0x112),'type':a58_0x17dfa6(0x10e),'description':a58_0x17dfa6(0xfe)},{'name':a58_0x17dfa6(0x10d),'type':a58_0x17dfa6(0xfa),'default':0x1,'description':a58_0x17dfa6(0xfd)},{'name':a58_0x17dfa6(0x100),'type':a58_0x17dfa6(0xfa),'default':0x64,'description':a58_0x17dfa6(0x11b)}],async 'validate'(_0x12b0e9){const _0x116fae=a58_0x17dfa6,_0x6897d0=_0x12b0e9['str'](_0x116fae(0x115))['toUpperCase']();if(_0x6897d0&&!RUNTIME_ROLE_TYPES[_0x116fae(0x110)](_0x6897d0))throw CliErrors[_0x116fae(0x11d)](_0x116fae(0x118)+_0x6897d0+'.');const _0x571794=_0x12b0e9[_0x116fae(0x11c)]('page',0x1),_0x2edf85=_0x12b0e9[_0x116fae(0x11c)]('pagesize',0x64);if(!Number['isSafeInteger'](_0x571794)||_0x571794<0x1)throw CliErrors[_0x116fae(0x11d)](_0x116fae(0x108));if(!Number[_0x116fae(0x103)](_0x2edf85)||_0x2edf85<0x1||_0x2edf85>0x64)throw CliErrors[_0x116fae(0x11d)]('--pagesize\x20must\x20be\x20an\x20integer\x20from\x201\x20to\x20100.');},async 'execute'(_0x2c423c){const _0x1a2666=a58_0x17dfa6,_0x3a64ac=_0x2c423c[_0x1a2666(0xff)]('type')[_0x1a2666(0x113)](),_0x3a89dc=_0x2c423c[_0x1a2666(0xff)](_0x1a2666(0x112))[_0x1a2666(0x105)](),_0x55a100=_0x2c423c[_0x1a2666(0x11c)](_0x1a2666(0x10d),0x1),_0x1ecb34=_0x2c423c[_0x1a2666(0x11c)](_0x1a2666(0x100),0x64);if(_0x3a64ac){const _0x47f76e=(await listAllRuntimeRoles(_0x2c423c[_0x1a2666(0x10b)],{..._0x3a89dc?{'roleName':_0x3a89dc}:{}}))[_0x1a2666(0x10c)](_0x2c248e=>_0x2c248e[_0x1a2666(0x117)]===_0x3a64ac),_0x5eadec=(_0x55a100-0x1)*_0x1ecb34;return{'ok':!![],'data':{'scope':_0x1a2666(0x119),'roles':_0x47f76e[_0x1a2666(0x101)](_0x5eadec,_0x5eadec+_0x1ecb34)[_0x1a2666(0x106)](projectRuntimeRole),'paging':{'currentPage':_0x55a100,'pageSize':_0x1ecb34,'totalCount':_0x47f76e['length']}}};}const _0x170182=await listRuntimeAppRoles(_0x2c423c[_0x1a2666(0x10b)],{..._0x3a89dc?{'roleName':_0x3a89dc}:{},'currentPage':_0x55a100,'pageSize':_0x1ecb34});return{'ok':!![],'data':{'scope':_0x1a2666(0x119),'roles':_0x170182[_0x1a2666(0xfb)][_0x1a2666(0x106)](projectRuntimeRole),'paging':_0x170182['paging']}};}};
@@ -1 +1 @@
1
- const a59_0x53234a=a59_0x1ed1;(function(_0x58b0a,_0x270c02){const _0x2dc229=a59_0x1ed1,_0x51ec4b=_0x58b0a();while(!![]){try{const _0x1cc4a=-parseInt(_0x2dc229(0xe3))/0x1*(parseInt(_0x2dc229(0xee))/0x2)+parseInt(_0x2dc229(0xc7))/0x3*(-parseInt(_0x2dc229(0xb7))/0x4)+-parseInt(_0x2dc229(0xf3))/0x5*(parseInt(_0x2dc229(0xe7))/0x6)+-parseInt(_0x2dc229(0xbf))/0x7*(parseInt(_0x2dc229(0xd5))/0x8)+parseInt(_0x2dc229(0xb2))/0x9+-parseInt(_0x2dc229(0xd2))/0xa*(-parseInt(_0x2dc229(0xd3))/0xb)+parseInt(_0x2dc229(0xe6))/0xc;if(_0x1cc4a===_0x270c02)break;else _0x51ec4b['push'](_0x51ec4b['shift']());}catch(_0x5f2b11){_0x51ec4b['push'](_0x51ec4b['shift']());}}}(a59_0x5d6d,0x2e172));import{listRuntimeAppUsers,listRuntimeAppRoles,listRuntimeRoleUsers}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{normalizeRuntimeUserId}from'../../utils/runtime-user-id.js';export const RUNTIME_ROLE_TYPES=[a59_0x53234a(0xa6),a59_0x53234a(0xda),a59_0x53234a(0xd0),a59_0x53234a(0xbc)];const BUILTIN_ROLE_TYPES=[a59_0x53234a(0xa6),a59_0x53234a(0xda),a59_0x53234a(0xd0)];export const ROLE_ID_FLAG={'name':'id','type':a59_0x53234a(0xb6),'required':!![],'description':a59_0x53234a(0xed)};export const ROLE_REF_FLAG={'name':a59_0x53234a(0xd6),'type':a59_0x53234a(0xd9),'required':!![],'description':a59_0x53234a(0xbd)};export const ROLE_CODE_FLAG={'name':a59_0x53234a(0xba),'type':a59_0x53234a(0xd9),'description':a59_0x53234a(0xc5)};export const USER_ID_FLAG={'name':a59_0x53234a(0xc8),'type':'string','required':!![],'description':a59_0x53234a(0xb5)};export const EXPECT_USER_COUNT_FLAG={'name':a59_0x53234a(0xf1),'type':a59_0x53234a(0xb6),'description':a59_0x53234a(0xe0)};function a59_0x1ed1(_0x58431b,_0x42a206){_0x58431b=_0x58431b-0xa6;const _0x5d6d1c=a59_0x5d6d();let _0x1ed1b9=_0x5d6d1c[_0x58431b];return _0x1ed1b9;}export function isBuiltinRuntimeRole(_0x2e1f89){const _0x4298b0=a59_0x53234a;return BUILTIN_ROLE_TYPES[_0x4298b0(0xa9)](_0x2e1f89);}export function assertCustomRuntimeRole(_0x3e8a63,_0x5f0447){const _0x2529f2=a59_0x53234a;if(_0x3e8a63[_0x2529f2(0xf6)]!=='CUSTOM')throw CliErrors['validation'](_0x2529f2(0xc9)+_0x5f0447+_0x2529f2(0xce)+_0x3e8a63['roleName']+'\x20('+_0x3e8a63[_0x2529f2(0xf6)]+').',_0x2529f2(0xc2));}export function projectRuntimeRole(_0x38b3c0){const _0x2dabd9=a59_0x53234a;return{'id':_0x38b3c0['id'],'roleCode':_0x38b3c0[_0x2dabd9(0xc0)],'roleName':_0x38b3c0[_0x2dabd9(0xc6)],'roleType':_0x38b3c0[_0x2dabd9(0xf6)],'remark':_0x38b3c0[_0x2dabd9(0xe1)],'userCount':_0x38b3c0[_0x2dabd9(0xa8)]??0x0,'permitCount':_0x38b3c0[_0x2dabd9(0xf7)]??0x0,'builtin':isBuiltinRuntimeRole(_0x38b3c0[_0x2dabd9(0xf6)])};}export function readOptionalRuntimeRoleCode(_0x224380){const _0x353978=a59_0x53234a,_0x27b378=_0x224380['flag'](_0x353978(0xba));if(_0x27b378===undefined||_0x27b378===null)return undefined;const _0x998a67=String(_0x27b378)['trim']();if(!_0x998a67)throw CliErrors[_0x353978(0xb4)]('--role-code\x20must\x20not\x20be\x20blank.');if(_0x998a67[_0x353978(0xb9)]>0x40)throw CliErrors[_0x353978(0xb4)]('--role-code\x20cannot\x20exceed\x2064\x20characters.');return _0x998a67;}export async function getRuntimeRoleById(_0x47b769,_0x5dc486){const _0x27c847=a59_0x53234a;if(!Number[_0x27c847(0xf5)](_0x5dc486)||_0x5dc486<=0x0)throw CliErrors[_0x27c847(0xb4)]('Role\x20ID\x20must\x20be\x20a\x20positive\x20integer.');const _0x5afd7a=(await listAllRuntimeRoles(_0x47b769))[_0x27c847(0xb0)](_0x9a97ab=>_0x9a97ab['id']===_0x5dc486&&(!_0x9a97ab[_0x27c847(0xdd)]||_0x9a97ab[_0x27c847(0xdd)]===_0x47b769));if(_0x5afd7a[_0x27c847(0xb9)]!==0x1)throw CliErrors[_0x27c847(0xb4)](_0x27c847(0xa7)+_0x5dc486+_0x27c847(0xcc)+_0x47b769+'.',_0x27c847(0xae));const _0x4369a8=_0x5afd7a[0x0],_0x4f78ea=_0x4369a8['id'];if(typeof _0x4f78ea!==_0x27c847(0xb6)||!Number[_0x27c847(0xf5)](_0x4f78ea)||_0x4f78ea<=0x0)throw CliErrors[_0x27c847(0xb4)](_0x27c847(0xc3));return{..._0x4369a8,'id':_0x4f78ea};}function a59_0x5d6d(){const _0x400b5a=[',\x20found\x20','join','appCode','Runtime\x20role\x20member\x20count\x20changed:\x20expected\x20','Pass\x20--user\x20<userId>;\x20name\x20and\x20account\x20lookup\x20are\x20not\x20available\x20in\x20runtime\x20scope.','Reject\x20when\x20the\x20target\x20role\x20member\x20count\x20has\x20changed','remark','flag','11yiNUrN','trim','test','9040656dkoNUM','542076CJvdzg','Reload\x20the\x20role\x20list\x20and\x20retry\x20after\x20the\x20server\x20state\x20is\x20consistent.','\x20is\x20not\x20in\x20runtime\x20role\x20','Runtime\x20role\x20member\x20snapshot\x20has\x20an\x20invalid\x20role\x20ID;\x20reload\x20before\x20writing.','Transfer\x20or\x20manage\x20application\x20ownership\x20through\x20the\x20dedicated\x20application\x20workflow.','num','Runtime\x20role\x20ID\x20returned\x20by\x20role\x20list','55724GykEtB','userId','str','expect-user-count','paging','10DeSjpC','Runtime\x20role\x20name\x20\x22','isSafeInteger','roleType','permitCount','\x22\x20was\x20not\x20found\x20in\x20app\x20','ADMIN','Runtime\x20role\x20id\x20','userCount','includes','Run\x20`lovrabet\x20role\x20list`\x20or\x20pass\x20--role\x20<id>.','\x22\x20is\x20ambiguous.','map','User\x20','Run\x20`lovrabet\x20role\x20list`\x20and\x20use\x20a\x20role\x20from\x20the\x20current\x20app.','Invalid\x20runtime\x20userId.','filter','Read\x20the\x20current\x20members\x20and\x20retry\x20with\x20the\x20new\x20expected\x20count.','873468NmRGno','totalCount','validation','Runtime\x20userId\x20(string)','number','12NJRiAB','push','length','role-code','Runtime\x20role\x20','CUSTOM','Runtime\x20role\x20ID\x20or\x20exact\x20role\x20name','userName','749077hZAauy','roleCode','items','Only\x20CUSTOM\x20runtime\x20roles\x20can\x20be\x20modified\x20or\x20deleted.','Runtime\x20role\x20has\x20an\x20invalid\x20ID;\x20reload\x20roles\x20before\x20writing.','\x20is\x20already\x20in\x20runtime\x20role\x20','Globally\x20unique\x20roleCode\x20(maximum\x2064\x20characters)','roleName','158328fBBwPy','user','Cannot\x20','Runtime\x20role\x20member\x20has\x20an\x20invalid\x20userId.','OWNER\x20runtime\x20role\x20membership\x20cannot\x20be\x20changed\x20with\x20this\x20command.','\x20was\x20not\x20found\x20in\x20app\x20','userList','\x20built-in\x20runtime\x20role\x20','Use\x20a\x20userId\x20returned\x20by\x20the\x20current\x20application\x27s\x20personnel\x20list.','OWNER','--expect-user-count\x20must\x20be\x20a\x20non-negative\x20integer.','10JmHNtV','3353691OaqwlB','applyUserList','24PDOxWq','role','Runtime\x20user\x20','Pass\x20one\x20role\x20ID:\x20','string','USER'];a59_0x5d6d=function(){return _0x400b5a;};return a59_0x5d6d();}export async function listAllRuntimeRoles(_0x182393,_0x5da12e={}){const _0x5e8916=a59_0x53234a,_0x5d6fc5=0x64,_0x5d92d2=[];for(let _0x396571=0x1;;_0x396571+=0x1){const _0x1d9796=await listRuntimeAppRoles(_0x182393,{..._0x5da12e['roleName']?{'roleName':_0x5da12e[_0x5e8916(0xc6)]}:{},'currentPage':_0x396571,'pageSize':_0x5d6fc5});_0x5d92d2['push'](..._0x1d9796[_0x5e8916(0xc1)]);if(_0x1d9796[_0x5e8916(0xc1)][_0x5e8916(0xb9)]<_0x5d6fc5||_0x1d9796['paging']&&_0x5d92d2[_0x5e8916(0xb9)]>=_0x1d9796[_0x5e8916(0xf2)][_0x5e8916(0xb3)])return _0x5d92d2;}}export async function resolveRuntimeRoleRef(_0x26fc73,_0x485720){const _0x747ae7=a59_0x53234a,_0x37aabf=_0x485720[_0x747ae7(0xe4)]();if(!_0x37aabf)throw CliErrors[_0x747ae7(0xb4)]('Missing\x20runtime\x20role\x20reference.','Pass\x20--role\x20<id|name>.');if(/^\d+$/[_0x747ae7(0xe5)](_0x37aabf))return getRuntimeRoleById(_0x26fc73,Number(_0x37aabf));const _0x5bbfd6=(await listAllRuntimeRoles(_0x26fc73))[_0x747ae7(0xb0)](_0x3f5ff1=>_0x3f5ff1[_0x747ae7(0xc6)]===_0x37aabf);if(_0x5bbfd6[_0x747ae7(0xb9)]===0x0)throw CliErrors[_0x747ae7(0xb4)](_0x747ae7(0xf4)+_0x37aabf+_0x747ae7(0xf8)+_0x26fc73+'.',_0x747ae7(0xaa));if(_0x5bbfd6[_0x747ae7(0xb9)]>0x1)throw CliErrors[_0x747ae7(0xb4)](_0x747ae7(0xf4)+_0x37aabf+_0x747ae7(0xab),_0x747ae7(0xd8)+_0x5bbfd6[_0x747ae7(0xac)](_0x57fc47=>_0x57fc47['id'])[_0x747ae7(0xdc)](',\x20')+'.');const _0x187d95=_0x5bbfd6[0x0],_0x349dd1=_0x187d95['id'];if(typeof _0x349dd1!==_0x747ae7(0xb6)||!Number[_0x747ae7(0xf5)](_0x349dd1)||_0x349dd1<=0x0)throw CliErrors[_0x747ae7(0xb4)](_0x747ae7(0xc3));return{..._0x187d95,'id':_0x349dd1};}function parseRuntimeUserId(_0x84576a){const _0x54f742=a59_0x53234a,_0x50f197=_0x84576a[_0x54f742(0xe4)](),_0x43d712=normalizeRuntimeUserId(_0x50f197);if(_0x43d712===undefined)throw CliErrors[_0x54f742(0xb4)](_0x54f742(0xaf),_0x54f742(0xdf));return _0x43d712;}export async function prepareRuntimeMemberMutation(_0x454248,_0x4a9cee){const _0x112c21=a59_0x53234a,_0x59f479=await resolveRuntimeRoleRef(_0x454248['appCode'],_0x454248[_0x112c21(0xf0)]('role'));if(_0x59f479[_0x112c21(0xf6)]===_0x112c21(0xd0))throw CliErrors['validation'](_0x112c21(0xcb),_0x112c21(0xeb));const _0x807f4c=parseRuntimeUserId(_0x454248[_0x112c21(0xf0)]('user')),_0x2ba681=(await listRuntimeRoleUsers(_0x454248[_0x112c21(0xdd)]))[_0x112c21(0xac)](_0x5cee21=>{const _0x1c102e=_0x112c21;if(typeof _0x5cee21['id']!==_0x1c102e(0xb6)||!Number[_0x1c102e(0xf5)](_0x5cee21['id'])||_0x5cee21['id']<=0x0)throw CliErrors['validation'](_0x1c102e(0xea));return{..._0x5cee21,'userList':[..._0x5cee21[_0x1c102e(0xcd)]??[]],'applyUserList':[..._0x5cee21[_0x1c102e(0xd4)]??[]]};}),_0x5d3b71=_0x2ba681['find'](_0x4e0585=>_0x4e0585['id']===_0x59f479['id']);if(!_0x5d3b71)throw CliErrors[_0x112c21(0xb4)](_0x112c21(0xbb)+_0x59f479['id']+'\x20is\x20missing\x20from\x20the\x20grouped\x20member\x20snapshot.',_0x112c21(0xe8));const _0x5da7ee=_0x930c43=>{const _0x241fb9=_0x112c21,_0x210ab2=normalizeRuntimeUserId(_0x930c43);if(_0x210ab2===undefined)throw CliErrors[_0x241fb9(0xb4)](_0x241fb9(0xca));return _0x210ab2;},_0x9a9b5f=_0x5d3b71[_0x112c21(0xcd)][_0x112c21(0xac)](_0x55be73=>_0x5da7ee(_0x55be73[_0x112c21(0xef)])),_0x26b353=_0x454248[_0x112c21(0xe2)]('expect-user-count');if(_0x26b353!==undefined&&_0x26b353!==null&&_0x26b353!==''){const _0x550b71=_0x454248[_0x112c21(0xec)](_0x112c21(0xf1));if(!Number[_0x112c21(0xf5)](_0x550b71)||_0x550b71<0x0)throw CliErrors[_0x112c21(0xb4)](_0x112c21(0xd1));if(_0x9a9b5f[_0x112c21(0xb9)]!==_0x550b71)throw CliErrors[_0x112c21(0xb4)](_0x112c21(0xde)+_0x550b71+_0x112c21(0xdb)+_0x9a9b5f['length']+'.',_0x112c21(0xb1));}const _0x21712a=_0x9a9b5f[_0x112c21(0xa9)](_0x807f4c),_0x1d8c2d=[];let _0x7a6caf=!![];if(_0x4a9cee==='user-add'){const _0x1ae9d2=await listRuntimeAppUsers(_0x454248[_0x112c21(0xdd)]),_0x2e969f=_0x1ae9d2[_0x112c21(0xb0)](_0xdec785=>normalizeRuntimeUserId(_0xdec785['code'])===_0x807f4c);if(_0x2e969f['length']!==0x1||!_0x2e969f[0x0]['userName']?.['trim']())throw CliErrors[_0x112c21(0xb4)](_0x112c21(0xd7)+_0x807f4c+_0x112c21(0xcc)+_0x454248[_0x112c21(0xdd)]+'.',_0x112c21(0xcf));_0x21712a?(_0x7a6caf=![],_0x1d8c2d[_0x112c21(0xb8)]('User\x20'+_0x807f4c+_0x112c21(0xc4)+_0x59f479['id']+'.')):_0x5d3b71[_0x112c21(0xcd)]['push']({'userId':_0x807f4c,'username':_0x2e969f[0x0][_0x112c21(0xbe)]});}else!_0x21712a?(_0x7a6caf=![],_0x1d8c2d[_0x112c21(0xb8)](_0x112c21(0xad)+_0x807f4c+_0x112c21(0xe9)+_0x59f479['id']+'.')):_0x5d3b71[_0x112c21(0xcd)]=_0x5d3b71[_0x112c21(0xcd)][_0x112c21(0xb0)](_0x1f0c2d=>_0x5da7ee(_0x1f0c2d[_0x112c21(0xef)])!==_0x807f4c);return{'role':_0x59f479,'userId':_0x807f4c,'roleList':_0x2ba681,'before':{'userIds':_0x9a9b5f},'after':{'userIds':_0x5d3b71[_0x112c21(0xcd)]['map'](_0x4fcb9e=>_0x5da7ee(_0x4fcb9e[_0x112c21(0xef)]))},'shouldWrite':_0x7a6caf,'warnings':_0x1d8c2d};}export function runtimeRoleWriteResult(_0x577173,_0x1e0f4f,_0x3a9308,_0x2c4b8c,_0x109696,_0xed6104=[]){return{'operation':_0x577173,'scope':'runtime','selector':_0x1e0f4f,'before':_0x3a9308,'after':_0x2c4b8c,'dryRun':![],'backend':_0x109696,'warnings':_0xed6104};}
1
+ function a59_0x1ef5(){const _0x16a228=['Pass\x20one\x20role\x20ID:\x20','80FxJnLe','3405zGJizb','Role\x20ID\x20must\x20be\x20a\x20positive\x20integer.','appCode','Runtime\x20role\x20member\x20snapshot\x20has\x20an\x20invalid\x20role\x20ID;\x20reload\x20before\x20writing.','--expect-user-count\x20must\x20be\x20a\x20non-negative\x20integer.','\x20is\x20already\x20in\x20runtime\x20role\x20','User\x20','includes','remark','\x20built-in\x20runtime\x20role\x20','17343981iDMPUO','Reload\x20the\x20role\x20list\x20and\x20retry\x20after\x20the\x20server\x20state\x20is\x20consistent.','roleCode','Use\x20a\x20userId\x20returned\x20by\x20the\x20current\x20application\x27s\x20personnel\x20list.','1486814gaDTMz','num','Runtime\x20role\x20member\x20count\x20changed:\x20expected\x20','80984zmUWPp','\x22\x20is\x20ambiguous.','roleName','Pass\x20--user\x20<userId>;\x20name\x20and\x20account\x20lookup\x20are\x20not\x20available\x20in\x20runtime\x20scope.','flag','6525438MbhiCo','Runtime\x20role\x20ID\x20returned\x20by\x20role\x20list','userId','number','Runtime\x20role\x20has\x20an\x20invalid\x20ID;\x20reload\x20roles\x20before\x20writing.','\x20is\x20missing\x20from\x20the\x20grouped\x20member\x20snapshot.','role-code','USER','str','expect-user-count','OWNER\x20runtime\x20role\x20membership\x20cannot\x20be\x20changed\x20with\x20this\x20command.','Pass\x20--role\x20<id|name>.','12768584HRzcDy','--role-code\x20must\x20not\x20be\x20blank.','applyUserList','push','Runtime\x20userId\x20(string)','isSafeInteger','Read\x20the\x20current\x20members\x20and\x20retry\x20with\x20the\x20new\x20expected\x20count.','permitCount','paging','--role-code\x20cannot\x20exceed\x2064\x20characters.','role','Only\x20CUSTOM\x20runtime\x20roles\x20can\x20be\x20modified\x20or\x20deleted.','userList','map','Runtime\x20role\x20name\x20\x22','Runtime\x20user\x20','totalCount','validation','Globally\x20unique\x20roleCode\x20(maximum\x2064\x20characters)','Cannot\x20','Runtime\x20role\x20','34PpEyQX','test','code','OWNER','filter','userName','9023400HCTTXK','length','user','string','userCount','user-add','trim','find','Run\x20`lovrabet\x20role\x20list`\x20and\x20use\x20a\x20role\x20from\x20the\x20current\x20app.','roleType','join','ADMIN','runtime','CUSTOM'];a59_0x1ef5=function(){return _0x16a228;};return a59_0x1ef5();}const a59_0x5ab7bd=a59_0x3f1a;(function(_0x18fe0c,_0x440073){const _0x56b508=a59_0x3f1a,_0x18cc4e=_0x18fe0c();while(!![]){try{const _0x12414d=parseInt(_0x56b508(0xb7))/0x1*(parseInt(_0x56b508(0xdd))/0x2)+parseInt(_0x56b508(0xa6))/0x3*(parseInt(_0x56b508(0xa5))/0x4)+parseInt(_0x56b508(0x96))/0x5+parseInt(_0x56b508(0xbc))/0x6+parseInt(_0x56b508(0xb4))/0x7+-parseInt(_0x56b508(0xc8))/0x8+-parseInt(_0x56b508(0xb0))/0x9;if(_0x12414d===_0x440073)break;else _0x18cc4e['push'](_0x18cc4e['shift']());}catch(_0x4b181a){_0x18cc4e['push'](_0x18cc4e['shift']());}}}(a59_0x1ef5,0xef7a5));import{listRuntimeAppUsers,listRuntimeAppRoles,listRuntimeRoleUsers}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{normalizeRuntimeUserId}from'../../utils/runtime-user-id.js';export const RUNTIME_ROLE_TYPES=['ADMIN',a59_0x5ab7bd(0xc3),'OWNER',a59_0x5ab7bd(0xa3)];function a59_0x3f1a(_0x5d68da,_0x414e88){_0x5d68da=_0x5d68da-0x92;const _0x1ef5bc=a59_0x1ef5();let _0x3f1a63=_0x1ef5bc[_0x5d68da];return _0x3f1a63;}const BUILTIN_ROLE_TYPES=[a59_0x5ab7bd(0xa1),'USER',a59_0x5ab7bd(0x93)];export const ROLE_ID_FLAG={'name':'id','type':a59_0x5ab7bd(0xbf),'required':!![],'description':a59_0x5ab7bd(0xbd)};export const ROLE_REF_FLAG={'name':a59_0x5ab7bd(0xd2),'type':a59_0x5ab7bd(0x99),'required':!![],'description':'Runtime\x20role\x20ID\x20or\x20exact\x20role\x20name'};export const ROLE_CODE_FLAG={'name':a59_0x5ab7bd(0xc2),'type':'string','description':a59_0x5ab7bd(0xda)};export const USER_ID_FLAG={'name':a59_0x5ab7bd(0x98),'type':a59_0x5ab7bd(0x99),'required':!![],'description':a59_0x5ab7bd(0xcc)};export const EXPECT_USER_COUNT_FLAG={'name':a59_0x5ab7bd(0xc5),'type':a59_0x5ab7bd(0xbf),'description':'Reject\x20when\x20the\x20target\x20role\x20member\x20count\x20has\x20changed'};export function isBuiltinRuntimeRole(_0x2fa1fb){const _0x4a4833=a59_0x5ab7bd;return BUILTIN_ROLE_TYPES[_0x4a4833(0xad)](_0x2fa1fb);}export function assertCustomRuntimeRole(_0x55652b,_0x5c6824){const _0x5f3d6c=a59_0x5ab7bd;if(_0x55652b['roleType']!=='CUSTOM')throw CliErrors['validation'](_0x5f3d6c(0xdb)+_0x5c6824+_0x5f3d6c(0xaf)+_0x55652b[_0x5f3d6c(0xb9)]+'\x20('+_0x55652b[_0x5f3d6c(0x9f)]+').',_0x5f3d6c(0xd3));}export function projectRuntimeRole(_0x15d342){const _0x49e817=a59_0x5ab7bd;return{'id':_0x15d342['id'],'roleCode':_0x15d342[_0x49e817(0xb2)],'roleName':_0x15d342['roleName'],'roleType':_0x15d342[_0x49e817(0x9f)],'remark':_0x15d342[_0x49e817(0xae)],'userCount':_0x15d342[_0x49e817(0x9a)]??0x0,'permitCount':_0x15d342[_0x49e817(0xcf)]??0x0,'builtin':isBuiltinRuntimeRole(_0x15d342['roleType'])};}export function readOptionalRuntimeRoleCode(_0x4c2d14){const _0x7fa387=a59_0x5ab7bd,_0x584a1e=_0x4c2d14[_0x7fa387(0xbb)](_0x7fa387(0xc2));if(_0x584a1e===undefined||_0x584a1e===null)return undefined;const _0x41e0e1=String(_0x584a1e)[_0x7fa387(0x9c)]();if(!_0x41e0e1)throw CliErrors['validation'](_0x7fa387(0xc9));if(_0x41e0e1[_0x7fa387(0x97)]>0x40)throw CliErrors[_0x7fa387(0xd9)](_0x7fa387(0xd1));return _0x41e0e1;}export async function getRuntimeRoleById(_0x17b138,_0x2e7e58){const _0x30e792=a59_0x5ab7bd;if(!Number['isSafeInteger'](_0x2e7e58)||_0x2e7e58<=0x0)throw CliErrors[_0x30e792(0xd9)](_0x30e792(0xa7));const _0x32f2a3=(await listAllRuntimeRoles(_0x17b138))[_0x30e792(0x94)](_0x21661b=>_0x21661b['id']===_0x2e7e58&&(!_0x21661b['appCode']||_0x21661b['appCode']===_0x17b138));if(_0x32f2a3[_0x30e792(0x97)]!==0x1)throw CliErrors[_0x30e792(0xd9)]('Runtime\x20role\x20id\x20'+_0x2e7e58+'\x20was\x20not\x20found\x20in\x20app\x20'+_0x17b138+'.',_0x30e792(0x9e));const _0x3e2bc9=_0x32f2a3[0x0],_0x5ecc48=_0x3e2bc9['id'];if(typeof _0x5ecc48!==_0x30e792(0xbf)||!Number[_0x30e792(0xcd)](_0x5ecc48)||_0x5ecc48<=0x0)throw CliErrors['validation']('Runtime\x20role\x20has\x20an\x20invalid\x20ID;\x20reload\x20roles\x20before\x20writing.');return{..._0x3e2bc9,'id':_0x5ecc48};}export async function listAllRuntimeRoles(_0x1d7811,_0xde228c={}){const _0x153a77=a59_0x5ab7bd,_0x12deac=0x64,_0x217526=[];for(let _0x542bbf=0x1;;_0x542bbf+=0x1){const _0x2d1937=await listRuntimeAppRoles(_0x1d7811,{..._0xde228c[_0x153a77(0xb9)]?{'roleName':_0xde228c[_0x153a77(0xb9)]}:{},'currentPage':_0x542bbf,'pageSize':_0x12deac});_0x217526[_0x153a77(0xcb)](..._0x2d1937['items']);if(_0x2d1937['items'][_0x153a77(0x97)]<_0x12deac||_0x2d1937[_0x153a77(0xd0)]&&_0x217526[_0x153a77(0x97)]>=_0x2d1937['paging'][_0x153a77(0xd8)])return _0x217526;}}export async function resolveRuntimeRoleRef(_0x52f65a,_0x652da4){const _0xa7405b=a59_0x5ab7bd,_0x282a01=_0x652da4[_0xa7405b(0x9c)]();if(!_0x282a01)throw CliErrors[_0xa7405b(0xd9)]('Missing\x20runtime\x20role\x20reference.',_0xa7405b(0xc7));if(/^\d+$/[_0xa7405b(0xde)](_0x282a01))return getRuntimeRoleById(_0x52f65a,Number(_0x282a01));const _0x374a77=(await listAllRuntimeRoles(_0x52f65a))[_0xa7405b(0x94)](_0x2c1548=>_0x2c1548['roleName']===_0x282a01);if(_0x374a77[_0xa7405b(0x97)]===0x0)throw CliErrors[_0xa7405b(0xd9)]('Runtime\x20role\x20name\x20\x22'+_0x282a01+'\x22\x20was\x20not\x20found\x20in\x20app\x20'+_0x52f65a+'.','Run\x20`lovrabet\x20role\x20list`\x20or\x20pass\x20--role\x20<id>.');if(_0x374a77[_0xa7405b(0x97)]>0x1)throw CliErrors[_0xa7405b(0xd9)](_0xa7405b(0xd6)+_0x282a01+_0xa7405b(0xb8),_0xa7405b(0xa4)+_0x374a77[_0xa7405b(0xd5)](_0x28daae=>_0x28daae['id'])[_0xa7405b(0xa0)](',\x20')+'.');const _0x2e9b57=_0x374a77[0x0],_0x6184d6=_0x2e9b57['id'];if(typeof _0x6184d6!==_0xa7405b(0xbf)||!Number[_0xa7405b(0xcd)](_0x6184d6)||_0x6184d6<=0x0)throw CliErrors[_0xa7405b(0xd9)](_0xa7405b(0xc0));return{..._0x2e9b57,'id':_0x6184d6};}function parseRuntimeUserId(_0x449460){const _0x569947=a59_0x5ab7bd,_0x45b289=_0x449460[_0x569947(0x9c)](),_0x1925c7=normalizeRuntimeUserId(_0x45b289);if(_0x1925c7===undefined)throw CliErrors[_0x569947(0xd9)]('Invalid\x20runtime\x20userId.',_0x569947(0xba));return _0x1925c7;}export async function prepareRuntimeMemberMutation(_0x5f1840,_0x2e1fe6){const _0x1afc7e=a59_0x5ab7bd,_0x46b97d=await resolveRuntimeRoleRef(_0x5f1840[_0x1afc7e(0xa8)],_0x5f1840[_0x1afc7e(0xc4)]('role'));if(_0x46b97d[_0x1afc7e(0x9f)]===_0x1afc7e(0x93))throw CliErrors[_0x1afc7e(0xd9)](_0x1afc7e(0xc6),'Transfer\x20or\x20manage\x20application\x20ownership\x20through\x20the\x20dedicated\x20application\x20workflow.');const _0xd3447e=parseRuntimeUserId(_0x5f1840[_0x1afc7e(0xc4)](_0x1afc7e(0x98))),_0x46970c=(await listRuntimeRoleUsers(_0x5f1840[_0x1afc7e(0xa8)]))[_0x1afc7e(0xd5)](_0xa8f423=>{const _0x5f1cf3=_0x1afc7e;if(typeof _0xa8f423['id']!==_0x5f1cf3(0xbf)||!Number[_0x5f1cf3(0xcd)](_0xa8f423['id'])||_0xa8f423['id']<=0x0)throw CliErrors[_0x5f1cf3(0xd9)](_0x5f1cf3(0xa9));return{..._0xa8f423,'userList':[..._0xa8f423[_0x5f1cf3(0xd4)]??[]],'applyUserList':[..._0xa8f423[_0x5f1cf3(0xca)]??[]]};}),_0x3b6c9c=_0x46970c[_0x1afc7e(0x9d)](_0x10e091=>_0x10e091['id']===_0x46b97d['id']);if(!_0x3b6c9c)throw CliErrors[_0x1afc7e(0xd9)](_0x1afc7e(0xdc)+_0x46b97d['id']+_0x1afc7e(0xc1),_0x1afc7e(0xb1));const _0x2d1bd6=_0x468e76=>{const _0x2a37b0=_0x1afc7e,_0x24829d=normalizeRuntimeUserId(_0x468e76);if(_0x24829d===undefined)throw CliErrors[_0x2a37b0(0xd9)]('Runtime\x20role\x20member\x20has\x20an\x20invalid\x20userId.');return _0x24829d;},_0x20f078=_0x3b6c9c['userList'][_0x1afc7e(0xd5)](_0x1c515c=>_0x2d1bd6(_0x1c515c[_0x1afc7e(0xbe)])),_0x4aa86e=_0x5f1840['flag'](_0x1afc7e(0xc5));if(_0x4aa86e!==undefined&&_0x4aa86e!==null&&_0x4aa86e!==''){const _0x41b5ea=_0x5f1840[_0x1afc7e(0xb5)]('expect-user-count');if(!Number[_0x1afc7e(0xcd)](_0x41b5ea)||_0x41b5ea<0x0)throw CliErrors['validation'](_0x1afc7e(0xaa));if(_0x20f078['length']!==_0x41b5ea)throw CliErrors[_0x1afc7e(0xd9)](_0x1afc7e(0xb6)+_0x41b5ea+',\x20found\x20'+_0x20f078[_0x1afc7e(0x97)]+'.',_0x1afc7e(0xce));}const _0x22af0a=_0x20f078['includes'](_0xd3447e),_0x58a3ad=[];let _0x15168f=!![];if(_0x2e1fe6===_0x1afc7e(0x9b)){const _0x5df149=await listRuntimeAppUsers(_0x5f1840[_0x1afc7e(0xa8)]),_0x23a991=_0x5df149['filter'](_0x21d3df=>normalizeRuntimeUserId(_0x21d3df[_0x1afc7e(0x92)])===_0xd3447e);if(_0x23a991[_0x1afc7e(0x97)]!==0x1||!_0x23a991[0x0][_0x1afc7e(0x95)]?.['trim']())throw CliErrors[_0x1afc7e(0xd9)](_0x1afc7e(0xd7)+_0xd3447e+'\x20was\x20not\x20found\x20in\x20app\x20'+_0x5f1840[_0x1afc7e(0xa8)]+'.',_0x1afc7e(0xb3));_0x22af0a?(_0x15168f=![],_0x58a3ad[_0x1afc7e(0xcb)](_0x1afc7e(0xac)+_0xd3447e+_0x1afc7e(0xab)+_0x46b97d['id']+'.')):_0x3b6c9c[_0x1afc7e(0xd4)][_0x1afc7e(0xcb)]({'userId':_0xd3447e,'username':_0x23a991[0x0][_0x1afc7e(0x95)]});}else!_0x22af0a?(_0x15168f=![],_0x58a3ad[_0x1afc7e(0xcb)](_0x1afc7e(0xac)+_0xd3447e+'\x20is\x20not\x20in\x20runtime\x20role\x20'+_0x46b97d['id']+'.')):_0x3b6c9c[_0x1afc7e(0xd4)]=_0x3b6c9c[_0x1afc7e(0xd4)][_0x1afc7e(0x94)](_0x4fb0b5=>_0x2d1bd6(_0x4fb0b5[_0x1afc7e(0xbe)])!==_0xd3447e);return{'role':_0x46b97d,'userId':_0xd3447e,'roleList':_0x46970c,'before':{'userIds':_0x20f078},'after':{'userIds':_0x3b6c9c[_0x1afc7e(0xd4)][_0x1afc7e(0xd5)](_0x1836f4=>_0x2d1bd6(_0x1836f4[_0x1afc7e(0xbe)]))},'shouldWrite':_0x15168f,'warnings':_0x58a3ad};}export function runtimeRoleWriteResult(_0x4aad98,_0x15bb47,_0x226d04,_0x2cb0a2,_0x3a017e,_0x4d1a8e=[]){const _0x5814e9=a59_0x5ab7bd;return{'operation':_0x4aad98,'scope':_0x5814e9(0xa2),'selector':_0x15bb47,'before':_0x226d04,'after':_0x2cb0a2,'dryRun':![],'backend':_0x3a017e,'warnings':_0x4d1a8e};}
@@ -1 +1 @@
1
- const a60_0x3330cd=a60_0x1c59;(function(_0x372c37,_0x19668e){const _0x826c4c=a60_0x1c59,_0x3b50ca=_0x372c37();while(!![]){try{const _0x37b526=-parseInt(_0x826c4c(0x1d7))/0x1+parseInt(_0x826c4c(0x1bc))/0x2*(parseInt(_0x826c4c(0x1cd))/0x3)+parseInt(_0x826c4c(0x1d4))/0x4*(-parseInt(_0x826c4c(0x1c9))/0x5)+-parseInt(_0x826c4c(0x1c0))/0x6+-parseInt(_0x826c4c(0x1be))/0x7+-parseInt(_0x826c4c(0x1c3))/0x8*(-parseInt(_0x826c4c(0x1b8))/0x9)+parseInt(_0x826c4c(0x1c6))/0xa;if(_0x37b526===_0x19668e)break;else _0x3b50ca['push'](_0x3b50ca['shift']());}catch(_0x18bb90){_0x3b50ca['push'](_0x3b50ca['shift']());}}}(a60_0x3989,0x2c21e));import{updateRuntimeAppRole}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';function a60_0x1c59(_0x4b947c,_0x2399b1){_0x4b947c=_0x4b947c-0x1b8;const _0x398926=a60_0x3989();let _0x1c596f=_0x398926[_0x4b947c];return _0x1c596f;}import{assertCustomRuntimeRole,getRuntimeRoleById,projectRuntimeRole,readOptionalRuntimeRoleCode,ROLE_CODE_FLAG,ROLE_ID_FLAG,runtimeRoleWriteResult}from'../../commands/role/shared.js';function a60_0x3989(){const _0x1ed608=['1908840OpKAex','trim','role-code','78488mhdhJs','name','/client/permit/role/update','3039990cXLKlU','update','str','2450yZmywf','flag','Preview:\x20update\x20a\x20runtime\x20CUSTOM\x20role','New\x20role\x20name','39xzaAvT','remark','build','POST','body','--remark\x20must\x20not\x20be\x20blank.','validation','244xVRQJC','high-risk-write','role','70588PFsOBY','Pass\x20--role-code,\x20--name,\x20or\x20--remark\x20to\x20update\x20the\x20runtime\x20role.','string','117IuvIyg','Changes\x20the\x20custom\x20role\x20code,\x20name,\x20or\x20note\x20in\x20the\x20current\x20runtime\x20app.\x20The\x20role\x20updates\x20immediately.','Update\x20a\x20runtime\x20CUSTOM\x20role\x27s\x20code,\x20name,\x20or\x20remark','num','53324CMTPLh','The\x20current\x20runtime\x20role\x20API\x20does\x20not\x20support\x20clearing\x20an\x20existing\x20remark.','1251348PTdxbF','appCode'];a60_0x3989=function(){return _0x1ed608;};return a60_0x3989();}function updateFields(_0x290c17){const _0x14adc8=a60_0x1c59,_0x393cc0=_0x290c17[_0x14adc8(0x1ca)](_0x14adc8(0x1c2))!==undefined,_0x228bea=_0x290c17[_0x14adc8(0x1ca)](_0x14adc8(0x1c4))!==undefined,_0x35c8e4=_0x290c17[_0x14adc8(0x1ca)]('remark')!==undefined;if(!_0x393cc0&&!_0x228bea&&!_0x35c8e4)throw CliErrors[_0x14adc8(0x1d3)](_0x14adc8(0x1d8));const _0x1d8da0=readOptionalRuntimeRoleCode(_0x290c17),_0x47cd6b=_0x290c17[_0x14adc8(0x1c8)](_0x14adc8(0x1c4))[_0x14adc8(0x1c1)](),_0x4f0ade=_0x290c17[_0x14adc8(0x1c8)](_0x14adc8(0x1ce))[_0x14adc8(0x1c1)]();if(_0x228bea&&!_0x47cd6b)throw CliErrors['validation']('--name\x20must\x20not\x20be\x20blank.');if(_0x35c8e4&&!_0x4f0ade)throw CliErrors[_0x14adc8(0x1d3)](_0x14adc8(0x1d2),_0x14adc8(0x1bd));return{..._0x1d8da0?{'roleCode':_0x1d8da0}:{},..._0x228bea?{'roleName':_0x47cd6b}:{},..._0x35c8e4?{'remark':_0x4f0ade}:{}};}async function prepare(_0x5e8968){const _0x5c0459=a60_0x1c59,_0x758826=await getRuntimeRoleById(_0x5e8968[_0x5c0459(0x1bf)],_0x5e8968[_0x5c0459(0x1bb)]('id'));return assertCustomRuntimeRole(_0x758826,_0x5c0459(0x1c7)),{'role':_0x758826,'body':{'id':_0x758826['id'],'appCode':_0x5e8968[_0x5c0459(0x1bf)],...updateFields(_0x5e8968)}};}export const roleUpdate={'service':a60_0x3330cd(0x1d6),'command':a60_0x3330cd(0x1c7),'description':a60_0x3330cd(0x1ba),'risk':a60_0x3330cd(0x1d5),'confirmationDescription':a60_0x3330cd(0x1b9),'flags':[ROLE_ID_FLAG,ROLE_CODE_FLAG,{'name':a60_0x3330cd(0x1c4),'type':a60_0x3330cd(0x1d9),'description':a60_0x3330cd(0x1cc)},{'name':'remark','type':'string','description':'New\x20non-empty\x20role\x20remark'}],async 'validate'(_0x2d39c3){updateFields(_0x2d39c3);},async 'dryRun'(_0x5e0ce7){const _0xb38db3=a60_0x3330cd,{body:_0x8c2205}=await prepare(_0x5e0ce7);return dryRun(_0xb38db3(0x1d0),_0xb38db3(0x1c5))[_0xb38db3(0x1d1)](_0x8c2205)['description'](_0xb38db3(0x1cb))[_0xb38db3(0x1cf)]();},async 'execute'(_0x4c3f62){const _0x31a256=a60_0x3330cd,{role:_0x299d06,body:_0x109f8d}=await prepare(_0x4c3f62),_0x401409=await updateRuntimeAppRole(_0x109f8d);return{'ok':!![],'data':runtimeRoleWriteResult(_0x31a256(0x1c7),{'roleId':_0x299d06['id']},projectRuntimeRole(_0x299d06),projectRuntimeRole(_0x401409),{'method':_0x31a256(0x1d0),'path':_0x31a256(0x1c5)})};}};
1
+ const a60_0x5b74c6=a60_0x7747;function a60_0x7747(_0x4b690f,_0x562c4c){_0x4b690f=_0x4b690f-0xfb;const _0x43bf6b=a60_0x43bf();let _0x7747d5=_0x43bf6b[_0x4b690f];return _0x7747d5;}(function(_0x46ec51,_0x4d4639){const _0x5a5291=a60_0x7747,_0x209956=_0x46ec51();while(!![]){try{const _0x293d17=parseInt(_0x5a5291(0x107))/0x1*(-parseInt(_0x5a5291(0x10a))/0x2)+-parseInt(_0x5a5291(0x111))/0x3+-parseInt(_0x5a5291(0xfc))/0x4*(parseInt(_0x5a5291(0xfd))/0x5)+parseInt(_0x5a5291(0xfb))/0x6+-parseInt(_0x5a5291(0x109))/0x7+parseInt(_0x5a5291(0xfe))/0x8+parseInt(_0x5a5291(0x10c))/0x9;if(_0x293d17===_0x4d4639)break;else _0x209956['push'](_0x209956['shift']());}catch(_0x466fb0){_0x209956['push'](_0x209956['shift']());}}}(a60_0x43bf,0x19790));import{updateRuntimeAppRole}from'../../core/api-client.js';function a60_0x43bf(){const _0x444dab=['validation','role-code','remark','trim','high-risk-write','string','--remark\x20must\x20not\x20be\x20blank.','update','1108392oDHWAT','59356UJphDV','65ftWqlE','1431328uOQipp','The\x20current\x20runtime\x20role\x20API\x20does\x20not\x20support\x20clearing\x20an\x20existing\x20remark.','New\x20role\x20name','flag','role','name','Changes\x20the\x20custom\x20role\x20code,\x20name,\x20or\x20note\x20in\x20the\x20current\x20runtime\x20app.\x20The\x20role\x20updates\x20immediately.','Update\x20a\x20runtime\x20CUSTOM\x20role\x27s\x20code,\x20name,\x20or\x20remark','POST','13691TZTKFz','/client/permit/role/update','489685Ktzoij','28RejLqT','Preview:\x20update\x20a\x20runtime\x20CUSTOM\x20role','2265075GTuJIr','appCode','body','num','str','169353fyMrMW'];a60_0x43bf=function(){return _0x444dab;};return a60_0x43bf();}import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';import{assertCustomRuntimeRole,getRuntimeRoleById,projectRuntimeRole,readOptionalRuntimeRoleCode,ROLE_CODE_FLAG,ROLE_ID_FLAG,runtimeRoleWriteResult}from'../../commands/role/shared.js';function updateFields(_0x48ec8d){const _0x82b40=a60_0x7747,_0x371d16=_0x48ec8d[_0x82b40(0x101)](_0x82b40(0x113))!==undefined,_0x4eec20=_0x48ec8d[_0x82b40(0x101)](_0x82b40(0x103))!==undefined,_0x54f366=_0x48ec8d[_0x82b40(0x101)](_0x82b40(0x114))!==undefined;if(!_0x371d16&&!_0x4eec20&&!_0x54f366)throw CliErrors['validation']('Pass\x20--role-code,\x20--name,\x20or\x20--remark\x20to\x20update\x20the\x20runtime\x20role.');const _0x35347e=readOptionalRuntimeRoleCode(_0x48ec8d),_0x23d17c=_0x48ec8d[_0x82b40(0x110)]('name')[_0x82b40(0x115)](),_0x804190=_0x48ec8d[_0x82b40(0x110)](_0x82b40(0x114))[_0x82b40(0x115)]();if(_0x4eec20&&!_0x23d17c)throw CliErrors[_0x82b40(0x112)]('--name\x20must\x20not\x20be\x20blank.');if(_0x54f366&&!_0x804190)throw CliErrors[_0x82b40(0x112)](_0x82b40(0x118),_0x82b40(0xff));return{..._0x35347e?{'roleCode':_0x35347e}:{},..._0x4eec20?{'roleName':_0x23d17c}:{},..._0x54f366?{'remark':_0x804190}:{}};}async function prepare(_0x3d2418){const _0x10685c=a60_0x7747,_0x395144=await getRuntimeRoleById(_0x3d2418[_0x10685c(0x10d)],_0x3d2418[_0x10685c(0x10f)]('id'));return assertCustomRuntimeRole(_0x395144,'update'),{'role':_0x395144,'body':{'id':_0x395144['id'],'appCode':_0x3d2418[_0x10685c(0x10d)],...updateFields(_0x3d2418)}};}export const roleUpdate={'service':a60_0x5b74c6(0x102),'command':a60_0x5b74c6(0x119),'description':a60_0x5b74c6(0x105),'risk':a60_0x5b74c6(0x116),'confirmationDescription':a60_0x5b74c6(0x104),'flags':[ROLE_ID_FLAG,ROLE_CODE_FLAG,{'name':'name','type':a60_0x5b74c6(0x117),'description':a60_0x5b74c6(0x100)},{'name':'remark','type':a60_0x5b74c6(0x117),'description':'New\x20non-empty\x20role\x20remark'}],async 'validate'(_0x2d8a30){updateFields(_0x2d8a30);},async 'dryRun'(_0x4682e2){const _0x154c62=a60_0x5b74c6,{body:_0x163d4e}=await prepare(_0x4682e2);return dryRun(_0x154c62(0x106),_0x154c62(0x108))[_0x154c62(0x10e)](_0x163d4e)['description'](_0x154c62(0x10b))['build']();},async 'execute'(_0xb5e209){const _0x3f7c7e=a60_0x5b74c6,{role:_0x1957c9,body:_0x5a6c3c}=await prepare(_0xb5e209),_0x3fe05c=await updateRuntimeAppRole(_0x5a6c3c);return{'ok':!![],'data':runtimeRoleWriteResult('update',{'roleId':_0x1957c9['id']},projectRuntimeRole(_0x1957c9),projectRuntimeRole(_0x3fe05c),{'method':_0x3f7c7e(0x106),'path':'/client/permit/role/update'})};}};
@@ -1 +1 @@
1
- const a61_0x3a210e=a61_0x39bf;(function(_0x130f3b,_0x186d6a){const _0x46799e=a61_0x39bf,_0x44c286=_0x130f3b();while(!![]){try{const _0x105c31=parseInt(_0x46799e(0x1e6))/0x1*(-parseInt(_0x46799e(0x1f3))/0x2)+parseInt(_0x46799e(0x1e9))/0x3*(-parseInt(_0x46799e(0x1f8))/0x4)+parseInt(_0x46799e(0x1fb))/0x5+-parseInt(_0x46799e(0x1ec))/0x6+parseInt(_0x46799e(0x1fa))/0x7*(parseInt(_0x46799e(0x1e1))/0x8)+parseInt(_0x46799e(0x1ee))/0x9*(parseInt(_0x46799e(0x1ed))/0xa)+-parseInt(_0x46799e(0x1e5))/0xb*(-parseInt(_0x46799e(0x1f9))/0xc);if(_0x105c31===_0x186d6a)break;else _0x44c286['push'](_0x44c286['shift']());}catch(_0x2f8008){_0x44c286['push'](_0x44c286['shift']());}}}(a61_0x28c5,0xe48b4));function a61_0x28c5(){const _0x33b5b4=['build','POST','4255062Szoenm','2039030CgmMsd','18rZgUBN','Adds\x20the\x20given\x20runtime\x20user\x20to\x20the\x20target\x20role.\x20The\x20user\x20receives\x20the\x20permissions\x20of\x20that\x20role.','shouldWrite','/client/permit/user-role/update-user-list','userId','555610rDYmUJ','high-risk-write','before','roleList','appCode','1412TyopOj','11264352VoPpJt','2541keaJCa','2084240UrUeGu','36296EOrkTv','body','role','warnings','11gkLHtq','2SElzdS','Add\x20a\x20userId\x20to\x20one\x20runtime\x20role','user-add','10278VsVDxK'];a61_0x28c5=function(){return _0x33b5b4;};return a61_0x28c5();}function a61_0x39bf(_0x1b4f93,_0x28f071){_0x1b4f93=_0x1b4f93-0x1e1;const _0x28c587=a61_0x28c5();let _0x39bf01=_0x28c587[_0x1b4f93];return _0x39bf01;}import{updateRuntimeRoleUsers}from'../../core/api-client.js';import{dryRun}from'../../framework/dryrun.js';import{EXPECT_USER_COUNT_FLAG,prepareRuntimeMemberMutation,ROLE_REF_FLAG,runtimeRoleWriteResult,USER_ID_FLAG}from'../../commands/role/shared.js';export const roleUserAdd={'service':a61_0x3a210e(0x1e3),'command':a61_0x3a210e(0x1e8),'description':a61_0x3a210e(0x1e7),'risk':a61_0x3a210e(0x1f4),'confirmationDescription':a61_0x3a210e(0x1ef),'flags':[ROLE_REF_FLAG,USER_ID_FLAG,EXPECT_USER_COUNT_FLAG],async 'dryRun'(_0x44cc01){const _0x389a61=a61_0x3a210e,_0x5c57ca=await prepareRuntimeMemberMutation(_0x44cc01,_0x389a61(0x1e8));return dryRun(_0x389a61(0x1eb),_0x389a61(0x1f1))[_0x389a61(0x1e2)]({'appCode':_0x44cc01['appCode'],'roleList':_0x5c57ca[_0x389a61(0x1f6)]})['description'](_0x5c57ca['shouldWrite']?'Preview:\x20add\x20runtime\x20role\x20member':_0x5c57ca[_0x389a61(0x1e4)][0x0])[_0x389a61(0x1ea)]();},async 'execute'(_0x6bf286){const _0x333b9e=a61_0x3a210e,_0x530870=await prepareRuntimeMemberMutation(_0x6bf286,_0x333b9e(0x1e8));return _0x530870[_0x333b9e(0x1f0)]&&await updateRuntimeRoleUsers(_0x6bf286[_0x333b9e(0x1f7)],_0x530870['roleList']),{'ok':!![],'data':runtimeRoleWriteResult('user-add',{'roleId':_0x530870[_0x333b9e(0x1e3)]['id'],'userId':_0x530870[_0x333b9e(0x1f2)]},_0x530870[_0x333b9e(0x1f5)],_0x530870['after'],{'method':_0x333b9e(0x1eb),'path':_0x333b9e(0x1f1)},_0x530870[_0x333b9e(0x1e4)])};}};
1
+ function a61_0x2bf1(){const _0x316d73=['role','description','16mZhgOh','34065bEUFsu','userId','before','build','3242477pwSQqV','9cbYfAy','442836qiSQEx','user-add','/client/permit/user-role/update-user-list','Add\x20a\x20userId\x20to\x20one\x20runtime\x20role','shouldWrite','warnings','roleList','408dBpzTx','1247928HcPycs','19689CFFXEQ','6miRcNo','appCode','after','Adds\x20the\x20given\x20runtime\x20user\x20to\x20the\x20target\x20role.\x20The\x20user\x20receives\x20the\x20permissions\x20of\x20that\x20role.','5644552ufZnxp','3982540DEofuZ','high-risk-write'];a61_0x2bf1=function(){return _0x316d73;};return a61_0x2bf1();}const a61_0x5ea8d6=a61_0x1606;(function(_0x5574c1,_0x2112d7){const _0x1c567a=a61_0x1606,_0x1460e5=_0x5574c1();while(!![]){try{const _0x982afa=-parseInt(_0x1c567a(0x1ef))/0x1*(parseInt(_0x1c567a(0x1df))/0x2)+-parseInt(_0x1c567a(0x1e6))/0x3+parseInt(_0x1c567a(0x1ed))/0x4*(-parseInt(_0x1c567a(0x1e0))/0x5)+-parseInt(_0x1c567a(0x1f0))/0x6*(-parseInt(_0x1c567a(0x1e4))/0x7)+-parseInt(_0x1c567a(0x1f4))/0x8*(-parseInt(_0x1c567a(0x1e5))/0x9)+parseInt(_0x1c567a(0x1f5))/0xa+-parseInt(_0x1c567a(0x1ee))/0xb;if(_0x982afa===_0x2112d7)break;else _0x1460e5['push'](_0x1460e5['shift']());}catch(_0x4e6240){_0x1460e5['push'](_0x1460e5['shift']());}}}(a61_0x2bf1,0x6eba0));import{updateRuntimeRoleUsers}from'../../core/api-client.js';import{dryRun}from'../../framework/dryrun.js';function a61_0x1606(_0x4120b3,_0x54d2af){_0x4120b3=_0x4120b3-0x1dd;const _0x2bf10d=a61_0x2bf1();let _0x1606ad=_0x2bf10d[_0x4120b3];return _0x1606ad;}import{EXPECT_USER_COUNT_FLAG,prepareRuntimeMemberMutation,ROLE_REF_FLAG,runtimeRoleWriteResult,USER_ID_FLAG}from'../../commands/role/shared.js';export const roleUserAdd={'service':a61_0x5ea8d6(0x1dd),'command':a61_0x5ea8d6(0x1e7),'description':a61_0x5ea8d6(0x1e9),'risk':a61_0x5ea8d6(0x1f6),'confirmationDescription':a61_0x5ea8d6(0x1f3),'flags':[ROLE_REF_FLAG,USER_ID_FLAG,EXPECT_USER_COUNT_FLAG],async 'dryRun'(_0x748c3d){const _0x45585b=a61_0x5ea8d6,_0x310474=await prepareRuntimeMemberMutation(_0x748c3d,_0x45585b(0x1e7));return dryRun('POST',_0x45585b(0x1e8))['body']({'appCode':_0x748c3d['appCode'],'roleList':_0x310474[_0x45585b(0x1ec)]})[_0x45585b(0x1de)](_0x310474[_0x45585b(0x1ea)]?'Preview:\x20add\x20runtime\x20role\x20member':_0x310474[_0x45585b(0x1eb)][0x0])[_0x45585b(0x1e3)]();},async 'execute'(_0x1c6211){const _0x257527=a61_0x5ea8d6,_0x2fa9c7=await prepareRuntimeMemberMutation(_0x1c6211,'user-add');return _0x2fa9c7[_0x257527(0x1ea)]&&await updateRuntimeRoleUsers(_0x1c6211[_0x257527(0x1f1)],_0x2fa9c7[_0x257527(0x1ec)]),{'ok':!![],'data':runtimeRoleWriteResult('user-add',{'roleId':_0x2fa9c7[_0x257527(0x1dd)]['id'],'userId':_0x2fa9c7[_0x257527(0x1e1)]},_0x2fa9c7[_0x257527(0x1e2)],_0x2fa9c7[_0x257527(0x1f2)],{'method':'POST','path':_0x257527(0x1e8)},_0x2fa9c7['warnings'])};}};
@@ -1 +1 @@
1
- const a62_0x13e846=a62_0x59a0;(function(_0x42c0b7,_0x17f3bf){const _0x42954d=a62_0x59a0,_0x46ac28=_0x42c0b7();while(!![]){try{const _0x2dabb9=parseInt(_0x42954d(0x94))/0x1+-parseInt(_0x42954d(0x9f))/0x2+parseInt(_0x42954d(0x9a))/0x3+-parseInt(_0x42954d(0x9e))/0x4+parseInt(_0x42954d(0xa0))/0x5+-parseInt(_0x42954d(0xa2))/0x6+parseInt(_0x42954d(0xa7))/0x7*(parseInt(_0x42954d(0xa8))/0x8);if(_0x2dabb9===_0x17f3bf)break;else _0x46ac28['push'](_0x46ac28['shift']());}catch(_0x5f3aa6){_0x46ac28['push'](_0x46ac28['shift']());}}}(a62_0x3811,0x1de0f));function a62_0x59a0(_0x9864d9,_0x595d58){_0x9864d9=_0x9864d9-0x94;const _0x38118d=a62_0x3811();let _0x59a09f=_0x38118d[_0x9864d9];return _0x59a09f;}function a62_0x3811(){const _0x2267f3=['after','812970jslfCO','body','build','warnings','user-remove','9079YhkbpK','1432UuFuGj','Preview:\x20remove\x20runtime\x20role\x20member','Removes\x20the\x20given\x20runtime\x20user\x20from\x20the\x20target\x20role.\x20The\x20user\x20loses\x20permissions\x20granted\x20only\x20by\x20that\x20role.','152225UnXbpG','description','shouldWrite','role','before','/client/permit/user-role/update-user-list','170598ipUYXO','userId','appCode','POST','279512svpbya','275388FtbhSr','120980SHTxdk'];a62_0x3811=function(){return _0x2267f3;};return a62_0x3811();}import{updateRuntimeRoleUsers}from'../../core/api-client.js';import{dryRun}from'../../framework/dryrun.js';import{EXPECT_USER_COUNT_FLAG,prepareRuntimeMemberMutation,ROLE_REF_FLAG,runtimeRoleWriteResult,USER_ID_FLAG}from'../../commands/role/shared.js';export const roleUserRemove={'service':a62_0x13e846(0x97),'command':a62_0x13e846(0xa6),'description':'Remove\x20a\x20userId\x20from\x20one\x20runtime\x20role','risk':'high-risk-write','confirmationDescription':a62_0x13e846(0xaa),'flags':[ROLE_REF_FLAG,USER_ID_FLAG,EXPECT_USER_COUNT_FLAG],async 'dryRun'(_0x43e7af){const _0x55543c=a62_0x13e846,_0x4b363a=await prepareRuntimeMemberMutation(_0x43e7af,_0x55543c(0xa6));return dryRun('POST',_0x55543c(0x99))[_0x55543c(0xa3)]({'appCode':_0x43e7af[_0x55543c(0x9c)],'roleList':_0x4b363a['roleList']})[_0x55543c(0x95)](_0x4b363a['shouldWrite']?_0x55543c(0xa9):_0x4b363a[_0x55543c(0xa5)][0x0])[_0x55543c(0xa4)]();},async 'execute'(_0x2a9c3f){const _0x2295fd=a62_0x13e846,_0x26cee8=await prepareRuntimeMemberMutation(_0x2a9c3f,_0x2295fd(0xa6));return _0x26cee8[_0x2295fd(0x96)]&&await updateRuntimeRoleUsers(_0x2a9c3f[_0x2295fd(0x9c)],_0x26cee8['roleList']),{'ok':!![],'data':runtimeRoleWriteResult(_0x2295fd(0xa6),{'roleId':_0x26cee8[_0x2295fd(0x97)]['id'],'userId':_0x26cee8[_0x2295fd(0x9b)]},_0x26cee8[_0x2295fd(0x98)],_0x26cee8[_0x2295fd(0xa1)],{'method':_0x2295fd(0x9d),'path':_0x2295fd(0x99)},_0x26cee8[_0x2295fd(0xa5)])};}};
1
+ const a62_0x5a6c34=a62_0x56cf;(function(_0x296c74,_0x1016ca){const _0x3fdb78=a62_0x56cf,_0x324073=_0x296c74();while(!![]){try{const _0x87f3fb=-parseInt(_0x3fdb78(0xda))/0x1*(parseInt(_0x3fdb78(0xed))/0x2)+parseInt(_0x3fdb78(0xdb))/0x3*(-parseInt(_0x3fdb78(0xe4))/0x4)+-parseInt(_0x3fdb78(0xd8))/0x5*(parseInt(_0x3fdb78(0xeb))/0x6)+parseInt(_0x3fdb78(0xe9))/0x7+parseInt(_0x3fdb78(0xe8))/0x8*(parseInt(_0x3fdb78(0xe7))/0x9)+parseInt(_0x3fdb78(0xe3))/0xa+-parseInt(_0x3fdb78(0xdd))/0xb*(parseInt(_0x3fdb78(0xe0))/0xc);if(_0x87f3fb===_0x1016ca)break;else _0x324073['push'](_0x324073['shift']());}catch(_0x8742ab){_0x324073['push'](_0x324073['shift']());}}}(a62_0x218d,0x8ee5e));function a62_0x56cf(_0x157a0c,_0x34dc52){_0x157a0c=_0x157a0c-0xd4;const _0x218dc3=a62_0x218d();let _0x56cfa2=_0x218dc3[_0x157a0c];return _0x56cfa2;}import{updateRuntimeRoleUsers}from'../../core/api-client.js';import{dryRun}from'../../framework/dryrun.js';import{EXPECT_USER_COUNT_FLAG,prepareRuntimeMemberMutation,ROLE_REF_FLAG,runtimeRoleWriteResult,USER_ID_FLAG}from'../../commands/role/shared.js';function a62_0x218d(){const _0x226645=['shouldWrite','after','11596370kqGQwn','2877716XoxiHw','Preview:\x20remove\x20runtime\x20role\x20member','role','9hgrHOo','8800408gJArGy','2700138zlvAFS','Removes\x20the\x20given\x20runtime\x20user\x20from\x20the\x20target\x20role.\x20The\x20user\x20loses\x20permissions\x20granted\x20only\x20by\x20that\x20role.','25170QoVkIU','user-remove','18JTIDVl','/client/permit/user-role/update-user-list','roleList','Remove\x20a\x20userId\x20from\x20one\x20runtime\x20role','userId','warnings','955qKZgYI','before','23841AYFsLN','3EIpzmA','description','3573559jGzHtR','high-risk-write','appCode','12qmuLRm'];a62_0x218d=function(){return _0x226645;};return a62_0x218d();}export const roleUserRemove={'service':'role','command':a62_0x5a6c34(0xec),'description':a62_0x5a6c34(0xd5),'risk':a62_0x5a6c34(0xde),'confirmationDescription':a62_0x5a6c34(0xea),'flags':[ROLE_REF_FLAG,USER_ID_FLAG,EXPECT_USER_COUNT_FLAG],async 'dryRun'(_0x56643b){const _0x5968ab=a62_0x5a6c34,_0xa5ba80=await prepareRuntimeMemberMutation(_0x56643b,_0x5968ab(0xec));return dryRun('POST',_0x5968ab(0xee))['body']({'appCode':_0x56643b[_0x5968ab(0xdf)],'roleList':_0xa5ba80[_0x5968ab(0xd4)]})[_0x5968ab(0xdc)](_0xa5ba80[_0x5968ab(0xe1)]?_0x5968ab(0xe5):_0xa5ba80[_0x5968ab(0xd7)][0x0])['build']();},async 'execute'(_0x38546a){const _0x2d669d=a62_0x5a6c34,_0x209113=await prepareRuntimeMemberMutation(_0x38546a,_0x2d669d(0xec));return _0x209113['shouldWrite']&&await updateRuntimeRoleUsers(_0x38546a[_0x2d669d(0xdf)],_0x209113['roleList']),{'ok':!![],'data':runtimeRoleWriteResult(_0x2d669d(0xec),{'roleId':_0x209113[_0x2d669d(0xe6)]['id'],'userId':_0x209113[_0x2d669d(0xd6)]},_0x209113[_0x2d669d(0xd9)],_0x209113[_0x2d669d(0xe2)],{'method':'POST','path':'/client/permit/user-role/update-user-list'},_0x209113[_0x2d669d(0xd7)])};}};
@@ -1 +1 @@
1
- const a63_0x225ec6=a63_0x4601;(function(_0x306ad4,_0x3a3cc9){const _0xcc6f60=a63_0x4601,_0x581c05=_0x306ad4();while(!![]){try{const _0x2e7711=-parseInt(_0xcc6f60(0x1ac))/0x1*(-parseInt(_0xcc6f60(0x1ae))/0x2)+parseInt(_0xcc6f60(0x1ad))/0x3+parseInt(_0xcc6f60(0x1ab))/0x4*(-parseInt(_0xcc6f60(0x1a8))/0x5)+parseInt(_0xcc6f60(0x176))/0x6*(-parseInt(_0xcc6f60(0x17f))/0x7)+parseInt(_0xcc6f60(0x1a1))/0x8+-parseInt(_0xcc6f60(0x1a9))/0x9+parseInt(_0xcc6f60(0x1b6))/0xa*(-parseInt(_0xcc6f60(0x18c))/0xb);if(_0x2e7711===_0x3a3cc9)break;else _0x581c05['push'](_0x581c05['shift']());}catch(_0x51892f){_0x581c05['push'](_0x581c05['shift']());}}}(a63_0x45dc,0x4be39));function a63_0x45dc(){const _0x13a63d=['Preview:\x20run\x20schedule\x20','\x20immediately','Create\x20a\x20recurring\x20or\x20one-shot\x20Agent\x20schedule','Ignores\x20the\x20original\x20trigger\x20time,\x20runs\x20the\x20schedule\x20once\x20now,\x20and\x20creates\x20a\x20new\x20Agent\x20Task.','List\x20current\x20user\x27s\x20schedules\x20for\x20the\x20current\x20app','validate','--kind\x20must\x20be\x20CRON\x20or\x20ONCE.','str','Opaque\x20nextCursor\x20returned\x20by\x20the\x20previous\x20list\x20call','UTC','create','string','3531zvJTuA','/run','Task\x20model\x20used\x20when\x20the\x20schedule\x20runs','Five-field\x20UTC\x20cron\x20expression\x20for\x20CRON\x20schedules','Creates\x20a\x20schedule\x20in\x20the\x20current\x20app\x20that\x20can\x20auto-trigger\x20an\x20Agent.\x20At\x20the\x20scheduled\x20time\x20a\x20Task\x20is\x20created\x20and\x20run.','Schedule\x20title','prompt','Validate\x20a\x20UTC\x20schedule\x20without\x20creating\x20it','limit','run','isSafeInteger','Queued\x20Task\x20','--cursor\x20must\x20be\x20the\x20unchanged\x20nextCursor\x20from\x20schedule\x20list.','ONCE','kind','\x20schedule\x20','Preview:\x20create\x20an\x20Agent\x20schedule','kimi/k3','ONCE\x20schedules\x20require\x20--scheduled-at\x20and\x20do\x20not\x20accept\x20--cron.','/api/harness/apps/','taskId','3862768pMMnKt','delete','high-risk-write','deepseek-v4-flash-0731','Preview:\x20delete\x20schedule\x20','\x20from\x20schedule\x20','schedule-id','5LjzyPx','1158300oqgIPJ','validation','2176272KoEkVC','1473NyWjSA','999252GmxNGd','646FoNqov','appCode','model','cron','description','schedule','CRON','--limit\x20must\x20be\x20an\x20integer\x20from\x201\x20to\x20100.','8480vIVHqP','list','/schedules','read','scheduled-at','Deleted\x20schedule\x20','cursor','trim','Schedule\x20kind:\x20CRON\x20or\x20ONCE','Permanently\x20deletes\x20the\x20schedule\x20and\x20stops\x20future\x20auto-triggers.\x20Historical\x20Tasks\x20already\x20created\x20are\x20not\x20affected.','17946QQVFqP','title','DELETE','length','--prompt\x20must\x20not\x20be\x20blank.','detail','Schedule\x20UUID','build','Created\x20','84ovlEZR'];a63_0x45dc=function(){return _0x13a63d;};return a63_0x45dc();}import{createRuntimeSchedule,deleteRuntimeSchedule,getRuntimeSchedule,listRuntimeSchedules,runRuntimeSchedule,validateRuntimeSchedule}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';function a63_0x4601(_0x39b42d,_0x35e0ba){_0x39b42d=_0x39b42d-0x16f;const _0x45dce2=a63_0x45dc();let _0x46012c=_0x45dce2[_0x39b42d];return _0x46012c;}const SCHEDULE_ID_PATTERN=/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i,KIND_FLAG={'name':a63_0x225ec6(0x19a),'type':a63_0x225ec6(0x18b),'required':!![],'enum':[a63_0x225ec6(0x1b4),a63_0x225ec6(0x199)],'description':a63_0x225ec6(0x174)},CRON_FLAG={'name':a63_0x225ec6(0x1b1),'type':a63_0x225ec6(0x18b),'description':a63_0x225ec6(0x18f)},SCHEDULED_AT_FLAG={'name':a63_0x225ec6(0x170),'type':a63_0x225ec6(0x18b),'description':'Canonical\x20UTC\x20ISO\x20datetime\x20for\x20ONCE\x20schedules'},TITLE_FLAG={'name':'title','type':a63_0x225ec6(0x18b),'required':!![],'description':a63_0x225ec6(0x191)},PROMPT_FLAG={'name':'prompt','type':'string','required':!![],'description':'Prompt\x20sent\x20to\x20the\x20Agent\x20when\x20the\x20schedule\x20runs'},MODEL_FLAG={'name':a63_0x225ec6(0x1b0),'type':a63_0x225ec6(0x18b),'enum':[a63_0x225ec6(0x19d),a63_0x225ec6(0x1a4),'deepseek-v4-pro-0813'],'default':a63_0x225ec6(0x1a4),'description':a63_0x225ec6(0x18e)},SCHEDULE_ID_FLAG={'name':a63_0x225ec6(0x1a7),'type':a63_0x225ec6(0x18b),'required':!![],'description':a63_0x225ec6(0x17c),'pattern':{'regex':SCHEDULE_ID_PATTERN,'description':'a\x20UUID\x20returned\x20by\x20schedule\x20create/list'}},LIMIT_FLAG={'name':a63_0x225ec6(0x194),'type':'number','default':0x14,'description':'Page\x20size\x20from\x201\x20to\x20100'},CURSOR_FLAG={'name':a63_0x225ec6(0x172),'type':a63_0x225ec6(0x18b),'description':a63_0x225ec6(0x188)},INPUT_FLAGS=[KIND_FLAG,CRON_FLAG,SCHEDULED_AT_FLAG,TITLE_FLAG,PROMPT_FLAG,MODEL_FLAG];function readScheduleInput(_0x24a7c4){const _0x36604b=a63_0x225ec6,_0x1c3823=_0x24a7c4[_0x36604b(0x187)](_0x36604b(0x19a)),_0x4802ce=_0x24a7c4[_0x36604b(0x187)](_0x36604b(0x177))[_0x36604b(0x173)](),_0x2b1f7a=_0x24a7c4[_0x36604b(0x187)](_0x36604b(0x192))[_0x36604b(0x173)](),_0x3998fd=_0x24a7c4[_0x36604b(0x187)](_0x36604b(0x1b0)),_0x12221e=_0x24a7c4[_0x36604b(0x187)]('cron'),_0x4f6d02=_0x24a7c4[_0x36604b(0x187)](_0x36604b(0x170));if(!_0x4802ce)throw CliErrors[_0x36604b(0x1aa)]('--title\x20must\x20not\x20be\x20blank.');if(!_0x2b1f7a)throw CliErrors[_0x36604b(0x1aa)](_0x36604b(0x17a));if(_0x1c3823==='CRON'){if(!_0x12221e||_0x4f6d02)throw CliErrors[_0x36604b(0x1aa)]('CRON\x20schedules\x20require\x20--cron\x20and\x20do\x20not\x20accept\x20--scheduled-at.');return{'kind':_0x1c3823,'timezone':_0x36604b(0x189),'cron':_0x12221e,'title':_0x4802ce,'prompt':_0x2b1f7a,'model':_0x3998fd};}if(_0x1c3823===_0x36604b(0x199)){if(!_0x4f6d02||_0x12221e)throw CliErrors[_0x36604b(0x1aa)](_0x36604b(0x19e));return{'kind':_0x1c3823,'timezone':_0x36604b(0x189),'scheduledAt':_0x4f6d02,'title':_0x4802ce,'prompt':_0x2b1f7a,'model':_0x3998fd};}throw CliErrors[_0x36604b(0x1aa)](_0x36604b(0x186));}function scheduleCollectionPath(_0x33db7c){const _0x2c0253=a63_0x225ec6;return _0x2c0253(0x19f)+encodeURIComponent(_0x33db7c)+_0x2c0253(0x1b8);}function scheduleItemPath(_0x20d926,_0x6d0abb){return scheduleCollectionPath(_0x20d926)+'/'+encodeURIComponent(_0x6d0abb);}const scheduleValidate={'service':'schedule','command':a63_0x225ec6(0x185),'description':a63_0x225ec6(0x193),'risk':a63_0x225ec6(0x16f),'flags':INPUT_FLAGS,async 'validate'(_0x2544d5){readScheduleInput(_0x2544d5);},async 'execute'(_0x3b17d){const _0x483302=readScheduleInput(_0x3b17d),_0x6fbef6=await validateRuntimeSchedule(_0x3b17d['appCode'],_0x483302);return{'ok':!![],'data':_0x6fbef6,'message':'Schedule\x20input\x20is\x20valid'};}},scheduleCreate={'service':'schedule','command':a63_0x225ec6(0x18a),'description':a63_0x225ec6(0x182),'risk':'high-risk-write','confirmationDescription':a63_0x225ec6(0x190),'flags':INPUT_FLAGS,async 'validate'(_0x401c65){readScheduleInput(_0x401c65);},async 'execute'(_0x1476c5){const _0x158693=a63_0x225ec6,_0xe2cf80=readScheduleInput(_0x1476c5),_0x2a53cc=await validateRuntimeSchedule(_0x1476c5['appCode'],_0xe2cf80),_0x359efa=await createRuntimeSchedule(_0x1476c5[_0x158693(0x1af)],_0x2a53cc);return{'ok':!![],'data':_0x359efa,'message':_0x158693(0x17e)+_0x359efa[_0x158693(0x19a)]+_0x158693(0x19b)+_0x359efa['scheduleId']};},async 'dryRun'(_0x22e6bf){const _0x5b3ada=a63_0x225ec6,_0x16fad0=readScheduleInput(_0x22e6bf);return dryRun('POST',scheduleCollectionPath(_0x22e6bf['appCode']))['body'](_0x16fad0)[_0x5b3ada(0x1b2)](_0x5b3ada(0x19c))['build']();}},scheduleList={'service':a63_0x225ec6(0x1b3),'command':a63_0x225ec6(0x1b7),'description':a63_0x225ec6(0x184),'risk':a63_0x225ec6(0x16f),'flags':[KIND_FLAG,LIMIT_FLAG,CURSOR_FLAG],async 'validate'(_0x3f86ae){const _0x1a4d54=a63_0x225ec6,_0x63d6c=_0x3f86ae['num']('limit');if(!Number[_0x1a4d54(0x196)](_0x63d6c)||_0x63d6c<0x1||_0x63d6c>0x64)throw CliErrors[_0x1a4d54(0x1aa)](_0x1a4d54(0x1b5));const _0x1b7b8f=_0x3f86ae[_0x1a4d54(0x187)](_0x1a4d54(0x172));if(_0x1b7b8f&&(_0x1b7b8f[_0x1a4d54(0x179)]>0x400||_0x1b7b8f[_0x1a4d54(0x173)]()!==_0x1b7b8f))throw CliErrors[_0x1a4d54(0x1aa)](_0x1a4d54(0x198));},async 'execute'(_0x48bdb4){const _0x3c7394=a63_0x225ec6,_0x3b31d1=_0x48bdb4[_0x3c7394(0x187)]('cursor'),_0x247196=await listRuntimeSchedules(_0x48bdb4[_0x3c7394(0x1af)],{'kind':_0x48bdb4[_0x3c7394(0x187)]('kind'),'limit':_0x48bdb4['num'](_0x3c7394(0x194)),..._0x3b31d1?{'cursor':_0x3b31d1}:{}});return{'ok':!![],'data':_0x247196};}},scheduleDetail={'service':a63_0x225ec6(0x1b3),'command':a63_0x225ec6(0x17b),'description':'Show\x20one\x20schedule\x20by\x20schedule\x20ID','risk':a63_0x225ec6(0x16f),'flags':[SCHEDULE_ID_FLAG],async 'execute'(_0x235860){const _0x5975c1=a63_0x225ec6,_0x30d602=await getRuntimeSchedule(_0x235860[_0x5975c1(0x1af)],_0x235860[_0x5975c1(0x187)](_0x5975c1(0x1a7)));return{'ok':!![],'data':_0x30d602};}},scheduleRun={'service':'schedule','command':a63_0x225ec6(0x195),'description':'Run\x20the\x20schedule\x20once\x20immediately\x20and\x20create\x20a\x20Task','risk':a63_0x225ec6(0x1a3),'confirmationDescription':a63_0x225ec6(0x183),'flags':[SCHEDULE_ID_FLAG],async 'execute'(_0x42dd73){const _0x50917e=a63_0x225ec6,_0x3f9ab4=_0x42dd73[_0x50917e(0x187)](_0x50917e(0x1a7)),_0x554fe4=await runRuntimeSchedule(_0x42dd73[_0x50917e(0x1af)],_0x3f9ab4);return{'ok':!![],'data':_0x554fe4,'message':_0x50917e(0x197)+_0x554fe4[_0x50917e(0x1a0)]+_0x50917e(0x1a6)+_0x3f9ab4};},async 'dryRun'(_0x5415b0){const _0x221444=a63_0x225ec6,_0x5bf031=_0x5415b0[_0x221444(0x187)](_0x221444(0x1a7));return dryRun('POST',scheduleItemPath(_0x5415b0[_0x221444(0x1af)],_0x5bf031)+_0x221444(0x18d))[_0x221444(0x1b2)](_0x221444(0x180)+_0x5bf031+_0x221444(0x181))[_0x221444(0x17d)]();}},scheduleDelete={'service':a63_0x225ec6(0x1b3),'command':a63_0x225ec6(0x1a2),'description':'Delete\x20the\x20schedule\x20and\x20stop\x20future\x20triggers','risk':'high-risk-write','confirmationDescription':a63_0x225ec6(0x175),'flags':[SCHEDULE_ID_FLAG],async 'execute'(_0x33bd43){const _0x40402b=a63_0x225ec6,_0x107d1f=_0x33bd43[_0x40402b(0x187)](_0x40402b(0x1a7)),_0x1a34c9=await deleteRuntimeSchedule(_0x33bd43[_0x40402b(0x1af)],_0x107d1f);return{'ok':!![],'data':_0x1a34c9,'message':_0x40402b(0x171)+_0x107d1f};},async 'dryRun'(_0x3e78fc){const _0x5c875b=a63_0x225ec6,_0xc70b4c=_0x3e78fc['str']('schedule-id');return dryRun(_0x5c875b(0x178),scheduleItemPath(_0x3e78fc[_0x5c875b(0x1af)],_0xc70b4c))[_0x5c875b(0x1b2)](_0x5c875b(0x1a5)+_0xc70b4c)[_0x5c875b(0x17d)]();}};export const scheduleDefinitions=[scheduleValidate,scheduleCreate,scheduleList,scheduleDetail,scheduleRun,scheduleDelete];
1
+ const a63_0x3f6c6b=a63_0x398e;(function(_0xebe22c,_0xfb58e8){const _0x31c83c=a63_0x398e,_0x51211a=_0xebe22c();while(!![]){try{const _0x5375bb=-parseInt(_0x31c83c(0xe1))/0x1*(-parseInt(_0x31c83c(0xc8))/0x2)+parseInt(_0x31c83c(0xa3))/0x3*(-parseInt(_0x31c83c(0xcc))/0x4)+-parseInt(_0x31c83c(0xb4))/0x5+parseInt(_0x31c83c(0xda))/0x6*(parseInt(_0x31c83c(0xdc))/0x7)+-parseInt(_0x31c83c(0xd6))/0x8+-parseInt(_0x31c83c(0xa8))/0x9+parseInt(_0x31c83c(0xb5))/0xa*(parseInt(_0x31c83c(0xae))/0xb);if(_0x5375bb===_0xfb58e8)break;else _0x51211a['push'](_0x51211a['shift']());}catch(_0x581485){_0x51211a['push'](_0x51211a['shift']());}}}(a63_0x5ce4,0x39355));function a63_0x5ce4(){const _0x2278f2=['create','Creates\x20a\x20schedule\x20in\x20the\x20current\x20app\x20that\x20can\x20auto-trigger\x20an\x20Agent.\x20At\x20the\x20scheduled\x20time\x20a\x20Task\x20is\x20created\x20and\x20run.','10631929GUaVQN','Schedule\x20input\x20is\x20valid','POST','appCode','CRON\x20schedules\x20require\x20--cron\x20and\x20do\x20not\x20accept\x20--scheduled-at.','Ignores\x20the\x20original\x20trigger\x20time,\x20runs\x20the\x20schedule\x20once\x20now,\x20and\x20creates\x20a\x20new\x20Agent\x20Task.','36735RTPWil','10BcpNFt','description','Show\x20one\x20schedule\x20by\x20schedule\x20ID','Preview:\x20delete\x20schedule\x20','number','UTC','Opaque\x20nextCursor\x20returned\x20by\x20the\x20previous\x20list\x20call','detail','deepseek-v4-flash-0731','cron','kind','delete','run','read','Delete\x20the\x20schedule\x20and\x20stop\x20future\x20triggers','schedule-id','build','scheduleId','ONCE\x20schedules\x20require\x20--scheduled-at\x20and\x20do\x20not\x20accept\x20--cron.','28438cAiQyA','ONCE','/api/harness/apps/','trim','1352UtWQwx','cursor','model','Preview:\x20run\x20schedule\x20','Schedule\x20UUID','string','scheduled-at','num','validation','Prompt\x20sent\x20to\x20the\x20Agent\x20when\x20the\x20schedule\x20runs','1389864bbBLmr','Task\x20model\x20used\x20when\x20the\x20schedule\x20runs','Canonical\x20UTC\x20ISO\x20datetime\x20for\x20ONCE\x20schedules','List\x20current\x20user\x27s\x20schedules\x20for\x20the\x20current\x20app','30cuxMoM','Deleted\x20schedule\x20','74144bXjcah','/run','Permanently\x20deletes\x20the\x20schedule\x20and\x20stops\x20future\x20auto-triggers.\x20Historical\x20Tasks\x20already\x20created\x20are\x20not\x20affected.','CRON','taskId','3TxqobZ','--kind\x20must\x20be\x20CRON\x20or\x20ONCE.','Five-field\x20UTC\x20cron\x20expression\x20for\x20CRON\x20schedules','high-risk-write','Schedule\x20kind:\x20CRON\x20or\x20ONCE','\x20schedule\x20','str','Schedule\x20title','list','Queued\x20Task\x20','deepseek-v4-pro-0813','1878RNPoqH','limit','schedule','prompt','\x20from\x20schedule\x20','3916467aUICFe','--title\x20must\x20not\x20be\x20blank.','Create\x20a\x20recurring\x20or\x20one-shot\x20Agent\x20schedule','title'];a63_0x5ce4=function(){return _0x2278f2;};return a63_0x5ce4();}import{createRuntimeSchedule,deleteRuntimeSchedule,getRuntimeSchedule,listRuntimeSchedules,runRuntimeSchedule,validateRuntimeSchedule}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const SCHEDULE_ID_PATTERN=/^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i,KIND_FLAG={'name':a63_0x3f6c6b(0xbf),'type':'string','required':!![],'enum':[a63_0x3f6c6b(0xdf),a63_0x3f6c6b(0xc9)],'description':a63_0x3f6c6b(0xe5)},CRON_FLAG={'name':a63_0x3f6c6b(0xbe),'type':a63_0x3f6c6b(0xd1),'description':a63_0x3f6c6b(0xe3)},SCHEDULED_AT_FLAG={'name':'scheduled-at','type':'string','description':a63_0x3f6c6b(0xd8)},TITLE_FLAG={'name':a63_0x3f6c6b(0xab),'type':'string','required':!![],'description':a63_0x3f6c6b(0x9f)},PROMPT_FLAG={'name':a63_0x3f6c6b(0xa6),'type':a63_0x3f6c6b(0xd1),'required':!![],'description':a63_0x3f6c6b(0xd5)},MODEL_FLAG={'name':'model','type':a63_0x3f6c6b(0xd1),'enum':['kimi/k3',a63_0x3f6c6b(0xbd),a63_0x3f6c6b(0xa2)],'default':'deepseek-v4-flash-0731','description':a63_0x3f6c6b(0xd7)},SCHEDULE_ID_FLAG={'name':a63_0x3f6c6b(0xc4),'type':a63_0x3f6c6b(0xd1),'required':!![],'description':a63_0x3f6c6b(0xd0),'pattern':{'regex':SCHEDULE_ID_PATTERN,'description':'a\x20UUID\x20returned\x20by\x20schedule\x20create/list'}},LIMIT_FLAG={'name':a63_0x3f6c6b(0xa4),'type':a63_0x3f6c6b(0xb9),'default':0x14,'description':'Page\x20size\x20from\x201\x20to\x20100'},CURSOR_FLAG={'name':'cursor','type':'string','description':a63_0x3f6c6b(0xbb)},INPUT_FLAGS=[KIND_FLAG,CRON_FLAG,SCHEDULED_AT_FLAG,TITLE_FLAG,PROMPT_FLAG,MODEL_FLAG];function a63_0x398e(_0x12f771,_0x539146){_0x12f771=_0x12f771-0x9f;const _0x5ce42d=a63_0x5ce4();let _0x398e72=_0x5ce42d[_0x12f771];return _0x398e72;}function readScheduleInput(_0x4cb446){const _0x13e5b1=a63_0x3f6c6b,_0x1d379c=_0x4cb446[_0x13e5b1(0xe7)]('kind'),_0x5e525b=_0x4cb446[_0x13e5b1(0xe7)](_0x13e5b1(0xab))[_0x13e5b1(0xcb)](),_0x119408=_0x4cb446[_0x13e5b1(0xe7)](_0x13e5b1(0xa6))['trim'](),_0x3a7287=_0x4cb446['str'](_0x13e5b1(0xce)),_0x11973f=_0x4cb446['str'](_0x13e5b1(0xbe)),_0x1f8d3e=_0x4cb446[_0x13e5b1(0xe7)](_0x13e5b1(0xd2));if(!_0x5e525b)throw CliErrors[_0x13e5b1(0xd4)](_0x13e5b1(0xa9));if(!_0x119408)throw CliErrors[_0x13e5b1(0xd4)]('--prompt\x20must\x20not\x20be\x20blank.');if(_0x1d379c===_0x13e5b1(0xdf)){if(!_0x11973f||_0x1f8d3e)throw CliErrors[_0x13e5b1(0xd4)](_0x13e5b1(0xb2));return{'kind':_0x1d379c,'timezone':_0x13e5b1(0xba),'cron':_0x11973f,'title':_0x5e525b,'prompt':_0x119408,'model':_0x3a7287};}if(_0x1d379c==='ONCE'){if(!_0x1f8d3e||_0x11973f)throw CliErrors[_0x13e5b1(0xd4)](_0x13e5b1(0xc7));return{'kind':_0x1d379c,'timezone':_0x13e5b1(0xba),'scheduledAt':_0x1f8d3e,'title':_0x5e525b,'prompt':_0x119408,'model':_0x3a7287};}throw CliErrors[_0x13e5b1(0xd4)](_0x13e5b1(0xe2));}function scheduleCollectionPath(_0x2721d3){const _0x374312=a63_0x3f6c6b;return _0x374312(0xca)+encodeURIComponent(_0x2721d3)+'/schedules';}function scheduleItemPath(_0x3f6ff2,_0x34d50d){return scheduleCollectionPath(_0x3f6ff2)+'/'+encodeURIComponent(_0x34d50d);}const scheduleValidate={'service':a63_0x3f6c6b(0xa5),'command':'validate','description':'Validate\x20a\x20UTC\x20schedule\x20without\x20creating\x20it','risk':a63_0x3f6c6b(0xc2),'flags':INPUT_FLAGS,async 'validate'(_0x59dcbc){readScheduleInput(_0x59dcbc);},async 'execute'(_0x225af3){const _0x36edc0=a63_0x3f6c6b,_0x52f74d=readScheduleInput(_0x225af3),_0x19c44c=await validateRuntimeSchedule(_0x225af3['appCode'],_0x52f74d);return{'ok':!![],'data':_0x19c44c,'message':_0x36edc0(0xaf)};}},scheduleCreate={'service':'schedule','command':a63_0x3f6c6b(0xac),'description':a63_0x3f6c6b(0xaa),'risk':a63_0x3f6c6b(0xe4),'confirmationDescription':a63_0x3f6c6b(0xad),'flags':INPUT_FLAGS,async 'validate'(_0x20aece){readScheduleInput(_0x20aece);},async 'execute'(_0x107e5d){const _0x2d86a3=a63_0x3f6c6b,_0x2ea3ca=readScheduleInput(_0x107e5d),_0x49d7f7=await validateRuntimeSchedule(_0x107e5d[_0x2d86a3(0xb1)],_0x2ea3ca),_0x1e12f7=await createRuntimeSchedule(_0x107e5d['appCode'],_0x49d7f7);return{'ok':!![],'data':_0x1e12f7,'message':'Created\x20'+_0x1e12f7[_0x2d86a3(0xbf)]+_0x2d86a3(0xe6)+_0x1e12f7[_0x2d86a3(0xc6)]};},async 'dryRun'(_0x519662){const _0x5613a9=a63_0x3f6c6b,_0x52b298=readScheduleInput(_0x519662);return dryRun('POST',scheduleCollectionPath(_0x519662[_0x5613a9(0xb1)]))['body'](_0x52b298)[_0x5613a9(0xb6)]('Preview:\x20create\x20an\x20Agent\x20schedule')['build']();}},scheduleList={'service':a63_0x3f6c6b(0xa5),'command':a63_0x3f6c6b(0xa0),'description':a63_0x3f6c6b(0xd9),'risk':a63_0x3f6c6b(0xc2),'flags':[KIND_FLAG,LIMIT_FLAG,CURSOR_FLAG],async 'validate'(_0x969b30){const _0x422c24=a63_0x3f6c6b,_0x2ff6c4=_0x969b30[_0x422c24(0xd3)](_0x422c24(0xa4));if(!Number['isSafeInteger'](_0x2ff6c4)||_0x2ff6c4<0x1||_0x2ff6c4>0x64)throw CliErrors[_0x422c24(0xd4)]('--limit\x20must\x20be\x20an\x20integer\x20from\x201\x20to\x20100.');const _0xf3a05f=_0x969b30[_0x422c24(0xe7)](_0x422c24(0xcd));if(_0xf3a05f&&(_0xf3a05f['length']>0x400||_0xf3a05f[_0x422c24(0xcb)]()!==_0xf3a05f))throw CliErrors[_0x422c24(0xd4)]('--cursor\x20must\x20be\x20the\x20unchanged\x20nextCursor\x20from\x20schedule\x20list.');},async 'execute'(_0x1030a6){const _0x1d9258=a63_0x3f6c6b,_0x4a224f=_0x1030a6[_0x1d9258(0xe7)]('cursor'),_0x542fed=await listRuntimeSchedules(_0x1030a6[_0x1d9258(0xb1)],{'kind':_0x1030a6['str'](_0x1d9258(0xbf)),'limit':_0x1030a6[_0x1d9258(0xd3)](_0x1d9258(0xa4)),..._0x4a224f?{'cursor':_0x4a224f}:{}});return{'ok':!![],'data':_0x542fed};}},scheduleDetail={'service':'schedule','command':a63_0x3f6c6b(0xbc),'description':a63_0x3f6c6b(0xb7),'risk':'read','flags':[SCHEDULE_ID_FLAG],async 'execute'(_0x4f5ec4){const _0x4ecb76=a63_0x3f6c6b,_0xe76767=await getRuntimeSchedule(_0x4f5ec4[_0x4ecb76(0xb1)],_0x4f5ec4[_0x4ecb76(0xe7)](_0x4ecb76(0xc4)));return{'ok':!![],'data':_0xe76767};}},scheduleRun={'service':a63_0x3f6c6b(0xa5),'command':a63_0x3f6c6b(0xc1),'description':'Run\x20the\x20schedule\x20once\x20immediately\x20and\x20create\x20a\x20Task','risk':'high-risk-write','confirmationDescription':a63_0x3f6c6b(0xb3),'flags':[SCHEDULE_ID_FLAG],async 'execute'(_0x11a693){const _0x16a02c=a63_0x3f6c6b,_0x403c92=_0x11a693['str'](_0x16a02c(0xc4)),_0x137d62=await runRuntimeSchedule(_0x11a693[_0x16a02c(0xb1)],_0x403c92);return{'ok':!![],'data':_0x137d62,'message':_0x16a02c(0xa1)+_0x137d62[_0x16a02c(0xe0)]+_0x16a02c(0xa7)+_0x403c92};},async 'dryRun'(_0xb33208){const _0x398cca=a63_0x3f6c6b,_0x2a9554=_0xb33208[_0x398cca(0xe7)](_0x398cca(0xc4));return dryRun(_0x398cca(0xb0),scheduleItemPath(_0xb33208[_0x398cca(0xb1)],_0x2a9554)+_0x398cca(0xdd))[_0x398cca(0xb6)](_0x398cca(0xcf)+_0x2a9554+'\x20immediately')[_0x398cca(0xc5)]();}},scheduleDelete={'service':a63_0x3f6c6b(0xa5),'command':a63_0x3f6c6b(0xc0),'description':a63_0x3f6c6b(0xc3),'risk':a63_0x3f6c6b(0xe4),'confirmationDescription':a63_0x3f6c6b(0xde),'flags':[SCHEDULE_ID_FLAG],async 'execute'(_0x274e08){const _0x351a78=a63_0x3f6c6b,_0x1bc888=_0x274e08[_0x351a78(0xe7)]('schedule-id'),_0x119d01=await deleteRuntimeSchedule(_0x274e08[_0x351a78(0xb1)],_0x1bc888);return{'ok':!![],'data':_0x119d01,'message':_0x351a78(0xdb)+_0x1bc888};},async 'dryRun'(_0x2b8464){const _0x56efba=a63_0x3f6c6b,_0x263eff=_0x2b8464[_0x56efba(0xe7)](_0x56efba(0xc4));return dryRun('DELETE',scheduleItemPath(_0x2b8464[_0x56efba(0xb1)],_0x263eff))[_0x56efba(0xb6)](_0x56efba(0xb8)+_0x263eff)['build']();}};export const scheduleDefinitions=[scheduleValidate,scheduleCreate,scheduleList,scheduleDetail,scheduleRun,scheduleDelete];
@@ -1 +1 @@
1
- const a64_0x1948d7=a64_0x46a9;(function(_0x3f079f,_0x488ecc){const _0x48dbe8=a64_0x46a9,_0x4b3e76=_0x3f079f();while(!![]){try{const _0x4dab81=-parseInt(_0x48dbe8(0x1c4))/0x1*(-parseInt(_0x48dbe8(0x1ce))/0x2)+parseInt(_0x48dbe8(0x1cf))/0x3*(-parseInt(_0x48dbe8(0x1c7))/0x4)+-parseInt(_0x48dbe8(0x1ca))/0x5+-parseInt(_0x48dbe8(0x1d0))/0x6+-parseInt(_0x48dbe8(0x1c5))/0x7*(parseInt(_0x48dbe8(0x1c9))/0x8)+-parseInt(_0x48dbe8(0x1cb))/0x9+-parseInt(_0x48dbe8(0x1cd))/0xa*(-parseInt(_0x48dbe8(0x1c8))/0xb);if(_0x4dab81===_0x488ecc)break;else _0x4b3e76['push'](_0x4b3e76['shift']());}catch(_0x4db3f3){_0x4b3e76['push'](_0x4b3e76['shift']());}}}(a64_0x38d2,0xc8ed0));import{buildSchemaPayload}from'../framework/schema-export.js';function a64_0x38d2(){const _0x398ccc=['7232124TqISKG','469szTUqg','21BPJnhC','Export\x20machine-readable\x20command\x20schema\x20(JSON)','112084aCKeoJ','132iploOq','1384296hfCUpm','7293365eVHtHl','10678662yQFxrf','schema','3562620OqRssR','5466oxoFnG','39XsjcDC'];a64_0x38d2=function(){return _0x398ccc;};return a64_0x38d2();}async function execute(_0xbb954b){const _0x346f8c=await buildSchemaPayload();return{'ok':!![],'data':_0x346f8c};}function a64_0x46a9(_0x33e80c,_0x48a290){_0x33e80c=_0x33e80c-0x1c4;const _0x38d29a=a64_0x38d2();let _0x46a976=_0x38d29a[_0x33e80c];return _0x46a976;}export const schemaDefinition={'service':a64_0x1948d7(0x1cc),'command':'export','description':a64_0x1948d7(0x1c6),'risk':'read','requiresAuth':![],'requiresAppCode':![],'hasFormat':!![],'flags':[],'execute':execute};
1
+ function a64_0x434a(){const _0x84468b=['5029871TPUYAz','schema','5019936wngPvT','494rYFEte','9YUbqby','733TgvdqN','export','1230678UYNybw','631205YZaphW','1576268FqGGfT','26352650bJzUst','3YERazQ'];a64_0x434a=function(){return _0x84468b;};return a64_0x434a();}function a64_0x4f7c(_0x42386d,_0x11a331){_0x42386d=_0x42386d-0x130;const _0x434af1=a64_0x434a();let _0x4f7c6c=_0x434af1[_0x42386d];return _0x4f7c6c;}const a64_0x444ba9=a64_0x4f7c;(function(_0x2bc67d,_0x2a034c){const _0x179366=a64_0x4f7c,_0x97b1bb=_0x2bc67d();while(!![]){try{const _0x4c7a8d=parseInt(_0x179366(0x133))/0x1*(-parseInt(_0x179366(0x131))/0x2)+-parseInt(_0x179366(0x139))/0x3*(parseInt(_0x179366(0x137))/0x4)+-parseInt(_0x179366(0x136))/0x5+-parseInt(_0x179366(0x135))/0x6+-parseInt(_0x179366(0x13a))/0x7+-parseInt(_0x179366(0x130))/0x8+-parseInt(_0x179366(0x132))/0x9*(-parseInt(_0x179366(0x138))/0xa);if(_0x4c7a8d===_0x2a034c)break;else _0x97b1bb['push'](_0x97b1bb['shift']());}catch(_0x5862fe){_0x97b1bb['push'](_0x97b1bb['shift']());}}}(a64_0x434a,0x5d71c));import{buildSchemaPayload}from'../framework/schema-export.js';async function execute(_0x46c745){const _0x575b29=await buildSchemaPayload();return{'ok':!![],'data':_0x575b29};}export const schemaDefinition={'service':a64_0x444ba9(0x13b),'command':a64_0x444ba9(0x134),'description':'Export\x20machine-readable\x20command\x20schema\x20(JSON)','risk':'read','requiresAuth':![],'requiresAppCode':![],'hasFormat':!![],'flags':[],'execute':execute};
@@ -1 +1 @@
1
- (function(_0x269569,_0x33dcaa){const _0x4e9c0c=a65_0x368b,_0x5092ee=_0x269569();while(!![]){try{const _0x39d912=-parseInt(_0x4e9c0c(0x123))/0x1+parseInt(_0x4e9c0c(0x12d))/0x2*(parseInt(_0x4e9c0c(0x142))/0x3)+parseInt(_0x4e9c0c(0x16e))/0x4*(-parseInt(_0x4e9c0c(0x139))/0x5)+parseInt(_0x4e9c0c(0x166))/0x6+-parseInt(_0x4e9c0c(0x15c))/0x7*(parseInt(_0x4e9c0c(0x130))/0x8)+parseInt(_0x4e9c0c(0x146))/0x9+parseInt(_0x4e9c0c(0x180))/0xa;if(_0x39d912===_0x33dcaa)break;else _0x5092ee['push'](_0x5092ee['shift']());}catch(_0x10349d){_0x5092ee['push'](_0x5092ee['shift']());}}}(a65_0x809c,0x38015));import{compileServiceTreeCommand,matchServiceTreeCommand}from'@lovrabet/cli-framework';import{getLoginUserInfo,listDatasets}from'../../core/api-client.js';import{executeData,executeSdkBff,executeSdkSql}from'../../core/sdk-client.js';import{CliErrors}from'../../errors.js';import{listLocalServices,listLocalServiceTrees}from'../../commands/service/registry.js';import{CLI_BIN_NAME}from'../../constant/cli.js';function a65_0x809c(){const _0x33402a=['operator','\x22\x20to\x20a\x20datasetCode\x20in\x20app\x20','3160251EFigoZ','\x20\x20\x20\x20datatable:\x20','Run\x20service\x20command\x20','remainingArgs','employeeId','const','ctx.','\x20<command>\x20[flags]','\x20\x20\x20\x20datasetCode:\x20','startsWith','bff','service','\x20\x20\x20\x20','read','kind','fullPath','userName','bffCode','\x20\x20\x20\x20command:\x20','boolean','The\x20manifest\x20marks\x20this\x20command\x20as\x20a\x20write.\x20It\x20may\x20change\x20business\x20data\x20or\x20service\x20state.','code','994MlBRzR','`\x20to\x20inspect\x20the\x20manifest.','\x20\x20MAP\x20TO','mapTo','args','risk','json','length','params','datatable','2295792eEMWsA','dbtableConfig','padEnd','map','join','cliName','tree','validation','92XQcPgi','high-risk-write','find','\x20\x20[','context.','description','appCode','\x20->\x20','\x20service\x20detail\x20--service\x20','data','app','Use\x20`','envName','target','This\x20will\x20run\x20Service\x20Tree\x20command\x20\x22','flags','bffId','flatMap','927560sSlers','push','command','The\x20manifest\x20marks\x20this\x20command\x20as\x20a\x20high-risk\x20write.\x20It\x20may\x20make\x20business\x20changes\x20that\x20are\x20hard\x20to\x20reverse.','sql','rawFlags','SERVICE_TREE','default','\x20requires\x20target.functionName.','env','appRef','Cannot\x20resolve\x20datatable\x20\x22','entries','382371DgMKWo','normalizedManifest','Unknown\x20appRef\x20\x22','name','\x22\x20in\x20service\x20command\x20','Use\x20lovrabet\x20dataset\x20list\x20to\x20confirm\x20the\x20physical\x20table\x20name\x20or\x20add\x20target.datasetCode\x20to\x20the\x20manifest.','source','tableName','appcode','Commands:','2eESWjR','nickName','userId','11048JYKYze','filter','type','string','scriptName','Define\x20the\x20appRef\x20under\x20appBindings\x20or\x20remove\x20target.appRef.','sqlCode','required','commands','57655aiaARs','number','cliPath','enum','datasetCode','now','slice','\x20requires\x20target.sqlCode.','Service\x20command\x20','739668WzxdBb','\x22.\x20'];a65_0x809c=function(){return _0x33402a;};return a65_0x809c();}export function resolveDynamicServiceCommand(_0x40068b,_0x553f8f){const _0x1fef42=a65_0x368b,_0x599f2a=listLocalServiceTrees();let _0x242da7;for(const _0x4d2872 of _0x599f2a){const _0x5d748a=matchServiceTreeCommand(_0x4d2872,_0x40068b);if(!_0x5d748a)continue;(!_0x242da7||_0x5d748a[_0x1fef42(0x182)]['fullPath']['length']>_0x242da7[_0x1fef42(0x182)][_0x1fef42(0x155)][_0x1fef42(0x163)])&&(_0x242da7={'tree':_0x4d2872,'command':_0x5d748a['command'],'remainingArgs':_0x5d748a[_0x1fef42(0x149)]});}if(!_0x242da7)return undefined;const _0x343cc3={..._0x553f8f};return applyAppBinding(_0x242da7[_0x1fef42(0x16c)],_0x242da7[_0x1fef42(0x182)],_0x343cc3),{'definition':buildDynamicCommandDefinition(_0x242da7['tree'],_0x242da7['command']),'args':_0x242da7[_0x1fef42(0x149)],'flags':_0x343cc3,'tree':_0x242da7['tree'],'command':_0x242da7[_0x1fef42(0x182)]};}export function generateDynamicServiceHelp(_0x528c79){const _0x57f773=a65_0x368b,_0x25baf2=listLocalServiceTrees()[_0x57f773(0x170)](_0x5431ac=>_0x5431ac[_0x57f773(0x151)][_0x57f773(0x15b)]===_0x528c79);if(!_0x25baf2)return undefined;const _0x1472ce=[CLI_BIN_NAME+'\x20'+_0x528c79+_0x57f773(0x14d),'',_0x25baf2[_0x57f773(0x151)][_0x57f773(0x126)]||_0x528c79,_0x25baf2[_0x57f773(0x151)][_0x57f773(0x173)]?'\x20\x20'+_0x25baf2['service'][_0x57f773(0x173)]:'','',_0x57f773(0x12c),..._0x25baf2[_0x57f773(0x138)][_0x57f773(0x169)](_0x4e9cf8=>{const _0x3999a9=_0x57f773,_0x1cc11f=_0x4e9cf8[_0x3999a9(0x155)][_0x3999a9(0x13f)](0x1)['join']('\x20'),_0x3dc5d2=_0x4e9cf8[_0x3999a9(0x161)]==='read'?'':'\x20['+_0x4e9cf8[_0x3999a9(0x161)]+']';return'\x20\x20'+_0x1cc11f[_0x3999a9(0x168)](0x18)+'\x20'+(_0x4e9cf8['description']||'')+_0x3dc5d2;}),'',_0x57f773(0x179)+CLI_BIN_NAME+_0x57f773(0x176)+_0x528c79+_0x57f773(0x15d)][_0x57f773(0x131)](Boolean);return _0x1472ce[_0x57f773(0x16a)]('\x0a');}export function listDynamicServiceEntries(){return listLocalServices()['map'](_0x3b078a=>{const _0x28d7e6=a65_0x368b,_0x4bb453=_0x3b078a[_0x28d7e6(0x124)];return{'service':_0x4bb453[_0x28d7e6(0x151)]['code'],'label':_0x4bb453['service'][_0x28d7e6(0x126)]||_0x4bb453[_0x28d7e6(0x151)][_0x28d7e6(0x15b)],'commands':_0x4bb453[_0x28d7e6(0x138)][_0x28d7e6(0x169)](_0x5a0cad=>({'command':dynamicCommandName(_0x5a0cad),'description':_0x5a0cad[_0x28d7e6(0x173)]||_0x28d7e6(0x148)+_0x5a0cad[_0x28d7e6(0x13b)],'tag':riskTag(_0x5a0cad[_0x28d7e6(0x161)])}))};});}export function getDynamicServiceEntry(_0xf77911){const _0x1755f6=a65_0x368b;return listDynamicServiceEntries()[_0x1755f6(0x170)](_0x368123=>_0x368123[_0x1755f6(0x151)]===_0xf77911);}export function listDynamicServiceDefinitions(_0x2e3ea7){const _0x32e0e2=a65_0x368b;return listLocalServiceTrees()[_0x32e0e2(0x131)](_0x3e1adc=>!_0x2e3ea7||_0x3e1adc[_0x32e0e2(0x151)]['code']===_0x2e3ea7)[_0x32e0e2(0x17f)](_0x300815=>_0x300815[_0x32e0e2(0x138)]['map'](_0x4639ff=>buildDynamicCommandDefinition(_0x300815,_0x4639ff)));}export function getDynamicServiceDefinitions(_0x1ea911){const _0x13a143=a65_0x368b,_0x2b135b=listDynamicServiceDefinitions(_0x1ea911);return _0x2b135b[_0x13a143(0x163)]>0x0?_0x2b135b:undefined;}export function findDynamicServiceDefinition(_0x35a23d,_0x2c73d6){const _0xf01fa4=a65_0x368b;return listDynamicServiceDefinitions(_0x35a23d)[_0xf01fa4(0x170)](_0x534f13=>_0x534f13[_0xf01fa4(0x182)]===_0x2c73d6);}export function buildDynamicCommandDefinition(_0x34c697,_0x4545cc){const _0x1bbb64=a65_0x368b;return{'service':_0x34c697[_0x1bbb64(0x151)][_0x1bbb64(0x15b)],'command':dynamicCommandName(_0x4545cc),'description':_0x4545cc[_0x1bbb64(0x173)]||'Run\x20service\x20command\x20'+_0x4545cc[_0x1bbb64(0x13b)],'risk':_0x4545cc[_0x1bbb64(0x161)],..._0x4545cc[_0x1bbb64(0x161)]===_0x1bbb64(0x153)?{}:{'confirmationDescription':buildDynamicConfirmationDescription(_0x4545cc)},'requiresAuth':!![],'requiresAppCode':!![],'args':_0x4545cc[_0x1bbb64(0x160)]['map'](_0x34cc04=>({'name':_0x34cc04['name'],'description':_0x34cc04['description']||_0x34cc04[_0x1bbb64(0x126)],'required':_0x34cc04[_0x1bbb64(0x137)]})),'flags':_0x4545cc[_0x1bbb64(0x17d)]['map'](flagToCommandFlag),'helpExtra':()=>renderDynamicCommandHelp(_0x4545cc),async 'dryRun'(_0x316204){const _0x1169a7=_0x1bbb64,_0x5ad02d=await compilePlan(_0x4545cc,_0x316204);return{'method':_0x1169a7(0x186),'url':_0x4545cc[_0x1169a7(0x13b)],'body':{'target':targetPreview(_0x5ad02d),'params':_0x5ad02d['params']},'description':'Preview\x20dynamic\x20service\x20command:\x20'+_0x4545cc[_0x1169a7(0x13b)]};},async 'execute'(_0x4ed75d){const _0x1f5354=_0x1bbb64,_0x51bc35=await compilePlan(_0x4545cc,_0x4ed75d),_0x321cba=Date[_0x1f5354(0x13e)](),_0x3a5b22=await executePlan(_0x51bc35,_0x4545cc,_0x4ed75d),_0x40e1e8=Date['now']()-_0x321cba;return{'ok':!![],'data':{'service':_0x34c697[_0x1f5354(0x151)],'command':_0x4545cc[_0x1f5354(0x13b)],'target':targetPreview(_0x51bc35),'result':_0x3a5b22,'elapsed':_0x40e1e8},'message':'Service\x20command\x20'+_0x4545cc[_0x1f5354(0x13b)]+'\x20completed\x20in\x20'+_0x40e1e8+'ms'};}};}function buildDynamicConfirmationDescription(_0x2771ec){const _0x34c7dc=a65_0x368b,_0x3a5a6c=_0x2771ec[_0x34c7dc(0x173)]||_0x2771ec[_0x34c7dc(0x13b)],_0x342276=_0x2771ec[_0x34c7dc(0x161)]===_0x34c7dc(0x16f)?_0x34c7dc(0x183):_0x34c7dc(0x15a);return _0x34c7dc(0x17c)+_0x3a5a6c+_0x34c7dc(0x143)+_0x342276;}function dynamicCommandName(_0x36cfd0){const _0x58aded=a65_0x368b;return _0x36cfd0[_0x58aded(0x155)][_0x58aded(0x13f)](0x1)[_0x58aded(0x16a)]('\x20');}function riskTag(_0x456726){const _0xaf3c4a=a65_0x368b;return _0x456726===_0xaf3c4a(0x153)?'':_0xaf3c4a(0x171)+_0x456726+']';}function flagToCommandFlag(_0x37c8dc){const _0x81deb2=a65_0x368b;return{'name':_0x37c8dc[_0x81deb2(0x16b)],'type':_0x37c8dc[_0x81deb2(0x132)]===_0x81deb2(0x162)?_0x81deb2(0x133):_0x37c8dc[_0x81deb2(0x132)],'description':_0x37c8dc[_0x81deb2(0x173)]||_0x37c8dc[_0x81deb2(0x126)],'required':_0x37c8dc[_0x81deb2(0x137)],'default':isPrimitiveFlagDefault(_0x37c8dc[_0x81deb2(0x187)])?_0x37c8dc[_0x81deb2(0x187)]:undefined,'enum':_0x37c8dc[_0x81deb2(0x13c)]};}async function compilePlan(_0x2b94a4,_0xff85c2){const _0x230165=a65_0x368b;return compileServiceTreeCommand(_0x2b94a4,{'flags':_0xff85c2[_0x230165(0x185)],'args':_0xff85c2[_0x230165(0x160)],'context':await buildServiceContext(_0x2b94a4,_0xff85c2)});}async function buildServiceContext(_0x5fef2d,_0x212aa8){const _0x2cc54f=a65_0x368b,_0xbe01b7={'appCode':_0x212aa8[_0x2cc54f(0x174)],'env':_0x212aa8['envName'],'envName':_0x212aa8[_0x2cc54f(0x17a)]};if(!usesRuntimeContext(_0x5fef2d))return _0xbe01b7;const _0x4040fe=await getLoginUserInfo(),_0x5e3052=pickFirst(_0x4040fe[_0x2cc54f(0x12f)],_0x4040fe['id']);return{..._0xbe01b7,'user':_0x4040fe,'userId':_0x5e3052,'id':_0x4040fe['id'],'username':pickFirst(_0x4040fe['username'],_0x4040fe[_0x2cc54f(0x156)],_0x4040fe['loginName']),'userName':_0x4040fe[_0x2cc54f(0x156)],'nickname':pickFirst(_0x4040fe['nickname'],_0x4040fe[_0x2cc54f(0x12e)]),'nickName':_0x4040fe[_0x2cc54f(0x12e)],'tenantCode':_0x4040fe['tenantCode'],'employeeId':_0x4040fe[_0x2cc54f(0x14a)]};}function usesRuntimeContext(_0x29dfbe){const _0x37d7a4=a65_0x368b;return _0x29dfbe[_0x37d7a4(0x15f)]['some'](_0x326ab5=>typeof _0x326ab5[_0x37d7a4(0x129)]===_0x37d7a4(0x133)&&(_0x326ab5[_0x37d7a4(0x129)][_0x37d7a4(0x14f)](_0x37d7a4(0x172))||_0x326ab5[_0x37d7a4(0x129)][_0x37d7a4(0x14f)](_0x37d7a4(0x14c))));}function pickFirst(..._0x3379e7){return _0x3379e7['find'](_0x3615fc=>_0x3615fc!==undefined&&_0x3615fc!==null);}async function executePlan(_0x3e0fcf,_0xbcd00,_0x2ba436){const _0x9a8ad2=a65_0x368b;if(_0x3e0fcf[_0x9a8ad2(0x154)]===_0x9a8ad2(0x177)){const _0x5162bf=await resolveDatasetCode(_0x3e0fcf,_0xbcd00,_0x2ba436);return executeData(_0x5162bf,_0x3e0fcf[_0x9a8ad2(0x182)],_0x3e0fcf['params']);}if(_0x3e0fcf['kind']===_0x9a8ad2(0x184)){if(!_0x3e0fcf[_0x9a8ad2(0x136)])throw CliErrors[_0x9a8ad2(0x16d)](_0x9a8ad2(0x141)+_0xbcd00['cliPath']+_0x9a8ad2(0x140));return executeSdkSql(_0x3e0fcf[_0x9a8ad2(0x136)],normalizeScalarParams(_0x3e0fcf[_0x9a8ad2(0x164)]));}if(_0x3e0fcf[_0x9a8ad2(0x154)]===_0x9a8ad2(0x150)){const _0x83bc2=_0x3e0fcf[_0x9a8ad2(0x134)]||_0x3e0fcf['bffCode']||(_0x3e0fcf[_0x9a8ad2(0x17e)]==null?'':String(_0x3e0fcf[_0x9a8ad2(0x17e)]));if(!_0x83bc2)throw CliErrors[_0x9a8ad2(0x16d)](_0x9a8ad2(0x141)+_0xbcd00[_0x9a8ad2(0x13b)]+_0x9a8ad2(0x11e));return executeSdkBff(_0x83bc2,_0x3e0fcf[_0x9a8ad2(0x164)]);}throw CliErrors['validation']('Unsupported\x20service\x20target\x20kind:\x20'+_0x3e0fcf['kind']);}async function resolveDatasetCode(_0x210698,_0x437be0,_0x56e36f){const _0x4cbf07=a65_0x368b;if(_0x210698[_0x4cbf07(0x13d)])return _0x210698[_0x4cbf07(0x13d)];if(!_0x210698[_0x4cbf07(0x165)])throw CliErrors['validation'](_0x4cbf07(0x141)+_0x437be0[_0x4cbf07(0x13b)]+'\x20requires\x20target.datasetCode\x20or\x20target.datatable.');const _0x4d5953=await listDatasets(_0x56e36f[_0x4cbf07(0x174)]),_0x531263=_0x4d5953['find'](_0x4deedc=>_0x4deedc[_0x4cbf07(0x167)]?.[_0x4cbf07(0x12a)]===_0x210698[_0x4cbf07(0x165)]);if(!_0x531263?.[_0x4cbf07(0x15b)])throw CliErrors[_0x4cbf07(0x16d)](_0x4cbf07(0x121)+_0x210698[_0x4cbf07(0x165)]+_0x4cbf07(0x145)+_0x56e36f['appCode']+'.',_0x4cbf07(0x128));return _0x531263[_0x4cbf07(0x15b)];}function applyAppBinding(_0x810571,_0x30686a,_0x2268bb){const _0x36ad68=a65_0x368b,_0x554b3c=_0x30686a['target'][_0x36ad68(0x120)];if(!_0x554b3c)return;const _0x34dc4d=_0x810571['appBindings'][_0x554b3c];if(!_0x34dc4d)throw CliErrors[_0x36ad68(0x16d)](_0x36ad68(0x125)+_0x554b3c+_0x36ad68(0x127)+_0x30686a[_0x36ad68(0x13b)]+'.',_0x36ad68(0x135));const _0xde99b6=_0x34dc4d['appcode']||_0x34dc4d[_0x36ad68(0x174)];_0xde99b6&&!hasText(_0x2268bb[_0x36ad68(0x12b)])&&(_0x2268bb[_0x36ad68(0x12b)]=_0xde99b6),_0x34dc4d[_0x36ad68(0x178)]&&!hasText(_0x2268bb['app'])&&!hasText(_0x2268bb[_0x36ad68(0x12b)])&&(_0x2268bb[_0x36ad68(0x178)]=_0x34dc4d[_0x36ad68(0x178)]),_0x34dc4d[_0x36ad68(0x11f)]&&!hasText(_0x2268bb[_0x36ad68(0x11f)])&&(_0x2268bb[_0x36ad68(0x11f)]=_0x34dc4d[_0x36ad68(0x11f)]);}function renderDynamicCommandHelp(_0x174a23){const _0x31158e=a65_0x368b,_0x43eb76=['\x20\x20SERVICE\x20TREE\x20TARGET','\x20\x20\x20\x20kind:\x20\x20\x20\x20'+_0x174a23[_0x31158e(0x17b)][_0x31158e(0x154)],_0x31158e(0x158)+_0x174a23[_0x31158e(0x17b)][_0x31158e(0x182)]];if(_0x174a23['target']['datasetCode'])_0x43eb76['push'](_0x31158e(0x14e)+_0x174a23[_0x31158e(0x17b)][_0x31158e(0x13d)]);if(_0x174a23[_0x31158e(0x17b)][_0x31158e(0x165)])_0x43eb76['push'](_0x31158e(0x147)+_0x174a23['target'][_0x31158e(0x165)]);if(_0x174a23[_0x31158e(0x17b)][_0x31158e(0x136)])_0x43eb76[_0x31158e(0x181)]('\x20\x20\x20\x20sqlCode:\x20'+_0x174a23['target'][_0x31158e(0x136)]);if(_0x174a23[_0x31158e(0x17b)][_0x31158e(0x134)])_0x43eb76['push']('\x20\x20\x20\x20functionName:\x20'+_0x174a23[_0x31158e(0x17b)]['scriptName']);if(_0x174a23[_0x31158e(0x15f)]['length']>0x0){_0x43eb76['push']('',_0x31158e(0x15e));for(const _0x1d346f of _0x174a23['mapTo']){_0x43eb76[_0x31158e(0x181)](_0x31158e(0x152)+(_0x1d346f[_0x31158e(0x129)]||_0x31158e(0x14b))+_0x31158e(0x175)+_0x1d346f['target']+(_0x1d346f[_0x31158e(0x144)]?'.'+_0x1d346f[_0x31158e(0x144)]:''));}}return _0x43eb76[_0x31158e(0x16a)]('\x0a');}function a65_0x368b(_0x3c08e5,_0x4dbfbb){_0x3c08e5=_0x3c08e5-0x11e;const _0x809c3e=a65_0x809c();let _0x368b51=_0x809c3e[_0x3c08e5];return _0x368b51;}function targetPreview(_0x514de4){const _0x40b0bd=a65_0x368b;return{'kind':_0x514de4[_0x40b0bd(0x154)],'command':_0x514de4[_0x40b0bd(0x182)],'appRef':_0x514de4[_0x40b0bd(0x120)],'datasetCode':_0x514de4[_0x40b0bd(0x13d)],'datatable':_0x514de4['datatable'],'sqlCode':_0x514de4[_0x40b0bd(0x136)],'bffCode':_0x514de4[_0x40b0bd(0x157)],'bffId':_0x514de4[_0x40b0bd(0x17e)],'functionName':_0x514de4[_0x40b0bd(0x134)]};}function normalizeScalarParams(_0x721be5){const _0x288ad7=a65_0x368b;return Object['fromEntries'](Object[_0x288ad7(0x122)](_0x721be5)[_0x288ad7(0x131)](([,_0x3964e9])=>typeof _0x3964e9===_0x288ad7(0x133)||typeof _0x3964e9==='number'));}function hasText(_0x14d6d4){const _0x2c1a55=a65_0x368b;return typeof _0x14d6d4===_0x2c1a55(0x133)&&_0x14d6d4['trim']()[_0x2c1a55(0x163)]>0x0;}function isPrimitiveFlagDefault(_0x457463){const _0x550d44=a65_0x368b;return _0x457463===undefined||typeof _0x457463==='string'||typeof _0x457463===_0x550d44(0x13a)||typeof _0x457463===_0x550d44(0x159);}
1
+ function a65_0x3b21(_0x336f5e,_0x572cdf){_0x336f5e=_0x336f5e-0x139;const _0x3b2dab=a65_0x3b2d();let _0x3b2185=_0x3b2dab[_0x336f5e];return _0x3b2185;}(function(_0x4b0028,_0x266b4d){const _0x416400=a65_0x3b21,_0x1b01e1=_0x4b0028();while(!![]){try{const _0x53f958=parseInt(_0x416400(0x195))/0x1+parseInt(_0x416400(0x194))/0x2*(-parseInt(_0x416400(0x169))/0x3)+-parseInt(_0x416400(0x140))/0x4+parseInt(_0x416400(0x14e))/0x5*(-parseInt(_0x416400(0x13d))/0x6)+-parseInt(_0x416400(0x15d))/0x7*(parseInt(_0x416400(0x13b))/0x8)+parseInt(_0x416400(0x196))/0x9*(-parseInt(_0x416400(0x19b))/0xa)+-parseInt(_0x416400(0x153))/0xb*(-parseInt(_0x416400(0x15b))/0xc);if(_0x53f958===_0x266b4d)break;else _0x1b01e1['push'](_0x1b01e1['shift']());}catch(_0x3cca0d){_0x1b01e1['push'](_0x1b01e1['shift']());}}}(a65_0x3b2d,0xcdac6));import{compileServiceTreeCommand,matchServiceTreeCommand}from'@lovrabet/cli-framework';import{getLoginUserInfo,listDatasets}from'../../core/api-client.js';import{executeData,executeSdkBff,executeSdkSql}from'../../core/sdk-client.js';import{CliErrors}from'../../errors.js';import{listLocalServices,listLocalServiceTrees}from'../../commands/service/registry.js';import{CLI_BIN_NAME}from'../../constant/cli.js';import{isDev,normalizeEnv}from'../../constant/env.js';export function resolveDynamicServiceCommand(_0x48d8cb,_0x476d0c){const _0x4a70a0=a65_0x3b21,_0x44ba3c=listLocalServiceTrees();let _0x1095d6;for(const _0x124e75 of _0x44ba3c){const _0x2bb636=matchServiceTreeCommand(_0x124e75,_0x48d8cb);if(!_0x2bb636)continue;(!_0x1095d6||_0x2bb636[_0x4a70a0(0x13f)]['fullPath'][_0x4a70a0(0x16d)]>_0x1095d6['command']['fullPath'][_0x4a70a0(0x16d)])&&(_0x1095d6={'tree':_0x124e75,'command':_0x2bb636[_0x4a70a0(0x13f)],'remainingArgs':_0x2bb636[_0x4a70a0(0x161)]});}if(!_0x1095d6)return undefined;const _0x1b1d36={..._0x476d0c};return applyAppBinding(_0x1095d6[_0x4a70a0(0x145)],_0x1095d6['command'],_0x1b1d36),{'definition':buildDynamicCommandDefinition(_0x1095d6[_0x4a70a0(0x145)],_0x1095d6[_0x4a70a0(0x13f)]),'args':_0x1095d6[_0x4a70a0(0x161)],'flags':_0x1b1d36,'tree':_0x1095d6[_0x4a70a0(0x145)],'command':_0x1095d6[_0x4a70a0(0x13f)]};}export function generateDynamicServiceHelp(_0x562c88){const _0x210247=a65_0x3b21,_0x515d2b=listLocalServiceTrees()[_0x210247(0x174)](_0x47e388=>_0x47e388[_0x210247(0x191)][_0x210247(0x16e)]===_0x562c88);if(!_0x515d2b)return undefined;const _0x479cfc=[CLI_BIN_NAME+'\x20'+_0x562c88+'\x20<command>\x20[flags]','',_0x515d2b[_0x210247(0x191)][_0x210247(0x197)]||_0x562c88,_0x515d2b['service']['description']?'\x20\x20'+_0x515d2b[_0x210247(0x191)]['description']:'','',_0x210247(0x162),..._0x515d2b[_0x210247(0x19c)]['map'](_0x43d1d1=>{const _0x3aa8b1=_0x210247,_0x494be5=_0x43d1d1[_0x3aa8b1(0x164)][_0x3aa8b1(0x198)](0x1)[_0x3aa8b1(0x160)]('\x20'),_0x434742=_0x43d1d1[_0x3aa8b1(0x172)]===_0x3aa8b1(0x14d)?'':'\x20['+_0x43d1d1[_0x3aa8b1(0x172)]+']';return'\x20\x20'+_0x494be5[_0x3aa8b1(0x14a)](0x18)+'\x20'+(_0x43d1d1['description']||'')+_0x434742;}),'',_0x210247(0x170)+CLI_BIN_NAME+_0x210247(0x1a5)+_0x562c88+_0x210247(0x159)][_0x210247(0x17f)](Boolean);return _0x479cfc['join']('\x0a');}export function listDynamicServiceEntries(){return listLocalServices()['map'](_0x85a7cb=>{const _0x17e392=a65_0x3b21,_0x5f0d30=_0x85a7cb[_0x17e392(0x15f)];return{'service':_0x5f0d30[_0x17e392(0x191)][_0x17e392(0x16e)],'label':_0x5f0d30[_0x17e392(0x191)][_0x17e392(0x197)]||_0x5f0d30[_0x17e392(0x191)][_0x17e392(0x16e)],'commands':_0x5f0d30[_0x17e392(0x19c)]['map'](_0x544402=>({'command':dynamicCommandName(_0x544402),'description':_0x544402[_0x17e392(0x13e)]||_0x17e392(0x178)+_0x544402[_0x17e392(0x15c)],'tag':riskTag(_0x544402[_0x17e392(0x172)])}))};});}export function getDynamicServiceEntry(_0x2fa9a4){const _0xd08ce9=a65_0x3b21;return listDynamicServiceEntries()['find'](_0x4d0389=>_0x4d0389[_0xd08ce9(0x191)]===_0x2fa9a4);}export function listDynamicServiceDefinitions(_0x4c5f6b){const _0x1871c6=a65_0x3b21;return listLocalServiceTrees()['filter'](_0x5ad72f=>!_0x4c5f6b||_0x5ad72f['service'][_0x1871c6(0x16e)]===_0x4c5f6b)[_0x1871c6(0x192)](_0x421411=>_0x421411[_0x1871c6(0x19c)][_0x1871c6(0x139)](_0x119e8f=>buildDynamicCommandDefinition(_0x421411,_0x119e8f)));}export function getDynamicServiceDefinitions(_0x561f9b){const _0x2f2d03=listDynamicServiceDefinitions(_0x561f9b);return _0x2f2d03['length']>0x0?_0x2f2d03:undefined;}export function findDynamicServiceDefinition(_0x320b31,_0x599c59){const _0x479baa=a65_0x3b21;return listDynamicServiceDefinitions(_0x320b31)[_0x479baa(0x174)](_0xb4a257=>_0xb4a257[_0x479baa(0x13f)]===_0x599c59);}export function buildDynamicCommandDefinition(_0xc5abad,_0x416e2a){const _0x25d61a=a65_0x3b21;return{'service':_0xc5abad[_0x25d61a(0x191)][_0x25d61a(0x16e)],'command':dynamicCommandName(_0x416e2a),'description':_0x416e2a[_0x25d61a(0x13e)]||_0x25d61a(0x178)+_0x416e2a['cliPath'],'risk':_0x416e2a['risk'],..._0x416e2a['risk']===_0x25d61a(0x14d)?{}:{'confirmationDescription':buildDynamicConfirmationDescription(_0x416e2a)},'requiresAuth':!![],'requiresAppCode':!![],'args':_0x416e2a['args']['map'](_0x111b31=>({'name':_0x111b31['name'],'description':_0x111b31['description']||_0x111b31[_0x25d61a(0x197)],'required':_0x111b31[_0x25d61a(0x190)]})),'flags':_0x416e2a[_0x25d61a(0x1a2)][_0x25d61a(0x139)](flagToCommandFlag),'helpExtra':()=>renderDynamicCommandHelp(_0x416e2a),async 'dryRun'(_0x30a8e3){const _0x146ca5=_0x25d61a,_0x49f133=await compilePlan(_0xc5abad,_0x416e2a,_0x30a8e3);return{'method':'SERVICE_TREE','url':_0x416e2a[_0x146ca5(0x15c)],'body':{'target':targetPreview(_0x49f133),'params':_0x49f133[_0x146ca5(0x144)]},'description':_0x146ca5(0x19e)+_0x416e2a[_0x146ca5(0x15c)]};},async 'execute'(_0xf0602e){const _0x391ad8=_0x25d61a,_0x30db79=await compilePlan(_0xc5abad,_0x416e2a,_0xf0602e),_0x86f62a=Date[_0x391ad8(0x158)](),_0x3e1496=await executePlan(_0x30db79,_0x416e2a,_0xf0602e),_0xac1569=Date[_0x391ad8(0x158)]()-_0x86f62a;return{'ok':!![],'data':{'service':_0xc5abad[_0x391ad8(0x191)],'command':_0x416e2a[_0x391ad8(0x15c)],'target':targetPreview(_0x30db79),'result':_0x3e1496,'elapsed':_0xac1569},'message':_0x391ad8(0x152)+_0x416e2a[_0x391ad8(0x15c)]+'\x20completed\x20in\x20'+_0xac1569+'ms'};}};}function buildDynamicConfirmationDescription(_0x5cff74){const _0x3c7989=a65_0x3b21,_0x2d0b9b=_0x5cff74[_0x3c7989(0x13e)]||_0x5cff74['cliPath'],_0x1ae109=_0x5cff74[_0x3c7989(0x172)]===_0x3c7989(0x186)?_0x3c7989(0x19a):'The\x20manifest\x20marks\x20this\x20command\x20as\x20a\x20write.\x20It\x20may\x20change\x20business\x20data\x20or\x20service\x20state.';return _0x3c7989(0x157)+_0x2d0b9b+'\x22.\x20'+_0x1ae109;}function dynamicCommandName(_0x5b2d39){const _0xd88454=a65_0x3b21;return _0x5b2d39[_0xd88454(0x164)][_0xd88454(0x198)](0x1)[_0xd88454(0x160)]('\x20');}function riskTag(_0x4b5439){const _0x41df74=a65_0x3b21;return _0x4b5439===_0x41df74(0x14d)?'':_0x41df74(0x165)+_0x4b5439+']';}function flagToCommandFlag(_0xd0d56a){const _0x38f11b=a65_0x3b21;return{'name':_0xd0d56a[_0x38f11b(0x18b)],'type':_0xd0d56a[_0x38f11b(0x143)]===_0x38f11b(0x182)?_0x38f11b(0x17a):_0xd0d56a[_0x38f11b(0x143)],'description':_0xd0d56a[_0x38f11b(0x13e)]||_0xd0d56a[_0x38f11b(0x197)],'required':_0xd0d56a[_0x38f11b(0x190)],'default':isPrimitiveFlagDefault(_0xd0d56a[_0x38f11b(0x19f)])?_0xd0d56a[_0x38f11b(0x19f)]:undefined,'enum':_0xd0d56a[_0x38f11b(0x18a)]};}async function compilePlan(_0xb047d9,_0x59bb13,_0x42094e){const _0x1e2273=a65_0x3b21,_0x2d5a55=_0x59bb13['target'][_0x1e2273(0x177)]?_0xb047d9[_0x1e2273(0x15e)][_0x59bb13[_0x1e2273(0x1a6)]['appRef']]:undefined;if(_0x2d5a55?.[_0x1e2273(0x168)]){const _0x5d3a38=isDev(_0x2d5a55[_0x1e2273(0x168)])?'development':normalizeEnv(_0x2d5a55['env']);if(_0x5d3a38!==_0x42094e[_0x1e2273(0x16a)])throw CliErrors[_0x1e2273(0x17c)](_0x1e2273(0x152)+_0x59bb13[_0x1e2273(0x15c)]+_0x1e2273(0x18c)+_0x5d3a38+_0x1e2273(0x156)+_0x42094e[_0x1e2273(0x16a)]+'\x22.',_0x1e2273(0x151));}return compileServiceTreeCommand(_0x59bb13,{'flags':_0x42094e[_0x1e2273(0x181)],'args':_0x42094e[_0x1e2273(0x171)],'context':await buildServiceContext(_0x59bb13,_0x42094e)});}async function buildServiceContext(_0x2985f2,_0x727e47){const _0x95db44=a65_0x3b21,_0x38f43b={'appCode':_0x727e47[_0x95db44(0x17b)],'env':_0x727e47[_0x95db44(0x16a)],'envName':_0x727e47[_0x95db44(0x16a)]};if(!usesRuntimeContext(_0x2985f2))return _0x38f43b;const _0x3d763d=await getLoginUserInfo(),_0x506cfb=pickFirst(_0x3d763d[_0x95db44(0x14f)],_0x3d763d['id']);return{..._0x38f43b,'user':_0x3d763d,'userId':_0x506cfb,'id':_0x3d763d['id'],'username':pickFirst(_0x3d763d['username'],_0x3d763d[_0x95db44(0x18e)],_0x3d763d[_0x95db44(0x150)]),'userName':_0x3d763d[_0x95db44(0x18e)],'nickname':pickFirst(_0x3d763d[_0x95db44(0x180)],_0x3d763d['nickName']),'nickName':_0x3d763d['nickName'],'tenantCode':_0x3d763d[_0x95db44(0x15a)],'employeeId':_0x3d763d[_0x95db44(0x147)]};}function usesRuntimeContext(_0x2149a9){const _0x53f477=a65_0x3b21;return _0x2149a9['mapTo'][_0x53f477(0x187)](_0x11b836=>typeof _0x11b836[_0x53f477(0x184)]===_0x53f477(0x17a)&&(_0x11b836[_0x53f477(0x184)]['startsWith'](_0x53f477(0x17e))||_0x11b836[_0x53f477(0x184)][_0x53f477(0x176)](_0x53f477(0x199))));}function pickFirst(..._0x2c9d4d){const _0x468f17=a65_0x3b21;return _0x2c9d4d[_0x468f17(0x174)](_0x1d23ce=>_0x1d23ce!==undefined&&_0x1d23ce!==null);}async function executePlan(_0x2a7702,_0x17af43,_0x57db99){const _0x2825c4=a65_0x3b21;if(_0x2a7702['kind']===_0x2825c4(0x17d)){const _0xa3d09=await resolveDatasetCode(_0x2a7702,_0x17af43,_0x57db99);return executeData(_0xa3d09,_0x2a7702[_0x2825c4(0x13f)],_0x2a7702['params']);}if(_0x2a7702[_0x2825c4(0x141)]===_0x2825c4(0x163)){if(!_0x2a7702[_0x2825c4(0x179)])throw CliErrors[_0x2825c4(0x17c)](_0x2825c4(0x152)+_0x17af43[_0x2825c4(0x15c)]+_0x2825c4(0x188));return executeSdkSql(_0x2a7702[_0x2825c4(0x179)],normalizeScalarParams(_0x2a7702['params']));}if(_0x2a7702['kind']===_0x2825c4(0x1a0)){const _0x49c631=_0x2a7702[_0x2825c4(0x175)]||_0x2a7702[_0x2825c4(0x1a1)]||(_0x2a7702[_0x2825c4(0x1a7)]==null?'':String(_0x2a7702[_0x2825c4(0x1a7)]));if(!_0x49c631)throw CliErrors[_0x2825c4(0x17c)](_0x2825c4(0x152)+_0x17af43['cliPath']+_0x2825c4(0x16c));return executeSdkBff(_0x49c631,_0x2a7702[_0x2825c4(0x144)]);}throw CliErrors[_0x2825c4(0x17c)](_0x2825c4(0x167)+_0x2a7702[_0x2825c4(0x141)]);}async function resolveDatasetCode(_0x2545a4,_0x54a624,_0x3ff5e2){const _0x42dc33=a65_0x3b21;if(_0x2545a4[_0x42dc33(0x1a3)])return _0x2545a4[_0x42dc33(0x1a3)];if(!_0x2545a4[_0x42dc33(0x146)])throw CliErrors[_0x42dc33(0x17c)](_0x42dc33(0x152)+_0x54a624[_0x42dc33(0x15c)]+'\x20requires\x20target.datasetCode\x20or\x20target.datatable.');const _0x51adda=await listDatasets(_0x3ff5e2[_0x42dc33(0x17b)]),_0x44a1e2=_0x51adda[_0x42dc33(0x174)](_0x26d2eb=>_0x26d2eb['dbtableConfig']?.['tableName']===_0x2545a4['datatable']);if(!_0x44a1e2?.[_0x42dc33(0x16e)])throw CliErrors[_0x42dc33(0x17c)](_0x42dc33(0x142)+_0x2545a4[_0x42dc33(0x146)]+_0x42dc33(0x149)+_0x3ff5e2['appCode']+'.',_0x42dc33(0x14b));return _0x44a1e2[_0x42dc33(0x16e)];}function applyAppBinding(_0x56c1d1,_0x4ca8b8,_0x3bab07){const _0x1edfbd=a65_0x3b21,_0x494514=_0x4ca8b8[_0x1edfbd(0x1a6)]['appRef'];if(!_0x494514)return;const _0x1b4165=_0x56c1d1[_0x1edfbd(0x15e)][_0x494514];if(!_0x1b4165)throw CliErrors['validation'](_0x1edfbd(0x13c)+_0x494514+_0x1edfbd(0x18f)+_0x4ca8b8[_0x1edfbd(0x15c)]+'.','Define\x20the\x20appRef\x20under\x20appBindings\x20or\x20remove\x20target.appRef.');const _0x3f73ac=_0x1b4165[_0x1edfbd(0x173)]||_0x1b4165[_0x1edfbd(0x17b)];_0x3f73ac&&!hasText(_0x3bab07[_0x1edfbd(0x173)])&&!hasText(_0x3bab07[_0x1edfbd(0x155)])&&(_0x3bab07[_0x1edfbd(0x173)]=_0x3f73ac),_0x1b4165[_0x1edfbd(0x155)]&&!hasText(_0x3bab07['app'])&&!hasText(_0x3bab07[_0x1edfbd(0x173)])&&(_0x3bab07[_0x1edfbd(0x155)]=_0x1b4165[_0x1edfbd(0x155)]);}function renderDynamicCommandHelp(_0x2c8065){const _0x4d9e8c=a65_0x3b21,_0x330acc=['\x20\x20SERVICE\x20TREE\x20TARGET','\x20\x20\x20\x20kind:\x20\x20\x20\x20'+_0x2c8065['target'][_0x4d9e8c(0x141)],_0x4d9e8c(0x189)+_0x2c8065['target'][_0x4d9e8c(0x13f)]];if(_0x2c8065[_0x4d9e8c(0x1a6)][_0x4d9e8c(0x1a3)])_0x330acc[_0x4d9e8c(0x18d)](_0x4d9e8c(0x193)+_0x2c8065[_0x4d9e8c(0x1a6)][_0x4d9e8c(0x1a3)]);if(_0x2c8065[_0x4d9e8c(0x1a6)][_0x4d9e8c(0x146)])_0x330acc[_0x4d9e8c(0x18d)]('\x20\x20\x20\x20datatable:\x20'+_0x2c8065[_0x4d9e8c(0x1a6)][_0x4d9e8c(0x146)]);if(_0x2c8065[_0x4d9e8c(0x1a6)][_0x4d9e8c(0x179)])_0x330acc[_0x4d9e8c(0x18d)](_0x4d9e8c(0x154)+_0x2c8065['target'][_0x4d9e8c(0x179)]);if(_0x2c8065[_0x4d9e8c(0x1a6)][_0x4d9e8c(0x175)])_0x330acc[_0x4d9e8c(0x18d)](_0x4d9e8c(0x185)+_0x2c8065['target']['scriptName']);if(_0x2c8065[_0x4d9e8c(0x14c)][_0x4d9e8c(0x16d)]>0x0){_0x330acc[_0x4d9e8c(0x18d)]('',_0x4d9e8c(0x16b));for(const _0x3dd05a of _0x2c8065[_0x4d9e8c(0x14c)]){_0x330acc[_0x4d9e8c(0x18d)]('\x20\x20\x20\x20'+(_0x3dd05a[_0x4d9e8c(0x184)]||_0x4d9e8c(0x13a))+_0x4d9e8c(0x183)+_0x3dd05a[_0x4d9e8c(0x1a6)]+(_0x3dd05a[_0x4d9e8c(0x1a4)]?'.'+_0x3dd05a[_0x4d9e8c(0x1a4)]:''));}}return _0x330acc['join']('\x0a');}function targetPreview(_0x207571){const _0x1a765e=a65_0x3b21;return{'kind':_0x207571[_0x1a765e(0x141)],'command':_0x207571[_0x1a765e(0x13f)],'appRef':_0x207571[_0x1a765e(0x177)],'datasetCode':_0x207571[_0x1a765e(0x1a3)],'datatable':_0x207571[_0x1a765e(0x146)],'sqlCode':_0x207571[_0x1a765e(0x179)],'bffCode':_0x207571[_0x1a765e(0x1a1)],'bffId':_0x207571[_0x1a765e(0x1a7)],'functionName':_0x207571[_0x1a765e(0x175)]};}function normalizeScalarParams(_0x3996a6){const _0x5488b2=a65_0x3b21;return Object['fromEntries'](Object[_0x5488b2(0x19d)](_0x3996a6)[_0x5488b2(0x17f)](([,_0x4633f8])=>typeof _0x4633f8==='string'||typeof _0x4633f8==='number'));}function hasText(_0x5a25b4){const _0x436873=a65_0x3b21;return typeof _0x5a25b4===_0x436873(0x17a)&&_0x5a25b4[_0x436873(0x166)]()[_0x436873(0x16d)]>0x0;}function a65_0x3b2d(){const _0x474874=['\x20requires\x20target.sqlCode.','\x20\x20\x20\x20command:\x20','enum','cliName','\x20requires\x20environment\x20\x22','push','userName','\x22\x20in\x20service\x20command\x20','required','service','flatMap','\x20\x20\x20\x20datasetCode:\x20','2plzzGn','904264cBqPKy','81ygHUSr','name','slice','ctx.','The\x20manifest\x20marks\x20this\x20command\x20as\x20a\x20high-risk\x20write.\x20It\x20may\x20make\x20business\x20changes\x20that\x20are\x20hard\x20to\x20reverse.','1241230AzSUmm','commands','entries','Preview\x20dynamic\x20service\x20command:\x20','default','bff','bffCode','flags','datasetCode','operator','\x20service\x20detail\x20--service\x20','target','bffId','map','const','8XuYrZf','Unknown\x20appRef\x20\x22','8922myLMyF','description','command','6528540cLrHeq','kind','Cannot\x20resolve\x20datatable\x20\x22','type','params','tree','datatable','employeeId','boolean','\x22\x20to\x20a\x20datasetCode\x20in\x20app\x20','padEnd','Use\x20lovrabet\x20dataset\x20list\x20to\x20confirm\x20the\x20physical\x20table\x20name\x20or\x20add\x20target.datasetCode\x20to\x20the\x20manifest.','mapTo','read','4245mBGhkm','userId','loginName','Check\x20the\x20service\x20binding\x20and\x20current\x20connection.\x20Do\x20not\x20switch\x20environments\x20or\x20credentials\x20automatically.','Service\x20command\x20','165AUdXyh','\x20\x20\x20\x20sqlCode:\x20','app','\x22,\x20but\x20the\x20current\x20environment\x20is\x20\x22','This\x20will\x20run\x20Service\x20Tree\x20command\x20\x22','now','`\x20to\x20inspect\x20the\x20manifest.','tenantCode','5289588BWqXFP','cliPath','7576331IXMfgh','appBindings','normalizedManifest','join','remainingArgs','Commands:','sql','fullPath','\x20\x20[','trim','Unsupported\x20service\x20target\x20kind:\x20','env','4739319NENURG','envName','\x20\x20MAP\x20TO','\x20requires\x20target.functionName.','length','code','number','Use\x20`','args','risk','appcode','find','scriptName','startsWith','appRef','Run\x20service\x20command\x20','sqlCode','string','appCode','validation','data','context.','filter','nickname','rawFlags','json','\x20->\x20','source','\x20\x20\x20\x20functionName:\x20','high-risk-write','some'];a65_0x3b2d=function(){return _0x474874;};return a65_0x3b2d();}function isPrimitiveFlagDefault(_0x153774){const _0x36ec18=a65_0x3b21;return _0x153774===undefined||typeof _0x153774==='string'||typeof _0x153774===_0x36ec18(0x16f)||typeof _0x153774===_0x36ec18(0x148);}
@@ -1 +1 @@
1
- (function(_0x43e4b6,_0x378c91){const _0xad3e41=a66_0x56a3,_0x41eb5d=_0x43e4b6();while(!![]){try{const _0x237f51=parseInt(_0xad3e41(0x6a))/0x1+-parseInt(_0xad3e41(0x8e))/0x2*(-parseInt(_0xad3e41(0x8b))/0x3)+-parseInt(_0xad3e41(0x73))/0x4*(-parseInt(_0xad3e41(0x7c))/0x5)+-parseInt(_0xad3e41(0x8a))/0x6+-parseInt(_0xad3e41(0x7e))/0x7*(-parseInt(_0xad3e41(0x82))/0x8)+-parseInt(_0xad3e41(0x71))/0x9*(parseInt(_0xad3e41(0x6c))/0xa)+parseInt(_0xad3e41(0x91))/0xb*(parseInt(_0xad3e41(0x81))/0xc);if(_0x237f51===_0x378c91)break;else _0x41eb5d['push'](_0x41eb5d['shift']());}catch(_0x195a40){_0x41eb5d['push'](_0x41eb5d['shift']());}}}(a66_0x1e53,0x9a769));export function adaptServiceTreeManifestForLegacyFramework(_0x45a981){const _0xfc663a=a66_0x56a3,_0xe1399f=cloneJsonValue(_0x45a981),_0x5e5255=[];if(!isObjectRecord(_0xe1399f))return{'manifest':_0xe1399f,'errors':_0x5e5255};return Array['isArray'](_0xe1399f[_0xfc663a(0x7f)])&&_0xe1399f[_0xfc663a(0x7f)][_0xfc663a(0x78)]((_0xc36091,_0x5ca6e4)=>{const _0x19c002=_0xfc663a;if(!isObjectRecord(_0xc36091))return;adaptBffTarget(_0xc36091['target'],_0x19c002(0x92)+_0x5ca6e4+_0x19c002(0x83),_0x5e5255);}),adaptResources(_0xe1399f[_0xfc663a(0x84)],'$.resources',_0x5e5255),{'manifest':_0xe1399f,'errors':_0x5e5255};}export function toPublicServiceTreeTarget(_0x5b8aed){const _0x59f6fc=a66_0x56a3,{scriptName:_0x106208,..._0x11842b}=_0x5b8aed;return typeof _0x106208==='string'&&_0x106208[_0x59f6fc(0x89)]()&&(_0x11842b['functionName']=_0x106208),_0x11842b;}export function toPublicNormalizedServiceTree(_0x51db12){const _0x27bb0f=a66_0x56a3;return{..._0x51db12,'commands':_0x51db12[_0x27bb0f(0x7f)][_0x27bb0f(0x77)](_0x57b766=>({..._0x57b766,'target':toPublicServiceTreeTarget(_0x57b766[_0x27bb0f(0x85)])}))};}function adaptResources(_0x3152e1,_0x4a5f9b,_0x3ddf29){const _0x313e78=a66_0x56a3;if(!isObjectRecord(_0x3152e1))return;for(const [_0x3511e9,_0x58edca]of Object[_0x313e78(0x7a)](_0x3152e1)){if(!isObjectRecord(_0x58edca))continue;const _0x5d6d6c=_0x4a5f9b+'.'+_0x3511e9;if(isObjectRecord(_0x58edca['actions']))for(const [_0x360f4b,_0x4ab414]of Object[_0x313e78(0x7a)](_0x58edca[_0x313e78(0x79)])){if(!isObjectRecord(_0x4ab414))continue;const _0xd7f512=_0x5d6d6c+_0x313e78(0x7b)+_0x360f4b,_0x3b7224=isObjectRecord(_0x4ab414[_0x313e78(0x85)])&&_0x4ab414[_0x313e78(0x85)][_0x313e78(0x76)]===_0x313e78(0x8c);adaptBffTarget(_0x4ab414['target'],_0xd7f512+_0x313e78(0x7d),_0x3ddf29),(_0x3b7224||isBffAction(_0x4ab414))&&adaptFunctionNameField(_0x4ab414,_0xd7f512,_0x3ddf29);}adaptResources(_0x58edca[_0x313e78(0x84)],_0x5d6d6c+'.resources',_0x3ddf29);}}function adaptBffTarget(_0xd1400b,_0x3a3fdc,_0x3d72ef){if(!isObjectRecord(_0xd1400b)||_0xd1400b['kind']!=='bff')return;adaptFunctionNameField(_0xd1400b,_0x3a3fdc,_0x3d72ef);}function adaptFunctionNameField(_0x1111c7,_0x548c37,_0x239e30){const _0x4e27d8=a66_0x56a3;Object[_0x4e27d8(0x6b)]['hasOwnProperty'][_0x4e27d8(0x88)](_0x1111c7,_0x4e27d8(0x8d))&&_0x239e30['push']({'level':'error','path':_0x548c37+_0x4e27d8(0x74),'message':_0x4e27d8(0x8f)});if(Object[_0x4e27d8(0x6b)][_0x4e27d8(0x70)]['call'](_0x1111c7,_0x4e27d8(0x6f))){if(typeof _0x1111c7['functionName']!==_0x4e27d8(0x6e)||!_0x1111c7[_0x4e27d8(0x6f)][_0x4e27d8(0x89)]()){_0x239e30[_0x4e27d8(0x87)]({'level':_0x4e27d8(0x93),'path':_0x548c37+'.functionName','message':_0x4e27d8(0x90)}),delete _0x1111c7['functionName'];return;}_0x1111c7[_0x4e27d8(0x8d)]=_0x1111c7[_0x4e27d8(0x6f)],delete _0x1111c7['functionName'];}}function a66_0x1e53(){const _0x5e676b=['hasOwnProperty','15399VGSIVI','bff.exec','100DbVKRK','.scriptName','action','kind','map','forEach','actions','entries','.actions.','12235vpOpjr','.target','48832lNzVZV','commands','object','200544UYVFkL','584hOoUCR','].target','resources','target','fromEntries','push','call','trim','526542skUdyQ','3mEsyUg','bff','scriptName','671516IjjcCL','Use\x20functionName;\x20scriptName\x20is\x20not\x20part\x20of\x20the\x20runtime\x20Service\x20Tree\x20contract.','functionName\x20must\x20be\x20a\x20non-empty\x20string.','77jewOLP','$.commands[','error','116468NehMPH','prototype','2450ljHpxY','isArray','string','functionName'];a66_0x1e53=function(){return _0x5e676b;};return a66_0x1e53();}function a66_0x56a3(_0x259057,_0x311ce4){_0x259057=_0x259057-0x6a;const _0x1e538c=a66_0x1e53();let _0x56a39d=_0x1e538c[_0x259057];return _0x56a39d;}function isBffAction(_0x3a8b7d){const _0x232184=a66_0x56a3;return _0x3a8b7d[_0x232184(0x76)]==='bff'||_0x3a8b7d[_0x232184(0x75)]===_0x232184(0x72)||_0x3a8b7d[_0x232184(0x85)]===_0x232184(0x72);}function cloneJsonValue(_0x2069f9){const _0xc2911e=a66_0x56a3;if(Array[_0xc2911e(0x6d)](_0x2069f9))return _0x2069f9[_0xc2911e(0x77)](_0x236f05=>cloneJsonValue(_0x236f05));if(isObjectRecord(_0x2069f9))return Object[_0xc2911e(0x86)](Object[_0xc2911e(0x7a)](_0x2069f9)[_0xc2911e(0x77)](([_0x76e378,_0x3f9555])=>[_0x76e378,cloneJsonValue(_0x3f9555)]));return _0x2069f9;}function isObjectRecord(_0x544125){const _0x399940=a66_0x56a3;return Boolean(_0x544125)&&typeof _0x544125===_0x399940(0x80)&&!Array['isArray'](_0x544125);}
1
+ (function(_0x4413ba,_0x56c62a){const _0x482c51=a66_0xc51e,_0x10cac1=_0x4413ba();while(!![]){try{const _0x1bbedf=-parseInt(_0x482c51(0xbf))/0x1+parseInt(_0x482c51(0xb0))/0x2+parseInt(_0x482c51(0xc3))/0x3*(-parseInt(_0x482c51(0xd3))/0x4)+-parseInt(_0x482c51(0xd4))/0x5+-parseInt(_0x482c51(0xd2))/0x6*(parseInt(_0x482c51(0xcc))/0x7)+parseInt(_0x482c51(0xc6))/0x8*(-parseInt(_0x482c51(0xb9))/0x9)+-parseInt(_0x482c51(0xce))/0xa*(-parseInt(_0x482c51(0xd1))/0xb);if(_0x1bbedf===_0x56c62a)break;else _0x10cac1['push'](_0x10cac1['shift']());}catch(_0x45dc4c){_0x10cac1['push'](_0x10cac1['shift']());}}}(a66_0x1f5e,0xda5f7));export function adaptServiceTreeManifestForLegacyFramework(_0x53f2ca){const _0x3eb555=a66_0xc51e,_0x4f9d94=cloneJsonValue(_0x53f2ca),_0xf517d4=[];if(!isObjectRecord(_0x4f9d94))return{'manifest':_0x4f9d94,'errors':_0xf517d4};return Array[_0x3eb555(0xb5)](_0x4f9d94[_0x3eb555(0xd7)])&&_0x4f9d94[_0x3eb555(0xd7)][_0x3eb555(0xb4)]((_0x516a42,_0x267a8d)=>{const _0x473558=_0x3eb555;if(!isObjectRecord(_0x516a42))return;adaptBffTarget(_0x516a42['target'],'$.commands['+_0x267a8d+_0x473558(0xc2),_0xf517d4);}),adaptResources(_0x4f9d94[_0x3eb555(0xbe)],_0x3eb555(0xb2),_0xf517d4),{'manifest':_0x4f9d94,'errors':_0xf517d4};}export function toPublicServiceTreeTarget(_0x575e38){const _0xa2f8c9=a66_0xc51e,{scriptName:_0xc45c38,..._0x58c63f}=_0x575e38;return typeof _0xc45c38===_0xa2f8c9(0xcd)&&_0xc45c38['trim']()&&(_0x58c63f[_0xa2f8c9(0xc9)]=_0xc45c38),_0x58c63f;}export function toPublicNormalizedServiceTree(_0x1e3506){const _0x44e6c1=a66_0xc51e;return{..._0x1e3506,'commands':_0x1e3506['commands'][_0x44e6c1(0xd0)](_0x1b58c2=>({..._0x1b58c2,'target':toPublicServiceTreeTarget(_0x1b58c2[_0x44e6c1(0xc4)])}))};}function adaptResources(_0x54113e,_0x22d93c,_0x35a9b2){const _0x4e4f43=a66_0xc51e;if(!isObjectRecord(_0x54113e))return;for(const [_0x47c53f,_0xff72d7]of Object[_0x4e4f43(0xb3)](_0x54113e)){if(!isObjectRecord(_0xff72d7))continue;const _0x330d13=_0x22d93c+'.'+_0x47c53f;if(isObjectRecord(_0xff72d7[_0x4e4f43(0xba)]))for(const [_0x10544a,_0x3f4779]of Object['entries'](_0xff72d7['actions'])){if(!isObjectRecord(_0x3f4779))continue;const _0x8c88d3=_0x330d13+_0x4e4f43(0xc5)+_0x10544a,_0x107602=isObjectRecord(_0x3f4779[_0x4e4f43(0xc4)])&&_0x3f4779[_0x4e4f43(0xc4)][_0x4e4f43(0xb7)]===_0x4e4f43(0xc7);adaptBffTarget(_0x3f4779[_0x4e4f43(0xc4)],_0x8c88d3+_0x4e4f43(0xc1),_0x35a9b2),(_0x107602||isBffAction(_0x3f4779))&&adaptFunctionNameField(_0x3f4779,_0x8c88d3,_0x35a9b2);}adaptResources(_0xff72d7[_0x4e4f43(0xbe)],_0x330d13+_0x4e4f43(0xbd),_0x35a9b2);}}function adaptBffTarget(_0x1f03fc,_0x380180,_0x4ee581){const _0x182644=a66_0xc51e;if(!isObjectRecord(_0x1f03fc)||_0x1f03fc[_0x182644(0xb7)]!==_0x182644(0xc7))return;adaptFunctionNameField(_0x1f03fc,_0x380180,_0x4ee581);}function adaptFunctionNameField(_0x4404a9,_0x3f1e10,_0x685960){const _0x294336=a66_0xc51e;Object[_0x294336(0xd5)][_0x294336(0xcf)][_0x294336(0xcb)](_0x4404a9,_0x294336(0xc0))&&_0x685960[_0x294336(0xbb)]({'level':_0x294336(0xca),'path':_0x3f1e10+_0x294336(0xc8),'message':_0x294336(0xb8)});if(Object[_0x294336(0xd5)][_0x294336(0xcf)]['call'](_0x4404a9,_0x294336(0xc9))){if(typeof _0x4404a9[_0x294336(0xc9)]!==_0x294336(0xcd)||!_0x4404a9[_0x294336(0xc9)]['trim']()){_0x685960['push']({'level':_0x294336(0xca),'path':_0x3f1e10+_0x294336(0xbc),'message':'functionName\x20must\x20be\x20a\x20non-empty\x20string.'}),delete _0x4404a9['functionName'];return;}_0x4404a9[_0x294336(0xc0)]=_0x4404a9[_0x294336(0xc9)],delete _0x4404a9['functionName'];}}function a66_0x1f5e(){const _0xbda7d9=['commands','fromEntries','1311900FwWkIz','object','$.resources','entries','forEach','isArray','action','kind','Use\x20functionName;\x20scriptName\x20is\x20not\x20part\x20of\x20the\x20runtime\x20Service\x20Tree\x20contract.','27bnhwBX','actions','push','.functionName','.resources','resources','4123cqvQZf','scriptName','.target','].target','5297016prnazX','target','.actions.','1205584WpDgoz','bff','.scriptName','functionName','error','call','7FfUCto','string','86990EYuXkZ','hasOwnProperty','map','5753VokxQt','2888034XjsBBR','4soELWU','8039220XElkhi','prototype','bff.exec'];a66_0x1f5e=function(){return _0xbda7d9;};return a66_0x1f5e();}function isBffAction(_0x1f4cfc){const _0x3c9be9=a66_0xc51e;return _0x1f4cfc['kind']==='bff'||_0x1f4cfc[_0x3c9be9(0xb6)]===_0x3c9be9(0xd6)||_0x1f4cfc['target']===_0x3c9be9(0xd6);}function cloneJsonValue(_0x2f7c1b){const _0x516225=a66_0xc51e;if(Array[_0x516225(0xb5)](_0x2f7c1b))return _0x2f7c1b[_0x516225(0xd0)](_0x44fae9=>cloneJsonValue(_0x44fae9));if(isObjectRecord(_0x2f7c1b))return Object[_0x516225(0xd8)](Object[_0x516225(0xb3)](_0x2f7c1b)[_0x516225(0xd0)](([_0x4e3a8f,_0x2f3bfa])=>[_0x4e3a8f,cloneJsonValue(_0x2f3bfa)]));return _0x2f7c1b;}function a66_0xc51e(_0x109884,_0x5d327f){_0x109884=_0x109884-0xb0;const _0x1f5e34=a66_0x1f5e();let _0xc51e3c=_0x1f5e34[_0x109884];return _0xc51e3c;}function isObjectRecord(_0x50fcd4){const _0x154597=a66_0xc51e;return Boolean(_0x50fcd4)&&typeof _0x50fcd4===_0x154597(0xb1)&&!Array[_0x154597(0xb5)](_0x50fcd4);}
@@ -1 +1 @@
1
- function a67_0x6055(){const _0x197926=['Import\x20a\x20Service\x20Tree\x20manifest\x20into\x20the\x20local\x20runtime\x20registry','Preview\x20Service\x20Tree\x20import\x20into\x20~/.lovrabet/service.json','registryPath','name','normalizedManifest','\x20service\x20','read','service','target','Local\x20service\x20code,\x20for\x20example\x20crm','warnings','Service\x20manifest\x20validation\x20passed.','128966jEBCjX','kind','\x20service(s).','export','205YLnTKS','Imported\x20','serviceCode','report','872048nTGcGE','entries','\x20service(s),\x20updated\x20','Show\x20a\x20locally\x20imported\x20Service\x20Tree\x20manifest','1336330TCzxAW','1636482rbYAbg','import','imported','validate','Removed\x20service\x20','hash','45152LWvSgW','str','version','registryIndex','registryServiceCode','updated','entry','string','filePath','3027791jCLQlG','8VwNMso','cliName','Imported','registry','errors','Service\x20Tree\x20manifest\x20file\x20path','replaced','list','map','commands','importedAt','lower\x20kebab-case\x20service\x20code','risk','7SLKiHc','List\x20locally\x20imported\x20Service\x20Tree\x20manifests','Remove\x20a\x20Service\x20Tree\x20manifest\x20from\x20the\x20local\x20runtime\x20registry','1006221skGuuu','Export\x20the\x20local\x20Service\x20Tree\x20manifest\x20to\x20a\x20JSON\x20file','manifests','source','serviceCount','48HpEyps','22iIdyJu','Service\x20registry\x20validation\x20passed.','flags','Preview\x20Service\x20Tree\x20export\x20from\x20~/.lovrabet/service.json','36dIHzrk','WRITE','Preview\x20Service\x20Tree\x20removal\x20from\x20~/.lovrabet/service.json','write','file','cliPath','manifest','length','Writes\x20the\x20local\x20Service\x20Tree\x20manifest\x20for\x20the\x20given\x20service\x20to\x20a\x20JSON\x20file.\x20An\x20existing\x20file\x20at\x20the\x20target\x20may\x20be\x20overwritten.\x20The\x20confirmation\x20UI\x20does\x20not\x20show\x20local\x20file\x20paths.'];a67_0x6055=function(){return _0x197926;};return a67_0x6055();}const a67_0x5161c3=a67_0x21d4;(function(_0x363a78,_0x54326c){const _0x2994b4=a67_0x21d4,_0x2ef4e0=_0x363a78();while(!![]){try{const _0x4893bb=-parseInt(_0x2994b4(0x1a3))/0x1*(parseInt(_0x2994b4(0x186))/0x2)+parseInt(_0x2994b4(0x167))/0x3+-parseInt(_0x2994b4(0x199))/0x4*(parseInt(_0x2994b4(0x18a))/0x5)+parseInt(_0x2994b4(0x193))/0x6*(parseInt(_0x2994b4(0x164))/0x7)+parseInt(_0x2994b4(0x18e))/0x8*(-parseInt(_0x2994b4(0x171))/0x9)+-parseInt(_0x2994b4(0x192))/0xa*(-parseInt(_0x2994b4(0x16d))/0xb)+-parseInt(_0x2994b4(0x16c))/0xc*(-parseInt(_0x2994b4(0x1a2))/0xd);if(_0x4893bb===_0x54326c)break;else _0x2ef4e0['push'](_0x2ef4e0['shift']());}catch(_0x5c562f){_0x2ef4e0['push'](_0x2ef4e0['shift']());}}}(a67_0x6055,0x5fca0));import{exportServiceManifest,formatValidationFailure,getLocalServiceEntry,getServiceRegistryPath,importServiceManifest,listLocalServices,loadServiceManifestFromFile,removeServiceManifest}from'../../commands/service/registry.js';import{toPublicNormalizedServiceTree,toPublicServiceTreeTarget}from'../../commands/service/function-name-adapter.js';const FILE_FLAG={'name':'file','type':'string','required':!![],'description':a67_0x5161c3(0x15c)},SERVICE_FLAG={'name':'service','type':a67_0x5161c3(0x1a0),'required':!![],'description':a67_0x5161c3(0x183),'pattern':{'regex':/^[a-z][a-z0-9-]*$/,'description':a67_0x5161c3(0x162)}};function summarizeService(_0x13ed63){const _0x36a7da=a67_0x5161c3;return{'serviceCode':_0x13ed63['serviceCode'],'name':_0x13ed63[_0x36a7da(0x17e)][_0x36a7da(0x181)]['name'],'version':_0x13ed63[_0x36a7da(0x19b)],'importedAt':_0x13ed63[_0x36a7da(0x161)],'source':_0x13ed63[_0x36a7da(0x16a)],'commandCount':_0x13ed63['normalizedManifest']['commands'][_0x36a7da(0x178)],'commands':_0x13ed63[_0x36a7da(0x17e)][_0x36a7da(0x160)][_0x36a7da(0x15f)](_0x1b5be8=>({'path':_0x1b5be8[_0x36a7da(0x176)],'description':_0x1b5be8['description'],'risk':_0x1b5be8[_0x36a7da(0x163)],'target':toPublicServiceTreeTarget(_0x1b5be8[_0x36a7da(0x182)]),'flags':_0x1b5be8[_0x36a7da(0x16f)][_0x36a7da(0x15f)](_0x415c73=>({'name':_0x415c73[_0x36a7da(0x17d)],'cliName':_0x415c73[_0x36a7da(0x1a4)],'type':_0x415c73['type'],'required':_0x415c73['required']===!![]}))}))};}function summarizeLoadedManifest(_0x1b08a4){const _0x26f49a=a67_0x5161c3;return{'service':_0x1b08a4[_0x26f49a(0x17e)]?.[_0x26f49a(0x181)],'version':_0x1b08a4[_0x26f49a(0x17e)]?.['version'],'commandCount':_0x1b08a4['normalizedManifest']?.[_0x26f49a(0x160)][_0x26f49a(0x178)]??0x0,'commands':_0x1b08a4[_0x26f49a(0x17e)]?.[_0x26f49a(0x160)][_0x26f49a(0x15f)](_0x86910c=>({'path':_0x86910c[_0x26f49a(0x176)],'risk':_0x86910c[_0x26f49a(0x163)],'target':toPublicServiceTreeTarget(_0x86910c[_0x26f49a(0x182)])}))??[],'registryIndex':_0x1b08a4[_0x26f49a(0x19c)],'registryServiceCode':_0x1b08a4[_0x26f49a(0x19d)],'errors':_0x1b08a4[_0x26f49a(0x18d)][_0x26f49a(0x15b)],'warnings':_0x1b08a4['report'][_0x26f49a(0x184)]};}function a67_0x21d4(_0x5ce1f9,_0x456d14){_0x5ce1f9=_0x5ce1f9-0x15a;const _0x6055d4=a67_0x6055();let _0x21d434=_0x6055d4[_0x5ce1f9];return _0x21d434;}export const serviceDefinitions=[{'service':a67_0x5161c3(0x181),'command':a67_0x5161c3(0x196),'description':'Validate\x20a\x20Service\x20Tree\x20JSON\x20manifest','risk':'read','requiresAuth':![],'requiresAppCode':![],'flags':[FILE_FLAG],async 'execute'(_0x4cf5f0){const _0x382ccd=a67_0x5161c3,_0x104bc6=loadServiceManifestFromFile(_0x4cf5f0[_0x382ccd(0x19a)]('file'));if(!_0x104bc6['report']['ok'])return{'ok':![],'data':{'file':_0x104bc6[_0x382ccd(0x1a1)],'hash':_0x104bc6[_0x382ccd(0x198)],'kind':_0x104bc6[_0x382ccd(0x187)],'serviceCount':_0x104bc6[_0x382ccd(0x169)][_0x382ccd(0x178)],'services':_0x104bc6[_0x382ccd(0x169)][_0x382ccd(0x15f)](summarizeLoadedManifest),'errors':_0x104bc6[_0x382ccd(0x18d)][_0x382ccd(0x15b)],'warnings':_0x104bc6['report'][_0x382ccd(0x184)]},'message':formatValidationFailure(_0x104bc6['report'])};if(_0x104bc6[_0x382ccd(0x187)]===_0x382ccd(0x15a)||_0x104bc6['manifests']['length']!==0x1)return{'ok':!![],'data':{'file':_0x104bc6[_0x382ccd(0x1a1)],'hash':_0x104bc6['hash'],'kind':_0x104bc6[_0x382ccd(0x187)],'serviceCount':_0x104bc6[_0x382ccd(0x169)][_0x382ccd(0x178)],'commandCount':_0x104bc6[_0x382ccd(0x169)]['reduce']((_0x30bf9b,_0x5d04d9)=>_0x30bf9b+(_0x5d04d9['normalizedManifest']?.[_0x382ccd(0x160)][_0x382ccd(0x178)]??0x0),0x0),'services':_0x104bc6[_0x382ccd(0x169)][_0x382ccd(0x15f)](summarizeLoadedManifest),'warnings':_0x104bc6['report']['warnings']},'message':_0x382ccd(0x16e)};return{'ok':!![],'data':{'file':_0x104bc6[_0x382ccd(0x1a1)],'hash':_0x104bc6[_0x382ccd(0x198)],'kind':_0x104bc6[_0x382ccd(0x187)],'service':_0x104bc6[_0x382ccd(0x17e)]?.[_0x382ccd(0x181)],'version':_0x104bc6[_0x382ccd(0x17e)]?.[_0x382ccd(0x19b)],'commandCount':_0x104bc6['normalizedManifest']?.[_0x382ccd(0x160)][_0x382ccd(0x178)]??0x0,'commands':_0x104bc6['normalizedManifest']?.[_0x382ccd(0x160)]['map'](_0x2cf48a=>({'path':_0x2cf48a[_0x382ccd(0x176)],'risk':_0x2cf48a['risk'],'target':toPublicServiceTreeTarget(_0x2cf48a['target'])})),'warnings':_0x104bc6['report'][_0x382ccd(0x184)]},'message':_0x382ccd(0x185)};}},{'service':a67_0x5161c3(0x181),'command':a67_0x5161c3(0x194),'description':a67_0x5161c3(0x17a),'risk':a67_0x5161c3(0x174),'confirmationDescription':'Reads\x20the\x20given\x20manifest\x20into\x20the\x20local\x20Service\x20Tree\x20registry.\x20An\x20existing\x20manifest\x20with\x20the\x20same\x20service\x20code\x20is\x20updated.\x20The\x20confirmation\x20UI\x20does\x20not\x20show\x20local\x20file\x20paths.','requiresAuth':![],'requiresAppCode':![],'flags':[FILE_FLAG],async 'dryRun'(_0x3ea5f5){const _0x19d81c=a67_0x5161c3,_0x32527e=loadServiceManifestFromFile(_0x3ea5f5['str'](_0x19d81c(0x175)));return{'method':'WRITE','url':getServiceRegistryPath(),'body':{'file':_0x32527e[_0x19d81c(0x1a1)],'hash':_0x32527e[_0x19d81c(0x198)],'kind':_0x32527e['kind'],'ok':_0x32527e[_0x19d81c(0x18d)]['ok'],'service':_0x32527e['normalizedManifest']?.[_0x19d81c(0x181)],'version':_0x32527e[_0x19d81c(0x17e)]?.[_0x19d81c(0x19b)],'serviceCount':_0x32527e['manifests'][_0x19d81c(0x178)],'services':_0x32527e[_0x19d81c(0x169)][_0x19d81c(0x15f)](_0x36afbf=>({'service':_0x36afbf[_0x19d81c(0x17e)]?.['service'],'version':_0x36afbf[_0x19d81c(0x17e)]?.['version'],'commandCount':_0x36afbf[_0x19d81c(0x17e)]?.[_0x19d81c(0x160)][_0x19d81c(0x178)]??0x0,'errors':_0x36afbf['report'][_0x19d81c(0x15b)]})),'errors':_0x32527e['report'][_0x19d81c(0x15b)],'commandCount':_0x32527e[_0x19d81c(0x17e)]?.['commands'][_0x19d81c(0x178)]??0x0},'description':_0x19d81c(0x17b)};},async 'execute'(_0x469e24){const _0x4486ca=a67_0x5161c3,_0xce8cb6=importServiceManifest(_0x469e24[_0x4486ca(0x19a)](_0x4486ca(0x175)));if(_0xce8cb6[_0x4486ca(0x18f)][_0x4486ca(0x178)]!==0x1)return{'ok':!![],'data':{'registryPath':_0xce8cb6[_0x4486ca(0x17c)],'imported':_0xce8cb6[_0x4486ca(0x195)],'updated':_0xce8cb6[_0x4486ca(0x19e)],'serviceCount':_0xce8cb6[_0x4486ca(0x16b)],'services':_0xce8cb6[_0x4486ca(0x18f)][_0x4486ca(0x15f)](summarizeService)},'message':_0x4486ca(0x18b)+_0xce8cb6['imported']+_0x4486ca(0x190)+_0xce8cb6[_0x4486ca(0x19e)]+_0x4486ca(0x188)};return{'ok':!![],'data':{'registryPath':_0xce8cb6[_0x4486ca(0x17c)],'replaced':_0xce8cb6[_0x4486ca(0x15d)],'imported':_0xce8cb6[_0x4486ca(0x195)],'updated':_0xce8cb6['updated'],'serviceCount':_0xce8cb6[_0x4486ca(0x16b)],'service':summarizeService(_0xce8cb6[_0x4486ca(0x19f)])},'message':(_0xce8cb6[_0x4486ca(0x15d)]?'Updated':_0x4486ca(0x1a5))+_0x4486ca(0x17f)+_0xce8cb6[_0x4486ca(0x19f)][_0x4486ca(0x18c)]+'.'};}},{'service':a67_0x5161c3(0x181),'command':a67_0x5161c3(0x189),'description':a67_0x5161c3(0x168),'risk':'write','confirmationDescription':a67_0x5161c3(0x179),'requiresAuth':![],'requiresAppCode':![],'flags':[SERVICE_FLAG,FILE_FLAG],async 'dryRun'(_0x1e302e){const _0x44cff4=a67_0x5161c3,_0xb246d0=getLocalServiceEntry(_0x1e302e[_0x44cff4(0x19a)](_0x44cff4(0x181)));return{'method':'WRITE','url':_0x1e302e['str'](_0x44cff4(0x175)),'body':{'service':_0x1e302e['str'](_0x44cff4(0x181)),'found':Boolean(_0xb246d0),'version':_0xb246d0?.[_0x44cff4(0x19b)],'source':_0xb246d0?.[_0x44cff4(0x16a)]},'description':_0x44cff4(0x170)};},async 'execute'(_0x47e307){const _0x519d75=a67_0x5161c3,_0x50123e=exportServiceManifest(_0x47e307[_0x519d75(0x19a)](_0x519d75(0x181)),_0x47e307['str'](_0x519d75(0x175)));return{'ok':!![],'data':{'registryPath':_0x50123e[_0x519d75(0x17c)],'file':_0x50123e[_0x519d75(0x1a1)],'service':summarizeService(_0x50123e['entry'])},'message':'Exported\x20service\x20'+_0x50123e[_0x519d75(0x19f)][_0x519d75(0x18c)]+'.'};}},{'service':'service','command':a67_0x5161c3(0x15e),'description':a67_0x5161c3(0x165),'risk':a67_0x5161c3(0x180),'requiresAuth':![],'requiresAppCode':![],'flags':[],async 'execute'(){const _0x5348de=a67_0x5161c3,_0x1a9345=listLocalServices();return{'ok':!![],'data':{'registryPath':getServiceRegistryPath(),'total':_0x1a9345[_0x5348de(0x178)],'services':_0x1a9345[_0x5348de(0x15f)](summarizeService)}};}},{'service':'service','command':'remove','description':a67_0x5161c3(0x166),'risk':a67_0x5161c3(0x174),'confirmationDescription':'Removes\x20the\x20given\x20service\x20manifest\x20from\x20the\x20local\x20Service\x20Tree\x20registry.\x20Dynamic\x20commands\x20from\x20that\x20manifest\x20will\x20no\x20longer\x20be\x20available.','requiresAuth':![],'requiresAppCode':![],'flags':[SERVICE_FLAG],async 'dryRun'(_0x4e887e){const _0x268d0a=a67_0x5161c3,_0x3bd773=getLocalServiceEntry(_0x4e887e[_0x268d0a(0x19a)](_0x268d0a(0x181)));return{'method':_0x268d0a(0x172),'url':getServiceRegistryPath(),'body':{'service':_0x4e887e['str']('service'),'found':Boolean(_0x3bd773),'version':_0x3bd773?.['version'],'source':_0x3bd773?.['source']},'description':_0x268d0a(0x173)};},async 'execute'(_0x2605bf){const _0x48f61e=a67_0x5161c3,_0xb038e4=removeServiceManifest(_0x2605bf['str'](_0x48f61e(0x181)));return{'ok':!![],'data':{'registryPath':_0xb038e4[_0x48f61e(0x17c)],'serviceCount':_0xb038e4[_0x48f61e(0x16b)],'service':summarizeService(_0xb038e4['entry'])},'message':_0x48f61e(0x197)+_0xb038e4[_0x48f61e(0x19f)][_0x48f61e(0x18c)]+'.'};}},{'service':a67_0x5161c3(0x181),'command':'detail','description':a67_0x5161c3(0x191),'risk':'read','requiresAuth':![],'requiresAppCode':![],'flags':[SERVICE_FLAG],async 'execute'(_0x5172b0){const _0x3a039d=a67_0x5161c3,_0x586ede=getLocalServiceEntry(_0x5172b0[_0x3a039d(0x19a)](_0x3a039d(0x181)));if(!_0x586ede)return{'ok':![],'data':{'registryPath':getServiceRegistryPath(),'service':_0x5172b0[_0x3a039d(0x19a)](_0x3a039d(0x181))},'message':'Local\x20service\x20not\x20found:\x20'+_0x5172b0[_0x3a039d(0x19a)](_0x3a039d(0x181))};return{'ok':!![],'data':{'registryPath':getServiceRegistryPath(),'service':summarizeService(_0x586ede),'manifest':_0x586ede[_0x3a039d(0x177)],'normalizedManifest':toPublicNormalizedServiceTree(_0x586ede[_0x3a039d(0x17e)])}};}}];
1
+ const a67_0x24c945=a67_0x4c0d;(function(_0x121824,_0x222bd4){const _0x17fc02=a67_0x4c0d,_0x2486fc=_0x121824();while(!![]){try{const _0x2e4134=parseInt(_0x17fc02(0xd2))/0x1+parseInt(_0x17fc02(0x111))/0x2+parseInt(_0x17fc02(0x110))/0x3+-parseInt(_0x17fc02(0xe4))/0x4*(-parseInt(_0x17fc02(0xf7))/0x5)+-parseInt(_0x17fc02(0x104))/0x6+-parseInt(_0x17fc02(0xf1))/0x7*(-parseInt(_0x17fc02(0xf5))/0x8)+-parseInt(_0x17fc02(0xfc))/0x9;if(_0x2e4134===_0x222bd4)break;else _0x2486fc['push'](_0x2486fc['shift']());}catch(_0x308617){_0x2486fc['push'](_0x2486fc['shift']());}}}(a67_0x2ed9,0x7ce6b));import{exportServiceManifest,formatValidationFailure,getLocalServiceEntry,getServiceRegistryPath,importServiceManifest,listLocalServices,loadServiceManifestFromFile,removeServiceManifest}from'../../commands/service/registry.js';function a67_0x2ed9(){const _0x2542c7=['replaced','errors','serviceCount','Service\x20Tree\x20manifest\x20file\x20path','Reads\x20the\x20given\x20manifest\x20into\x20the\x20local\x20Service\x20Tree\x20registry.\x20An\x20existing\x20manifest\x20with\x20the\x20same\x20service\x20code\x20is\x20updated.\x20The\x20confirmation\x20UI\x20does\x20not\x20show\x20local\x20file\x20paths.','\x20service\x20','387593XkaLno','Imported','import','List\x20locally\x20imported\x20Service\x20Tree\x20manifests','registryIndex','Preview\x20Service\x20Tree\x20export\x20from\x20~/.lovrabet/service.json','cliName','Removes\x20the\x20given\x20service\x20manifest\x20from\x20the\x20local\x20Service\x20Tree\x20registry.\x20Dynamic\x20commands\x20from\x20that\x20manifest\x20will\x20no\x20longer\x20be\x20available.','Updated','WRITE','Remove\x20a\x20Service\x20Tree\x20manifest\x20from\x20the\x20local\x20runtime\x20registry','Local\x20service\x20code,\x20for\x20example\x20crm','hash','Service\x20manifest\x20validation\x20passed.','length','\x20service(s).','report','str','3470756ptEKHC','\x20service(s),\x20updated\x20','map','read','Preview\x20Service\x20Tree\x20import\x20into\x20~/.lovrabet/service.json','manifest','importedAt','entries','Exported\x20service\x20','manifests','file','serviceCode','target','318094VEdekK','validate','detail','entry','176XaMAQm','imported','5BTkHUG','Service\x20registry\x20validation\x20passed.','lower\x20kebab-case\x20service\x20code','cliPath','kind','24156198fXWVIy','export','Export\x20the\x20local\x20Service\x20Tree\x20manifest\x20to\x20a\x20JSON\x20file','risk','flags','registryPath','version','remove','175770mqNEAI','list','Preview\x20Service\x20Tree\x20removal\x20from\x20~/.lovrabet/service.json','required','Import\x20a\x20Service\x20Tree\x20manifest\x20into\x20the\x20local\x20runtime\x20registry','commands','write','source','Show\x20a\x20locally\x20imported\x20Service\x20Tree\x20manifest','Removed\x20service\x20','service','normalizedManifest','2337525GjvTTf','381462cVnyiK','warnings','name','filePath','string','updated'];a67_0x2ed9=function(){return _0x2542c7;};return a67_0x2ed9();}import{toPublicNormalizedServiceTree,toPublicServiceTreeTarget}from'../../commands/service/function-name-adapter.js';const FILE_FLAG={'name':a67_0x24c945(0xee),'type':'string','required':!![],'description':a67_0x24c945(0x11a)},SERVICE_FLAG={'name':a67_0x24c945(0x10e),'type':a67_0x24c945(0x115),'required':!![],'description':a67_0x24c945(0xdd),'pattern':{'regex':/^[a-z][a-z0-9-]*$/,'description':a67_0x24c945(0xf9)}};function summarizeService(_0x3e2f7b){const _0x451e82=a67_0x24c945;return{'serviceCode':_0x3e2f7b['serviceCode'],'name':_0x3e2f7b['normalizedManifest'][_0x451e82(0x10e)][_0x451e82(0x113)],'version':_0x3e2f7b['version'],'importedAt':_0x3e2f7b[_0x451e82(0xea)],'source':_0x3e2f7b[_0x451e82(0x10b)],'commandCount':_0x3e2f7b[_0x451e82(0x10f)][_0x451e82(0x109)][_0x451e82(0xe0)],'commands':_0x3e2f7b[_0x451e82(0x10f)][_0x451e82(0x109)][_0x451e82(0xe6)](_0x27073d=>({'path':_0x27073d['cliPath'],'description':_0x27073d['description'],'risk':_0x27073d['risk'],'target':toPublicServiceTreeTarget(_0x27073d[_0x451e82(0xf0)]),'flags':_0x27073d[_0x451e82(0x100)][_0x451e82(0xe6)](_0x597c68=>({'name':_0x597c68[_0x451e82(0x113)],'cliName':_0x597c68[_0x451e82(0xd8)],'type':_0x597c68['type'],'required':_0x597c68[_0x451e82(0x107)]===!![]}))}))};}function a67_0x4c0d(_0x44ea4c,_0x12e772){_0x44ea4c=_0x44ea4c-0xd0;const _0x2ed911=a67_0x2ed9();let _0x4c0d36=_0x2ed911[_0x44ea4c];return _0x4c0d36;}function summarizeLoadedManifest(_0x1a62aa){const _0x495b29=a67_0x24c945;return{'service':_0x1a62aa[_0x495b29(0x10f)]?.[_0x495b29(0x10e)],'version':_0x1a62aa[_0x495b29(0x10f)]?.['version'],'commandCount':_0x1a62aa[_0x495b29(0x10f)]?.[_0x495b29(0x109)][_0x495b29(0xe0)]??0x0,'commands':_0x1a62aa[_0x495b29(0x10f)]?.[_0x495b29(0x109)][_0x495b29(0xe6)](_0x37b07a=>({'path':_0x37b07a[_0x495b29(0xfa)],'risk':_0x37b07a[_0x495b29(0xff)],'target':toPublicServiceTreeTarget(_0x37b07a[_0x495b29(0xf0)])}))??[],'registryIndex':_0x1a62aa[_0x495b29(0xd6)],'registryServiceCode':_0x1a62aa['registryServiceCode'],'errors':_0x1a62aa[_0x495b29(0xe2)]['errors'],'warnings':_0x1a62aa[_0x495b29(0xe2)][_0x495b29(0x112)]};}export const serviceDefinitions=[{'service':a67_0x24c945(0x10e),'command':a67_0x24c945(0xf2),'description':'Validate\x20a\x20Service\x20Tree\x20JSON\x20manifest','risk':a67_0x24c945(0xe7),'requiresAuth':![],'requiresAppCode':![],'flags':[FILE_FLAG],async 'execute'(_0x3f4860){const _0x460013=a67_0x24c945,_0x2036b9=loadServiceManifestFromFile(_0x3f4860['str'](_0x460013(0xee)));if(!_0x2036b9[_0x460013(0xe2)]['ok'])return{'ok':![],'data':{'file':_0x2036b9[_0x460013(0x114)],'hash':_0x2036b9[_0x460013(0xde)],'kind':_0x2036b9[_0x460013(0xfb)],'serviceCount':_0x2036b9['manifests'][_0x460013(0xe0)],'services':_0x2036b9[_0x460013(0xed)][_0x460013(0xe6)](summarizeLoadedManifest),'errors':_0x2036b9['report']['errors'],'warnings':_0x2036b9[_0x460013(0xe2)][_0x460013(0x112)]},'message':formatValidationFailure(_0x2036b9[_0x460013(0xe2)])};if(_0x2036b9['kind']==='registry'||_0x2036b9[_0x460013(0xed)]['length']!==0x1)return{'ok':!![],'data':{'file':_0x2036b9[_0x460013(0x114)],'hash':_0x2036b9['hash'],'kind':_0x2036b9[_0x460013(0xfb)],'serviceCount':_0x2036b9[_0x460013(0xed)][_0x460013(0xe0)],'commandCount':_0x2036b9[_0x460013(0xed)]['reduce']((_0x412f57,_0x49664f)=>_0x412f57+(_0x49664f[_0x460013(0x10f)]?.[_0x460013(0x109)][_0x460013(0xe0)]??0x0),0x0),'services':_0x2036b9['manifests']['map'](summarizeLoadedManifest),'warnings':_0x2036b9[_0x460013(0xe2)]['warnings']},'message':_0x460013(0xf8)};return{'ok':!![],'data':{'file':_0x2036b9[_0x460013(0x114)],'hash':_0x2036b9[_0x460013(0xde)],'kind':_0x2036b9['kind'],'service':_0x2036b9[_0x460013(0x10f)]?.[_0x460013(0x10e)],'version':_0x2036b9[_0x460013(0x10f)]?.[_0x460013(0x102)],'commandCount':_0x2036b9[_0x460013(0x10f)]?.[_0x460013(0x109)][_0x460013(0xe0)]??0x0,'commands':_0x2036b9['normalizedManifest']?.[_0x460013(0x109)]['map'](_0x4bf13b=>({'path':_0x4bf13b[_0x460013(0xfa)],'risk':_0x4bf13b['risk'],'target':toPublicServiceTreeTarget(_0x4bf13b[_0x460013(0xf0)])})),'warnings':_0x2036b9[_0x460013(0xe2)][_0x460013(0x112)]},'message':_0x460013(0xdf)};}},{'service':a67_0x24c945(0x10e),'command':a67_0x24c945(0xd4),'description':a67_0x24c945(0x108),'risk':a67_0x24c945(0x10a),'confirmationDescription':a67_0x24c945(0xd0),'requiresAuth':![],'requiresAppCode':![],'flags':[FILE_FLAG],async 'dryRun'(_0x59b41f){const _0x56faee=a67_0x24c945,_0x4beb61=loadServiceManifestFromFile(_0x59b41f['str'](_0x56faee(0xee)));return{'method':'WRITE','url':getServiceRegistryPath(),'body':{'file':_0x4beb61[_0x56faee(0x114)],'hash':_0x4beb61[_0x56faee(0xde)],'kind':_0x4beb61[_0x56faee(0xfb)],'ok':_0x4beb61[_0x56faee(0xe2)]['ok'],'service':_0x4beb61['normalizedManifest']?.[_0x56faee(0x10e)],'version':_0x4beb61['normalizedManifest']?.['version'],'serviceCount':_0x4beb61[_0x56faee(0xed)][_0x56faee(0xe0)],'services':_0x4beb61[_0x56faee(0xed)][_0x56faee(0xe6)](_0x3cb876=>({'service':_0x3cb876[_0x56faee(0x10f)]?.['service'],'version':_0x3cb876[_0x56faee(0x10f)]?.[_0x56faee(0x102)],'commandCount':_0x3cb876['normalizedManifest']?.[_0x56faee(0x109)][_0x56faee(0xe0)]??0x0,'errors':_0x3cb876['report']['errors']})),'errors':_0x4beb61[_0x56faee(0xe2)][_0x56faee(0x118)],'commandCount':_0x4beb61[_0x56faee(0x10f)]?.[_0x56faee(0x109)]['length']??0x0},'description':_0x56faee(0xe8)};},async 'execute'(_0x3d22b3){const _0x5363bb=a67_0x24c945,_0x2604c0=importServiceManifest(_0x3d22b3['str'](_0x5363bb(0xee)));if(_0x2604c0[_0x5363bb(0xeb)]['length']!==0x1)return{'ok':!![],'data':{'registryPath':_0x2604c0[_0x5363bb(0x101)],'imported':_0x2604c0[_0x5363bb(0xf6)],'updated':_0x2604c0['updated'],'serviceCount':_0x2604c0[_0x5363bb(0x119)],'services':_0x2604c0['entries'][_0x5363bb(0xe6)](summarizeService)},'message':'Imported\x20'+_0x2604c0[_0x5363bb(0xf6)]+_0x5363bb(0xe5)+_0x2604c0['updated']+_0x5363bb(0xe1)};return{'ok':!![],'data':{'registryPath':_0x2604c0[_0x5363bb(0x101)],'replaced':_0x2604c0[_0x5363bb(0x117)],'imported':_0x2604c0[_0x5363bb(0xf6)],'updated':_0x2604c0[_0x5363bb(0x116)],'serviceCount':_0x2604c0['serviceCount'],'service':summarizeService(_0x2604c0['entry'])},'message':(_0x2604c0[_0x5363bb(0x117)]?_0x5363bb(0xda):_0x5363bb(0xd3))+_0x5363bb(0xd1)+_0x2604c0[_0x5363bb(0xf4)][_0x5363bb(0xef)]+'.'};}},{'service':'service','command':a67_0x24c945(0xfd),'description':a67_0x24c945(0xfe),'risk':a67_0x24c945(0x10a),'confirmationDescription':'Writes\x20the\x20local\x20Service\x20Tree\x20manifest\x20for\x20the\x20given\x20service\x20to\x20a\x20JSON\x20file.\x20An\x20existing\x20file\x20at\x20the\x20target\x20may\x20be\x20overwritten.\x20The\x20confirmation\x20UI\x20does\x20not\x20show\x20local\x20file\x20paths.','requiresAuth':![],'requiresAppCode':![],'flags':[SERVICE_FLAG,FILE_FLAG],async 'dryRun'(_0x432e4b){const _0xfb15ea=a67_0x24c945,_0x138c20=getLocalServiceEntry(_0x432e4b[_0xfb15ea(0xe3)]('service'));return{'method':_0xfb15ea(0xdb),'url':_0x432e4b[_0xfb15ea(0xe3)](_0xfb15ea(0xee)),'body':{'service':_0x432e4b[_0xfb15ea(0xe3)](_0xfb15ea(0x10e)),'found':Boolean(_0x138c20),'version':_0x138c20?.[_0xfb15ea(0x102)],'source':_0x138c20?.[_0xfb15ea(0x10b)]},'description':_0xfb15ea(0xd7)};},async 'execute'(_0xe6c2d1){const _0x21dec9=a67_0x24c945,_0x5f15ec=exportServiceManifest(_0xe6c2d1[_0x21dec9(0xe3)]('service'),_0xe6c2d1['str']('file'));return{'ok':!![],'data':{'registryPath':_0x5f15ec[_0x21dec9(0x101)],'file':_0x5f15ec[_0x21dec9(0x114)],'service':summarizeService(_0x5f15ec[_0x21dec9(0xf4)])},'message':_0x21dec9(0xec)+_0x5f15ec[_0x21dec9(0xf4)][_0x21dec9(0xef)]+'.'};}},{'service':a67_0x24c945(0x10e),'command':a67_0x24c945(0x105),'description':a67_0x24c945(0xd5),'risk':a67_0x24c945(0xe7),'requiresAuth':![],'requiresAppCode':![],'flags':[],async 'execute'(){const _0x43ddab=a67_0x24c945,_0x3cd3af=listLocalServices();return{'ok':!![],'data':{'registryPath':getServiceRegistryPath(),'total':_0x3cd3af[_0x43ddab(0xe0)],'services':_0x3cd3af['map'](summarizeService)}};}},{'service':a67_0x24c945(0x10e),'command':a67_0x24c945(0x103),'description':a67_0x24c945(0xdc),'risk':a67_0x24c945(0x10a),'confirmationDescription':a67_0x24c945(0xd9),'requiresAuth':![],'requiresAppCode':![],'flags':[SERVICE_FLAG],async 'dryRun'(_0x3e1f8f){const _0x17cc3a=a67_0x24c945,_0x9f13ca=getLocalServiceEntry(_0x3e1f8f[_0x17cc3a(0xe3)]('service'));return{'method':'WRITE','url':getServiceRegistryPath(),'body':{'service':_0x3e1f8f[_0x17cc3a(0xe3)]('service'),'found':Boolean(_0x9f13ca),'version':_0x9f13ca?.[_0x17cc3a(0x102)],'source':_0x9f13ca?.[_0x17cc3a(0x10b)]},'description':_0x17cc3a(0x106)};},async 'execute'(_0x546639){const _0x31ad62=a67_0x24c945,_0x2b25cb=removeServiceManifest(_0x546639[_0x31ad62(0xe3)](_0x31ad62(0x10e)));return{'ok':!![],'data':{'registryPath':_0x2b25cb[_0x31ad62(0x101)],'serviceCount':_0x2b25cb[_0x31ad62(0x119)],'service':summarizeService(_0x2b25cb[_0x31ad62(0xf4)])},'message':_0x31ad62(0x10d)+_0x2b25cb['entry'][_0x31ad62(0xef)]+'.'};}},{'service':'service','command':a67_0x24c945(0xf3),'description':a67_0x24c945(0x10c),'risk':a67_0x24c945(0xe7),'requiresAuth':![],'requiresAppCode':![],'flags':[SERVICE_FLAG],async 'execute'(_0x4f31e9){const _0x3b2616=a67_0x24c945,_0x27d62f=getLocalServiceEntry(_0x4f31e9['str'](_0x3b2616(0x10e)));if(!_0x27d62f)return{'ok':![],'data':{'registryPath':getServiceRegistryPath(),'service':_0x4f31e9[_0x3b2616(0xe3)](_0x3b2616(0x10e))},'message':'Local\x20service\x20not\x20found:\x20'+_0x4f31e9[_0x3b2616(0xe3)]('service')};return{'ok':!![],'data':{'registryPath':getServiceRegistryPath(),'service':summarizeService(_0x27d62f),'manifest':_0x27d62f[_0x3b2616(0xe9)],'normalizedManifest':toPublicNormalizedServiceTree(_0x27d62f[_0x3b2616(0x10f)])}};}}];