@lovrabet/rabetbase-cli 2.5.0 → 2.5.1-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (312) hide show
  1. package/lib/api/api-doc.js +1 -1
  2. package/lib/api/fetch-model-list.js +1 -1
  3. package/lib/api/generate-api-file.js +1 -1
  4. package/lib/api/generate-sdk-config-file.js +1 -1
  5. package/lib/auth/auth-server-ui.js +1 -1
  6. package/lib/auth/auth-server.d.ts +7 -0
  7. package/lib/auth/auth-server.js +1 -1
  8. package/lib/auth/constant.js +1 -1
  9. package/lib/auth/get-cookie.js +1 -1
  10. package/lib/auth/get-session-user.js +1 -1
  11. package/lib/auth/is-session-valid.js +1 -1
  12. package/lib/auth/login-success-html.js +1 -1
  13. package/lib/auth/logout.js +1 -1
  14. package/lib/cli-flags.js +1 -1
  15. package/lib/cli.js +1 -1
  16. package/lib/commands/api/generate.js +1 -1
  17. package/lib/commands/api/index.js +1 -1
  18. package/lib/commands/api/list.js +1 -1
  19. package/lib/commands/api/pull.js +1 -1
  20. package/lib/commands/api/shared.js +1 -1
  21. package/lib/commands/app/index.js +1 -1
  22. package/lib/commands/app/list.js +1 -1
  23. package/lib/commands/app/members-list.js +1 -1
  24. package/lib/commands/app/remote-directory.js +1 -1
  25. package/lib/commands/app/shared.js +1 -1
  26. package/lib/commands/app-config/delete.js +1 -1
  27. package/lib/commands/app-config/get.js +1 -1
  28. package/lib/commands/app-config/index.js +1 -1
  29. package/lib/commands/app-config/list.js +1 -1
  30. package/lib/commands/app-config/set.js +1 -1
  31. package/lib/commands/app-config/shared.js +1 -1
  32. package/lib/commands/auth/index.js +1 -1
  33. package/lib/commands/bff/create.js +1 -1
  34. package/lib/commands/bff/delete.js +1 -1
  35. package/lib/commands/bff/detail.js +1 -1
  36. package/lib/commands/bff/index.js +1 -1
  37. package/lib/commands/bff/list.js +1 -1
  38. package/lib/commands/bff/pull.js +1 -1
  39. package/lib/commands/bff/push.js +1 -1
  40. package/lib/commands/bff/status.js +1 -1
  41. package/lib/commands/cli-skill/index.js +1 -1
  42. package/lib/commands/cli-update.js +1 -1
  43. package/lib/commands/codegen/index.js +1 -1
  44. package/lib/commands/codegen/sdk.js +1 -1
  45. package/lib/commands/codegen/sql.js +1 -1
  46. package/lib/commands/common/app-registry.js +1 -1
  47. package/lib/commands/common/app-selector.js +1 -1
  48. package/lib/commands/common/async-task.js +1 -1
  49. package/lib/commands/common/dry-run.js +1 -1
  50. package/lib/commands/common/flags.js +1 -1
  51. package/lib/commands/common/local-file.js +1 -1
  52. package/lib/commands/common/validate.js +1 -1
  53. package/lib/commands/config/delete.js +1 -1
  54. package/lib/commands/config/get.js +1 -1
  55. package/lib/commands/config/index.js +1 -1
  56. package/lib/commands/config/init.d.ts +1 -1
  57. package/lib/commands/config/init.js +1 -1
  58. package/lib/commands/config/list.js +1 -1
  59. package/lib/commands/config/set.js +1 -1
  60. package/lib/commands/config/shared.js +1 -1
  61. package/lib/commands/dataset/business-group-update.js +1 -1
  62. package/lib/commands/dataset/business-groups.js +1 -1
  63. package/lib/commands/dataset/capability.js +1 -1
  64. package/lib/commands/dataset/delete.js +1 -1
  65. package/lib/commands/dataset/detail.js +1 -1
  66. package/lib/commands/dataset/extend-update.js +1 -1
  67. package/lib/commands/dataset/field-update.js +1 -1
  68. package/lib/commands/dataset/generate.js +1 -1
  69. package/lib/commands/dataset/index.js +1 -1
  70. package/lib/commands/dataset/list.js +1 -1
  71. package/lib/commands/dataset/operations.js +1 -1
  72. package/lib/commands/dataset/relation-audit.js +1 -1
  73. package/lib/commands/dataset/relation-create.js +1 -1
  74. package/lib/commands/dataset/relation-delete.js +1 -1
  75. package/lib/commands/dataset/relation-shared.js +1 -1
  76. package/lib/commands/dataset/relation-update.js +1 -1
  77. package/lib/commands/dataset/relations.js +1 -1
  78. package/lib/commands/dataset/rename.js +1 -1
  79. package/lib/commands/dataset/restore.js +1 -1
  80. package/lib/commands/db/analysis-batching.js +1 -1
  81. package/lib/commands/db/analyze-batch-plan.js +1 -1
  82. package/lib/commands/db/analyze-cancel.js +1 -1
  83. package/lib/commands/db/analyze-start.js +1 -1
  84. package/lib/commands/db/analyze-status.js +1 -1
  85. package/lib/commands/db/create.js +1 -1
  86. package/lib/commands/db/delete.js +1 -1
  87. package/lib/commands/db/detail.js +1 -1
  88. package/lib/commands/db/diff-refresh-start.js +1 -1
  89. package/lib/commands/db/diff-refresh-status.js +1 -1
  90. package/lib/commands/db/diff.js +1 -1
  91. package/lib/commands/db/index.js +1 -1
  92. package/lib/commands/db/list.js +1 -1
  93. package/lib/commands/db/shared.js +1 -1
  94. package/lib/commands/db/table-diff-shared.js +1 -1
  95. package/lib/commands/db/tables.js +1 -1
  96. package/lib/commands/db/test.js +1 -1
  97. package/lib/commands/db/update.js +1 -1
  98. package/lib/commands/doctor.js +1 -1
  99. package/lib/commands/file/index.js +1 -1
  100. package/lib/commands/issue/index.js +1 -1
  101. package/lib/commands/issue/nudge.js +1 -1
  102. package/lib/commands/issue/report.js +1 -1
  103. package/lib/commands/issue/shared.js +1 -1
  104. package/lib/commands/kb/create.js +1 -1
  105. package/lib/commands/kb/delete.js +1 -1
  106. package/lib/commands/kb/detail.js +1 -1
  107. package/lib/commands/kb/index.js +1 -1
  108. package/lib/commands/kb/list.js +1 -1
  109. package/lib/commands/kb/search.js +1 -1
  110. package/lib/commands/kb/shared.js +1 -1
  111. package/lib/commands/kb/update.js +1 -1
  112. package/lib/commands/logs/index.js +1 -1
  113. package/lib/commands/menu/asset-update.js +1 -1
  114. package/lib/commands/menu/delete.js +1 -1
  115. package/lib/commands/menu/external-link-create.js +1 -1
  116. package/lib/commands/menu/external-link-update.js +1 -1
  117. package/lib/commands/menu/group-create.js +1 -1
  118. package/lib/commands/menu/group-update.js +1 -1
  119. package/lib/commands/menu/index.js +1 -1
  120. package/lib/commands/menu/list.js +1 -1
  121. package/lib/commands/menu/move.js +1 -1
  122. package/lib/commands/menu/regroup-start.js +1 -1
  123. package/lib/commands/menu/rename.js +1 -1
  124. package/lib/commands/menu/shared/compare-table.js +1 -1
  125. package/lib/commands/menu/shared/delete-plan.js +1 -1
  126. package/lib/commands/menu/shared/facts.js +1 -1
  127. package/lib/commands/menu/shared/index.js +1 -1
  128. package/lib/commands/menu/shared/inquirer.js +1 -1
  129. package/lib/commands/menu/shared/local-pages.js +1 -1
  130. package/lib/commands/menu/shared/logic.js +1 -1
  131. package/lib/commands/menu/shared/mutations.js +1 -1
  132. package/lib/commands/menu/shared/service.js +1 -1
  133. package/lib/commands/menu/shared/sync-core.js +1 -1
  134. package/lib/commands/menu/shared/update-core.js +1 -1
  135. package/lib/commands/menu/shared/valid-url.js +1 -1
  136. package/lib/commands/menu/sync.js +1 -1
  137. package/lib/commands/menu/visibility-update.js +1 -1
  138. package/lib/commands/notification/config-create.js +1 -1
  139. package/lib/commands/notification/config-delete.js +1 -1
  140. package/lib/commands/notification/config-list.js +1 -1
  141. package/lib/commands/notification/config-update.js +1 -1
  142. package/lib/commands/notification/index.js +1 -1
  143. package/lib/commands/notification/shared.js +1 -1
  144. package/lib/commands/ocr/index.js +1 -1
  145. package/lib/commands/page/create.js +1 -1
  146. package/lib/commands/page/custom/detail.js +1 -1
  147. package/lib/commands/page/custom/list.js +1 -1
  148. package/lib/commands/page/custom/publish.js +1 -1
  149. package/lib/commands/page/custom/shared.js +1 -1
  150. package/lib/commands/page/custom/syntax.js +1 -1
  151. package/lib/commands/page/custom/template.js +1 -1
  152. package/lib/commands/page/custom/update.js +1 -1
  153. package/lib/commands/page/data-list-status.js +1 -1
  154. package/lib/commands/page/generate-start.js +1 -1
  155. package/lib/commands/page/generate-status.js +1 -1
  156. package/lib/commands/page/index.js +1 -1
  157. package/lib/commands/page/pull.js +1 -1
  158. package/lib/commands/page/push.js +1 -1
  159. package/lib/commands/page/relation-audit.js +1 -1
  160. package/lib/commands/page/restore.js +1 -1
  161. package/lib/commands/page/shared.js +1 -1
  162. package/lib/commands/page/sync.js +1 -1
  163. package/lib/commands/project/create/enhanced-guided-create.js +1 -1
  164. package/lib/commands/project/create/format-elapsed.js +1 -1
  165. package/lib/commands/project/create/main.js +1 -1
  166. package/lib/commands/project/create/materialize-project-template.js +1 -1
  167. package/lib/commands/project/create/project-name.js +1 -1
  168. package/lib/commands/project/create/project-template-archive.js +1 -1
  169. package/lib/commands/project/create/project-template-path.js +1 -1
  170. package/lib/commands/project/create/use-copy-project-template.js +1 -1
  171. package/lib/commands/project/create/use-format-code.js +1 -1
  172. package/lib/commands/project/create/use-install-dependencies.js +1 -1
  173. package/lib/commands/project/index.js +1 -1
  174. package/lib/commands/project/upgrade.js +1 -1
  175. package/lib/commands/registry.js +1 -1
  176. package/lib/commands/role/delete.js +1 -1
  177. package/lib/commands/role/detail.js +1 -1
  178. package/lib/commands/role/index.js +1 -1
  179. package/lib/commands/role/list.js +1 -1
  180. package/lib/commands/role/shared.js +1 -1
  181. package/lib/commands/role/update.js +1 -1
  182. package/lib/commands/role/user-add.js +1 -1
  183. package/lib/commands/role/user-remove.js +1 -1
  184. package/lib/commands/role/user-resolve.js +1 -1
  185. package/lib/commands/run/index.js +1 -1
  186. package/lib/commands/schema.js +1 -1
  187. package/lib/commands/sql/create.js +1 -1
  188. package/lib/commands/sql/delete.js +1 -1
  189. package/lib/commands/sql/detail.js +1 -1
  190. package/lib/commands/sql/exec.js +1 -1
  191. package/lib/commands/sql/index.js +1 -1
  192. package/lib/commands/sql/list.js +1 -1
  193. package/lib/commands/sql/pull.js +1 -1
  194. package/lib/commands/sql/push.js +1 -1
  195. package/lib/commands/sql/shared.js +1 -1
  196. package/lib/commands/sql/status.js +1 -1
  197. package/lib/commands/sql/validate.js +1 -1
  198. package/lib/commands/task/index.js +1 -1
  199. package/lib/commands/task/status.js +1 -1
  200. package/lib/commands/tenant/index.js +1 -1
  201. package/lib/commands/tenant/members-list.js +1 -1
  202. package/lib/commands/tenant/shared.js +1 -1
  203. package/lib/commands/user-account/dingding-sandbox-bind.js +1 -1
  204. package/lib/commands/user-account/index.js +1 -1
  205. package/lib/commands/workspace/add.js +1 -1
  206. package/lib/commands/workspace/index.js +1 -1
  207. package/lib/commands/workspace/remove.js +1 -1
  208. package/lib/config/domain-config.d.ts +1 -1
  209. package/lib/config/domain-config.js +1 -1
  210. package/lib/config/project-routing.d.ts +30 -0
  211. package/lib/config/project-routing.js +1 -0
  212. package/lib/config/schema.d.ts +1 -1
  213. package/lib/config/schema.js +1 -1
  214. package/lib/constant/cdn.js +1 -1
  215. package/lib/constant/cli.js +1 -1
  216. package/lib/constant/defaults.js +1 -1
  217. package/lib/constant/domain.d.ts +7 -2
  218. package/lib/constant/domain.js +1 -1
  219. package/lib/constant/env.js +1 -1
  220. package/lib/constant/output.js +1 -1
  221. package/lib/constant/paths.js +1 -1
  222. package/lib/constant/region.d.ts +2 -2
  223. package/lib/constant/region.js +1 -1
  224. package/lib/constant/risk.js +1 -1
  225. package/lib/constant/routing-profile.d.ts +115 -0
  226. package/lib/constant/routing-profile.js +1 -0
  227. package/lib/context/app-resolver.js +1 -1
  228. package/lib/context/auth-resolver.js +1 -1
  229. package/lib/context/config-loader.js +1 -1
  230. package/lib/context.js +1 -1
  231. package/lib/core/alias-resolver.js +1 -1
  232. package/lib/core/api-client.js +1 -1
  233. package/lib/core/bff/config.js +1 -1
  234. package/lib/core/bff/file-system.js +1 -1
  235. package/lib/core/bff/hash.js +1 -1
  236. package/lib/core/bff/lock.js +1 -1
  237. package/lib/core/bff/utils.js +1 -1
  238. package/lib/core/db-resolver.js +1 -1
  239. package/lib/core/page/file-system.js +1 -1
  240. package/lib/core/page/hash.js +1 -1
  241. package/lib/core/page/lock.js +1 -1
  242. package/lib/core/sql-index-auditor.js +1 -1
  243. package/lib/core/sql-sync/config.js +1 -1
  244. package/lib/core/sql-sync/file-system.js +1 -1
  245. package/lib/core/sql-sync/hash.js +1 -1
  246. package/lib/core/sql-sync/lock.js +1 -1
  247. package/lib/core/sql-sync/utils.js +1 -1
  248. package/lib/core/sql-validator.js +1 -1
  249. package/lib/errors.js +1 -1
  250. package/lib/framework/build-all-flags.js +1 -1
  251. package/lib/framework/error-output.js +1 -1
  252. package/lib/framework/explicit-yes.js +1 -1
  253. package/lib/framework/flags.js +1 -1
  254. package/lib/framework/help.js +1 -1
  255. package/lib/framework/index.js +1 -1
  256. package/lib/framework/output.js +1 -1
  257. package/lib/framework/response.js +1 -1
  258. package/lib/framework/runner-alias.js +1 -1
  259. package/lib/framework/runner.js +1 -1
  260. package/lib/framework/schema-export.js +1 -1
  261. package/lib/framework/types.js +1 -1
  262. package/lib/generated/build-info.d.ts +4 -4
  263. package/lib/generated/build-info.js +1 -1
  264. package/lib/help.js +1 -1
  265. package/lib/postinstall.js +1 -1
  266. package/lib/runtime/confirmation.js +1 -1
  267. package/lib/runtime/event.js +1 -1
  268. package/lib/runtime/index.js +1 -1
  269. package/lib/runtime/queue.js +1 -1
  270. package/lib/runtime/resolve.js +1 -1
  271. package/lib/skills/builtin-skill.js +1 -1
  272. package/lib/skills/main.js +1 -1
  273. package/lib/skills/npx-skills-add.js +1 -1
  274. package/lib/skills/skill-presence.js +1 -1
  275. package/lib/telemetry/cli-command-trace.js +1 -1
  276. package/lib/telemetry/cli-help-trace.js +1 -1
  277. package/lib/telemetry/ensure-cli-otel-config.js +1 -1
  278. package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
  279. package/lib/telemetry/send-cli-trace-log.js +1 -1
  280. package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
  281. package/lib/utils/ai_config.js +1 -1
  282. package/lib/utils/apply-jq-filter.js +1 -1
  283. package/lib/utils/cdn-config.js +1 -1
  284. package/lib/utils/check-sdk-version.js +1 -1
  285. package/lib/utils/cli-version-check.js +1 -1
  286. package/lib/utils/cli-version-policy.js +1 -1
  287. package/lib/utils/config.js +1 -1
  288. package/lib/utils/entity-with-id.js +1 -1
  289. package/lib/utils/file-utils.js +1 -1
  290. package/lib/utils/guides-cdn.js +1 -1
  291. package/lib/utils/http-client.js +1 -1
  292. package/lib/utils/is-non-interactive.js +1 -1
  293. package/lib/utils/logger.js +1 -1
  294. package/lib/utils/params.js +1 -1
  295. package/lib/utils/platform.js +1 -1
  296. package/lib/utils/sleep.js +1 -1
  297. package/lib/utils/template-replacer.js +1 -1
  298. package/lib/utils/update-notice.js +1 -1
  299. package/lib/utils/version.js +1 -1
  300. package/lib/utils/with-active-cookie.js +1 -1
  301. package/lib/utils/write-cli-side-channel.js +1 -1
  302. package/package.json +1 -2
  303. package/skills/rabetbase/SKILL.md +10 -5
  304. package/skills/rabetbase/guides/frontend-development.md +2 -0
  305. package/skills/rabetbase/guides/sdk-client-generation.md +3 -2
  306. package/skills/rabetbase/guides/typescript-sdk.md +42 -0
  307. package/skills/rabetbase/references/rabetbase-api-pull.md +5 -3
  308. package/skills/rabetbase/references/rabetbase-config.md +9 -5
  309. package/skills/rabetbase/references/rabetbase-init.md +11 -5
  310. package/skills/rabetbase/references/rabetbase-project-create.md +6 -5
  311. package/skills/rabetbase.manifest.json +3 -3
  312. package/templates/README.md +13 -17
@@ -1 +1 @@
1
- const a141_0x2ec41a=a141_0x60d2;(function(_0x2c9445,_0x294431){const _0x32759f=a141_0x60d2,_0x308a3d=_0x2c9445();while(!![]){try{const _0x301a40=-parseInt(_0x32759f(0x1e0))/0x1*(parseInt(_0x32759f(0x1db))/0x2)+-parseInt(_0x32759f(0x1ce))/0x3*(-parseInt(_0x32759f(0x177))/0x4)+parseInt(_0x32759f(0x1df))/0x5+-parseInt(_0x32759f(0x1f6))/0x6+parseInt(_0x32759f(0x189))/0x7*(-parseInt(_0x32759f(0x182))/0x8)+parseInt(_0x32759f(0x1de))/0x9*(parseInt(_0x32759f(0x1dd))/0xa)+parseInt(_0x32759f(0x1c9))/0xb;if(_0x301a40===_0x294431)break;else _0x308a3d['push'](_0x308a3d['shift']());}catch(_0x466436){_0x308a3d['push'](_0x308a3d['shift']());}}}(a141_0x28f2,0x82d55));function a141_0x60d2(_0x13ab10,_0x4d8864){_0x13ab10=_0x13ab10-0x174;const _0x28f215=a141_0x28f2();let _0x60d2ef=_0x28f215[_0x13ab10];return _0x60d2ef;}import{readFile}from'node:fs/promises';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getNotificationChannelConfig}from'../../core/api-client.js';import{CliError,CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=[a141_0x2ec41a(0x1f5),a141_0x2ec41a(0x174),a141_0x2ec41a(0x187),'WECOM',a141_0x2ec41a(0x1d2)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a141_0x2ec41a(0x1c0),a141_0x2ec41a(0x1e2),a141_0x2ec41a(0x1ec),'channelConfig',a141_0x2ec41a(0x1cf),'connectTimeout',a141_0x2ec41a(0x1ca)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a141_0x2ec41a(0x17d),'configCode',a141_0x2ec41a(0x1e4)]),EMAIL_RECIPIENT_FIELDS=new Set([a141_0x2ec41a(0x18a),'recipients',a141_0x2ec41a(0x1ad),'bccList','replyTo','subjectPrefix',a141_0x2ec41a(0x1d1),'to','cc']);function a141_0x28f2(){const _0x4cf545=['Allowed\x20values:\x20','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','length','configName','kind','Unknown\x20notification\x20JSON\x20field\x20\x22','endpointUrlRaw','\x20has\x20an\x20unsupported\x20channelType.','Notification\x20config\x20list\x20item\x20','updateTime','a\x20JSON\x20object\x20or\x20null','\x22configName\x22.','12898820xWmcDh','readTimeout','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','endpointUrl:null','\x20has\x20an\x20invalid\x20id.','2933697cGHkKU','description','createTime','fromName','WEBHOOK','Item\x20','join','notification_config_field_unknown','stdin','includes','notification_config_field_invalid','has','utf8','86jbeZib','Missing\x20notification\x20JSON\x20source.','30380pFWoeA','216FctAdP','255680eeeabT','13242LzpSgl','str','channelType','a\x20string\x20or\x20null','channelCode','notification_config_','\x20characters.','trim','notification_config_update_empty','keys','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','push','endpointUrl','\x20has\x20invalid\x20field\x20\x22','environment\x20variable\x20','validation','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','_unavailable','Invalid\x20notification\x20config\x20response.','\x22channelType\x22.','notification_config_json_invalid','EMAIL','3781374UjCDLW','bool','\x20is\x20missing\x20required\x20field\x20\x22','FEISHU','configCode','rabetbase\x20notification\x20config-list\x20--appcode\x20','4ftLezl','\x20--format\x20compress','Create\x20JSON\x20requires\x20field\x20','\x20must\x20be\x20an\x20object.','isSafeInteger','call','appCode','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','from-env','channelConfig','apiError','8sOtAdL','string','num','channelConfigRaw','hasOwnProperty','DINGTALK','\x22\x20cannot\x20exceed\x20','3773273rBXosg','emailTargets','some','env','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','boolean','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','a\x20supported\x20string','name','\x20failed.','messageTemplate','Invalid\x20--','update','Notification\x20JSON\x20field\x20\x22','yes','\x20has\x20an\x20invalid\x20channelType.','notification_config_channel_field_forbidden','create','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','file','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','a\x20JSON\x20object','notification_config_id_invalid','type','\x22\x20is\x20forbidden.','connectTimeout','Application-level\x20notification\x20config\x20ID','notification_config_source_unavailable','Notification\x20config\x20','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','entries','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','notification_config_field_required','path','ccList','parse','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','number','a\x20non-empty\x20string','notification_config_field_forbidden','notification_config_response_invalid','prototype','Notification\x20JSON\x20from\x20','\x22\x20must\x20be\x20a\x20non-empty\x20string.','every','Notification\x20JSON\x20source\x20is\x20ambiguous.','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','isArray','Notification\x20JSON\x20channelConfig\x20field\x20\x22','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file'];a141_0x28f2=function(){return _0x4cf545;};return a141_0x28f2();}export const NOTIFICATION_INPUT_FLAGS=[{'name':a141_0x2ec41a(0x19d),'type':a141_0x2ec41a(0x183),'required':![],'description':a141_0x2ec41a(0x1bc)},{'name':a141_0x2ec41a(0x1d6),'type':a141_0x2ec41a(0x18e),'required':![],'default':![],'description':a141_0x2ec41a(0x1b9)},{'name':a141_0x2ec41a(0x17f),'type':'string','required':![],'description':a141_0x2ec41a(0x1f0)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a141_0x2ec41a(0x1b0),'required':!![],'description':a141_0x2ec41a(0x1a4)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x3269d3,_0x291302,_0x4827ac){return new CliError(_0x3269d3,0x1,_0x291302,_0x4827ac);}export function readNotificationId(_0x38d431){const _0x4ba77c=a141_0x2ec41a,_0x5495f2=_0x38d431[_0x4ba77c(0x184)]('id');if(!Number[_0x4ba77c(0x17b)](_0x5495f2)||_0x5495f2<=0x0)throw notificationError(_0x4ba77c(0x1a0),_0x4ba77c(0x1aa));return _0x5495f2;}export function requireNotificationExplicitYes(_0x34d184){const _0x1f6838=a141_0x2ec41a;if(_0x34d184['bool']('dry-run')||_0x34d184[_0x1f6838(0x1f7)](_0x1f6838(0x198)))return;throw notificationError('notification_config_confirmation_required',_0x1f6838(0x19e),_0x1f6838(0x17e));}export function readNotificationChannelType(_0x30ce05,_0x4b5810=a141_0x2ec41a(0x1a1),_0x2bf864='EMAIL'){const _0x1b2a90=a141_0x2ec41a,_0x1a0e82=_0x30ce05[_0x1b2a90(0x1e1)](_0x4b5810)['trim']()||_0x2bf864;if(!NOTIFICATION_CHANNEL_TYPES[_0x1b2a90(0x1d7)](_0x1a0e82))throw CliErrors[_0x1b2a90(0x1ef)](_0x1b2a90(0x195)+_0x4b5810+':\x20'+_0x1a0e82,_0x1b2a90(0x1bd)+NOTIFICATION_CHANNEL_TYPES[_0x1b2a90(0x1d4)](',\x20')+'.');return _0x1a0e82;}export function assertSingleNotificationSource(_0x43cede){const _0x3bb4dd=a141_0x2ec41a,_0x21fd08=[],_0xfadfc6=_0x43cede[_0x3bb4dd(0x1e1)]('file')[_0x3bb4dd(0x1e7)]();if(_0xfadfc6)_0x21fd08[_0x3bb4dd(0x1eb)]({'kind':_0x3bb4dd(0x19d),'path':_0xfadfc6});if(_0x43cede[_0x3bb4dd(0x1f7)](_0x3bb4dd(0x1d6)))_0x21fd08['push']({'kind':_0x3bb4dd(0x1d6)});const _0x203cb8=_0x43cede[_0x3bb4dd(0x1e1)](_0x3bb4dd(0x17f))['trim']();if(_0x203cb8)_0x21fd08[_0x3bb4dd(0x1eb)]({'kind':_0x3bb4dd(0x18c),'name':_0x203cb8});if(_0x21fd08['length']===0x0)throw CliErrors[_0x3bb4dd(0x1ef)](_0x3bb4dd(0x1dc),_0x3bb4dd(0x1a7));if(_0x21fd08[_0x3bb4dd(0x1bf)]>0x1)throw CliErrors[_0x3bb4dd(0x1ef)](_0x3bb4dd(0x1b8),_0x3bb4dd(0x1a7));return _0x21fd08[0x0];}export async function readNotificationDocument(_0x562676,_0x4372d5){const _0x2bc444=a141_0x2ec41a,_0x1ad750=assertSingleNotificationSource(_0x562676),_0x337693=_0x1ad750[_0x2bc444(0x1c1)]===_0x2bc444(0x19d)?'file\x20'+_0x1ad750[_0x2bc444(0x1ac)]:_0x1ad750[_0x2bc444(0x1c1)]===_0x2bc444(0x18c)?_0x2bc444(0x1ee)+_0x1ad750[_0x2bc444(0x192)]:_0x2bc444(0x1d6);let _0x120a0f;try{if(_0x1ad750[_0x2bc444(0x1c1)]===_0x2bc444(0x19d))_0x120a0f=await readFile(_0x1ad750[_0x2bc444(0x1ac)],_0x2bc444(0x1da));else{if(_0x1ad750[_0x2bc444(0x1c1)]===_0x2bc444(0x18c)){if(!(_0x1ad750['name']in process.env))throw notificationError('notification_config_source_unavailable',_0x2bc444(0x19c)+_0x1ad750[_0x2bc444(0x192)]);_0x120a0f=process.env[_0x1ad750.name]??'';}else _0x120a0f=await readStdin();}}catch(_0x37f0cd){if(_0x37f0cd instanceof CliError)throw _0x37f0cd;throw notificationError(_0x2bc444(0x1a5),_0x2bc444(0x18d)+_0x337693+'.');}let _0x1ce5e6;try{_0x1ce5e6=JSON[_0x2bc444(0x1ae)](_0x120a0f);}catch{throw notificationError(_0x2bc444(0x1f4),_0x2bc444(0x1b5)+_0x337693+'\x20is\x20invalid.',_0x2bc444(0x1cb));}if(!isJsonObject(_0x1ce5e6))throw notificationError('notification_config_json_invalid','Notification\x20JSON\x20from\x20'+_0x337693+_0x2bc444(0x17a));return validateNotificationDocument(_0x1ce5e6,_0x4372d5);}export function projectNotificationListConfig(_0x4100ac,_0x2f98ff){const _0x5290fc=a141_0x2ec41a;return{'id':typeof _0x4100ac['id']===_0x5290fc(0x1b0)?_0x4100ac['id']:null,'configCode':requireResponseString(_0x4100ac[_0x5290fc(0x175)],_0x5290fc(0x175),_0x2f98ff),'configName':requireResponseString(_0x4100ac[_0x5290fc(0x1c0)],'configName',_0x2f98ff),'channelType':requireResponseString(_0x4100ac['channelType'],_0x5290fc(0x1e2),_0x2f98ff),'description':normalizeNullableString(_0x4100ac[_0x5290fc(0x1cf)]),'createTime':normalizeNullableString(_0x4100ac[_0x5290fc(0x1d0)]),'updateTime':normalizeNullableString(_0x4100ac[_0x5290fc(0x1c6)])};}export function normalizeExactNotificationConfig(_0x5dcdfc,_0x2ea76d,_0x630f53){const _0x2e9f52=a141_0x2ec41a;if(!Number['isSafeInteger'](_0x5dcdfc['id'])||_0x5dcdfc['id']!==_0x2ea76d)throw notificationError(_0x2e9f52(0x1b3),'Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20'+_0x2ea76d+'.');if(_0x5dcdfc[_0x2e9f52(0x17d)]!==_0x630f53)throw notificationError(_0x2e9f52(0x1b3),'Notification\x20config\x20'+_0x2ea76d+_0x2e9f52(0x1ea));const _0x5516e9=requireExactString(_0x5dcdfc[_0x2e9f52(0x1c0)],_0x2e9f52(0x1c0),_0x2ea76d),_0x56c157=requireExactString(_0x5dcdfc[_0x2e9f52(0x175)],_0x2e9f52(0x175),_0x2ea76d),_0xf6b616=requireExactString(_0x5dcdfc[_0x2e9f52(0x1e2)],_0x2e9f52(0x1e2),_0x2ea76d);if(!NOTIFICATION_CHANNEL_TYPES[_0x2e9f52(0x1d7)](_0xf6b616))throw notificationError(_0x2e9f52(0x1b3),_0x2e9f52(0x1a6)+_0x2ea76d+_0x2e9f52(0x1c4));const _0x642425=responseNullableString(_0x5dcdfc[_0x2e9f52(0x1ec)],'endpointUrl',_0x2ea76d),_0x49353=responseNullableString(_0x5dcdfc[_0x2e9f52(0x180)],'channelConfig',_0x2ea76d),_0x145eb2=responseNullableString(_0x5dcdfc[_0x2e9f52(0x1cf)],'description',_0x2ea76d),_0x4b3afb=responseNullableTimeout(_0x5dcdfc['connectTimeout'],_0x2e9f52(0x1a3),_0x2ea76d),_0x21e831=responseNullableTimeout(_0x5dcdfc[_0x2e9f52(0x1ca)],_0x2e9f52(0x1ca),_0x2ea76d);return{'id':_0x2ea76d,'appCode':_0x630f53,'configCode':_0x56c157,'configName':_0x5516e9,'channelType':_0xf6b616,'endpointUrl':redactSensitive(_0x642425),'channelConfig':redactSensitive(_0x49353),'description':_0x145eb2,'connectTimeout':_0x4b3afb,'readTimeout':_0x21e831,'endpointUrlRaw':_0x642425,'channelConfigRaw':_0x49353};}export async function requireExactNotificationConfig(_0x522d66,_0x258371,_0x2c484c){const _0x474e90=a141_0x2ec41a;let _0x56247c;try{_0x56247c=await getNotificationChannelConfig(_0x258371,_0x522d66);}catch{throw safeApiFailure(_0x2c484c,'preflight',_0x474e90(0x18f)+_0x522d66+_0x474e90(0x1a9));}return normalizeExactNotificationConfig(_0x56247c,_0x258371,_0x522d66);}export function projectNotificationConfig(_0x5bd896){const _0x1d7691=a141_0x2ec41a;return{'id':_0x5bd896['id']??null,'appCode':_0x5bd896[_0x1d7691(0x17d)],'configCode':_0x5bd896[_0x1d7691(0x175)]??null,'configName':_0x5bd896[_0x1d7691(0x1c0)],'channelType':_0x5bd896[_0x1d7691(0x1e2)],'endpointUrl':redactSensitive(_0x5bd896[_0x1d7691(0x1ec)]),'channelConfig':redactSensitive(_0x5bd896[_0x1d7691(0x180)]),'description':_0x5bd896[_0x1d7691(0x1cf)]??null,'connectTimeout':_0x5bd896['connectTimeout']??null,'readTimeout':_0x5bd896[_0x1d7691(0x1ca)]??null};}export function notificationSelector(_0x3ca2cb){const _0x2f9764=a141_0x2ec41a;return{'appCode':_0x3ca2cb[_0x2f9764(0x17d)],'id':_0x3ca2cb['id'],'configCode':_0x3ca2cb[_0x2f9764(0x175)],'configName':_0x3ca2cb['configName'],'channelType':_0x3ca2cb['channelType']};}export function createMutationInput(_0xc55acb,_0x47ccf9){const _0x576ba9=a141_0x2ec41a;return{'appCode':_0xc55acb,'configName':_0x47ccf9[_0x576ba9(0x1c0)],'channelType':_0x47ccf9[_0x576ba9(0x1e2)],...hasOwn(_0x47ccf9,'endpointUrl')?{'endpointUrl':_0x47ccf9['endpointUrl']}:{},...hasOwn(_0x47ccf9,_0x576ba9(0x180))?{'channelConfig':serializeChannelConfig(_0x47ccf9[_0x576ba9(0x180)])}:{},...hasOwn(_0x47ccf9,_0x576ba9(0x1cf))?{'description':_0x47ccf9[_0x576ba9(0x1cf)]}:{},...hasOwn(_0x47ccf9,'connectTimeout')?{'connectTimeout':_0x47ccf9[_0x576ba9(0x1a3)]}:{},...hasOwn(_0x47ccf9,'readTimeout')?{'readTimeout':_0x47ccf9[_0x576ba9(0x1ca)]}:{}};}export function mergeUpdateInput(_0x245846,_0x3738c2){const _0x2d5623=a141_0x2ec41a;return{'id':_0x245846['id'],'appCode':_0x245846[_0x2d5623(0x17d)],'configName':_0x3738c2[_0x2d5623(0x1c0)]??_0x245846[_0x2d5623(0x1c0)],'channelType':_0x3738c2[_0x2d5623(0x1e2)]??_0x245846[_0x2d5623(0x1e2)],'endpointUrl':hasOwn(_0x3738c2,_0x2d5623(0x1ec))?_0x3738c2[_0x2d5623(0x1ec)]:_0x245846[_0x2d5623(0x1c3)],'channelConfig':hasOwn(_0x3738c2,'channelConfig')?serializeChannelConfig(_0x3738c2[_0x2d5623(0x180)]):_0x245846['channelConfigRaw'],'description':hasOwn(_0x3738c2,_0x2d5623(0x1cf))?_0x3738c2[_0x2d5623(0x1cf)]:_0x245846['description'],'connectTimeout':hasOwn(_0x3738c2,_0x2d5623(0x1a3))?_0x3738c2[_0x2d5623(0x1a3)]:_0x245846[_0x2d5623(0x1a3)],'readTimeout':hasOwn(_0x3738c2,'readTimeout')?_0x3738c2['readTimeout']:_0x245846[_0x2d5623(0x1ca)]};}export function plannedUpdateProjection(_0x9dac59,_0x4a5198){const _0x54dc41=a141_0x2ec41a;return projectNotificationConfig({'id':_0x9dac59['id'],'appCode':_0x9dac59[_0x54dc41(0x17d)],'configCode':_0x9dac59[_0x54dc41(0x175)],'configName':_0x4a5198[_0x54dc41(0x1c0)]??_0x9dac59[_0x54dc41(0x1c0)],'channelType':_0x4a5198['channelType']??_0x9dac59[_0x54dc41(0x1e2)],'endpointUrl':hasOwn(_0x4a5198,_0x54dc41(0x1ec))?_0x4a5198[_0x54dc41(0x1ec)]:_0x9dac59[_0x54dc41(0x1c3)],'channelConfig':hasOwn(_0x4a5198,_0x54dc41(0x180))?_0x4a5198[_0x54dc41(0x180)]:_0x9dac59[_0x54dc41(0x185)],'description':hasOwn(_0x4a5198,'description')?_0x4a5198[_0x54dc41(0x1cf)]:_0x9dac59[_0x54dc41(0x1cf)],'connectTimeout':hasOwn(_0x4a5198,_0x54dc41(0x1a3))?_0x4a5198[_0x54dc41(0x1a3)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x9dac59[_0x54dc41(0x1a3)],'readTimeout':hasOwn(_0x4a5198,_0x54dc41(0x1ca))?_0x4a5198['readTimeout']??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x9dac59[_0x54dc41(0x1ca)]});}export function requestedSafeFieldsMatch(_0x32bc3f,_0x3db517,_0x376913){const _0xe78568=a141_0x2ec41a,_0x5bf788=[],_0x3e8504=[],_0x455c8a=[];for(const _0x431b6c of[_0xe78568(0x1c0),_0xe78568(0x1e2),'description']){if(!hasOwn(_0x376913,_0x431b6c))continue;_0x455c8a['push'](_0x431b6c),_0x5bf788[_0xe78568(0x1eb)](_0x3db517[_0x431b6c]===_0x376913[_0x431b6c]),_0x3e8504['push'](_0x32bc3f[_0x431b6c]!==_0x376913[_0x431b6c]&&_0x3db517[_0x431b6c]===_0x376913[_0x431b6c]);}for(const _0x464a51 of[_0xe78568(0x1a3),_0xe78568(0x1ca)]){if(!hasOwn(_0x376913,_0x464a51))continue;const _0x5ea4c2=_0x376913[_0x464a51]??(_0x464a51==='connectTimeout'?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x455c8a[_0xe78568(0x1eb)](_0x464a51),_0x5bf788['push'](_0x3db517[_0x464a51]===_0x5ea4c2),_0x3e8504[_0xe78568(0x1eb)](_0x32bc3f[_0x464a51]!==_0x5ea4c2&&_0x3db517[_0x464a51]===_0x5ea4c2);}return hasOwn(_0x376913,_0xe78568(0x1ec))&&_0x376913[_0xe78568(0x1ec)]===null&&(_0x455c8a['push'](_0xe78568(0x1cc)),_0x5bf788['push'](_0x3db517['endpointUrlRaw']===null||_0x3db517[_0xe78568(0x1c3)]===''),_0x3e8504['push'](_0x32bc3f[_0xe78568(0x1c3)]!==null&&_0x32bc3f['endpointUrlRaw']!==''&&(_0x3db517[_0xe78568(0x1c3)]===null||_0x3db517[_0xe78568(0x1c3)]===''))),{'allMatch':_0x5bf788[_0xe78568(0x1b7)](Boolean),'provesChange':_0x3e8504[_0xe78568(0x18b)](Boolean),'verifiedFields':_0x455c8a};}export function validateNotificationDeleteReadback(_0x4c3990,_0x464088,_0x38c51e){const _0x26cea9=a141_0x2ec41a;for(const [_0x4a8acc,_0x28949a]of _0x4c3990[_0x26cea9(0x1a8)]()){if(!Number['isSafeInteger'](_0x28949a['id'])||_0x28949a['id']<=0x0)throw notificationError(_0x26cea9(0x1b3),_0x26cea9(0x1c5)+(_0x4a8acc+0x1)+_0x26cea9(0x1cd));if(_0x28949a[_0x26cea9(0x17d)]!==_0x464088)throw notificationError('notification_config_response_invalid',_0x26cea9(0x1c5)+(_0x4a8acc+0x1)+'\x20has\x20an\x20invalid\x20appCode.');if(_0x28949a[_0x26cea9(0x1e2)]!==_0x38c51e)throw notificationError(_0x26cea9(0x1b3),_0x26cea9(0x1c5)+(_0x4a8acc+0x1)+_0x26cea9(0x199));}}export function safeApiFailure(_0xba0d4f,_0xa24088,_0x2bc985){const _0x3ade9d=a141_0x2ec41a;return notificationError(_0x3ade9d(0x1e5)+_0xba0d4f+'_'+(_0xa24088==='mutation'?'failed':_0xa24088+_0x3ade9d(0x1f1)),_0x3ade9d(0x1a6)+_0xba0d4f+'\x20'+_0xa24088+_0x3ade9d(0x193),_0x2bc985);}export function notificationLookupCommand(_0x478cd7,_0x5adb13){const _0x5dd064=a141_0x2ec41a;return _0x5dd064(0x176)+_0x478cd7+'\x20--type\x20'+_0x5adb13+_0x5dd064(0x178);}function validateNotificationDocument(_0x3b218c,_0x5d0cf1){const _0x56ae7b=a141_0x2ec41a;for(const _0x5e7e7d of Object[_0x56ae7b(0x1e9)](_0x3b218c)){if(FORBIDDEN_IDENTITY_FIELDS['has'](_0x5e7e7d))throw notificationError(_0x56ae7b(0x1b2),_0x56ae7b(0x197)+_0x5e7e7d+_0x56ae7b(0x190));if(!ALLOWED_INPUT_FIELDS[_0x56ae7b(0x1d9)](_0x5e7e7d))throw notificationError(_0x56ae7b(0x1d5),_0x56ae7b(0x1c2)+_0x5e7e7d+'\x22.');}if(_0x5d0cf1==='update'&&Object[_0x56ae7b(0x1e9)](_0x3b218c)['length']===0x0)throw notificationError(_0x56ae7b(0x1e8),_0x56ae7b(0x1af));const _0x8f1b49={};if(hasOwn(_0x3b218c,_0x56ae7b(0x1c0)))_0x8f1b49[_0x56ae7b(0x1c0)]=validateRequiredString(_0x3b218c['configName'],_0x56ae7b(0x1c0),0x80);else{if(_0x5d0cf1===_0x56ae7b(0x19b))throw notificationError(_0x56ae7b(0x1ab),_0x56ae7b(0x179)+_0x56ae7b(0x1c8));}if(hasOwn(_0x3b218c,_0x56ae7b(0x1e2))){if(typeof _0x3b218c['channelType']!==_0x56ae7b(0x183))throw invalidFieldType(_0x56ae7b(0x1e2),_0x56ae7b(0x191));const _0x15a8da=_0x3b218c[_0x56ae7b(0x1e2)][_0x56ae7b(0x1e7)]();if(!NOTIFICATION_CHANNEL_TYPES[_0x56ae7b(0x1d7)](_0x15a8da))throw notificationError(_0x56ae7b(0x1d8),'Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0x56ae7b(0x1d4)](',\x20')+'.');_0x8f1b49[_0x56ae7b(0x1e2)]=_0x15a8da;}else{if(_0x5d0cf1==='create')throw notificationError('notification_config_field_required',_0x56ae7b(0x179)+_0x56ae7b(0x1f3));}for(const [_0x28b348,_0x2b3947]of[[_0x56ae7b(0x1ec),0x200],[_0x56ae7b(0x1cf),0x100]]){if(!hasOwn(_0x3b218c,_0x28b348))continue;const _0x38581a=_0x3b218c[_0x28b348];if(_0x38581a!==null&&typeof _0x38581a!=='string')throw invalidFieldType(_0x28b348,_0x56ae7b(0x1e3));if(typeof _0x38581a===_0x56ae7b(0x183)&&_0x38581a[_0x56ae7b(0x1bf)]>_0x2b3947)throw notificationError('notification_config_field_invalid',_0x56ae7b(0x197)+_0x28b348+_0x56ae7b(0x188)+_0x2b3947+_0x56ae7b(0x1e6));_0x8f1b49[_0x28b348]=_0x38581a;}if(hasOwn(_0x3b218c,_0x56ae7b(0x180))){const _0x62b5fb=_0x3b218c['channelConfig'];if(_0x62b5fb===null&&_0x5d0cf1===_0x56ae7b(0x19b))throw invalidFieldType(_0x56ae7b(0x180),'a\x20JSON\x20object');if(_0x62b5fb!==null&&!isJsonObject(_0x62b5fb))throw invalidFieldType(_0x56ae7b(0x180),_0x5d0cf1===_0x56ae7b(0x196)?_0x56ae7b(0x1c7):_0x56ae7b(0x19f));_0x62b5fb!==null&&validateChannelConfigFields(_0x8f1b49[_0x56ae7b(0x1e2)],_0x62b5fb),_0x8f1b49[_0x56ae7b(0x180)]=_0x62b5fb;}for(const _0x5a2961 of[_0x56ae7b(0x1a3),_0x56ae7b(0x1ca)]){if(!hasOwn(_0x3b218c,_0x5a2961))continue;const _0x9a5e5a=_0x3b218c[_0x5a2961];if(_0x9a5e5a!==null&&(!Number[_0x56ae7b(0x17b)](_0x9a5e5a)||_0x9a5e5a<0x0))throw notificationError('notification_config_field_invalid',_0x56ae7b(0x197)+_0x5a2961+_0x56ae7b(0x1be));_0x8f1b49[_0x5a2961]=_0x9a5e5a;}return _0x8f1b49;}function validateRequiredString(_0x24c826,_0x56927f,_0x38e5b8){const _0x14ce78=a141_0x2ec41a;if(typeof _0x24c826!==_0x14ce78(0x183))throw invalidFieldType(_0x56927f,_0x14ce78(0x1b1));const _0x8bec3e=_0x24c826[_0x14ce78(0x1e7)]();if(!_0x8bec3e)throw notificationError(_0x14ce78(0x1d8),_0x14ce78(0x197)+_0x56927f+_0x14ce78(0x1b6));if(_0x8bec3e[_0x14ce78(0x1bf)]>_0x38e5b8)throw notificationError(_0x14ce78(0x1d8),_0x14ce78(0x197)+_0x56927f+_0x14ce78(0x188)+_0x38e5b8+_0x14ce78(0x1e6));return _0x8bec3e;}function validateChannelConfigFields(_0x16313e,_0x42c0ec){const _0x43edc2=a141_0x2ec41a;if(hasOwn(_0x42c0ec,_0x43edc2(0x194)))throw forbiddenChannelConfigField(_0x43edc2(0x194));if(_0x16313e==='EMAIL')for(const _0xa2aa8e of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x42c0ec,_0xa2aa8e))throw forbiddenChannelConfigField(_0xa2aa8e);}}function forbiddenChannelConfigField(_0x56eef1){const _0x135e79=a141_0x2ec41a;return notificationError(_0x135e79(0x19a),_0x135e79(0x1bb)+_0x56eef1+_0x135e79(0x1a2));}function invalidFieldType(_0x2d2b8a,_0x275fa6){return notificationError('notification_config_field_invalid','Notification\x20JSON\x20field\x20\x22'+_0x2d2b8a+'\x22\x20must\x20be\x20'+_0x275fa6+'.');}function serializeChannelConfig(_0x475d05){return _0x475d05===null||_0x475d05===undefined?null:JSON['stringify'](_0x475d05);}function redactSensitive(_0xcd25a3){return _0xcd25a3===null||_0xcd25a3===undefined||_0xcd25a3===''?null:'<redacted>';}function requireResponseString(_0x5acce9,_0xe8e038,_0x26dea1){const _0x589cf2=a141_0x2ec41a;if(typeof _0x5acce9!==_0x589cf2(0x183)||_0x5acce9['trim']()==='')throw CliErrors[_0x589cf2(0x181)](_0x589cf2(0x1f2),_0x589cf2(0x1d3)+(_0x26dea1+0x1)+_0x589cf2(0x1f8)+_0xe8e038+'\x22.');return _0x5acce9[_0x589cf2(0x1e7)]();}function requireExactString(_0x143347,_0x5bbdb6,_0x598546){const _0x49efad=a141_0x2ec41a;if(typeof _0x143347!=='string'||_0x143347[_0x49efad(0x1e7)]()==='')throw notificationError('notification_config_response_invalid',_0x49efad(0x1a6)+_0x598546+'\x20is\x20missing\x20required\x20field\x20\x22'+_0x5bbdb6+'\x22.');return _0x143347['trim']();}function responseNullableString(_0x4cf539,_0x4d7dee,_0x5508ae){const _0x4a72e9=a141_0x2ec41a;if(_0x4cf539===undefined||_0x4cf539===null)return null;if(typeof _0x4cf539!==_0x4a72e9(0x183))throw notificationError('notification_config_response_invalid','Notification\x20config\x20'+_0x5508ae+_0x4a72e9(0x1ed)+_0x4d7dee+'\x22.');return _0x4cf539;}function responseNullableTimeout(_0x20e3c0,_0x29025b,_0x2669e0){const _0x4c11d4=a141_0x2ec41a;if(_0x20e3c0===undefined||_0x20e3c0===null)return null;if(!Number[_0x4c11d4(0x17b)](_0x20e3c0)||_0x20e3c0<0x0)throw notificationError(_0x4c11d4(0x1b3),_0x4c11d4(0x1a6)+_0x2669e0+_0x4c11d4(0x1ed)+_0x29025b+'\x22.');return _0x20e3c0;}function normalizeNullableString(_0x3092d3){return typeof _0x3092d3==='string'?_0x3092d3:null;}function isJsonObject(_0x540458){const _0x3c7de3=a141_0x2ec41a;return _0x540458!==null&&typeof _0x540458==='object'&&!Array[_0x3c7de3(0x1ba)](_0x540458);}function hasOwn(_0x69137,_0xa38a77){const _0x2625c6=a141_0x2ec41a;return Object[_0x2625c6(0x1b4)][_0x2625c6(0x186)][_0x2625c6(0x17c)](_0x69137,_0xa38a77);}async function readStdin(){const _0x15406d=a141_0x2ec41a;let _0x21680e='';process[_0x15406d(0x1d6)]['setEncoding']('utf8');for await(const _0xf103f0 of process[_0x15406d(0x1d6)])_0x21680e+=_0xf103f0;return _0x21680e;}
1
+ const a141_0x3ddf3f=a141_0x457c;(function(_0x132de8,_0x384ab1){const _0x13b511=a141_0x457c,_0x4df2e0=_0x132de8();while(!![]){try{const _0x35fc38=parseInt(_0x13b511(0x17e))/0x1+parseInt(_0x13b511(0x175))/0x2*(parseInt(_0x13b511(0x1bb))/0x3)+-parseInt(_0x13b511(0x1a8))/0x4+parseInt(_0x13b511(0x179))/0x5*(-parseInt(_0x13b511(0x1bd))/0x6)+parseInt(_0x13b511(0x173))/0x7*(-parseInt(_0x13b511(0x1d8))/0x8)+-parseInt(_0x13b511(0x1cc))/0x9+parseInt(_0x13b511(0x1d4))/0xa;if(_0x35fc38===_0x384ab1)break;else _0x4df2e0['push'](_0x4df2e0['shift']());}catch(_0x56896b){_0x4df2e0['push'](_0x4df2e0['shift']());}}}(a141_0x2ce0,0x77a63));import{readFile}from'node:fs/promises';import{APPCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{getNotificationChannelConfig}from'../../core/api-client.js';import{CliError,CliErrors}from'../../errors.js';export const NOTIFICATION_CHANNEL_TYPES=[a141_0x3ddf3f(0x180),a141_0x3ddf3f(0x1dc),a141_0x3ddf3f(0x1ca),a141_0x3ddf3f(0x19d),a141_0x3ddf3f(0x183)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;function a141_0x457c(_0x1cee39,_0x3cdf75){_0x1cee39=_0x1cee39-0x16c;const _0x2ce056=a141_0x2ce0();let _0x457c53=_0x2ce056[_0x1cee39];return _0x457c53;}export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a141_0x3ddf3f(0x1b6),a141_0x3ddf3f(0x19c),'endpointUrl',a141_0x3ddf3f(0x1e4),a141_0x3ddf3f(0x189),'connectTimeout',a141_0x3ddf3f(0x1d6)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a141_0x3ddf3f(0x18d),a141_0x3ddf3f(0x192),a141_0x3ddf3f(0x193)]),EMAIL_RECIPIENT_FIELDS=new Set([a141_0x3ddf3f(0x16f),'recipients',a141_0x3ddf3f(0x1b9),a141_0x3ddf3f(0x1e0),a141_0x3ddf3f(0x16c),'subjectPrefix',a141_0x3ddf3f(0x1cb),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':'file','type':a141_0x3ddf3f(0x1b3),'required':![],'description':a141_0x3ddf3f(0x188)},{'name':a141_0x3ddf3f(0x187),'type':'boolean','required':![],'default':![],'description':a141_0x3ddf3f(0x1c3)},{'name':a141_0x3ddf3f(0x1c2),'type':a141_0x3ddf3f(0x1b3),'required':![],'description':a141_0x3ddf3f(0x195)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a141_0x3ddf3f(0x1ae),'required':!![],'description':'Application-level\x20notification\x20config\x20ID'};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x22bbc2,_0x657123,_0x329852){return new CliError(_0x22bbc2,0x1,_0x657123,_0x329852);}export function readNotificationId(_0xb663b5){const _0xf50abd=a141_0x3ddf3f,_0x57505d=_0xb663b5['num']('id');if(!Number[_0xf50abd(0x1da)](_0x57505d)||_0x57505d<=0x0)throw notificationError(_0xf50abd(0x1a0),'--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.');return _0x57505d;}export function requireNotificationExplicitYes(_0x1aeaae){const _0x53db62=a141_0x3ddf3f;if(_0x1aeaae[_0x53db62(0x18e)](_0x53db62(0x190))||_0x1aeaae[_0x53db62(0x18e)]('yes'))return;throw notificationError('notification_config_confirmation_required',_0x53db62(0x199),_0x53db62(0x1b5));}export function readNotificationChannelType(_0x3c4ac2,_0x4315db=a141_0x3ddf3f(0x1ec),_0x546c43='EMAIL'){const _0x582083=a141_0x3ddf3f,_0x5307f6=_0x3c4ac2['str'](_0x4315db)[_0x582083(0x17d)]()||_0x546c43;if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x5307f6))throw CliErrors[_0x582083(0x1e1)]('Invalid\x20--'+_0x4315db+':\x20'+_0x5307f6,'Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0x582083(0x1d9)](',\x20')+'.');return _0x5307f6;}export function assertSingleNotificationSource(_0x5d32c4){const _0xbb7645=a141_0x3ddf3f,_0x1cccf1=[],_0x5f376e=_0x5d32c4['str'](_0xbb7645(0x1ad))[_0xbb7645(0x17d)]();if(_0x5f376e)_0x1cccf1[_0xbb7645(0x1b1)]({'kind':_0xbb7645(0x1ad),'path':_0x5f376e});if(_0x5d32c4[_0xbb7645(0x18e)](_0xbb7645(0x187)))_0x1cccf1[_0xbb7645(0x1b1)]({'kind':_0xbb7645(0x187)});const _0x533f81=_0x5d32c4[_0xbb7645(0x17a)](_0xbb7645(0x1c2))[_0xbb7645(0x17d)]();if(_0x533f81)_0x1cccf1[_0xbb7645(0x1b1)]({'kind':_0xbb7645(0x1e8),'name':_0x533f81});if(_0x1cccf1['length']===0x0)throw CliErrors[_0xbb7645(0x1e1)]('Missing\x20notification\x20JSON\x20source.',_0xbb7645(0x1d3));if(_0x1cccf1[_0xbb7645(0x185)]>0x1)throw CliErrors[_0xbb7645(0x1e1)](_0xbb7645(0x197),'Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.');return _0x1cccf1[0x0];}export async function readNotificationDocument(_0x2f76d2,_0x3acf56){const _0x2c68ce=a141_0x3ddf3f,_0x2f226d=assertSingleNotificationSource(_0x2f76d2),_0x140187=_0x2f226d[_0x2c68ce(0x1e5)]===_0x2c68ce(0x1ad)?'file\x20'+_0x2f226d['path']:_0x2f226d[_0x2c68ce(0x1e5)]===_0x2c68ce(0x1e8)?_0x2c68ce(0x18a)+_0x2f226d[_0x2c68ce(0x19f)]:_0x2c68ce(0x187);let _0x1fe1b9;try{if(_0x2f226d['kind']===_0x2c68ce(0x1ad))_0x1fe1b9=await readFile(_0x2f226d[_0x2c68ce(0x1ee)],_0x2c68ce(0x1d7));else{if(_0x2f226d[_0x2c68ce(0x1e5)]===_0x2c68ce(0x1e8)){if(!(_0x2f226d[_0x2c68ce(0x19f)]in process.env))throw notificationError(_0x2c68ce(0x1c9),_0x2c68ce(0x1a1)+_0x2f226d['name']);_0x1fe1b9=process.env[_0x2f226d.name]??'';}else _0x1fe1b9=await readStdin();}}catch(_0x1a6bac){if(_0x1a6bac instanceof CliError)throw _0x1a6bac;throw notificationError('notification_config_source_unavailable',_0x2c68ce(0x1a7)+_0x140187+'.');}let _0x5a339b;try{_0x5a339b=JSON[_0x2c68ce(0x1c6)](_0x1fe1b9);}catch{throw notificationError(_0x2c68ce(0x1de),_0x2c68ce(0x1c0)+_0x140187+'\x20is\x20invalid.',_0x2c68ce(0x196));}if(!isJsonObject(_0x5a339b))throw notificationError(_0x2c68ce(0x1de),_0x2c68ce(0x1c0)+_0x140187+_0x2c68ce(0x1ea));return validateNotificationDocument(_0x5a339b,_0x3acf56);}export function projectNotificationListConfig(_0x284598,_0x375003){const _0x671e8d=a141_0x3ddf3f;return{'id':typeof _0x284598['id']===_0x671e8d(0x1ae)?_0x284598['id']:null,'configCode':requireResponseString(_0x284598[_0x671e8d(0x192)],'configCode',_0x375003),'configName':requireResponseString(_0x284598[_0x671e8d(0x1b6)],_0x671e8d(0x1b6),_0x375003),'channelType':requireResponseString(_0x284598[_0x671e8d(0x19c)],'channelType',_0x375003),'description':normalizeNullableString(_0x284598['description']),'createTime':normalizeNullableString(_0x284598[_0x671e8d(0x1e2)]),'updateTime':normalizeNullableString(_0x284598[_0x671e8d(0x1ba)])};}export function normalizeExactNotificationConfig(_0x24f549,_0xfce77e,_0x49838f){const _0x5c6839=a141_0x3ddf3f;if(!Number['isSafeInteger'](_0x24f549['id'])||_0x24f549['id']!==_0xfce77e)throw notificationError(_0x5c6839(0x1a5),_0x5c6839(0x1d1)+_0xfce77e+'.');if(_0x24f549['appCode']!==_0x49838f)throw notificationError(_0x5c6839(0x1a5),_0x5c6839(0x17b)+_0xfce77e+_0x5c6839(0x174));const _0x56ab1e=requireExactString(_0x24f549[_0x5c6839(0x1b6)],'configName',_0xfce77e),_0x29f454=requireExactString(_0x24f549[_0x5c6839(0x192)],_0x5c6839(0x192),_0xfce77e),_0x1de247=requireExactString(_0x24f549[_0x5c6839(0x19c)],_0x5c6839(0x19c),_0xfce77e);if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x1de247))throw notificationError(_0x5c6839(0x1a5),_0x5c6839(0x17b)+_0xfce77e+_0x5c6839(0x1eb));const _0x497256=responseNullableString(_0x24f549['endpointUrl'],_0x5c6839(0x1af),_0xfce77e),_0xd7b905=responseNullableString(_0x24f549[_0x5c6839(0x1e4)],_0x5c6839(0x1e4),_0xfce77e),_0x2e3e71=responseNullableString(_0x24f549[_0x5c6839(0x189)],_0x5c6839(0x189),_0xfce77e),_0x394fee=responseNullableTimeout(_0x24f549['connectTimeout'],_0x5c6839(0x1b2),_0xfce77e),_0x47ed81=responseNullableTimeout(_0x24f549[_0x5c6839(0x1d6)],'readTimeout',_0xfce77e);return{'id':_0xfce77e,'appCode':_0x49838f,'configCode':_0x29f454,'configName':_0x56ab1e,'channelType':_0x1de247,'endpointUrl':redactSensitive(_0x497256),'channelConfig':redactSensitive(_0xd7b905),'description':_0x2e3e71,'connectTimeout':_0x394fee,'readTimeout':_0x47ed81,'endpointUrlRaw':_0x497256,'channelConfigRaw':_0xd7b905};}export async function requireExactNotificationConfig(_0x326783,_0x41e296,_0x1c6225){const _0x3f1a79=a141_0x3ddf3f;let _0xfd425;try{_0xfd425=await getNotificationChannelConfig(_0x41e296,_0x326783);}catch{throw safeApiFailure(_0x1c6225,_0x3f1a79(0x1aa),_0x3f1a79(0x1a2)+_0x326783+_0x3f1a79(0x178));}return normalizeExactNotificationConfig(_0xfd425,_0x41e296,_0x326783);}export function projectNotificationConfig(_0x1a018e){const _0x53bd8b=a141_0x3ddf3f;return{'id':_0x1a018e['id']??null,'appCode':_0x1a018e[_0x53bd8b(0x18d)],'configCode':_0x1a018e[_0x53bd8b(0x192)]??null,'configName':_0x1a018e[_0x53bd8b(0x1b6)],'channelType':_0x1a018e[_0x53bd8b(0x19c)],'endpointUrl':redactSensitive(_0x1a018e[_0x53bd8b(0x1af)]),'channelConfig':redactSensitive(_0x1a018e[_0x53bd8b(0x1e4)]),'description':_0x1a018e[_0x53bd8b(0x189)]??null,'connectTimeout':_0x1a018e[_0x53bd8b(0x1b2)]??null,'readTimeout':_0x1a018e[_0x53bd8b(0x1d6)]??null};}export function notificationSelector(_0xb57d95){const _0x455a5c=a141_0x3ddf3f;return{'appCode':_0xb57d95[_0x455a5c(0x18d)],'id':_0xb57d95['id'],'configCode':_0xb57d95['configCode'],'configName':_0xb57d95[_0x455a5c(0x1b6)],'channelType':_0xb57d95[_0x455a5c(0x19c)]};}export function createMutationInput(_0x2e6076,_0x4cba70){const _0x49aa06=a141_0x3ddf3f;return{'appCode':_0x2e6076,'configName':_0x4cba70[_0x49aa06(0x1b6)],'channelType':_0x4cba70[_0x49aa06(0x19c)],...hasOwn(_0x4cba70,_0x49aa06(0x1af))?{'endpointUrl':_0x4cba70[_0x49aa06(0x1af)]}:{},...hasOwn(_0x4cba70,_0x49aa06(0x1e4))?{'channelConfig':serializeChannelConfig(_0x4cba70[_0x49aa06(0x1e4)])}:{},...hasOwn(_0x4cba70,_0x49aa06(0x189))?{'description':_0x4cba70[_0x49aa06(0x189)]}:{},...hasOwn(_0x4cba70,_0x49aa06(0x1b2))?{'connectTimeout':_0x4cba70[_0x49aa06(0x1b2)]}:{},...hasOwn(_0x4cba70,_0x49aa06(0x1d6))?{'readTimeout':_0x4cba70[_0x49aa06(0x1d6)]}:{}};}export function mergeUpdateInput(_0x2f640f,_0x3b1e43){const _0x38f9d3=a141_0x3ddf3f;return{'id':_0x2f640f['id'],'appCode':_0x2f640f[_0x38f9d3(0x18d)],'configName':_0x3b1e43['configName']??_0x2f640f[_0x38f9d3(0x1b6)],'channelType':_0x3b1e43['channelType']??_0x2f640f['channelType'],'endpointUrl':hasOwn(_0x3b1e43,_0x38f9d3(0x1af))?_0x3b1e43['endpointUrl']:_0x2f640f[_0x38f9d3(0x19a)],'channelConfig':hasOwn(_0x3b1e43,_0x38f9d3(0x1e4))?serializeChannelConfig(_0x3b1e43[_0x38f9d3(0x1e4)]):_0x2f640f[_0x38f9d3(0x1c5)],'description':hasOwn(_0x3b1e43,'description')?_0x3b1e43[_0x38f9d3(0x189)]:_0x2f640f[_0x38f9d3(0x189)],'connectTimeout':hasOwn(_0x3b1e43,_0x38f9d3(0x1b2))?_0x3b1e43[_0x38f9d3(0x1b2)]:_0x2f640f[_0x38f9d3(0x1b2)],'readTimeout':hasOwn(_0x3b1e43,'readTimeout')?_0x3b1e43['readTimeout']:_0x2f640f['readTimeout']};}export function plannedUpdateProjection(_0x44aa4a,_0x33e0be){const _0x4e118f=a141_0x3ddf3f;return projectNotificationConfig({'id':_0x44aa4a['id'],'appCode':_0x44aa4a[_0x4e118f(0x18d)],'configCode':_0x44aa4a['configCode'],'configName':_0x33e0be[_0x4e118f(0x1b6)]??_0x44aa4a[_0x4e118f(0x1b6)],'channelType':_0x33e0be[_0x4e118f(0x19c)]??_0x44aa4a['channelType'],'endpointUrl':hasOwn(_0x33e0be,'endpointUrl')?_0x33e0be[_0x4e118f(0x1af)]:_0x44aa4a[_0x4e118f(0x19a)],'channelConfig':hasOwn(_0x33e0be,_0x4e118f(0x1e4))?_0x33e0be[_0x4e118f(0x1e4)]:_0x44aa4a['channelConfigRaw'],'description':hasOwn(_0x33e0be,_0x4e118f(0x189))?_0x33e0be[_0x4e118f(0x189)]:_0x44aa4a[_0x4e118f(0x189)],'connectTimeout':hasOwn(_0x33e0be,'connectTimeout')?_0x33e0be[_0x4e118f(0x1b2)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x44aa4a[_0x4e118f(0x1b2)],'readTimeout':hasOwn(_0x33e0be,_0x4e118f(0x1d6))?_0x33e0be[_0x4e118f(0x1d6)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x44aa4a[_0x4e118f(0x1d6)]});}export function requestedSafeFieldsMatch(_0x49f769,_0xe30008,_0x21cea0){const _0xff1574=a141_0x3ddf3f,_0x22cc28=[],_0x17b21e=[],_0x130452=[];for(const _0x4ca658 of[_0xff1574(0x1b6),_0xff1574(0x19c),_0xff1574(0x189)]){if(!hasOwn(_0x21cea0,_0x4ca658))continue;_0x130452['push'](_0x4ca658),_0x22cc28[_0xff1574(0x1b1)](_0xe30008[_0x4ca658]===_0x21cea0[_0x4ca658]),_0x17b21e[_0xff1574(0x1b1)](_0x49f769[_0x4ca658]!==_0x21cea0[_0x4ca658]&&_0xe30008[_0x4ca658]===_0x21cea0[_0x4ca658]);}for(const _0x462250 of['connectTimeout',_0xff1574(0x1d6)]){if(!hasOwn(_0x21cea0,_0x462250))continue;const _0x5c9528=_0x21cea0[_0x462250]??(_0x462250===_0xff1574(0x1b2)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x130452[_0xff1574(0x1b1)](_0x462250),_0x22cc28[_0xff1574(0x1b1)](_0xe30008[_0x462250]===_0x5c9528),_0x17b21e[_0xff1574(0x1b1)](_0x49f769[_0x462250]!==_0x5c9528&&_0xe30008[_0x462250]===_0x5c9528);}return hasOwn(_0x21cea0,_0xff1574(0x1af))&&_0x21cea0[_0xff1574(0x1af)]===null&&(_0x130452[_0xff1574(0x1b1)](_0xff1574(0x1e3)),_0x22cc28[_0xff1574(0x1b1)](_0xe30008[_0xff1574(0x19a)]===null||_0xe30008[_0xff1574(0x19a)]===''),_0x17b21e[_0xff1574(0x1b1)](_0x49f769[_0xff1574(0x19a)]!==null&&_0x49f769[_0xff1574(0x19a)]!==''&&(_0xe30008[_0xff1574(0x19a)]===null||_0xe30008[_0xff1574(0x19a)]===''))),{'allMatch':_0x22cc28[_0xff1574(0x171)](Boolean),'provesChange':_0x17b21e[_0xff1574(0x18c)](Boolean),'verifiedFields':_0x130452};}export function validateNotificationDeleteReadback(_0x5c0f1c,_0x336059,_0x5cac76){const _0x76035b=a141_0x3ddf3f;for(const [_0x2e0169,_0x50631a]of _0x5c0f1c[_0x76035b(0x1cd)]()){if(!Number[_0x76035b(0x1da)](_0x50631a['id'])||_0x50631a['id']<=0x0)throw notificationError(_0x76035b(0x1a5),_0x76035b(0x1c8)+(_0x2e0169+0x1)+_0x76035b(0x1a9));if(_0x50631a['appCode']!==_0x336059)throw notificationError(_0x76035b(0x1a5),_0x76035b(0x1c8)+(_0x2e0169+0x1)+_0x76035b(0x1b7));if(_0x50631a['channelType']!==_0x5cac76)throw notificationError(_0x76035b(0x1a5),'Notification\x20config\x20list\x20item\x20'+(_0x2e0169+0x1)+_0x76035b(0x1c1));}}export function safeApiFailure(_0x35310d,_0x403247,_0x1e4719){const _0x4789b9=a141_0x3ddf3f;return notificationError('notification_config_'+_0x35310d+'_'+(_0x403247==='mutation'?_0x4789b9(0x1a6):_0x403247+_0x4789b9(0x182)),_0x4789b9(0x17b)+_0x35310d+'\x20'+_0x403247+_0x4789b9(0x177),_0x1e4719);}export function notificationLookupCommand(_0x11cfbd,_0x351baf){const _0x2af9de=a141_0x3ddf3f;return'rabetbase\x20notification\x20config-list\x20--appcode\x20'+_0x11cfbd+_0x2af9de(0x1d0)+_0x351baf+_0x2af9de(0x1ed);}function validateNotificationDocument(_0x568969,_0x392af7){const _0x3f052c=a141_0x3ddf3f;for(const _0x1b306e of Object[_0x3f052c(0x1dd)](_0x568969)){if(FORBIDDEN_IDENTITY_FIELDS['has'](_0x1b306e))throw notificationError(_0x3f052c(0x194),_0x3f052c(0x1a3)+_0x1b306e+'\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.');if(!ALLOWED_INPUT_FIELDS[_0x3f052c(0x1e6)](_0x1b306e))throw notificationError(_0x3f052c(0x1d2),_0x3f052c(0x19b)+_0x1b306e+'\x22.');}if(_0x392af7===_0x3f052c(0x1c4)&&Object[_0x3f052c(0x1dd)](_0x568969)[_0x3f052c(0x185)]===0x0)throw notificationError(_0x3f052c(0x181),'Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.');const _0x51a370={};if(hasOwn(_0x568969,'configName'))_0x51a370[_0x3f052c(0x1b6)]=validateRequiredString(_0x568969[_0x3f052c(0x1b6)],_0x3f052c(0x1b6),0x80);else{if(_0x392af7===_0x3f052c(0x1ce))throw notificationError('notification_config_field_required',_0x3f052c(0x176)+_0x3f052c(0x1bf));}if(hasOwn(_0x568969,_0x3f052c(0x19c))){if(typeof _0x568969[_0x3f052c(0x19c)]!=='string')throw invalidFieldType(_0x3f052c(0x19c),_0x3f052c(0x1ac));const _0x1d9a51=_0x568969[_0x3f052c(0x19c)]['trim']();if(!NOTIFICATION_CHANNEL_TYPES[_0x3f052c(0x1be)](_0x1d9a51))throw notificationError('notification_config_field_invalid',_0x3f052c(0x186),_0x3f052c(0x1e9)+NOTIFICATION_CHANNEL_TYPES[_0x3f052c(0x1d9)](',\x20')+'.');_0x51a370[_0x3f052c(0x19c)]=_0x1d9a51;}else{if(_0x392af7===_0x3f052c(0x1ce))throw notificationError(_0x3f052c(0x16d),_0x3f052c(0x176)+_0x3f052c(0x1a4));}for(const [_0x36ff04,_0x582456]of[[_0x3f052c(0x1af),0x200],[_0x3f052c(0x189),0x100]]){if(!hasOwn(_0x568969,_0x36ff04))continue;const _0x2ac6ec=_0x568969[_0x36ff04];if(_0x2ac6ec!==null&&typeof _0x2ac6ec!==_0x3f052c(0x1b3))throw invalidFieldType(_0x36ff04,_0x3f052c(0x1cf));if(typeof _0x2ac6ec===_0x3f052c(0x1b3)&&_0x2ac6ec[_0x3f052c(0x185)]>_0x582456)throw notificationError(_0x3f052c(0x1bc),_0x3f052c(0x1a3)+_0x36ff04+'\x22\x20cannot\x20exceed\x20'+_0x582456+_0x3f052c(0x1b0));_0x51a370[_0x36ff04]=_0x2ac6ec;}if(hasOwn(_0x568969,_0x3f052c(0x1e4))){const _0x368eac=_0x568969[_0x3f052c(0x1e4)];if(_0x368eac===null&&_0x392af7==='create')throw invalidFieldType('channelConfig',_0x3f052c(0x191));if(_0x368eac!==null&&!isJsonObject(_0x368eac))throw invalidFieldType('channelConfig',_0x392af7==='update'?_0x3f052c(0x172):_0x3f052c(0x191));_0x368eac!==null&&validateChannelConfigFields(_0x51a370[_0x3f052c(0x19c)],_0x368eac),_0x51a370[_0x3f052c(0x1e4)]=_0x368eac;}for(const _0x39bdac of['connectTimeout',_0x3f052c(0x1d6)]){if(!hasOwn(_0x568969,_0x39bdac))continue;const _0x5362da=_0x568969[_0x39bdac];if(_0x5362da!==null&&(!Number[_0x3f052c(0x1da)](_0x5362da)||_0x5362da<0x0))throw notificationError('notification_config_field_invalid',_0x3f052c(0x1a3)+_0x39bdac+_0x3f052c(0x16e));_0x51a370[_0x39bdac]=_0x5362da;}return _0x51a370;}function validateRequiredString(_0x48a1ac,_0x1fbfab,_0x483b1c){const _0x5e44f7=a141_0x3ddf3f;if(typeof _0x48a1ac!==_0x5e44f7(0x1b3))throw invalidFieldType(_0x1fbfab,_0x5e44f7(0x170));const _0x5ab845=_0x48a1ac[_0x5e44f7(0x17d)]();if(!_0x5ab845)throw notificationError(_0x5e44f7(0x1bc),_0x5e44f7(0x1a3)+_0x1fbfab+_0x5e44f7(0x18f));if(_0x5ab845[_0x5e44f7(0x185)]>_0x483b1c)throw notificationError('notification_config_field_invalid',_0x5e44f7(0x1a3)+_0x1fbfab+_0x5e44f7(0x184)+_0x483b1c+_0x5e44f7(0x1b0));return _0x5ab845;}function validateChannelConfigFields(_0x1bcdbe,_0x481f0f){const _0x6ad1b2=a141_0x3ddf3f;if(hasOwn(_0x481f0f,_0x6ad1b2(0x1e7)))throw forbiddenChannelConfigField(_0x6ad1b2(0x1e7));if(_0x1bcdbe===_0x6ad1b2(0x180))for(const _0x14ff70 of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x481f0f,_0x14ff70))throw forbiddenChannelConfigField(_0x14ff70);}}function forbiddenChannelConfigField(_0x3c4ab0){const _0x5283d2=a141_0x3ddf3f;return notificationError('notification_config_channel_field_forbidden',_0x5283d2(0x17c)+_0x3c4ab0+_0x5283d2(0x1db));}function invalidFieldType(_0x597431,_0x5170a7){const _0x2597bb=a141_0x3ddf3f;return notificationError('notification_config_field_invalid',_0x2597bb(0x1a3)+_0x597431+_0x2597bb(0x1c7)+_0x5170a7+'.');}function serializeChannelConfig(_0x1d3436){return _0x1d3436===null||_0x1d3436===undefined?null:JSON['stringify'](_0x1d3436);}function redactSensitive(_0x4a6a20){const _0x1ce5f7=a141_0x3ddf3f;return _0x4a6a20===null||_0x4a6a20===undefined||_0x4a6a20===''?null:_0x1ce5f7(0x19e);}function requireResponseString(_0x498f3d,_0x3e8b2a,_0x3565a0){const _0xa60565=a141_0x3ddf3f;if(typeof _0x498f3d!==_0xa60565(0x1b3)||_0x498f3d[_0xa60565(0x17d)]()==='')throw CliErrors[_0xa60565(0x18b)](_0xa60565(0x1d5),_0xa60565(0x1b8)+(_0x3565a0+0x1)+'\x20is\x20missing\x20required\x20field\x20\x22'+_0x3e8b2a+'\x22.');return _0x498f3d['trim']();}function requireExactString(_0x480bee,_0x4faf3d,_0x2d113f){const _0x3a087b=a141_0x3ddf3f;if(typeof _0x480bee!==_0x3a087b(0x1b3)||_0x480bee[_0x3a087b(0x17d)]()==='')throw notificationError('notification_config_response_invalid','Notification\x20config\x20'+_0x2d113f+_0x3a087b(0x17f)+_0x4faf3d+'\x22.');return _0x480bee['trim']();}function responseNullableString(_0x34c969,_0x3f1f80,_0x521c7e){const _0x8ef68e=a141_0x3ddf3f;if(_0x34c969===undefined||_0x34c969===null)return null;if(typeof _0x34c969!=='string')throw notificationError(_0x8ef68e(0x1a5),_0x8ef68e(0x17b)+_0x521c7e+'\x20has\x20invalid\x20field\x20\x22'+_0x3f1f80+'\x22.');return _0x34c969;}function responseNullableTimeout(_0x3a3378,_0x6cc81b,_0x268654){const _0x35bada=a141_0x3ddf3f;if(_0x3a3378===undefined||_0x3a3378===null)return null;if(!Number['isSafeInteger'](_0x3a3378)||_0x3a3378<0x0)throw notificationError(_0x35bada(0x1a5),_0x35bada(0x17b)+_0x268654+'\x20has\x20invalid\x20field\x20\x22'+_0x6cc81b+'\x22.');return _0x3a3378;}function normalizeNullableString(_0xd7160d){const _0x578c34=a141_0x3ddf3f;return typeof _0xd7160d===_0x578c34(0x1b3)?_0xd7160d:null;}function isJsonObject(_0x167e6f){const _0x33c0a3=a141_0x3ddf3f;return _0x167e6f!==null&&typeof _0x167e6f===_0x33c0a3(0x1ab)&&!Array['isArray'](_0x167e6f);}function hasOwn(_0x26c022,_0x4af721){const _0x318c6f=a141_0x3ddf3f;return Object[_0x318c6f(0x1b4)]['hasOwnProperty'][_0x318c6f(0x198)](_0x26c022,_0x4af721);}function a141_0x2ce0(){const _0x28fb15=['23814810CEiLrs','Invalid\x20notification\x20config\x20response.','readTimeout','utf8','2177264dfPTyZ','join','isSafeInteger','\x22\x20is\x20forbidden.','FEISHU','keys','notification_config_json_invalid','setEncoding','bccList','validation','createTime','endpointUrl:null','channelConfig','kind','has','messageTemplate','env','Allowed\x20values:\x20','\x20must\x20be\x20an\x20object.','\x20has\x20an\x20unsupported\x20channelType.','type','\x20--format\x20compress','path','replyTo','notification_config_field_required','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','emailTargets','a\x20non-empty\x20string','every','a\x20JSON\x20object\x20or\x20null','7ghvhbJ','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','62014BqmeVp','Create\x20JSON\x20requires\x20field\x20','\x20failed.','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','190425rtkNEG','str','Notification\x20config\x20','Notification\x20JSON\x20channelConfig\x20field\x20\x22','trim','188585WhgfLC','\x20is\x20missing\x20required\x20field\x20\x22','EMAIL','notification_config_update_empty','_unavailable','WEBHOOK','\x22\x20cannot\x20exceed\x20','length','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','stdin','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','description','environment\x20variable\x20','apiError','some','appCode','bool','\x22\x20must\x20be\x20a\x20non-empty\x20string.','dry-run','a\x20JSON\x20object','configCode','channelCode','notification_config_field_forbidden','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','Notification\x20JSON\x20source\x20is\x20ambiguous.','call','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','endpointUrlRaw','Unknown\x20notification\x20JSON\x20field\x20\x22','channelType','WECOM','<redacted>','name','notification_config_id_invalid','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','Notification\x20JSON\x20field\x20\x22','\x22channelType\x22.','notification_config_response_invalid','failed','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','2172300cJTXqT','\x20has\x20an\x20invalid\x20id.','preflight','object','a\x20supported\x20string','file','number','endpointUrl','\x20characters.','push','connectTimeout','string','prototype','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','configName','\x20has\x20an\x20invalid\x20appCode.','Item\x20','ccList','updateTime','33Kfddqq','notification_config_field_invalid','102hDUsgS','includes','\x22configName\x22.','Notification\x20JSON\x20from\x20','\x20has\x20an\x20invalid\x20channelType.','from-env','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','update','channelConfigRaw','parse','\x22\x20must\x20be\x20','Notification\x20config\x20list\x20item\x20','notification_config_source_unavailable','DINGTALK','fromName','8625438yVHttR','entries','create','a\x20string\x20or\x20null','\x20--type\x20','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','notification_config_field_unknown','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.'];a141_0x2ce0=function(){return _0x28fb15;};return a141_0x2ce0();}async function readStdin(){const _0x3aecaf=a141_0x3ddf3f;let _0x2805f0='';process[_0x3aecaf(0x187)][_0x3aecaf(0x1df)](_0x3aecaf(0x1d7));for await(const _0x40d9f2 of process[_0x3aecaf(0x187)])_0x2805f0+=_0x40d9f2;return _0x2805f0;}
@@ -1 +1 @@
1
- const a142_0x2c0e50=a142_0x588c;(function(_0x389e91,_0x4e5402){const _0x45acf5=a142_0x588c,_0x328f5b=_0x389e91();while(!![]){try{const _0xa00977=parseInt(_0x45acf5(0x129))/0x1*(-parseInt(_0x45acf5(0x134))/0x2)+parseInt(_0x45acf5(0x14f))/0x3*(parseInt(_0x45acf5(0x12c))/0x4)+-parseInt(_0x45acf5(0x138))/0x5*(-parseInt(_0x45acf5(0x11d))/0x6)+parseInt(_0x45acf5(0x11f))/0x7*(parseInt(_0x45acf5(0x12b))/0x8)+-parseInt(_0x45acf5(0x14d))/0x9*(-parseInt(_0x45acf5(0x14c))/0xa)+parseInt(_0x45acf5(0x120))/0xb*(-parseInt(_0x45acf5(0x130))/0xc)+-parseInt(_0x45acf5(0x127))/0xd;if(_0xa00977===_0x4e5402)break;else _0x328f5b['push'](_0x328f5b['shift']());}catch(_0x4d5f45){_0x328f5b['push'](_0x328f5b['shift']());}}}(a142_0x43fa,0x28207));import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';import{queryDevelopmentFileUrl,recognizeDevelopmentOcr,uploadDevelopmentFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';function a142_0x588c(_0x48bc9d,_0x365c55){_0x48bc9d=_0x48bc9d-0x117;const _0x43fa84=a142_0x43fa();let _0x588c54=_0x43fa84[_0x48bc9d];return _0x588c54;}const SUPPORTED_SCENES=[a142_0x2c0e50(0x135),a142_0x2c0e50(0x152),a142_0x2c0e50(0x14a),a142_0x2c0e50(0x13f)],SCENE_TO_LEGACY_TYPE={'invoice':a142_0x2c0e50(0x13a),'general':a142_0x2c0e50(0x119),'form':'Table','idCard':a142_0x2c0e50(0x14b)},SCENE_FLAG={'name':a142_0x2c0e50(0x11c),'type':a142_0x2c0e50(0x145),'required':!![],'enum':[...SUPPORTED_SCENES],'description':a142_0x2c0e50(0x142)},IMAGE_FILE_FLAG={'name':a142_0x2c0e50(0x149),'type':'string','description':a142_0x2c0e50(0x121)},IMAGE_URL_FLAG={'name':a142_0x2c0e50(0x140),'type':a142_0x2c0e50(0x145),'description':a142_0x2c0e50(0x13d)};function normalizeScene(_0x2abc79){const _0x147034=a142_0x2c0e50,_0x11551e=_0x2abc79[_0x147034(0x12a)]()[_0x147034(0x124)]();if(_0x11551e===_0x147034(0x151))return _0x147034(0x13f);if(_0x11551e===_0x147034(0x135)||_0x11551e===_0x147034(0x152)||_0x11551e==='form')return _0x11551e;throw CliErrors[_0x147034(0x13c)](_0x147034(0x13b)+_0x2abc79+_0x147034(0x11a)+SUPPORTED_SCENES[_0x147034(0x133)](',\x20'));}function a142_0x43fa(){const _0x4c40aa=['image-file','form','IdCard','5860KTXsHx','4482eLrxKX','Preview:\x20recognize\x20','28347DEhyRN','<fileUrl\x20returned\x20by\x20/smartapi/common/queryFileUrl>','idcard','general','Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','count','\x20OCR','Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.','General','.\x20Supported\x20scenes:\x20','filePath','scene','570nNoqbO','<filePath\x20returned\x20by\x20/smartapi/common/uploadFile>','91ghZTCx','7117rhrEbW','Local\x20image\x20or\x20PDF\x20file;\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','fileUrl','GET','toLowerCase','File\x20URL\x20response\x20missing\x20fileUrl.','fileName','6614205YduXOD','path','1ePOShs','trim','202184Pcvcjz','12EobtFB','Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20','/smartapi/common/uploadFile','str','48DQkooF','toString','imageUrl','join','104254amsWcy','invoice','\x20OCR\x20from\x20URL','recognize','4165IZlhrm','POST','Invoice','Unsupported\x20OCR\x20scene:\x20','validation','Publicly\x20accessible\x20image\x20or\x20file\x20URL','read','idCard','image-url','/smartapi/ocr/recognize-text?','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','appCode','ocr','string','apiError','length','File\x20upload\x20response\x20missing\x20filePath.'];a142_0x43fa=function(){return _0x4c40aa;};return a142_0x43fa();}function selectedInputs(_0x1d773c){const _0x46aa6c=a142_0x2c0e50,_0x5698f1=_0x1d773c[_0x46aa6c(0x12f)](_0x46aa6c(0x149))[_0x46aa6c(0x12a)](),_0x2e3c14=_0x1d773c['str'](_0x46aa6c(0x140))[_0x46aa6c(0x12a)]();return{'imageFile':_0x5698f1,'imageUrl':_0x2e3c14,'count':[_0x5698f1,_0x2e3c14]['filter'](Boolean)[_0x46aa6c(0x147)]};}function validateInputSelection(_0x244876){const _0x567156=a142_0x2c0e50,_0x12df23=selectedInputs(_0x244876);if(_0x12df23[_0x567156(0x154)]!==0x1)throw CliErrors[_0x567156(0x13c)](_0x567156(0x118));return _0x12df23;}function withScene(_0x547692,_0x26317b,_0x459d90){const _0x954dbe=a142_0x2c0e50;return{..._0x547692,'scene':_0x26317b,..._0x459d90?{'sourceFile':{'fileName':_0x459d90[_0x954dbe(0x126)],'filePath':_0x459d90[_0x954dbe(0x11b)]}}:{}};}const ocrRecognize={'service':a142_0x2c0e50(0x144),'command':a142_0x2c0e50(0x137),'description':a142_0x2c0e50(0x153),'risk':a142_0x2c0e50(0x13e),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x44d0d5){const _0x46afe8=a142_0x2c0e50,_0x211468=normalizeScene(_0x44d0d5[_0x46afe8(0x12f)](_0x46afe8(0x11c))),_0x31c5a0=SCENE_TO_LEGACY_TYPE[_0x211468],_0xea31bc=validateInputSelection(_0x44d0d5);if(_0xea31bc['imageUrl']){const _0x172b94=new URLSearchParams({'url':_0xea31bc['imageUrl'],'type':_0x31c5a0,'appCode':_0x44d0d5[_0x46afe8(0x143)]});return{'method':_0x46afe8(0x123),'url':_0x46afe8(0x141)+_0x172b94[_0x46afe8(0x131)](),'description':_0x46afe8(0x14e)+_0x211468+_0x46afe8(0x136)};}const _0x2783d=requireDevelopmentUploadFile(_0xea31bc['imageFile'],'image-file');return{'method':'POST','url':_0x46afe8(0x12e),'body':{'steps':[{'method':_0x46afe8(0x139),'url':'/smartapi/common/uploadFile','body':{'appCode':_0x44d0d5[_0x46afe8(0x143)],'multipart':{'file':_0x2783d}}},{'method':_0x46afe8(0x139),'url':'/smartapi/common/queryFileUrl','body':{'filePath':_0x46afe8(0x11e),'downloadFlag':![]}},{'method':_0x46afe8(0x123),'url':'/smartapi/ocr/recognize-text','query':{'appCode':_0x44d0d5[_0x46afe8(0x143)],'url':_0x46afe8(0x150),'type':_0x31c5a0}}]},'description':_0x46afe8(0x12d)+_0x211468+_0x46afe8(0x117)};},async 'execute'(_0x50632d){const _0x3fc318=a142_0x2c0e50,_0x385665=normalizeScene(_0x50632d[_0x3fc318(0x12f)](_0x3fc318(0x11c))),_0x4bc091=SCENE_TO_LEGACY_TYPE[_0x385665],_0x2b8e6c=validateInputSelection(_0x50632d);if(_0x2b8e6c[_0x3fc318(0x132)]){const _0x1ad98e=await recognizeDevelopmentOcr(_0x50632d[_0x3fc318(0x143)],{'url':_0x2b8e6c[_0x3fc318(0x132)],'type':_0x4bc091});return{'ok':!![],'data':withScene(_0x1ad98e,_0x385665)};}const _0x17697b=requireDevelopmentUploadFile(_0x2b8e6c['imageFile'],'image-file'),_0x42b327=await uploadDevelopmentFile(_0x50632d[_0x3fc318(0x143)],_0x17697b[_0x3fc318(0x128)]);if(!_0x42b327[_0x3fc318(0x11b)])throw CliErrors['apiError'](_0x3fc318(0x148));const _0xcc60e5=await queryDevelopmentFileUrl(_0x42b327[_0x3fc318(0x11b)],{'download':![]});if(!_0xcc60e5[_0x3fc318(0x122)])throw CliErrors[_0x3fc318(0x146)](_0x3fc318(0x125));const _0x4562af=await recognizeDevelopmentOcr(_0x50632d[_0x3fc318(0x143)],{'url':_0xcc60e5[_0x3fc318(0x122)],'type':_0x4bc091});return{'ok':!![],'data':withScene(_0x4562af,_0x385665,_0x42b327)};}};export const ocrDefinitions=[ocrRecognize];
1
+ function a142_0x5789(_0x3dd138,_0x1365f7){_0x3dd138=_0x3dd138-0x1a0;const _0x48a41e=a142_0x48a4();let _0x578945=_0x48a41e[_0x3dd138];return _0x578945;}const a142_0x5da126=a142_0x5789;function a142_0x48a4(){const _0x47d2b0=['<fileUrl\x20returned\x20by\x20/smartapi/common/queryFileUrl>','fileUrl','invoice','Publicly\x20accessible\x20image\x20or\x20file\x20URL','418216NNHikJ','imageFile','toString','\x20OCR','General','image-url','File\x20upload\x20response\x20missing\x20filePath.','Local\x20image\x20or\x20PDF\x20file;\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','.\x20Supported\x20scenes:\x20','Invoice','21ivGuoR','OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard','form','7190jrcuwp','Preview:\x20recognize\x20','string','idcard','/smartapi/ocr/recognize-text?','Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','1013322dRTeuo','length','filePath','/smartapi/common/uploadFile','Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20','13574BiofYD','/smartapi/ocr/recognize-text','idCard','read','image-file','GET','1646559ZtWUpq','POST','1mTipTJ','764056vgiNIW','recognize','425695oQQOye','imageUrl','6dWsVYB','validation','path','scene','general','<filePath\x20returned\x20by\x20/smartapi/common/uploadFile>','Table','ocr','585912WizHXP','trim','appCode','str','File\x20URL\x20response\x20missing\x20fileUrl.'];a142_0x48a4=function(){return _0x47d2b0;};return a142_0x48a4();}(function(_0x5a5a4d,_0x1eb82a){const _0x3d9021=a142_0x5789,_0x34612b=_0x5a5a4d();while(!![]){try{const _0x3ed5bf=parseInt(_0x3d9021(0x1b4))/0x1*(parseInt(_0x3d9021(0x1b5))/0x2)+parseInt(_0x3d9021(0x1a7))/0x3+-parseInt(_0x3d9021(0x1ca))/0x4+parseInt(_0x3d9021(0x1b7))/0x5*(parseInt(_0x3d9021(0x1b9))/0x6)+parseInt(_0x3d9021(0x1d4))/0x7*(parseInt(_0x3d9021(0x1c1))/0x8)+parseInt(_0x3d9021(0x1b2))/0x9+-parseInt(_0x3d9021(0x1a1))/0xa*(parseInt(_0x3d9021(0x1ac))/0xb);if(_0x3ed5bf===_0x1eb82a)break;else _0x34612b['push'](_0x34612b['shift']());}catch(_0x4083dd){_0x34612b['push'](_0x34612b['shift']());}}}(a142_0x48a4,0x34b01));import{requireDevelopmentUploadFile}from'../../commands/common/local-file.js';import{queryDevelopmentFileUrl,recognizeDevelopmentOcr,uploadDevelopmentFile}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';const SUPPORTED_SCENES=[a142_0x5da126(0x1c8),'general',a142_0x5da126(0x1a0),a142_0x5da126(0x1ae)],SCENE_TO_LEGACY_TYPE={'invoice':a142_0x5da126(0x1d3),'general':a142_0x5da126(0x1ce),'form':a142_0x5da126(0x1bf),'idCard':'IdCard'},SCENE_FLAG={'name':'scene','type':a142_0x5da126(0x1a3),'required':!![],'enum':[...SUPPORTED_SCENES],'description':a142_0x5da126(0x1d5)},IMAGE_FILE_FLAG={'name':'image-file','type':a142_0x5da126(0x1a3),'description':a142_0x5da126(0x1d1)},IMAGE_URL_FLAG={'name':a142_0x5da126(0x1cf),'type':a142_0x5da126(0x1a3),'description':a142_0x5da126(0x1c9)};function normalizeScene(_0x3f123d){const _0x3c0829=a142_0x5da126,_0xd80ee7=_0x3f123d[_0x3c0829(0x1c2)]()['toLowerCase']();if(_0xd80ee7===_0x3c0829(0x1a4))return'idCard';if(_0xd80ee7===_0x3c0829(0x1c8)||_0xd80ee7===_0x3c0829(0x1bd)||_0xd80ee7===_0x3c0829(0x1a0))return _0xd80ee7;throw CliErrors['validation']('Unsupported\x20OCR\x20scene:\x20'+_0x3f123d+_0x3c0829(0x1d2)+SUPPORTED_SCENES['join'](',\x20'));}function selectedInputs(_0x395310){const _0x8fb5ae=a142_0x5da126,_0x5cd216=_0x395310[_0x8fb5ae(0x1c4)](_0x8fb5ae(0x1b0))[_0x8fb5ae(0x1c2)](),_0x3927e6=_0x395310[_0x8fb5ae(0x1c4)](_0x8fb5ae(0x1cf))[_0x8fb5ae(0x1c2)]();return{'imageFile':_0x5cd216,'imageUrl':_0x3927e6,'count':[_0x5cd216,_0x3927e6]['filter'](Boolean)[_0x8fb5ae(0x1a8)]};}function validateInputSelection(_0x41e498){const _0x371009=a142_0x5da126,_0x3cf37b=selectedInputs(_0x41e498);if(_0x3cf37b['count']!==0x1)throw CliErrors[_0x371009(0x1ba)]('Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.');return _0x3cf37b;}function withScene(_0x5b46d3,_0x4170a5,_0x16962e){const _0x4f94f=a142_0x5da126;return{..._0x5b46d3,'scene':_0x4170a5,..._0x16962e?{'sourceFile':{'fileName':_0x16962e['fileName'],'filePath':_0x16962e[_0x4f94f(0x1a9)]}}:{}};}const ocrRecognize={'service':a142_0x5da126(0x1c0),'command':a142_0x5da126(0x1b6),'description':a142_0x5da126(0x1a6),'risk':a142_0x5da126(0x1af),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x8c6f2){const _0x10c1e8=a142_0x5da126,_0x347293=normalizeScene(_0x8c6f2['str'](_0x10c1e8(0x1bc))),_0xa3e90f=SCENE_TO_LEGACY_TYPE[_0x347293],_0x39bdcc=validateInputSelection(_0x8c6f2);if(_0x39bdcc[_0x10c1e8(0x1b8)]){const _0x433696=new URLSearchParams({'url':_0x39bdcc[_0x10c1e8(0x1b8)],'type':_0xa3e90f,'appCode':_0x8c6f2[_0x10c1e8(0x1c3)]});return{'method':_0x10c1e8(0x1b1),'url':_0x10c1e8(0x1a5)+_0x433696[_0x10c1e8(0x1cc)](),'description':_0x10c1e8(0x1a2)+_0x347293+'\x20OCR\x20from\x20URL'};}const _0x49a7f5=requireDevelopmentUploadFile(_0x39bdcc[_0x10c1e8(0x1cb)],'image-file');return{'method':_0x10c1e8(0x1b3),'url':'/smartapi/common/uploadFile','body':{'steps':[{'method':'POST','url':_0x10c1e8(0x1aa),'body':{'appCode':_0x8c6f2['appCode'],'multipart':{'file':_0x49a7f5}}},{'method':_0x10c1e8(0x1b3),'url':'/smartapi/common/queryFileUrl','body':{'filePath':_0x10c1e8(0x1be),'downloadFlag':![]}},{'method':_0x10c1e8(0x1b1),'url':_0x10c1e8(0x1ad),'query':{'appCode':_0x8c6f2[_0x10c1e8(0x1c3)],'url':_0x10c1e8(0x1c6),'type':_0xa3e90f}}]},'description':_0x10c1e8(0x1ab)+_0x347293+_0x10c1e8(0x1cd)};},async 'execute'(_0x34dcf0){const _0xe19ecd=a142_0x5da126,_0x528f20=normalizeScene(_0x34dcf0['str']('scene')),_0x21fd89=SCENE_TO_LEGACY_TYPE[_0x528f20],_0x1fecd2=validateInputSelection(_0x34dcf0);if(_0x1fecd2[_0xe19ecd(0x1b8)]){const _0x42ac80=await recognizeDevelopmentOcr(_0x34dcf0[_0xe19ecd(0x1c3)],{'url':_0x1fecd2['imageUrl'],'type':_0x21fd89});return{'ok':!![],'data':withScene(_0x42ac80,_0x528f20)};}const _0x2d842d=requireDevelopmentUploadFile(_0x1fecd2[_0xe19ecd(0x1cb)],_0xe19ecd(0x1b0)),_0x30feb6=await uploadDevelopmentFile(_0x34dcf0[_0xe19ecd(0x1c3)],_0x2d842d[_0xe19ecd(0x1bb)]);if(!_0x30feb6[_0xe19ecd(0x1a9)])throw CliErrors['apiError'](_0xe19ecd(0x1d0));const _0xad2519=await queryDevelopmentFileUrl(_0x30feb6[_0xe19ecd(0x1a9)],{'download':![]});if(!_0xad2519['fileUrl'])throw CliErrors['apiError'](_0xe19ecd(0x1c5));const _0x2b10ca=await recognizeDevelopmentOcr(_0x34dcf0['appCode'],{'url':_0xad2519[_0xe19ecd(0x1c7)],'type':_0x21fd89});return{'ok':!![],'data':withScene(_0x2b10ca,_0x528f20,_0x30feb6)};}};export const ocrDefinitions=[ocrRecognize];
@@ -1 +1 @@
1
- const a143_0x46f7a9=a143_0x4844;(function(_0x345da7,_0x2722a7){const _0x1bc021=a143_0x4844,_0x491c04=_0x345da7();while(!![]){try{const _0x2306d2=-parseInt(_0x1bc021(0xd2))/0x1+parseInt(_0x1bc021(0xa0))/0x2+-parseInt(_0x1bc021(0xd5))/0x3*(-parseInt(_0x1bc021(0xaf))/0x4)+-parseInt(_0x1bc021(0xd7))/0x5*(-parseInt(_0x1bc021(0xd9))/0x6)+-parseInt(_0x1bc021(0xa9))/0x7+parseInt(_0x1bc021(0xb0))/0x8+-parseInt(_0x1bc021(0xa4))/0x9*(-parseInt(_0x1bc021(0xce))/0xa);if(_0x2306d2===_0x2722a7)break;else _0x491c04['push'](_0x491c04['shift']());}catch(_0x2dd932){_0x491c04['push'](_0x491c04['shift']());}}}(a143_0x5a38,0xd64c3));import{APPCODE_FLAG}from'../../commands/common/flags.js';import{buildInitialFiles}from'../../commands/page/custom/template.js';import{createCustomPage,getI18nInfo}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,parseCustomPageContent,validateCustomPageContent}from'./custom/shared.js';const DEFAULT_CUSTOM_PAGE_LANGUAGES=[a143_0x46f7a9(0xd6),'en-US'];export const pageCreate={'service':'page','command':a143_0x46f7a9(0xbd),'description':a143_0x46f7a9(0xc1),'risk':a143_0x46f7a9(0xc8),'defaultOutputFormat':'compress','structuredErrors':!![],'rejectedFlags':[{'name':a143_0x46f7a9(0xbe),'message':a143_0x46f7a9(0xac),'hint':a143_0x46f7a9(0xbb)}],'flags':[{'name':'name','type':a143_0x46f7a9(0xc7),'description':a143_0x46f7a9(0xb3)},{'name':a143_0x46f7a9(0xc3),'type':'number','description':a143_0x46f7a9(0xa1)},{'name':a143_0x46f7a9(0xc0),'type':a143_0x46f7a9(0xc7),'description':a143_0x46f7a9(0xa7),'enum':[a143_0x46f7a9(0xd8)]},{'name':a143_0x46f7a9(0xc4),'type':a143_0x46f7a9(0xc7),'description':a143_0x46f7a9(0xa6)},APPCODE_FLAG],async 'validate'(_0x124133){const _0x29fefc=a143_0x46f7a9,_0x599e50=readPagePattern(_0x124133);await validateCustomPageContent(readInput(_0x124133,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x599e50)[_0x29fefc(0xb5)]);},async 'dryRun'(_0x325efe){const _0x50d107=a143_0x46f7a9,{input:_0x236873}=await prepare(_0x325efe);return{'method':'POST','url':'/smartapi/webcode/page/create','body':{'appCode':_0x236873['appCode'],'pageName':_0x236873['pageName'],..._0x236873['parentMenuId']!=null?{'parentMenuId':_0x236873[_0x50d107(0xb1)]}:{},'createMenu':_0x236873['createMenu'],'codeContent':_0x236873[_0x50d107(0xb5)]},'description':'Would\x20create\x20Custom\x20Page\x20'+JSON[_0x50d107(0xca)](_0x236873[_0x50d107(0xd1)])+_0x50d107(0xaa)};},async 'execute'(_0x891731){const _0x34bef5=a143_0x46f7a9,_0x1cc0fe=await prepare(_0x891731),_0x4b24ae=await createCustomPage(_0x1cc0fe[_0x34bef5(0xbf)]);if(!Number['isInteger'](_0x4b24ae[_0x34bef5(0xd3)])||_0x4b24ae[_0x34bef5(0xd3)]<=0x0)throw CliErrors[_0x34bef5(0xcd)](_0x34bef5(0xb2));return{'ok':!![],'data':buildMutationData(_0x1cc0fe,_0x4b24ae),'message':_0x34bef5(0xcc)+_0x4b24ae[_0x34bef5(0xd3)]+'.'};}};async function prepare(_0x41cb8e){const _0x487d0c=a143_0x46f7a9,_0x290666=readPagePattern(_0x41cb8e);if(_0x290666===null)return{'input':readInput(_0x41cb8e,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x290666),'warnings':[],'pagePattern':_0x290666};let _0x2a42dc=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x3919c3=[];try{const _0x2efb4f=await getI18nInfo(_0x41cb8e[_0x487d0c(0xb7)]);_0x2efb4f[_0x487d0c(0xae)]&&_0x2efb4f[_0x487d0c(0xd0)]?.['length']&&(_0x2a42dc=_0x2efb4f[_0x487d0c(0xd0)]);}catch{_0x3919c3=[_0x487d0c(0xb8)];}return{'input':readInput(_0x41cb8e,_0x2a42dc,_0x290666),'warnings':_0x3919c3,'pagePattern':_0x290666};}function a143_0x5a38(){const _0x3d7427=['stringify','pageName\x20cannot\x20exceed\x20100\x20characters.','Created\x20Custom\x20Page\x20','apiError','3710Sjshcj','isInteger','langs','pageName','834143PoSUGZ','pageId','pagePattern','175254vfPcUP','zh-CN','21265cEWMDa','BLANK','6QSwsyT','version','str','2272472BKplVJ','Optional\x20parent\x20menu\x20id\x20when\x20creating\x20a\x20menu\x20entry','keys','CUSTOM','31491nKuonh','trim','Complete\x20page\x20files\x20as\x20JSON\x20(conflicts\x20with\x20--page-pattern)','Custom\x20Page\x20pattern\x20(currently\x20BLANK;\x20conflicts\x20with\x20--page-content)','now','11972779lwBnZX','\x20and\x20its\x20menu\x20entry.','page.create','page\x20create\x20does\x20not\x20accept\x20--page-type.','num','enableI18n','48GEQnQW','2261352PGzDRI','parentMenuId','Custom\x20Page\x20creation\x20did\x20not\x20return\x20a\x20valid\x20pageId.','Optional\x20Custom\x20Page\x20name\x20(1-100\x20characters)','isNaN','files','warnings','appCode','Application\x20language\x20settings\x20could\x20not\x20be\x20read;\x20default\x20Chinese\x20and\x20English\x20language\x20files\x20were\x20generated.','name','menuPath','This\x20command\x20always\x20creates\x20a\x20CUSTOM\x20JSX\x20page;\x20use\x20--page-pattern\x20BLANK\x20or\x20--page-content.','length','create','page-type','input','page-pattern','Create\x20a\x20JSX\x20Custom\x20Page\x20from\x20a\x20released\x20pattern\x20or\x20complete\x20files','validation','parent-menu-id','page-content','Custom_page_','--parent-menu-id\x20must\x20be\x20a\x20positive\x20integer.','string','write','Custom\x20Page\x20was\x20created,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.'];a143_0x5a38=function(){return _0x3d7427;};return a143_0x5a38();}function readPagePattern(_0x5a9e1f){const _0x54276b=a143_0x46f7a9,_0x7965d7=_0x5a9e1f['str'](_0x54276b(0xc0))[_0x54276b(0xa5)](),_0x4f826a=_0x5a9e1f[_0x54276b(0x9f)]('page-content')[_0x54276b(0xa5)]()['length']>0x0;if(_0x7965d7&&_0x4f826a)throw CliErrors['validation']('--page-pattern\x20and\x20--page-content\x20cannot\x20be\x20used\x20together.');if(_0x4f826a)return null;if(!_0x7965d7)throw CliErrors[_0x54276b(0xc2)]('Provide\x20--page-pattern\x20BLANK\x20or\x20--page-content.');if(_0x7965d7!==_0x54276b(0xd8))throw CliErrors['validation']('--page-pattern\x20currently\x20supports\x20only\x20BLANK.');return _0x7965d7;}function readInput(_0x485829,_0x71fda=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x1c9ab6=readPagePattern(_0x485829)){const _0x50bf4c=a143_0x46f7a9,_0x5182c3=_0x485829[_0x50bf4c(0x9f)](_0x50bf4c(0xb9))[_0x50bf4c(0xa5)]()||_0x50bf4c(0xc5)+Date[_0x50bf4c(0xa8)]();if(_0x5182c3[_0x50bf4c(0xbc)]>0x64)throw CliErrors[_0x50bf4c(0xc2)](_0x50bf4c(0xcb));const _0x3e2c32=_0x485829[_0x50bf4c(0xad)](_0x50bf4c(0xc3),NaN),_0x54a3fc=!Number[_0x50bf4c(0xb4)](_0x3e2c32);if(_0x54a3fc&&(!Number[_0x50bf4c(0xcf)](_0x3e2c32)||_0x3e2c32<=0x0))throw CliErrors[_0x50bf4c(0xc2)](_0x50bf4c(0xc6));return{'appCode':_0x485829['appCode'],'pageName':_0x5182c3,..._0x54a3fc?{'parentMenuId':_0x3e2c32}:{},'createMenu':!![],'files':_0x1c9ab6===null?parseCustomPageContent(_0x485829[_0x50bf4c(0x9f)](_0x50bf4c(0xc4))):buildInitialFiles(_0x5182c3,_0x71fda)};}function a143_0x4844(_0x32c062,_0x4140b8){_0x32c062=_0x32c062-0x9e;const _0x5a38ce=a143_0x5a38();let _0x484477=_0x5a38ce[_0x32c062];return _0x484477;}function buildMutationData(_0x195747,_0x117372){const _0x3f717e=a143_0x46f7a9,{input:_0x9db4b1}=_0x195747,_0x1276fd=_0x117372&&buildCustomPageDevelopmentUrl(_0x9db4b1['appCode'],_0x117372[_0x3f717e(0xba)]),_0x31a8df=_0x117372&&buildCustomPageEditUrl(_0x9db4b1[_0x3f717e(0xb7)],_0x117372['pageId']);return{'operation':_0x3f717e(0xab),'pageType':_0x3f717e(0xa3),'pagePattern':_0x195747[_0x3f717e(0xd4)],'selector':{'appCode':_0x9db4b1[_0x3f717e(0xb7)],'pageName':_0x9db4b1['pageName']},'before':null,'after':{'pageId':_0x117372?.[_0x3f717e(0xd3)]??null,'pageName':_0x117372?.[_0x3f717e(0xd1)]??_0x9db4b1['pageName'],'appCode':_0x117372?.[_0x3f717e(0xb7)]??_0x9db4b1[_0x3f717e(0xb7)],'version':_0x117372?.[_0x3f717e(0x9e)]??null,'menuId':_0x117372?.['menuId']??null,'menuPath':_0x117372?.['menuPath']??null,'files':_0x117372?.['files']??Object[_0x3f717e(0xa2)](_0x9db4b1['files'])},'dryRun':_0x117372===undefined,'request':_0x9db4b1,..._0x1276fd?{'pageUrl':_0x1276fd}:{},..._0x31a8df?{'editPageUrl':_0x31a8df}:{},'warnings':[..._0x195747[_0x3f717e(0xb6)],..._0x117372&&!_0x1276fd?[_0x3f717e(0xc9)]:[]]};}
1
+ const a143_0x41d9af=a143_0x14dd;function a143_0x17a3(){const _0x21a72f=['files','2047038NgdthF','CUSTOM','465528QrwEbt','Optional\x20parent\x20menu\x20id\x20when\x20creating\x20a\x20menu\x20entry','\x20and\x20its\x20menu\x20entry.','stringify','length','BLANK','trim','page\x20create\x20does\x20not\x20accept\x20--page-type.','menuPath','page-content','Optional\x20Custom\x20Page\x20name\x20(1-100\x20characters)','87WQRMNB','Created\x20Custom\x20Page\x20','number','isNaN','Complete\x20page\x20files\x20as\x20JSON\x20(conflicts\x20with\x20--page-pattern)','appCode','version','pageName','string','895244dklNDg','--parent-menu-id\x20must\x20be\x20a\x20positive\x20integer.','452785ArQZOk','Application\x20language\x20settings\x20could\x20not\x20be\x20read;\x20default\x20Chinese\x20and\x20English\x20language\x20files\x20were\x20generated.','apiError','page-pattern','name','parent-menu-id','Would\x20create\x20Custom\x20Page\x20','input','Create\x20a\x20JSX\x20Custom\x20Page\x20from\x20a\x20released\x20pattern\x20or\x20complete\x20files','Custom_page_','isInteger','keys','compress','menuId','zh-CN','page-type','614112Hyihxm','str','parentMenuId','4730KQBbhk','page','Provide\x20--page-pattern\x20BLANK\x20or\x20--page-content.','pagePattern','validation','langs','POST','pageId','page.create','2971640maJMtH','now','warnings','--page-pattern\x20and\x20--page-content\x20cannot\x20be\x20used\x20together.'];a143_0x17a3=function(){return _0x21a72f;};return a143_0x17a3();}(function(_0x23b36f,_0x2d3d48){const _0x1dab07=a143_0x14dd,_0x5a1cef=_0x23b36f();while(!![]){try{const _0x15aed9=parseInt(_0x1dab07(0x10c))/0x1*(-parseInt(_0x1dab07(0x12a))/0x2)+parseInt(_0x1dab07(0x138))/0x3+parseInt(_0x1dab07(0x127))/0x4+-parseInt(_0x1dab07(0x117))/0x5+parseInt(_0x1dab07(0x101))/0x6+parseInt(_0x1dab07(0x115))/0x7+-parseInt(_0x1dab07(0x133))/0x8;if(_0x15aed9===_0x2d3d48)break;else _0x5a1cef['push'](_0x5a1cef['shift']());}catch(_0x3574a1){_0x5a1cef['push'](_0x5a1cef['shift']());}}}(a143_0x17a3,0x5b353));function a143_0x14dd(_0x3468cd,_0x2db795){_0x3468cd=_0x3468cd-0x101;const _0x17a3ac=a143_0x17a3();let _0x14ddb5=_0x17a3ac[_0x3468cd];return _0x14ddb5;}import{APPCODE_FLAG}from'../../commands/common/flags.js';import{buildInitialFiles}from'../../commands/page/custom/template.js';import{createCustomPage,getI18nInfo}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,parseCustomPageContent,validateCustomPageContent}from'./custom/shared.js';const DEFAULT_CUSTOM_PAGE_LANGUAGES=[a143_0x41d9af(0x125),'en-US'];export const pageCreate={'service':a143_0x41d9af(0x12b),'command':'create','description':a143_0x41d9af(0x11f),'risk':'write','defaultOutputFormat':a143_0x41d9af(0x123),'structuredErrors':!![],'rejectedFlags':[{'name':a143_0x41d9af(0x126),'message':a143_0x41d9af(0x108),'hint':'This\x20command\x20always\x20creates\x20a\x20CUSTOM\x20JSX\x20page;\x20use\x20--page-pattern\x20BLANK\x20or\x20--page-content.'}],'flags':[{'name':'name','type':a143_0x41d9af(0x114),'description':a143_0x41d9af(0x10b)},{'name':a143_0x41d9af(0x11c),'type':a143_0x41d9af(0x10e),'description':a143_0x41d9af(0x102)},{'name':a143_0x41d9af(0x11a),'type':a143_0x41d9af(0x114),'description':'Custom\x20Page\x20pattern\x20(currently\x20BLANK;\x20conflicts\x20with\x20--page-content)','enum':['BLANK']},{'name':a143_0x41d9af(0x10a),'type':a143_0x41d9af(0x114),'description':a143_0x41d9af(0x110)},APPCODE_FLAG],async 'validate'(_0x4fb791){const _0x9efbac=a143_0x41d9af,_0x5063a1=readPagePattern(_0x4fb791);await validateCustomPageContent(readInput(_0x4fb791,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x5063a1)[_0x9efbac(0x137)]);},async 'dryRun'(_0x5994f4){const _0x6f76e9=a143_0x41d9af,{input:_0x3d1dc1}=await prepare(_0x5994f4);return{'method':_0x6f76e9(0x130),'url':'/smartapi/webcode/page/create','body':{'appCode':_0x3d1dc1['appCode'],'pageName':_0x3d1dc1[_0x6f76e9(0x113)],..._0x3d1dc1[_0x6f76e9(0x129)]!=null?{'parentMenuId':_0x3d1dc1[_0x6f76e9(0x129)]}:{},'createMenu':_0x3d1dc1['createMenu'],'codeContent':_0x3d1dc1[_0x6f76e9(0x137)]},'description':_0x6f76e9(0x11d)+JSON[_0x6f76e9(0x104)](_0x3d1dc1[_0x6f76e9(0x113)])+_0x6f76e9(0x103)};},async 'execute'(_0x4aeae4){const _0x45616d=a143_0x41d9af,_0x58d422=await prepare(_0x4aeae4),_0x5816d2=await createCustomPage(_0x58d422[_0x45616d(0x11e)]);if(!Number[_0x45616d(0x121)](_0x5816d2[_0x45616d(0x131)])||_0x5816d2[_0x45616d(0x131)]<=0x0)throw CliErrors[_0x45616d(0x119)]('Custom\x20Page\x20creation\x20did\x20not\x20return\x20a\x20valid\x20pageId.');return{'ok':!![],'data':buildMutationData(_0x58d422,_0x5816d2),'message':_0x45616d(0x10d)+_0x5816d2['pageId']+'.'};}};async function prepare(_0x3f19a4){const _0x90674c=a143_0x41d9af,_0x1f6ae8=readPagePattern(_0x3f19a4);if(_0x1f6ae8===null)return{'input':readInput(_0x3f19a4,DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x1f6ae8),'warnings':[],'pagePattern':_0x1f6ae8};let _0x593da4=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x51e623=[];try{const _0x315261=await getI18nInfo(_0x3f19a4['appCode']);_0x315261['enableI18n']&&_0x315261[_0x90674c(0x12f)]?.['length']&&(_0x593da4=_0x315261[_0x90674c(0x12f)]);}catch{_0x51e623=[_0x90674c(0x118)];}return{'input':readInput(_0x3f19a4,_0x593da4,_0x1f6ae8),'warnings':_0x51e623,'pagePattern':_0x1f6ae8};}function readPagePattern(_0x4d7b7c){const _0x1c683d=a143_0x41d9af,_0x49b175=_0x4d7b7c[_0x1c683d(0x128)](_0x1c683d(0x11a))['trim'](),_0x2e34d1=_0x4d7b7c[_0x1c683d(0x128)](_0x1c683d(0x10a))[_0x1c683d(0x107)]()[_0x1c683d(0x105)]>0x0;if(_0x49b175&&_0x2e34d1)throw CliErrors[_0x1c683d(0x12e)](_0x1c683d(0x136));if(_0x2e34d1)return null;if(!_0x49b175)throw CliErrors['validation'](_0x1c683d(0x12c));if(_0x49b175!==_0x1c683d(0x106))throw CliErrors[_0x1c683d(0x12e)]('--page-pattern\x20currently\x20supports\x20only\x20BLANK.');return _0x49b175;}function readInput(_0x56506e,_0x513cbd=DEFAULT_CUSTOM_PAGE_LANGUAGES,_0x24dd19=readPagePattern(_0x56506e)){const _0x4dd3db=a143_0x41d9af,_0x3c6af8=_0x56506e[_0x4dd3db(0x128)](_0x4dd3db(0x11b))[_0x4dd3db(0x107)]()||_0x4dd3db(0x120)+Date[_0x4dd3db(0x134)]();if(_0x3c6af8['length']>0x64)throw CliErrors[_0x4dd3db(0x12e)]('pageName\x20cannot\x20exceed\x20100\x20characters.');const _0x39c781=_0x56506e['num'](_0x4dd3db(0x11c),NaN),_0x1bca74=!Number[_0x4dd3db(0x10f)](_0x39c781);if(_0x1bca74&&(!Number[_0x4dd3db(0x121)](_0x39c781)||_0x39c781<=0x0))throw CliErrors[_0x4dd3db(0x12e)](_0x4dd3db(0x116));return{'appCode':_0x56506e[_0x4dd3db(0x111)],'pageName':_0x3c6af8,..._0x1bca74?{'parentMenuId':_0x39c781}:{},'createMenu':!![],'files':_0x24dd19===null?parseCustomPageContent(_0x56506e[_0x4dd3db(0x128)](_0x4dd3db(0x10a))):buildInitialFiles(_0x3c6af8,_0x513cbd)};}function buildMutationData(_0x483eb1,_0x2c6d4b){const _0x5e5643=a143_0x41d9af,{input:_0x314210}=_0x483eb1,_0x3567e0=_0x2c6d4b&&buildCustomPageDevelopmentUrl(_0x314210['appCode'],_0x2c6d4b[_0x5e5643(0x109)]),_0xd4df0b=_0x2c6d4b&&buildCustomPageEditUrl(_0x314210[_0x5e5643(0x111)],_0x2c6d4b['pageId']);return{'operation':_0x5e5643(0x132),'pageType':_0x5e5643(0x139),'pagePattern':_0x483eb1[_0x5e5643(0x12d)],'selector':{'appCode':_0x314210[_0x5e5643(0x111)],'pageName':_0x314210[_0x5e5643(0x113)]},'before':null,'after':{'pageId':_0x2c6d4b?.['pageId']??null,'pageName':_0x2c6d4b?.[_0x5e5643(0x113)]??_0x314210['pageName'],'appCode':_0x2c6d4b?.['appCode']??_0x314210[_0x5e5643(0x111)],'version':_0x2c6d4b?.[_0x5e5643(0x112)]??null,'menuId':_0x2c6d4b?.[_0x5e5643(0x124)]??null,'menuPath':_0x2c6d4b?.[_0x5e5643(0x109)]??null,'files':_0x2c6d4b?.[_0x5e5643(0x137)]??Object[_0x5e5643(0x122)](_0x314210[_0x5e5643(0x137)])},'dryRun':_0x2c6d4b===undefined,'request':_0x314210,..._0x3567e0?{'pageUrl':_0x3567e0}:{},..._0xd4df0b?{'editPageUrl':_0xd4df0b}:{},'warnings':[..._0x483eb1[_0x5e5643(0x135)],..._0x2c6d4b&&!_0x3567e0?['Custom\x20Page\x20was\x20created,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.']:[]]};}
@@ -1 +1 @@
1
- function a144_0x4936(){const _0x2b39e2=['page','294sSyHHQ','getHours','7022sVvxXd','getMinutes','3744044fDWgFz','padStart','number','appcode','138urjLic','cookie','custom-detail','trim','appCode','getFullYear','36818Qbclio','74824cgLvaj','48293EaJxsh','Show\x20a\x20Custom\x20Page\x20and\x20all\x20of\x20its\x20files','Retrieved\x20Custom\x20Page\x20','2124010SNHRlf','747OXmKbJ','pageCode','24269800zevnUT','read'];a144_0x4936=function(){return _0x2b39e2;};return a144_0x4936();}const a144_0x431b49=a144_0x2af8;(function(_0x65f13e,_0x5da42e){const _0xa4793e=a144_0x2af8,_0x460f07=_0x65f13e();while(!![]){try{const _0x406fe5=parseInt(_0xa4793e(0x1eb))/0x1+parseInt(_0xa4793e(0x1df))/0x2*(-parseInt(_0xa4793e(0x1e5))/0x3)+-parseInt(_0xa4793e(0x1e1))/0x4+parseInt(_0xa4793e(0x1f0))/0x5+parseInt(_0xa4793e(0x1dd))/0x6*(-parseInt(_0xa4793e(0x1ed))/0x7)+-parseInt(_0xa4793e(0x1ec))/0x8*(parseInt(_0xa4793e(0x1f1))/0x9)+parseInt(_0xa4793e(0x1f3))/0xa;if(_0x406fe5===_0x5da42e)break;else _0x460f07['push'](_0x460f07['shift']());}catch(_0x7abd4d){_0x460f07['push'](_0x460f07['shift']());}}}(a144_0x4936,0xa537d));import{getCustomPageSource}from'../../../core/api-client.js';function a144_0x2af8(_0x278a3,_0x59c6f1){_0x278a3=_0x278a3-0x1dc;const _0x49369d=a144_0x4936();let _0x2af88f=_0x49369d[_0x278a3];return _0x2af88f;}import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,resolveCustomPageDevelopmentUrl}from'./shared.js';export const pageCustomDetail={'service':a144_0x431b49(0x1dc),'command':a144_0x431b49(0x1e7),'description':a144_0x431b49(0x1ee),'risk':a144_0x431b49(0x1f4),'defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a144_0x431b49(0x1e3),'required':!![],'description':'Custom\x20Page\x20ID'},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0xffd2a9){readCustomPageId(_0xffd2a9);},async 'execute'(_0x4e14dd){const _0x117097=a144_0x431b49,_0x34f68d=readCustomPageId(_0x4e14dd),_0x3c81e9=await getCustomPageSource(_0x34f68d),{bundle:_0x5916d3,createTime:_0x3b13e4,updateTime:_0x431577,..._0x18f6fa}=_0x3c81e9,_0x315974=_0x3c81e9['id']??_0x34f68d,_0xbb1236=_0x3c81e9[_0x117097(0x1e9)]?.['trim']()||_0x4e14dd['str'](_0x117097(0x1e4))[_0x117097(0x1e8)](),_0x5b1522=buildCustomPageRuntimeUrl(_0xbb1236,_0x3c81e9[_0x117097(0x1f2)]),_0x14dc4e=buildCustomPageEditUrl(_0xbb1236,_0x315974),_0x3df653=await resolveCustomPageDevelopmentUrl(_0xbb1236,_0x315974,_0x4e14dd[_0x117097(0x1e6)]);return{'ok':!![],'data':{..._0x18f6fa,..._0x5b1522?{'runtimePageUrl':_0x5b1522}:{},..._0x3df653?{'pageUrl':_0x3df653}:{},..._0x14dc4e?{'editPageUrl':_0x14dc4e}:{},..._0x3b13e4==null?{}:{'createTime':formatTime(_0x3b13e4)},..._0x431577==null?{}:{'updateTime':formatTime(_0x431577)}},'message':_0x117097(0x1ef)+_0x34f68d+'.'};}};function formatTime(_0x52a539){const _0x419990=a144_0x431b49,_0x5512ac=new Date(_0x52a539);if(Number['isNaN'](_0x5512ac['getTime']()))return String(_0x52a539);const _0x4ffaef=[_0x5512ac[_0x419990(0x1ea)](),String(_0x5512ac['getMonth']()+0x1)[_0x419990(0x1e2)](0x2,'0'),String(_0x5512ac['getDate']())[_0x419990(0x1e2)](0x2,'0')]['join']('-'),_0x1a818d=[String(_0x5512ac[_0x419990(0x1de)]())[_0x419990(0x1e2)](0x2,'0'),String(_0x5512ac[_0x419990(0x1e0)]())[_0x419990(0x1e2)](0x2,'0'),String(_0x5512ac['getSeconds']())['padStart'](0x2,'0')]['join'](':');return _0x4ffaef+'\x20'+_0x1a818d;}
1
+ const a144_0x3bc9b1=a144_0x8d08;(function(_0x157a18,_0x448cde){const _0x299d16=a144_0x8d08,_0x587c33=_0x157a18();while(!![]){try{const _0x1d654e=-parseInt(_0x299d16(0x10e))/0x1*(-parseInt(_0x299d16(0xf7))/0x2)+parseInt(_0x299d16(0x110))/0x3+-parseInt(_0x299d16(0xfb))/0x4*(parseInt(_0x299d16(0xfc))/0x5)+-parseInt(_0x299d16(0xf9))/0x6*(-parseInt(_0x299d16(0xfa))/0x7)+parseInt(_0x299d16(0x109))/0x8*(parseInt(_0x299d16(0x10a))/0x9)+-parseInt(_0x299d16(0x10c))/0xa+parseInt(_0x299d16(0x106))/0xb*(-parseInt(_0x299d16(0x100))/0xc);if(_0x1d654e===_0x448cde)break;else _0x587c33['push'](_0x587c33['shift']());}catch(_0x444697){_0x587c33['push'](_0x587c33['shift']());}}}(a144_0x3edf,0x88f06));import{getCustomPageSource}from'../../../core/api-client.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,resolveCustomPageDevelopmentUrl}from'./shared.js';function a144_0x8d08(_0x240e5b,_0x54e600){_0x240e5b=_0x240e5b-0xf7;const _0x3edf01=a144_0x3edf();let _0x8d08c1=_0x3edf01[_0x240e5b];return _0x8d08c1;}function a144_0x3edf(){const _0x5d6280=['2264748JKPchR','getHours','getFullYear','page','getSeconds','isNaN','55Canbpl','appcode','getMinutes','120fIfDOf','612306GmCCZV','pageCode','4006130Fwgbjv','Show\x20a\x20Custom\x20Page\x20and\x20all\x20of\x20its\x20files','374300JSLZjS','join','2762910ItBcZh','trim','getTime','Retrieved\x20Custom\x20Page\x20','getMonth','2ZdMiMz','number','2672430bmMlAB','7nRCdLS','388MTRozc','44125uzEFRu','appCode','str','padStart'];a144_0x3edf=function(){return _0x5d6280;};return a144_0x3edf();}export const pageCustomDetail={'service':a144_0x3bc9b1(0x103),'command':'custom-detail','description':a144_0x3bc9b1(0x10d),'risk':'read','defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a144_0x3bc9b1(0xf8),'required':!![],'description':'Custom\x20Page\x20ID'},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x2fa9db){readCustomPageId(_0x2fa9db);},async 'execute'(_0x1a8273){const _0xe3e472=a144_0x3bc9b1,_0x2184a8=readCustomPageId(_0x1a8273),_0x1d092b=await getCustomPageSource(_0x2184a8),{bundle:_0x181eff,createTime:_0x2a14fa,updateTime:_0x246f29,..._0x2ac19f}=_0x1d092b,_0x1a902e=_0x1d092b['id']??_0x2184a8,_0x260335=_0x1d092b[_0xe3e472(0xfd)]?.[_0xe3e472(0x111)]()||_0x1a8273[_0xe3e472(0xfe)](_0xe3e472(0x107))['trim'](),_0x4e2b26=buildCustomPageRuntimeUrl(_0x260335,_0x1d092b[_0xe3e472(0x10b)]),_0x3dea8e=buildCustomPageEditUrl(_0x260335,_0x1a902e),_0x8088a6=await resolveCustomPageDevelopmentUrl(_0x260335,_0x1a902e,_0x1a8273['cookie']);return{'ok':!![],'data':{..._0x2ac19f,..._0x4e2b26?{'runtimePageUrl':_0x4e2b26}:{},..._0x8088a6?{'pageUrl':_0x8088a6}:{},..._0x3dea8e?{'editPageUrl':_0x3dea8e}:{},..._0x2a14fa==null?{}:{'createTime':formatTime(_0x2a14fa)},..._0x246f29==null?{}:{'updateTime':formatTime(_0x246f29)}},'message':_0xe3e472(0x113)+_0x2184a8+'.'};}};function formatTime(_0x5b341c){const _0x4eb34d=a144_0x3bc9b1,_0x2293bd=new Date(_0x5b341c);if(Number[_0x4eb34d(0x105)](_0x2293bd[_0x4eb34d(0x112)]()))return String(_0x5b341c);const _0x126be2=[_0x2293bd[_0x4eb34d(0x102)](),String(_0x2293bd[_0x4eb34d(0x114)]()+0x1)[_0x4eb34d(0xff)](0x2,'0'),String(_0x2293bd['getDate']())[_0x4eb34d(0xff)](0x2,'0')]['join']('-'),_0x34044e=[String(_0x2293bd[_0x4eb34d(0x101)]())['padStart'](0x2,'0'),String(_0x2293bd[_0x4eb34d(0x108)]())[_0x4eb34d(0xff)](0x2,'0'),String(_0x2293bd[_0x4eb34d(0x104)]())[_0x4eb34d(0xff)](0x2,'0')][_0x4eb34d(0x10f)](':');return _0x126be2+'\x20'+_0x34044e;}
@@ -1 +1 @@
1
- const a145_0x4e7d52=a145_0x3aea;(function(_0x4a8027,_0x295ba4){const _0x1d2a5b=a145_0x3aea,_0x1c3e5e=_0x4a8027();while(!![]){try{const _0x2a3e38=parseInt(_0x1d2a5b(0x191))/0x1*(-parseInt(_0x1d2a5b(0x196))/0x2)+parseInt(_0x1d2a5b(0x18a))/0x3+parseInt(_0x1d2a5b(0x195))/0x4*(-parseInt(_0x1d2a5b(0x181))/0x5)+parseInt(_0x1d2a5b(0x182))/0x6*(-parseInt(_0x1d2a5b(0x185))/0x7)+-parseInt(_0x1d2a5b(0x183))/0x8*(-parseInt(_0x1d2a5b(0x18e))/0x9)+-parseInt(_0x1d2a5b(0x192))/0xa*(parseInt(_0x1d2a5b(0x18c))/0xb)+parseInt(_0x1d2a5b(0x18d))/0xc*(parseInt(_0x1d2a5b(0x194))/0xd);if(_0x2a3e38===_0x295ba4)break;else _0x1c3e5e['push'](_0x1c3e5e['shift']());}catch(_0x4bc305){_0x1c3e5e['push'](_0x1c3e5e['shift']());}}}(a145_0x2388,0x7f456));function a145_0x3aea(_0x5e4e96,_0x5229c2){_0x5e4e96=_0x5e4e96-0x17f;const _0x238833=a145_0x2388();let _0x3aeaad=_0x238833[_0x5e4e96];return _0x3aeaad;}function a145_0x2388(){const _0x44507f=['203910ynpwiq','100976aPdveM','read','98FsSARk','custom-list','react','appCode','page','1683783TNrFRa','menus','66thWhgM','12cQHELF','270baicnT','No\x20Custom\x20Pages\x20found.','label','20369wkeiWO','1434710wmkqgc','flatMap','35505379VqLMQo','436JTujxT','82MeZWLf','type','pageId','\x20Custom\x20Page(s).','length','44865CYgjvM'];a145_0x2388=function(){return _0x44507f;};return a145_0x2388();}import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl}from'./shared.js';export const pageCustomList={'service':a145_0x4e7d52(0x189),'command':a145_0x4e7d52(0x186),'description':'List\x20Custom\x20Pages\x20in\x20the\x20current\x20app','risk':a145_0x4e7d52(0x184),'defaultOutputFormat':'compress','structuredErrors':!![],'flags':[APPCODE_FLAG_OPTIONAL],async 'execute'(_0x5bbef0){const _0x537264=a145_0x4e7d52,_0x5af601=(await fetchMenuSnapshot(_0x5bbef0[_0x537264(0x188)],_0x5bbef0['cookie']))[_0x537264(0x18b)][_0x537264(0x193)](_0x32260c=>{const _0x1f3280=_0x537264;if(_0x32260c[_0x1f3280(0x197)]!==_0x1f3280(0x187)||_0x32260c[_0x1f3280(0x198)]==null)return[];const _0x3b15a3=buildCustomPageDevelopmentUrl(_0x5bbef0['appCode'],_0x32260c['path']),_0x59d9f1=buildCustomPageEditUrl(_0x5bbef0[_0x1f3280(0x188)],_0x32260c['pageId']);return[{'pageId':_0x32260c[_0x1f3280(0x198)],'label':_0x32260c[_0x1f3280(0x190)],..._0x3b15a3?{'pageUrl':_0x3b15a3}:{},..._0x59d9f1?{'editPageUrl':_0x59d9f1}:{}}];});return{'ok':!![],'data':{'pages':_0x5af601},'message':_0x5af601['length']===0x0?_0x537264(0x18f):'Found\x20'+_0x5af601[_0x537264(0x180)]+_0x537264(0x17f)};}};
1
+ const a145_0x2bc05a=a145_0xbd0d;(function(_0xf30e17,_0x16d4ad){const _0x5a6a74=a145_0xbd0d,_0x11b83c=_0xf30e17();while(!![]){try{const _0x253593=-parseInt(_0x5a6a74(0x112))/0x1*(parseInt(_0x5a6a74(0xfc))/0x2)+-parseInt(_0x5a6a74(0x115))/0x3+-parseInt(_0x5a6a74(0x10b))/0x4+parseInt(_0x5a6a74(0x10d))/0x5*(parseInt(_0x5a6a74(0x106))/0x6)+parseInt(_0x5a6a74(0x107))/0x7*(-parseInt(_0x5a6a74(0x108))/0x8)+parseInt(_0x5a6a74(0x113))/0x9*(parseInt(_0x5a6a74(0xfd))/0xa)+-parseInt(_0x5a6a74(0xff))/0xb*(-parseInt(_0x5a6a74(0x109))/0xc);if(_0x253593===_0x16d4ad)break;else _0x11b83c['push'](_0x11b83c['shift']());}catch(_0x26bd4d){_0x11b83c['push'](_0x11b83c['shift']());}}}(a145_0x12c2,0x7cf9a));function a145_0x12c2(){const _0x425f5d=['2456855cusVmn','path','label','pageId','Found\x20','2407gaaBlp','9DCuaUy','type','947715hpnksP','294DlhLlb','2434270WPnpsa','No\x20Custom\x20Pages\x20found.','6512OUPJpq','menus','length','cookie','compress','appCode','List\x20Custom\x20Pages\x20in\x20the\x20current\x20app','12ZanpcX','70mtwHrx','65368GrSGHr','10668lBgTJn','custom-list','1956460yiJoYM','flatMap'];a145_0x12c2=function(){return _0x425f5d;};return a145_0x12c2();}import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl}from'./shared.js';function a145_0xbd0d(_0x1b8a4f,_0x13958e){_0x1b8a4f=_0x1b8a4f-0xfc;const _0x12c25a=a145_0x12c2();let _0xbd0d67=_0x12c25a[_0x1b8a4f];return _0xbd0d67;}export const pageCustomList={'service':'page','command':a145_0x2bc05a(0x10a),'description':a145_0x2bc05a(0x105),'risk':'read','defaultOutputFormat':a145_0x2bc05a(0x103),'structuredErrors':!![],'flags':[APPCODE_FLAG_OPTIONAL],async 'execute'(_0x33dbb6){const _0x4ab214=a145_0x2bc05a,_0x98a021=(await fetchMenuSnapshot(_0x33dbb6['appCode'],_0x33dbb6[_0x4ab214(0x102)]))[_0x4ab214(0x100)][_0x4ab214(0x10c)](_0x4d3b8b=>{const _0x3bdfe8=_0x4ab214;if(_0x4d3b8b[_0x3bdfe8(0x114)]!=='react'||_0x4d3b8b[_0x3bdfe8(0x110)]==null)return[];const _0x136585=buildCustomPageDevelopmentUrl(_0x33dbb6[_0x3bdfe8(0x104)],_0x4d3b8b[_0x3bdfe8(0x10e)]),_0x421ea0=buildCustomPageEditUrl(_0x33dbb6[_0x3bdfe8(0x104)],_0x4d3b8b['pageId']);return[{'pageId':_0x4d3b8b[_0x3bdfe8(0x110)],'label':_0x4d3b8b[_0x3bdfe8(0x10f)],..._0x136585?{'pageUrl':_0x136585}:{},..._0x421ea0?{'editPageUrl':_0x421ea0}:{}}];});return{'ok':!![],'data':{'pages':_0x98a021},'message':_0x98a021[_0x4ab214(0x101)]===0x0?_0x4ab214(0xfe):_0x4ab214(0x111)+_0x98a021[_0x4ab214(0x101)]+'\x20Custom\x20Page(s).'};}};
@@ -1 +1 @@
1
- const a146_0x8cfbde=a146_0x343a;(function(_0x85628,_0x7e7c14){const _0x2aa027=a146_0x343a,_0x48dd09=_0x85628();while(!![]){try{const _0x34877d=-parseInt(_0x2aa027(0x181))/0x1+-parseInt(_0x2aa027(0x17a))/0x2*(parseInt(_0x2aa027(0x199))/0x3)+-parseInt(_0x2aa027(0x17d))/0x4*(parseInt(_0x2aa027(0x176))/0x5)+parseInt(_0x2aa027(0x18d))/0x6*(parseInt(_0x2aa027(0x17e))/0x7)+-parseInt(_0x2aa027(0x19b))/0x8+-parseInt(_0x2aa027(0x17f))/0x9+parseInt(_0x2aa027(0x195))/0xa*(parseInt(_0x2aa027(0x197))/0xb);if(_0x34877d===_0x7e7c14)break;else _0x48dd09['push'](_0x48dd09['shift']());}catch(_0x4659a7){_0x48dd09['push'](_0x48dd09['shift']());}}}(a146_0x2c4f,0xaabc6));import{getCustomPageSource,publishCustomPage}from'../../../core/api-client.js';import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,resolveCustomPageDevelopmentUrl}from'./shared.js';export const pageCustomPublish={'service':a146_0x8cfbde(0x188),'command':a146_0x8cfbde(0x18b),'description':a146_0x8cfbde(0x186),'risk':'write','defaultOutputFormat':a146_0x8cfbde(0x177),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':'number','required':!![],'description':a146_0x8cfbde(0x17c)},{'name':a146_0x8cfbde(0x190),'type':a146_0x8cfbde(0x184),'description':'Optional\x20publish\x20remark'}],async 'validate'(_0x2e0c8e){readCustomPageId(_0x2e0c8e);},async 'dryRun'(_0x53e6cf){const _0x336ec7=a146_0x8cfbde,_0x40d081=readInput(_0x53e6cf);return{'method':_0x336ec7(0x19a),'url':_0x336ec7(0x19d),'body':{'id':_0x40d081[_0x336ec7(0x179)],..._0x40d081[_0x336ec7(0x190)]?{'remark':_0x40d081[_0x336ec7(0x190)]}:{}},'description':_0x336ec7(0x193)+_0x40d081['pageId']+'.'};},async 'execute'(_0x8c689f){const _0x12057e=a146_0x8cfbde,_0x364d7b=readInput(_0x8c689f);await getCustomPageSource(_0x364d7b['pageId']);const _0x5b6f6d=await publishCustomPage(_0x364d7b);if(!Number[_0x12057e(0x180)](_0x5b6f6d)||_0x5b6f6d!==_0x364d7b[_0x12057e(0x179)])throw CliErrors[_0x12057e(0x187)](_0x12057e(0x191));const _0x22661a=await getCustomPageSource(_0x364d7b[_0x12057e(0x179)]);if(_0x22661a[_0x12057e(0x196)]!=='FORMAL')throw CliErrors['apiError'](_0x12057e(0x18c)+(_0x22661a[_0x12057e(0x196)]??_0x12057e(0x185))+'.');const _0x58f999=_0x22661a[_0x12057e(0x18f)]?.[_0x12057e(0x183)](),_0x4f1133=buildCustomPageEditUrl(_0x58f999,_0x364d7b[_0x12057e(0x179)]),_0x584a7a=await resolveCustomPageDevelopmentUrl(_0x58f999,_0x364d7b[_0x12057e(0x179)],_0x8c689f[_0x12057e(0x178)]),_0x330930=buildMutationData(_0x364d7b,!![],_0x584a7a,_0x4f1133);_0x58f999&&!_0x584a7a&&_0x330930['warnings']['push'](_0x12057e(0x182));const _0xe6a9c7=buildCustomPageRuntimeUrl(_0x22661a['appCode'],_0x22661a[_0x12057e(0x192)]);return _0xe6a9c7?_0x330930[_0x12057e(0x18e)]=_0xe6a9c7:_0x330930[_0x12057e(0x194)][_0x12057e(0x18a)](_0x12057e(0x189)),{'ok':!![],'data':_0x330930,'message':'Published\x20Custom\x20Page\x20'+_0x364d7b[_0x12057e(0x179)]+'.'};}};function a146_0x343a(_0x4c7c6a,_0x263b7e){_0x4c7c6a=_0x4c7c6a-0x176;const _0x2c4fe8=a146_0x2c4f();let _0x343a44=_0x2c4fe8[_0x4c7c6a];return _0x343a44;}function readInput(_0x2badae){const _0x5be732=a146_0x8cfbde,_0x3aab0e=readCustomPageId(_0x2badae),_0xdd3ed=_0x2badae[_0x5be732(0x17b)](_0x5be732(0x190))[_0x5be732(0x183)]();return{'pageId':_0x3aab0e,..._0xdd3ed?{'remark':_0xdd3ed}:{}};}function a146_0x2c4f(){const _0x35e25e=['apiError','page','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20published\x20page\x20could\x20not\x20be\x20generated.','push','custom-publish','Custom\x20Page\x20publish\x20did\x20not\x20reach\x20published\x20status:\x20','84qqURDo','runtimePageUrl','appCode','remark','Custom\x20Page\x20publish\x20did\x20not\x20return\x20the\x20expected\x20page\x20ID.','pageCode','Would\x20publish\x20Custom\x20Page\x20','warnings','58270UdCwgK','status','6809JgYZuu','FORMAL','567612yuLyzX','POST','409072VxDxMe','page.custom-publish','/smartapi/webcode/file/publish','8290vyLQYl','compress','cookie','pageId','4RXzlUV','str','Custom\x20Page\x20ID','2984QZuvpm','76727LVYSxP','4209075rtdLcw','isInteger','926948ZwORwV','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','trim','string','unknown','Publish\x20the\x20latest\x20saved\x20content\x20of\x20a\x20Custom\x20Page'];a146_0x2c4f=function(){return _0x35e25e;};return a146_0x2c4f();}function buildMutationData(_0xe4dcd2,_0x511b87=![],_0x1754a9,_0x4238a9){const _0xf00a6a=a146_0x8cfbde;return{'operation':_0xf00a6a(0x19c),'selector':{'pageId':_0xe4dcd2['pageId']},'before':null,'after':{'pageId':_0xe4dcd2['pageId'],'status':_0xf00a6a(0x198)},'dryRun':!_0x511b87,'request':_0xe4dcd2,..._0x1754a9?{'pageUrl':_0x1754a9}:{},..._0x4238a9?{'editPageUrl':_0x4238a9}:{},'warnings':[]};}
1
+ const a146_0x47922d=a146_0x599b;(function(_0x14724d,_0xca7170){const _0x4f6e1c=a146_0x599b,_0x1d0561=_0x14724d();while(!![]){try{const _0x4ce749=-parseInt(_0x4f6e1c(0xc3))/0x1*(parseInt(_0x4f6e1c(0xbc))/0x2)+-parseInt(_0x4f6e1c(0xba))/0x3*(-parseInt(_0x4f6e1c(0xbf))/0x4)+parseInt(_0x4f6e1c(0xb4))/0x5*(-parseInt(_0x4f6e1c(0xb5))/0x6)+parseInt(_0x4f6e1c(0xdb))/0x7+parseInt(_0x4f6e1c(0xd6))/0x8*(parseInt(_0x4f6e1c(0xca))/0x9)+-parseInt(_0x4f6e1c(0xbb))/0xa*(-parseInt(_0x4f6e1c(0xd4))/0xb)+-parseInt(_0x4f6e1c(0xd3))/0xc;if(_0x4ce749===_0xca7170)break;else _0x1d0561['push'](_0x1d0561['shift']());}catch(_0x14fbec){_0x1d0561['push'](_0x1d0561['shift']());}}}(a146_0x1477,0x3dc45));import{getCustomPageSource,publishCustomPage}from'../../../core/api-client.js';function a146_0x599b(_0x468c84,_0x59b319){_0x468c84=_0x468c84-0xb3;const _0x147727=a146_0x1477();let _0x599b36=_0x147727[_0x468c84];return _0x599b36;}import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,resolveCustomPageDevelopmentUrl}from'./shared.js';export const pageCustomPublish={'service':a146_0x47922d(0xb6),'command':a146_0x47922d(0xc6),'description':a146_0x47922d(0xb7),'risk':a146_0x47922d(0xcb),'defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a146_0x47922d(0xcd),'required':!![],'description':a146_0x47922d(0xc1)},{'name':a146_0x47922d(0xbd),'type':a146_0x47922d(0xc9),'description':a146_0x47922d(0xcf)}],async 'validate'(_0x4289d2){readCustomPageId(_0x4289d2);},async 'dryRun'(_0x789891){const _0x4a7aad=a146_0x47922d,_0x37dc2b=readInput(_0x789891);return{'method':_0x4a7aad(0xd9),'url':_0x4a7aad(0xd2),'body':{'id':_0x37dc2b[_0x4a7aad(0xb9)],..._0x37dc2b[_0x4a7aad(0xbd)]?{'remark':_0x37dc2b['remark']}:{}},'description':_0x4a7aad(0xc4)+_0x37dc2b[_0x4a7aad(0xb9)]+'.'};},async 'execute'(_0x30d545){const _0x15066b=a146_0x47922d,_0x8a1766=readInput(_0x30d545);await getCustomPageSource(_0x8a1766[_0x15066b(0xb9)]);const _0xee2342=await publishCustomPage(_0x8a1766);if(!Number['isInteger'](_0xee2342)||_0xee2342!==_0x8a1766[_0x15066b(0xb9)])throw CliErrors[_0x15066b(0xce)]('Custom\x20Page\x20publish\x20did\x20not\x20return\x20the\x20expected\x20page\x20ID.');const _0x2902ef=await getCustomPageSource(_0x8a1766[_0x15066b(0xb9)]);if(_0x2902ef[_0x15066b(0xd1)]!==_0x15066b(0xc0))throw CliErrors[_0x15066b(0xce)](_0x15066b(0xc8)+(_0x2902ef[_0x15066b(0xd1)]??_0x15066b(0xd8))+'.');const _0xda40a9=_0x2902ef[_0x15066b(0xd7)]?.[_0x15066b(0xb8)](),_0x58b37e=buildCustomPageEditUrl(_0xda40a9,_0x8a1766['pageId']),_0x248065=await resolveCustomPageDevelopmentUrl(_0xda40a9,_0x8a1766[_0x15066b(0xb9)],_0x30d545[_0x15066b(0xc2)]),_0x49bf35=buildMutationData(_0x8a1766,!![],_0x248065,_0x58b37e);_0xda40a9&&!_0x248065&&_0x49bf35[_0x15066b(0xd0)][_0x15066b(0xda)](_0x15066b(0xb3));const _0x499ac1=buildCustomPageRuntimeUrl(_0x2902ef[_0x15066b(0xd7)],_0x2902ef[_0x15066b(0xbe)]);return _0x499ac1?_0x49bf35[_0x15066b(0xc5)]=_0x499ac1:_0x49bf35[_0x15066b(0xd0)]['push'](_0x15066b(0xcc)),{'ok':!![],'data':_0x49bf35,'message':'Published\x20Custom\x20Page\x20'+_0x8a1766['pageId']+'.'};}};function readInput(_0x128d59){const _0xc648ef=a146_0x47922d,_0x4ff4cb=readCustomPageId(_0x128d59),_0x4e9bc3=_0x128d59[_0xc648ef(0xd5)](_0xc648ef(0xbd))[_0xc648ef(0xb8)]();return{'pageId':_0x4ff4cb,..._0x4e9bc3?{'remark':_0x4e9bc3}:{}};}function buildMutationData(_0x3fab7c,_0x1420a7=![],_0xbd0838,_0x4e1c3d){const _0x1546b7=a146_0x47922d;return{'operation':_0x1546b7(0xc7),'selector':{'pageId':_0x3fab7c[_0x1546b7(0xb9)]},'before':null,'after':{'pageId':_0x3fab7c[_0x1546b7(0xb9)],'status':_0x1546b7(0xc0)},'dryRun':!_0x1420a7,'request':_0x3fab7c,..._0xbd0838?{'pageUrl':_0xbd0838}:{},..._0x4e1c3d?{'editPageUrl':_0x4e1c3d}:{},'warnings':[]};}function a146_0x1477(){const _0x501c4c=['Custom\x20Page\x20ID','cookie','30yCflLy','Would\x20publish\x20Custom\x20Page\x20','runtimePageUrl','custom-publish','page.custom-publish','Custom\x20Page\x20publish\x20did\x20not\x20reach\x20published\x20status:\x20','string','9egeWrU','write','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20published\x20page\x20could\x20not\x20be\x20generated.','number','apiError','Optional\x20publish\x20remark','warnings','status','/smartapi/webcode/file/publish','3698556veNWsw','11ZNGBlz','str','1132408lIZWKg','appCode','unknown','POST','push','2032849XKHOMU','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','2440gWKilA','4320ORvYrH','page','Publish\x20the\x20latest\x20saved\x20content\x20of\x20a\x20Custom\x20Page','trim','pageId','3yxWail','3498130kflmGQ','1294fIldah','remark','pageCode','600836HviefD','FORMAL'];a146_0x1477=function(){return _0x501c4c;};return a146_0x1477();}
@@ -1 +1 @@
1
- (function(_0x1a1826,_0x2cc655){const _0x2208a1=a147_0xe4c1,_0x1a7c10=_0x1a1826();while(!![]){try{const _0x58cffb=-parseInt(_0x2208a1(0x77))/0x1+-parseInt(_0x2208a1(0x76))/0x2+parseInt(_0x2208a1(0x91))/0x3+parseInt(_0x2208a1(0x93))/0x4*(-parseInt(_0x2208a1(0x7d))/0x5)+-parseInt(_0x2208a1(0x88))/0x6*(parseInt(_0x2208a1(0x7a))/0x7)+-parseInt(_0x2208a1(0x79))/0x8*(parseInt(_0x2208a1(0x90))/0x9)+parseInt(_0x2208a1(0x73))/0xa*(parseInt(_0x2208a1(0x7f))/0xb);if(_0x58cffb===_0x2cc655)break;else _0x1a7c10['push'](_0x1a7c10['shift']());}catch(_0xbf8146){_0x1a7c10['push'](_0x1a7c10['shift']());}}}(a147_0x13c9,0x699df));import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{getAppBaseUrl,getPublishedAppDomain}from'../../../constant/domain.js';import{CliErrors}from'../../../errors.js';import{validateCustomPageSourceFiles}from'./syntax.js';function a147_0x13c9(){const _0x41da06=['type','string','object','page-content','Invalid\x20Custom\x20Page\x20content:\x20','map','/ide/','2471772irMyOz','message','isInteger','values','validation','num','--id\x20must\x20be\x20a\x20positive\x20integer.','menus','9QEpdpJ','1598064lvADFI','length','2345788GYvSTl','some','isArray','file','/pages/','85970BybsHI','path','flagMissing','997426gQBJWg','852555oIUQJB','parse','6011608eTrQHp','14gBxOZB','trim','--page-content\x20must\x20be\x20valid\x20JSON.','5KbfJsK','join','4367oyYRSg','find'];a147_0x13c9=function(){return _0x41da06;};return a147_0x13c9();}export const CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL={...APPCODE_FLAG_OPTIONAL,'description':'Optional\x20app\x20code\x20resolved\x20from\x20page\x20ID\x20when\x20omitted'};function trimOptional(_0x2da7aa){const _0x3cea8b=a147_0xe4c1;return _0x2da7aa?.[_0x3cea8b(0x7b)]()||undefined;}function a147_0xe4c1(_0x28330a,_0x51ba62){_0x28330a=_0x28330a-0x70;const _0x13c96a=a147_0x13c9();let _0xe4c1ee=_0x13c96a[_0x28330a];return _0xe4c1ee;}export function buildCustomPageRuntimeUrl(_0x32da56,_0x37ffda){const _0x1bd008=trimOptional(_0x32da56),_0xfff6ee=trimOptional(_0x37ffda);if(!_0x1bd008||!_0xfff6ee)return undefined;return getPublishedAppDomain(_0x1bd008)+'/'+encodeURIComponent(_0xfff6ee);}export function buildCustomPageDevelopmentUrl(_0x143c4e,_0x10104e){const _0x8debfa=a147_0xe4c1,_0x231eef=trimOptional(_0x143c4e),_0x49c1d4=trimOptional(_0x10104e);if(!_0x231eef||!_0x49c1d4)return undefined;return getAppBaseUrl(_0x231eef)+_0x8debfa(0x72)+encodeURIComponent(_0x49c1d4);}export async function resolveCustomPageDevelopmentUrl(_0x47d44b,_0xb06ff0,_0x2f407f){const _0x2e6bde=a147_0xe4c1,_0x44f8b7=trimOptional(_0x47d44b);if(!_0x44f8b7)return undefined;try{const _0x27bf8f=(await fetchMenuSnapshot(_0x44f8b7,_0x2f407f))[_0x2e6bde(0x8f)][_0x2e6bde(0x80)](_0x125d45=>_0x125d45[_0x2e6bde(0x81)]==='react'&&_0x125d45['pageId']===_0xb06ff0);return buildCustomPageDevelopmentUrl(_0x44f8b7,_0x27bf8f?.[_0x2e6bde(0x74)]);}catch{return undefined;}}export function buildCustomPageEditUrl(_0x3ee804,_0x245585){const _0x23c7bb=a147_0xe4c1,_0xe60704=trimOptional(_0x3ee804);if(!_0xe60704)return;const _0x482909=trimOptional(_0x245585==null?undefined:String(_0x245585));if(!_0x482909)return;return getAppBaseUrl(_0xe60704)+_0x23c7bb(0x87)+encodeURIComponent(_0x482909);}export function parseCustomPageContent(_0x21546d){const _0x358093=a147_0xe4c1;if(!_0x21546d[_0x358093(0x7b)]())throw CliErrors[_0x358093(0x75)](_0x358093(0x84));let _0x50975e;try{_0x50975e=JSON[_0x358093(0x78)](_0x21546d);}catch{throw CliErrors[_0x358093(0x8c)](_0x358093(0x7c));}if(typeof _0x50975e!==_0x358093(0x83)||_0x50975e===null||Array[_0x358093(0x70)](_0x50975e)||Object[_0x358093(0x8b)](_0x50975e)[_0x358093(0x94)](_0x15cf57=>typeof _0x15cf57!==_0x358093(0x82)))throw CliErrors[_0x358093(0x8c)]('--page-content\x20must\x20be\x20a\x20JSON\x20object\x20whose\x20values\x20are\x20file\x20content\x20strings.');return _0x50975e;}export async function validateCustomPageContent(_0x2663c3){const _0x51c43b=a147_0xe4c1,_0x18269a=await validateCustomPageSourceFiles(_0x2663c3);if(_0x18269a[_0x51c43b(0x92)]>0x0)throw CliErrors[_0x51c43b(0x8c)](_0x51c43b(0x85)+_0x18269a[_0x51c43b(0x86)](_0x143950=>_0x143950[_0x51c43b(0x71)]+':\x20'+_0x143950[_0x51c43b(0x89)])[_0x51c43b(0x7e)](';\x20'));}export function readCustomPageId(_0x5c2c04){const _0x464c12=a147_0xe4c1,_0x4e081d=_0x5c2c04[_0x464c12(0x8d)]('id');if(!Number[_0x464c12(0x8a)](_0x4e081d)||_0x4e081d<=0x0)throw CliErrors[_0x464c12(0x8c)](_0x464c12(0x8e));return _0x4e081d;}
1
+ const a147_0x53f576=a147_0x1c15;(function(_0x2f10ad,_0x3f415c){const _0x1373be=a147_0x1c15,_0x13bb35=_0x2f10ad();while(!![]){try{const _0x544887=parseInt(_0x1373be(0x185))/0x1+parseInt(_0x1373be(0x184))/0x2+-parseInt(_0x1373be(0x172))/0x3+-parseInt(_0x1373be(0x174))/0x4*(-parseInt(_0x1373be(0x170))/0x5)+-parseInt(_0x1373be(0x179))/0x6*(-parseInt(_0x1373be(0x16b))/0x7)+-parseInt(_0x1373be(0x176))/0x8*(-parseInt(_0x1373be(0x183))/0x9)+-parseInt(_0x1373be(0x171))/0xa;if(_0x544887===_0x3f415c)break;else _0x13bb35['push'](_0x13bb35['shift']());}catch(_0x14e9fc){_0x13bb35['push'](_0x13bb35['shift']());}}}(a147_0x5d04,0x35e28));import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{getAppBaseUrl,getPublishedAppDomain}from'../../../constant/domain.js';import{CliErrors}from'../../../errors.js';import{validateCustomPageSourceFiles}from'./syntax.js';export const CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL={...APPCODE_FLAG_OPTIONAL,'description':a147_0x53f576(0x17f)};function trimOptional(_0xf83553){const _0x2fd93e=a147_0x53f576;return _0xf83553?.[_0x2fd93e(0x188)]()||undefined;}export function buildCustomPageRuntimeUrl(_0x2b03f7,_0x4e9ba8){const _0xd1b3c2=trimOptional(_0x2b03f7),_0x48c5a2=trimOptional(_0x4e9ba8);if(!_0xd1b3c2||!_0x48c5a2)return undefined;return getPublishedAppDomain(_0xd1b3c2)+'/'+encodeURIComponent(_0x48c5a2);}function a147_0x1c15(_0x4c42ee,_0x17b378){_0x4c42ee=_0x4c42ee-0x169;const _0x5d0491=a147_0x5d04();let _0x1c15a0=_0x5d0491[_0x4c42ee];return _0x1c15a0;}export function buildCustomPageDevelopmentUrl(_0x5f335c,_0x35b7e8){const _0x13ad9f=a147_0x53f576,_0x409ba8=trimOptional(_0x5f335c),_0x4a28db=trimOptional(_0x35b7e8);if(!_0x409ba8||!_0x4a28db)return undefined;return getAppBaseUrl(_0x409ba8)+_0x13ad9f(0x16a)+encodeURIComponent(_0x4a28db);}export async function resolveCustomPageDevelopmentUrl(_0x1f771a,_0x35c0a3,_0x29ba4a){const _0x10270c=a147_0x53f576,_0x55c295=trimOptional(_0x1f771a);if(!_0x55c295)return undefined;try{const _0x3b7f5b=(await fetchMenuSnapshot(_0x55c295,_0x29ba4a))[_0x10270c(0x17d)]['find'](_0x30a9aa=>_0x30a9aa[_0x10270c(0x189)]==='react'&&_0x30a9aa[_0x10270c(0x16c)]===_0x35c0a3);return buildCustomPageDevelopmentUrl(_0x55c295,_0x3b7f5b?.[_0x10270c(0x17e)]);}catch{return undefined;}}export function buildCustomPageEditUrl(_0x151d8d,_0xd3bd8f){const _0x189b91=a147_0x53f576,_0xdbbf75=trimOptional(_0x151d8d);if(!_0xdbbf75)return;const _0x3691ba=trimOptional(_0xd3bd8f==null?undefined:String(_0xd3bd8f));if(!_0x3691ba)return;return getAppBaseUrl(_0xdbbf75)+_0x189b91(0x177)+encodeURIComponent(_0x3691ba);}export function parseCustomPageContent(_0x17f750){const _0x386cbb=a147_0x53f576;if(!_0x17f750[_0x386cbb(0x188)]())throw CliErrors[_0x386cbb(0x178)](_0x386cbb(0x182));let _0x572075;try{_0x572075=JSON['parse'](_0x17f750);}catch{throw CliErrors[_0x386cbb(0x16f)](_0x386cbb(0x16d));}if(typeof _0x572075!=='object'||_0x572075===null||Array[_0x386cbb(0x187)](_0x572075)||Object[_0x386cbb(0x17a)](_0x572075)[_0x386cbb(0x17c)](_0x50dcb2=>typeof _0x50dcb2!==_0x386cbb(0x17b)))throw CliErrors['validation'](_0x386cbb(0x175));return _0x572075;}export async function validateCustomPageContent(_0x1677fc){const _0x571737=a147_0x53f576,_0xcd64ad=await validateCustomPageSourceFiles(_0x1677fc);if(_0xcd64ad['length']>0x0)throw CliErrors[_0x571737(0x16f)](_0x571737(0x180)+_0xcd64ad[_0x571737(0x169)](_0x140481=>_0x140481[_0x571737(0x16e)]+':\x20'+_0x140481['message'])[_0x571737(0x181)](';\x20'));}function a147_0x5d04(){const _0x18de7b=['777114zyMDgW','num','33228TWPfvs','--page-content\x20must\x20be\x20a\x20JSON\x20object\x20whose\x20values\x20are\x20file\x20content\x20strings.','859584Jonsxw','/ide/','flagMissing','12NNqUns','values','string','some','menus','path','Optional\x20app\x20code\x20resolved\x20from\x20page\x20ID\x20when\x20omitted','Invalid\x20Custom\x20Page\x20content:\x20','join','page-content','27wdkkhW','628876nGxVyU','20717EpoWqL','isInteger','isArray','trim','type','map','/pages/','1512259qgJvSE','pageId','--page-content\x20must\x20be\x20valid\x20JSON.','file','validation','15wVzRZf','6347440ledyKZ'];a147_0x5d04=function(){return _0x18de7b;};return a147_0x5d04();}export function readCustomPageId(_0x2659ee){const _0x21d54f=a147_0x53f576,_0xa37704=_0x2659ee[_0x21d54f(0x173)]('id');if(!Number[_0x21d54f(0x186)](_0xa37704)||_0xa37704<=0x0)throw CliErrors[_0x21d54f(0x16f)]('--id\x20must\x20be\x20a\x20positive\x20integer.');return _0xa37704;}
@@ -1 +1 @@
1
- const a148_0x885996=a148_0x15bb;(function(_0x103dc1,_0x382546){const _0x3b3156=a148_0x15bb,_0x26b22f=_0x103dc1();while(!![]){try{const _0x5c6a7d=-parseInt(_0x3b3156(0x10c))/0x1*(-parseInt(_0x3b3156(0x10b))/0x2)+-parseInt(_0x3b3156(0x104))/0x3+-parseInt(_0x3b3156(0x10e))/0x4+-parseInt(_0x3b3156(0x108))/0x5+-parseInt(_0x3b3156(0x107))/0x6+parseInt(_0x3b3156(0x10f))/0x7+parseInt(_0x3b3156(0x111))/0x8;if(_0x5c6a7d===_0x382546)break;else _0x26b22f['push'](_0x26b22f['shift']());}catch(_0x59e06c){_0x26b22f['push'](_0x26b22f['shift']());}}}(a148_0x336b,0xcc338));function a148_0x336b(){const _0x2bfcd3=['4979852sedZBg','3479553WzhvzA','babel','25069864BfDiem','toLowerCase','some','trim','filter','page-content','.jsx','message','.tsx','1322760mlydIx','entries','find','7584378eaXTEc','4926925ygGcxb','Missing\x20React\x20source\x20file\x20with\x20extension\x20.jsx\x20or\x20.tsx','typescript','2qfSloZ','1140927mKgijm','all'];a148_0x336b=function(){return _0x2bfcd3;};return a148_0x336b();}import{format}from'prettier';function a148_0x15bb(_0x1d1266,_0x4cf0d0){_0x1d1266=_0x1d1266-0xfd;const _0x336bcd=a148_0x336b();let _0x15bb55=_0x336bcd[_0x1d1266];return _0x15bb55;}const SOURCE_PARSERS={'.js':'babel','.jsx':a148_0x885996(0x110),'.ts':'typescript','.tsx':a148_0x885996(0x10a)},CUSTOM_PAGE_EXTENSIONS=[a148_0x885996(0x101),a148_0x885996(0x103)];export async function validateCustomPageSourceFiles(_0x3436fe){const _0x9ad6fa=a148_0x885996,_0x51eea5=Object[_0x9ad6fa(0x105)](_0x3436fe)[_0x9ad6fa(0xff)](([_0x376967])=>getParser(_0x376967));if(!_0x51eea5['some'](([_0x5df294])=>isReactSourceFile(_0x5df294)))return[{'file':_0x9ad6fa(0x100),'message':_0x9ad6fa(0x109)}];const _0x3d2e8d=await Promise[_0x9ad6fa(0x10d)](_0x51eea5['map'](async([_0x2cbd2a,_0x44cacf])=>{const _0x5b5f53=_0x9ad6fa;try{return await format(_0x44cacf,{'parser':getParser(_0x2cbd2a)}),undefined;}catch(_0x4655e6){return{'file':_0x2cbd2a,'message':_0x4655e6 instanceof Error?_0x4655e6[_0x5b5f53(0x102)]:String(_0x4655e6)};}}));return _0x3d2e8d[_0x9ad6fa(0xff)](_0x5dcb2b=>_0x5dcb2b!==undefined);}function getParser(_0x403d45){const _0x1bd941=a148_0x885996,_0x2c6366=_0x403d45[_0x1bd941(0xfe)]()[_0x1bd941(0x112)]();return Object[_0x1bd941(0x105)](SOURCE_PARSERS)[_0x1bd941(0x106)](([_0x84e068])=>_0x2c6366['endsWith'](_0x84e068))?.[0x1];}function isReactSourceFile(_0x3aef3e){const _0x513773=a148_0x885996,_0x407fd0=_0x3aef3e[_0x513773(0xfe)]()[_0x513773(0x112)]();return CUSTOM_PAGE_EXTENSIONS[_0x513773(0xfd)](_0x381cf9=>_0x407fd0['endsWith'](_0x381cf9));}
1
+ const a148_0x334b18=a148_0xdde5;(function(_0x45a719,_0x10fe4e){const _0x25779b=a148_0xdde5,_0x1fe085=_0x45a719();while(!![]){try{const _0x1fe24e=-parseInt(_0x25779b(0xad))/0x1+-parseInt(_0x25779b(0xc0))/0x2+parseInt(_0x25779b(0xac))/0x3*(parseInt(_0x25779b(0xb5))/0x4)+parseInt(_0x25779b(0xb7))/0x5*(-parseInt(_0x25779b(0xbd))/0x6)+-parseInt(_0x25779b(0xaa))/0x7+-parseInt(_0x25779b(0xb4))/0x8+-parseInt(_0x25779b(0xb8))/0x9*(-parseInt(_0x25779b(0xc1))/0xa);if(_0x1fe24e===_0x10fe4e)break;else _0x1fe085['push'](_0x1fe085['shift']());}catch(_0x4791eb){_0x1fe085['push'](_0x1fe085['shift']());}}}(a148_0x53d9,0x99213));import{format}from'prettier';function a148_0xdde5(_0x2b4ac2,_0x2daebe){_0x2b4ac2=_0x2b4ac2-0xaa;const _0x53d911=a148_0x53d9();let _0xdde55c=_0x53d911[_0x2b4ac2];return _0xdde55c;}const SOURCE_PARSERS={'.js':'babel','.jsx':'babel','.ts':a148_0x334b18(0xb2),'.tsx':a148_0x334b18(0xb2)},CUSTOM_PAGE_EXTENSIONS=[a148_0x334b18(0xba),a148_0x334b18(0xaf)];export async function validateCustomPageSourceFiles(_0x3b51fa){const _0x3233ce=a148_0x334b18,_0x3923a0=Object[_0x3233ce(0xb3)](_0x3b51fa)[_0x3233ce(0xbc)](([_0x3098b7])=>getParser(_0x3098b7));if(!_0x3923a0[_0x3233ce(0xbb)](([_0x4e6782])=>isReactSourceFile(_0x4e6782)))return[{'file':_0x3233ce(0xb0),'message':'Missing\x20React\x20source\x20file\x20with\x20extension\x20.jsx\x20or\x20.tsx'}];const _0xabcebd=await Promise[_0x3233ce(0xb1)](_0x3923a0[_0x3233ce(0xbf)](async([_0x4100a6,_0x344a45])=>{const _0xcc0ac3=_0x3233ce;try{return await format(_0x344a45,{'parser':getParser(_0x4100a6)}),undefined;}catch(_0x5523c3){return{'file':_0x4100a6,'message':_0x5523c3 instanceof Error?_0x5523c3[_0xcc0ac3(0xae)]:String(_0x5523c3)};}}));return _0xabcebd['filter'](_0x3064b0=>_0x3064b0!==undefined);}function a148_0x53d9(){const _0x65e5d5=['find','.jsx','some','filter','8886BKqwWo','trim','map','2163776zVnHeT','117430pufRwN','8161629yMvXpA','endsWith','3zoNrYi','1244234wlVZQE','message','.tsx','page-content','all','typescript','entries','4769240ihOnvy','1330408gUTlpQ','toLowerCase','2885PcUmCS','4014vudUJP'];a148_0x53d9=function(){return _0x65e5d5;};return a148_0x53d9();}function getParser(_0x2e06e7){const _0x3f9bfe=a148_0x334b18,_0x33eabc=_0x2e06e7['trim']()[_0x3f9bfe(0xb6)]();return Object[_0x3f9bfe(0xb3)](SOURCE_PARSERS)[_0x3f9bfe(0xb9)](([_0x5e9099])=>_0x33eabc[_0x3f9bfe(0xab)](_0x5e9099))?.[0x1];}function isReactSourceFile(_0x3d307e){const _0x11899a=a148_0x334b18,_0x3cf631=_0x3d307e[_0x11899a(0xbe)]()[_0x11899a(0xb6)]();return CUSTOM_PAGE_EXTENSIONS['some'](_0x1ed14b=>_0x3cf631[_0x11899a(0xab)](_0x1ed14b));}
@@ -1 +1 @@
1
- function a149_0x2fb9(){const _0x3c4868=['2809330xMOgsR','2239MMjPVf','16RsGETq','stringify','export\x20const\x20locales\x20=\x20{\x0a','486UjvFQK','8978688XiBqaQ','1457358GzTqwm','1932180rVNiPU','}</Typography.Title>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<Typography.Paragraph>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{$i18n.t(\x27pageDescription\x27,\x20\x27这是一个基础页面模板,你可以在此基础上进行开发。\x27)}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</Typography.Paragraph>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</Typography>\x0a\x20\x20\x20\x20\x20\x20</Card>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20);\x0a};\x0a\x0aexport\x20default\x20App;\x0a','join','392259hExFUj','2411226EnBkLU','en-US','ja-JP','Ini\x20adalah\x20sebuah\x20halaman\x20dasar.\x20Anda\x20dapat\x20mengembangkan\x20ini.',',\x0a\x20\x20}','This\x20is\x20a\x20basic\x20page\x20template,\x20you\x20can\x20develop\x20based\x20on\x20it.','Bu\x20bir\x20temel\x20sayfa\x20şablonudur.\x20Bu\x20temaplana\x20dayanarak\x20geliştirilebilir.','import\x20React\x20from\x20\x27react\x27;\x0aimport\x20{\x20Card,\x20Typography\x20}\x20from\x20\x27antd\x27;\x0aimport\x20{\x20useSdkClient,\x20useI18n,\x20useNavigate,\x20useLocation\x20}\x20from\x20\x22@/context/app-context\x22;\x0aimport\x20{\x20locales\x20}\x20from\x20\x27../locales\x27;\x0aimport\x20\x27./index.css\x27;\x0a\x0aconst\x20App\x20=\x20()\x20=>\x20{\x0a\x20\x20const\x20client\x20=\x20useSdkClient();\x20//\x20client\x20可以用于获取其他数据集的数据\x0a\x20\x20const\x20$i18n\x20=\x20useI18n();\x20//\x20国际化多语言\x20i18n\x20实例\x0a\x20\x20const\x20navigate\x20=\x20useNavigate();\x20//\x20react-router\x20navigate\x20导航实例\x0a\x20\x20const\x20location\x20=\x20useLocation();\x20//\x20浏览器\x20location\x20实例\x0a\x0a\x20\x20$i18n.addLocale(locales);\x20//\x20添加多语言词包\x0a\x0a\x20\x20return\x20(\x0a\x20\x20\x20\x20<div\x20className=\x22page-container\x22>\x0a\x20\x20\x20\x20\x20\x20<Card>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<Typography>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<Typography.Title\x20level={2}>{','zh-CN',':\x20{\x0a\x20\x20\x20\x20','.page-container\x20{\x0a\x20\x20padding:\x2024px;\x0a\x20\x20background:\x20#f0f2f5;\x0a\x20\x20min-height:\x20100vh;\x0a}\x0a','これは基本ページテンプレートです。あなたは、これに基づいて開発できます。'];a149_0x2fb9=function(){return _0x3c4868;};return a149_0x2fb9();}(function(_0x45d582,_0x4aa69c){const _0x385492=a149_0x5559,_0x4607a0=_0x45d582();while(!![]){try{const _0x2ae065=-parseInt(_0x385492(0x142))/0x1*(parseInt(_0x385492(0x146))/0x2)+parseInt(_0x385492(0x134))/0x3+parseInt(_0x385492(0x131))/0x4+-parseInt(_0x385492(0x141))/0x5+parseInt(_0x385492(0x135))/0x6+-parseInt(_0x385492(0x130))/0x7*(parseInt(_0x385492(0x143))/0x8)+parseInt(_0x385492(0x147))/0x9;if(_0x2ae065===_0x4aa69c)break;else _0x4607a0['push'](_0x4607a0['shift']());}catch(_0xde538f){_0x4607a0['push'](_0x4607a0['shift']());}}}(a149_0x2fb9,0x77dda));function a149_0x5559(_0x2f70f7,_0x1fb016){_0x2f70f7=_0x2f70f7-0x130;const _0x2fb93d=a149_0x2fb9();let _0x555931=_0x2fb93d[_0x2f70f7];return _0x555931;}function buildIndexFile(_0xdcf7b0){const _0x5c398c=a149_0x5559;return _0x5c398c(0x13c)+JSON[_0x5c398c(0x144)](_0xdcf7b0)+_0x5c398c(0x132);}function buildStyleFile(){const _0x483f5c=a149_0x5559;return _0x483f5c(0x13f);}function buildLocalesFile(_0x43420a){const _0x8cd6df=a149_0x5559,_0xf38f6c=_0x43420a['map'](_0x9d1084=>{const _0x572568=a149_0x5559;let _0x166d43='';switch(_0x9d1084){case _0x572568(0x13d):_0x166d43='这是一个基础页面模板,你可以在此基础上进行开发。';break;case _0x572568(0x136):_0x166d43=_0x572568(0x13a);break;case _0x572568(0x137):_0x166d43=_0x572568(0x140);break;case'tr-TR':_0x166d43=_0x572568(0x13b);break;case'id-ID':_0x166d43=_0x572568(0x138);break;default:_0x166d43=_0x572568(0x13a);}return'\x20\x20'+JSON[_0x572568(0x144)](_0x9d1084)+_0x572568(0x13e)+JSON[_0x572568(0x144)]('pageDescription')+':\x20'+JSON['stringify'](_0x166d43)+_0x572568(0x139);})[_0x8cd6df(0x133)](',\x0a');return _0x8cd6df(0x145)+_0xf38f6c+'\x0a};\x0a';}export function buildInitialFiles(_0x12aebe,_0x1511f9){return{'src/app/index.jsx':buildIndexFile(_0x12aebe),'src/app/index.css':buildStyleFile(),'src/locales/index.js':buildLocalesFile(_0x1511f9)};}
1
+ (function(_0x131b4f,_0x37e730){const _0x1c2a14=a149_0x1510,_0x4df4b9=_0x131b4f();while(!![]){try{const _0x3f4f9a=parseInt(_0x1c2a14(0x12f))/0x1*(parseInt(_0x1c2a14(0x12e))/0x2)+parseInt(_0x1c2a14(0x11f))/0x3*(-parseInt(_0x1c2a14(0x133))/0x4)+-parseInt(_0x1c2a14(0x12c))/0x5+parseInt(_0x1c2a14(0x12a))/0x6+parseInt(_0x1c2a14(0x12b))/0x7*(parseInt(_0x1c2a14(0x126))/0x8)+-parseInt(_0x1c2a14(0x11d))/0x9+parseInt(_0x1c2a14(0x11c))/0xa;if(_0x3f4f9a===_0x37e730)break;else _0x4df4b9['push'](_0x4df4b9['shift']());}catch(_0x1e7a36){_0x4df4b9['push'](_0x4df4b9['shift']());}}}(a149_0x530a,0x78cbf));function buildIndexFile(_0x482f0d){const _0x402a1d=a149_0x1510;return _0x402a1d(0x122)+JSON['stringify'](_0x482f0d)+_0x402a1d(0x124);}function a149_0x1510(_0x2147ef,_0x3bda67){_0x2147ef=_0x2147ef-0x11b;const _0x530ad6=a149_0x530a();let _0x1510eb=_0x530ad6[_0x2147ef];return _0x1510eb;}function buildStyleFile(){return'.page-container\x20{\x0a\x20\x20padding:\x2024px;\x0a\x20\x20background:\x20#f0f2f5;\x0a\x20\x20min-height:\x20100vh;\x0a}\x0a';}function buildLocalesFile(_0xa93f32){const _0x1a3217=a149_0x1510,_0xe282bb=_0xa93f32[_0x1a3217(0x12d)](_0x158879=>{const _0x5125ab=_0x1a3217;let _0x2ce9ee='';switch(_0x158879){case'zh-CN':_0x2ce9ee=_0x5125ab(0x129);break;case _0x5125ab(0x11b):_0x2ce9ee=_0x5125ab(0x11e);break;case'ja-JP':_0x2ce9ee=_0x5125ab(0x128);break;case _0x5125ab(0x121):_0x2ce9ee=_0x5125ab(0x120);break;case'id-ID':_0x2ce9ee=_0x5125ab(0x132);break;default:_0x2ce9ee=_0x5125ab(0x11e);}return'\x20\x20'+JSON[_0x5125ab(0x123)](_0x158879)+':\x20{\x0a\x20\x20\x20\x20'+JSON[_0x5125ab(0x123)](_0x5125ab(0x125))+':\x20'+JSON[_0x5125ab(0x123)](_0x2ce9ee)+_0x5125ab(0x127);})[_0x1a3217(0x134)](',\x0a');return _0x1a3217(0x131)+_0xe282bb+_0x1a3217(0x130);}function a149_0x530a(){const _0x56d677=['6969950KFOoWL','5285502wfmsZN','This\x20is\x20a\x20basic\x20page\x20template,\x20you\x20can\x20develop\x20based\x20on\x20it.','30toaTLA','Bu\x20bir\x20temel\x20sayfa\x20şablonudur.\x20Bu\x20temaplana\x20dayanarak\x20geliştirilebilir.','tr-TR','import\x20React\x20from\x20\x27react\x27;\x0aimport\x20{\x20Card,\x20Typography\x20}\x20from\x20\x27antd\x27;\x0aimport\x20{\x20useSdkClient,\x20useI18n,\x20useNavigate,\x20useLocation\x20}\x20from\x20\x22@/context/app-context\x22;\x0aimport\x20{\x20locales\x20}\x20from\x20\x27../locales\x27;\x0aimport\x20\x27./index.css\x27;\x0a\x0aconst\x20App\x20=\x20()\x20=>\x20{\x0a\x20\x20const\x20client\x20=\x20useSdkClient();\x20//\x20client\x20可以用于获取其他数据集的数据\x0a\x20\x20const\x20$i18n\x20=\x20useI18n();\x20//\x20国际化多语言\x20i18n\x20实例\x0a\x20\x20const\x20navigate\x20=\x20useNavigate();\x20//\x20react-router\x20navigate\x20导航实例\x0a\x20\x20const\x20location\x20=\x20useLocation();\x20//\x20浏览器\x20location\x20实例\x0a\x0a\x20\x20$i18n.addLocale(locales);\x20//\x20添加多语言词包\x0a\x0a\x20\x20return\x20(\x0a\x20\x20\x20\x20<div\x20className=\x22page-container\x22>\x0a\x20\x20\x20\x20\x20\x20<Card>\x0a\x20\x20\x20\x20\x20\x20\x20\x20<Typography>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<Typography.Title\x20level={2}>{','stringify','}</Typography.Title>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20<Typography.Paragraph>\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{$i18n.t(\x27pageDescription\x27,\x20\x27这是一个基础页面模板,你可以在此基础上进行开发。\x27)}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20</Typography.Paragraph>\x0a\x20\x20\x20\x20\x20\x20\x20\x20</Typography>\x0a\x20\x20\x20\x20\x20\x20</Card>\x0a\x20\x20\x20\x20</div>\x0a\x20\x20);\x0a};\x0a\x0aexport\x20default\x20App;\x0a','pageDescription','104bpsEuO',',\x0a\x20\x20}','これは基本ページテンプレートです。あなたは、これに基づいて開発できます。','这是一个基础页面模板,你可以在此基础上进行开发。','2385534CpvcsB','63854AirWjs','1083345haHEAt','map','179630RCkxue','4zEHieP','\x0a};\x0a','export\x20const\x20locales\x20=\x20{\x0a','Ini\x20adalah\x20sebuah\x20halaman\x20dasar.\x20Anda\x20dapat\x20mengembangkan\x20ini.','109480FmsFac','join','en-US'];a149_0x530a=function(){return _0x56d677;};return a149_0x530a();}export function buildInitialFiles(_0x3ee2e3,_0x548e29){return{'src/app/index.jsx':buildIndexFile(_0x3ee2e3),'src/app/index.css':buildStyleFile(),'src/locales/index.js':buildLocalesFile(_0x548e29)};}
@@ -1 +1 @@
1
- const a150_0x34c7c1=a150_0x11bd;(function(_0x2d0612,_0x67890){const _0x2d44a9=a150_0x11bd,_0x5203d5=_0x2d0612();while(!![]){try{const _0x237509=-parseInt(_0x2d44a9(0x7c))/0x1+parseInt(_0x2d44a9(0x80))/0x2+-parseInt(_0x2d44a9(0x91))/0x3+-parseInt(_0x2d44a9(0x8c))/0x4+parseInt(_0x2d44a9(0x92))/0x5+parseInt(_0x2d44a9(0x8e))/0x6+parseInt(_0x2d44a9(0x85))/0x7;if(_0x237509===_0x67890)break;else _0x5203d5['push'](_0x5203d5['shift']());}catch(_0xf7032e){_0x5203d5['push'](_0x5203d5['shift']());}}}(a150_0xa32f,0x5a239));import{getCustomPageSource,updateCustomPageContent}from'../../../core/api-client.js';function a150_0xa32f(){const _0x212477=['Would\x20save\x20all\x20files\x20of\x20Custom\x20Page\x20','Complete\x20page\x20files\x20as\x20JSON','664620gkEzsG','179830rFZAng','Custom\x20Page\x20update\x20did\x20not\x20create\x20a\x20new\x20version.','POST','cookie','compress','page-content','page','newVersion','206069NRwleE','write','str','pageId','59884gEwtKH','validation','Custom\x20Page\x20ID','Custom\x20Page\x20was\x20updated,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','Cannot\x20determine\x20the\x20appCode\x20for\x20Custom\x20Page\x20','3292247oOUspN','appcode','Updated\x20Custom\x20Page\x20','isInteger','trim','/smartapi/webcode/page/update/content','appCode','1691428DwauOY','pageContent','4100676nByGmx'];a150_0xa32f=function(){return _0x212477;};return a150_0xa32f();}function a150_0x11bd(_0x2ad0a1,_0xda4a4d){_0x2ad0a1=_0x2ad0a1-0x77;const _0xa32f53=a150_0xa32f();let _0x11bd99=_0xa32f53[_0x2ad0a1];return _0x11bd99;}import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,parseCustomPageContent,resolveCustomPageDevelopmentUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,validateCustomPageContent}from'./shared.js';export const pageCustomUpdate={'service':a150_0x34c7c1(0x7a),'command':'custom-update','description':'Save\x20all\x20files\x20of\x20a\x20Custom\x20Page','risk':a150_0x34c7c1(0x7d),'defaultOutputFormat':a150_0x34c7c1(0x78),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':'number','required':!![],'description':a150_0x34c7c1(0x82)},{'name':a150_0x34c7c1(0x79),'type':'string','required':!![],'description':a150_0x34c7c1(0x90)},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x1e0b27){const _0x4b2063=a150_0x34c7c1;readCustomPageId(_0x1e0b27),await validateCustomPageContent(parseCustomPageContent(_0x1e0b27['str'](_0x4b2063(0x79))));},async 'dryRun'(_0x1040ef){const _0x166b16=a150_0x34c7c1,_0x4dfd85=await readInput(_0x1040ef);return{'method':_0x166b16(0x94),'url':_0x166b16(0x8a),'body':{'id':_0x4dfd85[_0x166b16(0x7f)],'codeContent':_0x4dfd85[_0x166b16(0x8d)]},'description':_0x166b16(0x8f)+_0x4dfd85[_0x166b16(0x7f)]+'.'};},async 'execute'(_0x58f868){const _0x2d5acd=a150_0x34c7c1,_0x36b034=await readInput(_0x58f868),_0x2760a9=await updateCustomPageContent({'pageId':_0x36b034['pageId'],'pageContent':_0x36b034[_0x2d5acd(0x8d)]});if(!Number[_0x2d5acd(0x88)](_0x2760a9['newVersion'])||_0x2760a9[_0x2d5acd(0x7b)]<=0x0)throw CliErrors['apiError'](_0x2d5acd(0x93));const _0x5a34ae=buildCustomPageEditUrl(_0x36b034[_0x2d5acd(0x8b)],_0x36b034[_0x2d5acd(0x7f)]),_0x6c71b9=await resolveCustomPageDevelopmentUrl(_0x36b034[_0x2d5acd(0x8b)],_0x36b034['pageId'],_0x58f868[_0x2d5acd(0x77)]);return{'ok':!![],'data':buildMutationData(_0x36b034,_0x2760a9,_0x6c71b9,_0x5a34ae,_0x6c71b9?[]:[_0x2d5acd(0x83)]),'message':_0x2d5acd(0x87)+_0x36b034[_0x2d5acd(0x7f)]+'.'};}};async function readInput(_0x1b6786){const _0x1bb39f=a150_0x34c7c1,_0x543435=readCustomPageId(_0x1b6786),_0x46a5fc=_0x1b6786[_0x1bb39f(0x7e)](_0x1bb39f(0x86))[_0x1bb39f(0x89)]()||(await getCustomPageSource(_0x543435))[_0x1bb39f(0x8b)]?.['trim']();if(!_0x46a5fc)throw CliErrors[_0x1bb39f(0x81)](_0x1bb39f(0x84)+_0x543435+'.');return{'appCode':_0x46a5fc,'pageId':_0x543435,'pageContent':parseCustomPageContent(_0x1b6786[_0x1bb39f(0x7e)]('page-content'))};}function buildMutationData(_0x99b31,_0x1d1a24,_0x43c7ac,_0x2a495a,_0x175c42=[]){const _0x2e926e=a150_0x34c7c1;return{'operation':'page.custom-update','selector':{'appCode':_0x99b31[_0x2e926e(0x8b)],'pageId':_0x99b31[_0x2e926e(0x7f)]},'before':null,'after':{'pageId':_0x1d1a24?.[_0x2e926e(0x7f)]??_0x99b31['pageId'],'version':_0x1d1a24?.[_0x2e926e(0x7b)]??null,'pageContent':_0x99b31[_0x2e926e(0x8d)]},'dryRun':_0x1d1a24===undefined,'request':_0x99b31,..._0x43c7ac?{'pageUrl':_0x43c7ac}:{},..._0x2a495a?{'editPageUrl':_0x2a495a}:{},'warnings':_0x175c42};}
1
+ const a150_0x387bdb=a150_0x7f1a;function a150_0x5757(){const _0x5c5d76=['Custom\x20Page\x20was\x20updated,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','page','write','trim','Complete\x20page\x20files\x20as\x20JSON','str','119352uvzhuy','newVersion','page-content','50KAbSpR','number','appcode','3983892qMexOv','347711cgNhRA','cookie','99DUMgwg','custom-update','931073zBZAmj','pageId','431322tQtuae','Updated\x20Custom\x20Page\x20','POST','Save\x20all\x20files\x20of\x20a\x20Custom\x20Page','appCode','page.custom-update','609990pwrDOc','isInteger','Cannot\x20determine\x20the\x20appCode\x20for\x20Custom\x20Page\x20','4104603tRrqbt','3HRYRGO','string','pageContent','Custom\x20Page\x20ID','apiError','compress','72YDJakc'];a150_0x5757=function(){return _0x5c5d76;};return a150_0x5757();}function a150_0x7f1a(_0x358b4f,_0x16ec83){_0x358b4f=_0x358b4f-0x12c;const _0x5757c8=a150_0x5757();let _0x7f1a1c=_0x5757c8[_0x358b4f];return _0x7f1a1c;}(function(_0x1270a7,_0x5622d8){const _0x462605=a150_0x7f1a,_0x502bef=_0x1270a7();while(!![]){try{const _0x21479d=parseInt(_0x462605(0x138))/0x1+-parseInt(_0x462605(0x12d))/0x2+-parseInt(_0x462605(0x144))/0x3*(-parseInt(_0x462605(0x133))/0x4)+-parseInt(_0x462605(0x130))/0x5*(parseInt(_0x462605(0x13a))/0x6)+parseInt(_0x462605(0x134))/0x7*(parseInt(_0x462605(0x14a))/0x8)+-parseInt(_0x462605(0x143))/0x9+-parseInt(_0x462605(0x140))/0xa*(parseInt(_0x462605(0x136))/0xb);if(_0x21479d===_0x5622d8)break;else _0x502bef['push'](_0x502bef['shift']());}catch(_0x4b6c45){_0x502bef['push'](_0x502bef['shift']());}}}(a150_0x5757,0x902a3));import{getCustomPageSource,updateCustomPageContent}from'../../../core/api-client.js';import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,parseCustomPageContent,resolveCustomPageDevelopmentUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,validateCustomPageContent}from'./shared.js';export const pageCustomUpdate={'service':a150_0x387bdb(0x14c),'command':a150_0x387bdb(0x137),'description':a150_0x387bdb(0x13d),'risk':a150_0x387bdb(0x14d),'defaultOutputFormat':a150_0x387bdb(0x149),'structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a150_0x387bdb(0x131),'required':!![],'description':a150_0x387bdb(0x147)},{'name':a150_0x387bdb(0x12f),'type':a150_0x387bdb(0x145),'required':!![],'description':a150_0x387bdb(0x14f)},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x12c7db){const _0x6e144c=a150_0x387bdb;readCustomPageId(_0x12c7db),await validateCustomPageContent(parseCustomPageContent(_0x12c7db[_0x6e144c(0x12c)](_0x6e144c(0x12f))));},async 'dryRun'(_0xa9a1f2){const _0x74cd48=a150_0x387bdb,_0x50e25a=await readInput(_0xa9a1f2);return{'method':_0x74cd48(0x13c),'url':'/smartapi/webcode/page/update/content','body':{'id':_0x50e25a[_0x74cd48(0x139)],'codeContent':_0x50e25a[_0x74cd48(0x146)]},'description':'Would\x20save\x20all\x20files\x20of\x20Custom\x20Page\x20'+_0x50e25a[_0x74cd48(0x139)]+'.'};},async 'execute'(_0x1c1d3f){const _0x32ff3d=a150_0x387bdb,_0x12bb59=await readInput(_0x1c1d3f),_0xb92439=await updateCustomPageContent({'pageId':_0x12bb59[_0x32ff3d(0x139)],'pageContent':_0x12bb59[_0x32ff3d(0x146)]});if(!Number[_0x32ff3d(0x141)](_0xb92439[_0x32ff3d(0x12e)])||_0xb92439['newVersion']<=0x0)throw CliErrors[_0x32ff3d(0x148)]('Custom\x20Page\x20update\x20did\x20not\x20create\x20a\x20new\x20version.');const _0x50772c=buildCustomPageEditUrl(_0x12bb59['appCode'],_0x12bb59[_0x32ff3d(0x139)]),_0x5b8c1d=await resolveCustomPageDevelopmentUrl(_0x12bb59[_0x32ff3d(0x13e)],_0x12bb59[_0x32ff3d(0x139)],_0x1c1d3f[_0x32ff3d(0x135)]);return{'ok':!![],'data':buildMutationData(_0x12bb59,_0xb92439,_0x5b8c1d,_0x50772c,_0x5b8c1d?[]:[_0x32ff3d(0x14b)]),'message':_0x32ff3d(0x13b)+_0x12bb59[_0x32ff3d(0x139)]+'.'};}};async function readInput(_0x4a87eb){const _0x532a5f=a150_0x387bdb,_0x410f63=readCustomPageId(_0x4a87eb),_0x4b4d9f=_0x4a87eb[_0x532a5f(0x12c)](_0x532a5f(0x132))[_0x532a5f(0x14e)]()||(await getCustomPageSource(_0x410f63))[_0x532a5f(0x13e)]?.[_0x532a5f(0x14e)]();if(!_0x4b4d9f)throw CliErrors['validation'](_0x532a5f(0x142)+_0x410f63+'.');return{'appCode':_0x4b4d9f,'pageId':_0x410f63,'pageContent':parseCustomPageContent(_0x4a87eb[_0x532a5f(0x12c)](_0x532a5f(0x12f)))};}function buildMutationData(_0x1f26da,_0x5f3650,_0x5b656b,_0x904b89,_0x53c43e=[]){const _0x50faf6=a150_0x387bdb;return{'operation':_0x50faf6(0x13f),'selector':{'appCode':_0x1f26da[_0x50faf6(0x13e)],'pageId':_0x1f26da[_0x50faf6(0x139)]},'before':null,'after':{'pageId':_0x5f3650?.[_0x50faf6(0x139)]??_0x1f26da[_0x50faf6(0x139)],'version':_0x5f3650?.['newVersion']??null,'pageContent':_0x1f26da[_0x50faf6(0x146)]},'dryRun':_0x5f3650===undefined,'request':_0x1f26da,..._0x5b656b?{'pageUrl':_0x5b656b}:{},..._0x904b89?{'editPageUrl':_0x904b89}:{},'warnings':_0x53c43e};}
@@ -1 +1 @@
1
- function a151_0x8c18(_0x4308a3,_0x6072fa){_0x4308a3=_0x4308a3-0x150;const _0x5136d8=a151_0x5136();let _0x8c1810=_0x5136d8[_0x4308a3];return _0x8c1810;}const a151_0x439e1c=a151_0x8c18;(function(_0x46e4f6,_0x224620){const _0x578acc=a151_0x8c18,_0x37569d=_0x46e4f6();while(!![]){try{const _0x35191b=-parseInt(_0x578acc(0x151))/0x1*(-parseInt(_0x578acc(0x168))/0x2)+-parseInt(_0x578acc(0x167))/0x3*(-parseInt(_0x578acc(0x15e))/0x4)+parseInt(_0x578acc(0x15b))/0x5+parseInt(_0x578acc(0x161))/0x6+-parseInt(_0x578acc(0x154))/0x7+parseInt(_0x578acc(0x157))/0x8+-parseInt(_0x578acc(0x160))/0x9*(parseInt(_0x578acc(0x156))/0xa);if(_0x35191b===_0x224620)break;else _0x37569d['push'](_0x37569d['shift']());}catch(_0x5b4ddb){_0x37569d['push'](_0x37569d['shift']());}}}(a151_0x5136,0x24610));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assessDataListPageState,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';export const pageDataListStatus={'service':a151_0x439e1c(0x159),'command':'data-list-status','description':'Query\x20Data\x20List\x20Page\x20facts\x20for\x20a\x20dataset','risk':a151_0x439e1c(0x163),'defaultOutputFormat':a151_0x439e1c(0x152),'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a151_0x439e1c(0x162),'type':a151_0x439e1c(0x165),'description':'Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)'}],async 'validate'(_0x20436a){validateDatasetSelector(_0x20436a);},async 'dryRun'(_0x71b55b){const _0xef571=a151_0x439e1c,_0x37a5e2=await loadDatasetDetailForPage(_0x71b55b);return{'method':_0xef571(0x153),'url':_0xef571(0x15c)+_0x37a5e2[_0xef571(0x158)]+'/standard-page-status?appCode='+encodeURIComponent(_0x71b55b[_0xef571(0x164)]),'description':serializeDryRunDescription({'dataset':{'id':_0x37a5e2['id'],'code':_0x37a5e2['code'],'name':_0x37a5e2[_0xef571(0x150)]},'action':_0xef571(0x15d)})};},async 'execute'(_0x3e17d4){const _0x29039e=a151_0x439e1c,_0x50eee3=await loadDatasetDetailForPage(_0x3e17d4),_0x69052f=await loadDataListPageStatusForGenerate(_0x3e17d4,_0x50eee3[_0x29039e(0x158)]),_0x35807e=getUndeletedRelatedPages(_0x50eee3),_0x2a0d84=assessDataListPageState(_0x50eee3[_0x29039e(0x158)],_0x69052f,{'fallbackUndeletedPages':_0x35807e});return{'ok':!![],'data':{'datasetCode':_0x50eee3[_0x29039e(0x158)],'precheckSource':_0x69052f?.[_0x29039e(0x166)]??_0x29039e(0x15a),'status':_0x2a0d84['status'],'manualResolutionRequired':_0x2a0d84['manualResolutionRequired'],'nextAction':_0x2a0d84['nextAction'],'dataListPageStatus':_0x69052f,'relatedPages':{'total':_0x50eee3[_0x29039e(0x15f)][_0x29039e(0x155)],'undeletedCount':_0x35807e[_0x29039e(0x155)]}}};}};function a151_0x5136(){const _0x351e5f=['query-data-list-status','5384EyyOAh','relatedPages','9846ydqjCy','249888HNdBQF','alias','read','appCode','string','source','33CYKaEn','6DucwfI','name','86230vGskiu','compress','GET','288470wHAaIC','length','4450wXjOhs','2176008AGYiOO','code','page','related-pages-fallback','449515Xdsvfn','/smartapi/lovrabet/dataset/'];a151_0x5136=function(){return _0x351e5f;};return a151_0x5136();}
1
+ function a151_0x10de(_0x2df519,_0x20bf85){_0x2df519=_0x2df519-0xaf;const _0x478c3b=a151_0x478c();let _0x10de12=_0x478c3b[_0x2df519];return _0x10de12;}const a151_0x45a8e1=a151_0x10de;(function(_0x33dd3a,_0x3ba74f){const _0x3f0f14=a151_0x10de,_0x1b4e49=_0x33dd3a();while(!![]){try{const _0xc07db8=parseInt(_0x3f0f14(0xb4))/0x1*(parseInt(_0x3f0f14(0xb9))/0x2)+parseInt(_0x3f0f14(0xb7))/0x3*(parseInt(_0x3f0f14(0xc3))/0x4)+parseInt(_0x3f0f14(0xc1))/0x5*(parseInt(_0x3f0f14(0xc0))/0x6)+-parseInt(_0x3f0f14(0xb5))/0x7+parseInt(_0x3f0f14(0xb3))/0x8*(-parseInt(_0x3f0f14(0xc6))/0x9)+parseInt(_0x3f0f14(0xb8))/0xa+-parseInt(_0x3f0f14(0xb1))/0xb;if(_0xc07db8===_0x3ba74f)break;else _0x1b4e49['push'](_0x1b4e49['shift']());}catch(_0x2abf65){_0x1b4e49['push'](_0x1b4e49['shift']());}}}(a151_0x478c,0x284b2));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a151_0x478c(){const _0x29adbf=['string','compress','5586LSPPhy','1275fKolCc','alias','96244iFrmeD','related-pages-fallback','GET','1969407hQaOqq','code','appCode','read','2536952vSocab','status','8ypDpJT','113SDLGFG','866005kePCIZ','relatedPages','33cGdwCp','1771500AKNYWV','1044ZQZaky','length','Query\x20Data\x20List\x20Page\x20facts\x20for\x20a\x20dataset','nextAction','page'];a151_0x478c=function(){return _0x29adbf;};return a151_0x478c();}import{assessDataListPageState,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';export const pageDataListStatus={'service':a151_0x45a8e1(0xbd),'command':'data-list-status','description':a151_0x45a8e1(0xbb),'risk':a151_0x45a8e1(0xb0),'defaultOutputFormat':a151_0x45a8e1(0xbf),'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a151_0x45a8e1(0xc2),'type':a151_0x45a8e1(0xbe),'description':'Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)'}],async 'validate'(_0x6604cd){validateDatasetSelector(_0x6604cd);},async 'dryRun'(_0x3e7b8f){const _0x2983e3=a151_0x45a8e1,_0x3bad16=await loadDatasetDetailForPage(_0x3e7b8f);return{'method':_0x2983e3(0xc5),'url':'/smartapi/lovrabet/dataset/'+_0x3bad16[_0x2983e3(0xc7)]+'/standard-page-status?appCode='+encodeURIComponent(_0x3e7b8f[_0x2983e3(0xaf)]),'description':serializeDryRunDescription({'dataset':{'id':_0x3bad16['id'],'code':_0x3bad16['code'],'name':_0x3bad16['name']},'action':'query-data-list-status'})};},async 'execute'(_0x32a4a8){const _0x4d8890=a151_0x45a8e1,_0x1852c9=await loadDatasetDetailForPage(_0x32a4a8),_0x5d6770=await loadDataListPageStatusForGenerate(_0x32a4a8,_0x1852c9[_0x4d8890(0xc7)]),_0x44a402=getUndeletedRelatedPages(_0x1852c9),_0x489906=assessDataListPageState(_0x1852c9[_0x4d8890(0xc7)],_0x5d6770,{'fallbackUndeletedPages':_0x44a402});return{'ok':!![],'data':{'datasetCode':_0x1852c9[_0x4d8890(0xc7)],'precheckSource':_0x5d6770?.['source']??_0x4d8890(0xc4),'status':_0x489906[_0x4d8890(0xb2)],'manualResolutionRequired':_0x489906['manualResolutionRequired'],'nextAction':_0x489906[_0x4d8890(0xbc)],'dataListPageStatus':_0x5d6770,'relatedPages':{'total':_0x1852c9[_0x4d8890(0xb6)]['length'],'undeletedCount':_0x44a402[_0x4d8890(0xba)]}}};}};
@@ -1 +1 @@
1
- const a152_0x2cb193=a152_0x1eb5;(function(_0x41955e,_0x55efea){const _0x620dd1=a152_0x1eb5,_0x339b38=_0x41955e();while(!![]){try{const _0x6d98b2=-parseInt(_0x620dd1(0xb2))/0x1*(-parseInt(_0x620dd1(0x88))/0x2)+parseInt(_0x620dd1(0xb1))/0x3*(parseInt(_0x620dd1(0x8a))/0x4)+-parseInt(_0x620dd1(0x91))/0x5+-parseInt(_0x620dd1(0x8d))/0x6+parseInt(_0x620dd1(0x82))/0x7*(-parseInt(_0x620dd1(0x83))/0x8)+-parseInt(_0x620dd1(0xa2))/0x9+parseInt(_0x620dd1(0xab))/0xa;if(_0x6d98b2===_0x55efea)break;else _0x339b38['push'](_0x339b38['shift']());}catch(_0x27fc9a){_0x339b38['push'](_0x339b38['shift']());}}}(a152_0x4d24,0xa973c));function a152_0x4d24(){const _0x5df1b3=['page-type','Actually\x20execute\x20the\x20generation.\x20Without\x20this\x20flag,\x20only\x20a\x20dry-run\x20preview\x20is\x20shown.','Submitted\x20a\x20generate\x20task','PARTIAL_SUCCESS','4385550tPCtzc','Reusing\x20an\x20existing\x20generate\x20task','page','write','reused','page\x20generate-start\x20does\x20not\x20accept\x20--page-pattern.','2782209GtmWWJ','2FLLZJX','compress','code','related-pages-fallback','Dry-run\x20preview\x20(pass\x20--apply\x20to\x20execute\x20the\x20generation)','DATA_LIST\x20currently\x20has\x20one\x20fixed\x20pattern:\x20CRUD_PAGE_SET.','SUCCESS','7XnYbTL','7061048blyEli','manualResolutionRequired','currentStep','number','Start\x20async\x20Data\x20List\x20Page\x20generation\x20from\x20a\x20dataset','1056426LXOiDG','precheck','4sarYuW','fieldCount','page\x20generate-start\x20does\x20not\x20accept\x20--page-type.','601428rWBzCQ','status','dataset','DATA_LIST','181550UivuYI','nextAction','progressRate','/generate-standard-pages/start','message','appCode','Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','page-pattern','taskId','CRUD_PAGE_SET','clientOperationId','allowGenerate','string','alias','operationId','source','POST','6382161bkTTzt','name','This\x20command\x20always\x20generates\x20a\x20DATA_LIST\x20page\x20from\x20a\x20dataset.','apply','generate-start'];a152_0x4d24=function(){return _0x5df1b3;};return a152_0x4d24();}import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assessGenerateOperationState,assessDataListPageState,buildPageGenerateOperationStatusQueryCommand,buildDataListPageStatusQueryCommand,createPageGenerateClientOperationId,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';import{startGenerateDataListPages}from'../../core/api-client.js';export const pageGenerateStart={'service':a152_0x2cb193(0xad),'command':a152_0x2cb193(0xa6),'description':a152_0x2cb193(0x87),'risk':a152_0x2cb193(0xae),'defaultOutputFormat':a152_0x2cb193(0xb3),'rejectedFlags':[{'name':a152_0x2cb193(0xa7),'message':a152_0x2cb193(0x8c),'hint':a152_0x2cb193(0xa4)},{'name':a152_0x2cb193(0x98),'message':a152_0x2cb193(0xb0),'hint':a152_0x2cb193(0x80)}],'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a152_0x2cb193(0x9e),'type':a152_0x2cb193(0x9d),'description':a152_0x2cb193(0x97)},{'name':a152_0x2cb193(0xa5),'type':'boolean','description':a152_0x2cb193(0xa8)}],async 'validate'(_0x4200a4){validateDatasetSelector(_0x4200a4);},async 'dryRun'(_0x39632a){const _0x34a38d=a152_0x2cb193,_0x28f20=await prepare(_0x39632a);return{'method':_0x34a38d(0xa1),'url':'/smartapi/lovrabet/dataset/'+_0x28f20[_0x34a38d(0x8f)]['code']+_0x34a38d(0x94),'body':{'appCode':_0x39632a[_0x34a38d(0x96)],'clientOperationId':_0x28f20[_0x34a38d(0x9b)]},'description':serializeDryRunDescription({'dataset':{'id':_0x28f20[_0x34a38d(0x8f)]['id'],'code':_0x28f20['dataset'][_0x34a38d(0xb4)],'name':_0x28f20[_0x34a38d(0x8f)][_0x34a38d(0xa3)],'fieldCount':_0x28f20[_0x34a38d(0x8f)][_0x34a38d(0x8b)]},'precheckSource':_0x28f20['dataListPageStatus']?.[_0x34a38d(0xa0)]??_0x34a38d(0xb5),'action':'generate-start','clientOperationId':_0x28f20[_0x34a38d(0x9b)],'plannedStatus':_0x28f20['precheck'][_0x34a38d(0x8e)],'reason':_0x28f20[_0x34a38d(0x89)][_0x34a38d(0x95)]})};},async 'execute'(_0x48bfb9){const _0x10ca18=a152_0x2cb193;if(!_0x48bfb9['bool']('apply')){const _0x393636=await pageGenerateStart['dryRun'](_0x48bfb9);return{'ok':!![],'message':_0x10ca18(0x7f),'data':_0x393636};}const _0x1d2aab=await prepare(_0x48bfb9);if(!_0x1d2aab[_0x10ca18(0x89)][_0x10ca18(0x9c)])return{'ok':![],'message':_0x1d2aab[_0x10ca18(0x89)]['message'],'data':{'datasetCode':_0x1d2aab[_0x10ca18(0x8f)][_0x10ca18(0xb4)],'pageType':'DATA_LIST','pagePattern':_0x10ca18(0x9a),'clientOperationId':_0x1d2aab['clientOperationId'],'precheckSource':_0x1d2aab['dataListPageStatus']?.[_0x10ca18(0xa0)]??'related-pages-fallback','status':_0x1d2aab['precheck']['status'],'manualResolutionRequired':_0x1d2aab['precheck']['manualResolutionRequired'],'nextAction':_0x1d2aab[_0x10ca18(0x89)][_0x10ca18(0x92)],'query':{'command':buildDataListPageStatusQueryCommand(_0x1d2aab[_0x10ca18(0x8f)]['code'],_0x48bfb9[_0x10ca18(0x96)])},'dataListPageStatus':_0x1d2aab['dataListPageStatus']}};const _0x56e43e=await startGenerateDataListPages(_0x48bfb9[_0x10ca18(0x96)],_0x1d2aab[_0x10ca18(0x8f)][_0x10ca18(0xb4)],{'clientOperationId':_0x1d2aab[_0x10ca18(0x9b)]}),_0x27cb84=_0x56e43e['status']===_0x10ca18(0x81)||_0x56e43e['status']===_0x10ca18(0xaa)?await loadDataListPageStatusForGenerate(_0x48bfb9,_0x1d2aab[_0x10ca18(0x8f)][_0x10ca18(0xb4)]):null,_0x186b83=assessGenerateOperationState(_0x1d2aab[_0x10ca18(0x8f)]['code'],_0x56e43e[_0x10ca18(0x8e)],_0x27cb84);return{'ok':!![],'message':_0x56e43e[_0x10ca18(0xaf)]?_0x10ca18(0xac):_0x10ca18(0xa9),'data':{'datasetCode':_0x1d2aab[_0x10ca18(0x8f)][_0x10ca18(0xb4)],'appCode':_0x48bfb9[_0x10ca18(0x96)],'pageType':_0x10ca18(0x90),'pagePattern':_0x10ca18(0x9a),'taskId':_0x56e43e[_0x10ca18(0x99)]??null,'operationId':_0x56e43e[_0x10ca18(0x9f)]??null,'clientOperationId':_0x1d2aab[_0x10ca18(0x9b)],'jobStatus':_0x56e43e[_0x10ca18(0x8e)]??null,'progressRate':typeof _0x56e43e[_0x10ca18(0x93)]===_0x10ca18(0x86)?_0x56e43e[_0x10ca18(0x93)]:null,'currentStep':_0x56e43e[_0x10ca18(0x85)]??null,'reused':_0x56e43e[_0x10ca18(0xaf)]===!![],'status':_0x186b83['status'],'manualResolutionRequired':_0x186b83[_0x10ca18(0x84)],'nextAction':_0x186b83[_0x10ca18(0x92)],'query':{'command':buildPageGenerateOperationStatusQueryCommand(_0x1d2aab[_0x10ca18(0x8f)][_0x10ca18(0xb4)],{'appCode':_0x48bfb9[_0x10ca18(0x96)],'taskId':_0x56e43e[_0x10ca18(0x99)],'operationId':_0x56e43e[_0x10ca18(0x9f)],'clientOperationId':_0x1d2aab[_0x10ca18(0x9b)]})},'dataListPageStatus':_0x27cb84}};}};function a152_0x1eb5(_0x3cdcf7,_0x4d5db3){_0x3cdcf7=_0x3cdcf7-0x7f;const _0x4d245c=a152_0x4d24();let _0x1eb56b=_0x4d245c[_0x3cdcf7];return _0x1eb56b;}async function prepare(_0x5c3b1b){const _0x571e40=a152_0x2cb193,_0x178171=await loadDatasetDetailForPage(_0x5c3b1b),_0x1803e6=await loadDataListPageStatusForGenerate(_0x5c3b1b,_0x178171[_0x571e40(0xb4)]),_0x5bdff3=getUndeletedRelatedPages(_0x178171);return{'dataset':_0x178171,'dataListPageStatus':_0x1803e6,'clientOperationId':createPageGenerateClientOperationId(),'precheck':assessDataListPageState(_0x178171[_0x571e40(0xb4)],_0x1803e6,{'fallbackUndeletedPages':_0x5bdff3})};}
1
+ function a152_0x580f(_0x2ea5c9,_0x15cc66){_0x2ea5c9=_0x2ea5c9-0x9b;const _0x3b8ed3=a152_0x3b8e();let _0x580f6d=_0x3b8ed3[_0x2ea5c9];return _0x580f6d;}const a152_0x33ea98=a152_0x580f;(function(_0x44f4e6,_0x4d9037){const _0x6c9b05=a152_0x580f,_0x26479e=_0x44f4e6();while(!![]){try{const _0xd0e954=-parseInt(_0x6c9b05(0xb9))/0x1*(parseInt(_0x6c9b05(0xa9))/0x2)+parseInt(_0x6c9b05(0xb2))/0x3*(-parseInt(_0x6c9b05(0xca))/0x4)+parseInt(_0x6c9b05(0xa1))/0x5+-parseInt(_0x6c9b05(0xc9))/0x6+parseInt(_0x6c9b05(0xcc))/0x7+parseInt(_0x6c9b05(0x9f))/0x8*(-parseInt(_0x6c9b05(0xb5))/0x9)+parseInt(_0x6c9b05(0xb4))/0xa;if(_0xd0e954===_0x4d9037)break;else _0x26479e['push'](_0x26479e['shift']());}catch(_0x20333c){_0x26479e['push'](_0x26479e['shift']());}}}(a152_0x3b8e,0x7de93));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assessGenerateOperationState,assessDataListPageState,buildPageGenerateOperationStatusQueryCommand,buildDataListPageStatusQueryCommand,createPageGenerateClientOperationId,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';import{startGenerateDataListPages}from'../../core/api-client.js';export const pageGenerateStart={'service':a152_0x33ea98(0xb0),'command':a152_0x33ea98(0xc0),'description':a152_0x33ea98(0xa6),'risk':a152_0x33ea98(0xa2),'defaultOutputFormat':a152_0x33ea98(0xab),'rejectedFlags':[{'name':a152_0x33ea98(0xa3),'message':a152_0x33ea98(0x9d),'hint':a152_0x33ea98(0xbe)},{'name':a152_0x33ea98(0xb6),'message':a152_0x33ea98(0xbb),'hint':a152_0x33ea98(0xc6)}],'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a152_0x33ea98(0xba),'type':a152_0x33ea98(0xce),'description':'Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)'},{'name':'apply','type':a152_0x33ea98(0xa4),'description':a152_0x33ea98(0xc3)}],async 'validate'(_0x114a05){validateDatasetSelector(_0x114a05);},async 'dryRun'(_0x2a7ebb){const _0x3e6c98=a152_0x33ea98,_0x1dc210=await prepare(_0x2a7ebb);return{'method':'POST','url':_0x3e6c98(0xb1)+_0x1dc210[_0x3e6c98(0xa8)][_0x3e6c98(0xb3)]+_0x3e6c98(0xb7),'body':{'appCode':_0x2a7ebb[_0x3e6c98(0xbd)],'clientOperationId':_0x1dc210[_0x3e6c98(0xaf)]},'description':serializeDryRunDescription({'dataset':{'id':_0x1dc210[_0x3e6c98(0xa8)]['id'],'code':_0x1dc210[_0x3e6c98(0xa8)][_0x3e6c98(0xb3)],'name':_0x1dc210[_0x3e6c98(0xa8)][_0x3e6c98(0xad)],'fieldCount':_0x1dc210[_0x3e6c98(0xa8)][_0x3e6c98(0xc2)]},'precheckSource':_0x1dc210['dataListPageStatus']?.[_0x3e6c98(0xd2)]??'related-pages-fallback','action':_0x3e6c98(0xc0),'clientOperationId':_0x1dc210[_0x3e6c98(0xaf)],'plannedStatus':_0x1dc210[_0x3e6c98(0xa7)][_0x3e6c98(0xc4)],'reason':_0x1dc210[_0x3e6c98(0xa7)]['message']})};},async 'execute'(_0x3ce5b5){const _0x3fc9ce=a152_0x33ea98;if(!_0x3ce5b5[_0x3fc9ce(0xaa)](_0x3fc9ce(0xae))){const _0x50e028=await pageGenerateStart[_0x3fc9ce(0xc5)](_0x3ce5b5);return{'ok':!![],'message':_0x3fc9ce(0xa0),'data':_0x50e028};}const _0x59cfa7=await prepare(_0x3ce5b5);if(!_0x59cfa7['precheck']['allowGenerate'])return{'ok':![],'message':_0x59cfa7['precheck'][_0x3fc9ce(0xd0)],'data':{'datasetCode':_0x59cfa7['dataset'][_0x3fc9ce(0xb3)],'pageType':_0x3fc9ce(0xd1),'pagePattern':_0x3fc9ce(0x9e),'clientOperationId':_0x59cfa7['clientOperationId'],'precheckSource':_0x59cfa7['dataListPageStatus']?.[_0x3fc9ce(0xd2)]??_0x3fc9ce(0xc7),'status':_0x59cfa7['precheck']['status'],'manualResolutionRequired':_0x59cfa7[_0x3fc9ce(0xa7)]['manualResolutionRequired'],'nextAction':_0x59cfa7[_0x3fc9ce(0xa7)][_0x3fc9ce(0xbc)],'query':{'command':buildDataListPageStatusQueryCommand(_0x59cfa7['dataset'][_0x3fc9ce(0xb3)],_0x3ce5b5[_0x3fc9ce(0xbd)])},'dataListPageStatus':_0x59cfa7[_0x3fc9ce(0x9b)]}};const _0x423e7d=await startGenerateDataListPages(_0x3ce5b5[_0x3fc9ce(0xbd)],_0x59cfa7[_0x3fc9ce(0xa8)][_0x3fc9ce(0xb3)],{'clientOperationId':_0x59cfa7['clientOperationId']}),_0x1cc235=_0x423e7d[_0x3fc9ce(0xc4)]===_0x3fc9ce(0xcb)||_0x423e7d['status']===_0x3fc9ce(0xcd)?await loadDataListPageStatusForGenerate(_0x3ce5b5,_0x59cfa7[_0x3fc9ce(0xa8)][_0x3fc9ce(0xb3)]):null,_0x1fa1d3=assessGenerateOperationState(_0x59cfa7[_0x3fc9ce(0xa8)]['code'],_0x423e7d[_0x3fc9ce(0xc4)],_0x1cc235);return{'ok':!![],'message':_0x423e7d[_0x3fc9ce(0xd3)]?_0x3fc9ce(0xc1):_0x3fc9ce(0xac),'data':{'datasetCode':_0x59cfa7[_0x3fc9ce(0xa8)][_0x3fc9ce(0xb3)],'appCode':_0x3ce5b5[_0x3fc9ce(0xbd)],'pageType':_0x3fc9ce(0xd1),'pagePattern':_0x3fc9ce(0x9e),'taskId':_0x423e7d[_0x3fc9ce(0xb8)]??null,'operationId':_0x423e7d[_0x3fc9ce(0xbf)]??null,'clientOperationId':_0x59cfa7[_0x3fc9ce(0xaf)],'jobStatus':_0x423e7d[_0x3fc9ce(0xc4)]??null,'progressRate':typeof _0x423e7d[_0x3fc9ce(0xa5)]===_0x3fc9ce(0x9c)?_0x423e7d['progressRate']:null,'currentStep':_0x423e7d[_0x3fc9ce(0xc8)]??null,'reused':_0x423e7d['reused']===!![],'status':_0x1fa1d3['status'],'manualResolutionRequired':_0x1fa1d3[_0x3fc9ce(0xcf)],'nextAction':_0x1fa1d3['nextAction'],'query':{'command':buildPageGenerateOperationStatusQueryCommand(_0x59cfa7[_0x3fc9ce(0xa8)][_0x3fc9ce(0xb3)],{'appCode':_0x3ce5b5['appCode'],'taskId':_0x423e7d['taskId'],'operationId':_0x423e7d[_0x3fc9ce(0xbf)],'clientOperationId':_0x59cfa7[_0x3fc9ce(0xaf)]})},'dataListPageStatus':_0x1cc235}};}};function a152_0x3b8e(){const _0x2fd0a9=['DATA_LIST\x20currently\x20has\x20one\x20fixed\x20pattern:\x20CRUD_PAGE_SET.','related-pages-fallback','currentStep','2444784BKMREy','11644MbriXc','SUCCESS','5705504YDKodq','PARTIAL_SUCCESS','string','manualResolutionRequired','message','DATA_LIST','source','reused','dataListPageStatus','number','page\x20generate-start\x20does\x20not\x20accept\x20--page-type.','CRUD_PAGE_SET','1373800kRkMle','Dry-run\x20preview\x20(pass\x20--apply\x20to\x20execute\x20the\x20generation)','3514095tlEtov','write','page-type','boolean','progressRate','Start\x20async\x20Data\x20List\x20Page\x20generation\x20from\x20a\x20dataset','precheck','dataset','620uJJsen','bool','compress','Submitted\x20a\x20generate\x20task','name','apply','clientOperationId','page','/smartapi/lovrabet/dataset/','591nhqqWC','code','13049210pPoQfv','18qIxaKn','page-pattern','/generate-standard-pages/start','taskId','3170oqkJfo','alias','page\x20generate-start\x20does\x20not\x20accept\x20--page-pattern.','nextAction','appCode','This\x20command\x20always\x20generates\x20a\x20DATA_LIST\x20page\x20from\x20a\x20dataset.','operationId','generate-start','Reusing\x20an\x20existing\x20generate\x20task','fieldCount','Actually\x20execute\x20the\x20generation.\x20Without\x20this\x20flag,\x20only\x20a\x20dry-run\x20preview\x20is\x20shown.','status','dryRun'];a152_0x3b8e=function(){return _0x2fd0a9;};return a152_0x3b8e();}async function prepare(_0x1c68b0){const _0xbe459d=a152_0x33ea98,_0x70d160=await loadDatasetDetailForPage(_0x1c68b0),_0x54ac79=await loadDataListPageStatusForGenerate(_0x1c68b0,_0x70d160['code']),_0x328386=getUndeletedRelatedPages(_0x70d160);return{'dataset':_0x70d160,'dataListPageStatus':_0x54ac79,'clientOperationId':createPageGenerateClientOperationId(),'precheck':assessDataListPageState(_0x70d160[_0xbe459d(0xb3)],_0x54ac79,{'fallbackUndeletedPages':_0x328386})};}