@lovrabet/rabetbase-cli 2.5.7-beta.1 → 2.5.8-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.
- package/lib/api/api-doc.js +1 -1
- package/lib/api/api-group.js +1 -1
- package/lib/api/fetch-model-list.js +1 -1
- package/lib/api/generate-api-file.js +1 -1
- package/lib/api/generate-sdk-config-file.js +1 -1
- package/lib/api/legacy-api-file.js +1 -1
- package/lib/api/model-registry-file.js +1 -1
- package/lib/api/model-registry-scaffold.js +1 -1
- package/lib/api/model-source.js +1 -1
- package/lib/auth/auth-server-ui.js +1 -1
- package/lib/auth/auth-server.js +1 -1
- package/lib/auth/constant.js +1 -1
- package/lib/auth/get-cookie.js +1 -1
- package/lib/auth/get-session-user.js +1 -1
- package/lib/auth/is-session-valid.js +1 -1
- package/lib/auth/login-success-html.js +1 -1
- package/lib/auth/logout.js +1 -1
- package/lib/cli-flags.js +1 -1
- package/lib/cli.js +1 -1
- package/lib/commands/api/generate.js +1 -1
- package/lib/commands/api/index.js +1 -1
- package/lib/commands/api/list.js +1 -1
- package/lib/commands/api/pull.js +1 -1
- package/lib/commands/api/shared.js +1 -1
- package/lib/commands/app/detail.js +1 -1
- package/lib/commands/app/index.js +1 -1
- package/lib/commands/app/list.js +1 -1
- package/lib/commands/app/members-list.js +1 -1
- package/lib/commands/app/remote-directory.js +1 -1
- package/lib/commands/app/shared.js +1 -1
- package/lib/commands/app-config/delete.js +1 -1
- package/lib/commands/app-config/get.js +1 -1
- package/lib/commands/app-config/index.js +1 -1
- package/lib/commands/app-config/list.js +1 -1
- package/lib/commands/app-config/set.js +1 -1
- package/lib/commands/app-config/shared.js +1 -1
- package/lib/commands/auth/index.js +1 -1
- package/lib/commands/bff/create.js +1 -1
- package/lib/commands/bff/delete.js +1 -1
- package/lib/commands/bff/detail.js +1 -1
- package/lib/commands/bff/index.js +1 -1
- package/lib/commands/bff/list.js +1 -1
- package/lib/commands/bff/logs.js +1 -1
- package/lib/commands/bff/pull.js +1 -1
- package/lib/commands/bff/push.js +1 -1
- package/lib/commands/bff/status.js +1 -1
- package/lib/commands/cli-skill/index.js +1 -1
- package/lib/commands/cli-update.js +1 -1
- package/lib/commands/codegen/index.js +1 -1
- package/lib/commands/codegen/sdk.js +1 -1
- package/lib/commands/codegen/sql.js +1 -1
- package/lib/commands/common/app-registry.js +1 -1
- package/lib/commands/common/app-selector.js +1 -1
- package/lib/commands/common/async-task.js +1 -1
- package/lib/commands/common/dry-run.js +1 -1
- package/lib/commands/common/flags.js +1 -1
- package/lib/commands/common/local-file.js +1 -1
- package/lib/commands/common/validate.js +1 -1
- package/lib/commands/config/delete.js +1 -1
- package/lib/commands/config/get.js +1 -1
- package/lib/commands/config/index.js +1 -1
- package/lib/commands/config/init.js +1 -1
- package/lib/commands/config/list.js +1 -1
- package/lib/commands/config/set.js +1 -1
- package/lib/commands/config/shared.js +1 -1
- package/lib/commands/dataset/batch-design.js +1 -1
- package/lib/commands/dataset/business-group-update.js +1 -1
- package/lib/commands/dataset/business-groups.js +1 -1
- package/lib/commands/dataset/capability.js +1 -1
- package/lib/commands/dataset/cross-relation-create.js +1 -1
- package/lib/commands/dataset/cross-relation-delete.js +1 -1
- package/lib/commands/dataset/cross-relation-list.js +1 -1
- package/lib/commands/dataset/cross-relation-shared.js +1 -1
- package/lib/commands/dataset/cross-relation-update.js +1 -1
- package/lib/commands/dataset/delete.js +1 -1
- package/lib/commands/dataset/design-context.js +1 -1
- package/lib/commands/dataset/design-start.js +1 -1
- package/lib/commands/dataset/design-status.js +1 -1
- package/lib/commands/dataset/design-sync-retry.js +1 -1
- package/lib/commands/dataset/design-sync-status.js +1 -1
- package/lib/commands/dataset/design-validate.js +1 -1
- package/lib/commands/dataset/detail.js +1 -1
- package/lib/commands/dataset/extend-update.js +1 -1
- package/lib/commands/dataset/field-restore.js +1 -1
- package/lib/commands/dataset/field-update.js +1 -1
- package/lib/commands/dataset/generate.js +1 -1
- package/lib/commands/dataset/index.js +1 -1
- package/lib/commands/dataset/list.js +1 -1
- package/lib/commands/dataset/operations.js +1 -1
- package/lib/commands/dataset/relation-audit.js +1 -1
- package/lib/commands/dataset/relation-create.js +1 -1
- package/lib/commands/dataset/relation-delete.js +1 -1
- package/lib/commands/dataset/relation-shared.js +1 -1
- package/lib/commands/dataset/relation-update.js +1 -1
- package/lib/commands/dataset/relations.js +1 -1
- package/lib/commands/dataset/rename.js +1 -1
- package/lib/commands/dataset/restore.js +1 -1
- package/lib/commands/dataset/user-deleted-field-list.js +1 -1
- package/lib/commands/db/analysis-batching.js +1 -1
- package/lib/commands/db/analyze-batch-plan.js +1 -1
- package/lib/commands/db/analyze-cancel.js +1 -1
- package/lib/commands/db/analyze-start.js +1 -1
- package/lib/commands/db/analyze-status.js +1 -1
- package/lib/commands/db/create.js +1 -1
- package/lib/commands/db/cross-db-analysis-shared.js +1 -1
- package/lib/commands/db/cross-db-analyze-latest.js +1 -1
- package/lib/commands/db/cross-db-analyze-start.js +1 -1
- package/lib/commands/db/cross-db-analyze-status.js +1 -1
- package/lib/commands/db/delete.js +1 -1
- package/lib/commands/db/detail.js +1 -1
- package/lib/commands/db/diff-refresh-start.js +1 -1
- package/lib/commands/db/diff-refresh-status.js +1 -1
- package/lib/commands/db/diff.js +1 -1
- package/lib/commands/db/index.js +1 -1
- package/lib/commands/db/list.js +1 -1
- package/lib/commands/db/shared.js +1 -1
- package/lib/commands/db/table-diff-shared.js +1 -1
- package/lib/commands/db/tables.js +1 -1
- package/lib/commands/db/test.js +1 -1
- package/lib/commands/db/update.js +1 -1
- package/lib/commands/deployment/index.js +1 -1
- package/lib/commands/deployment/sync-all.js +1 -1
- package/lib/commands/deployment/sync-jobs.js +1 -1
- package/lib/commands/deployment/sync-status.js +1 -1
- package/lib/commands/doctor.js +1 -1
- package/lib/commands/file/index.js +1 -1
- package/lib/commands/flow/create.js +1 -1
- package/lib/commands/flow/detail.js +1 -1
- package/lib/commands/flow/index.js +1 -1
- package/lib/commands/flow/list.js +1 -1
- package/lib/commands/flow/page-list.js +1 -1
- package/lib/commands/flow/publish.js +1 -1
- package/lib/commands/flow/runtime-resources-shared.js +1 -1
- package/lib/commands/flow/runtime-role-list.js +1 -1
- package/lib/commands/flow/runtime-role-user-list.js +1 -1
- package/lib/commands/flow/runtime-user-search.js +1 -1
- package/lib/commands/flow/shared.js +1 -1
- package/lib/commands/flow/update.js +1 -1
- package/lib/commands/flow/validate.js +1 -1
- package/lib/commands/instant-api-policy/current.js +1 -1
- package/lib/commands/instant-api-policy/index.js +1 -1
- package/lib/commands/instant-api-policy/init.js +1 -1
- package/lib/commands/instant-api-policy/publish.js +1 -1
- package/lib/commands/instant-api-policy/pull.js +1 -1
- package/lib/commands/instant-api-policy/revision.js +1 -1
- package/lib/commands/instant-api-policy/revisions.js +1 -1
- package/lib/commands/instant-api-policy/rollback.js +1 -1
- package/lib/commands/instant-api-policy/shared.js +1 -1
- package/lib/commands/instant-api-policy/validate.js +1 -1
- package/lib/commands/issue/index.js +1 -1
- package/lib/commands/issue/nudge.js +1 -1
- package/lib/commands/issue/report.js +1 -1
- package/lib/commands/issue/shared.js +1 -1
- package/lib/commands/kb/create.js +1 -1
- package/lib/commands/kb/delete.js +1 -1
- package/lib/commands/kb/detail.js +1 -1
- package/lib/commands/kb/index.js +1 -1
- package/lib/commands/kb/list.js +1 -1
- package/lib/commands/kb/search.js +1 -1
- package/lib/commands/kb/shared.js +1 -1
- package/lib/commands/kb/update.js +1 -1
- package/lib/commands/logs/index.js +1 -1
- package/lib/commands/menu/asset-update.js +1 -1
- package/lib/commands/menu/delete.js +1 -1
- package/lib/commands/menu/external-link-create.js +1 -1
- package/lib/commands/menu/external-link-update.js +1 -1
- package/lib/commands/menu/group-create.js +1 -1
- package/lib/commands/menu/group-update.js +1 -1
- package/lib/commands/menu/index.js +1 -1
- package/lib/commands/menu/list.js +1 -1
- package/lib/commands/menu/move.js +1 -1
- package/lib/commands/menu/regroup-start.js +1 -1
- package/lib/commands/menu/rename.js +1 -1
- package/lib/commands/menu/shared/compare-table.js +1 -1
- package/lib/commands/menu/shared/delete-plan.js +1 -1
- package/lib/commands/menu/shared/facts.js +1 -1
- package/lib/commands/menu/shared/index.js +1 -1
- package/lib/commands/menu/shared/inquirer.js +1 -1
- package/lib/commands/menu/shared/local-pages.js +1 -1
- package/lib/commands/menu/shared/logic.js +1 -1
- package/lib/commands/menu/shared/mutations.js +1 -1
- package/lib/commands/menu/shared/path.js +1 -1
- package/lib/commands/menu/shared/service.js +1 -1
- package/lib/commands/menu/shared/subapp-assets.js +1 -1
- package/lib/commands/menu/shared/sync-core.js +1 -1
- package/lib/commands/menu/shared/update-core.js +1 -1
- package/lib/commands/menu/shared/valid-url.js +1 -1
- package/lib/commands/menu/subapp-assets-status.js +1 -1
- package/lib/commands/menu/subapp-assets-update.js +1 -1
- package/lib/commands/menu/sync.js +1 -1
- package/lib/commands/menu/visibility-update.js +1 -1
- package/lib/commands/notification/config-create.js +1 -1
- package/lib/commands/notification/config-delete.js +1 -1
- package/lib/commands/notification/config-list.js +1 -1
- package/lib/commands/notification/config-update.js +1 -1
- package/lib/commands/notification/index.js +1 -1
- package/lib/commands/notification/shared.js +1 -1
- package/lib/commands/ocr/index.js +1 -1
- package/lib/commands/page/create.js +1 -1
- package/lib/commands/page/custom/detail.js +1 -1
- package/lib/commands/page/custom/list.js +1 -1
- package/lib/commands/page/custom/publish.js +1 -1
- package/lib/commands/page/custom/shared.js +1 -1
- package/lib/commands/page/custom/syntax.js +1 -1
- package/lib/commands/page/custom/update.js +1 -1
- package/lib/commands/page/data-list-status.js +1 -1
- package/lib/commands/page/generate-start.js +1 -1
- package/lib/commands/page/generate-status.js +1 -1
- package/lib/commands/page/index.js +1 -1
- package/lib/commands/page/pull.js +1 -1
- package/lib/commands/page/push.js +1 -1
- package/lib/commands/page/relation-audit.js +1 -1
- package/lib/commands/page/restore.js +1 -1
- package/lib/commands/page/shared.js +1 -1
- package/lib/commands/page/sync.js +1 -1
- package/lib/commands/project/api-architecture-upgrade.js +1 -1
- package/lib/commands/project/create/enhanced-guided-create.js +1 -1
- package/lib/commands/project/create/format-elapsed.js +1 -1
- package/lib/commands/project/create/main.js +1 -1
- package/lib/commands/project/create/materialize-project-template.js +1 -1
- package/lib/commands/project/create/project-name.js +1 -1
- package/lib/commands/project/create/project-template-archive.js +1 -1
- package/lib/commands/project/create/project-template-path.js +1 -1
- package/lib/commands/project/create/use-copy-project-template.js +1 -1
- package/lib/commands/project/create/use-format-code.js +1 -1
- package/lib/commands/project/create/use-install-dependencies.js +1 -1
- package/lib/commands/project/domain-routing-sync.js +1 -1
- package/lib/commands/project/index.js +1 -1
- package/lib/commands/project/upgrade.js +1 -1
- package/lib/commands/registry.js +1 -1
- package/lib/commands/role/delete.js +1 -1
- package/lib/commands/role/detail.js +1 -1
- package/lib/commands/role/index.js +1 -1
- package/lib/commands/role/list.js +1 -1
- package/lib/commands/role/shared.js +1 -1
- package/lib/commands/role/update.js +1 -1
- package/lib/commands/role/user-add.js +1 -1
- package/lib/commands/role/user-remove.js +1 -1
- package/lib/commands/role/user-resolve.js +1 -1
- package/lib/commands/rule/get.js +1 -1
- package/lib/commands/rule/index.js +1 -1
- package/lib/commands/rule/list.js +1 -1
- package/lib/commands/rule/set.js +1 -1
- package/lib/commands/rule/shared.js +1 -1
- package/lib/commands/run/index.js +1 -1
- package/lib/commands/schema.js +1 -1
- package/lib/commands/sql/create.js +1 -1
- package/lib/commands/sql/delete.js +1 -1
- package/lib/commands/sql/detail.js +1 -1
- package/lib/commands/sql/exec.js +1 -1
- package/lib/commands/sql/index.js +1 -1
- package/lib/commands/sql/list.js +1 -1
- package/lib/commands/sql/pull.js +1 -1
- package/lib/commands/sql/push.js +1 -1
- package/lib/commands/sql/shared.js +1 -1
- package/lib/commands/sql/status.js +1 -1
- package/lib/commands/sql/validate.js +1 -1
- package/lib/commands/task/index.js +1 -1
- package/lib/commands/task/status.js +1 -1
- package/lib/commands/tenant/index.js +1 -1
- package/lib/commands/tenant/members-list.js +1 -1
- package/lib/commands/tenant/shared.js +1 -1
- package/lib/commands/user-account/dingding-sandbox-bind.js +1 -1
- package/lib/commands/user-account/feishu-bind.js +1 -1
- package/lib/commands/user-account/index.js +1 -1
- package/lib/commands/workspace/add.js +1 -1
- package/lib/commands/workspace/index.js +1 -1
- package/lib/commands/workspace/remove.js +1 -1
- package/lib/config/domain-config.js +1 -1
- package/lib/config/project-domain-routing.js +1 -1
- package/lib/config/region-config.js +1 -1
- package/lib/config/schema.js +1 -1
- package/lib/constant/cdn.js +1 -1
- package/lib/constant/cli.js +1 -1
- package/lib/constant/defaults.js +1 -1
- package/lib/constant/domain.js +1 -1
- package/lib/constant/env.js +1 -1
- package/lib/constant/output.js +1 -1
- package/lib/constant/paths.js +1 -1
- package/lib/constant/region.js +1 -1
- package/lib/constant/risk.js +1 -1
- package/lib/constant/routing-profile.js +1 -1
- package/lib/context/app-resolver.js +1 -1
- package/lib/context/auth-resolver.js +1 -1
- package/lib/context/config-loader.js +1 -1
- package/lib/context.js +1 -1
- package/lib/core/alias-resolver.js +1 -1
- package/lib/core/api-client.js +1 -1
- package/lib/core/bff/config.js +1 -1
- package/lib/core/bff/file-system.js +1 -1
- package/lib/core/bff/hash.js +1 -1
- package/lib/core/bff/hook-directory.js +1 -1
- package/lib/core/bff/lock.js +1 -1
- package/lib/core/bff/utils.js +1 -1
- package/lib/core/cross-db-analysis.js +1 -1
- package/lib/core/cross-db-relation.js +1 -1
- package/lib/core/db-resolver.js +1 -1
- package/lib/core/flow-config.js +1 -1
- package/lib/core/instant-api-policy/config.js +1 -1
- package/lib/core/kb-search-client.js +1 -1
- package/lib/core/page/file-system.js +1 -1
- package/lib/core/page/hash.js +1 -1
- package/lib/core/page/lock.js +1 -1
- package/lib/core/page/lr-smart-jsx.js +1 -1
- package/lib/core/sql-index-auditor.js +1 -1
- package/lib/core/sql-sync/config.js +1 -1
- package/lib/core/sql-sync/file-system.js +1 -1
- package/lib/core/sql-sync/hash.js +1 -1
- package/lib/core/sql-sync/lock.js +1 -1
- package/lib/core/sql-sync/utils.js +1 -1
- package/lib/core/sql-validator.js +1 -1
- package/lib/errors.js +1 -1
- package/lib/framework/build-all-flags.js +1 -1
- package/lib/framework/error-output.js +1 -1
- package/lib/framework/explicit-yes.js +1 -1
- package/lib/framework/flags.js +1 -1
- package/lib/framework/help.js +1 -1
- package/lib/framework/index.js +1 -1
- package/lib/framework/output.js +1 -1
- package/lib/framework/response.js +1 -1
- package/lib/framework/runner-alias.js +1 -1
- package/lib/framework/runner.js +1 -1
- package/lib/framework/schema-export.js +1 -1
- package/lib/framework/supported-flags.js +1 -1
- package/lib/framework/types.js +1 -1
- package/lib/generated/build-info.d.ts +4 -4
- package/lib/generated/build-info.js +1 -1
- package/lib/generated/official-routing.js +1 -1
- package/lib/generated/routing-contract.js +1 -1
- package/lib/help.js +1 -1
- package/lib/postinstall.js +1 -1
- package/lib/runtime/confirmation.js +1 -1
- package/lib/runtime/event.js +1 -1
- package/lib/runtime/index.js +1 -1
- package/lib/runtime/queue.js +1 -1
- package/lib/runtime/resolve.js +1 -1
- package/lib/services/dataset-design/checkpoint.js +1 -1
- package/lib/services/dataset-design/commands.js +1 -1
- package/lib/services/dataset-design/contract.js +1 -1
- package/lib/skills/builtin-skill.js +1 -1
- package/lib/skills/main.js +1 -1
- package/lib/skills/npx-skills-add.js +1 -1
- package/lib/skills/skill-presence.js +1 -1
- package/lib/telemetry/cli-command-trace.js +1 -1
- package/lib/telemetry/cli-help-trace.js +1 -1
- package/lib/telemetry/ensure-cli-otel-config.js +1 -1
- package/lib/telemetry/register-otel-exit-shutdown.js +1 -1
- package/lib/telemetry/send-cli-trace-log.js +1 -1
- package/lib/telemetry/send-platform-issue-collect-log.js +1 -1
- package/lib/utils/ai_config.js +1 -1
- package/lib/utils/apply-jq-filter.js +1 -1
- package/lib/utils/cdn-config.js +1 -1
- package/lib/utils/check-sdk-version.js +1 -1
- package/lib/utils/cli-version-check.js +1 -1
- package/lib/utils/cli-version-policy.js +1 -1
- package/lib/utils/config.js +1 -1
- package/lib/utils/entity-with-id.js +1 -1
- package/lib/utils/file-utils.js +1 -1
- package/lib/utils/guides-cdn.js +1 -1
- package/lib/utils/http-client.js +1 -1
- package/lib/utils/is-non-interactive.js +1 -1
- package/lib/utils/logger.js +1 -1
- package/lib/utils/params.js +1 -1
- package/lib/utils/platform.js +1 -1
- package/lib/utils/sleep.js +1 -1
- package/lib/utils/template-replacer.js +1 -1
- package/lib/utils/update-notice.js +1 -1
- package/lib/utils/version.js +1 -1
- package/lib/utils/with-active-cookie.js +1 -1
- package/lib/utils/write-cli-side-channel.js +1 -1
- package/package.json +1 -1
- package/skills/rabetbase/SKILL.md +1 -1
- package/skills/rabetbase-dataset-generation/SKILL.md +1 -1
- package/skills/rabetbase-page-generation/SKILL.md +1 -1
- package/skills/rabetbase.manifest.json +3 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
const a197_0x9e85a2=a197_0x479c;(function(_0x2a068a,_0x567b42){const _0x4f91f0=a197_0x479c,_0x36884e=_0x2a068a();while(!![]){try{const _0x1a525c=parseInt(_0x4f91f0(0xe8))/0x1+parseInt(_0x4f91f0(0x123))/0x2*(-parseInt(_0x4f91f0(0x15c))/0x3)+-parseInt(_0x4f91f0(0xf9))/0x4+parseInt(_0x4f91f0(0xe6))/0x5+parseInt(_0x4f91f0(0xdd))/0x6+parseInt(_0x4f91f0(0x147))/0x7*(parseInt(_0x4f91f0(0xef))/0x8)+parseInt(_0x4f91f0(0x12d))/0x9*(parseInt(_0x4f91f0(0xf0))/0xa);if(_0x1a525c===_0x567b42)break;else _0x36884e['push'](_0x36884e['shift']());}catch(_0xf07a71){_0x36884e['push'](_0x36884e['shift']());}}}(a197_0x2930,0xdfcb4));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=['EMAIL',a197_0x9e85a2(0x103),'DINGTALK',a197_0x9e85a2(0x104),a197_0x9e85a2(0x11a)];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a197_0x9e85a2(0x146),'channelType',a197_0x9e85a2(0x114),a197_0x9e85a2(0x12f),a197_0x9e85a2(0xf4),a197_0x9e85a2(0x158),a197_0x9e85a2(0x116)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id',a197_0x9e85a2(0x13d),a197_0x9e85a2(0x15f),a197_0x9e85a2(0x111)]),EMAIL_RECIPIENT_FIELDS=new Set([a197_0x9e85a2(0xea),a197_0x9e85a2(0xf2),'ccList',a197_0x9e85a2(0x106),a197_0x9e85a2(0xf7),a197_0x9e85a2(0x145),a197_0x9e85a2(0x102),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':a197_0x9e85a2(0x141),'type':a197_0x9e85a2(0x13a),'required':![],'description':a197_0x9e85a2(0x11b)},{'name':'stdin','type':a197_0x9e85a2(0x133),'required':![],'default':![],'description':a197_0x9e85a2(0x12b)},{'name':a197_0x9e85a2(0x13f),'type':a197_0x9e85a2(0x13a),'required':![],'description':a197_0x9e85a2(0x13e)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':a197_0x9e85a2(0x152),'required':!![],'description':a197_0x9e85a2(0x155)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x53d31a,_0x42be99,_0x8111fe){return new CliError(_0x53d31a,0x1,_0x42be99,_0x8111fe);}export function readNotificationId(_0x9ed7a1){const _0x1afc63=a197_0x9e85a2,_0x1c2d1e=_0x9ed7a1[_0x1afc63(0x139)]('id');if(!Number['isSafeInteger'](_0x1c2d1e)||_0x1c2d1e<=0x0)throw notificationError(_0x1afc63(0xdb),_0x1afc63(0x10e));return _0x1c2d1e;}export function requireNotificationExplicitYes(_0x323ca5){const _0x1c7ea5=a197_0x9e85a2;if(_0x323ca5[_0x1c7ea5(0xf3)](_0x1c7ea5(0x149))||_0x323ca5['bool'](_0x1c7ea5(0x128)))return;throw notificationError(_0x1c7ea5(0x10c),_0x1c7ea5(0xf1),_0x1c7ea5(0x124));}export function readNotificationChannelType(_0x9574b4,_0x2cab09='type',_0x4291ac='EMAIL'){const _0x5be0b5=a197_0x9e85a2,_0x554105=_0x9574b4[_0x5be0b5(0x15d)](_0x2cab09)[_0x5be0b5(0xde)]()||_0x4291ac;if(!NOTIFICATION_CHANNEL_TYPES[_0x5be0b5(0x13c)](_0x554105))throw CliErrors[_0x5be0b5(0xe0)]('Invalid\x20--'+_0x2cab09+':\x20'+_0x554105,'Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0x5be0b5(0x156)](',\x20')+'.');return _0x554105;}export function assertSingleNotificationSource(_0x4ce423){const _0xbca546=a197_0x9e85a2,_0x5a7d24=[],_0x556a91=_0x4ce423['str']('file')[_0xbca546(0xde)]();if(_0x556a91)_0x5a7d24['push']({'kind':_0xbca546(0x141),'path':_0x556a91});if(_0x4ce423[_0xbca546(0xf3)](_0xbca546(0x125)))_0x5a7d24[_0xbca546(0xe5)]({'kind':_0xbca546(0x125)});const _0x103d68=_0x4ce423[_0xbca546(0x15d)](_0xbca546(0x13f))['trim']();if(_0x103d68)_0x5a7d24[_0xbca546(0xe5)]({'kind':_0xbca546(0xfc),'name':_0x103d68});if(_0x5a7d24[_0xbca546(0x10d)]===0x0)throw CliErrors['validation']('Missing\x20notification\x20JSON\x20source.',_0xbca546(0xe1));if(_0x5a7d24['length']>0x1)throw CliErrors[_0xbca546(0xe0)](_0xbca546(0x108),_0xbca546(0xe1));return _0x5a7d24[0x0];}export async function readNotificationDocument(_0x4e8cde,_0x5cb85c){const _0x4589a2=a197_0x9e85a2,_0x23e152=assertSingleNotificationSource(_0x4e8cde),_0x2f5797=_0x23e152[_0x4589a2(0x130)]===_0x4589a2(0x141)?_0x4589a2(0x121)+_0x23e152[_0x4589a2(0x100)]:_0x23e152['kind']==='env'?_0x4589a2(0x132)+_0x23e152[_0x4589a2(0x11f)]:_0x4589a2(0x125);let _0x165a0c;try{if(_0x23e152['kind']===_0x4589a2(0x141))_0x165a0c=await readFile(_0x23e152[_0x4589a2(0x100)],'utf8');else{if(_0x23e152[_0x4589a2(0x130)]===_0x4589a2(0xfc)){if(!(_0x23e152[_0x4589a2(0x11f)]in process.env))throw notificationError(_0x4589a2(0x138),_0x4589a2(0xfa)+_0x23e152[_0x4589a2(0x11f)]);_0x165a0c=process.env[_0x23e152.name]??'';}else _0x165a0c=await readStdin();}}catch(_0xb8576a){if(_0xb8576a instanceof CliError)throw _0xb8576a;throw notificationError('notification_config_source_unavailable',_0x4589a2(0x136)+_0x2f5797+'.');}let _0x3e2d74;try{_0x3e2d74=JSON[_0x4589a2(0x14a)](_0x165a0c);}catch{throw notificationError('notification_config_json_invalid','Notification\x20JSON\x20from\x20'+_0x2f5797+_0x4589a2(0x151),_0x4589a2(0x14c));}if(!isJsonObject(_0x3e2d74))throw notificationError(_0x4589a2(0x13b),'Notification\x20JSON\x20from\x20'+_0x2f5797+_0x4589a2(0x142));return validateNotificationDocument(_0x3e2d74,_0x5cb85c);}export function projectNotificationListConfig(_0x2af762,_0x1e4b42){const _0x1fad12=a197_0x9e85a2;return{'id':typeof _0x2af762['id']===_0x1fad12(0x152)?_0x2af762['id']:null,'configCode':requireResponseString(_0x2af762[_0x1fad12(0x15f)],'configCode',_0x1e4b42),'configName':requireResponseString(_0x2af762['configName'],_0x1fad12(0x146),_0x1e4b42),'channelType':requireResponseString(_0x2af762['channelType'],'channelType',_0x1e4b42),'description':normalizeNullableString(_0x2af762[_0x1fad12(0xf4)]),'createTime':normalizeNullableString(_0x2af762[_0x1fad12(0xf6)]),'updateTime':normalizeNullableString(_0x2af762[_0x1fad12(0xdf)])};}export function normalizeExactNotificationConfig(_0x19a8b8,_0x33fa2e,_0x5ddac5){const _0x4d40c7=a197_0x9e85a2;if(!Number['isSafeInteger'](_0x19a8b8['id'])||_0x19a8b8['id']!==_0x33fa2e)throw notificationError(_0x4d40c7(0xff),_0x4d40c7(0xda)+_0x33fa2e+'.');if(_0x19a8b8[_0x4d40c7(0x13d)]!==_0x5ddac5)throw notificationError(_0x4d40c7(0xff),_0x4d40c7(0x154)+_0x33fa2e+_0x4d40c7(0xfb));const _0x55f96a=requireExactString(_0x19a8b8[_0x4d40c7(0x146)],_0x4d40c7(0x146),_0x33fa2e),_0x407b1a=requireExactString(_0x19a8b8[_0x4d40c7(0x15f)],_0x4d40c7(0x15f),_0x33fa2e),_0x5e8b3a=requireExactString(_0x19a8b8[_0x4d40c7(0x157)],_0x4d40c7(0x157),_0x33fa2e);if(!NOTIFICATION_CHANNEL_TYPES[_0x4d40c7(0x13c)](_0x5e8b3a))throw notificationError(_0x4d40c7(0xff),_0x4d40c7(0x154)+_0x33fa2e+'\x20has\x20an\x20unsupported\x20channelType.');const _0x4884d0=responseNullableString(_0x19a8b8['endpointUrl'],_0x4d40c7(0x114),_0x33fa2e),_0x464960=responseNullableString(_0x19a8b8[_0x4d40c7(0x12f)],_0x4d40c7(0x12f),_0x33fa2e),_0x2d4b03=responseNullableString(_0x19a8b8[_0x4d40c7(0xf4)],_0x4d40c7(0xf4),_0x33fa2e),_0x441a54=responseNullableTimeout(_0x19a8b8['connectTimeout'],_0x4d40c7(0x158),_0x33fa2e),_0x34a6df=responseNullableTimeout(_0x19a8b8[_0x4d40c7(0x116)],_0x4d40c7(0x116),_0x33fa2e);return{'id':_0x33fa2e,'appCode':_0x5ddac5,'configCode':_0x407b1a,'configName':_0x55f96a,'channelType':_0x5e8b3a,'endpointUrl':redactSensitive(_0x4884d0),'channelConfig':redactSensitive(_0x464960),'description':_0x2d4b03,'connectTimeout':_0x441a54,'readTimeout':_0x34a6df,'endpointUrlRaw':_0x4884d0,'channelConfigRaw':_0x464960};}export async function requireExactNotificationConfig(_0xd2a8db,_0x9a2e88,_0x2258ef){const _0x345bb4=a197_0x9e85a2;let _0x12d1ea;try{_0x12d1ea=await getNotificationChannelConfig(_0x9a2e88,_0xd2a8db);}catch{throw safeApiFailure(_0x2258ef,'preflight','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20'+_0xd2a8db+_0x345bb4(0x10f));}return normalizeExactNotificationConfig(_0x12d1ea,_0x9a2e88,_0xd2a8db);}export function projectNotificationConfig(_0x539da3){const _0x188b9c=a197_0x9e85a2;return{'id':_0x539da3['id']??null,'appCode':_0x539da3[_0x188b9c(0x13d)],'configCode':_0x539da3['configCode']??null,'configName':_0x539da3['configName'],'channelType':_0x539da3[_0x188b9c(0x157)],'endpointUrl':redactSensitive(_0x539da3[_0x188b9c(0x114)]),'channelConfig':redactSensitive(_0x539da3[_0x188b9c(0x12f)]),'description':_0x539da3[_0x188b9c(0xf4)]??null,'connectTimeout':_0x539da3[_0x188b9c(0x158)]??null,'readTimeout':_0x539da3[_0x188b9c(0x116)]??null};}export function notificationSelector(_0x1bca7c){const _0x1f4ce4=a197_0x9e85a2;return{'appCode':_0x1bca7c[_0x1f4ce4(0x13d)],'id':_0x1bca7c['id'],'configCode':_0x1bca7c['configCode'],'configName':_0x1bca7c[_0x1f4ce4(0x146)],'channelType':_0x1bca7c['channelType']};}export function createMutationInput(_0x3cf9ea,_0x4518d6){const _0x2dca69=a197_0x9e85a2;return{'appCode':_0x3cf9ea,'configName':_0x4518d6[_0x2dca69(0x146)],'channelType':_0x4518d6[_0x2dca69(0x157)],...hasOwn(_0x4518d6,'endpointUrl')?{'endpointUrl':_0x4518d6[_0x2dca69(0x114)]}:{},...hasOwn(_0x4518d6,_0x2dca69(0x12f))?{'channelConfig':serializeChannelConfig(_0x4518d6[_0x2dca69(0x12f)])}:{},...hasOwn(_0x4518d6,_0x2dca69(0xf4))?{'description':_0x4518d6[_0x2dca69(0xf4)]}:{},...hasOwn(_0x4518d6,'connectTimeout')?{'connectTimeout':_0x4518d6[_0x2dca69(0x158)]}:{},...hasOwn(_0x4518d6,'readTimeout')?{'readTimeout':_0x4518d6['readTimeout']}:{}};}export function mergeUpdateInput(_0x5c4365,_0x2401df){const _0x1e5cd8=a197_0x9e85a2;return{'id':_0x5c4365['id'],'appCode':_0x5c4365['appCode'],'configName':_0x2401df[_0x1e5cd8(0x146)]??_0x5c4365[_0x1e5cd8(0x146)],'channelType':_0x2401df[_0x1e5cd8(0x157)]??_0x5c4365[_0x1e5cd8(0x157)],'endpointUrl':hasOwn(_0x2401df,_0x1e5cd8(0x114))?_0x2401df[_0x1e5cd8(0x114)]:_0x5c4365[_0x1e5cd8(0x113)],'channelConfig':hasOwn(_0x2401df,_0x1e5cd8(0x12f))?serializeChannelConfig(_0x2401df['channelConfig']):_0x5c4365[_0x1e5cd8(0x140)],'description':hasOwn(_0x2401df,_0x1e5cd8(0xf4))?_0x2401df[_0x1e5cd8(0xf4)]:_0x5c4365[_0x1e5cd8(0xf4)],'connectTimeout':hasOwn(_0x2401df,_0x1e5cd8(0x158))?_0x2401df['connectTimeout']:_0x5c4365['connectTimeout'],'readTimeout':hasOwn(_0x2401df,_0x1e5cd8(0x116))?_0x2401df['readTimeout']:_0x5c4365[_0x1e5cd8(0x116)]};}export function plannedUpdateProjection(_0x319333,_0xc35160){const _0x17d4e5=a197_0x9e85a2;return projectNotificationConfig({'id':_0x319333['id'],'appCode':_0x319333['appCode'],'configCode':_0x319333[_0x17d4e5(0x15f)],'configName':_0xc35160[_0x17d4e5(0x146)]??_0x319333[_0x17d4e5(0x146)],'channelType':_0xc35160[_0x17d4e5(0x157)]??_0x319333[_0x17d4e5(0x157)],'endpointUrl':hasOwn(_0xc35160,_0x17d4e5(0x114))?_0xc35160[_0x17d4e5(0x114)]:_0x319333['endpointUrlRaw'],'channelConfig':hasOwn(_0xc35160,_0x17d4e5(0x12f))?_0xc35160[_0x17d4e5(0x12f)]:_0x319333[_0x17d4e5(0x140)],'description':hasOwn(_0xc35160,_0x17d4e5(0xf4))?_0xc35160[_0x17d4e5(0xf4)]:_0x319333[_0x17d4e5(0xf4)],'connectTimeout':hasOwn(_0xc35160,_0x17d4e5(0x158))?_0xc35160[_0x17d4e5(0x158)]??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x319333['connectTimeout'],'readTimeout':hasOwn(_0xc35160,_0x17d4e5(0x116))?_0xc35160[_0x17d4e5(0x116)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x319333['readTimeout']});}export function requestedSafeFieldsMatch(_0x499db9,_0xe282ac,_0x4941eb){const _0x334a12=a197_0x9e85a2,_0x354b41=[],_0x2a7706=[],_0x276199=[];for(const _0x2c0616 of[_0x334a12(0x146),_0x334a12(0x157),_0x334a12(0xf4)]){if(!hasOwn(_0x4941eb,_0x2c0616))continue;_0x276199[_0x334a12(0xe5)](_0x2c0616),_0x354b41['push'](_0xe282ac[_0x2c0616]===_0x4941eb[_0x2c0616]),_0x2a7706['push'](_0x499db9[_0x2c0616]!==_0x4941eb[_0x2c0616]&&_0xe282ac[_0x2c0616]===_0x4941eb[_0x2c0616]);}for(const _0xf6b079 of[_0x334a12(0x158),_0x334a12(0x116)]){if(!hasOwn(_0x4941eb,_0xf6b079))continue;const _0x16fa62=_0x4941eb[_0xf6b079]??(_0xf6b079===_0x334a12(0x158)?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x276199[_0x334a12(0xe5)](_0xf6b079),_0x354b41[_0x334a12(0xe5)](_0xe282ac[_0xf6b079]===_0x16fa62),_0x2a7706[_0x334a12(0xe5)](_0x499db9[_0xf6b079]!==_0x16fa62&&_0xe282ac[_0xf6b079]===_0x16fa62);}return hasOwn(_0x4941eb,_0x334a12(0x114))&&_0x4941eb['endpointUrl']===null&&(_0x276199[_0x334a12(0xe5)]('endpointUrl:null'),_0x354b41[_0x334a12(0xe5)](_0xe282ac[_0x334a12(0x113)]===null||_0xe282ac[_0x334a12(0x113)]===''),_0x2a7706['push'](_0x499db9['endpointUrlRaw']!==null&&_0x499db9[_0x334a12(0x113)]!==''&&(_0xe282ac[_0x334a12(0x113)]===null||_0xe282ac[_0x334a12(0x113)]===''))),{'allMatch':_0x354b41['every'](Boolean),'provesChange':_0x2a7706[_0x334a12(0x11d)](Boolean),'verifiedFields':_0x276199};}export function validateNotificationDeleteReadback(_0x25a2c8,_0xe06e59,_0x230664){const _0x346b61=a197_0x9e85a2;for(const [_0x3a8fc4,_0x1a6bd8]of _0x25a2c8[_0x346b61(0x11c)]()){if(!Number[_0x346b61(0x131)](_0x1a6bd8['id'])||_0x1a6bd8['id']<=0x0)throw notificationError(_0x346b61(0xff),'Notification\x20config\x20list\x20item\x20'+(_0x3a8fc4+0x1)+_0x346b61(0x118));if(_0x1a6bd8[_0x346b61(0x13d)]!==_0xe06e59)throw notificationError('notification_config_response_invalid',_0x346b61(0xfe)+(_0x3a8fc4+0x1)+_0x346b61(0xec));if(_0x1a6bd8[_0x346b61(0x157)]!==_0x230664)throw notificationError('notification_config_response_invalid','Notification\x20config\x20list\x20item\x20'+(_0x3a8fc4+0x1)+_0x346b61(0xf8));}}export function safeApiFailure(_0x2dfb63,_0x43e338,_0x502fbd){const _0x305b59=a197_0x9e85a2;return notificationError(_0x305b59(0x15e)+_0x2dfb63+'_'+(_0x43e338===_0x305b59(0x119)?_0x305b59(0x129):_0x43e338+_0x305b59(0xe2)),_0x305b59(0x154)+_0x2dfb63+'\x20'+_0x43e338+_0x305b59(0x14b),_0x502fbd);}export function notificationLookupCommand(_0x44162c,_0x36c807){const _0x548566=a197_0x9e85a2;return _0x548566(0x137)+_0x44162c+_0x548566(0x112)+_0x36c807+_0x548566(0xee);}function validateNotificationDocument(_0x41fba6,_0x5bdb26){const _0x1d8384=a197_0x9e85a2;for(const _0x2e07c0 of Object[_0x1d8384(0x14e)](_0x41fba6)){if(FORBIDDEN_IDENTITY_FIELDS[_0x1d8384(0xe3)](_0x2e07c0))throw notificationError(_0x1d8384(0xdc),'Notification\x20JSON\x20field\x20\x22'+_0x2e07c0+_0x1d8384(0xe7));if(!ALLOWED_INPUT_FIELDS[_0x1d8384(0xe3)](_0x2e07c0))throw notificationError(_0x1d8384(0x150),_0x1d8384(0x15b)+_0x2e07c0+'\x22.');}if(_0x5bdb26==='update'&&Object[_0x1d8384(0x14e)](_0x41fba6)['length']===0x0)throw notificationError(_0x1d8384(0x109),_0x1d8384(0x127));const _0x568a86={};if(hasOwn(_0x41fba6,_0x1d8384(0x146)))_0x568a86[_0x1d8384(0x146)]=validateRequiredString(_0x41fba6[_0x1d8384(0x146)],_0x1d8384(0x146),0x80);else{if(_0x5bdb26===_0x1d8384(0xe4))throw notificationError(_0x1d8384(0x135),_0x1d8384(0x11e)+_0x1d8384(0x105));}if(hasOwn(_0x41fba6,_0x1d8384(0x157))){if(typeof _0x41fba6[_0x1d8384(0x157)]!==_0x1d8384(0x13a))throw invalidFieldType(_0x1d8384(0x157),_0x1d8384(0x12c));const _0x568cef=_0x41fba6[_0x1d8384(0x157)][_0x1d8384(0xde)]();if(!NOTIFICATION_CHANNEL_TYPES[_0x1d8384(0x13c)](_0x568cef))throw notificationError(_0x1d8384(0x115),_0x1d8384(0x14f),_0x1d8384(0x143)+NOTIFICATION_CHANNEL_TYPES[_0x1d8384(0x156)](',\x20')+'.');_0x568a86[_0x1d8384(0x157)]=_0x568cef;}else{if(_0x5bdb26==='create')throw notificationError(_0x1d8384(0x135),_0x1d8384(0x11e)+_0x1d8384(0x101));}for(const [_0x87db04,_0x14f56f]of[[_0x1d8384(0x114),0x200],[_0x1d8384(0xf4),0x100]]){if(!hasOwn(_0x41fba6,_0x87db04))continue;const _0x393212=_0x41fba6[_0x87db04];if(_0x393212!==null&&typeof _0x393212!==_0x1d8384(0x13a))throw invalidFieldType(_0x87db04,_0x1d8384(0x120));if(typeof _0x393212===_0x1d8384(0x13a)&&_0x393212[_0x1d8384(0x10d)]>_0x14f56f)throw notificationError(_0x1d8384(0x115),_0x1d8384(0x14d)+_0x87db04+'\x22\x20cannot\x20exceed\x20'+_0x14f56f+'\x20characters.');_0x568a86[_0x87db04]=_0x393212;}if(hasOwn(_0x41fba6,'channelConfig')){const _0x2c38c6=_0x41fba6[_0x1d8384(0x12f)];if(_0x2c38c6===null&&_0x5bdb26===_0x1d8384(0xe4))throw invalidFieldType(_0x1d8384(0x12f),_0x1d8384(0x153));if(_0x2c38c6!==null&&!isJsonObject(_0x2c38c6))throw invalidFieldType(_0x1d8384(0x12f),_0x5bdb26==='update'?_0x1d8384(0x122):_0x1d8384(0x153));_0x2c38c6!==null&&validateChannelConfigFields(_0x568a86[_0x1d8384(0x157)],_0x2c38c6),_0x568a86[_0x1d8384(0x12f)]=_0x2c38c6;}for(const _0x2c8779 of[_0x1d8384(0x158),'readTimeout']){if(!hasOwn(_0x41fba6,_0x2c8779))continue;const _0x44ecb2=_0x41fba6[_0x2c8779];if(_0x44ecb2!==null&&(!Number['isSafeInteger'](_0x44ecb2)||_0x44ecb2<0x0))throw notificationError(_0x1d8384(0x115),'Notification\x20JSON\x20field\x20\x22'+_0x2c8779+_0x1d8384(0x110));_0x568a86[_0x2c8779]=_0x44ecb2;}return _0x568a86;}function validateRequiredString(_0x301d02,_0x3ef287,_0x21f4aa){const _0x25346a=a197_0x9e85a2;if(typeof _0x301d02!==_0x25346a(0x13a))throw invalidFieldType(_0x3ef287,_0x25346a(0x117));const _0x3285ad=_0x301d02[_0x25346a(0xde)]();if(!_0x3285ad)throw notificationError(_0x25346a(0x115),_0x25346a(0x14d)+_0x3ef287+_0x25346a(0xfd));if(_0x3285ad[_0x25346a(0x10d)]>_0x21f4aa)throw notificationError(_0x25346a(0x115),_0x25346a(0x14d)+_0x3ef287+'\x22\x20cannot\x20exceed\x20'+_0x21f4aa+'\x20characters.');return _0x3285ad;}function validateChannelConfigFields(_0xf9f69,_0x29eea2){const _0x2d6073=a197_0x9e85a2;if(hasOwn(_0x29eea2,_0x2d6073(0x12e)))throw forbiddenChannelConfigField(_0x2d6073(0x12e));if(_0xf9f69===_0x2d6073(0x12a))for(const _0xc8ac6c of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x29eea2,_0xc8ac6c))throw forbiddenChannelConfigField(_0xc8ac6c);}}function forbiddenChannelConfigField(_0x3f2f95){const _0x33fbff=a197_0x9e85a2;return notificationError(_0x33fbff(0x159),_0x33fbff(0x15a)+_0x3f2f95+_0x33fbff(0x134));}function invalidFieldType(_0x1cc9b3,_0x2c1e35){const _0x328564=a197_0x9e85a2;return notificationError(_0x328564(0x115),_0x328564(0x14d)+_0x1cc9b3+_0x328564(0xf5)+_0x2c1e35+'.');}function serializeChannelConfig(_0x18958f){const _0x1932dc=a197_0x9e85a2;return _0x18958f===null||_0x18958f===undefined?null:JSON[_0x1932dc(0x148)](_0x18958f);}function redactSensitive(_0x2ee812){return _0x2ee812===null||_0x2ee812===undefined||_0x2ee812===''?null:'<redacted>';}function a197_0x2930(){const _0x5d80af=['WEBHOOK','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','entries','some','Create\x20JSON\x20requires\x20field\x20','name','a\x20string\x20or\x20null','file\x20','a\x20JSON\x20object\x20or\x20null','43260PjfOuL','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','stdin','object','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','yes','failed','EMAIL','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','a\x20supported\x20string','502047rxtHzU','messageTemplate','channelConfig','kind','isSafeInteger','environment\x20variable\x20','boolean','\x22\x20is\x20forbidden.','notification_config_field_required','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','rabetbase\x20notification\x20config-list\x20--appcode\x20','notification_config_source_unavailable','num','string','notification_config_json_invalid','includes','appCode','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','from-env','channelConfigRaw','file','\x20must\x20be\x20an\x20object.','Allowed\x20values:\x20','Item\x20','subjectPrefix','configName','3693858SLvOMC','stringify','dry-run','parse','\x20failed.','Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','Notification\x20JSON\x20field\x20\x22','keys','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','notification_config_field_unknown','\x20is\x20invalid.','number','a\x20JSON\x20object','Notification\x20config\x20','Application-level\x20notification\x20config\x20ID','join','channelType','connectTimeout','notification_config_channel_field_forbidden','Notification\x20JSON\x20channelConfig\x20field\x20\x22','Unknown\x20notification\x20JSON\x20field\x20\x22','222ONHBkW','str','notification_config_','configCode','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','notification_config_id_invalid','notification_config_field_forbidden','1902258XTAJkM','trim','updateTime','validation','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','_unavailable','has','create','push','5450950DfLQvS','\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.','280123DWWrXI','\x20has\x20invalid\x20field\x20\x22','emailTargets','\x20is\x20missing\x20required\x20field\x20\x22','\x20has\x20an\x20invalid\x20appCode.','isArray','\x20--format\x20compress','16XpXBCJ','240pNiwga','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','recipients','bool','description','\x22\x20must\x20be\x20','createTime','replyTo','\x20has\x20an\x20invalid\x20channelType.','6257024xEeMBM','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','env','\x22\x20must\x20be\x20a\x20non-empty\x20string.','Notification\x20config\x20list\x20item\x20','notification_config_response_invalid','path','\x22channelType\x22.','fromName','FEISHU','WECOM','\x22configName\x22.','bccList','setEncoding','Notification\x20JSON\x20source\x20is\x20ambiguous.','notification_config_update_empty','hasOwnProperty','apiError','notification_config_confirmation_required','length','--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','channelCode','\x20--type\x20','endpointUrlRaw','endpointUrl','notification_config_field_invalid','readTimeout','a\x20non-empty\x20string','\x20has\x20an\x20invalid\x20id.','mutation'];a197_0x2930=function(){return _0x5d80af;};return a197_0x2930();}function requireResponseString(_0x34885c,_0x378576,_0x115a56){const _0x5722a5=a197_0x9e85a2;if(typeof _0x34885c!=='string'||_0x34885c[_0x5722a5(0xde)]()==='')throw CliErrors[_0x5722a5(0x10b)]('Invalid\x20notification\x20config\x20response.',_0x5722a5(0x144)+(_0x115a56+0x1)+_0x5722a5(0xeb)+_0x378576+'\x22.');return _0x34885c['trim']();}function a197_0x479c(_0x89e3c2,_0x430cc6){_0x89e3c2=_0x89e3c2-0xda;const _0x293054=a197_0x2930();let _0x479c48=_0x293054[_0x89e3c2];return _0x479c48;}function requireExactString(_0x4d37e5,_0x9518bf,_0x9dbd3a){const _0xb20fe6=a197_0x9e85a2;if(typeof _0x4d37e5!==_0xb20fe6(0x13a)||_0x4d37e5[_0xb20fe6(0xde)]()==='')throw notificationError(_0xb20fe6(0xff),_0xb20fe6(0x154)+_0x9dbd3a+_0xb20fe6(0xeb)+_0x9518bf+'\x22.');return _0x4d37e5['trim']();}function responseNullableString(_0x1e19c3,_0x5bec99,_0x187640){const _0x24ead8=a197_0x9e85a2;if(_0x1e19c3===undefined||_0x1e19c3===null)return null;if(typeof _0x1e19c3!==_0x24ead8(0x13a))throw notificationError(_0x24ead8(0xff),'Notification\x20config\x20'+_0x187640+_0x24ead8(0xe9)+_0x5bec99+'\x22.');return _0x1e19c3;}function responseNullableTimeout(_0x8eedd4,_0x51078e,_0xbfbe44){const _0x4f299b=a197_0x9e85a2;if(_0x8eedd4===undefined||_0x8eedd4===null)return null;if(!Number[_0x4f299b(0x131)](_0x8eedd4)||_0x8eedd4<0x0)throw notificationError(_0x4f299b(0xff),_0x4f299b(0x154)+_0xbfbe44+_0x4f299b(0xe9)+_0x51078e+'\x22.');return _0x8eedd4;}function normalizeNullableString(_0x5e829f){return typeof _0x5e829f==='string'?_0x5e829f:null;}function isJsonObject(_0x56819b){const _0x501811=a197_0x9e85a2;return _0x56819b!==null&&typeof _0x56819b===_0x501811(0x126)&&!Array[_0x501811(0xed)](_0x56819b);}function hasOwn(_0x10da83,_0xfd3c95){const _0x5c5c35=a197_0x9e85a2;return Object['prototype'][_0x5c5c35(0x10a)]['call'](_0x10da83,_0xfd3c95);}async function readStdin(){const _0x555f44=a197_0x9e85a2;let _0x132c51='';process[_0x555f44(0x125)][_0x555f44(0x107)]('utf8');for await(const _0x1519d0 of process['stdin'])_0x132c51+=_0x1519d0;return _0x132c51;}
|
|
1
|
+
const a197_0x12d8c6=a197_0x50e4;(function(_0xb7db52,_0x67cfe7){const _0x3f86b8=a197_0x50e4,_0x323778=_0xb7db52();while(!![]){try{const _0x587a38=parseInt(_0x3f86b8(0x19f))/0x1+parseInt(_0x3f86b8(0x1ab))/0x2*(-parseInt(_0x3f86b8(0x1b9))/0x3)+-parseInt(_0x3f86b8(0x158))/0x4+parseInt(_0x3f86b8(0x1bc))/0x5*(parseInt(_0x3f86b8(0x1c4))/0x6)+-parseInt(_0x3f86b8(0x1ca))/0x7+-parseInt(_0x3f86b8(0x1c8))/0x8*(-parseInt(_0x3f86b8(0x15c))/0x9)+parseInt(_0x3f86b8(0x19d))/0xa;if(_0x587a38===_0x67cfe7)break;else _0x323778['push'](_0x323778['shift']());}catch(_0x1ea4ae){_0x323778['push'](_0x323778['shift']());}}}(a197_0x189f,0x415ab));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=[a197_0x12d8c6(0x169),'FEISHU',a197_0x12d8c6(0x15e),a197_0x12d8c6(0x190),'WEBHOOK'];export const DEFAULT_NOTIFICATION_CONNECT_TIMEOUT=0x1388;export const DEFAULT_NOTIFICATION_READ_TIMEOUT=0x2710;const ALLOWED_INPUT_FIELDS=new Set([a197_0x12d8c6(0x166),a197_0x12d8c6(0x1a0),'endpointUrl',a197_0x12d8c6(0x185),'description',a197_0x12d8c6(0x173),a197_0x12d8c6(0x1bb)]),FORBIDDEN_IDENTITY_FIELDS=new Set(['id','appCode','configCode',a197_0x12d8c6(0x1ae)]),EMAIL_RECIPIENT_FIELDS=new Set([a197_0x12d8c6(0x1a6),'recipients','ccList',a197_0x12d8c6(0x178),'replyTo',a197_0x12d8c6(0x177),a197_0x12d8c6(0x167),'to','cc']);export const NOTIFICATION_INPUT_FLAGS=[{'name':'file','type':'string','required':![],'description':a197_0x12d8c6(0x160)},{'name':a197_0x12d8c6(0x188),'type':a197_0x12d8c6(0x1a8),'required':![],'default':![],'description':a197_0x12d8c6(0x16e)},{'name':'from-env','type':'string','required':![],'description':a197_0x12d8c6(0x194)}];export const NOTIFICATION_ID_FLAG={'name':'id','type':'number','required':!![],'description':a197_0x12d8c6(0x193)};export const NOTIFICATION_APP_FLAG=APPCODE_FLAG_OPTIONAL;export function notificationError(_0x4f6839,_0x20aea5,_0x562bbf){return new CliError(_0x4f6839,0x1,_0x20aea5,_0x562bbf);}function a197_0x50e4(_0x5d672d,_0x5171b3){_0x5d672d=_0x5d672d-0x157;const _0x189f43=a197_0x189f();let _0x50e482=_0x189f43[_0x5d672d];return _0x50e482;}export function readNotificationId(_0x20e0dc){const _0x104dc7=a197_0x12d8c6,_0x121bc9=_0x20e0dc[_0x104dc7(0x183)]('id');if(!Number['isSafeInteger'](_0x121bc9)||_0x121bc9<=0x0)throw notificationError(_0x104dc7(0x1a7),'--id\x20must\x20be\x20a\x20positive\x20safe\x20integer.');return _0x121bc9;}export function requireNotificationExplicitYes(_0x1a27e5){const _0x80aa7c=a197_0x12d8c6;if(_0x1a27e5[_0x80aa7c(0x1bd)](_0x80aa7c(0x1c5))||_0x1a27e5[_0x80aa7c(0x1bd)](_0x80aa7c(0x186)))return;throw notificationError('notification_config_confirmation_required',_0x80aa7c(0x189),_0x80aa7c(0x15f));}export function readNotificationChannelType(_0x8925a6,_0x52ae2a=a197_0x12d8c6(0x168),_0x3d4f1b=a197_0x12d8c6(0x169)){const _0x16238e=a197_0x12d8c6,_0x6cabe1=_0x8925a6[_0x16238e(0x181)](_0x52ae2a)['trim']()||_0x3d4f1b;if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x6cabe1))throw CliErrors[_0x16238e(0x199)](_0x16238e(0x1b2)+_0x52ae2a+':\x20'+_0x6cabe1,'Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0x16238e(0x1c6)](',\x20')+'.');return _0x6cabe1;}export function assertSingleNotificationSource(_0x2c8c30){const _0x2e711c=a197_0x12d8c6,_0x347d0b=[],_0x14a832=_0x2c8c30[_0x2e711c(0x181)](_0x2e711c(0x1cd))[_0x2e711c(0x1cb)]();if(_0x14a832)_0x347d0b[_0x2e711c(0x1cf)]({'kind':'file','path':_0x14a832});if(_0x2c8c30[_0x2e711c(0x1bd)]('stdin'))_0x347d0b[_0x2e711c(0x1cf)]({'kind':'stdin'});const _0x12b419=_0x2c8c30[_0x2e711c(0x181)](_0x2e711c(0x1b3))[_0x2e711c(0x1cb)]();if(_0x12b419)_0x347d0b['push']({'kind':'env','name':_0x12b419});if(_0x347d0b[_0x2e711c(0x1a3)]===0x0)throw CliErrors[_0x2e711c(0x199)](_0x2e711c(0x165),_0x2e711c(0x1b6));if(_0x347d0b[_0x2e711c(0x1a3)]>0x1)throw CliErrors[_0x2e711c(0x199)](_0x2e711c(0x19c),_0x2e711c(0x1b6));return _0x347d0b[0x0];}export async function readNotificationDocument(_0x5eabfc,_0x4f2ba7){const _0xd4aeaf=a197_0x12d8c6,_0xa80c6b=assertSingleNotificationSource(_0x5eabfc),_0xe7957f=_0xa80c6b[_0xd4aeaf(0x16c)]==='file'?_0xd4aeaf(0x18b)+_0xa80c6b[_0xd4aeaf(0x15b)]:_0xa80c6b['kind']===_0xd4aeaf(0x1a5)?_0xd4aeaf(0x1ac)+_0xa80c6b[_0xd4aeaf(0x163)]:_0xd4aeaf(0x188);let _0x350641;try{if(_0xa80c6b[_0xd4aeaf(0x16c)]===_0xd4aeaf(0x1cd))_0x350641=await readFile(_0xa80c6b[_0xd4aeaf(0x15b)],'utf8');else{if(_0xa80c6b[_0xd4aeaf(0x16c)]===_0xd4aeaf(0x1a5)){if(!(_0xa80c6b[_0xd4aeaf(0x163)]in process.env))throw notificationError(_0xd4aeaf(0x18d),_0xd4aeaf(0x157)+_0xa80c6b[_0xd4aeaf(0x163)]);_0x350641=process.env[_0xa80c6b.name]??'';}else _0x350641=await readStdin();}}catch(_0x39657e){if(_0x39657e instanceof CliError)throw _0x39657e;throw notificationError(_0xd4aeaf(0x18d),_0xd4aeaf(0x17d)+_0xe7957f+'.');}let _0x450ba1;try{_0x450ba1=JSON[_0xd4aeaf(0x197)](_0x350641);}catch{throw notificationError(_0xd4aeaf(0x184),_0xd4aeaf(0x18c)+_0xe7957f+_0xd4aeaf(0x191),_0xd4aeaf(0x170));}if(!isJsonObject(_0x450ba1))throw notificationError(_0xd4aeaf(0x184),_0xd4aeaf(0x18c)+_0xe7957f+_0xd4aeaf(0x1c7));return validateNotificationDocument(_0x450ba1,_0x4f2ba7);}export function projectNotificationListConfig(_0x2a330f,_0x1a02aa){const _0x2833ef=a197_0x12d8c6;return{'id':typeof _0x2a330f['id']===_0x2833ef(0x17c)?_0x2a330f['id']:null,'configCode':requireResponseString(_0x2a330f[_0x2833ef(0x1a9)],_0x2833ef(0x1a9),_0x1a02aa),'configName':requireResponseString(_0x2a330f[_0x2833ef(0x166)],_0x2833ef(0x166),_0x1a02aa),'channelType':requireResponseString(_0x2a330f[_0x2833ef(0x1a0)],'channelType',_0x1a02aa),'description':normalizeNullableString(_0x2a330f[_0x2833ef(0x161)]),'createTime':normalizeNullableString(_0x2a330f['createTime']),'updateTime':normalizeNullableString(_0x2a330f[_0x2833ef(0x1ad)])};}export function normalizeExactNotificationConfig(_0x474756,_0xc72308,_0x5e766e){const _0x1c04e1=a197_0x12d8c6;if(!Number[_0x1c04e1(0x1c0)](_0x474756['id'])||_0x474756['id']!==_0xc72308)throw notificationError(_0x1c04e1(0x17e),_0x1c04e1(0x159)+_0xc72308+'.');if(_0x474756[_0x1c04e1(0x182)]!==_0x5e766e)throw notificationError(_0x1c04e1(0x17e),_0x1c04e1(0x18e)+_0xc72308+_0x1c04e1(0x1cc));const _0x5e10e0=requireExactString(_0x474756[_0x1c04e1(0x166)],'configName',_0xc72308),_0x1806a0=requireExactString(_0x474756[_0x1c04e1(0x1a9)],_0x1c04e1(0x1a9),_0xc72308),_0x237289=requireExactString(_0x474756[_0x1c04e1(0x1a0)],_0x1c04e1(0x1a0),_0xc72308);if(!NOTIFICATION_CHANNEL_TYPES[_0x1c04e1(0x1d0)](_0x237289))throw notificationError(_0x1c04e1(0x17e),_0x1c04e1(0x18e)+_0xc72308+_0x1c04e1(0x162));const _0x330160=responseNullableString(_0x474756[_0x1c04e1(0x16f)],'endpointUrl',_0xc72308),_0x2e9fee=responseNullableString(_0x474756[_0x1c04e1(0x185)],'channelConfig',_0xc72308),_0x3a51f1=responseNullableString(_0x474756[_0x1c04e1(0x161)],_0x1c04e1(0x161),_0xc72308),_0x2c37dd=responseNullableTimeout(_0x474756[_0x1c04e1(0x173)],_0x1c04e1(0x173),_0xc72308),_0x1e3a85=responseNullableTimeout(_0x474756[_0x1c04e1(0x1bb)],_0x1c04e1(0x1bb),_0xc72308);return{'id':_0xc72308,'appCode':_0x5e766e,'configCode':_0x1806a0,'configName':_0x5e10e0,'channelType':_0x237289,'endpointUrl':redactSensitive(_0x330160),'channelConfig':redactSensitive(_0x2e9fee),'description':_0x3a51f1,'connectTimeout':_0x2c37dd,'readTimeout':_0x1e3a85,'endpointUrlRaw':_0x330160,'channelConfigRaw':_0x2e9fee};}export async function requireExactNotificationConfig(_0x3e1700,_0x383d96,_0x35f482){const _0x15a46c=a197_0x12d8c6;let _0x13264e;try{_0x13264e=await getNotificationChannelConfig(_0x383d96,_0x3e1700);}catch{throw safeApiFailure(_0x35f482,_0x15a46c(0x180),_0x15a46c(0x179)+_0x3e1700+_0x15a46c(0x196));}return normalizeExactNotificationConfig(_0x13264e,_0x383d96,_0x3e1700);}export function projectNotificationConfig(_0x270af9){const _0x1b2113=a197_0x12d8c6;return{'id':_0x270af9['id']??null,'appCode':_0x270af9[_0x1b2113(0x182)],'configCode':_0x270af9[_0x1b2113(0x1a9)]??null,'configName':_0x270af9[_0x1b2113(0x166)],'channelType':_0x270af9[_0x1b2113(0x1a0)],'endpointUrl':redactSensitive(_0x270af9[_0x1b2113(0x16f)]),'channelConfig':redactSensitive(_0x270af9[_0x1b2113(0x185)]),'description':_0x270af9[_0x1b2113(0x161)]??null,'connectTimeout':_0x270af9[_0x1b2113(0x173)]??null,'readTimeout':_0x270af9[_0x1b2113(0x1bb)]??null};}function a197_0x189f(){const _0x5a95ba=['Provide\x20one\x20valid\x20JSON\x20object;\x20source\x20contents\x20are\x20not\x20included\x20in\x20errors.','failed','keys','connectTimeout','\x22configName\x22.','has','call','subjectPrefix','bccList','Inspect\x20with\x20rabetbase\x20notification\x20config-list\x20--appcode\x20','\x22\x20must\x20be\x20','<redacted>','number','Unable\x20to\x20read\x20notification\x20JSON\x20from\x20','notification_config_response_invalid','\x22channelType\x22.','preflight','str','appCode','num','notification_config_json_invalid','channelConfig','yes','update','stdin','This\x20notification\x20config\x20mutation\x20requires\x20explicit\x20--yes.','\x20has\x20invalid\x20field\x20\x22','file\x20','Notification\x20JSON\x20from\x20','notification_config_source_unavailable','Notification\x20config\x20','mutation','WECOM','\x20is\x20invalid.','isArray','Application-level\x20notification\x20config\x20ID','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20named\x20environment\x20variable','string','\x20--type\x20<CHANNEL_TYPE>\x20--format\x20compress;\x20no\x20mutation\x20was\x20submitted.','parse','create','validation','some','Notification\x20JSON\x20field\x20\x22','Notification\x20JSON\x20source\x20is\x20ambiguous.','2000080hMqSBf','\x22\x20must\x20be\x20a\x20non-empty\x20string.','139433ognUmv','channelType','_unavailable','a\x20JSON\x20object','length','notification_config_','env','emailTargets','notification_config_id_invalid','boolean','configCode','messageTemplate','64peKPil','environment\x20variable\x20','updateTime','channelCode','\x20--type\x20','\x20has\x20an\x20invalid\x20id.','notification_config_update_empty','Invalid\x20--','from-env','Update\x20JSON\x20must\x20contain\x20at\x20least\x20one\x20allowed\x20field.','notification_config_field_invalid','Use\x20exactly\x20one\x20of\x20--file\x20<path>,\x20--stdin,\x20or\x20--from-env\x20<NAME>.','a\x20non-empty\x20string','rabetbase\x20notification\x20config-list\x20--appcode\x20','30963Nhchrk','notification_config_field_required','readTimeout','811405wlGzKE','bool','Notification\x20JSON\x20field\x20\x22channelType\x22\x20is\x20unsupported.','a\x20supported\x20string','isSafeInteger','\x20is\x20missing\x20required\x20field\x20\x22','Notification\x20config\x20list\x20item\x20','endpointUrlRaw','12dQxoSH','dry-run','join','\x20must\x20be\x20an\x20object.','8JDDAEr','Unknown\x20notification\x20JSON\x20field\x20\x22','103992JOSDDT','trim','\x20does\x20not\x20belong\x20to\x20the\x20resolved\x20app.','file','\x20characters.','push','includes','Notification\x20JSON\x20environment\x20variable\x20is\x20not\x20set:\x20','1149240hAuliH','Notification\x20config\x20detail\x20did\x20not\x20contain\x20the\x20requested\x20ID\x20','\x22\x20cannot\x20exceed\x20','path','2125134KnefYs','Create\x20JSON\x20requires\x20field\x20','DINGTALK','Run\x20the\x20command\x20with\x20--dry-run\x20first,\x20then\x20add\x20--yes\x20after\x20reviewing\x20the\x20plan.','Read\x20the\x20notification\x20JSON\x20document\x20from\x20a\x20UTF-8\x20file','description','\x20has\x20an\x20unsupported\x20channelType.','name','notification_config_field_unknown','Missing\x20notification\x20JSON\x20source.','configName','fromName','type','EMAIL','channelConfigRaw','entries','kind','\x22\x20must\x20be\x20a\x20non-negative\x20safe\x20integer\x20or\x20null.','Read\x20the\x20notification\x20JSON\x20document\x20from\x20stdin','endpointUrl'];a197_0x189f=function(){return _0x5a95ba;};return a197_0x189f();}export function notificationSelector(_0xdd2879){const _0x32f093=a197_0x12d8c6;return{'appCode':_0xdd2879[_0x32f093(0x182)],'id':_0xdd2879['id'],'configCode':_0xdd2879[_0x32f093(0x1a9)],'configName':_0xdd2879[_0x32f093(0x166)],'channelType':_0xdd2879[_0x32f093(0x1a0)]};}export function createMutationInput(_0x13245d,_0x4fa96e){const _0x51e6d4=a197_0x12d8c6;return{'appCode':_0x13245d,'configName':_0x4fa96e[_0x51e6d4(0x166)],'channelType':_0x4fa96e[_0x51e6d4(0x1a0)],...hasOwn(_0x4fa96e,_0x51e6d4(0x16f))?{'endpointUrl':_0x4fa96e[_0x51e6d4(0x16f)]}:{},...hasOwn(_0x4fa96e,_0x51e6d4(0x185))?{'channelConfig':serializeChannelConfig(_0x4fa96e[_0x51e6d4(0x185)])}:{},...hasOwn(_0x4fa96e,'description')?{'description':_0x4fa96e[_0x51e6d4(0x161)]}:{},...hasOwn(_0x4fa96e,'connectTimeout')?{'connectTimeout':_0x4fa96e[_0x51e6d4(0x173)]}:{},...hasOwn(_0x4fa96e,_0x51e6d4(0x1bb))?{'readTimeout':_0x4fa96e['readTimeout']}:{}};}export function mergeUpdateInput(_0x289c32,_0x364966){const _0xc77c9a=a197_0x12d8c6;return{'id':_0x289c32['id'],'appCode':_0x289c32[_0xc77c9a(0x182)],'configName':_0x364966['configName']??_0x289c32[_0xc77c9a(0x166)],'channelType':_0x364966[_0xc77c9a(0x1a0)]??_0x289c32['channelType'],'endpointUrl':hasOwn(_0x364966,'endpointUrl')?_0x364966[_0xc77c9a(0x16f)]:_0x289c32[_0xc77c9a(0x1c3)],'channelConfig':hasOwn(_0x364966,_0xc77c9a(0x185))?serializeChannelConfig(_0x364966[_0xc77c9a(0x185)]):_0x289c32[_0xc77c9a(0x16a)],'description':hasOwn(_0x364966,_0xc77c9a(0x161))?_0x364966[_0xc77c9a(0x161)]:_0x289c32[_0xc77c9a(0x161)],'connectTimeout':hasOwn(_0x364966,'connectTimeout')?_0x364966['connectTimeout']:_0x289c32[_0xc77c9a(0x173)],'readTimeout':hasOwn(_0x364966,_0xc77c9a(0x1bb))?_0x364966['readTimeout']:_0x289c32['readTimeout']};}export function plannedUpdateProjection(_0x2a3dee,_0x27906d){const _0x18480c=a197_0x12d8c6;return projectNotificationConfig({'id':_0x2a3dee['id'],'appCode':_0x2a3dee['appCode'],'configCode':_0x2a3dee[_0x18480c(0x1a9)],'configName':_0x27906d['configName']??_0x2a3dee[_0x18480c(0x166)],'channelType':_0x27906d['channelType']??_0x2a3dee['channelType'],'endpointUrl':hasOwn(_0x27906d,_0x18480c(0x16f))?_0x27906d[_0x18480c(0x16f)]:_0x2a3dee[_0x18480c(0x1c3)],'channelConfig':hasOwn(_0x27906d,_0x18480c(0x185))?_0x27906d[_0x18480c(0x185)]:_0x2a3dee[_0x18480c(0x16a)],'description':hasOwn(_0x27906d,_0x18480c(0x161))?_0x27906d[_0x18480c(0x161)]:_0x2a3dee[_0x18480c(0x161)],'connectTimeout':hasOwn(_0x27906d,_0x18480c(0x173))?_0x27906d['connectTimeout']??DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:_0x2a3dee[_0x18480c(0x173)],'readTimeout':hasOwn(_0x27906d,_0x18480c(0x1bb))?_0x27906d[_0x18480c(0x1bb)]??DEFAULT_NOTIFICATION_READ_TIMEOUT:_0x2a3dee[_0x18480c(0x1bb)]});}export function requestedSafeFieldsMatch(_0x295246,_0x237b43,_0x21bb62){const _0x5e6443=a197_0x12d8c6,_0x3ca7f1=[],_0x44d137=[],_0x453a9e=[];for(const _0x288db3 of[_0x5e6443(0x166),'channelType',_0x5e6443(0x161)]){if(!hasOwn(_0x21bb62,_0x288db3))continue;_0x453a9e[_0x5e6443(0x1cf)](_0x288db3),_0x3ca7f1[_0x5e6443(0x1cf)](_0x237b43[_0x288db3]===_0x21bb62[_0x288db3]),_0x44d137[_0x5e6443(0x1cf)](_0x295246[_0x288db3]!==_0x21bb62[_0x288db3]&&_0x237b43[_0x288db3]===_0x21bb62[_0x288db3]);}for(const _0x4a685b of['connectTimeout',_0x5e6443(0x1bb)]){if(!hasOwn(_0x21bb62,_0x4a685b))continue;const _0x337837=_0x21bb62[_0x4a685b]??(_0x4a685b==='connectTimeout'?DEFAULT_NOTIFICATION_CONNECT_TIMEOUT:DEFAULT_NOTIFICATION_READ_TIMEOUT);_0x453a9e[_0x5e6443(0x1cf)](_0x4a685b),_0x3ca7f1[_0x5e6443(0x1cf)](_0x237b43[_0x4a685b]===_0x337837),_0x44d137['push'](_0x295246[_0x4a685b]!==_0x337837&&_0x237b43[_0x4a685b]===_0x337837);}return hasOwn(_0x21bb62,'endpointUrl')&&_0x21bb62['endpointUrl']===null&&(_0x453a9e[_0x5e6443(0x1cf)]('endpointUrl:null'),_0x3ca7f1['push'](_0x237b43[_0x5e6443(0x1c3)]===null||_0x237b43[_0x5e6443(0x1c3)]===''),_0x44d137[_0x5e6443(0x1cf)](_0x295246[_0x5e6443(0x1c3)]!==null&&_0x295246[_0x5e6443(0x1c3)]!==''&&(_0x237b43[_0x5e6443(0x1c3)]===null||_0x237b43[_0x5e6443(0x1c3)]===''))),{'allMatch':_0x3ca7f1['every'](Boolean),'provesChange':_0x44d137[_0x5e6443(0x19a)](Boolean),'verifiedFields':_0x453a9e};}export function validateNotificationDeleteReadback(_0x405000,_0x3d50f4,_0x50e13d){const _0x2c21e7=a197_0x12d8c6;for(const [_0x32ee2b,_0x56dd5c]of _0x405000[_0x2c21e7(0x16b)]()){if(!Number['isSafeInteger'](_0x56dd5c['id'])||_0x56dd5c['id']<=0x0)throw notificationError(_0x2c21e7(0x17e),'Notification\x20config\x20list\x20item\x20'+(_0x32ee2b+0x1)+_0x2c21e7(0x1b0));if(_0x56dd5c[_0x2c21e7(0x182)]!==_0x3d50f4)throw notificationError(_0x2c21e7(0x17e),_0x2c21e7(0x1c2)+(_0x32ee2b+0x1)+'\x20has\x20an\x20invalid\x20appCode.');if(_0x56dd5c[_0x2c21e7(0x1a0)]!==_0x50e13d)throw notificationError(_0x2c21e7(0x17e),_0x2c21e7(0x1c2)+(_0x32ee2b+0x1)+'\x20has\x20an\x20invalid\x20channelType.');}}export function safeApiFailure(_0x150da3,_0x14e05c,_0x1e9467){const _0x3cdf59=a197_0x12d8c6;return notificationError(_0x3cdf59(0x1a4)+_0x150da3+'_'+(_0x14e05c===_0x3cdf59(0x18f)?_0x3cdf59(0x171):_0x14e05c+_0x3cdf59(0x1a1)),_0x3cdf59(0x18e)+_0x150da3+'\x20'+_0x14e05c+'\x20failed.',_0x1e9467);}export function notificationLookupCommand(_0x28e758,_0x376ae0){const _0x2e550d=a197_0x12d8c6;return _0x2e550d(0x1b8)+_0x28e758+_0x2e550d(0x1af)+_0x376ae0+'\x20--format\x20compress';}function validateNotificationDocument(_0x484fef,_0x4674ef){const _0x47645d=a197_0x12d8c6;for(const _0x532e05 of Object[_0x47645d(0x172)](_0x484fef)){if(FORBIDDEN_IDENTITY_FIELDS[_0x47645d(0x175)](_0x532e05))throw notificationError('notification_config_field_forbidden',_0x47645d(0x19b)+_0x532e05+'\x22\x20is\x20controlled\x20by\x20the\x20CLI\x20or\x20server\x20and\x20is\x20forbidden.');if(!ALLOWED_INPUT_FIELDS[_0x47645d(0x175)](_0x532e05))throw notificationError(_0x47645d(0x164),_0x47645d(0x1c9)+_0x532e05+'\x22.');}if(_0x4674ef===_0x47645d(0x187)&&Object['keys'](_0x484fef)[_0x47645d(0x1a3)]===0x0)throw notificationError(_0x47645d(0x1b1),_0x47645d(0x1b4));const _0x313073={};if(hasOwn(_0x484fef,_0x47645d(0x166)))_0x313073[_0x47645d(0x166)]=validateRequiredString(_0x484fef['configName'],'configName',0x80);else{if(_0x4674ef===_0x47645d(0x198))throw notificationError(_0x47645d(0x1ba),'Create\x20JSON\x20requires\x20field\x20'+_0x47645d(0x174));}if(hasOwn(_0x484fef,_0x47645d(0x1a0))){if(typeof _0x484fef[_0x47645d(0x1a0)]!=='string')throw invalidFieldType(_0x47645d(0x1a0),_0x47645d(0x1bf));const _0x5983a8=_0x484fef[_0x47645d(0x1a0)][_0x47645d(0x1cb)]();if(!NOTIFICATION_CHANNEL_TYPES['includes'](_0x5983a8))throw notificationError(_0x47645d(0x1b5),_0x47645d(0x1be),'Allowed\x20values:\x20'+NOTIFICATION_CHANNEL_TYPES[_0x47645d(0x1c6)](',\x20')+'.');_0x313073[_0x47645d(0x1a0)]=_0x5983a8;}else{if(_0x4674ef===_0x47645d(0x198))throw notificationError(_0x47645d(0x1ba),_0x47645d(0x15d)+_0x47645d(0x17f));}for(const [_0x4e4979,_0x53b0e4]of[[_0x47645d(0x16f),0x200],[_0x47645d(0x161),0x100]]){if(!hasOwn(_0x484fef,_0x4e4979))continue;const _0x1daf99=_0x484fef[_0x4e4979];if(_0x1daf99!==null&&typeof _0x1daf99!==_0x47645d(0x195))throw invalidFieldType(_0x4e4979,'a\x20string\x20or\x20null');if(typeof _0x1daf99==='string'&&_0x1daf99[_0x47645d(0x1a3)]>_0x53b0e4)throw notificationError(_0x47645d(0x1b5),_0x47645d(0x19b)+_0x4e4979+_0x47645d(0x15a)+_0x53b0e4+_0x47645d(0x1ce));_0x313073[_0x4e4979]=_0x1daf99;}if(hasOwn(_0x484fef,_0x47645d(0x185))){const _0x2f5758=_0x484fef[_0x47645d(0x185)];if(_0x2f5758===null&&_0x4674ef===_0x47645d(0x198))throw invalidFieldType(_0x47645d(0x185),_0x47645d(0x1a2));if(_0x2f5758!==null&&!isJsonObject(_0x2f5758))throw invalidFieldType('channelConfig',_0x4674ef===_0x47645d(0x187)?'a\x20JSON\x20object\x20or\x20null':_0x47645d(0x1a2));_0x2f5758!==null&&validateChannelConfigFields(_0x313073[_0x47645d(0x1a0)],_0x2f5758),_0x313073['channelConfig']=_0x2f5758;}for(const _0x384cdf of[_0x47645d(0x173),_0x47645d(0x1bb)]){if(!hasOwn(_0x484fef,_0x384cdf))continue;const _0x864baf=_0x484fef[_0x384cdf];if(_0x864baf!==null&&(!Number[_0x47645d(0x1c0)](_0x864baf)||_0x864baf<0x0))throw notificationError(_0x47645d(0x1b5),_0x47645d(0x19b)+_0x384cdf+_0x47645d(0x16d));_0x313073[_0x384cdf]=_0x864baf;}return _0x313073;}function validateRequiredString(_0x52eab4,_0x34f9f2,_0x220001){const _0x2868c2=a197_0x12d8c6;if(typeof _0x52eab4!==_0x2868c2(0x195))throw invalidFieldType(_0x34f9f2,_0x2868c2(0x1b7));const _0x3597f6=_0x52eab4['trim']();if(!_0x3597f6)throw notificationError('notification_config_field_invalid',_0x2868c2(0x19b)+_0x34f9f2+_0x2868c2(0x19e));if(_0x3597f6[_0x2868c2(0x1a3)]>_0x220001)throw notificationError(_0x2868c2(0x1b5),_0x2868c2(0x19b)+_0x34f9f2+'\x22\x20cannot\x20exceed\x20'+_0x220001+_0x2868c2(0x1ce));return _0x3597f6;}function validateChannelConfigFields(_0x260cc2,_0x5d9ca8){const _0x2cc9fa=a197_0x12d8c6;if(hasOwn(_0x5d9ca8,'messageTemplate'))throw forbiddenChannelConfigField(_0x2cc9fa(0x1aa));if(_0x260cc2==='EMAIL')for(const _0xceea5f of EMAIL_RECIPIENT_FIELDS){if(hasOwn(_0x5d9ca8,_0xceea5f))throw forbiddenChannelConfigField(_0xceea5f);}}function forbiddenChannelConfigField(_0x16035e){return notificationError('notification_config_channel_field_forbidden','Notification\x20JSON\x20channelConfig\x20field\x20\x22'+_0x16035e+'\x22\x20is\x20forbidden.');}function invalidFieldType(_0x295b67,_0x2cbe42){const _0x30a345=a197_0x12d8c6;return notificationError(_0x30a345(0x1b5),_0x30a345(0x19b)+_0x295b67+_0x30a345(0x17a)+_0x2cbe42+'.');}function serializeChannelConfig(_0x55e47c){return _0x55e47c===null||_0x55e47c===undefined?null:JSON['stringify'](_0x55e47c);}function redactSensitive(_0x36259a){const _0xd3b602=a197_0x12d8c6;return _0x36259a===null||_0x36259a===undefined||_0x36259a===''?null:_0xd3b602(0x17b);}function requireResponseString(_0x141a44,_0x20b07c,_0x385e3a){const _0x363af4=a197_0x12d8c6;if(typeof _0x141a44!=='string'||_0x141a44[_0x363af4(0x1cb)]()==='')throw CliErrors['apiError']('Invalid\x20notification\x20config\x20response.','Item\x20'+(_0x385e3a+0x1)+_0x363af4(0x1c1)+_0x20b07c+'\x22.');return _0x141a44['trim']();}function requireExactString(_0x26cb72,_0x263354,_0x89e11d){const _0x25e568=a197_0x12d8c6;if(typeof _0x26cb72!=='string'||_0x26cb72[_0x25e568(0x1cb)]()==='')throw notificationError(_0x25e568(0x17e),'Notification\x20config\x20'+_0x89e11d+_0x25e568(0x1c1)+_0x263354+'\x22.');return _0x26cb72[_0x25e568(0x1cb)]();}function responseNullableString(_0x43e024,_0x276062,_0x3f8f7c){const _0x4e08d8=a197_0x12d8c6;if(_0x43e024===undefined||_0x43e024===null)return null;if(typeof _0x43e024!==_0x4e08d8(0x195))throw notificationError(_0x4e08d8(0x17e),_0x4e08d8(0x18e)+_0x3f8f7c+_0x4e08d8(0x18a)+_0x276062+'\x22.');return _0x43e024;}function responseNullableTimeout(_0x2c1f7d,_0x213810,_0x53c291){const _0x192c0c=a197_0x12d8c6;if(_0x2c1f7d===undefined||_0x2c1f7d===null)return null;if(!Number[_0x192c0c(0x1c0)](_0x2c1f7d)||_0x2c1f7d<0x0)throw notificationError(_0x192c0c(0x17e),_0x192c0c(0x18e)+_0x53c291+_0x192c0c(0x18a)+_0x213810+'\x22.');return _0x2c1f7d;}function normalizeNullableString(_0x64174c){return typeof _0x64174c==='string'?_0x64174c:null;}function isJsonObject(_0x5cd752){const _0x24bde0=a197_0x12d8c6;return _0x5cd752!==null&&typeof _0x5cd752==='object'&&!Array[_0x24bde0(0x192)](_0x5cd752);}function hasOwn(_0xa5a186,_0x529802){const _0x1bf081=a197_0x12d8c6;return Object['prototype']['hasOwnProperty'][_0x1bf081(0x176)](_0xa5a186,_0x529802);}async function readStdin(){const _0x30a2e3=a197_0x12d8c6;let _0x4aeaae='';process['stdin']['setEncoding']('utf8');for await(const _0xa6c2e9 of process[_0x30a2e3(0x188)])_0x4aeaae+=_0xa6c2e9;return _0x4aeaae;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a198_0x281a(_0x482713,_0x28b09a){_0x482713=_0x482713-0xd5;const _0x3d9503=a198_0x3d95();let _0x281ad3=_0x3d9503[_0x482713];return _0x281ad3;}const a198_0x26ce4a=a198_0x281a;(function(_0x1be861,_0x327d12){const _0x42d7ee=a198_0x281a,_0x3ea591=_0x1be861();while(!![]){try{const _0x1196f2=parseInt(_0x42d7ee(0xf6))/0x1+parseInt(_0x42d7ee(0xfd))/0x2*(parseInt(_0x42d7ee(0xd6))/0x3)+-parseInt(_0x42d7ee(0xd7))/0x4+parseInt(_0x42d7ee(0xdf))/0x5*(parseInt(_0x42d7ee(0xe2))/0x6)+parseInt(_0x42d7ee(0xfa))/0x7*(-parseInt(_0x42d7ee(0x100))/0x8)+-parseInt(_0x42d7ee(0xda))/0x9*(parseInt(_0x42d7ee(0xf0))/0xa)+parseInt(_0x42d7ee(0xf8))/0xb*(parseInt(_0x42d7ee(0xfc))/0xc);if(_0x1196f2===_0x327d12)break;else _0x3ea591['push'](_0x3ea591['shift']());}catch(_0x12c387){_0x3ea591['push'](_0x3ea591['shift']());}}}(a198_0x3d95,0x6ba01));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=[a198_0x26ce4a(0xf4),a198_0x26ce4a(0xe6),'form',a198_0x26ce4a(0xf2)],SCENE_TO_LEGACY_TYPE={'invoice':'Invoice','general':'General','form':a198_0x26ce4a(0xde),'idCard':'IdCard'},SCENE_FLAG={'name':a198_0x26ce4a(0xe1),'type':a198_0x26ce4a(0x106),'required':!![],'enum':[...SUPPORTED_SCENES],'description':'OCR\x20scene:\x20invoice,\x20general,\x20form,\x20or\x20idCard'},IMAGE_FILE_FLAG={'name':'image-file','type':a198_0x26ce4a(0x106),'description':a198_0x26ce4a(0xd8)},IMAGE_URL_FLAG={'name':a198_0x26ce4a(0xf3),'type':a198_0x26ce4a(0x106),'description':a198_0x26ce4a(0xf5)};function normalizeScene(_0x3a77a1){const _0x274347=a198_0x26ce4a,_0x4a608e=_0x3a77a1[_0x274347(0xe4)]()[_0x274347(0xd9)]();if(_0x4a608e==='idcard')return _0x274347(0xf2);if(_0x4a608e===_0x274347(0xf4)||_0x4a608e==='general'||_0x4a608e===_0x274347(0xdd))return _0x4a608e;throw CliErrors[_0x274347(0xdc)](_0x274347(0xe0)+_0x3a77a1+'.\x20Supported\x20scenes:\x20'+SUPPORTED_SCENES['join'](',\x20'));}function selectedInputs(_0x2fd672){const _0x6f4fc7=a198_0x26ce4a,_0x4a57ca=_0x2fd672[_0x6f4fc7(0x102)]('image-file')[_0x6f4fc7(0xe4)](),_0x173342=_0x2fd672[_0x6f4fc7(0x102)](_0x6f4fc7(0xf3))[_0x6f4fc7(0xe4)]();return{'imageFile':_0x4a57ca,'imageUrl':_0x173342,'count':[_0x4a57ca,_0x173342][_0x6f4fc7(0xee)](Boolean)[_0x6f4fc7(0xf7)]};}function a198_0x3d95(){const _0x4b1c8a=['idCard','image-url','invoice','Publicly\x20accessible\x20image\x20or\x20file\x20URL','190146HyqnUj','length','1376177TIojgG','Preview:\x20recognize\x20','259txfVMg','read','60rrywpb','1092682UFXLCN','recognize','/smartapi/common/queryFileUrl','33032yecuJS','imageUrl','str','count','fileName','image-file','string','/smartapi/ocr/recognize-text?','3GvpqKe','2834188kZHHxz','Local\x20image\x20or\x20PDF\x20file;\x20uses\x20upload\x20->\x20query-url\x20->\x20OCR','toLowerCase','18594zlVzvy','filePath','validation','form','Table','445QcXaRa','Unsupported\x20OCR\x20scene:\x20','scene','38166iFChYF','GET','trim','<fileUrl\x20returned\x20by\x20/smartapi/common/queryFileUrl>','general','fileUrl','toString','Choose\x20exactly\x20one\x20OCR\x20input:\x20--image-file\x20or\x20--image-url.','POST','\x20OCR\x20from\x20URL','appCode','apiError','filter','imageFile','3030WGIAwQ','/smartapi/common/uploadFile'];a198_0x3d95=function(){return _0x4b1c8a;};return a198_0x3d95();}function validateInputSelection(_0x34d936){const _0x3ceede=a198_0x26ce4a,_0x1d6514=selectedInputs(_0x34d936);if(_0x1d6514[_0x3ceede(0x103)]!==0x1)throw CliErrors['validation'](_0x3ceede(0xe9));return _0x1d6514;}function withScene(_0x392a10,_0x25230c,_0x185cf3){const _0x30687f=a198_0x26ce4a;return{..._0x392a10,'scene':_0x25230c,..._0x185cf3?{'sourceFile':{'fileName':_0x185cf3[_0x30687f(0x104)],'filePath':_0x185cf3[_0x30687f(0xdb)]}}:{}};}const ocrRecognize={'service':'ocr','command':a198_0x26ce4a(0xfe),'description':'Extract\x20text\x20and\x20structured\x20fields\x20from\x20voucher-style\x20business\x20documents;\x20not\x20for\x20general\x20image\x20understanding','risk':a198_0x26ce4a(0xfb),'flags':[SCENE_FLAG,IMAGE_FILE_FLAG,IMAGE_URL_FLAG],async 'dryRun'(_0x3543e3){const _0xcceef4=a198_0x26ce4a,_0x3d0ed3=normalizeScene(_0x3543e3['str'](_0xcceef4(0xe1))),_0x1d0a99=SCENE_TO_LEGACY_TYPE[_0x3d0ed3],_0x1bfe18=validateInputSelection(_0x3543e3);if(_0x1bfe18[_0xcceef4(0x101)]){const _0x539f8f=new URLSearchParams({'url':_0x1bfe18[_0xcceef4(0x101)],'type':_0x1d0a99,'appCode':_0x3543e3['appCode']});return{'method':_0xcceef4(0xe3),'url':_0xcceef4(0xd5)+_0x539f8f[_0xcceef4(0xe8)](),'description':_0xcceef4(0xf9)+_0x3d0ed3+_0xcceef4(0xeb)};}const _0x401445=requireDevelopmentUploadFile(_0x1bfe18[_0xcceef4(0xef)],'image-file');return{'method':_0xcceef4(0xea),'url':_0xcceef4(0xf1),'body':{'steps':[{'method':'POST','url':_0xcceef4(0xf1),'body':{'appCode':_0x3543e3['appCode'],'multipart':{'file':_0x401445}}},{'method':_0xcceef4(0xea),'url':_0xcceef4(0xff),'body':{'filePath':'<filePath\x20returned\x20by\x20/smartapi/common/uploadFile>','downloadFlag':![]}},{'method':_0xcceef4(0xe3),'url':'/smartapi/ocr/recognize-text','query':{'appCode':_0x3543e3['appCode'],'url':_0xcceef4(0xe5),'type':_0x1d0a99}}]},'description':'Preview:\x20upload\x20local\x20file,\x20query\x20temporary\x20URL,\x20then\x20recognize\x20'+_0x3d0ed3+'\x20OCR'};},async 'execute'(_0x471adb){const _0x3a5367=a198_0x26ce4a,_0x39a712=normalizeScene(_0x471adb[_0x3a5367(0x102)](_0x3a5367(0xe1))),_0x4f54d0=SCENE_TO_LEGACY_TYPE[_0x39a712],_0x416bfc=validateInputSelection(_0x471adb);if(_0x416bfc['imageUrl']){const _0x5a8ab2=await recognizeDevelopmentOcr(_0x471adb['appCode'],{'url':_0x416bfc[_0x3a5367(0x101)],'type':_0x4f54d0});return{'ok':!![],'data':withScene(_0x5a8ab2,_0x39a712)};}const _0x2e8de2=requireDevelopmentUploadFile(_0x416bfc[_0x3a5367(0xef)],_0x3a5367(0x105)),_0x101457=await uploadDevelopmentFile(_0x471adb[_0x3a5367(0xec)],_0x2e8de2['path']);if(!_0x101457[_0x3a5367(0xdb)])throw CliErrors[_0x3a5367(0xed)]('File\x20upload\x20response\x20missing\x20filePath.');const _0x2eb23b=await queryDevelopmentFileUrl(_0x101457[_0x3a5367(0xdb)],{'download':![]});if(!_0x2eb23b[_0x3a5367(0xe7)])throw CliErrors[_0x3a5367(0xed)]('File\x20URL\x20response\x20missing\x20fileUrl.');const _0x338047=await recognizeDevelopmentOcr(_0x471adb[_0x3a5367(0xec)],{'url':_0x2eb23b[_0x3a5367(0xe7)],'type':_0x4f54d0});return{'ok':!![],'data':withScene(_0x338047,_0x39a712,_0x101457)};}};export const ocrDefinitions=[ocrRecognize];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a199_0x5a767f=a199_0x2a9d;(function(_0x12ab4e,_0x687e7){const _0x3a5412=a199_0x2a9d,_0x122d90=_0x12ab4e();while(!![]){try{const _0x2ff76a=parseInt(_0x3a5412(0x9e))/0x1*(-parseInt(_0x3a5412(0xa2))/0x2)+-parseInt(_0x3a5412(0xad))/0x3+parseInt(_0x3a5412(0xb1))/0x4*(-parseInt(_0x3a5412(0xce))/0x5)+-parseInt(_0x3a5412(0xb6))/0x6*(parseInt(_0x3a5412(0xc0))/0x7)+parseInt(_0x3a5412(0xdd))/0x8*(-parseInt(_0x3a5412(0xd5))/0x9)+-parseInt(_0x3a5412(0xdc))/0xa*(parseInt(_0x3a5412(0xcb))/0xb)+parseInt(_0x3a5412(0xbc))/0xc;if(_0x2ff76a===_0x687e7)break;else _0x122d90['push'](_0x122d90['shift']());}catch(_0x4e3f95){_0x122d90['push'](_0x122d90['shift']());}}}(a199_0x55ff,0x349f5));import{readFile}from'node:fs/promises';import{dirname,join,resolve}from'node:path';import{fileURLToPath}from'node:url';import{APPCODE_FLAG}from'../../commands/common/flags.js';import{readCustomPageDirectory}from'../../core/page/file-system.js';import{createCustomPage}from'../../core/api-client.js';import{CliErrors}from'../../errors.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,validateCustomPageContent}from'./custom/shared.js';const CUSTOM_PAGE_PATTERNS=[a199_0x5a767f(0xbe),a199_0x5a767f(0xd9),a199_0x5a767f(0xda)],CUSTOM_PAGE_TEMPLATE_DIR=resolve(dirname(fileURLToPath(import.meta.url)),'../../../templates/custom-pages');function a199_0x2a9d(_0x4f44f2,_0x1c6eb4){_0x4f44f2=_0x4f44f2-0x9e;const _0x55ff64=a199_0x55ff();let _0x2a9d90=_0x55ff64[_0x4f44f2];return _0x2a9d90;}export const pageCreate={'service':'page','command':a199_0x5a767f(0xae),'description':a199_0x5a767f(0xc1),'risk':a199_0x5a767f(0xd1),'defaultOutputFormat':a199_0x5a767f(0xcc),'structuredErrors':!![],'rejectedFlags':[{'name':'page-type','message':a199_0x5a767f(0xe0),'hint':a199_0x5a767f(0xc4)},{'name':'page-content','message':a199_0x5a767f(0xaa),'hint':a199_0x5a767f(0xc3)}],'flags':[{'name':a199_0x5a767f(0xde),'type':'string','description':a199_0x5a767f(0xc5)},{'name':'parent-menu-id','type':a199_0x5a767f(0xd0),'description':a199_0x5a767f(0xb8)},{'name':'page-pattern','type':a199_0x5a767f(0xa5),'description':a199_0x5a767f(0xd6),'enum':CUSTOM_PAGE_PATTERNS},{'name':a199_0x5a767f(0xdb),'type':'string','description':a199_0x5a767f(0xc9)},APPCODE_FLAG],async 'validate'(_0x28db36){await readValidatedPageSource(_0x28db36);},async 'dryRun'(_0x14d0ad){const _0x4f695a=a199_0x5a767f,_0x1fc364=readInput(_0x14d0ad,await readValidatedPageSource(_0x14d0ad));return{'method':_0x4f695a(0xb5),'url':_0x4f695a(0xe2),'body':{'appCode':_0x1fc364[_0x4f695a(0xa9)],'pageName':_0x1fc364['pageName'],..._0x1fc364[_0x4f695a(0xe1)]!=null?{'parentMenuId':_0x1fc364[_0x4f695a(0xe1)]}:{},'createMenu':_0x1fc364[_0x4f695a(0xb4)],'codeContent':_0x1fc364[_0x4f695a(0xa0)]},'description':'Would\x20create\x20Custom\x20Page\x20'+JSON[_0x4f695a(0xb3)](_0x1fc364[_0x4f695a(0xd7)])+_0x4f695a(0xbb)};},async 'execute'(_0x5345ec){const _0x3cd1d1=a199_0x5a767f,_0x25553e=readInput(_0x5345ec,await readValidatedPageSource(_0x5345ec)),_0x3bb768=await createCustomPage(_0x25553e);if(!Number[_0x3cd1d1(0xa4)](_0x3bb768['pageId'])||_0x3bb768[_0x3cd1d1(0xca)]<=0x0)throw CliErrors[_0x3cd1d1(0xba)](_0x3cd1d1(0xd2));const _0x3ba17b=buildCustomPageDevelopmentUrl(_0x25553e[_0x3cd1d1(0xa9)],_0x3bb768[_0x3cd1d1(0xc7)]),_0x1b9cfa=buildCustomPageEditUrl(_0x25553e[_0x3cd1d1(0xa9)],_0x3bb768[_0x3cd1d1(0xca)]);return{'ok':!![],'data':{'operation':_0x3cd1d1(0xc6),'pageType':_0x3cd1d1(0xdf),'pagePattern':readPagePattern(_0x5345ec),'selector':{'appCode':_0x25553e['appCode'],'pageName':_0x25553e[_0x3cd1d1(0xd7)]},'before':null,'after':{'pageId':_0x3bb768[_0x3cd1d1(0xca)],'pageName':_0x3bb768[_0x3cd1d1(0xd7)],'appCode':_0x3bb768[_0x3cd1d1(0xa9)],'version':_0x3bb768[_0x3cd1d1(0xa1)],'menuId':_0x3bb768[_0x3cd1d1(0xa6)],'menuPath':_0x3bb768[_0x3cd1d1(0xc7)],'files':_0x3bb768['files']??Object[_0x3cd1d1(0x9f)](_0x25553e[_0x3cd1d1(0xa0)])},'dryRun':![],'request':_0x25553e,..._0x3ba17b?{'pageUrl':_0x3ba17b}:{},..._0x1b9cfa?{'editPageUrl':_0x1b9cfa}:{},'warnings':_0x3ba17b?[]:[_0x3cd1d1(0xaf)]},'message':_0x3cd1d1(0xbf)+_0x3bb768[_0x3cd1d1(0xca)]+'.'};}};function readPagePattern(_0x5bdc0a){const _0x4fdfe9=a199_0x5a767f,_0x1292aa=_0x5bdc0a[_0x4fdfe9(0xc2)](_0x4fdfe9(0xd8))[_0x4fdfe9(0xa8)](),_0x22d3f3=_0x5bdc0a[_0x4fdfe9(0xc2)](_0x4fdfe9(0xdb))[_0x4fdfe9(0xa8)]();if(_0x1292aa&&_0x22d3f3)throw CliErrors[_0x4fdfe9(0xac)](_0x4fdfe9(0xb7));if(_0x22d3f3)return null;if(!_0x1292aa)throw CliErrors[_0x4fdfe9(0xac)](_0x4fdfe9(0xcf));if(!CUSTOM_PAGE_PATTERNS['includes'](_0x1292aa))throw CliErrors[_0x4fdfe9(0xac)](_0x4fdfe9(0xc8));return _0x1292aa;}async function readPageSource(_0x52868e){const _0x198de5=a199_0x5a767f,_0x192b8d=_0x52868e['str'](_0x198de5(0xdb))[_0x198de5(0xa8)](),_0x90d48d=readPagePattern(_0x52868e);if(_0x90d48d===null){const _0x4d667b=await readCustomPageDirectory(_0x192b8d);if(Object['keys'](_0x4d667b)['length']===0x0)throw CliErrors['validation'](_0x198de5(0xd4));return _0x4d667b;}let _0x417186;try{_0x417186=await readFile(join(CUSTOM_PAGE_TEMPLATE_DIR,_0x90d48d[_0x198de5(0xcd)]()+'.json'),'utf8');}catch{throw CliErrors[_0x198de5(0xac)]('Custom\x20Page\x20pattern\x20not\x20found:\x20'+_0x90d48d+'.');}let _0x4d6ea4;try{_0x4d6ea4=JSON[_0x198de5(0xd3)](_0x417186);}catch{throw CliErrors[_0x198de5(0xac)](_0x198de5(0xe5)+_0x90d48d+'.');}if(!_0x4d6ea4||typeof _0x4d6ea4!==_0x198de5(0xb0)||Array['isArray'](_0x4d6ea4)||Object[_0x198de5(0xb2)](_0x4d6ea4)[_0x198de5(0xa3)](_0x248624=>typeof _0x248624!==_0x198de5(0xa5)))throw CliErrors[_0x198de5(0xac)]('Invalid\x20Custom\x20Page\x20pattern:\x20'+_0x90d48d+'.');return _0x4d6ea4;}async function readValidatedPageSource(_0x168b3c){const _0xf6beef=await readPageSource(_0x168b3c);return await validateCustomPageContent(_0xf6beef),_0xf6beef;}function a199_0x55ff(){const _0x171512=['Created\x20Custom\x20Page\x20','79457JnLLnN','Create\x20a\x20JSX\x20Custom\x20Page\x20from\x20a\x20released\x20pattern\x20or\x20local\x20directory','str','Write\x20the\x20complete\x20page\x20files\x20to\x20a\x20local\x20directory\x20and\x20use\x20--page-dir\x20<dir>.','This\x20command\x20always\x20creates\x20a\x20CUSTOM\x20JSX\x20page;\x20use\x20--page-pattern\x20BLANK,\x20ONEPAGE,\x20DASHBOARD,\x20or\x20--page-dir.','Optional\x20Custom\x20Page\x20name\x20(1-100\x20characters)','page.create','menuPath','--page-pattern\x20must\x20be\x20BLANK,\x20ONEPAGE,\x20or\x20DASHBOARD.','Directory\x20containing\x20all\x20page\x20files\x20(cannot\x20be\x20used\x20with\x20--page-pattern)','pageId','55dtUcYS','compress','toLowerCase','2043470cubSVy','Provide\x20--page-pattern\x20BLANK,\x20ONEPAGE,\x20DASHBOARD,\x20or\x20--page-dir\x20<dir>.','number','write','Custom\x20Page\x20creation\x20did\x20not\x20return\x20a\x20valid\x20pageId.','parse','--page-dir\x20must\x20contain\x20at\x20least\x20one\x20page\x20file.','117ZgQVPE','Built-in\x20Custom\x20Page\x20pattern\x20(cannot\x20be\x20used\x20with\x20--page-dir)','pageName','page-pattern','ONEPAGE','DASHBOARD','page-dir','235150TRjkYr','35032wvmRUE','name','CUSTOM','page\x20create\x20does\x20not\x20accept\x20--page-type.','parentMenuId','/smartapi/webcode/page/create','num','--parent-menu-id\x20must\x20be\x20a\x20positive\x20integer.','Invalid\x20Custom\x20Page\x20pattern:\x20','47jTtESv','keys','files','version','1948WMGqzA','some','isInteger','string','menuId','length','trim','appCode','page\x20create\x20no\x20longer\x20accepts\x20--page-content.','Custom_page_','validation','1102452nEqUgv','create','Custom\x20Page\x20was\x20created,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','object','4iZSGZz','values','stringify','createMenu','POST','180fbdBFR','--page-pattern\x20and\x20--page-dir\x20cannot\x20be\x20used\x20together.','Optional\x20parent\x20menu\x20id\x20when\x20creating\x20a\x20menu\x20entry','now','apiError','\x20and\x20its\x20menu\x20entry.','18630348ZzfXXl','pageName\x20cannot\x20exceed\x20100\x20characters.','BLANK'];a199_0x55ff=function(){return _0x171512;};return a199_0x55ff();}function readInput(_0x3a56fa,_0x1e2760){const _0x5d7731=a199_0x5a767f,_0x323bc5=_0x3a56fa[_0x5d7731(0xc2)](_0x5d7731(0xde))[_0x5d7731(0xa8)]()||_0x5d7731(0xab)+Date[_0x5d7731(0xb9)]();if(_0x323bc5[_0x5d7731(0xa7)]>0x64)throw CliErrors[_0x5d7731(0xac)](_0x5d7731(0xbd));const _0xa37f43=_0x3a56fa[_0x5d7731(0xe3)]('parent-menu-id',NaN),_0x2c9284=!Number['isNaN'](_0xa37f43);if(_0x2c9284&&(!Number['isInteger'](_0xa37f43)||_0xa37f43<=0x0))throw CliErrors['validation'](_0x5d7731(0xe4));return{'appCode':_0x3a56fa[_0x5d7731(0xa9)],'pageName':_0x323bc5,..._0x2c9284?{'parentMenuId':_0xa37f43}:{},'createMenu':!![],'files':_0x1e2760};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a200_0x9702(_0x43b9dc,_0x59d977){_0x43b9dc=_0x43b9dc-0x164;const _0x25e6ce=a200_0x25e6();let _0x97029f=_0x25e6ce[_0x43b9dc];return _0x97029f;}const a200_0x3f3807=a200_0x9702;(function(_0x356dfb,_0x586ae7){const _0x5334b0=a200_0x9702,_0x4016bd=_0x356dfb();while(!![]){try{const _0x27d788=parseInt(_0x5334b0(0x180))/0x1*(-parseInt(_0x5334b0(0x176))/0x2)+parseInt(_0x5334b0(0x17c))/0x3+-parseInt(_0x5334b0(0x169))/0x4+parseInt(_0x5334b0(0x16c))/0x5+parseInt(_0x5334b0(0x17d))/0x6*(-parseInt(_0x5334b0(0x16a))/0x7)+-parseInt(_0x5334b0(0x16e))/0x8+parseInt(_0x5334b0(0x170))/0x9;if(_0x27d788===_0x586ae7)break;else _0x4016bd['push'](_0x4016bd['shift']());}catch(_0x95737b){_0x4016bd['push'](_0x4016bd['shift']());}}}(a200_0x25e6,0x69131));import{getCustomPageSource}from'../../../core/api-client.js';function a200_0x25e6(){const _0x508031=['20qOwxFE','getFullYear','getMinutes','trim','Retrieved\x20Custom\x20Page\x20','str','getTime','3209936MVupXG','793947hcZtOG','join','3785220sIJFDz','custom-detail','3731064NyilMR','cookie','13397193rUHPGg','Custom\x20Page\x20ID','Show\x20a\x20Custom\x20Page\x20and\x20all\x20of\x20its\x20files','getMonth','isNaN','page','40452iOxTrt','appCode','appcode','getSeconds','getHours','pageCode','1956294wizUpF','42iMhpTc','getDate','padStart'];a200_0x25e6=function(){return _0x508031;};return a200_0x25e6();}import{buildCustomPageEditUrl,buildCustomPageRuntimeUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,resolveCustomPageDevelopmentUrl}from'./shared.js';export const pageCustomDetail={'service':a200_0x3f3807(0x175),'command':a200_0x3f3807(0x16d),'description':a200_0x3f3807(0x172),'risk':'read','defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':'number','required':!![],'description':a200_0x3f3807(0x171)},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x4e0a37){readCustomPageId(_0x4e0a37);},async 'execute'(_0x471152){const _0x418dd4=a200_0x3f3807,_0x336224=readCustomPageId(_0x471152),_0x24ba5b=await getCustomPageSource(_0x336224),{bundle:_0x178888,createTime:_0x27fe66,updateTime:_0x1016ea,..._0x22b0f0}=_0x24ba5b,_0x179d16=_0x24ba5b['id']??_0x336224,_0x30f3e1=_0x24ba5b[_0x418dd4(0x177)]?.['trim']()||_0x471152[_0x418dd4(0x167)](_0x418dd4(0x178))[_0x418dd4(0x165)](),_0x2b0a98=buildCustomPageRuntimeUrl(_0x30f3e1,_0x24ba5b[_0x418dd4(0x17b)]),_0x4c2034=buildCustomPageEditUrl(_0x30f3e1,_0x179d16),_0x4c5734=await resolveCustomPageDevelopmentUrl(_0x30f3e1,_0x179d16,_0x471152[_0x418dd4(0x16f)]);return{'ok':!![],'data':{..._0x22b0f0,..._0x2b0a98?{'runtimePageUrl':_0x2b0a98}:{},..._0x4c5734?{'pageUrl':_0x4c5734}:{},..._0x4c2034?{'editPageUrl':_0x4c2034}:{},..._0x27fe66==null?{}:{'createTime':formatTime(_0x27fe66)},..._0x1016ea==null?{}:{'updateTime':formatTime(_0x1016ea)}},'message':_0x418dd4(0x166)+_0x336224+'.'};}};function formatTime(_0x3f24af){const _0x309c9f=a200_0x3f3807,_0x17ca39=new Date(_0x3f24af);if(Number[_0x309c9f(0x174)](_0x17ca39[_0x309c9f(0x168)]()))return String(_0x3f24af);const _0x1d49b9=[_0x17ca39[_0x309c9f(0x181)](),String(_0x17ca39[_0x309c9f(0x173)]()+0x1)['padStart'](0x2,'0'),String(_0x17ca39[_0x309c9f(0x17e)]())['padStart'](0x2,'0')][_0x309c9f(0x16b)]('-'),_0x1d3acb=[String(_0x17ca39[_0x309c9f(0x17a)]())[_0x309c9f(0x17f)](0x2,'0'),String(_0x17ca39[_0x309c9f(0x164)]())[_0x309c9f(0x17f)](0x2,'0'),String(_0x17ca39[_0x309c9f(0x179)]())[_0x309c9f(0x17f)](0x2,'0')][_0x309c9f(0x16b)](':');return _0x1d49b9+'\x20'+_0x1d3acb;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a201_0x40c97d=a201_0x452a;function a201_0x452a(_0x49bb8b,_0x5cfcf3){_0x49bb8b=_0x49bb8b-0x127;const _0x6a81c1=a201_0x6a81();let _0x452aa8=_0x6a81c1[_0x49bb8b];return _0x452aa8;}(function(_0x107d8b,_0x30b6f1){const _0x1c06b4=a201_0x452a,_0x123f6d=_0x107d8b();while(!![]){try{const _0xa4e4f7=-parseInt(_0x1c06b4(0x139))/0x1*(-parseInt(_0x1c06b4(0x134))/0x2)+parseInt(_0x1c06b4(0x133))/0x3+parseInt(_0x1c06b4(0x13a))/0x4*(-parseInt(_0x1c06b4(0x12e))/0x5)+-parseInt(_0x1c06b4(0x130))/0x6*(-parseInt(_0x1c06b4(0x12f))/0x7)+-parseInt(_0x1c06b4(0x138))/0x8+parseInt(_0x1c06b4(0x131))/0x9*(parseInt(_0x1c06b4(0x137))/0xa)+-parseInt(_0x1c06b4(0x136))/0xb;if(_0xa4e4f7===_0x30b6f1)break;else _0x123f6d['push'](_0x123f6d['shift']());}catch(_0x53b6b6){_0x123f6d['push'](_0x123f6d['shift']());}}}(a201_0x6a81,0xd554c));import{APPCODE_FLAG_OPTIONAL}from'../../../commands/common/flags.js';import{fetchMenuSnapshot}from'../../../commands/menu/shared/facts.js';import{buildCustomPageDevelopmentUrl,buildCustomPageEditUrl,buildCustomPageRuntimeUrl}from'./shared.js';function a201_0x6a81(){const _0x3e1335=['\x20Custom\x20Page(s).','cookie','react','5IQRuTy','59668kKQqSX','474yKAVKk','9jLNQkw','List\x20Custom\x20Pages\x20in\x20the\x20current\x20app','3184644qNCRqa','14GrrQqp','No\x20Custom\x20Pages\x20found.','17384741DTSZRQ','4330650RRQvXq','91728wSGtjo','121749XBgrQb','2218204RjZzCq','pageId','compress','appCode','path','type','page','menus','length','flatMap'];a201_0x6a81=function(){return _0x3e1335;};return a201_0x6a81();}export const pageCustomList={'service':a201_0x40c97d(0x127),'command':'custom-list','description':a201_0x40c97d(0x132),'risk':'read','defaultOutputFormat':a201_0x40c97d(0x13c),'structuredErrors':!![],'flags':[APPCODE_FLAG_OPTIONAL],async 'execute'(_0x3acc9d){const _0x4afaf4=a201_0x40c97d,_0x1d8f1d=(await fetchMenuSnapshot(_0x3acc9d[_0x4afaf4(0x13d)],_0x3acc9d[_0x4afaf4(0x12c)]))[_0x4afaf4(0x128)][_0x4afaf4(0x12a)](_0x198a93=>{const _0x3a3f56=_0x4afaf4;if(_0x198a93[_0x3a3f56(0x13f)]!==_0x3a3f56(0x12d)||_0x198a93[_0x3a3f56(0x13b)]==null)return[];const _0x56d444=buildCustomPageDevelopmentUrl(_0x3acc9d['appCode'],_0x198a93[_0x3a3f56(0x13e)]),_0x940d37=buildCustomPageRuntimeUrl(_0x3acc9d[_0x3a3f56(0x13d)],_0x198a93[_0x3a3f56(0x13e)]),_0x2d714b=buildCustomPageEditUrl(_0x3acc9d[_0x3a3f56(0x13d)],_0x198a93['pageId']);return[{'pageId':_0x198a93[_0x3a3f56(0x13b)],'label':_0x198a93['label'],'path':_0x198a93[_0x3a3f56(0x13e)],..._0x56d444?{'pageUrl':_0x56d444}:{},..._0x940d37?{'runtimePageUrl':_0x940d37}:{},..._0x2d714b?{'editPageUrl':_0x2d714b}:{}}];});return{'ok':!![],'data':{'pages':_0x1d8f1d},'message':_0x1d8f1d[_0x4afaf4(0x129)]===0x0?_0x4afaf4(0x135):'Found\x20'+_0x1d8f1d[_0x4afaf4(0x129)]+_0x4afaf4(0x12b)};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a202_0x1b1b1e=a202_0xe9a1;(function(_0x213a41,_0x166d9f){const _0x3fec45=a202_0xe9a1,_0xdb6be=_0x213a41();while(!![]){try{const _0x1f366a=parseInt(_0x3fec45(0x1d9))/0x1+parseInt(_0x3fec45(0x1cc))/0x2*(-parseInt(_0x3fec45(0x1dd))/0x3)+-parseInt(_0x3fec45(0x1e5))/0x4+-parseInt(_0x3fec45(0x1da))/0x5*(parseInt(_0x3fec45(0x1dc))/0x6)+parseInt(_0x3fec45(0x1db))/0x7*(parseInt(_0x3fec45(0x1e1))/0x8)+parseInt(_0x3fec45(0x1d7))/0x9+parseInt(_0x3fec45(0x1ca))/0xa*(parseInt(_0x3fec45(0x1d8))/0xb);if(_0x1f366a===_0x166d9f)break;else _0xdb6be['push'](_0xdb6be['shift']());}catch(_0x15e927){_0xdb6be['push'](_0xdb6be['shift']());}}}(a202_0x2dd6,0x5d5ae));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':a202_0x1b1b1e(0x1d6),'command':a202_0x1b1b1e(0x1cb),'description':a202_0x1b1b1e(0x1d1),'risk':'write','defaultOutputFormat':'compress','structuredErrors':!![],'requiresAppCode':![],'flags':[{'name':'id','type':a202_0x1b1b1e(0x1e2),'required':!![],'description':a202_0x1b1b1e(0x1d5)},{'name':'remark','type':a202_0x1b1b1e(0x1d2),'description':'Optional\x20publish\x20remark'}],async 'validate'(_0x478d8b){readCustomPageId(_0x478d8b);},async 'dryRun'(_0x4a69eb){const _0x51348e=a202_0x1b1b1e,_0x49f72c=readInput(_0x4a69eb);return{'method':'POST','url':_0x51348e(0x1df),'body':{'id':_0x49f72c[_0x51348e(0x1d4)],..._0x49f72c[_0x51348e(0x1cf)]?{'remark':_0x49f72c[_0x51348e(0x1cf)]}:{}},'description':'Would\x20publish\x20Custom\x20Page\x20'+_0x49f72c[_0x51348e(0x1d4)]+'.'};},async 'execute'(_0x3404d7){const _0x5c7fc2=a202_0x1b1b1e,_0x81bff0=readInput(_0x3404d7);await getCustomPageSource(_0x81bff0['pageId']);const _0x3eb1ed=await publishCustomPage(_0x81bff0);if(!Number['isInteger'](_0x3eb1ed)||_0x3eb1ed!==_0x81bff0['pageId'])throw CliErrors[_0x5c7fc2(0x1d0)](_0x5c7fc2(0x1c6));const _0x3efaa2=await getCustomPageSource(_0x81bff0[_0x5c7fc2(0x1d4)]);if(_0x3efaa2[_0x5c7fc2(0x1e3)]!=='FORMAL')throw CliErrors['apiError'](_0x5c7fc2(0x1de)+(_0x3efaa2[_0x5c7fc2(0x1e3)]??'unknown')+'.');const _0x273d4a=_0x3efaa2[_0x5c7fc2(0x1c5)]?.[_0x5c7fc2(0x1c9)](),_0x1a9534=buildCustomPageEditUrl(_0x273d4a,_0x81bff0[_0x5c7fc2(0x1d4)]),_0x249a75=await resolveCustomPageDevelopmentUrl(_0x273d4a,_0x81bff0['pageId'],_0x3404d7['cookie']),_0xef9f3f=buildMutationData(_0x81bff0,!![],_0x249a75,_0x1a9534);_0x273d4a&&!_0x249a75&&_0xef9f3f[_0x5c7fc2(0x1ce)]['push'](_0x5c7fc2(0x1cd));const _0x5b80f6=buildCustomPageRuntimeUrl(_0x3efaa2[_0x5c7fc2(0x1c5)],_0x3efaa2[_0x5c7fc2(0x1e0)]);return _0x5b80f6?_0xef9f3f[_0x5c7fc2(0x1c8)]=_0x5b80f6:_0xef9f3f[_0x5c7fc2(0x1ce)]['push']('Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20published\x20page\x20could\x20not\x20be\x20generated.'),{'ok':!![],'data':_0xef9f3f,'message':_0x5c7fc2(0x1d3)+_0x81bff0[_0x5c7fc2(0x1d4)]+'.'};}};function readInput(_0x509dc4){const _0x5e6d17=a202_0x1b1b1e,_0x86fd42=readCustomPageId(_0x509dc4),_0x2fa03e=_0x509dc4[_0x5e6d17(0x1c7)](_0x5e6d17(0x1cf))[_0x5e6d17(0x1c9)]();return{'pageId':_0x86fd42,..._0x2fa03e?{'remark':_0x2fa03e}:{}};}function a202_0xe9a1(_0x353d15,_0x203ce0){_0x353d15=_0x353d15-0x1c5;const _0x2dd6f5=a202_0x2dd6();let _0xe9a131=_0x2dd6f5[_0x353d15];return _0xe9a131;}function buildMutationData(_0x270731,_0xc39621=![],_0xc2ae9f,_0x4d5f4f){const _0x2c34c3=a202_0x1b1b1e;return{'operation':_0x2c34c3(0x1e4),'selector':{'pageId':_0x270731[_0x2c34c3(0x1d4)]},'before':null,'after':{'pageId':_0x270731[_0x2c34c3(0x1d4)],'status':'FORMAL'},'dryRun':!_0xc39621,'request':_0x270731,..._0xc2ae9f?{'pageUrl':_0xc2ae9f}:{},..._0x4d5f4f?{'editPageUrl':_0x4d5f4f}:{},'warnings':[]};}function a202_0x2dd6(){const _0x31daa2=['custom-publish','1132948ivSvNH','Published\x20successfully,\x20but\x20a\x20link\x20to\x20the\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','warnings','remark','apiError','Publish\x20the\x20latest\x20saved\x20content\x20of\x20a\x20Custom\x20Page','string','Published\x20Custom\x20Page\x20','pageId','Custom\x20Page\x20ID','page','3053340iSWNfq','814YLqFsD','294633VbpTCx','1401245XAdIGL','2443DhcVjr','12kbsyjd','3XdTcOX','Custom\x20Page\x20publish\x20did\x20not\x20reach\x20published\x20status:\x20','/smartapi/webcode/file/publish','pageCode','13544PoxKob','number','status','page.custom-publish','283272zDOWeS','appCode','Custom\x20Page\x20publish\x20did\x20not\x20return\x20the\x20expected\x20page\x20ID.','str','runtimePageUrl','trim','48030gOJtAf'];a202_0x2dd6=function(){return _0x31daa2;};return a202_0x2dd6();}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
function a203_0x2cf3(_0xea4b8a,_0x3c0621){_0xea4b8a=_0xea4b8a-0xff;const _0x379b36=a203_0x379b();let _0x2cf3dd=_0x379b36[_0xea4b8a];return _0x2cf3dd;}const a203_0x5255e0=a203_0x2cf3;(function(_0x1c265f,_0x3a0315){const _0x493ee3=a203_0x2cf3,_0x5c0e31=_0x1c265f();while(!![]){try{const _0x1e2120=-parseInt(_0x493ee3(0xff))/0x1*(-parseInt(_0x493ee3(0x102))/0x2)+parseInt(_0x493ee3(0x108))/0x3+parseInt(_0x493ee3(0x10f))/0x4*(parseInt(_0x493ee3(0x10c))/0x5)+-parseInt(_0x493ee3(0x11c))/0x6*(-parseInt(_0x493ee3(0x117))/0x7)+parseInt(_0x493ee3(0x118))/0x8+parseInt(_0x493ee3(0x10d))/0x9+parseInt(_0x493ee3(0x106))/0xa*(-parseInt(_0x493ee3(0x110))/0xb);if(_0x1e2120===_0x3a0315)break;else _0x5c0e31['push'](_0x5c0e31['shift']());}catch(_0x5e89b6){_0x5c0e31['push'](_0x5c0e31['shift']());}}}(a203_0x379b,0x1daae));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 a203_0x379b(){const _0x2be547=['message','204Urdili','113971WhNxRG','num','validation','react','Optional\x20app\x20code\x20resolved\x20from\x20page\x20ID\x20when\x20omitted','/ide/','pageId','423283BcsjEn','1773376TgcGip','trim','type','find','24cudAhF','72elJksI','isInteger','join','4202fvwsAt','length','file','map','780jpXagz','--id\x20must\x20be\x20a\x20positive\x20integer.','369348aStMOS','Invalid\x20Custom\x20Page\x20content:\x20','path','/pages/','4205EHSKIt','1339641JbNQYf'];a203_0x379b=function(){return _0x2be547;};return a203_0x379b();}export const CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL={...APPCODE_FLAG_OPTIONAL,'description':a203_0x5255e0(0x114)};function trimOptional(_0x29e07d){const _0x5f1dcc=a203_0x5255e0;return _0x29e07d?.[_0x5f1dcc(0x119)]()||undefined;}export function buildCustomPageRuntimeUrl(_0x507408,_0x501209){const _0x1213aa=trimOptional(_0x507408),_0x58412e=trimOptional(_0x501209);if(!_0x1213aa||!_0x58412e)return undefined;return getPublishedAppDomain(_0x1213aa)+'/'+encodeURIComponent(_0x58412e);}export function buildCustomPageDevelopmentUrl(_0x3de8e4,_0x220705){const _0x7de8b0=a203_0x5255e0,_0x30698d=trimOptional(_0x3de8e4),_0x346448=trimOptional(_0x220705);if(!_0x30698d||!_0x346448)return undefined;return getAppBaseUrl(_0x30698d)+_0x7de8b0(0x10b)+encodeURIComponent(_0x346448);}export async function resolveCustomPageDevelopmentUrl(_0x498b8f,_0x57682f,_0xa9c44f){const _0xdb5ea8=a203_0x5255e0,_0x4a7c94=trimOptional(_0x498b8f);if(!_0x4a7c94)return undefined;try{const _0x33b3f9=(await fetchMenuSnapshot(_0x4a7c94,_0xa9c44f))['menus'][_0xdb5ea8(0x11b)](_0x2e7303=>_0x2e7303[_0xdb5ea8(0x11a)]===_0xdb5ea8(0x113)&&_0x2e7303[_0xdb5ea8(0x116)]===_0x57682f);return buildCustomPageDevelopmentUrl(_0x4a7c94,_0x33b3f9?.[_0xdb5ea8(0x10a)]);}catch{return undefined;}}export function buildCustomPageEditUrl(_0x5adb77,_0xc98377){const _0x534aa7=a203_0x5255e0,_0x423d15=trimOptional(_0x5adb77);if(!_0x423d15)return;const _0x219e8e=trimOptional(String(_0xc98377??''));if(!_0x219e8e)return;return getAppBaseUrl(_0x423d15)+_0x534aa7(0x115)+encodeURIComponent(_0x219e8e);}export async function validateCustomPageContent(_0x1d8b74){const _0x188a35=a203_0x5255e0,_0x1a7d6c=await validateCustomPageSourceFiles(_0x1d8b74);if(_0x1a7d6c[_0x188a35(0x103)]>0x0)throw CliErrors[_0x188a35(0x112)](_0x188a35(0x109)+_0x1a7d6c[_0x188a35(0x105)](_0x3961a0=>_0x3961a0[_0x188a35(0x104)]+':\x20'+_0x3961a0[_0x188a35(0x10e)])[_0x188a35(0x101)](';\x20'));}export function readCustomPageId(_0x3d779f){const _0x41b634=a203_0x5255e0,_0x5b757a=_0x3d779f[_0x41b634(0x111)]('id');if(!Number[_0x41b634(0x100)](_0x5b757a)||_0x5b757a<=0x0)throw CliErrors[_0x41b634(0x112)](_0x41b634(0x107));return _0x5b757a;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a204_0x529189=a204_0x249a;(function(_0x3cf132,_0x240290){const _0x1c684d=a204_0x249a,_0x88e1cf=_0x3cf132();while(!![]){try{const _0x18c6f9=parseInt(_0x1c684d(0x1e6))/0x1+-parseInt(_0x1c684d(0x1da))/0x2*(-parseInt(_0x1c684d(0x1de))/0x3)+-parseInt(_0x1c684d(0x1db))/0x4*(parseInt(_0x1c684d(0x1e8))/0x5)+-parseInt(_0x1c684d(0x1e9))/0x6+-parseInt(_0x1c684d(0x1d3))/0x7+-parseInt(_0x1c684d(0x1ea))/0x8+parseInt(_0x1c684d(0x1e4))/0x9;if(_0x18c6f9===_0x240290)break;else _0x88e1cf['push'](_0x88e1cf['shift']());}catch(_0x7c436d){_0x88e1cf['push'](_0x88e1cf['shift']());}}}(a204_0x2a15,0x8ed23));import{format}from'prettier';function a204_0x249a(_0x3f47c5,_0x4486c6){_0x3f47c5=_0x3f47c5-0x1d3;const _0x2a157f=a204_0x2a15();let _0x249a73=_0x2a157f[_0x3f47c5];return _0x249a73;}const SOURCE_PARSERS={'.js':a204_0x529189(0x1e5),'.jsx':a204_0x529189(0x1e5),'.ts':a204_0x529189(0x1d9),'.tsx':a204_0x529189(0x1d9)},CUSTOM_PAGE_EXTENSIONS=[a204_0x529189(0x1dd),'.tsx'];export async function validateCustomPageSourceFiles(_0x2f779c){const _0x5dc98c=a204_0x529189,_0x4ac8eb=Object[_0x5dc98c(0x1e2)](_0x2f779c)[_0x5dc98c(0x1df)](([_0x52b61f])=>getParser(_0x52b61f));if(!_0x4ac8eb[_0x5dc98c(0x1dc)](([_0x4fc778])=>isReactSourceFile(_0x4fc778)))return[{'file':_0x5dc98c(0x1e7),'message':_0x5dc98c(0x1e0)}];const _0x234551=await Promise[_0x5dc98c(0x1d4)](_0x4ac8eb[_0x5dc98c(0x1e1)](async([_0x5f1bed,_0x22b216])=>{const _0x552901=_0x5dc98c;try{return await format(_0x22b216,{'parser':getParser(_0x5f1bed)}),undefined;}catch(_0x1a5eb4){return{'file':_0x5f1bed,'message':_0x1a5eb4 instanceof Error?_0x1a5eb4[_0x552901(0x1d6)]:String(_0x1a5eb4)};}}));return _0x234551[_0x5dc98c(0x1df)](_0x36dc02=>_0x36dc02!==undefined);}function getParser(_0x4bb2b7){const _0x425d7f=a204_0x529189,_0x45cd20=_0x4bb2b7[_0x425d7f(0x1e3)]()[_0x425d7f(0x1d8)]();return Object[_0x425d7f(0x1e2)](SOURCE_PARSERS)[_0x425d7f(0x1d5)](([_0x238a77])=>_0x45cd20['endsWith'](_0x238a77))?.[0x1];}function a204_0x2a15(){const _0x43f795=['46047wWRzdl','filter','Missing\x20React\x20source\x20file\x20with\x20extension\x20.jsx\x20or\x20.tsx','map','entries','trim','25830639ZGaazL','babel','118835cemzFW','page\x20files','5KtTSrf','1637826FgsNhs','5012896yWgHkj','4294444AGyTGm','all','find','message','endsWith','toLowerCase','typescript','32UDHXSm','4545680sKWNCf','some','.jsx'];a204_0x2a15=function(){return _0x43f795;};return a204_0x2a15();}function isReactSourceFile(_0x29b446){const _0x18d833=a204_0x529189,_0x20167d=_0x29b446[_0x18d833(0x1e3)]()[_0x18d833(0x1d8)]();return CUSTOM_PAGE_EXTENSIONS[_0x18d833(0x1dc)](_0x51732e=>_0x20167d[_0x18d833(0x1d7)](_0x51732e));}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a205_0x12d85b=a205_0x4572;(function(_0x500100,_0x6ffb1b){const _0x30141c=a205_0x4572,_0x463e31=_0x500100();while(!![]){try{const _0x4c4fe8=-parseInt(_0x30141c(0x16e))/0x1*(-parseInt(_0x30141c(0x17d))/0x2)+parseInt(_0x30141c(0x167))/0x3+-parseInt(_0x30141c(0x186))/0x4+parseInt(_0x30141c(0x176))/0x5+-parseInt(_0x30141c(0x17f))/0x6*(-parseInt(_0x30141c(0x16b))/0x7)+-parseInt(_0x30141c(0x177))/0x8*(-parseInt(_0x30141c(0x183))/0x9)+-parseInt(_0x30141c(0x185))/0xa;if(_0x4c4fe8===_0x6ffb1b)break;else _0x463e31['push'](_0x463e31['shift']());}catch(_0x5b32af){_0x463e31['push'](_0x463e31['shift']());}}}(a205_0x4a5e,0x963f2));import{getCustomPageSource,updateCustomPageContent}from'../../../core/api-client.js';import{readCustomPageDirectory}from'../../../core/page/file-system.js';function a205_0x4572(_0xde8778,_0x2596a5){_0xde8778=_0xde8778-0x161;const _0x4a5e3c=a205_0x4a5e();let _0x4572b5=_0x4a5e3c[_0xde8778];return _0x4572b5;}import{CliErrors}from'../../../errors.js';import{buildCustomPageEditUrl,resolveCustomPageDevelopmentUrl,readCustomPageId,CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL,validateCustomPageContent}from'./shared.js';function a205_0x4a5e(){const _0xe4e2ee=['388827GhbpGV','page','12268210YqFWUa','4476976mgmvRA','Custom\x20Page\x20ID','page.custom-update','pageId','/smartapi/webcode/page/update/content','POST','Would\x20save\x20all\x20files\x20of\x20Custom\x20Page\x20','3082977RAVJvq','cookie','trim','number','7SZTJbu','Updated\x20Custom\x20Page\x20','page\x20custom-update\x20no\x20longer\x20accepts\x20--page-content.','2699CkTzNv','write','str','page-content','compress','Cannot\x20determine\x20the\x20appCode\x20for\x20Custom\x20Page\x20','appCode','validation','5905190ROKgqr','48oiibes','Save\x20all\x20files\x20of\x20a\x20Custom\x20Page','Write\x20the\x20complete\x20page\x20files\x20to\x20a\x20local\x20directory\x20and\x20use\x20--page-dir\x20<dir>.','pageContent','custom-update','string','170tmAjcr','Custom\x20Page\x20was\x20updated,\x20but\x20a\x20link\x20to\x20its\x20latest\x20saved\x20content\x20could\x20not\x20be\x20generated.','1584870slDUjs','isInteger','newVersion','page-dir'];a205_0x4a5e=function(){return _0xe4e2ee;};return a205_0x4a5e();}export const pageCustomUpdate={'service':a205_0x12d85b(0x184),'command':a205_0x12d85b(0x17b),'description':a205_0x12d85b(0x178),'risk':a205_0x12d85b(0x16f),'defaultOutputFormat':a205_0x12d85b(0x172),'structuredErrors':!![],'requiresAppCode':![],'rejectedFlags':[{'name':a205_0x12d85b(0x171),'message':a205_0x12d85b(0x16d),'hint':a205_0x12d85b(0x179)}],'flags':[{'name':'id','type':a205_0x12d85b(0x16a),'required':!![],'description':a205_0x12d85b(0x161)},{'name':a205_0x12d85b(0x182),'type':a205_0x12d85b(0x17c),'required':!![],'description':'Directory\x20containing\x20all\x20complete\x20page\x20files'},CUSTOM_PAGE_APPCODE_FLAG_OPTIONAL],async 'validate'(_0x213edc){readCustomPageId(_0x213edc),await readValidatedPageContent(_0x213edc);},async 'dryRun'(_0x46361a){const _0x3aa401=a205_0x12d85b,_0x374552=await readInput(_0x46361a);return{'method':_0x3aa401(0x165),'url':_0x3aa401(0x164),'body':{'id':_0x374552['pageId'],'codeContent':_0x374552['pageContent']},'description':_0x3aa401(0x166)+_0x374552[_0x3aa401(0x163)]+'.'};},async 'execute'(_0x24e895){const _0x381e77=a205_0x12d85b,_0xf138ab=await readInput(_0x24e895),_0x46de65=await updateCustomPageContent({'pageId':_0xf138ab[_0x381e77(0x163)],'pageContent':_0xf138ab['pageContent']});if(!Number[_0x381e77(0x180)](_0x46de65['newVersion'])||_0x46de65[_0x381e77(0x181)]<=0x0)throw CliErrors['apiError']('Custom\x20Page\x20update\x20did\x20not\x20create\x20a\x20new\x20version.');const _0x3bb8f1=buildCustomPageEditUrl(_0xf138ab[_0x381e77(0x174)],_0xf138ab['pageId']),_0x4b7271=await resolveCustomPageDevelopmentUrl(_0xf138ab[_0x381e77(0x174)],_0xf138ab[_0x381e77(0x163)],_0x24e895[_0x381e77(0x168)]);return{'ok':!![],'data':{'operation':_0x381e77(0x162),'selector':{'appCode':_0xf138ab[_0x381e77(0x174)],'pageId':_0xf138ab[_0x381e77(0x163)]},'before':null,'after':{'pageId':_0x46de65[_0x381e77(0x163)],'version':_0x46de65[_0x381e77(0x181)],'pageContent':_0xf138ab[_0x381e77(0x17a)]},'dryRun':![],'request':_0xf138ab,..._0x4b7271?{'pageUrl':_0x4b7271}:{},..._0x3bb8f1?{'editPageUrl':_0x3bb8f1}:{},'warnings':_0x4b7271?[]:[_0x381e77(0x17e)]},'message':_0x381e77(0x16c)+_0xf138ab[_0x381e77(0x163)]+'.'};}};async function readInput(_0x19f4d9){const _0x399651=a205_0x12d85b,_0x115e26=readCustomPageId(_0x19f4d9),_0x57656f=_0x19f4d9['str']('appcode')[_0x399651(0x169)]()||(await getCustomPageSource(_0x115e26))['appCode']?.[_0x399651(0x169)]();if(!_0x57656f)throw CliErrors[_0x399651(0x175)](_0x399651(0x173)+_0x115e26+'.');return{'appCode':_0x57656f,'pageId':_0x115e26,'pageContent':await readValidatedPageContent(_0x19f4d9)};}async function readValidatedPageContent(_0x156e42){const _0x1e42a7=a205_0x12d85b,_0x508ff4=await readCustomPageDirectory(_0x156e42[_0x1e42a7(0x170)](_0x1e42a7(0x182)));return await validateCustomPageContent(_0x508ff4),_0x508ff4;}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const a206_0x358c57=a206_0x31f6;(function(_0xa479c,_0x2e17db){const _0x5ea798=a206_0x31f6,_0x5eb86b=_0xa479c();while(!![]){try{const _0x48bb0e=parseInt(_0x5ea798(0x91))/0x1*(parseInt(_0x5ea798(0x90))/0x2)+-parseInt(_0x5ea798(0x93))/0x3*(-parseInt(_0x5ea798(0xa2))/0x4)+-parseInt(_0x5ea798(0x94))/0x5*(-parseInt(_0x5ea798(0x97))/0x6)+-parseInt(_0x5ea798(0x9c))/0x7+parseInt(_0x5ea798(0xa1))/0x8*(-parseInt(_0x5ea798(0x9f))/0x9)+parseInt(_0x5ea798(0x8f))/0xa+-parseInt(_0x5ea798(0xa5))/0xb*(parseInt(_0x5ea798(0x8c))/0xc);if(_0x48bb0e===_0x2e17db)break;else _0x5eb86b['push'](_0x5eb86b['shift']());}catch(_0x672d19){_0x5eb86b['push'](_0x5eb86b['shift']());}}}(a206_0x487f,0xc78b4));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';function a206_0x487f(){const _0x26045e=['Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','status','4526767FHYCAc','code','read','1359NMxOCG','page','73432LANSJI','2087088ItYaDZ','query-data-list-status','compress','255497DvVZFA','/standard-page-status?appCode=','12WkdUSv','alias','manualResolutionRequired','9376960txChtX','456040JpHEbr','1AjVROi','length','9DKYXMQ','711185gzkHVY','data-list-status','Query\x20Data\x20List\x20Page\x20facts\x20for\x20a\x20dataset','6VabOUv','name','GET'];a206_0x487f=function(){return _0x26045e;};return a206_0x487f();}import{assessDataListPageState,getUndeletedRelatedPages,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector}from'../../commands/page/shared.js';function a206_0x31f6(_0x5d776e,_0x3dfed4){_0x5d776e=_0x5d776e-0x8c;const _0x487fa5=a206_0x487f();let _0x31f620=_0x487fa5[_0x5d776e];return _0x31f620;}export const pageDataListStatus={'service':a206_0x358c57(0xa0),'command':a206_0x358c57(0x95),'description':a206_0x358c57(0x96),'risk':a206_0x358c57(0x9e),'defaultOutputFormat':a206_0x358c57(0xa4),'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a206_0x358c57(0x8d),'type':'string','description':a206_0x358c57(0x9a)}],async 'validate'(_0x59057f){validateDatasetSelector(_0x59057f);},async 'dryRun'(_0x505641){const _0x414fb6=a206_0x358c57,_0x412f9c=await loadDatasetDetailForPage(_0x505641);return{'method':_0x414fb6(0x99),'url':'/smartapi/lovrabet/dataset/'+_0x412f9c['code']+_0x414fb6(0xa6)+encodeURIComponent(_0x505641['appCode']),'description':serializeDryRunDescription({'dataset':{'id':_0x412f9c['id'],'code':_0x412f9c[_0x414fb6(0x9d)],'name':_0x412f9c[_0x414fb6(0x98)]},'action':_0x414fb6(0xa3)})};},async 'execute'(_0x1aad59){const _0x4e62b8=a206_0x358c57,_0x57a8ab=await loadDatasetDetailForPage(_0x1aad59),_0x517546=await loadDataListPageStatusForGenerate(_0x1aad59,_0x57a8ab[_0x4e62b8(0x9d)]),_0x24f299=getUndeletedRelatedPages(_0x57a8ab),_0x3cbac0=assessDataListPageState(_0x57a8ab[_0x4e62b8(0x9d)],_0x517546,{'fallbackUndeletedPages':_0x24f299});return{'ok':!![],'data':{'datasetCode':_0x57a8ab['code'],'precheckSource':_0x517546?.['source']??'related-pages-fallback','status':_0x3cbac0[_0x4e62b8(0x9b)],'manualResolutionRequired':_0x3cbac0[_0x4e62b8(0x8e)],'nextAction':_0x3cbac0['nextAction'],'dataListPageStatus':_0x517546,'relatedPages':{'total':_0x57a8ab['relatedPages'][_0x4e62b8(0x92)],'undeletedCount':_0x24f299[_0x4e62b8(0x92)]}}};}};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a207_0x4ae471=a207_0x2d4f;(function(_0xeadfeb,_0x4007ed){const _0x56553f=a207_0x2d4f,_0x1147c0=_0xeadfeb();while(!![]){try{const _0x33a648=-parseInt(_0x56553f(0xed))/0x1+-parseInt(_0x56553f(0xca))/0x2*(parseInt(_0x56553f(0xc8))/0x3)+parseInt(_0x56553f(0xe5))/0x4*(parseInt(_0x56553f(0xbe))/0x5)+parseInt(_0x56553f(0xe1))/0x6*(parseInt(_0x56553f(0xdc))/0x7)+parseInt(_0x56553f(0xcb))/0x8+parseInt(_0x56553f(0xc6))/0x9+parseInt(_0x56553f(0xee))/0xa*(parseInt(_0x56553f(0xbf))/0xb);if(_0x33a648===_0x4007ed)break;else _0x1147c0['push'](_0x1147c0['shift']());}catch(_0x189d39){_0x1147c0['push'](_0x1147c0['shift']());}}}(a207_0x13f6,0x5d4d2));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';function a207_0x2d4f(_0x2831f2,_0x10930e){_0x2831f2=_0x2831f2-0xb9;const _0x13f653=a207_0x13f6();let _0x2d4f73=_0x13f653[_0x2831f2];return _0x2d4f73;}function a207_0x13f6(){const _0x1e6f01=['alias','Submitted\x20a\x20generate\x20task','manualResolutionRequired','dryRun','apply','progressRate','734150iYlJoK','438220ttpuAs','Dry-run\x20preview\x20(pass\x20--apply\x20to\x20execute\x20the\x20generation)','generate-start','/generate-standard-pages/start','bool','precheck','535UhIMPx','55uNQhca','allowGenerate','CRUD_PAGE_SET','currentStep','code','page','page\x20generate-start\x20does\x20not\x20accept\x20--page-pattern.','5960448MkMJkW','PARTIAL_SUCCESS','33dQdnLf','page-pattern','98636XAWumP','676032AjNjqt','write','taskId','boolean','status','name','operationId','fieldCount','DATA_LIST\x20currently\x20has\x20one\x20fixed\x20pattern:\x20CRUD_PAGE_SET.','compress','Reusing\x20an\x20existing\x20generate\x20task','Start\x20async\x20Data\x20List\x20Page\x20generation\x20from\x20a\x20dataset','reused','DATA_LIST','number','page\x20generate-start\x20does\x20not\x20accept\x20--page-type.','appCode','7FbtUoS','SUCCESS','nextAction','clientOperationId','related-pages-fallback','515478GAtOtL','string','dataset','source','22692GQgVyL','dataListPageStatus'];a207_0x13f6=function(){return _0x1e6f01;};return a207_0x13f6();}import{startGenerateDataListPages}from'../../core/api-client.js';export const pageGenerateStart={'service':a207_0x4ae471(0xc4),'command':a207_0x4ae471(0xba),'description':a207_0x4ae471(0xd6),'risk':a207_0x4ae471(0xcc),'defaultOutputFormat':a207_0x4ae471(0xd4),'rejectedFlags':[{'name':'page-type','message':a207_0x4ae471(0xda),'hint':'This\x20command\x20always\x20generates\x20a\x20DATA_LIST\x20page\x20from\x20a\x20dataset.'},{'name':a207_0x4ae471(0xc9),'message':a207_0x4ae471(0xc5),'hint':a207_0x4ae471(0xd3)}],'flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a207_0x4ae471(0xe7),'type':a207_0x4ae471(0xe2),'description':'Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)'},{'name':a207_0x4ae471(0xeb),'type':a207_0x4ae471(0xce),'description':'Actually\x20execute\x20the\x20generation.\x20Without\x20this\x20flag,\x20only\x20a\x20dry-run\x20preview\x20is\x20shown.'}],async 'validate'(_0x40a2e7){validateDatasetSelector(_0x40a2e7);},async 'dryRun'(_0x3eb02c){const _0x2b0d39=a207_0x4ae471,_0x1b2dc2=await prepare(_0x3eb02c);return{'method':'POST','url':'/smartapi/lovrabet/dataset/'+_0x1b2dc2[_0x2b0d39(0xe3)][_0x2b0d39(0xc3)]+_0x2b0d39(0xbb),'body':{'appCode':_0x3eb02c[_0x2b0d39(0xdb)],'clientOperationId':_0x1b2dc2[_0x2b0d39(0xdf)]},'description':serializeDryRunDescription({'dataset':{'id':_0x1b2dc2[_0x2b0d39(0xe3)]['id'],'code':_0x1b2dc2[_0x2b0d39(0xe3)][_0x2b0d39(0xc3)],'name':_0x1b2dc2[_0x2b0d39(0xe3)][_0x2b0d39(0xd0)],'fieldCount':_0x1b2dc2[_0x2b0d39(0xe3)][_0x2b0d39(0xd2)]},'precheckSource':_0x1b2dc2[_0x2b0d39(0xe6)]?.[_0x2b0d39(0xe4)]??_0x2b0d39(0xe0),'action':_0x2b0d39(0xba),'clientOperationId':_0x1b2dc2['clientOperationId'],'plannedStatus':_0x1b2dc2[_0x2b0d39(0xbd)][_0x2b0d39(0xcf)],'reason':_0x1b2dc2['precheck']['message']})};},async 'execute'(_0x2f0bf9){const _0x1124e3=a207_0x4ae471;if(!_0x2f0bf9[_0x1124e3(0xbc)]('apply')){const _0x4f2a23=await pageGenerateStart[_0x1124e3(0xea)](_0x2f0bf9);return{'ok':!![],'message':_0x1124e3(0xb9),'data':_0x4f2a23};}const _0x2fb0c2=await prepare(_0x2f0bf9);if(!_0x2fb0c2[_0x1124e3(0xbd)][_0x1124e3(0xc0)])return{'ok':![],'message':_0x2fb0c2[_0x1124e3(0xbd)]['message'],'data':{'datasetCode':_0x2fb0c2[_0x1124e3(0xe3)][_0x1124e3(0xc3)],'pageType':_0x1124e3(0xd8),'pagePattern':_0x1124e3(0xc1),'clientOperationId':_0x2fb0c2[_0x1124e3(0xdf)],'precheckSource':_0x2fb0c2[_0x1124e3(0xe6)]?.[_0x1124e3(0xe4)]??_0x1124e3(0xe0),'status':_0x2fb0c2[_0x1124e3(0xbd)]['status'],'manualResolutionRequired':_0x2fb0c2['precheck'][_0x1124e3(0xe9)],'nextAction':_0x2fb0c2['precheck'][_0x1124e3(0xde)],'query':{'command':buildDataListPageStatusQueryCommand(_0x2fb0c2[_0x1124e3(0xe3)][_0x1124e3(0xc3)],_0x2f0bf9[_0x1124e3(0xdb)])},'dataListPageStatus':_0x2fb0c2[_0x1124e3(0xe6)]}};const _0x35efaf=await startGenerateDataListPages(_0x2f0bf9[_0x1124e3(0xdb)],_0x2fb0c2[_0x1124e3(0xe3)]['code'],{'clientOperationId':_0x2fb0c2[_0x1124e3(0xdf)]}),_0x41a749=_0x35efaf['status']===_0x1124e3(0xdd)||_0x35efaf[_0x1124e3(0xcf)]===_0x1124e3(0xc7)?await loadDataListPageStatusForGenerate(_0x2f0bf9,_0x2fb0c2['dataset']['code']):null,_0x40332b=assessGenerateOperationState(_0x2fb0c2[_0x1124e3(0xe3)][_0x1124e3(0xc3)],_0x35efaf[_0x1124e3(0xcf)],_0x41a749);return{'ok':!![],'message':_0x35efaf['reused']?_0x1124e3(0xd5):_0x1124e3(0xe8),'data':{'datasetCode':_0x2fb0c2['dataset'][_0x1124e3(0xc3)],'appCode':_0x2f0bf9[_0x1124e3(0xdb)],'pageType':'DATA_LIST','pagePattern':_0x1124e3(0xc1),'taskId':_0x35efaf[_0x1124e3(0xcd)]??null,'operationId':_0x35efaf[_0x1124e3(0xd1)]??null,'clientOperationId':_0x2fb0c2['clientOperationId'],'jobStatus':_0x35efaf[_0x1124e3(0xcf)]??null,'progressRate':typeof _0x35efaf['progressRate']===_0x1124e3(0xd9)?_0x35efaf[_0x1124e3(0xec)]:null,'currentStep':_0x35efaf[_0x1124e3(0xc2)]??null,'reused':_0x35efaf[_0x1124e3(0xd7)]===!![],'status':_0x40332b[_0x1124e3(0xcf)],'manualResolutionRequired':_0x40332b[_0x1124e3(0xe9)],'nextAction':_0x40332b[_0x1124e3(0xde)],'query':{'command':buildPageGenerateOperationStatusQueryCommand(_0x2fb0c2[_0x1124e3(0xe3)][_0x1124e3(0xc3)],{'appCode':_0x2f0bf9[_0x1124e3(0xdb)],'taskId':_0x35efaf[_0x1124e3(0xcd)],'operationId':_0x35efaf[_0x1124e3(0xd1)],'clientOperationId':_0x2fb0c2[_0x1124e3(0xdf)]})},'dataListPageStatus':_0x41a749}};}};async function prepare(_0x172b33){const _0x219797=a207_0x4ae471,_0x18dae9=await loadDatasetDetailForPage(_0x172b33),_0x55ef65=await loadDataListPageStatusForGenerate(_0x172b33,_0x18dae9['code']),_0x5f46aa=getUndeletedRelatedPages(_0x18dae9);return{'dataset':_0x18dae9,'dataListPageStatus':_0x55ef65,'clientOperationId':createPageGenerateClientOperationId(),'precheck':assessDataListPageState(_0x18dae9[_0x219797(0xc3)],_0x55ef65,{'fallbackUndeletedPages':_0x5f46aa})};}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const a208_0x1cbdb9=a208_0xa069;function a208_0x4b61(){const _0x4aa195=['alias','result','675965tGAGTb','7622904mGcULN','746yWeBon','14BOOsEj','code','name','read','currentStep','query-generate-operation-status','string','2637128lxwzcv','progressRate','page','status','Dataset\x20alias\x20from\x20api.ts\x20(resolves\x20to\x20dataset\x20code\x20automatically)','operation_failed','Generic\x20task\x20id\x20returned\x20by\x20page\x20generate-start','appCode','clientOperationId','errorMsg','PARTIAL_SUCCESS','number','Async\x20operation\x20id\x20returned\x20by\x20page\x20generate-start','GET','str','4vviIdl','/generate-standard-pages/status?','nextAction','9893538jysgAG','8166Leivoj','generate-status','Query\x20Data\x20List\x20Page\x20generate\x20operation\x20status','client-operation-id','set','manualResolutionRequired','task-id','taskId','986vEixIE','SUCCESS','toString','operation-id','message','/smartapi/lovrabet/dataset/','13063680yGTmuC'];a208_0x4b61=function(){return _0x4aa195;};return a208_0x4b61();}function a208_0xa069(_0x5ccb6c,_0x5b7aed){_0x5ccb6c=_0x5ccb6c-0x142;const _0x4b61be=a208_0x4b61();let _0xa06968=_0x4b61be[_0x5ccb6c];return _0xa06968;}(function(_0x5bfd44,_0x220477){const _0x527557=a208_0xa069,_0x264ae7=_0x5bfd44();while(!![]){try{const _0x3669d7=-parseInt(_0x527557(0x14a))/0x1*(-parseInt(_0x527557(0x155))/0x2)+-parseInt(_0x527557(0x142))/0x3*(-parseInt(_0x527557(0x16c))/0x4)+-parseInt(_0x527557(0x153))/0x5+parseInt(_0x527557(0x154))/0x6+-parseInt(_0x527557(0x156))/0x7*(parseInt(_0x527557(0x15d))/0x8)+parseInt(_0x527557(0x16f))/0x9+-parseInt(_0x527557(0x150))/0xa;if(_0x3669d7===_0x220477)break;else _0x264ae7['push'](_0x264ae7['shift']());}catch(_0x3819f9){_0x264ae7['push'](_0x264ae7['shift']());}}}(a208_0x4b61,0x9c1bf));import{APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL}from'../../commands/common/flags.js';import{assessGenerateOperationState,buildPageGenerateOperationStatusQueryCommand,loadDatasetDetailForPage,loadDataListPageStatusForGenerate,serializeDryRunDescription,validateDatasetSelector,validateGenerateOperationSelector}from'../../commands/page/shared.js';import{getGenerateDataListPagesStatus}from'../../core/api-client.js';export const pageGenerateStatus={'service':a208_0x1cbdb9(0x15f),'command':a208_0x1cbdb9(0x143),'description':a208_0x1cbdb9(0x144),'risk':a208_0x1cbdb9(0x159),'defaultOutputFormat':'compress','flags':[APPCODE_FLAG_OPTIONAL,DATASETCODE_FLAG_OPTIONAL,{'name':a208_0x1cbdb9(0x151),'type':'string','description':a208_0x1cbdb9(0x161)},{'name':'task-id','type':'string','description':a208_0x1cbdb9(0x163)},{'name':'operation-id','type':a208_0x1cbdb9(0x15c),'description':a208_0x1cbdb9(0x169)},{'name':'client-operation-id','type':a208_0x1cbdb9(0x15c),'description':'Client\x20recovery/idempotency\x20id\x20when\x20operationId\x20is\x20unavailable\x20or\x20lost'}],async 'validate'(_0x37fda3){validateDatasetSelector(_0x37fda3),validateGenerateOperationSelector(_0x37fda3);},async 'dryRun'(_0x52e685){const _0x206158=a208_0x1cbdb9,_0x40bfe4=await loadDatasetDetailForPage(_0x52e685),_0x17addd=_0x52e685[_0x206158(0x16b)](_0x206158(0x148)),_0x39f792=_0x52e685['str'](_0x206158(0x14d)),_0x2ca901=_0x52e685[_0x206158(0x16b)](_0x206158(0x145)),_0x157ecc=new URLSearchParams({'appCode':_0x52e685['appCode']});return _0x17addd&&_0x157ecc[_0x206158(0x146)](_0x206158(0x149),_0x17addd),_0x39f792&&_0x157ecc[_0x206158(0x146)]('operationId',_0x39f792),_0x2ca901&&_0x157ecc[_0x206158(0x146)](_0x206158(0x165),_0x2ca901),{'method':_0x206158(0x16a),'url':_0x206158(0x14f)+_0x40bfe4[_0x206158(0x157)]+_0x206158(0x16d)+_0x157ecc[_0x206158(0x14c)](),'description':serializeDryRunDescription({'dataset':{'id':_0x40bfe4['id'],'code':_0x40bfe4[_0x206158(0x157)],'name':_0x40bfe4[_0x206158(0x158)]},'action':_0x206158(0x15b),'taskId':_0x17addd||undefined,'operationId':_0x39f792||undefined,'clientOperationId':_0x2ca901||undefined})};},async 'execute'(_0x471316){const _0x23ad04=a208_0x1cbdb9,_0x13534f=await loadDatasetDetailForPage(_0x471316),_0x54cb81=_0x471316[_0x23ad04(0x16b)](_0x23ad04(0x148)),_0x288de6=_0x471316[_0x23ad04(0x16b)](_0x23ad04(0x14d)),_0x2c24d2=_0x471316[_0x23ad04(0x16b)]('client-operation-id'),_0x2fa686=await getGenerateDataListPagesStatus(_0x471316[_0x23ad04(0x164)],_0x13534f[_0x23ad04(0x157)],{'taskId':_0x54cb81||undefined,'operationId':_0x288de6||undefined,'clientOperationId':_0x2c24d2||undefined}),_0x3e0f50=_0x2fa686[_0x23ad04(0x160)]===_0x23ad04(0x14b)||_0x2fa686['status']===_0x23ad04(0x167),_0x473750=_0x3e0f50?await loadDataListPageStatusForGenerate(_0x471316,_0x13534f[_0x23ad04(0x157)]):null,_0x3aa192=assessGenerateOperationState(_0x13534f[_0x23ad04(0x157)],_0x2fa686[_0x23ad04(0x160)],_0x473750),_0x1afdef=_0x2fa686['taskId']??_0x54cb81??undefined,_0x36622c=_0x2fa686['operationId']??_0x288de6??undefined,_0x176d5f=_0x2fa686['clientOperationId']??_0x2c24d2??undefined;return{'ok':!![],'message':_0x3aa192[_0x23ad04(0x160)]===_0x23ad04(0x162)?_0x2fa686[_0x23ad04(0x166)]||_0x3aa192['message']:_0x3aa192[_0x23ad04(0x14e)],'data':{'datasetCode':_0x13534f['code'],'appCode':_0x471316['appCode'],'taskId':_0x1afdef,'operationId':_0x36622c,'clientOperationId':_0x176d5f,'jobStatus':_0x2fa686[_0x23ad04(0x160)]??null,'progressRate':typeof _0x2fa686[_0x23ad04(0x15e)]===_0x23ad04(0x168)?_0x2fa686[_0x23ad04(0x15e)]:null,'currentStep':_0x2fa686[_0x23ad04(0x15a)]??null,'errorMsg':_0x2fa686['errorMsg']??null,'status':_0x3aa192[_0x23ad04(0x160)],'manualResolutionRequired':_0x3aa192[_0x23ad04(0x147)],'nextAction':_0x3aa192[_0x23ad04(0x16e)],'query':{'command':buildPageGenerateOperationStatusQueryCommand(_0x13534f[_0x23ad04(0x157)],{'appCode':_0x471316[_0x23ad04(0x164)],'taskId':_0x1afdef,'operationId':_0x36622c,'clientOperationId':_0x176d5f})},'dataListPageStatus':_0x473750,'result':_0x2fa686[_0x23ad04(0x152)]??null}};}};
|