@lovrabet/lovrabet-cli 2.0.8 → 2.0.9-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/lib/cli.js +1 -1
  2. package/lib/commands/app/cache.js +1 -1
  3. package/lib/commands/app/definitions.js +1 -1
  4. package/lib/commands/app/mock-loader.js +1 -1
  5. package/lib/commands/app/remote-source.js +1 -1
  6. package/lib/commands/app/shared.js +1 -1
  7. package/lib/commands/auth/index.js +1 -1
  8. package/lib/commands/auth/prompt.js +1 -1
  9. package/lib/commands/bff/detail.js +1 -1
  10. package/lib/commands/bff/exec.js +1 -1
  11. package/lib/commands/bff/index.js +1 -1
  12. package/lib/commands/common/config-policy.js +1 -1
  13. package/lib/commands/common/constraints.js +1 -1
  14. package/lib/commands/common/flags.js +1 -1
  15. package/lib/commands/config/definitions.js +1 -1
  16. package/lib/commands/config/shared.js +1 -1
  17. package/lib/commands/data/index.js +1 -1
  18. package/lib/commands/dataset/detail.js +1 -1
  19. package/lib/commands/dataset/index.js +1 -1
  20. package/lib/commands/dataset/list.js +1 -1
  21. package/lib/commands/doctor.js +1 -1
  22. package/lib/commands/init.js +1 -1
  23. package/lib/commands/kb/index.js +1 -0
  24. package/lib/commands/logs/index.js +1 -1
  25. package/lib/commands/registry.js +1 -1
  26. package/lib/commands/schema.js +1 -1
  27. package/lib/commands/skill/index.js +1 -1
  28. package/lib/commands/sql/detail.js +1 -1
  29. package/lib/commands/sql/exec.js +1 -1
  30. package/lib/commands/sql/index.js +1 -1
  31. package/lib/commands/update.js +1 -1
  32. package/lib/config/schema.js +1 -1
  33. package/lib/constant/auth-mode.js +1 -1
  34. package/lib/constant/cli.js +1 -1
  35. package/lib/constant/defaults.js +1 -1
  36. package/lib/constant/distribution.js +1 -1
  37. package/lib/constant/domain.js +1 -1
  38. package/lib/constant/env.js +1 -1
  39. package/lib/constant/output.js +1 -1
  40. package/lib/constant/product.js +1 -1
  41. package/lib/constant/risk.js +1 -1
  42. package/lib/constant/url.js +1 -1
  43. package/lib/context.js +1 -1
  44. package/lib/core/api-client.js +1 -1
  45. package/lib/core/db-resolver.js +1 -1
  46. package/lib/core/sdk-client.js +1 -1
  47. package/lib/errors.js +1 -1
  48. package/lib/framework/build-all-flags.js +1 -1
  49. package/lib/framework/dryrun.js +1 -1
  50. package/lib/framework/flags.js +1 -1
  51. package/lib/framework/help.js +1 -1
  52. package/lib/framework/index.js +1 -1
  53. package/lib/framework/output.js +1 -1
  54. package/lib/framework/preparse.js +1 -1
  55. package/lib/framework/response.js +1 -1
  56. package/lib/framework/runner-confirmation.js +1 -1
  57. package/lib/framework/runner-error.js +1 -1
  58. package/lib/framework/runner.js +1 -1
  59. package/lib/framework/schema-export.js +1 -1
  60. package/lib/framework/types.js +1 -1
  61. package/lib/help.js +1 -1
  62. package/lib/skills/npx-skills-add.js +1 -1
  63. package/lib/skills/runtime-skill-sync.js +1 -0
  64. package/lib/utils/apply-jq-filter.js +1 -1
  65. package/lib/utils/logger.js +1 -1
  66. package/lib/utils/params.js +1 -1
  67. package/lib/utils/platform.js +1 -1
  68. package/lib/utils/version.js +1 -1
  69. package/lib/utils/write-cli-side-channel.js +1 -1
  70. package/package.json +1 -1
@@ -1 +1 @@
1
- function a16_0x397a(_0x380659,_0x3932f8){_0x380659=_0x380659-0xde;const _0x40213a=a16_0x4021();let _0x397a86=_0x40213a[_0x380659];return _0x397a86;}const a16_0x360d1c=a16_0x397a;(function(_0x353a1c,_0x5b649d){const _0x1d191a=a16_0x397a,_0x52d4ba=_0x353a1c();while(!![]){try{const _0x4a64f7=parseInt(_0x1d191a(0xf9))/0x1*(-parseInt(_0x1d191a(0x10f))/0x2)+parseInt(_0x1d191a(0xff))/0x3*(-parseInt(_0x1d191a(0xe1))/0x4)+-parseInt(_0x1d191a(0x130))/0x5*(-parseInt(_0x1d191a(0x10a))/0x6)+parseInt(_0x1d191a(0xfd))/0x7+parseInt(_0x1d191a(0x108))/0x8+parseInt(_0x1d191a(0x11f))/0x9*(parseInt(_0x1d191a(0xf6))/0xa)+-parseInt(_0x1d191a(0xe4))/0xb*(-parseInt(_0x1d191a(0xe7))/0xc);if(_0x4a64f7===_0x5b649d)break;else _0x52d4ba['push'](_0x52d4ba['shift']());}catch(_0x2f42c0){_0x52d4ba['push'](_0x52d4ba['shift']());}}}(a16_0x4021,0x19c06));import{executeData}from'../../core/sdk-client.js';import{CODE_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';import{requireAnyOf}from'../../commands/common/constraints.js';import{parseJsonParams,parseJsonParamsValue,parseBatchCreateItemsFromParams}from'../../utils/params.js';function a16_0x4021(){const _0x243703=['body','map','JSON\x20with\x20id\x20+\x20fields\x20to\x20update.\x20Example:\x20\x27{\x22id\x22:123,\x22status\x22:\x22completed\x22}\x27','Get\x20a\x20single\x20record\x20by\x20ID','dryRun','370JUSEyc','\x20\x20\x20\x20Pagination\x20is\x20controlled\x20via\x20JSON\x20in\x20--params.\x20Do\x20NOT\x20use\x20--page-size\x20as\x20a\x20CLI\x20flag.','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22total\x22:\x22desc\x22}]','2067gOkltq','delete','getOne','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)','96397hNKZgt','Delete\x20a\x20record\x20(requires\x20--yes\x20in\x20non-interactive)','1479dHQSrO','description','JSON\x20array\x20of\x20record\x20objects,\x20or\x20{\x22items\x22:[...]}.\x20Example:\x20\x27[{\x22name\x22:\x22a\x22},{\x22name\x22:\x22b\x22}]\x27','high-risk-write','filter','\x20\x20LOGICAL\x20COMBINATORS','\x20\x20PARAMS\x20STRUCTURE','paramsRequired','build','407600qAtZVg','\x20on\x20dataset\x20','2364euPXBf','command','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Pre-aggregation\x20filter\x20(same\x20operators\x20as\x20data\x20filter)','str','batchCreate','110imgnmm','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return\x20alongside\x20aggregates,\x20e.g.\x20[\x22status\x22,\x22region\x22]','Update\x20an\x20existing\x20record','read','\x20\x20\x20\x20SUM\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Sum\x20of\x20field\x20values\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}','update','data','\x20\x20WHERE\x20OPERATORS','\x20\x20\x20\x20MIN\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Minimum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22price\x22,\x22type\x22:\x22MIN\x22,\x22alias\x22:\x22min_price\x22}','\x20\x20\x20\x20aggregate\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Aggregation\x20definitions\x20(see\x20AGGREGATE\x20TYPES\x20above)','\x20\x20\x20\x20#\x20Count\x20orders\x20per\x20region\x20with\x20filter','Aggregate\x20dataset\x20records\x20(group\x20by,\x20sum,\x20count,\x20avg,\x20etc.)','\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page\x20(default:\x2020)','\x20completed\x20in\x20','\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22field\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27','\x20\x20\x20\x20Correct:\x20\x20--params\x20\x27{\x22currentPage\x22:1,\x22pageSize\x22:10}\x27','3339GPJfOF','\x20\x20\x20\x20$gte\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20or\x20equal\x20\x20{\x22amount\x22:{\x22$gte\x22:100}}','risk','paramsHint','write','\x20\x20\x20\x20$contain\x20\x20\x20\x20\x20Substring\x20match\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$contain\x22:\x22test\x22}}','\x20\x20\x20\x20$lte\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20or\x20equal\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lte\x22:1000}}','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20','\x20\x20\x20\x20$eq\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22age\x22:{\x22$eq\x22:18}}','params','join','data\x20','\x20\x20\x20\x20$gt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$gt\x22:100}}','create','\x20\x20\x20\x20having\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Post-aggregation\x20filter,\x20e.g.\x20{\x22total\x22:{\x22$gt\x22:1000}}','Create\x20a\x20new\x20record\x20in\x20a\x20dataset','JSON\x20with\x20field\x20values.\x20Example:\x20\x27{\x22name\x22:\x22test\x22,\x22amount\x22:100}\x27','2050OutDbH','now','\x20\x20\x20\x20$and\x20\x20\x20\x20\x20\x20\x20\x20\x20All\x20conditions\x20match\x20\x20\x20{\x22$and\x22:[{\x22age\x22:{\x22$gte\x22:18}},{\x22status\x22:{\x22$eq\x22:\x22active\x22}}]}','\x20\x20EXAMPLES','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions\x20(see\x20operators\x20above)','444PYgtvn','POST','\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20of\x20records\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}','186439Bsfjav','aggregate','\x20\x20\x20\x20MAX\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Maximum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22price\x22,\x22type\x22:\x22MAX\x22,\x22alias\x22:\x22max_price\x22}','24EaUOFF','Example:\x20\x27{\x22aggregate\x22:[{\x22field\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27','\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22field\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}],\x22groupBy\x22:[\x22region\x22],\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}}}\x27','operation','JSON\x20body\x20for\x20aggregate\x20API.\x20Fields:\x20select,\x20aggregate,\x20where,\x20groupBy,\x20having,\x20orderBy.\x20','code','\x20\x20\x20\x20groupBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Grouping\x20fields,\x20e.g.\x20[\x22status\x22,\x22region\x22]','Preview:\x20data\x20','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]'];a16_0x4021=function(){return _0x243703;};return a16_0x4021();}import{dryRun}from'../../framework/dryrun.js';const specs=[{'command':a16_0x360d1c(0x103),'operation':a16_0x360d1c(0x103),'risk':a16_0x360d1c(0x112),'paramsRequired':![],'description':'Filter\x20dataset\x20records\x20with\x20query\x20conditions','paramsHint':a16_0x360d1c(0x126)+'Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','helpExtra':[a16_0x360d1c(0x116),a16_0x360d1c(0x127),'\x20\x20\x20\x20$ne\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Not\x20equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22status\x22:{\x22$ne\x22:\x22deleted\x22}}',a16_0x360d1c(0x12b),a16_0x360d1c(0x120),'\x20\x20\x20\x20$lt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lt\x22:1000}}',a16_0x360d1c(0x125),'\x20\x20\x20\x20$in\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Value\x20in\x20set\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22country\x22:{\x22$in\x22:[\x22CN\x22,\x22US\x22]}}',a16_0x360d1c(0x124),'\x20\x20\x20\x20$startWith\x20\x20\x20Starts\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$startWith\x22:\x22Mr.\x22}}','\x20\x20\x20\x20$endWith\x20\x20\x20\x20\x20Ends\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22email\x22:{\x22$endWith\x22:\x22@example.com\x22}}','',a16_0x360d1c(0x104),a16_0x360d1c(0xde),'\x20\x20\x20\x20$or\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Any\x20condition\x20matches\x20\x20{\x22$or\x22:[{\x22status\x22:{\x22$eq\x22:\x22active\x22}},{\x22status\x22:{\x22$eq\x22:\x22pending\x22}}]}','',a16_0x360d1c(0xfc),a16_0x360d1c(0xe0),'\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]',a16_0x360d1c(0xf0),'\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)',a16_0x360d1c(0x11b),'','\x20\x20PAGINATION',a16_0x360d1c(0xf7),a16_0x360d1c(0x11e),'\x20\x20\x20\x20Wrong:\x20\x20\x20\x20--page-size\x2010\x20\x20(this\x20is\x20not\x20a\x20valid\x20flag)']['join']('\x0a')},{'command':a16_0x360d1c(0xfb),'operation':'getOne','risk':a16_0x360d1c(0x112),'paramsRequired':!![],'description':a16_0x360d1c(0xf4),'paramsHint':a16_0x360d1c(0xef)},{'command':a16_0x360d1c(0x12c),'operation':a16_0x360d1c(0x12c),'risk':a16_0x360d1c(0x123),'paramsRequired':!![],'description':a16_0x360d1c(0x12e),'paramsHint':a16_0x360d1c(0x12f)},{'command':a16_0x360d1c(0x10e),'operation':a16_0x360d1c(0x10e),'risk':a16_0x360d1c(0x123),'paramsRequired':!![],'description':'Create\x20multiple\x20records\x20in\x20one\x20request\x20(SDK\x20batchCreate)','paramsHint':a16_0x360d1c(0x101)},{'command':a16_0x360d1c(0x114),'operation':a16_0x360d1c(0x114),'risk':a16_0x360d1c(0x123),'paramsRequired':!![],'description':a16_0x360d1c(0x111),'paramsHint':a16_0x360d1c(0xf3)},{'command':a16_0x360d1c(0xfa),'operation':a16_0x360d1c(0xfa),'risk':a16_0x360d1c(0x102),'paramsRequired':!![],'description':a16_0x360d1c(0xfe),'paramsHint':a16_0x360d1c(0xef)},{'command':a16_0x360d1c(0xe5),'operation':a16_0x360d1c(0xe5),'risk':a16_0x360d1c(0x112),'paramsRequired':![],'description':a16_0x360d1c(0x11a),'paramsHint':a16_0x360d1c(0xeb)+a16_0x360d1c(0xe8),'helpExtra':['\x20\x20AGGREGATE\x20TYPES',a16_0x360d1c(0x113),a16_0x360d1c(0xe3),'\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20distinct\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22,\x22distinct\x22:true}','\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Average\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg_score\x22}','\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Rounded\x20average\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg\x22,\x22round\x22:true,\x22precision\x22:2}',a16_0x360d1c(0xe6),a16_0x360d1c(0x117),'',a16_0x360d1c(0x105),a16_0x360d1c(0x110),a16_0x360d1c(0x118),a16_0x360d1c(0x10c),a16_0x360d1c(0xed),a16_0x360d1c(0x12d),a16_0x360d1c(0xf8),'',a16_0x360d1c(0xdf),'\x20\x20\x20\x20#\x20Sum\x20amount\x20grouped\x20by\x20status',a16_0x360d1c(0x11d),'',a16_0x360d1c(0x119),a16_0x360d1c(0xe9)][a16_0x360d1c(0x129)]('\x0a')}];function makeDataCommand(_0x2eaf6d){const _0x312f2c=a16_0x360d1c,_0x4e5788='data\x20'+_0x2eaf6d[_0x312f2c(0x10b)],_0x4a2431={'service':_0x312f2c(0x115),'command':_0x2eaf6d[_0x312f2c(0x10b)],'description':_0x2eaf6d[_0x312f2c(0x100)],'risk':_0x2eaf6d[_0x312f2c(0x121)],'helpExtra':_0x2eaf6d['helpExtra'],'flags':[CODE_FLAG,{...PARAMS_FLAG,'description':_0x2eaf6d[_0x312f2c(0x122)]}],'validate':async _0x1e0f97=>{const _0x316244=_0x312f2c;_0x2eaf6d[_0x316244(0x106)]&&requireAnyOf(_0x1e0f97,[_0x316244(0x128)],_0x4e5788),_0x2eaf6d[_0x316244(0xea)]==='batchCreate'&&parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x1e0f97['str'](_0x316244(0x128))));},async 'execute'(_0x139bae){const _0x34191f=_0x312f2c,_0x3cb7b0=_0x139bae[_0x34191f(0x10d)](_0x34191f(0xec)),_0x1a8763=_0x2eaf6d['operation']==='batchCreate'?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x139bae[_0x34191f(0x10d)](_0x34191f(0x128)))):parseJsonParams(_0x139bae[_0x34191f(0x10d)](_0x34191f(0x128)))??{},_0x53f32d=Date[_0x34191f(0x131)](),_0x3d0d98=await executeData(_0x3cb7b0,_0x2eaf6d['operation'],_0x1a8763),_0x5bc3d1=Date['now']()-_0x53f32d;return{'ok':!![],'data':{'result':_0x3d0d98,'elapsed':_0x5bc3d1},'message':_0x34191f(0x12a)+_0x2eaf6d['command']+_0x34191f(0x11c)+_0x5bc3d1+'ms'};}};return _0x2eaf6d[_0x312f2c(0x121)]!==_0x312f2c(0x112)&&(_0x4a2431[_0x312f2c(0xf5)]=async _0x2d2c51=>{const _0x71eee2=_0x312f2c,_0x3bf5e5=_0x2d2c51[_0x71eee2(0x10d)](_0x71eee2(0xec)),_0x114c0f=_0x2eaf6d[_0x71eee2(0xea)]==='batchCreate'?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x2d2c51[_0x71eee2(0x10d)](_0x71eee2(0x128)))):parseJsonParams(_0x2d2c51[_0x71eee2(0x10d)](_0x71eee2(0x128)))??{};return dryRun(_0x71eee2(0xe2),'/api/{appCode}/'+_0x3bf5e5+'/'+_0x2eaf6d[_0x71eee2(0xea)])[_0x71eee2(0xf1)](_0x114c0f)[_0x71eee2(0x100)](_0x71eee2(0xee)+_0x2eaf6d[_0x71eee2(0x10b)]+_0x71eee2(0x109)+_0x3bf5e5)[_0x71eee2(0x107)]();}),_0x4a2431;}export const dataDefinitions=specs[a16_0x360d1c(0xf2)](makeDataCommand);
1
+ function a16_0x76e5(_0x18cd02,_0x24f529){_0x18cd02=_0x18cd02-0x1f0;const _0x3374c6=a16_0x3374();let _0x76e536=_0x3374c6[_0x18cd02];return _0x76e536;}const a16_0x1897b8=a16_0x76e5;(function(_0x320290,_0xd5b5e5){const _0x59d0e6=a16_0x76e5,_0x4d0c0a=_0x320290();while(!![]){try{const _0x319ea7=parseInt(_0x59d0e6(0x210))/0x1*(-parseInt(_0x59d0e6(0x219))/0x2)+parseInt(_0x59d0e6(0x211))/0x3+-parseInt(_0x59d0e6(0x236))/0x4+parseInt(_0x59d0e6(0x21c))/0x5+-parseInt(_0x59d0e6(0x209))/0x6*(-parseInt(_0x59d0e6(0x1fe))/0x7)+-parseInt(_0x59d0e6(0x1fd))/0x8*(parseInt(_0x59d0e6(0x21e))/0x9)+parseInt(_0x59d0e6(0x241))/0xa;if(_0x319ea7===_0xd5b5e5)break;else _0x4d0c0a['push'](_0x4d0c0a['shift']());}catch(_0x1ee488){_0x4d0c0a['push'](_0x4d0c0a['shift']());}}}(a16_0x3374,0x383f3));import{executeData}from'../../core/sdk-client.js';import{CODE_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';import{requireAnyOf}from'../../commands/common/constraints.js';import{parseJsonParams,parseJsonParamsValue,parseBatchCreateItemsFromParams}from'../../utils/params.js';import{dryRun}from'../../framework/dryrun.js';const specs=[{'command':a16_0x1897b8(0x22e),'operation':a16_0x1897b8(0x22e),'risk':a16_0x1897b8(0x204),'paramsRequired':![],'description':a16_0x1897b8(0x221),'paramsHint':a16_0x1897b8(0x246)+a16_0x1897b8(0x207),'helpExtra':['\x20\x20WHERE\x20OPERATORS',a16_0x1897b8(0x1f4),'\x20\x20\x20\x20$ne\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Not\x20equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22status\x22:{\x22$ne\x22:\x22deleted\x22}}','\x20\x20\x20\x20$gt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$gt\x22:100}}',a16_0x1897b8(0x231),a16_0x1897b8(0x234),a16_0x1897b8(0x1fa),'\x20\x20\x20\x20$in\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Value\x20in\x20set\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22country\x22:{\x22$in\x22:[\x22CN\x22,\x22US\x22]}}',a16_0x1897b8(0x1f5),a16_0x1897b8(0x20a),'\x20\x20\x20\x20$endWith\x20\x20\x20\x20\x20Ends\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22email\x22:{\x22$endWith\x22:\x22@example.com\x22}}','',a16_0x1897b8(0x217),a16_0x1897b8(0x227),a16_0x1897b8(0x215),'','\x20\x20JSON\x20BODY\x20FIELDS\x20(pass\x20inside\x20--params)',a16_0x1897b8(0x232),a16_0x1897b8(0x1f7),a16_0x1897b8(0x226),a16_0x1897b8(0x21a),'\x20\x20\x20\x20pageSize\x20\x20\x20\x20\x20\x20Number\x20\x20\x20Records\x20per\x20page\x20(default:\x2020)','',a16_0x1897b8(0x202),a16_0x1897b8(0x1f3),a16_0x1897b8(0x223),a16_0x1897b8(0x21f)][a16_0x1897b8(0x218)]('\x0a')},{'command':a16_0x1897b8(0x22f),'operation':a16_0x1897b8(0x22f),'risk':a16_0x1897b8(0x204),'paramsRequired':!![],'description':a16_0x1897b8(0x20b),'paramsHint':a16_0x1897b8(0x23c)},{'command':'create','operation':a16_0x1897b8(0x22c),'risk':a16_0x1897b8(0x20e),'paramsRequired':!![],'description':a16_0x1897b8(0x203),'paramsHint':a16_0x1897b8(0x237)},{'command':'batchCreate','operation':a16_0x1897b8(0x205),'risk':a16_0x1897b8(0x20e),'paramsRequired':!![],'description':a16_0x1897b8(0x22a),'paramsHint':a16_0x1897b8(0x243)},{'command':a16_0x1897b8(0x229),'operation':a16_0x1897b8(0x229),'risk':a16_0x1897b8(0x20e),'paramsRequired':!![],'description':a16_0x1897b8(0x21d),'paramsHint':a16_0x1897b8(0x23e)},{'command':a16_0x1897b8(0x22d),'operation':a16_0x1897b8(0x22d),'risk':a16_0x1897b8(0x1fb),'paramsRequired':!![],'description':a16_0x1897b8(0x20d),'paramsHint':'JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27'},{'command':a16_0x1897b8(0x239),'operation':a16_0x1897b8(0x239),'risk':a16_0x1897b8(0x204),'paramsRequired':![],'description':a16_0x1897b8(0x1f6),'paramsHint':a16_0x1897b8(0x242)+a16_0x1897b8(0x216),'helpExtra':[a16_0x1897b8(0x1f8),'\x20\x20\x20\x20SUM\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Sum\x20of\x20field\x20values\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}',a16_0x1897b8(0x238),a16_0x1897b8(0x228),a16_0x1897b8(0x213),a16_0x1897b8(0x244),'\x20\x20\x20\x20MAX\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Maximum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22price\x22,\x22type\x22:\x22MAX\x22,\x22alias\x22:\x22max_price\x22}',a16_0x1897b8(0x1f2),'',a16_0x1897b8(0x233),a16_0x1897b8(0x23d),'\x20\x20\x20\x20aggregate\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Aggregation\x20definitions\x20(see\x20AGGREGATE\x20TYPES\x20above)',a16_0x1897b8(0x208),'\x20\x20\x20\x20groupBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Grouping\x20fields,\x20e.g.\x20[\x22status\x22,\x22region\x22]','\x20\x20\x20\x20having\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Post-aggregation\x20filter,\x20e.g.\x20{\x22total\x22:{\x22$gt\x22:1000}}',a16_0x1897b8(0x224),'',a16_0x1897b8(0x201),a16_0x1897b8(0x20f),a16_0x1897b8(0x206),'',a16_0x1897b8(0x222),'\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22field\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}],\x22groupBy\x22:[\x22region\x22],\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}}}\x27'][a16_0x1897b8(0x218)]('\x0a')}];function makeDataCommand(_0x24d61d){const _0x21c9fa=a16_0x1897b8,_0x3060e0='data\x20'+_0x24d61d[_0x21c9fa(0x23b)],_0x3fcbf5={'service':_0x21c9fa(0x212),'command':_0x24d61d['command'],'description':_0x24d61d[_0x21c9fa(0x20c)],'risk':_0x24d61d['risk'],'helpExtra':_0x24d61d[_0x21c9fa(0x22b)],'flags':[CODE_FLAG,{...PARAMS_FLAG,'description':_0x24d61d[_0x21c9fa(0x21b)]}],'validate':async _0x227cf6=>{const _0x3a318e=_0x21c9fa;_0x24d61d['paramsRequired']&&requireAnyOf(_0x227cf6,[_0x3a318e(0x1ff)],_0x3060e0),_0x24d61d[_0x3a318e(0x240)]===_0x3a318e(0x205)&&parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x227cf6[_0x3a318e(0x200)](_0x3a318e(0x1ff))));},async 'execute'(_0x3d3bb3){const _0x5133b7=_0x21c9fa,_0x5d6e40=_0x3d3bb3['str'](_0x5133b7(0x1f0)),_0xf86161=_0x24d61d[_0x5133b7(0x240)]==='batchCreate'?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x3d3bb3[_0x5133b7(0x200)](_0x5133b7(0x1ff)))):parseJsonParams(_0x3d3bb3[_0x5133b7(0x200)]('params'))??{},_0x2713dc=Date[_0x5133b7(0x23a)](),_0x3f02d4=await executeData(_0x5d6e40,_0x24d61d['operation'],_0xf86161),_0x4149f1=Date['now']()-_0x2713dc;return{'ok':!![],'data':{'result':_0x3f02d4,'elapsed':_0x4149f1},'message':_0x5133b7(0x245)+_0x24d61d[_0x5133b7(0x23b)]+_0x5133b7(0x1fc)+_0x4149f1+'ms'};}};return _0x24d61d[_0x21c9fa(0x230)]!=='read'&&(_0x3fcbf5['dryRun']=async _0x3d9555=>{const _0x5962c9=_0x21c9fa,_0x468540=_0x3d9555[_0x5962c9(0x200)](_0x5962c9(0x1f0)),_0x1621ff=_0x24d61d[_0x5962c9(0x240)]===_0x5962c9(0x205)?parseBatchCreateItemsFromParams(parseJsonParamsValue(_0x3d9555[_0x5962c9(0x200)](_0x5962c9(0x1ff)))):parseJsonParams(_0x3d9555[_0x5962c9(0x200)](_0x5962c9(0x1ff)))??{};return dryRun(_0x5962c9(0x235),_0x5962c9(0x220)+_0x468540+'/'+_0x24d61d['operation'])[_0x5962c9(0x214)](_0x1621ff)[_0x5962c9(0x20c)](_0x5962c9(0x225)+_0x24d61d[_0x5962c9(0x23b)]+_0x5962c9(0x1f9)+_0x468540)[_0x5962c9(0x23f)]();}),_0x3fcbf5;}export const dataDefinitions=specs[a16_0x1897b8(0x1f1)](makeDataCommand);function a16_0x3374(){const _0x1b83bf=['Example:\x20\x27{\x22where\x22:{\x22status\x22:{\x22$eq\x22:\x22active\x22}},\x22currentPage\x22:1,\x22pageSize\x22:20}\x27','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Pre-aggregation\x20filter\x20(same\x20operators\x20as\x20data\x20filter)','12vNWDba','\x20\x20\x20\x20$startWith\x20\x20\x20Starts\x20with\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$startWith\x22:\x22Mr.\x22}}','Get\x20a\x20single\x20record\x20by\x20ID','description','Delete\x20a\x20record\x20(requires\x20--yes\x20in\x20non-interactive)','write','\x20\x20\x20\x20#\x20Sum\x20amount\x20grouped\x20by\x20status','10775lPTEHl','496221JsAsro','data','\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Average\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg_score\x22}','body','\x20\x20\x20\x20$or\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Any\x20condition\x20matches\x20\x20{\x22$or\x22:[{\x22status\x22:{\x22$eq\x22:\x22active\x22}},{\x22status\x22:{\x22$eq\x22:\x22pending\x22}}]}','Example:\x20\x27{\x22aggregate\x22:[{\x22field\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27','\x20\x20LOGICAL\x20COMBINATORS','join','46gozRRw','\x20\x20\x20\x20currentPage\x20\x20\x20Number\x20\x20\x20Page\x20number\x20(starts\x20from\x201)','paramsHint','867010MDPMJh','Update\x20an\x20existing\x20record','1370601hpZyQV','\x20\x20\x20\x20Wrong:\x20\x20\x20\x20--page-size\x2010\x20\x20(this\x20is\x20not\x20a\x20valid\x20flag)','/api/{appCode}/','Filter\x20dataset\x20records\x20with\x20query\x20conditions','\x20\x20\x20\x20#\x20Count\x20orders\x20per\x20region\x20with\x20filter','\x20\x20\x20\x20Correct:\x20\x20--params\x20\x27{\x22currentPage\x22:1,\x22pageSize\x22:10}\x27','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22total\x22:\x22desc\x22}]','Preview:\x20data\x20','\x20\x20\x20\x20orderBy\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Sort\x20order,\x20e.g.\x20[{\x22id\x22:\x22desc\x22},{\x22name\x22:\x22asc\x22}]','\x20\x20\x20\x20$and\x20\x20\x20\x20\x20\x20\x20\x20\x20All\x20conditions\x20match\x20\x20\x20{\x22$and\x22:[{\x22age\x22:{\x22$gte\x22:18}},{\x22status\x22:{\x22$eq\x22:\x22active\x22}}]}','\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20distinct\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22,\x22distinct\x22:true}','update','Create\x20multiple\x20records\x20in\x20one\x20request\x20(SDK\x20batchCreate)','helpExtra','create','delete','filter','getOne','risk','\x20\x20\x20\x20$gte\x20\x20\x20\x20\x20\x20\x20\x20\x20Greater\x20than\x20or\x20equal\x20\x20{\x22amount\x22:{\x22$gte\x22:100}}','\x20\x20\x20\x20where\x20\x20\x20\x20\x20\x20\x20\x20\x20Object\x20\x20\x20Query\x20conditions\x20(see\x20operators\x20above)','\x20\x20PARAMS\x20STRUCTURE','\x20\x20\x20\x20$lt\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lt\x22:1000}}','POST','1776604qvJCag','JSON\x20with\x20field\x20values.\x20Example:\x20\x27{\x22name\x22:\x22test\x22,\x22amount\x22:100}\x27','\x20\x20\x20\x20COUNT\x20\x20\x20\x20\x20\x20\x20\x20Count\x20of\x20records\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22id\x22,\x22type\x22:\x22COUNT\x22,\x22alias\x22:\x22cnt\x22}','aggregate','now','command','JSON\x20with\x20record\x20id.\x20Example:\x20\x27{\x22id\x22:123}\x27','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return\x20alongside\x20aggregates,\x20e.g.\x20[\x22status\x22,\x22region\x22]','JSON\x20with\x20id\x20+\x20fields\x20to\x20update.\x20Example:\x20\x27{\x22id\x22:123,\x22status\x22:\x22completed\x22}\x27','build','operation','5025760PLMbxn','JSON\x20body\x20for\x20aggregate\x20API.\x20Fields:\x20select,\x20aggregate,\x20where,\x20groupBy,\x20having,\x20orderBy.\x20','JSON\x20array\x20of\x20record\x20objects,\x20or\x20{\x22items\x22:[...]}.\x20Example:\x20\x27[{\x22name\x22:\x22a\x22},{\x22name\x22:\x22b\x22}]\x27','\x20\x20\x20\x20AVG\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Rounded\x20average\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22score\x22,\x22type\x22:\x22AVG\x22,\x22alias\x22:\x22avg\x22,\x22round\x22:true,\x22precision\x22:2}','data\x20','JSON\x20body\x20for\x20filter\x20API.\x20Fields:\x20where,\x20select,\x20orderBy,\x20currentPage,\x20pageSize.\x20','code','map','\x20\x20\x20\x20MIN\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Minimum\x20value\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22field\x22:\x22price\x22,\x22type\x22:\x22MIN\x22,\x22alias\x22:\x22min_price\x22}','\x20\x20\x20\x20Pagination\x20is\x20controlled\x20via\x20JSON\x20in\x20--params.\x20Do\x20NOT\x20use\x20--page-size\x20as\x20a\x20CLI\x20flag.','\x20\x20\x20\x20$eq\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20Equals\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20{\x22age\x22:{\x22$eq\x22:18}}','\x20\x20\x20\x20$contain\x20\x20\x20\x20\x20Substring\x20match\x20\x20\x20\x20\x20\x20\x20\x20{\x22name\x22:{\x22$contain\x22:\x22test\x22}}','Aggregate\x20dataset\x20records\x20(group\x20by,\x20sum,\x20count,\x20avg,\x20etc.)','\x20\x20\x20\x20select\x20\x20\x20\x20\x20\x20\x20\x20Array\x20\x20\x20\x20Fields\x20to\x20return,\x20e.g.\x20[\x22id\x22,\x22name\x22,\x22status\x22]','\x20\x20AGGREGATE\x20TYPES','\x20on\x20dataset\x20','\x20\x20\x20\x20$lte\x20\x20\x20\x20\x20\x20\x20\x20\x20Less\x20than\x20or\x20equal\x20\x20\x20\x20\x20{\x22amount\x22:{\x22$lte\x22:1000}}','high-risk-write','\x20completed\x20in\x20','16pkPXFx','1349446oyfCXn','params','str','\x20\x20EXAMPLES','\x20\x20PAGINATION','Create\x20a\x20new\x20record\x20in\x20a\x20dataset','read','batchCreate','\x20\x20\x20\x20--params\x20\x27{\x22aggregate\x22:[{\x22field\x22:\x22amount\x22,\x22type\x22:\x22SUM\x22,\x22alias\x22:\x22total\x22}],\x22groupBy\x22:[\x22status\x22]}\x27'];a16_0x3374=function(){return _0x1b83bf;};return a16_0x3374();}
@@ -1 +1 @@
1
- const a17_0x153c8a=a17_0x2f31;(function(_0x177dba,_0x574959){const _0xb2a96=a17_0x2f31,_0x408f9b=_0x177dba();while(!![]){try{const _0x35baa0=parseInt(_0xb2a96(0x187))/0x1+-parseInt(_0xb2a96(0x18b))/0x2+-parseInt(_0xb2a96(0x184))/0x3*(parseInt(_0xb2a96(0x1b6))/0x4)+parseInt(_0xb2a96(0x1bc))/0x5+-parseInt(_0xb2a96(0x18e))/0x6+-parseInt(_0xb2a96(0x18c))/0x7*(-parseInt(_0xb2a96(0x1b5))/0x8)+parseInt(_0xb2a96(0x1ab))/0x9;if(_0x35baa0===_0x574959)break;else _0x408f9b['push'](_0x408f9b['shift']());}catch(_0x5bc7c9){_0x408f9b['push'](_0x408f9b['shift']());}}}(a17_0xa857,0xbe364));function a17_0x2f31(_0x1c4d8f,_0x3d8bd2){_0x1c4d8f=_0x1c4d8f-0x174;const _0xa8577f=a17_0xa857();let _0x2f31d9=_0xa8577f[_0x1c4d8f];return _0x2f31d9;}import{getDatasetDetail}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';function normalizeField(_0x2e44ce){const _0x4681c5=a17_0x2f31;if(_0x2e44ce['deleted'])return null;const _0x366304=Boolean(_0x2e44ce[_0x4681c5(0x182)]!==undefined||_0x2e44ce[_0x4681c5(0x1a2)]!==undefined);let _0x3fd1ae={};if(!_0x366304&&typeof _0x2e44ce[_0x4681c5(0x1a0)]===_0x4681c5(0x19a))try{_0x3fd1ae=JSON[_0x4681c5(0x191)](_0x2e44ce[_0x4681c5(0x1a0)]);}catch{}const _0x52d4b6=_0x366304?_0x2e44ce[_0x4681c5(0x180)]:_0x2e44ce[_0x4681c5(0x1a6)],_0x19c3af=_0x366304?_0x2e44ce['displayName']:_0x2e44ce[_0x4681c5(0x180)],_0x35f125=_0x366304?_0x2e44ce[_0x4681c5(0x1a2)]:_0x2e44ce[_0x4681c5(0x175)]||_0x2e44ce['dataType'],_0x2919b7=_0x366304?_0x2e44ce['pkField']===!![]:_0x3fd1ae[_0x4681c5(0x1ac)]===!![],_0x144edf=_0x366304?_0x2e44ce['required']===!![]:_0x3fd1ae[_0x4681c5(0x194)]===!![],_0x14927c=_0x366304?_0x2e44ce[_0x4681c5(0x186)]??null:_0x3fd1ae[_0x4681c5(0x186)]??null,_0x458ca7={'name':_0x52d4b6,'displayName':_0x19c3af||_0x52d4b6,'type':_0x35f125,'dbType':_0x2e44ce[_0x4681c5(0x1b4)],'pk':_0x2919b7,'required':_0x144edf,'description':_0x2e44ce[_0x4681c5(0x1a7)]||undefined};return Array['isArray'](_0x14927c)&&_0x14927c[_0x4681c5(0x17b)]>0x0&&(_0x458ca7[_0x4681c5(0x186)]=_0x14927c),_0x458ca7;}function parseJsonMaybe(_0x4066cb){const _0x100b42=a17_0x2f31;if(typeof _0x4066cb!==_0x100b42(0x19a))return _0x4066cb;try{return JSON[_0x100b42(0x191)](_0x4066cb);}catch{return _0x4066cb;}}function normalizeOperationEntry(_0x50e9ca,_0xb7ecb5){const _0x4dd6cf=a17_0x2f31;if(!_0xb7ecb5||typeof _0xb7ecb5!==_0x4dd6cf(0x199))return null;if(!_0xb7ecb5['method']||!_0xb7ecb5[_0x4dd6cf(0x17f)])return null;const _0x309366={'name':_0x50e9ca,'method':_0xb7ecb5[_0x4dd6cf(0x1aa)],'path':_0xb7ecb5[_0x4dd6cf(0x17f)]};if(_0xb7ecb5[_0x4dd6cf(0x17c)])_0x309366['host']=_0xb7ecb5['host'];if(_0xb7ecb5['requestBody']!=null)_0x309366[_0x4dd6cf(0x176)]=parseJsonMaybe(_0xb7ecb5[_0x4dd6cf(0x176)]);if(_0xb7ecb5[_0x4dd6cf(0x177)]!=null)_0x309366[_0x4dd6cf(0x177)]=parseJsonMaybe(_0xb7ecb5[_0x4dd6cf(0x177)]);if(_0xb7ecb5[_0x4dd6cf(0x1ba)]!=null)_0x309366[_0x4dd6cf(0x1ba)]=_0xb7ecb5[_0x4dd6cf(0x1ba)];if(_0xb7ecb5[_0x4dd6cf(0x1b9)]!=null)_0x309366[_0x4dd6cf(0x1b9)]=_0xb7ecb5['afterScriptId'];if(Array[_0x4dd6cf(0x17e)](_0xb7ecb5[_0x4dd6cf(0x198)]))_0x309366[_0x4dd6cf(0x198)]=_0xb7ecb5[_0x4dd6cf(0x198)];if(Array['isArray'](_0xb7ecb5[_0x4dd6cf(0x1b7)]))_0x309366[_0x4dd6cf(0x1b7)]=_0xb7ecb5['responseFields'];return _0x309366;}function a17_0xa857(){const _0x2a08fc=['dataset','dbId','toDatasetCode','modifierNameField','dbType','8tjfaao','6019516domYAk','responseFields','allFields','afterScriptId','beforeScriptId','properties','7684840HYdNWW','sourceType','toField','type','requestBody','responseBody','Get\x20dataset\x20detail\x20including\x20fields\x20and\x20operations','toTableName','str','length','host','createTimeField','isArray','path','name','map','displayName','dbName','3XPHVKg','logicField','options','37434OtQHTF','read','creatorNameField','entries','564842BZLuSl','5020113CgFHay','modelId','7353498DBPKEM','operations','split','parse','formatRules','toFieldLabel','required','labelField','modifierIdField','dbtableConfig','requestFields','object','string','validateRules','title','allFieldNames','toDatasetName','indexes','extend','detail','doType','filter','fromField','creatorIdField','code','description','fields','tableName','method','13503870GKMeDU','pkField','relations','deleted','modelCode'];a17_0xa857=function(){return _0x2a08fc;};return a17_0xa857();}function summarizeDbtable(_0x5f2e9b){const _0x297ceb=a17_0x2f31,_0x1f4328={},_0x2fe05b=[_0x297ceb(0x1b1),'dbName','tableName','datasetKey','pkField',_0x297ceb(0x1b8),_0x297ceb(0x185),_0x297ceb(0x17d),'updateTimeField',_0x297ceb(0x1a5),_0x297ceb(0x189),_0x297ceb(0x196),_0x297ceb(0x1b3),_0x297ceb(0x195),'dblinkInfoDTO'];for(const _0x23f1b0 of _0x2fe05b){if(_0x5f2e9b[_0x23f1b0]!==undefined)_0x1f4328[_0x23f1b0]=_0x5f2e9b[_0x23f1b0];}return typeof _0x1f4328[_0x297ceb(0x1b8)]==='string'&&_0x1f4328[_0x297ceb(0x1b8)][_0x297ceb(0x17b)]>0x0&&(_0x1f4328[_0x297ceb(0x19d)]=_0x1f4328['allFields'][_0x297ceb(0x190)](',')[_0x297ceb(0x181)](_0xaaea1d=>_0xaaea1d['trim']())[_0x297ceb(0x1a3)](Boolean)),_0x1f4328;}function normalizeRelatedPages(_0x301635){const _0x293391=a17_0x2f31;if(!Array[_0x293391(0x17e)](_0x301635))return[];return _0x301635[_0x293391(0x1a3)](_0x5cbdfa=>_0x5cbdfa&&typeof _0x5cbdfa===_0x293391(0x199))[_0x293391(0x181)](_0x3ba39e=>({'id':_0x3ba39e['id'],'type':_0x3ba39e[_0x293391(0x175)],'code':_0x3ba39e[_0x293391(0x1a6)],'title':_0x3ba39e[_0x293391(0x19c)],'deleted':_0x3ba39e[_0x293391(0x1ae)]===!![]}));}export const datasetDetail={'service':a17_0x153c8a(0x1b0),'command':a17_0x153c8a(0x1a1),'description':a17_0x153c8a(0x178),'risk':a17_0x153c8a(0x188),'flags':[CODE_FLAG],async 'execute'(_0x1f6170){const _0x46478d=a17_0x153c8a,_0x29d7e2=await getDatasetDetail(_0x1f6170[_0x46478d(0x17a)](_0x46478d(0x1a6))),_0x13ec28=Array['isArray'](_0x29d7e2[_0x46478d(0x1a8)])?_0x29d7e2[_0x46478d(0x1a8)]:Array[_0x46478d(0x17e)](_0x29d7e2[_0x46478d(0x1bb)])?_0x29d7e2['properties']:[],_0x5a0f96=_0x13ec28['map'](_0x3770fd=>normalizeField(_0x3770fd))[_0x46478d(0x1a3)](_0x5207cf=>_0x5207cf!==null),_0x65db2b=_0x29d7e2[_0x46478d(0x18f)]??{},_0x4051af=[];for(const [_0x133417,_0x4f3f1f]of Object[_0x46478d(0x18a)](_0x65db2b)){const _0x105449=normalizeOperationEntry(_0x133417,_0x4f3f1f);if(_0x105449)_0x4051af['push'](_0x105449);}const _0x12fcda=_0x29d7e2[_0x46478d(0x197)]??{},_0x27b118=_0x29d7e2[_0x46478d(0x1b0)]??{},_0x164d19=_0x12fcda[_0x46478d(0x1b1)]!=null?{'id':_0x12fcda[_0x46478d(0x1b1)],'name':_0x12fcda[_0x46478d(0x183)]??null}:undefined;let _0x304498;return typeof _0x29d7e2[_0x46478d(0x1a0)]===_0x46478d(0x19a)&&(_0x304498=parseJsonMaybe(_0x29d7e2[_0x46478d(0x1a0)])),{'ok':!![],'data':{'id':_0x29d7e2[_0x46478d(0x18d)]??_0x29d7e2['id'],'name':_0x29d7e2[_0x46478d(0x180)],'code':_0x29d7e2[_0x46478d(0x1af)]||_0x29d7e2[_0x46478d(0x1a6)],'doVersion':_0x29d7e2['doVersion'],'description':_0x29d7e2[_0x46478d(0x1a7)]||_0x27b118['tableComment']||undefined,'source':_0x29d7e2['source']||_0x27b118[_0x46478d(0x1bd)],'table':_0x12fcda[_0x46478d(0x1a9)]||_0x27b118['tableName'],'datasetKey':_0x12fcda['datasetKey'],'pk':_0x12fcda[_0x46478d(0x1ac)],'db':_0x164d19,'dbtable':summarizeDbtable(_0x12fcda),'fields':_0x5a0f96,'operations':_0x4051af,'indexes':Array[_0x46478d(0x17e)](_0x27b118['indexes'])?_0x27b118[_0x46478d(0x19f)]:[],'relations':Array['isArray'](_0x29d7e2[_0x46478d(0x1ad)])?_0x29d7e2[_0x46478d(0x1ad)][_0x46478d(0x181)](_0x90bb35=>({'fromField':_0x90bb35[_0x46478d(0x1a4)],'toDataset':_0x90bb35[_0x46478d(0x19e)],'toCode':_0x90bb35[_0x46478d(0x1b2)],'toTable':_0x90bb35[_0x46478d(0x179)],'toField':_0x90bb35[_0x46478d(0x174)],'labelField':_0x90bb35[_0x46478d(0x193)]||undefined})):[],'relatedPages':normalizeRelatedPages(_0x29d7e2['relatedPageInfoList']),...Array[_0x46478d(0x17e)](_0x29d7e2['columnCodeListWithDeleted'])?{'columnCodeListWithDeleted':_0x29d7e2['columnCodeListWithDeleted']}:{},'formatRules':Array['isArray'](_0x29d7e2[_0x46478d(0x192)])?_0x29d7e2['formatRules']:[],'validateRules':Array['isArray'](_0x29d7e2[_0x46478d(0x19b)])?_0x29d7e2[_0x46478d(0x19b)]:[],..._0x304498!==undefined?{'extend':_0x304498}:{},'stats':{'fieldCount':_0x5a0f96[_0x46478d(0x17b)],'operationCount':_0x4051af[_0x46478d(0x17b)]}}};}};
1
+ const a17_0x2cec0d=a17_0x3ec0;(function(_0x52909c,_0x14223b){const _0x1e5994=a17_0x3ec0,_0x2ce4f2=_0x52909c();while(!![]){try{const _0x3c24b1=-parseInt(_0x1e5994(0x1c8))/0x1+parseInt(_0x1e5994(0x1e7))/0x2+parseInt(_0x1e5994(0x200))/0x3+-parseInt(_0x1e5994(0x1d9))/0x4+-parseInt(_0x1e5994(0x1cd))/0x5*(-parseInt(_0x1e5994(0x1e8))/0x6)+parseInt(_0x1e5994(0x1c4))/0x7*(-parseInt(_0x1e5994(0x1d4))/0x8)+-parseInt(_0x1e5994(0x1e4))/0x9*(-parseInt(_0x1e5994(0x1f3))/0xa);if(_0x3c24b1===_0x14223b)break;else _0x2ce4f2['push'](_0x2ce4f2['shift']());}catch(_0x22d7c8){_0x2ce4f2['push'](_0x2ce4f2['shift']());}}}(a17_0x1e35,0xa4c79));import{getDatasetDetail}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';function a17_0x3ec0(_0x3caacd,_0x3b6dee){_0x3caacd=_0x3caacd-0x1c4;const _0x1e35fb=a17_0x1e35();let _0x3ec012=_0x1e35fb[_0x3caacd];return _0x3ec012;}function normalizeField(_0x6ee723){const _0x583c9b=a17_0x3ec0;if(_0x6ee723[_0x583c9b(0x1f0)])return null;const _0x19acf5=Boolean(_0x6ee723[_0x583c9b(0x1d6)]!==undefined||_0x6ee723[_0x583c9b(0x1e1)]!==undefined);let _0x4c7937={};if(!_0x19acf5&&typeof _0x6ee723[_0x583c9b(0x1ca)]===_0x583c9b(0x209))try{_0x4c7937=JSON[_0x583c9b(0x1d1)](_0x6ee723[_0x583c9b(0x1ca)]);}catch{}const _0x5a8ce0=_0x19acf5?_0x6ee723[_0x583c9b(0x201)]:_0x6ee723[_0x583c9b(0x1f8)],_0x586575=_0x19acf5?_0x6ee723[_0x583c9b(0x1d6)]:_0x6ee723['name'],_0x9a0643=_0x19acf5?_0x6ee723[_0x583c9b(0x1e1)]:_0x6ee723['type']||_0x6ee723['dataType'],_0x1ede3=_0x19acf5?_0x6ee723[_0x583c9b(0x1cf)]===!![]:_0x4c7937['pkField']===!![],_0x2e5b3a=_0x19acf5?_0x6ee723[_0x583c9b(0x1e5)]===!![]:_0x4c7937[_0x583c9b(0x1e5)]===!![],_0x49205f=_0x19acf5?_0x6ee723[_0x583c9b(0x208)]??null:_0x4c7937['options']??null,_0x46567e={'name':_0x5a8ce0,'displayName':_0x586575||_0x5a8ce0,'type':_0x9a0643,'dbType':_0x6ee723[_0x583c9b(0x1d2)],'pk':_0x1ede3,'required':_0x2e5b3a,'description':_0x6ee723[_0x583c9b(0x1d5)]||undefined};return Array['isArray'](_0x49205f)&&_0x49205f[_0x583c9b(0x207)]>0x0&&(_0x46567e['options']=_0x49205f),_0x46567e;}function parseJsonMaybe(_0x39ef93){const _0x285f08=a17_0x3ec0;if(typeof _0x39ef93!==_0x285f08(0x209))return _0x39ef93;try{return JSON[_0x285f08(0x1d1)](_0x39ef93);}catch{return _0x39ef93;}}function a17_0x1e35(){const _0x4c5398=['name','requestBody','toField','beforeScriptId','host','entries','length','options','string','properties','273guAYtR','responseBody','creatorNameField','operations','265164YxvbEQ','requestFields','extend','fromField','createTimeField','15ujvPSH','toTableName','pkField','dbtableConfig','parse','dbType','dbName','224568NIqnYN','description','displayName','modifierIdField','object','4522080bqPlYb','dbId','tableName','sourceType','map','indexes','method','isArray','doType','formatRules','read','92727kEnfLj','required','afterScriptId','405894TTzAKx','2565174JUsDMq','doVersion','toDatasetCode','filter','tableComment','modifierNameField','toDatasetName','str','deleted','creatorIdField','title','1030uxidHj','path','labelField','updateTimeField','modelCode','code','datasetKey','validateRules','relatedPageInfoList','toFieldLabel','responseFields','allFields','relations','1855941jrsyxL'];a17_0x1e35=function(){return _0x4c5398;};return a17_0x1e35();}function normalizeOperationEntry(_0x553b0b,_0x458ad9){const _0x57fcb7=a17_0x3ec0;if(!_0x458ad9||typeof _0x458ad9!==_0x57fcb7(0x1d8))return null;if(!_0x458ad9[_0x57fcb7(0x1df)]||!_0x458ad9['path'])return null;const _0x587510={'name':_0x553b0b,'method':_0x458ad9[_0x57fcb7(0x1df)],'path':_0x458ad9[_0x57fcb7(0x1f4)]};if(_0x458ad9[_0x57fcb7(0x205)])_0x587510[_0x57fcb7(0x205)]=_0x458ad9[_0x57fcb7(0x205)];if(_0x458ad9[_0x57fcb7(0x202)]!=null)_0x587510[_0x57fcb7(0x202)]=parseJsonMaybe(_0x458ad9[_0x57fcb7(0x202)]);if(_0x458ad9[_0x57fcb7(0x1c5)]!=null)_0x587510[_0x57fcb7(0x1c5)]=parseJsonMaybe(_0x458ad9[_0x57fcb7(0x1c5)]);if(_0x458ad9['beforeScriptId']!=null)_0x587510['beforeScriptId']=_0x458ad9[_0x57fcb7(0x204)];if(_0x458ad9[_0x57fcb7(0x1e6)]!=null)_0x587510[_0x57fcb7(0x1e6)]=_0x458ad9['afterScriptId'];if(Array['isArray'](_0x458ad9[_0x57fcb7(0x1c9)]))_0x587510['requestFields']=_0x458ad9[_0x57fcb7(0x1c9)];if(Array['isArray'](_0x458ad9[_0x57fcb7(0x1fd)]))_0x587510[_0x57fcb7(0x1fd)]=_0x458ad9[_0x57fcb7(0x1fd)];return _0x587510;}function summarizeDbtable(_0x413a3c){const _0x76e69=a17_0x3ec0,_0x5bc699={},_0x2d53ff=[_0x76e69(0x1da),_0x76e69(0x1d3),_0x76e69(0x1db),_0x76e69(0x1f9),_0x76e69(0x1cf),'allFields','logicField',_0x76e69(0x1cc),_0x76e69(0x1f6),_0x76e69(0x1f1),_0x76e69(0x1c6),_0x76e69(0x1d7),_0x76e69(0x1ed),_0x76e69(0x1f5),'dblinkInfoDTO'];for(const _0x156f87 of _0x2d53ff){if(_0x413a3c[_0x156f87]!==undefined)_0x5bc699[_0x156f87]=_0x413a3c[_0x156f87];}return typeof _0x5bc699[_0x76e69(0x1fe)]===_0x76e69(0x209)&&_0x5bc699[_0x76e69(0x1fe)]['length']>0x0&&(_0x5bc699['allFieldNames']=_0x5bc699['allFields']['split'](',')[_0x76e69(0x1dd)](_0x58ed5e=>_0x58ed5e['trim']())[_0x76e69(0x1eb)](Boolean)),_0x5bc699;}function normalizeRelatedPages(_0xee1c7b){const _0x2ee89b=a17_0x3ec0;if(!Array[_0x2ee89b(0x1e0)](_0xee1c7b))return[];return _0xee1c7b[_0x2ee89b(0x1eb)](_0x4cad49=>_0x4cad49&&typeof _0x4cad49===_0x2ee89b(0x1d8))[_0x2ee89b(0x1dd)](_0x2eae6b=>({'id':_0x2eae6b['id'],'type':_0x2eae6b['type'],'code':_0x2eae6b[_0x2ee89b(0x1f8)],'title':_0x2eae6b[_0x2ee89b(0x1f2)],'deleted':_0x2eae6b[_0x2ee89b(0x1f0)]===!![]}));}export const datasetDetail={'service':'dataset','command':'detail','description':'Get\x20dataset\x20detail\x20including\x20fields\x20and\x20operations','risk':a17_0x2cec0d(0x1e3),'flags':[CODE_FLAG],async 'execute'(_0x351c21){const _0xbbf7fa=a17_0x2cec0d,_0xce32ab=await getDatasetDetail(_0x351c21[_0xbbf7fa(0x1ef)](_0xbbf7fa(0x1f8))),_0x30bfe4=Array['isArray'](_0xce32ab['fields'])?_0xce32ab['fields']:Array['isArray'](_0xce32ab[_0xbbf7fa(0x20a)])?_0xce32ab[_0xbbf7fa(0x20a)]:[],_0x1f85c5=_0x30bfe4['map'](_0x181bb=>normalizeField(_0x181bb))[_0xbbf7fa(0x1eb)](_0x3bbfa0=>_0x3bbfa0!==null),_0x5b7991=_0xce32ab[_0xbbf7fa(0x1c7)]??{},_0x554aaf=[];for(const [_0x4dc4cf,_0x1bb08d]of Object[_0xbbf7fa(0x206)](_0x5b7991)){const _0x218a00=normalizeOperationEntry(_0x4dc4cf,_0x1bb08d);if(_0x218a00)_0x554aaf['push'](_0x218a00);}const _0xdf0cfc=_0xce32ab[_0xbbf7fa(0x1d0)]??{},_0x1f7aaf=_0xce32ab['dataset']??{},_0xabee0e=_0xdf0cfc['dbId']!=null?{'id':_0xdf0cfc[_0xbbf7fa(0x1da)],'name':_0xdf0cfc[_0xbbf7fa(0x1d3)]??null}:undefined;let _0x35ccf6;return typeof _0xce32ab['extend']===_0xbbf7fa(0x209)&&(_0x35ccf6=parseJsonMaybe(_0xce32ab[_0xbbf7fa(0x1ca)])),{'ok':!![],'data':{'id':_0xce32ab['modelId']??_0xce32ab['id'],'name':_0xce32ab['name'],'code':_0xce32ab[_0xbbf7fa(0x1f7)]||_0xce32ab[_0xbbf7fa(0x1f8)],'doVersion':_0xce32ab[_0xbbf7fa(0x1e9)],'description':_0xce32ab[_0xbbf7fa(0x1d5)]||_0x1f7aaf[_0xbbf7fa(0x1ec)]||undefined,'source':_0xce32ab['source']||_0x1f7aaf[_0xbbf7fa(0x1dc)],'table':_0xdf0cfc[_0xbbf7fa(0x1db)]||_0x1f7aaf[_0xbbf7fa(0x1db)],'datasetKey':_0xdf0cfc[_0xbbf7fa(0x1f9)],'pk':_0xdf0cfc['pkField'],'db':_0xabee0e,'dbtable':summarizeDbtable(_0xdf0cfc),'fields':_0x1f85c5,'operations':_0x554aaf,'indexes':Array[_0xbbf7fa(0x1e0)](_0x1f7aaf[_0xbbf7fa(0x1de)])?_0x1f7aaf[_0xbbf7fa(0x1de)]:[],'relations':Array[_0xbbf7fa(0x1e0)](_0xce32ab[_0xbbf7fa(0x1ff)])?_0xce32ab[_0xbbf7fa(0x1ff)]['map'](_0x49cb31=>({'fromField':_0x49cb31[_0xbbf7fa(0x1cb)],'toDataset':_0x49cb31[_0xbbf7fa(0x1ee)],'toCode':_0x49cb31[_0xbbf7fa(0x1ea)],'toTable':_0x49cb31[_0xbbf7fa(0x1ce)],'toField':_0x49cb31[_0xbbf7fa(0x203)],'labelField':_0x49cb31[_0xbbf7fa(0x1fc)]||undefined})):[],'relatedPages':normalizeRelatedPages(_0xce32ab[_0xbbf7fa(0x1fb)]),...Array[_0xbbf7fa(0x1e0)](_0xce32ab['columnCodeListWithDeleted'])?{'columnCodeListWithDeleted':_0xce32ab['columnCodeListWithDeleted']}:{},'formatRules':Array['isArray'](_0xce32ab[_0xbbf7fa(0x1e2)])?_0xce32ab[_0xbbf7fa(0x1e2)]:[],'validateRules':Array[_0xbbf7fa(0x1e0)](_0xce32ab[_0xbbf7fa(0x1fa)])?_0xce32ab[_0xbbf7fa(0x1fa)]:[],..._0x35ccf6!==undefined?{'extend':_0x35ccf6}:{},'stats':{'fieldCount':_0x1f85c5[_0xbbf7fa(0x207)],'operationCount':_0x554aaf[_0xbbf7fa(0x207)]}}};}};
@@ -1 +1 @@
1
- (function(_0x5db4cb,_0x25f76e){const _0x1416da=a18_0x33e2,_0x18fe0d=_0x5db4cb();while(!![]){try{const _0xf76ada=-parseInt(_0x1416da(0x10e))/0x1*(-parseInt(_0x1416da(0x10f))/0x2)+parseInt(_0x1416da(0x10d))/0x3*(-parseInt(_0x1416da(0x110))/0x4)+parseInt(_0x1416da(0x112))/0x5+-parseInt(_0x1416da(0x113))/0x6+parseInt(_0x1416da(0x10c))/0x7*(-parseInt(_0x1416da(0x111))/0x8)+-parseInt(_0x1416da(0x10a))/0x9+parseInt(_0x1416da(0x10b))/0xa;if(_0xf76ada===_0x25f76e)break;else _0x18fe0d['push'](_0x18fe0d['shift']());}catch(_0x4343cf){_0x18fe0d['push'](_0x18fe0d['shift']());}}}(a18_0x1f0b,0xe04b6));function a18_0x1f0b(){const _0x5c637b=['41911feumlI','2JXCzzp','4SUwymC','3944OPoyiT','3103765TeyxWK','9774804FTqzfJ','2173932WyEmmp','32217430MiqGgp','1974FWZrXn','2867967LnBedn'];a18_0x1f0b=function(){return _0x5c637b;};return a18_0x1f0b();}import{datasetList}from'../../commands/dataset/list.js';function a18_0x33e2(_0xa4a8dd,_0x125218){_0xa4a8dd=_0xa4a8dd-0x10a;const _0x1f0b65=a18_0x1f0b();let _0x33e2c2=_0x1f0b65[_0xa4a8dd];return _0x33e2c2;}import{datasetDetail}from'../../commands/dataset/detail.js';export const datasetDefinitions=[datasetList,datasetDetail];
1
+ (function(_0x85ce1d,_0x262476){const _0x56019a=a18_0x1254,_0x562cd6=_0x85ce1d();while(!![]){try{const _0x41e633=parseInt(_0x56019a(0x133))/0x1+parseInt(_0x56019a(0x130))/0x2*(-parseInt(_0x56019a(0x134))/0x3)+-parseInt(_0x56019a(0x131))/0x4+parseInt(_0x56019a(0x12d))/0x5+-parseInt(_0x56019a(0x132))/0x6+-parseInt(_0x56019a(0x12f))/0x7+parseInt(_0x56019a(0x12e))/0x8;if(_0x41e633===_0x262476)break;else _0x562cd6['push'](_0x562cd6['shift']());}catch(_0x5530fc){_0x562cd6['push'](_0x562cd6['shift']());}}}(a18_0x4387,0xa51bf));import{datasetList}from'../../commands/dataset/list.js';function a18_0x4387(){const _0x5ae8c8=['6810012uopydj','707938pxiAYe','6PKkJiq','1373685KLDoxK','37935200SInpbj','8549471cXVsJs','1346626SnmhID','5381228IFRChN'];a18_0x4387=function(){return _0x5ae8c8;};return a18_0x4387();}import{datasetDetail}from'../../commands/dataset/detail.js';function a18_0x1254(_0x24c3e6,_0x29b2b9){_0x24c3e6=_0x24c3e6-0x12d;const _0x4387e7=a18_0x4387();let _0x125410=_0x4387e7[_0x24c3e6];return _0x125410;}export const datasetDefinitions=[datasetList,datasetDetail];
@@ -1 +1 @@
1
- const a19_0x182c0f=a19_0x4ea4;function a19_0x5390(){const _0x11361f=['Filter\x20by\x20dataset\x20code\x20(server-side\x20exact\x20match)','52snsitx','description','string','dataset','dbtableConfig','source','6626AwkzCn','6243wZdxqL','810261PfnqfN','trim','length','160rjcvpu','allFields','pkField','map','6492250xyZeIA','12860kAWvaf','name','split','Filter\x20by\x20dataset\x20name\x20(server-side\x20fuzzy\x20match)','3468bYLEBl','476980HLjNPw','appCode','List\x20datasets\x20in\x20the\x20app\x20(supports\x20server-side\x20name/code\x20filtering)','str','74zDaecz','1869670CyiiOB','list','code','tableName'];a19_0x5390=function(){return _0x11361f;};return a19_0x5390();}function a19_0x4ea4(_0x140eeb,_0x245bc1){_0x140eeb=_0x140eeb-0x12c;const _0x53909f=a19_0x5390();let _0x4ea44d=_0x53909f[_0x140eeb];return _0x4ea44d;}(function(_0x51317a,_0xe60f2f){const _0x4b4a47=a19_0x4ea4,_0x396b4c=_0x51317a();while(!![]){try{const _0x4cb6ce=parseInt(_0x4b4a47(0x141))/0x1*(-parseInt(_0x4b4a47(0x12e))/0x2)+-parseInt(_0x4b4a47(0x12f))/0x3*(-parseInt(_0x4b4a47(0x147))/0x4)+parseInt(_0x4b4a47(0x138))/0x5*(parseInt(_0x4b4a47(0x13c))/0x6)+-parseInt(_0x4b4a47(0x13d))/0x7*(parseInt(_0x4b4a47(0x133))/0x8)+parseInt(_0x4b4a47(0x130))/0x9+parseInt(_0x4b4a47(0x137))/0xa+parseInt(_0x4b4a47(0x142))/0xb;if(_0x4cb6ce===_0xe60f2f)break;else _0x396b4c['push'](_0x396b4c['shift']());}catch(_0x3c0b3c){_0x396b4c['push'](_0x396b4c['shift']());}}}(a19_0x5390,0xc6f53));import{listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';export const datasetList={'service':a19_0x182c0f(0x14a),'command':a19_0x182c0f(0x143),'description':a19_0x182c0f(0x13f),'risk':'read','flags':[{'name':a19_0x182c0f(0x139),'type':a19_0x182c0f(0x149),'description':a19_0x182c0f(0x13b)},{...CODE_FLAG,'required':![],'description':a19_0x182c0f(0x146)}],async 'execute'(_0x52690e){const _0x5d8149=a19_0x182c0f,_0x25a969=_0x52690e[_0x5d8149(0x140)](_0x5d8149(0x139)),_0x296134=_0x52690e[_0x5d8149(0x140)](_0x5d8149(0x144)),_0x40da6c=await listDatasets(_0x52690e[_0x5d8149(0x13e)],{..._0x25a969&&{'name':_0x25a969},..._0x296134&&{'code':_0x296134}});return{'ok':!![],'data':{'total':_0x40da6c[_0x5d8149(0x132)],'datasets':_0x40da6c[_0x5d8149(0x136)](_0xa3fa95=>{const _0x3d6247=_0x5d8149,_0x582e7e=_0xa3fa95[_0x3d6247(0x12c)]??{};return{'id':_0xa3fa95['id'],'code':_0xa3fa95['code'],'name':_0xa3fa95['name'],'source':_0xa3fa95[_0x3d6247(0x12d)],'description':_0xa3fa95[_0x3d6247(0x148)],'table':_0x582e7e[_0x3d6247(0x145)],'datasetKey':_0x582e7e['datasetKey'],'pk':_0x582e7e[_0x3d6247(0x135)],'fields':_0x582e7e['allFields']?_0x582e7e[_0x3d6247(0x134)][_0x3d6247(0x13a)](',')['map'](_0x195b07=>_0x195b07[_0x3d6247(0x131)]()):[]};})}};}};
1
+ const a19_0x2baed3=a19_0x7460;function a19_0x7460(_0xe714b3,_0x2a3fc2){_0xe714b3=_0xe714b3-0x151;const _0x238e27=a19_0x238e();let _0x74609=_0x238e27[_0xe714b3];return _0x74609;}function a19_0x238e(){const _0x58c509=['description','dataset','tableName','237650cUtFVH','6681790oDjWZD','str','36mIknca','appCode','length','4VenoVt','map','trim','112xVDteC','1124128cCYjib','1255521WdEikf','string','49511ltPOXd','List\x20datasets\x20in\x20the\x20app\x20(supports\x20server-side\x20name/code\x20filtering)','source','pkField','Filter\x20by\x20dataset\x20code\x20(server-side\x20exact\x20match)','code','name','178983ZjjofS','11042JqCRHx','list'];a19_0x238e=function(){return _0x58c509;};return a19_0x238e();}(function(_0x185c78,_0x1d71f1){const _0x1c40a1=a19_0x7460,_0x51b63a=_0x185c78();while(!![]){try{const _0x52d213=-parseInt(_0x1c40a1(0x163))/0x1*(parseInt(_0x1c40a1(0x154))/0x2)+-parseInt(_0x1c40a1(0x159))/0x3+-parseInt(_0x1c40a1(0x158))/0x4+-parseInt(_0x1c40a1(0x168))/0x5+parseInt(_0x1c40a1(0x151))/0x6*(parseInt(_0x1c40a1(0x15b))/0x7)+-parseInt(_0x1c40a1(0x157))/0x8*(-parseInt(_0x1c40a1(0x162))/0x9)+parseInt(_0x1c40a1(0x169))/0xa;if(_0x52d213===_0x1d71f1)break;else _0x51b63a['push'](_0x51b63a['shift']());}catch(_0x83bdb6){_0x51b63a['push'](_0x51b63a['shift']());}}}(a19_0x238e,0x35aea));import{listDatasets}from'../../core/api-client.js';import{CODE_FLAG}from'../../commands/common/flags.js';export const datasetList={'service':a19_0x2baed3(0x166),'command':a19_0x2baed3(0x164),'description':a19_0x2baed3(0x15c),'risk':'read','flags':[{'name':a19_0x2baed3(0x161),'type':a19_0x2baed3(0x15a),'description':'Filter\x20by\x20dataset\x20name\x20(server-side\x20fuzzy\x20match)'},{...CODE_FLAG,'required':![],'description':a19_0x2baed3(0x15f)}],async 'execute'(_0x480f39){const _0x2c62a5=a19_0x2baed3,_0xeee6ce=_0x480f39[_0x2c62a5(0x16a)]('name'),_0xa647b2=_0x480f39[_0x2c62a5(0x16a)](_0x2c62a5(0x160)),_0x3c2d57=await listDatasets(_0x480f39[_0x2c62a5(0x152)],{..._0xeee6ce&&{'name':_0xeee6ce},..._0xa647b2&&{'code':_0xa647b2}});return{'ok':!![],'data':{'total':_0x3c2d57[_0x2c62a5(0x153)],'datasets':_0x3c2d57[_0x2c62a5(0x155)](_0x22921b=>{const _0x1aadaf=_0x2c62a5,_0x534f97=_0x22921b['dbtableConfig']??{};return{'id':_0x22921b['id'],'code':_0x22921b[_0x1aadaf(0x160)],'name':_0x22921b['name'],'source':_0x22921b[_0x1aadaf(0x15d)],'description':_0x22921b[_0x1aadaf(0x165)],'table':_0x534f97[_0x1aadaf(0x167)],'datasetKey':_0x534f97['datasetKey'],'pk':_0x534f97[_0x1aadaf(0x15e)],'fields':_0x534f97['allFields']?_0x534f97['allFields']['split'](',')[_0x1aadaf(0x155)](_0x690ce3=>_0x690ce3[_0x1aadaf(0x156)]()):[]};})}};}};
@@ -1 +1 @@
1
- function a20_0x14ef(_0x38ea88,_0x2b42c7){_0x38ea88=_0x38ea88-0x89;const _0x2ac8a1=a20_0x2ac8();let _0x14ef88=_0x2ac8a1[_0x38ea88];return _0x14ef88;}const a20_0x47b162=a20_0x14ef;(function(_0x2919fe,_0x2162cc){const _0x118cb8=a20_0x14ef,_0x2e0dca=_0x2919fe();while(!![]){try{const _0x45da1c=-parseInt(_0x118cb8(0x8a))/0x1+-parseInt(_0x118cb8(0xaa))/0x2*(-parseInt(_0x118cb8(0xad))/0x3)+-parseInt(_0x118cb8(0x94))/0x4+parseInt(_0x118cb8(0xa8))/0x5*(-parseInt(_0x118cb8(0xd1))/0x6)+parseInt(_0x118cb8(0x8c))/0x7+parseInt(_0x118cb8(0xa7))/0x8*(-parseInt(_0x118cb8(0xb7))/0x9)+parseInt(_0x118cb8(0xb3))/0xa;if(_0x45da1c===_0x2162cc)break;else _0x2e0dca['push'](_0x2e0dca['shift']());}catch(_0xb49409){_0x2e0dca['push'](_0x2e0dca['shift']());}}}(a20_0x2ac8,0xab27f));import a20_0x4b1f82 from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{getCliVersion}from'../utils/version.js';import{getApiDomain,getRuntimeDomain,getUserDomain}from'../constant/domain.js';import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';import{isLegacyCompatConfigKey}from'../config/schema.js';async function execute(_0x29cbce){const _0x554701=a20_0x14ef,_0x38cd99=getCliVersion(),_0xe9edbe=buildConfigFromFlags({});await initGlobalEnvironment(_0xe9edbe),console['log'](),console[_0x554701(0xbc)](a20_0x4b1f82[_0x554701(0xac)](CLI_BIN_NAME+_0x554701(0xba))),console['log'](a20_0x4b1f82[_0x554701(0x8d)]('─'[_0x554701(0xb6)](0x32))),console[_0x554701(0xbc)](_0x554701(0xd2)+_0x38cd99),console[_0x554701(0xbc)]('\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+process[_0x554701(0xcb)]),console[_0x554701(0xbc)](_0x554701(0xc7)+process['platform']+'\x20'+process['arch']),console[_0x554701(0xbc)](),console[_0x554701(0xbc)](a20_0x4b1f82[_0x554701(0xac)](_0x554701(0xc6))),console[_0x554701(0xbc)](a20_0x4b1f82[_0x554701(0x8d)](_0x554701(0x8f)[_0x554701(0xb6)](0x1e)));const _0x1594d7=getGlobalConfigPath(),_0x2d69f8=getProjectConfigPath();console['log'](_0x554701(0x8b)+(_0x1594d7||a20_0x4b1f82[_0x554701(0x8d)](_0x554701(0xc4)))),console[_0x554701(0xbc)](_0x554701(0xbb)+(_0x2d69f8||a20_0x4b1f82[_0x554701(0x8d)]('(not\x20found)'))),console['log'](),console[_0x554701(0xbc)](a20_0x4b1f82['bold'](_0x554701(0xc2))),console[_0x554701(0xbc)](a20_0x4b1f82[_0x554701(0x8d)](_0x554701(0x8f)[_0x554701(0xb6)](0x1e)));const _0x42fbc2=(_0x4513d5,_0x537f17)=>{const _0x3e4e98=_0x554701;if(!_0x537f17){console['log']('\x20\x20'+_0x4513d5['padEnd'](0x11)+'\x20'+a20_0x4b1f82[_0x3e4e98(0x8d)](_0x3e4e98(0xbe)));return;}const _0x2fa0e2=inspectCliConfigJsonFile(_0x537f17);if(_0x2fa0e2[_0x3e4e98(0x91)]==='ok')console[_0x3e4e98(0xbc)]('\x20\x20'+_0x4513d5[_0x3e4e98(0xcc)](0x11)+'\x20'+a20_0x4b1f82['green'](_0x3e4e98(0xd5)));else{if(_0x2fa0e2[_0x3e4e98(0x91)]==='empty')console['log']('\x20\x20'+_0x4513d5[_0x3e4e98(0xcc)](0x11)+'\x20'+a20_0x4b1f82[_0x3e4e98(0xa2)](_0x3e4e98(0x89)));else _0x2fa0e2['status']===_0x3e4e98(0xb9)?console[_0x3e4e98(0xbc)]('\x20\x20'+_0x4513d5[_0x3e4e98(0xcc)](0x11)+'\x20'+a20_0x4b1f82[_0x3e4e98(0x8d)](_0x3e4e98(0x92))):(console[_0x3e4e98(0xbc)]('\x20\x20'+_0x4513d5[_0x3e4e98(0xcc)](0x11)+'\x20'+a20_0x4b1f82[_0x3e4e98(0x95)]('✗\x20Invalid\x20JSON')),console[_0x3e4e98(0xbc)]('\x20\x20'+''['padEnd'](0x11)+'\x20'+a20_0x4b1f82[_0x3e4e98(0x95)](_0x2fa0e2[_0x3e4e98(0xcd)])));}};_0x42fbc2(_0x554701(0xbf),_0x1594d7),_0x42fbc2(_0x554701(0xb2),_0x2d69f8),console['log'](),console[_0x554701(0xbc)](a20_0x4b1f82[_0x554701(0xac)](_0x554701(0xb4))),console[_0x554701(0xbc)](a20_0x4b1f82['gray'](_0x554701(0x8f)[_0x554701(0xb6)](0x1e))),console[_0x554701(0xbc)](_0x554701(0xa0)+(_0xe9edbe['appCode']||a20_0x4b1f82[_0x554701(0x95)](_0x554701(0x8e)))),console[_0x554701(0xbc)](_0x554701(0xa4)+_0xe9edbe[_0x554701(0xd4)]);const _0x1d007c=isLegacyCompatConfigKey(_0x554701(0xa6))?a20_0x4b1f82[_0x554701(0x8d)](_0xe9edbe[_0x554701(0xa6)]+_0x554701(0xa5)):_0xe9edbe[_0x554701(0xa6)];return console[_0x554701(0xbc)](_0x554701(0xa1)+_0x1d007c),console[_0x554701(0xbc)](_0x554701(0xc1)+(_0xe9edbe[_0x554701(0xc0)]||a20_0x4b1f82[_0x554701(0x8d)](_0x554701(0xb1)))),console['log'](_0x554701(0x9f)+(_0xe9edbe[_0x554701(0xcf)]||a20_0x4b1f82[_0x554701(0x8d)]('(none)'))),console[_0x554701(0xbc)](_0x554701(0x9b)+(_0xe9edbe[_0x554701(0xbd)]||a20_0x4b1f82['gray'](_0x554701(0xce)+DEFAULT_CONFIG_VALUES[_0x554701(0xbd)]+')'))),console[_0x554701(0xbc)](_0x554701(0xc9)+(_0xe9edbe[_0x554701(0xd0)]??a20_0x4b1f82[_0x554701(0x8d)](_0x554701(0xae)))),console[_0x554701(0xbc)](_0x554701(0x99)+_0xe9edbe[_0x554701(0x98)]),console[_0x554701(0xbc)](_0x554701(0xb8)+_0xe9edbe[_0x554701(0xa3)]),console[_0x554701(0xbc)](_0x554701(0xa9)+AUTH_MODE[_0x554701(0x9d)]),console['log'](_0x554701(0x90)+(_0xe9edbe[_0x554701(0xc5)]?a20_0x4b1f82[_0x554701(0x9e)](_0x554701(0xaf)+_0xe9edbe[_0x554701(0xc5)][_0x554701(0x96)]+')'):a20_0x4b1f82[_0x554701(0x8d)]('(none)'))),console[_0x554701(0xbc)](),console[_0x554701(0xbc)](a20_0x4b1f82['bold'](_0x554701(0xab))),console[_0x554701(0xbc)](a20_0x4b1f82[_0x554701(0x8d)]('\x20\x20─'[_0x554701(0xb6)](0x1e))),console[_0x554701(0xbc)](_0x554701(0x93)+getApiDomain()),console['log'](_0x554701(0xc8)+getUserDomain()),console[_0x554701(0xbc)](_0x554701(0xca)+getRuntimeDomain()),console[_0x554701(0xbc)](),console[_0x554701(0xbc)](a20_0x4b1f82['bold'](_0x554701(0x97))),console[_0x554701(0xbc)](a20_0x4b1f82[_0x554701(0x8d)]('\x20\x20─'[_0x554701(0xb6)](0x1e))),console[_0x554701(0xbc)](_0x554701(0xb0)+a20_0x4b1f82['green'](AUTH_MODE[_0x554701(0x9d)]+_0x554701(0x9a))),console[_0x554701(0xbc)](_0x554701(0x9c)+a20_0x4b1f82[_0x554701(0x8d)](_0x554701(0xc3))),console['log'](),{'ok':!![]};}function a20_0x2ac8(){const _0xab77c1=['\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20locale:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','yellow','verbose','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20(legacy/compat\x20only)','locale','8NazQSm','518325cLbbmo','\x20\x20auth\x20(effective):\x20','2012KOebcw','\x20\x20API\x20Endpoints','bold','1857XOetpq','(default)','(set,\x20length=','\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','(none)','Project','33346450RTvYIO','\x20\x20Merged\x20Config','Diagnose\x20CLI\x20configuration\x20and\x20environment','repeat','5741082dMPvdV','\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20','missing','\x20doctor','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','log','format','(no\x20file)','Global','defaultApp','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','\x20\x20Config\x20JSON','(removed\x20—\x20cookie\x20auth\x20disabled)','(not\x20found)','accessKey','\x20\x20Config\x20Files','\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20userDomain:\x20\x20\x20\x20\x20\x20','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20runtimeDomain:\x20\x20\x20','version','padEnd','message','(default:\x20','currentApp','pageSize','72BEpUvZ','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','doctor','env','✓\x20Valid\x20JSON','⚠\x20Empty\x20(treated\x20as\x20{})','1299480OixFEr','\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','493794HUiadz','gray','(not\x20set)','\x20\x20─','\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20','status','(missing)','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','581952KpQitl','red','length','\x20\x20Auth','riskLevel','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','\x20(accessKey)','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Session\x20check:\x20\x20\x20','ClientAk','green','\x20\x20currentApp:\x20\x20\x20\x20\x20\x20'];a20_0x2ac8=function(){return _0xab77c1;};return a20_0x2ac8();}export const doctorDefinition={'service':a20_0x47b162(0xd3),'command':'check','description':a20_0x47b162(0xb5),'risk':'read','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
1
+ const a20_0x3b3151=a20_0x238c;(function(_0x3b7c84,_0x4b6068){const _0x4b2a59=a20_0x238c,_0x4cd24d=_0x3b7c84();while(!![]){try{const _0x2b85e9=parseInt(_0x4b2a59(0xdc))/0x1+parseInt(_0x4b2a59(0xf4))/0x2*(parseInt(_0x4b2a59(0xd2))/0x3)+parseInt(_0x4b2a59(0xd8))/0x4*(parseInt(_0x4b2a59(0xdd))/0x5)+parseInt(_0x4b2a59(0xd1))/0x6*(parseInt(_0x4b2a59(0xdb))/0x7)+parseInt(_0x4b2a59(0x116))/0x8*(-parseInt(_0x4b2a59(0x109))/0x9)+-parseInt(_0x4b2a59(0x10c))/0xa*(parseInt(_0x4b2a59(0xf9))/0xb)+-parseInt(_0x4b2a59(0xe7))/0xc;if(_0x2b85e9===_0x4b6068)break;else _0x4cd24d['push'](_0x4cd24d['shift']());}catch(_0x153cf9){_0x4cd24d['push'](_0x4cd24d['shift']());}}}(a20_0x5a0d,0x93b56));import a20_0x58d8c8 from'chalk';import{CLI_BIN_NAME}from'../constant/cli.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{getCliVersion}from'../utils/version.js';function a20_0x5a0d(){const _0x304257=['repeat','(none)','\x20\x20riskLevel:\x20\x20\x20\x20\x20\x20\x20','log','verbose','26382wMtXVE','empty','env','\x20\x20Merged\x20Config','\x20\x20Config\x20JSON','11zcvWFU','\x20\x20Config\x20Files','doctor','\x20\x20API\x20Endpoints','(not\x20set)','✓\x20Valid\x20JSON','message','\x20\x20appCode:\x20\x20\x20\x20\x20\x20\x20\x20\x20','format','\x20\x20currentApp:\x20\x20\x20\x20\x20\x20','read','\x20\x20CLI\x20Version:\x20\x20\x20\x20\x20','gray','\x20\x20Session\x20check:\x20\x20\x20','\x20\x20runtimeDomain:\x20\x20\x20','\x20\x20defaultApp:\x20\x20\x20\x20\x20\x20','72270vPEPOI','currentApp','appCode','4186870JWlFkL','(not\x20found)','accessKey','(default)','\x20\x20Platform:\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20apiDomain:\x20\x20\x20\x20\x20\x20\x20','missing','locale','Global','\x20\x20auth\x20(effective):\x20','160OffOxe','\x20\x20env:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Project:\x20\x20\x20\x20\x20\x20\x20\x20\x20','\x20\x20Node:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','12UpoUVP','201iLxyxu','red','status','\x20\x20Global:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','(missing)','\x20doctor','2121124Ggblyj','\x20(legacy/compat\x20only)','⚠\x20Empty\x20(treated\x20as\x20{})','3082793MvlOrf','940844uQOSQa','5vbEPeI','padEnd','bold','\x20\x20format:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','platform','\x20\x20─','(set,\x20length=','\x20\x20userDomain:\x20\x20\x20\x20\x20\x20','ClientAk','\x20\x20locale:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20','24617028FIKntM','\x20\x20pageSize:\x20\x20\x20\x20\x20\x20\x20\x20','pageSize','\x20\x20accessKey:\x20\x20\x20\x20\x20\x20\x20','(no\x20file)','Project','\x20\x20Auth','green'];a20_0x5a0d=function(){return _0x304257;};return a20_0x5a0d();}import{getApiDomain,getRuntimeDomain,getUserDomain}from'../constant/domain.js';import{buildConfigFromFlags,initGlobalEnvironment,getProjectConfigPath,getGlobalConfigPath,inspectCliConfigJsonFile}from'../context.js';import{AUTH_MODE}from'../constant/auth-mode.js';import{isLegacyCompatConfigKey}from'../config/schema.js';async function execute(_0x50d7c8){const _0x5e7c9f=a20_0x238c,_0x50bc8a=getCliVersion(),_0x4569d8=buildConfigFromFlags({});await initGlobalEnvironment(_0x4569d8),console[_0x5e7c9f(0xf2)](),console['log'](a20_0x58d8c8[_0x5e7c9f(0xdf)](CLI_BIN_NAME+_0x5e7c9f(0xd7))),console['log'](a20_0x58d8c8[_0x5e7c9f(0x105)]('─'['repeat'](0x32))),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x104)+_0x50bc8a),console['log'](_0x5e7c9f(0xd0)+process['version']),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x110)+process[_0x5e7c9f(0xe1)]+'\x20'+process['arch']),console['log'](),console[_0x5e7c9f(0xf2)](a20_0x58d8c8['bold'](_0x5e7c9f(0xfa))),console['log'](a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0xe2)[_0x5e7c9f(0xef)](0x1e)));const _0x5566a0=getGlobalConfigPath(),_0x3dcca5=getProjectConfigPath();console[_0x5e7c9f(0xf2)](_0x5e7c9f(0xd5)+(_0x5566a0||a20_0x58d8c8['gray'](_0x5e7c9f(0x10d)))),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0xcf)+(_0x3dcca5||a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0x10d)))),console[_0x5e7c9f(0xf2)](),console[_0x5e7c9f(0xf2)](a20_0x58d8c8[_0x5e7c9f(0xdf)](_0x5e7c9f(0xf8))),console[_0x5e7c9f(0xf2)](a20_0x58d8c8[_0x5e7c9f(0x105)]('\x20\x20─'[_0x5e7c9f(0xef)](0x1e)));const _0x25a4b6=(_0x200023,_0x41ebf3)=>{const _0x267229=_0x5e7c9f;if(!_0x41ebf3){console[_0x267229(0xf2)]('\x20\x20'+_0x200023['padEnd'](0x11)+'\x20'+a20_0x58d8c8[_0x267229(0x105)](_0x267229(0xeb)));return;}const _0x3e164b=inspectCliConfigJsonFile(_0x41ebf3);if(_0x3e164b[_0x267229(0xd4)]==='ok')console[_0x267229(0xf2)]('\x20\x20'+_0x200023['padEnd'](0x11)+'\x20'+a20_0x58d8c8[_0x267229(0xee)](_0x267229(0xfe)));else{if(_0x3e164b[_0x267229(0xd4)]===_0x267229(0xf5))console[_0x267229(0xf2)]('\x20\x20'+_0x200023['padEnd'](0x11)+'\x20'+a20_0x58d8c8['yellow'](_0x267229(0xda)));else _0x3e164b[_0x267229(0xd4)]===_0x267229(0x112)?console[_0x267229(0xf2)]('\x20\x20'+_0x200023['padEnd'](0x11)+'\x20'+a20_0x58d8c8[_0x267229(0x105)](_0x267229(0xd6))):(console[_0x267229(0xf2)]('\x20\x20'+_0x200023[_0x267229(0xde)](0x11)+'\x20'+a20_0x58d8c8[_0x267229(0xd3)]('✗\x20Invalid\x20JSON')),console[_0x267229(0xf2)]('\x20\x20'+''[_0x267229(0xde)](0x11)+'\x20'+a20_0x58d8c8['red'](_0x3e164b[_0x267229(0xff)])));}};_0x25a4b6(_0x5e7c9f(0x114),_0x5566a0),_0x25a4b6(_0x5e7c9f(0xec),_0x3dcca5),console[_0x5e7c9f(0xf2)](),console[_0x5e7c9f(0xf2)](a20_0x58d8c8[_0x5e7c9f(0xdf)](_0x5e7c9f(0xf7))),console['log'](a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0xe2)[_0x5e7c9f(0xef)](0x1e))),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x100)+(_0x4569d8[_0x5e7c9f(0x10b)]||a20_0x58d8c8[_0x5e7c9f(0xd3)](_0x5e7c9f(0xfd)))),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x117)+_0x4569d8[_0x5e7c9f(0xf6)]);const _0x5f08cc=isLegacyCompatConfigKey(_0x5e7c9f(0x113))?a20_0x58d8c8['gray'](_0x4569d8[_0x5e7c9f(0x113)]+_0x5e7c9f(0xd9)):_0x4569d8[_0x5e7c9f(0x113)];return console[_0x5e7c9f(0xf2)](_0x5e7c9f(0xe6)+_0x5f08cc),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x108)+(_0x4569d8['defaultApp']||a20_0x58d8c8['gray'](_0x5e7c9f(0xf0)))),console['log'](_0x5e7c9f(0x102)+(_0x4569d8[_0x5e7c9f(0x10a)]||a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0xf0)))),console['log'](_0x5e7c9f(0xe0)+(_0x4569d8[_0x5e7c9f(0x101)]||a20_0x58d8c8[_0x5e7c9f(0x105)]('(default:\x20'+DEFAULT_CONFIG_VALUES[_0x5e7c9f(0x101)]+')'))),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0xe8)+(_0x4569d8[_0x5e7c9f(0xe9)]??a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0x10f)))),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0xf1)+_0x4569d8['riskLevel']),console[_0x5e7c9f(0xf2)]('\x20\x20verbose:\x20\x20\x20\x20\x20\x20\x20\x20\x20'+_0x4569d8[_0x5e7c9f(0xf3)]),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x115)+AUTH_MODE[_0x5e7c9f(0xe5)]),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0xea)+(_0x4569d8[_0x5e7c9f(0x10e)]?a20_0x58d8c8[_0x5e7c9f(0xee)](_0x5e7c9f(0xe3)+_0x4569d8[_0x5e7c9f(0x10e)]['length']+')'):a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0xf0)))),console[_0x5e7c9f(0xf2)](),console[_0x5e7c9f(0xf2)](a20_0x58d8c8[_0x5e7c9f(0xdf)](_0x5e7c9f(0xfc))),console['log'](a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0xe2)['repeat'](0x1e))),console['log'](_0x5e7c9f(0x111)+getApiDomain()),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0xe4)+getUserDomain()),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x107)+getRuntimeDomain()),console[_0x5e7c9f(0xf2)](),console[_0x5e7c9f(0xf2)](a20_0x58d8c8[_0x5e7c9f(0xdf)](_0x5e7c9f(0xed))),console[_0x5e7c9f(0xf2)](a20_0x58d8c8[_0x5e7c9f(0x105)](_0x5e7c9f(0xe2)[_0x5e7c9f(0xef)](0x1e))),console['log']('\x20\x20Mode:\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20'+a20_0x58d8c8['green'](AUTH_MODE[_0x5e7c9f(0xe5)]+'\x20(accessKey)')),console[_0x5e7c9f(0xf2)](_0x5e7c9f(0x106)+a20_0x58d8c8[_0x5e7c9f(0x105)]('(removed\x20—\x20cookie\x20auth\x20disabled)')),console[_0x5e7c9f(0xf2)](),{'ok':!![]};}function a20_0x238c(_0x59d9a9,_0x2d0961){_0x59d9a9=_0x59d9a9-0xcf;const _0x5a0dd2=a20_0x5a0d();let _0x238c9b=_0x5a0dd2[_0x59d9a9];return _0x238c9b;}export const doctorDefinition={'service':a20_0x3b3151(0xfb),'command':'check','description':'Diagnose\x20CLI\x20configuration\x20and\x20environment','risk':a20_0x3b3151(0x103),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],'execute':execute};
@@ -1 +1 @@
1
- const a21_0x478fda=a21_0xfd6c;(function(_0x47d74b,_0x364372){const _0x556385=a21_0xfd6c,_0x4215ae=_0x47d74b();while(!![]){try{const _0xd3be00=parseInt(_0x556385(0xe0))/0x1*(parseInt(_0x556385(0x103))/0x2)+-parseInt(_0x556385(0xd9))/0x3*(-parseInt(_0x556385(0x10b))/0x4)+parseInt(_0x556385(0x112))/0x5+parseInt(_0x556385(0x110))/0x6+-parseInt(_0x556385(0x108))/0x7*(parseInt(_0x556385(0x115))/0x8)+-parseInt(_0x556385(0x111))/0x9+parseInt(_0x556385(0xd8))/0xa*(-parseInt(_0x556385(0xec))/0xb);if(_0xd3be00===_0x364372)break;else _0x4215ae['push'](_0x4215ae['shift']());}catch(_0x297ed7){_0x4215ae['push'](_0x4215ae['shift']());}}}(a21_0x2180,0xbe736));import{existsSync,readFileSync}from'node:fs';import{resolve,isAbsolute}from'node:path';import{createInterface}from'node:readline';import{CliErrors}from'../errors.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../constant/env.js';import{IMPORTABLE_RUNTIME_CONFIG_KEYS}from'../config/schema.js';import{resolveWriteConfigPath,readConfigFile,writeConfigFile,isNonInteractiveMode}from'../context.js';import{CLI_BIN_NAME}from'../constant/cli.js';import{PRODUCT_CONFIG}from'../constant/product.js';export const initCreateFlagDefs=[{'name':a21_0x478fda(0xf1),'type':'string','description':a21_0x478fda(0x11c)},{'name':a21_0x478fda(0xdf),'type':a21_0x478fda(0xf3),'description':a21_0x478fda(0xe6)+DEFAULT_CONFIG_VALUES[a21_0x478fda(0xdf)]+')','enum':[...RUNTIME_ENV_VALUES]},{'name':a21_0x478fda(0xe4),'type':a21_0x478fda(0xfc),'description':a21_0x478fda(0x118)+PRODUCT_CONFIG[a21_0x478fda(0xd6)]+a21_0x478fda(0xda),'default':![]},{'name':a21_0x478fda(0x117),'type':'boolean','description':a21_0x478fda(0xf9),'default':![]}];export const initImportFlagDefs=[{'name':a21_0x478fda(0xd7),'type':a21_0x478fda(0xf3),'description':a21_0x478fda(0xf5),'required':!![]},{'name':a21_0x478fda(0xf1),'type':'string','description':a21_0x478fda(0xea)},{'name':a21_0x478fda(0xdf),'type':a21_0x478fda(0xf3),'description':a21_0x478fda(0x104),'enum':[...RUNTIME_ENV_VALUES]},{'name':a21_0x478fda(0xe4),'type':a21_0x478fda(0xfc),'description':a21_0x478fda(0x118)+PRODUCT_CONFIG[a21_0x478fda(0xd6)]+a21_0x478fda(0xda),'default':![]},{'name':'yes','type':a21_0x478fda(0xfc),'description':a21_0x478fda(0xf9),'default':![]}];export async function runInit(_0x30d95f){const _0x2e18c7=a21_0x478fda,_0x233fe7=isNonInteractiveMode(_0x30d95f),_0x5228a7=_0x30d95f[_0x2e18c7(0xe4)]?_0x2e18c7(0xe4):_0x2e18c7(0xdb),_0x4023a3=resolveWriteConfigPath(_0x5228a7);try{_0x233fe7?await runNonInteractive(_0x30d95f,_0x4023a3):await runInteractive(_0x30d95f,_0x4023a3);}catch(_0x44780c){if(_0x44780c instanceof AbortPrompt)throw CliErrors[_0x2e18c7(0x11a)]();throw _0x44780c;}}export async function runInitImport(_0x377ec4){const _0x409f5e=a21_0x478fda,_0x4ecd52=_0x377ec4['global']?_0x409f5e(0xe4):'project',_0x1bc5e8=resolveWriteConfigPath(_0x4ecd52);await runFromImport(_0x377ec4,_0x1bc5e8);}const RUNTIME_IRRELEVANT_KEYS=new Set(['apiDir']);async function runFromImport(_0x36c806,_0x5f2dfb){const _0x347879=a21_0x478fda,_0x40905a=resolveFilePath(_0x36c806['file']);if(!existsSync(_0x40905a))throw CliErrors[_0x347879(0x116)](_0x347879(0x101)+_0x40905a);const _0x1bef9c=readSourceFile(_0x40905a),_0x5161c2=convertToRuntimeConfig(_0x1bef9c);_0x36c806[_0x347879(0xf1)]&&(_0x5161c2[_0x347879(0xf1)]=String(_0x36c806[_0x347879(0xf1)]));_0x36c806[_0x347879(0xdf)]&&(_0x5161c2[_0x347879(0xdf)]=resolveInitEnv(_0x36c806));if(!_0x5161c2['appcode'])throw CliErrors[_0x347879(0x116)](_0x347879(0x113),_0x347879(0x10a));await writeInitConfig(_0x5f2dfb,_0x5161c2,_0x36c806),console[_0x347879(0xf6)]('Imported\x20from\x20'+_0x40905a),console[_0x347879(0xf6)](_0x347879(0xee)+_0x5f2dfb),console['log'](_0x347879(0x100)+_0x5161c2['appcode']);if(_0x5161c2[_0x347879(0x11b)])console[_0x347879(0xf6)](_0x347879(0xfd)+_0x5161c2[_0x347879(0x11b)]);}function convertToRuntimeConfig(_0x44fb78){const _0x26ee78=a21_0x478fda;if(_0x44fb78[_0x26ee78(0xef)]&&typeof _0x44fb78[_0x26ee78(0xef)]===_0x26ee78(0x10f))throw CliErrors[_0x26ee78(0x116)]('Legacy\x20/\x20multi-app\x20.rabetbase.json\x20is\x20no\x20longer\x20supported\x20for\x20import.','Run\x20`rabetbase\x20project\x20upgrade`\x20first,\x20then\x20retry\x20`lovrabet\x20app\x20import`.');const _0x234bf3={};for(const _0x1737c6 of IMPORTABLE_RUNTIME_CONFIG_KEYS){_0x44fb78[_0x1737c6]!==undefined&&(_0x234bf3[_0x1737c6]=_0x44fb78[_0x1737c6]);}return!_0x234bf3['riskLevel']&&(_0x234bf3[_0x26ee78(0xdc)]=DEFAULT_CONFIG_VALUES[_0x26ee78(0xdc)]),_0x234bf3;}async function runNonInteractive(_0xaa1ff7,_0x173827){const _0x554597=a21_0x478fda,_0xd05bb=_0xaa1ff7['appcode'];if(!_0xd05bb)throw CliErrors['flagMissing'](_0x554597(0xf1),_0x554597(0x10d)+CLI_BIN_NAME+'\x20app\x20init\x20--appcode\x20<code>\x20[--env\x20daily]\x20[--global]');const _0x274654=resolveInitEnv(_0xaa1ff7);await writeInitConfig(_0x173827,{'appcode':_0xd05bb,'env':_0x274654},_0xaa1ff7),console[_0x554597(0xf6)]('Initialized\x20'+_0x173827),console['log'](_0x554597(0x100)+_0xd05bb),console[_0x554597(0xf6)](_0x554597(0xff)+_0x274654);}function a21_0xfd6c(_0x2ef46e,_0x2a0e99){_0x2ef46e=_0x2ef46e-0xd6;const _0x2180b0=a21_0x2180();let _0xfd6ce4=_0x2180b0[_0x2ef46e];return _0xfd6ce4;}async function runInteractive(_0x37b379,_0x3f7d87){const _0x5a384f=a21_0x478fda,_0xd6c2a6=loadExisting(_0x3f7d87),_0x23b744=typeof _0xd6c2a6?.['appcode']===_0x5a384f(0xf3)?_0xd6c2a6[_0x5a384f(0xf1)]:'',_0x3fb439=resolveInitEnv(_0x37b379);console[_0x5a384f(0xf6)](CLI_BIN_NAME+_0x5a384f(0x107)+PRODUCT_CONFIG[_0x5a384f(0xd6)]+'\x0a');if(existsSync(_0x3f7d87)&&!_0x37b379[_0x5a384f(0x117)]){const _0x2ef231=await promptYesNo('File\x20'+_0x3f7d87+_0x5a384f(0xe8),![]);if(!_0x2ef231){console[_0x5a384f(0xf6)](_0x5a384f(0xe9));return;}}const _0x541632=typeof _0x37b379[_0x5a384f(0xf1)]==='string'?_0x37b379['appcode']['trim']():'';let _0x447aae=_0x541632;!_0x447aae&&(_0x447aae=await promptInput(_0x5a384f(0xf8),_0x23b744));if(!_0x447aae[_0x5a384f(0xe5)]())throw CliErrors[_0x5a384f(0x116)](_0x5a384f(0xdd));await writeInitConfig(_0x3f7d87,{'appcode':_0x447aae[_0x5a384f(0xe5)](),'env':_0x3fb439},_0x37b379),console[_0x5a384f(0xf6)](_0x5a384f(0xf0)+_0x3f7d87),console[_0x5a384f(0xf6)](_0x5a384f(0x100)+_0x447aae[_0x5a384f(0xe5)]()),console['log']('\x20\x20env:\x20\x20\x20\x20\x20'+_0x3fb439);}function a21_0x2180(){const _0x1f626d=['7968sAaNpJ','validation','yes','Write\x20to\x20global\x20(~/','includes','cancelled','defaultApp','App\x20code\x20for\x20the\x20project','newConfigFileName','file','10wHWrRs','3kbOcDt',')\x20instead\x20of\x20project','project','riskLevel','App\x20code\x20cannot\x20be\x20empty.','stdin','env','368249hQOdyG','removeListener','cwd','SIGINT','global','trim','Target\x20environment\x20(default\x20','parse','\x20already\x20exists.\x20Overwrite?','Aborted.','Override\x20imported\x20default\x20appcode','Failed\x20to\x20parse\x20source\x20file:\x20','13372843QsJBBL','Invalid\x20env\x20\x22','\x20\x20config:\x20\x20','apps','\x0aInitialized\x20','appcode','toLowerCase','string','once','Import\x20from\x20a\x20.rabetbase.json\x20file\x20path','log','close','App\x20code','Skip\x20confirmation\x20when\x20overwriting','name','question','boolean','\x20\x20default:\x20','entries','\x20\x20env:\x20\x20\x20\x20\x20','\x20\x20appcode:\x20','Source\x20file\x20not\x20found:\x20','utf8','6yqNdzj','Override\x20imported\x20default\x20env','app','[y/N]','\x20init\x20—\x20Create\x20','9191DpqIyU','[Y/n]','Provide\x20--appcode\x20<code>\x20or\x20use\x20an\x20upgraded\x20.rabetbase.json\x20with\x20top-level\x20appcode.\x20Legacy\x20files\x20must\x20be\x20upgraded\x20first\x20with\x20`rabetbase\x20project\x20upgrade`.','2906216RBEoNS','stdout','Usage:\x20','message','object','5954148jSjuLj','3586941FpBVEI','4392185fgMEJv','Source\x20file\x20does\x20not\x20contain\x20an\x20importable\x20appcode.','):\x20'];a21_0x2180=function(){return _0x1f626d;};return a21_0x2180();}async function writeInitConfig(_0x1b49e3,_0x3fd89a,_0x35bdb5){const _0x138063=a21_0x478fda;let _0x3535c5={};existsSync(_0x1b49e3)&&!_0x35bdb5['yes']&&(_0x3535c5=readConfigFile(_0x1b49e3));for(const [_0x3fc1cf,_0x21cbc7]of Object[_0x138063(0xfe)](_0x3fd89a)){_0x21cbc7!==undefined&&(_0x3535c5[_0x3fc1cf]=_0x21cbc7);}if(_0x3535c5[_0x138063(0x105)])delete _0x3535c5[_0x138063(0x105)];writeConfigFile(_0x1b49e3,_0x3535c5);}class AbortPrompt extends Error{constructor(){const _0x590c71=a21_0x478fda;super('User\x20aborted\x20prompt'),this[_0x590c71(0xfa)]='AbortPrompt';}}function createSafeRl(){const _0x161523=a21_0x478fda,_0x53efb6=createInterface({'input':process[_0x161523(0xde)],'output':process[_0x161523(0x10c)]});let _0x32a631;const _0x265704=new Promise((_0x1bb6a7,_0x346863)=>{const _0x3c9838=_0x161523;_0x32a631=()=>{const _0x5d7c5d=a21_0xfd6c;_0x32a631&&(_0x53efb6[_0x5d7c5d(0xe1)](_0x5d7c5d(0xe3),_0x32a631),_0x32a631=undefined);try{_0x53efb6[_0x5d7c5d(0xf7)]();}catch{}_0x346863(new AbortPrompt());},_0x53efb6[_0x3c9838(0xf4)]('SIGINT',_0x32a631);}),_0x4da660=()=>{const _0x32ad7a=_0x161523;_0x32a631&&(_0x53efb6['removeListener'](_0x32ad7a(0xe3),_0x32a631),_0x32a631=undefined);try{_0x53efb6[_0x32ad7a(0xf7)]();}catch{}};return{'rl':_0x53efb6,'abortPromise':_0x265704,'disposeSuccess':_0x4da660};}async function promptInput(_0x5a93e7,_0x28abbb){const {rl:_0x46de9f,abortPromise:_0x2677d8,disposeSuccess:_0x361676}=createSafeRl(),_0x451f66=new Promise(_0x4376ba=>{const _0x554c2c=a21_0xfd6c,_0x33cc80=_0x28abbb?'\x20\x20'+_0x5a93e7+'\x20('+_0x28abbb+_0x554c2c(0x114):'\x20\x20'+_0x5a93e7+':\x20';_0x46de9f[_0x554c2c(0xfb)](_0x33cc80,_0x275782=>{_0x361676(),_0x4376ba(_0x275782['trim']()||_0x28abbb);});});return Promise['race']([_0x451f66,_0x2677d8]);}async function promptYesNo(_0x7d7c60,_0xbf71fe){const {rl:_0x5e8476,abortPromise:_0x13c072,disposeSuccess:_0x4608f5}=createSafeRl(),_0x2f4ea7=new Promise(_0x442ce5=>{const _0x2cb14b=a21_0xfd6c,_0x1318a9=_0xbf71fe?_0x2cb14b(0x109):_0x2cb14b(0x106);_0x5e8476[_0x2cb14b(0xfb)]('\x20\x20'+_0x7d7c60+'\x20'+_0x1318a9+':\x20',_0x1fd15a=>{const _0x1e1db6=_0x2cb14b;_0x4608f5();const _0x328db1=_0x1fd15a[_0x1e1db6(0xe5)]()[_0x1e1db6(0xf2)]();if(_0x328db1==='y'||_0x328db1===_0x1e1db6(0x117))_0x442ce5(!![]);else{if(_0x328db1==='n'||_0x328db1==='no')_0x442ce5(![]);else _0x442ce5(_0xbf71fe);}});});return Promise['race']([_0x2f4ea7,_0x13c072]);}function loadExisting(_0x29ae64){if(!existsSync(_0x29ae64))return null;return readConfigFile(_0x29ae64);}function resolveFilePath(_0x2cd26e){const _0x22a45d=a21_0x478fda;return isAbsolute(_0x2cd26e)?_0x2cd26e:resolve(process[_0x22a45d(0xe2)](),_0x2cd26e);}function readSourceFile(_0x57c694){const _0x12e9e2=a21_0x478fda;try{const _0x43a84b=readFileSync(_0x57c694,{'encoding':_0x12e9e2(0x102)});return JSON[_0x12e9e2(0xe7)](_0x43a84b);}catch(_0x42f1e3){throw CliErrors[_0x12e9e2(0x116)](_0x12e9e2(0xeb)+_0x42f1e3[_0x12e9e2(0x10e)]);}}function resolveInitEnv(_0x53cf05){const _0x5463cb=a21_0x478fda,_0x47a430=_0x53cf05[_0x5463cb(0xdf)];if(_0x47a430===undefined||_0x47a430==='')return DEFAULT_CONFIG_VALUES[_0x5463cb(0xdf)];if(!RUNTIME_ENV_VALUES[_0x5463cb(0x119)](_0x47a430))throw CliErrors[_0x5463cb(0x116)](_0x5463cb(0xed)+_0x47a430+'\x22.\x20Allowed:\x20'+RUNTIME_ENV_VALUES['join'](',\x20'));return _0x47a430;}
1
+ const a21_0x24d3f4=a21_0x2cae;(function(_0x4c380b,_0x252de6){const _0x3008bc=a21_0x2cae,_0x4a15e8=_0x4c380b();while(!![]){try{const _0x3da32c=parseInt(_0x3008bc(0x106))/0x1*(parseInt(_0x3008bc(0x104))/0x2)+parseInt(_0x3008bc(0xf5))/0x3*(-parseInt(_0x3008bc(0x12e))/0x4)+parseInt(_0x3008bc(0x109))/0x5+-parseInt(_0x3008bc(0x107))/0x6*(-parseInt(_0x3008bc(0x10e))/0x7)+parseInt(_0x3008bc(0x11b))/0x8*(-parseInt(_0x3008bc(0xef))/0x9)+-parseInt(_0x3008bc(0x12c))/0xa*(-parseInt(_0x3008bc(0xfe))/0xb)+parseInt(_0x3008bc(0x12d))/0xc*(parseInt(_0x3008bc(0x120))/0xd);if(_0x3da32c===_0x252de6)break;else _0x4a15e8['push'](_0x4a15e8['shift']());}catch(_0x3eae13){_0x4a15e8['push'](_0x4a15e8['shift']());}}}(a21_0xec52,0xea491));function a21_0xec52(){const _0x5ebd41=['project','once','string','\x20\x20default:\x20','appcode','newConfigFileName','boolean','Invalid\x20env\x20\x22','416581SHVyAr','Write\x20to\x20global\x20(~/','apps','User\x20aborted\x20prompt','riskLevel','stdin','10zAAyoj','Legacy\x20/\x20multi-app\x20.rabetbase.json\x20is\x20no\x20longer\x20supported\x20for\x20import.','218301ifFURM','9798WXZPcd','toLowerCase','521985urlRxc','global','log','yes','join','3962wyScgW','\x22.\x20Allowed:\x20','defaultApp','app','[Y/n]','\x0aInitialized\x20','Source\x20file\x20does\x20not\x20contain\x20an\x20importable\x20appcode.','):\x20','Source\x20file\x20not\x20found:\x20','AbortPrompt',')\x20instead\x20of\x20project','App\x20code\x20cannot\x20be\x20empty.','Failed\x20to\x20parse\x20source\x20file:\x20','31576VwxRiA','Provide\x20--appcode\x20<code>\x20or\x20use\x20an\x20upgraded\x20.rabetbase.json\x20with\x20top-level\x20appcode.\x20Legacy\x20files\x20must\x20be\x20upgraded\x20first\x20with\x20`rabetbase\x20project\x20upgrade`.','App\x20code','file','Imported\x20from\x20','3855007vTvHQB','race','entries','Initialized\x20','Import\x20from\x20a\x20.rabetbase.json\x20file\x20path','trim','question','\x20\x20env:\x20\x20\x20\x20\x20','name','stdout','cancelled','File\x20','60KVNeTd','12MrhLGZ','1648uEulqJ','validation','Skip\x20confirmation\x20when\x20overwriting','removeListener','env','object','cwd','Override\x20imported\x20default\x20appcode','\x20\x20config:\x20\x20','1476uYLEBT','\x20app\x20init\x20--appcode\x20<code>\x20[--env\x20daily]\x20[--global]','includes','close','SIGINT','\x20\x20appcode:\x20','7551xhvqiA'];a21_0xec52=function(){return _0x5ebd41;};return a21_0xec52();}import{existsSync,readFileSync}from'node:fs';import{resolve,isAbsolute}from'node:path';import{createInterface}from'node:readline';import{CliErrors}from'../errors.js';import{DEFAULT_CONFIG_VALUES}from'../constant/defaults.js';import{RUNTIME_ENV_VALUES}from'../constant/env.js';import{IMPORTABLE_RUNTIME_CONFIG_KEYS}from'../config/schema.js';import{resolveWriteConfigPath,readConfigFile,writeConfigFile,isNonInteractiveMode}from'../context.js';import{CLI_BIN_NAME}from'../constant/cli.js';import{PRODUCT_CONFIG}from'../constant/product.js';export const initCreateFlagDefs=[{'name':a21_0x24d3f4(0xfa),'type':a21_0x24d3f4(0xf8),'description':'App\x20code\x20for\x20the\x20project'},{'name':a21_0x24d3f4(0x132),'type':a21_0x24d3f4(0xf8),'description':'Target\x20environment\x20(default\x20'+DEFAULT_CONFIG_VALUES['env']+')','enum':[...RUNTIME_ENV_VALUES]},{'name':'global','type':a21_0x24d3f4(0xfc),'description':a21_0x24d3f4(0xff)+PRODUCT_CONFIG[a21_0x24d3f4(0xfb)]+a21_0x24d3f4(0x118),'default':![]},{'name':a21_0x24d3f4(0x10c),'type':a21_0x24d3f4(0xfc),'description':a21_0x24d3f4(0x130),'default':![]}];export const initImportFlagDefs=[{'name':a21_0x24d3f4(0x11e),'type':a21_0x24d3f4(0xf8),'description':a21_0x24d3f4(0x124),'required':!![]},{'name':a21_0x24d3f4(0xfa),'type':a21_0x24d3f4(0xf8),'description':a21_0x24d3f4(0xed)},{'name':a21_0x24d3f4(0x132),'type':'string','description':'Override\x20imported\x20default\x20env','enum':[...RUNTIME_ENV_VALUES]},{'name':a21_0x24d3f4(0x10a),'type':a21_0x24d3f4(0xfc),'description':'Write\x20to\x20global\x20(~/'+PRODUCT_CONFIG['newConfigFileName']+a21_0x24d3f4(0x118),'default':![]},{'name':'yes','type':a21_0x24d3f4(0xfc),'description':a21_0x24d3f4(0x130),'default':![]}];export async function runInit(_0x323b86){const _0xb311e2=a21_0x24d3f4,_0x2255a7=isNonInteractiveMode(_0x323b86),_0xe584c8=_0x323b86['global']?_0xb311e2(0x10a):_0xb311e2(0xf6),_0x1cc656=resolveWriteConfigPath(_0xe584c8);try{_0x2255a7?await runNonInteractive(_0x323b86,_0x1cc656):await runInteractive(_0x323b86,_0x1cc656);}catch(_0x3de886){if(_0x3de886 instanceof AbortPrompt)throw CliErrors[_0xb311e2(0x12a)]();throw _0x3de886;}}export async function runInitImport(_0x538880){const _0x53f69b=a21_0x24d3f4,_0x4d699f=_0x538880[_0x53f69b(0x10a)]?_0x53f69b(0x10a):_0x53f69b(0xf6),_0x15c5b1=resolveWriteConfigPath(_0x4d699f);await runFromImport(_0x538880,_0x15c5b1);}const RUNTIME_IRRELEVANT_KEYS=new Set(['apiDir']);async function runFromImport(_0x5a3c88,_0x19c4af){const _0xa1d4b9=a21_0x24d3f4,_0x10bd41=resolveFilePath(_0x5a3c88[_0xa1d4b9(0x11e)]);if(!existsSync(_0x10bd41))throw CliErrors['validation'](_0xa1d4b9(0x116)+_0x10bd41);const _0x2ad90c=readSourceFile(_0x10bd41),_0x222632=convertToRuntimeConfig(_0x2ad90c);_0x5a3c88[_0xa1d4b9(0xfa)]&&(_0x222632['appcode']=String(_0x5a3c88['appcode']));_0x5a3c88[_0xa1d4b9(0x132)]&&(_0x222632[_0xa1d4b9(0x132)]=resolveInitEnv(_0x5a3c88));if(!_0x222632[_0xa1d4b9(0xfa)])throw CliErrors[_0xa1d4b9(0x12f)](_0xa1d4b9(0x114),_0xa1d4b9(0x11c));await writeInitConfig(_0x19c4af,_0x222632,_0x5a3c88),console[_0xa1d4b9(0x10b)](_0xa1d4b9(0x11f)+_0x10bd41),console['log'](_0xa1d4b9(0xee)+_0x19c4af),console['log']('\x20\x20appcode:\x20'+_0x222632[_0xa1d4b9(0xfa)]);if(_0x222632['defaultApp'])console[_0xa1d4b9(0x10b)](_0xa1d4b9(0xf9)+_0x222632[_0xa1d4b9(0x110)]);}function convertToRuntimeConfig(_0x35d360){const _0x842e75=a21_0x24d3f4;if(_0x35d360['apps']&&typeof _0x35d360[_0x842e75(0x100)]===_0x842e75(0x133))throw CliErrors[_0x842e75(0x12f)](_0x842e75(0x105),'Run\x20`rabetbase\x20project\x20upgrade`\x20first,\x20then\x20retry\x20`lovrabet\x20app\x20import`.');const _0x2b6183={};for(const _0x2539b9 of IMPORTABLE_RUNTIME_CONFIG_KEYS){_0x35d360[_0x2539b9]!==undefined&&(_0x2b6183[_0x2539b9]=_0x35d360[_0x2539b9]);}return!_0x2b6183['riskLevel']&&(_0x2b6183['riskLevel']=DEFAULT_CONFIG_VALUES[_0x842e75(0x102)]),_0x2b6183;}async function runNonInteractive(_0x1745c9,_0x118249){const _0x426f45=a21_0x24d3f4,_0x526d40=_0x1745c9[_0x426f45(0xfa)];if(!_0x526d40)throw CliErrors['flagMissing'](_0x426f45(0xfa),'Usage:\x20'+CLI_BIN_NAME+_0x426f45(0xf0));const _0x33b5ce=resolveInitEnv(_0x1745c9);await writeInitConfig(_0x118249,{'appcode':_0x526d40,'env':_0x33b5ce},_0x1745c9),console[_0x426f45(0x10b)](_0x426f45(0x123)+_0x118249),console[_0x426f45(0x10b)](_0x426f45(0xf4)+_0x526d40),console[_0x426f45(0x10b)](_0x426f45(0x127)+_0x33b5ce);}async function runInteractive(_0x50c16a,_0x244c96){const _0xc22a7=a21_0x24d3f4,_0x46bfcd=loadExisting(_0x244c96),_0x43a6fa=typeof _0x46bfcd?.[_0xc22a7(0xfa)]===_0xc22a7(0xf8)?_0x46bfcd['appcode']:'',_0x668940=resolveInitEnv(_0x50c16a);console['log'](CLI_BIN_NAME+'\x20init\x20—\x20Create\x20'+PRODUCT_CONFIG[_0xc22a7(0xfb)]+'\x0a');if(existsSync(_0x244c96)&&!_0x50c16a[_0xc22a7(0x10c)]){const _0x418698=await promptYesNo(_0xc22a7(0x12b)+_0x244c96+'\x20already\x20exists.\x20Overwrite?',![]);if(!_0x418698){console['log']('Aborted.');return;}}const _0x490c4a=typeof _0x50c16a[_0xc22a7(0xfa)]===_0xc22a7(0xf8)?_0x50c16a[_0xc22a7(0xfa)]['trim']():'';let _0x18daf7=_0x490c4a;!_0x18daf7&&(_0x18daf7=await promptInput(_0xc22a7(0x11d),_0x43a6fa));if(!_0x18daf7[_0xc22a7(0x125)]())throw CliErrors[_0xc22a7(0x12f)](_0xc22a7(0x119));await writeInitConfig(_0x244c96,{'appcode':_0x18daf7[_0xc22a7(0x125)](),'env':_0x668940},_0x50c16a),console[_0xc22a7(0x10b)](_0xc22a7(0x113)+_0x244c96),console[_0xc22a7(0x10b)](_0xc22a7(0xf4)+_0x18daf7[_0xc22a7(0x125)]()),console['log']('\x20\x20env:\x20\x20\x20\x20\x20'+_0x668940);}async function writeInitConfig(_0x3f6fc1,_0x540104,_0x19dd3e){const _0x2aec05=a21_0x24d3f4;let _0x50abe4={};existsSync(_0x3f6fc1)&&!_0x19dd3e[_0x2aec05(0x10c)]&&(_0x50abe4=readConfigFile(_0x3f6fc1));for(const [_0x1303aa,_0x44efc9]of Object[_0x2aec05(0x122)](_0x540104)){_0x44efc9!==undefined&&(_0x50abe4[_0x1303aa]=_0x44efc9);}if(_0x50abe4['app'])delete _0x50abe4[_0x2aec05(0x111)];writeConfigFile(_0x3f6fc1,_0x50abe4);}class AbortPrompt extends Error{constructor(){const _0x29852c=a21_0x24d3f4;super(_0x29852c(0x101)),this[_0x29852c(0x128)]=_0x29852c(0x117);}}function createSafeRl(){const _0x4ce388=a21_0x24d3f4,_0x1618fc=createInterface({'input':process[_0x4ce388(0x103)],'output':process[_0x4ce388(0x129)]});let _0x224739;const _0xf06209=new Promise((_0x4bb8fd,_0x5b3f73)=>{const _0x3f952c=_0x4ce388;_0x224739=()=>{const _0x2b780b=a21_0x2cae;_0x224739&&(_0x1618fc['removeListener'](_0x2b780b(0xf3),_0x224739),_0x224739=undefined);try{_0x1618fc[_0x2b780b(0xf2)]();}catch{}_0x5b3f73(new AbortPrompt());},_0x1618fc[_0x3f952c(0xf7)](_0x3f952c(0xf3),_0x224739);}),_0x1ffa9e=()=>{const _0x5e2fff=_0x4ce388;_0x224739&&(_0x1618fc[_0x5e2fff(0x131)](_0x5e2fff(0xf3),_0x224739),_0x224739=undefined);try{_0x1618fc['close']();}catch{}};return{'rl':_0x1618fc,'abortPromise':_0xf06209,'disposeSuccess':_0x1ffa9e};}async function promptInput(_0x57b25b,_0x24d039){const _0x1ff025=a21_0x24d3f4,{rl:_0x5b44f5,abortPromise:_0x36fb3f,disposeSuccess:_0x2fd7cd}=createSafeRl(),_0x3c18ff=new Promise(_0x36e147=>{const _0x4db67a=a21_0x2cae,_0xeeefc9=_0x24d039?'\x20\x20'+_0x57b25b+'\x20('+_0x24d039+_0x4db67a(0x115):'\x20\x20'+_0x57b25b+':\x20';_0x5b44f5[_0x4db67a(0x126)](_0xeeefc9,_0x47805f=>{const _0x53cc34=_0x4db67a;_0x2fd7cd(),_0x36e147(_0x47805f[_0x53cc34(0x125)]()||_0x24d039);});});return Promise[_0x1ff025(0x121)]([_0x3c18ff,_0x36fb3f]);}function a21_0x2cae(_0x3f1ec5,_0x4d5a00){_0x3f1ec5=_0x3f1ec5-0xec;const _0xec521b=a21_0xec52();let _0x2cae03=_0xec521b[_0x3f1ec5];return _0x2cae03;}async function promptYesNo(_0x14f754,_0x3a32fc){const _0x3dc31e=a21_0x24d3f4,{rl:_0x50580a,abortPromise:_0x899664,disposeSuccess:_0xe31dc0}=createSafeRl(),_0x3bef58=new Promise(_0x526f38=>{const _0x4df40b=a21_0x2cae,_0x48294c=_0x3a32fc?_0x4df40b(0x112):'[y/N]';_0x50580a[_0x4df40b(0x126)]('\x20\x20'+_0x14f754+'\x20'+_0x48294c+':\x20',_0x197abf=>{const _0xa75add=_0x4df40b;_0xe31dc0();const _0x1519c7=_0x197abf[_0xa75add(0x125)]()[_0xa75add(0x108)]();if(_0x1519c7==='y'||_0x1519c7===_0xa75add(0x10c))_0x526f38(!![]);else{if(_0x1519c7==='n'||_0x1519c7==='no')_0x526f38(![]);else _0x526f38(_0x3a32fc);}});});return Promise[_0x3dc31e(0x121)]([_0x3bef58,_0x899664]);}function loadExisting(_0x408d10){if(!existsSync(_0x408d10))return null;return readConfigFile(_0x408d10);}function resolveFilePath(_0x5b1842){const _0x354d7c=a21_0x24d3f4;return isAbsolute(_0x5b1842)?_0x5b1842:resolve(process[_0x354d7c(0xec)](),_0x5b1842);}function readSourceFile(_0x5bb3d5){const _0x48cfee=a21_0x24d3f4;try{const _0x3145fa=readFileSync(_0x5bb3d5,{'encoding':'utf8'});return JSON['parse'](_0x3145fa);}catch(_0x5715d9){throw CliErrors['validation'](_0x48cfee(0x11a)+_0x5715d9['message']);}}function resolveInitEnv(_0x532fe7){const _0x2e25df=a21_0x24d3f4,_0x45030d=_0x532fe7[_0x2e25df(0x132)];if(_0x45030d===undefined||_0x45030d==='')return DEFAULT_CONFIG_VALUES['env'];if(!RUNTIME_ENV_VALUES[_0x2e25df(0xf1)](_0x45030d))throw CliErrors['validation'](_0x2e25df(0xfd)+_0x45030d+_0x2e25df(0x10f)+RUNTIME_ENV_VALUES[_0x2e25df(0x10d)](',\x20'));return _0x45030d;}
@@ -0,0 +1 @@
1
+ function a22_0x3547(){const _0x1531ef=['appCode','List\x20personal\x20knowledge-base\x20entries\x20for\x20the\x20current\x20app','1090golUPz','--topk\x20must\x20be\x20a\x20positive\x20number.','trim','isFinite','Create\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','map','file','detail','165txXXMz','1101898QyawSe','create','Path\x20to\x20a\x20local\x20UTF-8\x20text\x20or\x20Markdown\x20file','flag','verbose','1859763dEDLSH','2540625ODNerq','score','4suKkrZ','build','/client/knowledge-base/personal/','ragStatus','Update\x20a\x20personal\x20knowledge-base\x20entry\x20from\x20a\x20local\x20file','POST','query','content','title','Maximum\x20number\x20of\x20search\x20hits\x20to\x20return','ragErrorMessage','21564JhWYjC','Preview:\x20create\x20personal\x20knowledge-base\x20entry\x20\x22','2TratwZ','userId','weightedScore','4866582aOAOwm','Created\x20KB\x20entry\x20','topk','validation','File\x20path\x20is\x20required.','length','docId','list','number','num','Personal\x20knowledge-base\x20entry\x20title','Personal\x20knowledge-base\x20entry\x20ID','/update','write','read','/client/knowledge-base/personal/create','File\x20not\x20found:\x20','Search\x20visible\x20company\x20and\x20personal\x20knowledge\x20base\x20content','480696KPnNjZ','Override\x20the\x20existing\x20entry\x20title','body','Preview:\x20update\x20personal\x20knowledge-base\x20entry\x20','updateTime','415709byCSMg','string','File\x20is\x20not\x20a\x20regular\x20file:\x20','Show\x20one\x20personal\x20knowledge-base\x20entry\x20by\x20id','16wSZHyO','description','str','Updated\x20KB\x20entry\x20','isFile','scope'];a22_0x3547=function(){return _0x1531ef;};return a22_0x3547();}const a22_0x435563=a22_0x3cef;(function(_0x38de91,_0x34cf6e){const _0x312b6f=a22_0x3cef,_0x1b811c=_0x38de91();while(!![]){try{const _0x595c5f=-parseInt(_0x312b6f(0x208))/0x1*(-parseInt(_0x312b6f(0x1ee))/0x2)+-parseInt(_0x312b6f(0x1de))/0x3*(parseInt(_0x312b6f(0x1e1))/0x4)+parseInt(_0x312b6f(0x1df))/0x5+parseInt(_0x312b6f(0x1f1))/0x6+-parseInt(_0x312b6f(0x1d9))/0x7*(parseInt(_0x312b6f(0x20c))/0x8)+parseInt(_0x312b6f(0x1ec))/0x9*(parseInt(_0x312b6f(0x1d0))/0xa)+-parseInt(_0x312b6f(0x1d8))/0xb*(parseInt(_0x312b6f(0x203))/0xc);if(_0x595c5f===_0x34cf6e)break;else _0x1b811c['push'](_0x1b811c['shift']());}catch(_0x4950ee){_0x1b811c['push'](_0x1b811c['shift']());}}}(a22_0x3547,0x706bc));import{existsSync,readFileSync,statSync}from'node:fs';import{createPersonalKnowledgeBaseItem,getPersonalKnowledgeBaseItem,listPersonalKnowledgeBaseItems,searchKnowledgeBase,updatePersonalKnowledgeBaseItem}from'../../core/api-client.js';import{ID_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';import{CliErrors}from'../../errors.js';import{dryRun}from'../../framework/dryrun.js';const TITLE_FLAG={'name':a22_0x435563(0x1e9),'type':a22_0x435563(0x209),'required':!![],'description':a22_0x435563(0x1fb)},FILE_FLAG={'name':'file','type':a22_0x435563(0x209),'required':!![],'description':a22_0x435563(0x1db)},QUERY_FLAG={'name':a22_0x435563(0x1e7),'type':a22_0x435563(0x209),'required':!![],'description':'Search\x20query\x20for\x20visible\x20company\x20and\x20personal\x20knowledge'},TOPK_FLAG={'name':'topk','type':a22_0x435563(0x1f9),'description':a22_0x435563(0x1ea)};function a22_0x3cef(_0x27f9a2,_0x3c4209){_0x27f9a2=_0x27f9a2-0x1cd;const _0x3547cb=a22_0x3547();let _0x3cefb9=_0x3547cb[_0x27f9a2];return _0x3cefb9;}function readKnowledgeFile(_0x5971ca){const _0x58986e=a22_0x435563;if(!_0x5971ca)throw CliErrors[_0x58986e(0x1f4)](_0x58986e(0x1f5));if(!existsSync(_0x5971ca))throw CliErrors[_0x58986e(0x1f4)](_0x58986e(0x201)+_0x5971ca);if(!statSync(_0x5971ca)[_0x58986e(0x210)]())throw CliErrors[_0x58986e(0x1f4)](_0x58986e(0x20a)+_0x5971ca);return readFileSync(_0x5971ca,'utf8');}function summarizePersonalItem(_0xd342d3){const _0x29c317=a22_0x435563;return{'id':_0xd342d3['id'],'title':_0xd342d3[_0x29c317(0x1e9)],'version':_0xd342d3['version'],'ragStatus':_0xd342d3[_0x29c317(0x1e4)],'ragErrorMessage':_0xd342d3[_0x29c317(0x1eb)],'updateTime':_0xd342d3[_0x29c317(0x207)]};}function detailPersonalItem(_0x5615d8){const _0x5ef91d=a22_0x435563;return{'id':_0x5615d8['id'],'appCode':_0x5615d8[_0x5ef91d(0x1ce)],'scope':_0x5615d8[_0x5ef91d(0x1cd)],'userId':_0x5615d8[_0x5ef91d(0x1ef)],'title':_0x5615d8[_0x5ef91d(0x1e9)],'content':_0x5615d8[_0x5ef91d(0x1e8)]??'','version':_0x5615d8['version'],'ragStatus':_0x5615d8['ragStatus'],'ragErrorMessage':_0x5615d8[_0x5ef91d(0x1eb)],'createTime':_0x5615d8['createTime'],'updateTime':_0x5615d8[_0x5ef91d(0x207)]};}function summarizeSearchHit(_0x6d1477){const _0x3ab469=a22_0x435563;return{'scope':_0x6d1477['scope'],'docId':_0x6d1477[_0x3ab469(0x1f7)],'score':_0x6d1477[_0x3ab469(0x1e0)],'weightedScore':_0x6d1477[_0x3ab469(0x1f0)],'content':_0x6d1477[_0x3ab469(0x1e8)],'metadata':_0x6d1477['metadata']};}function readTopK(_0x369243){const _0x59d1be=a22_0x435563,_0x169110=_0x369243[_0x59d1be(0x1dc)](_0x59d1be(0x1f3));if(_0x169110===undefined||_0x169110===null||_0x169110==='')return undefined;const _0x1c546a=_0x369243['num'](_0x59d1be(0x1f3));if(!Number[_0x59d1be(0x1d3)](_0x1c546a)||_0x1c546a<0x1)throw CliErrors[_0x59d1be(0x1f4)](_0x59d1be(0x1d1));return _0x1c546a;}const kbList={'service':'kb','command':a22_0x435563(0x1f8),'description':a22_0x435563(0x1cf),'risk':a22_0x435563(0x1ff),'flags':[VERBOSE_FLAG],async 'execute'(_0x3f7774){const _0x57f0b0=a22_0x435563,_0x679526=await listPersonalKnowledgeBaseItems(_0x3f7774[_0x57f0b0(0x1ce)]);if(_0x3f7774['bool'](_0x57f0b0(0x1dd)))return{'ok':!![],'data':{'total':_0x679526[_0x57f0b0(0x1f6)],'items':_0x679526}};return{'ok':!![],'data':{'total':_0x679526[_0x57f0b0(0x1f6)],'items':_0x679526[_0x57f0b0(0x1d5)](summarizePersonalItem)}};}},kbDetail={'service':'kb','command':a22_0x435563(0x1d7),'description':a22_0x435563(0x20b),'risk':'read','flags':[{...ID_FLAG,'description':'Personal\x20knowledge-base\x20entry\x20ID'}],async 'execute'(_0x2c93c8){const _0x2b3af6=a22_0x435563,_0x27f6c5=await getPersonalKnowledgeBaseItem(_0x2c93c8['num']('id'),_0x2c93c8[_0x2b3af6(0x1ce)]);return{'ok':!![],'data':detailPersonalItem(_0x27f6c5)};}},kbCreate={'service':'kb','command':a22_0x435563(0x1da),'description':a22_0x435563(0x1d4),'risk':a22_0x435563(0x1fe),'flags':[TITLE_FLAG,FILE_FLAG],async 'execute'(_0x996513){const _0x548ff6=a22_0x435563,_0x49d906=_0x996513[_0x548ff6(0x20e)]('title'),_0x1317dc=readKnowledgeFile(_0x996513[_0x548ff6(0x20e)](_0x548ff6(0x1d6))),_0x9f71b=await createPersonalKnowledgeBaseItem(_0x996513['appCode'],{'title':_0x49d906,'content':_0x1317dc});return{'ok':!![],'data':summarizePersonalItem(_0x9f71b),'message':_0x548ff6(0x1f2)+_0x9f71b['id']+'\x20('+_0x9f71b[_0x548ff6(0x1e9)]+')'};},async 'dryRun'(_0x4cae56){const _0xfdc180=a22_0x435563,_0x1ed84e=_0x4cae56[_0xfdc180(0x20e)]('title'),_0x2fa9f6=readKnowledgeFile(_0x4cae56[_0xfdc180(0x20e)](_0xfdc180(0x1d6)));return dryRun(_0xfdc180(0x1e6),_0xfdc180(0x200))[_0xfdc180(0x205)]({'appCode':_0x4cae56['appCode'],'title':_0x1ed84e,'content':_0x2fa9f6})[_0xfdc180(0x20d)](_0xfdc180(0x1ed)+_0x1ed84e+'\x22')[_0xfdc180(0x1e2)]();}},kbUpdate={'service':'kb','command':'update','description':a22_0x435563(0x1e5),'risk':'write','flags':[{...ID_FLAG,'description':a22_0x435563(0x1fc)},{...TITLE_FLAG,'required':![],'description':a22_0x435563(0x204)},FILE_FLAG],async 'execute'(_0x2ffc4d){const _0x529bad=a22_0x435563,_0x5bac37=_0x2ffc4d[_0x529bad(0x1fa)]('id'),_0x58de14=readKnowledgeFile(_0x2ffc4d[_0x529bad(0x20e)](_0x529bad(0x1d6))),_0x11e5b4=_0x2ffc4d[_0x529bad(0x20e)]('title')||(await getPersonalKnowledgeBaseItem(_0x5bac37,_0x2ffc4d[_0x529bad(0x1ce)]))[_0x529bad(0x1e9)],_0x3c0780=await updatePersonalKnowledgeBaseItem(_0x5bac37,_0x2ffc4d['appCode'],{'title':_0x11e5b4,'content':_0x58de14});return{'ok':!![],'data':summarizePersonalItem(_0x3c0780),'message':_0x529bad(0x20f)+_0x3c0780['id']+'\x20('+_0x3c0780[_0x529bad(0x1e9)]+')'};},async 'dryRun'(_0x75a7ad){const _0x99e3df=a22_0x435563,_0x4cf27d=_0x75a7ad[_0x99e3df(0x1fa)]('id'),_0x4ba366=readKnowledgeFile(_0x75a7ad[_0x99e3df(0x20e)](_0x99e3df(0x1d6))),_0x399a96=_0x75a7ad[_0x99e3df(0x20e)](_0x99e3df(0x1e9))||(await getPersonalKnowledgeBaseItem(_0x4cf27d,_0x75a7ad[_0x99e3df(0x1ce)]))[_0x99e3df(0x1e9)];return dryRun(_0x99e3df(0x1e6),_0x99e3df(0x1e3)+_0x4cf27d+_0x99e3df(0x1fd))[_0x99e3df(0x205)]({'appCode':_0x75a7ad[_0x99e3df(0x1ce)],'title':_0x399a96,'content':_0x4ba366})[_0x99e3df(0x20d)](_0x99e3df(0x206)+_0x4cf27d)[_0x99e3df(0x1e2)]();}},kbSearch={'service':'kb','command':'search','description':a22_0x435563(0x202),'risk':a22_0x435563(0x1ff),'flags':[QUERY_FLAG,TOPK_FLAG],async 'validate'(_0x102d2f){const _0xb329eb=a22_0x435563;if(!_0x102d2f[_0xb329eb(0x20e)](_0xb329eb(0x1e7))[_0xb329eb(0x1d2)]())throw CliErrors['validation']('Search\x20query\x20is\x20required.');readTopK(_0x102d2f);},async 'execute'(_0x2fea60){const _0x451942=a22_0x435563,_0x26c858=_0x2fea60[_0x451942(0x20e)](_0x451942(0x1e7))[_0x451942(0x1d2)](),_0x5b726b=readTopK(_0x2fea60),_0x3aec87=await searchKnowledgeBase(_0x2fea60['appCode'],{'query':_0x26c858,'topK':_0x5b726b});return{'ok':!![],'data':{'total':_0x3aec87['length'],'hits':_0x3aec87[_0x451942(0x1d5)](summarizeSearchHit)}};}};export const kbDefinitions=[kbList,kbDetail,kbCreate,kbUpdate,kbSearch];
@@ -1 +1 @@
1
- const a22_0x42a396=a22_0x5e55;(function(_0x5f4e9b,_0x129695){const _0x31384b=a22_0x5e55,_0x23bd10=_0x5f4e9b();while(!![]){try{const _0x570c3e=-parseInt(_0x31384b(0x13e))/0x1*(-parseInt(_0x31384b(0x13c))/0x2)+parseInt(_0x31384b(0x12a))/0x3*(parseInt(_0x31384b(0x13d))/0x4)+parseInt(_0x31384b(0x12b))/0x5*(-parseInt(_0x31384b(0x141))/0x6)+-parseInt(_0x31384b(0x137))/0x7+-parseInt(_0x31384b(0x142))/0x8+parseInt(_0x31384b(0x135))/0x9+parseInt(_0x31384b(0x125))/0xa;if(_0x570c3e===_0x129695)break;else _0x23bd10['push'](_0x23bd10['shift']());}catch(_0x56145b){_0x23bd10['push'](_0x23bd10['shift']());}}}(a22_0x5171,0x83f1c));import{logger}from'../../utils/logger.js';import{CLI_DISPLAY_NAME}from'../../constant/cli.js';function printLogs(_0x558604){const _0x45ddc3=a22_0x5e55;if(_0x558604[_0x45ddc3(0x146)]===0x0){console[_0x45ddc3(0x139)](_0x45ddc3(0x12c));return;}console['log']('*\x20'+CLI_DISPLAY_NAME+_0x45ddc3(0x130)),_0x558604[_0x45ddc3(0x12e)]((_0x1bc5a3,_0xdaf807)=>{const _0xfb808c=_0x45ddc3,_0x5e0394=new Date(_0x1bc5a3[_0xfb808c(0x143)])[_0xfb808c(0x133)](_0xfb808c(0x13f)),_0x24f364=_0x1bc5a3[_0xfb808c(0x136)]==='success'?'√':_0x1bc5a3[_0xfb808c(0x136)]===_0xfb808c(0x127)?'×':_0x1bc5a3['level']===_0xfb808c(0x126)?'!':'i';console['log'](_0xdaf807+0x1+'.\x20'+_0x24f364+'\x20['+_0x1bc5a3[_0xfb808c(0x12d)]+']\x20'+_0x1bc5a3[_0xfb808c(0x122)]),console['log'](_0xfb808c(0x128)+_0x5e0394),_0x1bc5a3['duration']&&console[_0xfb808c(0x139)](_0xfb808c(0x129)+_0x1bc5a3[_0xfb808c(0x123)]+'ms'),_0x1bc5a3[_0xfb808c(0x138)]&&Object[_0xfb808c(0x121)](_0x1bc5a3[_0xfb808c(0x138)])[_0xfb808c(0x146)]>0x0&&console['log'](_0xfb808c(0x134)+JSON[_0xfb808c(0x124)](_0x1bc5a3[_0xfb808c(0x138)],null,0x2)),console[_0xfb808c(0x139)]('');});}export const logsDefinitions=[{'service':a22_0x42a396(0x145),'command':a22_0x42a396(0x132),'description':a22_0x42a396(0x13b),'risk':a22_0x42a396(0x131),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x1c6094){return printLogs(logger['readLogs']()),{'ok':!![]};}},{'service':a22_0x42a396(0x145),'command':a22_0x42a396(0x12f),'description':a22_0x42a396(0x147),'risk':a22_0x42a396(0x13a),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x137286){const _0x19fd99=a22_0x42a396;return logger[_0x19fd99(0x140)](),console[_0x19fd99(0x139)](_0x19fd99(0x144)),{'ok':!![]};}}];function a22_0x5e55(_0x3d8226,_0x28a69d){_0x3d8226=_0x3d8226-0x121;const _0x5171d6=a22_0x5171();let _0x5e554e=_0x5171d6[_0x3d8226];return _0x5e554e;}function a22_0x5171(){const _0xea9a64=['5SyAHxS','*\x20No\x20logs\x20found','command','forEach','clear','\x20logs:\x0a','read','show','toLocaleString','\x20\x20\x20Details:\x20','9323847RbjWwC','level','6481405cufZcl','details','log','write','View\x20command\x20history\x20logs','1024372VCoDMl','120ONBbns','1ecVZpI','en-US','clearLogs','5909340KHaxJu','2486224cbDKRO','timestamp','*\x20Logs\x20cleared','logs','length','Clear\x20command\x20history\x20logs','keys','message','duration','stringify','8643580DpghsY','warn','error','\x20\x20\x20Time:\x20','\x20\x20\x20Duration:\x20','34950SZSrZN'];a22_0x5171=function(){return _0xea9a64;};return a22_0x5171();}
1
+ function a23_0xb46b(){const _0x45b604=['logs','1643232UURPcs','level','1475632SMZmBC','12631130bircsJ','3GpGhhh','43312MQFkcI','168988mNobJW','length','show','clearLogs','log','message','88pgfWnZ','44wrXPBp','timestamp','9QkkVty','readLogs','*\x20No\x20logs\x20found','\x20\x20\x20Time:\x20','761928JUkJCl','toLocaleString','30magXwg','522340EYOwSH','details','keys','duration','\x20logs:\x0a','\x20\x20\x20Details:\x20','command'];a23_0xb46b=function(){return _0x45b604;};return a23_0xb46b();}const a23_0x53eb38=a23_0x4d69;(function(_0x3a8a17,_0x534796){const _0x453196=a23_0x4d69,_0x24e362=_0x3a8a17();while(!![]){try{const _0x3e75cd=-parseInt(_0x453196(0x16e))/0x1*(-parseInt(_0x453196(0x176))/0x2)+parseInt(_0x453196(0x16d))/0x3*(parseInt(_0x453196(0x16f))/0x4)+parseInt(_0x453196(0x17e))/0x5*(-parseInt(_0x453196(0x17c))/0x6)+parseInt(_0x453196(0x17f))/0x7+parseInt(_0x453196(0x16b))/0x8+parseInt(_0x453196(0x178))/0x9*(parseInt(_0x453196(0x16c))/0xa)+-parseInt(_0x453196(0x175))/0xb*(parseInt(_0x453196(0x169))/0xc);if(_0x3e75cd===_0x534796)break;else _0x24e362['push'](_0x24e362['shift']());}catch(_0x39f0d8){_0x24e362['push'](_0x24e362['shift']());}}}(a23_0xb46b,0xa11aa));import{logger}from'../../utils/logger.js';import{CLI_DISPLAY_NAME}from'../../constant/cli.js';function printLogs(_0x1a4617){const _0x260b28=a23_0x4d69;if(_0x1a4617[_0x260b28(0x170)]===0x0){console[_0x260b28(0x173)](_0x260b28(0x17a));return;}console['log']('*\x20'+CLI_DISPLAY_NAME+_0x260b28(0x183)),_0x1a4617['forEach']((_0x53c420,_0x41fc37)=>{const _0x3d9d8c=_0x260b28,_0x4d3468=new Date(_0x53c420[_0x3d9d8c(0x177)])[_0x3d9d8c(0x17d)]('en-US'),_0x29f47b=_0x53c420[_0x3d9d8c(0x16a)]==='success'?'√':_0x53c420[_0x3d9d8c(0x16a)]==='error'?'×':_0x53c420[_0x3d9d8c(0x16a)]==='warn'?'!':'i';console[_0x3d9d8c(0x173)](_0x41fc37+0x1+'.\x20'+_0x29f47b+'\x20['+_0x53c420[_0x3d9d8c(0x167)]+']\x20'+_0x53c420[_0x3d9d8c(0x174)]),console[_0x3d9d8c(0x173)](_0x3d9d8c(0x17b)+_0x4d3468),_0x53c420[_0x3d9d8c(0x182)]&&console[_0x3d9d8c(0x173)]('\x20\x20\x20Duration:\x20'+_0x53c420['duration']+'ms'),_0x53c420[_0x3d9d8c(0x180)]&&Object[_0x3d9d8c(0x181)](_0x53c420[_0x3d9d8c(0x180)])[_0x3d9d8c(0x170)]>0x0&&console['log'](_0x3d9d8c(0x166)+JSON['stringify'](_0x53c420[_0x3d9d8c(0x180)],null,0x2)),console['log']('');});}function a23_0x4d69(_0x1c8031,_0x154634){_0x1c8031=_0x1c8031-0x166;const _0xb46b94=a23_0xb46b();let _0x4d697e=_0xb46b94[_0x1c8031];return _0x4d697e;}export const logsDefinitions=[{'service':'logs','command':a23_0x53eb38(0x171),'description':'View\x20command\x20history\x20logs','risk':'read','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x1d883e){const _0x35642c=a23_0x53eb38;return printLogs(logger[_0x35642c(0x179)]()),{'ok':!![]};}},{'service':a23_0x53eb38(0x168),'command':'clear','description':'Clear\x20command\x20history\x20logs','risk':'write','requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x23dec3){const _0x5be609=a23_0x53eb38;return logger[_0x5be609(0x172)](),console[_0x5be609(0x173)]('*\x20Logs\x20cleared'),{'ok':!![]};}}];
@@ -1 +1 @@
1
- function a23_0xa7a8(){const _0x5f209=['set','defaultCommand','1324260QRIvYn','Configuration','SQL\x20Queries','from','634374YSsXyE','command','install','Datasets','2xuSpiL','16iRutNs','\x20\x20[write]','\x20\x20[high-risk-write]','App\x20Management','service','Skills','393676GgkuOz','Self\x20Update','push','risk','list','read','Authentication','isSingleCommand','values','199100KPTQzF','2486379GhaDsI','10xdTzEs','run','Logs','map','login','show','10uXiIyP','1958949IGREGc','Diagnostics','Schema','get','965327nNMqkk'];a23_0xa7a8=function(){return _0x5f209;};return a23_0xa7a8();}const a23_0x43bed5=a23_0x370c;(function(_0x5d825d,_0x4e13cb){const _0x3fbafd=a23_0x370c,_0xf85162=_0x5d825d();while(!![]){try{const _0x10dfac=parseInt(_0x3fbafd(0xaf))/0x1*(-parseInt(_0x3fbafd(0xa8))/0x2)+parseInt(_0x3fbafd(0xa0))/0x3+parseInt(_0x3fbafd(0x90))/0x4+-parseInt(_0x3fbafd(0x92))/0x5*(-parseInt(_0x3fbafd(0xa4))/0x6)+parseInt(_0x3fbafd(0x91))/0x7+parseInt(_0x3fbafd(0xa9))/0x8*(-parseInt(_0x3fbafd(0x99))/0x9)+-parseInt(_0x3fbafd(0x98))/0xa*(-parseInt(_0x3fbafd(0x9d))/0xb);if(_0x10dfac===_0x4e13cb)break;else _0xf85162['push'](_0xf85162['shift']());}catch(_0x5b27f3){_0xf85162['push'](_0xf85162['shift']());}}}(a23_0xa7a8,0x4d4c1));import{authDefinitions}from'../commands/auth/index.js';import{logsDefinitions}from'../commands/logs/index.js';import{skillDefinitions}from'../commands/skill/index.js';import{updateDefinition}from'../commands/update.js';import{doctorDefinition}from'../commands/doctor.js';import{schemaDefinition}from'../commands/schema.js';import{appDefinitions}from'../commands/app/definitions.js';import{configDefinitions}from'../commands/config/definitions.js';import{bffDefinitions}from'../commands/bff/index.js';import{sqlDefinitions}from'../commands/sql/index.js';import{datasetDefinitions}from'../commands/dataset/index.js';import{dataDefinitions}from'../commands/data/index.js';export const serviceRegistry=[];const serviceByName=new Map();export const definitions=new Map();export const serviceGroups=new Map();function registerDefinitions(_0x243700){const _0x4e3cbc=a23_0x370c;for(const _0x26d518 of _0x243700){definitions[_0x4e3cbc(0x9e)](_0x26d518['service']+':'+_0x26d518[_0x4e3cbc(0xa5)],_0x26d518);let _0x40f781=serviceGroups[_0x4e3cbc(0x9c)](_0x26d518[_0x4e3cbc(0xad)]);!_0x40f781&&(_0x40f781=[],serviceGroups[_0x4e3cbc(0x9e)](_0x26d518[_0x4e3cbc(0xad)],_0x40f781)),_0x40f781['push'](_0x26d518);}}function registerService(_0x47759f,_0x15369f,_0x1889eb){const _0x3928cb=a23_0x370c;registerDefinitions(_0x15369f);const _0x3bfcf0=_0x26e4cb=>_0x26e4cb===_0x3928cb(0x8c)?'':_0x26e4cb==='write'?_0x3928cb(0xaa):_0x3928cb(0xab),_0x1f1364={'service':_0x15369f[0x0]['service'],'label':_0x47759f,'commands':_0x15369f[_0x3928cb(0x95)](_0x3869c7=>({'command':_0x3869c7[_0x3928cb(0xa5)],'description':_0x3869c7['description'],'tag':_0x3bfcf0(_0x3869c7[_0x3928cb(0x8a)])})),'defaultCommand':_0x1889eb?.[_0x3928cb(0x9f)]??(_0x1889eb?.[_0x3928cb(0x8e)]?_0x15369f[0x0]['command']:undefined),'isSingleCommand':_0x1889eb?.['isSingleCommand']};serviceRegistry[_0x3928cb(0xb1)](_0x1f1364),serviceByName[_0x3928cb(0x9e)](_0x1f1364['service'],_0x1f1364);}registerService(a23_0x43bed5(0x8d),authDefinitions,{'defaultCommand':a23_0x43bed5(0x96)}),registerService(a23_0x43bed5(0xa7),datasetDefinitions),registerService('Instant\x20API',dataDefinitions),registerService(a23_0x43bed5(0xa2),sqlDefinitions),registerService('BFF\x20Scripts',bffDefinitions),registerService(a23_0x43bed5(0xac),appDefinitions,{'defaultCommand':a23_0x43bed5(0x8b)}),registerService(a23_0x43bed5(0xa1),configDefinitions,{'defaultCommand':'list'}),registerService(a23_0x43bed5(0xae),skillDefinitions,{'defaultCommand':a23_0x43bed5(0xa6)}),registerService(a23_0x43bed5(0xb0),[updateDefinition],{'defaultCommand':a23_0x43bed5(0x93),'isSingleCommand':!![]}),registerService(a23_0x43bed5(0x9a),[doctorDefinition],{'isSingleCommand':!![]}),registerService(a23_0x43bed5(0x9b),[schemaDefinition],{'isSingleCommand':!![]}),registerService(a23_0x43bed5(0x94),logsDefinitions,{'defaultCommand':a23_0x43bed5(0x97)});export function findDefinition(_0x3464c2,_0x3c8c7a){const _0x308668=a23_0x43bed5;return definitions[_0x308668(0x9c)](_0x3464c2+':'+_0x3c8c7a);}function a23_0x370c(_0x106e6a,_0x1a6f5f){_0x106e6a=_0x106e6a-0x8a;const _0xa7a8f2=a23_0xa7a8();let _0x370c36=_0xa7a8f2[_0x106e6a];return _0x370c36;}export function isKnownService(_0x1a8b7d){return serviceByName['has'](_0x1a8b7d);}export function getServiceEntry(_0x288bec){const _0x2159f4=a23_0x43bed5;return serviceByName[_0x2159f4(0x9c)](_0x288bec);}export function getAllDefinitions(){const _0x3997f3=a23_0x43bed5;return Array[_0x3997f3(0xa3)](definitions[_0x3997f3(0x8f)]());}
1
+ function a24_0x8476(_0x42265f,_0x13e925){_0x42265f=_0x42265f-0x1e9;const _0x16ae6a=a24_0x16ae();let _0x84764e=_0x16ae6a[_0x42265f];return _0x84764e;}const a24_0x3262b8=a24_0x8476;(function(_0x194a8c,_0x26516a){const _0x66e13c=a24_0x8476,_0x30455f=_0x194a8c();while(!![]){try{const _0x1747fd=parseInt(_0x66e13c(0x1eb))/0x1+-parseInt(_0x66e13c(0x20c))/0x2+parseInt(_0x66e13c(0x20d))/0x3+-parseInt(_0x66e13c(0x1f7))/0x4+parseInt(_0x66e13c(0x1fb))/0x5*(-parseInt(_0x66e13c(0x1ea))/0x6)+parseInt(_0x66e13c(0x207))/0x7*(-parseInt(_0x66e13c(0x20a))/0x8)+parseInt(_0x66e13c(0x1f0))/0x9*(parseInt(_0x66e13c(0x203))/0xa);if(_0x1747fd===_0x26516a)break;else _0x30455f['push'](_0x30455f['shift']());}catch(_0x4beb82){_0x30455f['push'](_0x30455f['shift']());}}}(a24_0x16ae,0xaff12));import{authDefinitions}from'../commands/auth/index.js';import{logsDefinitions}from'../commands/logs/index.js';import{skillDefinitions}from'../commands/skill/index.js';import{updateDefinition}from'../commands/update.js';import{doctorDefinition}from'../commands/doctor.js';import{schemaDefinition}from'../commands/schema.js';import{appDefinitions}from'../commands/app/definitions.js';import{configDefinitions}from'../commands/config/definitions.js';import{bffDefinitions}from'../commands/bff/index.js';import{sqlDefinitions}from'../commands/sql/index.js';import{datasetDefinitions}from'../commands/dataset/index.js';import{dataDefinitions}from'../commands/data/index.js';function a24_0x16ae(){const _0x2d999a=['10LolDEa','SQL\x20Queries','Configuration','Self\x20Update','1486646XJZvAZ','Datasets','read','8UGyneQ','\x20\x20[high-risk-write]','2240202TFrEHC','2555544PLjtJc','from','run','7746sEeMgF','562750eIQigr','defaultCommand','service','command','push','25575183Splutx','write','get','map','BFF\x20Scripts','install','description','5027380PfizdD','\x20\x20[write]','Instant\x20API','set','3665jXXUwT','has','risk','Skills','show','login','values','isSingleCommand'];a24_0x16ae=function(){return _0x2d999a;};return a24_0x16ae();}import{kbDefinitions}from'../commands/kb/index.js';export const serviceRegistry=[];const serviceByName=new Map();export const definitions=new Map();export const serviceGroups=new Map();function registerDefinitions(_0x1c05ce){const _0x382739=a24_0x8476;for(const _0x151323 of _0x1c05ce){definitions[_0x382739(0x1fa)](_0x151323['service']+':'+_0x151323[_0x382739(0x1ee)],_0x151323);let _0x5e06a0=serviceGroups[_0x382739(0x1f2)](_0x151323[_0x382739(0x1ed)]);!_0x5e06a0&&(_0x5e06a0=[],serviceGroups[_0x382739(0x1fa)](_0x151323[_0x382739(0x1ed)],_0x5e06a0)),_0x5e06a0['push'](_0x151323);}}function registerService(_0x14e70a,_0x1ca007,_0x564351){const _0x27530f=a24_0x8476;registerDefinitions(_0x1ca007);const _0x2173ee=_0x49754d=>_0x49754d===_0x27530f(0x209)?'':_0x49754d===_0x27530f(0x1f1)?_0x27530f(0x1f8):_0x27530f(0x20b),_0x536e8f={'service':_0x1ca007[0x0][_0x27530f(0x1ed)],'label':_0x14e70a,'commands':_0x1ca007[_0x27530f(0x1f3)](_0x38f4d2=>({'command':_0x38f4d2[_0x27530f(0x1ee)],'description':_0x38f4d2[_0x27530f(0x1f6)],'tag':_0x2173ee(_0x38f4d2[_0x27530f(0x1fd)])})),'defaultCommand':_0x564351?.[_0x27530f(0x1ec)]??(_0x564351?.[_0x27530f(0x202)]?_0x1ca007[0x0][_0x27530f(0x1ee)]:undefined),'isSingleCommand':_0x564351?.[_0x27530f(0x202)]};serviceRegistry[_0x27530f(0x1ef)](_0x536e8f),serviceByName[_0x27530f(0x1fa)](_0x536e8f[_0x27530f(0x1ed)],_0x536e8f);}registerService('Authentication',authDefinitions,{'defaultCommand':a24_0x3262b8(0x200)}),registerService(a24_0x3262b8(0x208),datasetDefinitions),registerService(a24_0x3262b8(0x1f9),dataDefinitions),registerService(a24_0x3262b8(0x204),sqlDefinitions),registerService(a24_0x3262b8(0x1f4),bffDefinitions),registerService('Knowledge\x20Base',kbDefinitions),registerService('App\x20Management',appDefinitions,{'defaultCommand':'list'}),registerService(a24_0x3262b8(0x205),configDefinitions,{'defaultCommand':'list'}),registerService(a24_0x3262b8(0x1fe),skillDefinitions,{'defaultCommand':a24_0x3262b8(0x1f5)}),registerService(a24_0x3262b8(0x206),[updateDefinition],{'defaultCommand':a24_0x3262b8(0x1e9),'isSingleCommand':!![]}),registerService('Diagnostics',[doctorDefinition],{'isSingleCommand':!![]}),registerService('Schema',[schemaDefinition],{'isSingleCommand':!![]}),registerService('Logs',logsDefinitions,{'defaultCommand':a24_0x3262b8(0x1ff)});export function findDefinition(_0x6f9899,_0x476a68){const _0x3f345c=a24_0x3262b8;return definitions[_0x3f345c(0x1f2)](_0x6f9899+':'+_0x476a68);}export function isKnownService(_0xc07862){const _0x728c9d=a24_0x3262b8;return serviceByName[_0x728c9d(0x1fc)](_0xc07862);}export function getServiceEntry(_0x4e9c6f){const _0x4aa2b5=a24_0x3262b8;return serviceByName[_0x4aa2b5(0x1f2)](_0x4e9c6f);}export function getAllDefinitions(){const _0x369127=a24_0x3262b8;return Array[_0x369127(0x20e)](definitions[_0x369127(0x201)]());}
@@ -1 +1 @@
1
- const a24_0x8edf81=a24_0x299f;(function(_0x21615a,_0x419046){const _0x2e5f64=a24_0x299f,_0x36dd36=_0x21615a();while(!![]){try{const _0x29b713=-parseInt(_0x2e5f64(0x138))/0x1*(parseInt(_0x2e5f64(0x12c))/0x2)+-parseInt(_0x2e5f64(0x131))/0x3*(-parseInt(_0x2e5f64(0x12f))/0x4)+-parseInt(_0x2e5f64(0x13a))/0x5*(parseInt(_0x2e5f64(0x136))/0x6)+-parseInt(_0x2e5f64(0x137))/0x7*(-parseInt(_0x2e5f64(0x132))/0x8)+parseInt(_0x2e5f64(0x12a))/0x9*(parseInt(_0x2e5f64(0x135))/0xa)+parseInt(_0x2e5f64(0x12e))/0xb*(parseInt(_0x2e5f64(0x12d))/0xc)+parseInt(_0x2e5f64(0x133))/0xd*(-parseInt(_0x2e5f64(0x139))/0xe);if(_0x29b713===_0x419046)break;else _0x36dd36['push'](_0x36dd36['shift']());}catch(_0x4c4078){_0x36dd36['push'](_0x36dd36['shift']());}}}(a24_0xc194,0x4df1e));function a24_0x299f(_0x4cb56f,_0xc3c920){_0x4cb56f=_0x4cb56f-0x12a;const _0xc19494=a24_0xc194();let _0x299f40=_0xc19494[_0x4cb56f];return _0x299f40;}import{buildSchemaPayload}from'../framework/schema-export.js';async function execute(_0x2ec6c9){const _0x34d786=await buildSchemaPayload();return{'ok':!![],'data':_0x34d786};}export const schemaDefinition={'service':a24_0x8edf81(0x12b),'command':a24_0x8edf81(0x134),'description':'Export\x20machine-readable\x20command\x20schema\x20(JSON)','risk':a24_0x8edf81(0x130),'requiresAuth':![],'requiresAppCode':![],'hasFormat':!![],'flags':[],'execute':execute};function a24_0xc194(){const _0x1c6b06=['1962768BTnySL','119PSxmJP','15NJAKae','4470382zRmMPZ','5erinxS','6723FySttE','schema','31782tGehPx','900gcxuJI','27214PqasAf','61428MKfSCF','read','117CCeuzm','179880disczv','13CXeORH','export','500mAsFYk'];a24_0xc194=function(){return _0x1c6b06;};return a24_0xc194();}
1
+ function a25_0xdcb3(){const _0x2eaefc=['Export\x20machine-readable\x20command\x20schema\x20(JSON)','1242iMugtt','1033070BalawD','5790DaAKCa','read','573948NgAvIj','322Lhhhir','20478XTklOE','1106121KvNzfe','2431640mPFYgJ','219106dUXuXM','7SFRiLA'];a25_0xdcb3=function(){return _0x2eaefc;};return a25_0xdcb3();}const a25_0x24409d=a25_0x3c65;function a25_0x3c65(_0x349dd3,_0x443da4){_0x349dd3=_0x349dd3-0x1ac;const _0xdcb3d4=a25_0xdcb3();let _0x3c6547=_0xdcb3d4[_0x349dd3];return _0x3c6547;}(function(_0x41a2c0,_0x3149c5){const _0x9f3ecf=a25_0x3c65,_0x1ee2da=_0x41a2c0();while(!![]){try{const _0x7001=-parseInt(_0x9f3ecf(0x1b5))/0x1*(parseInt(_0x9f3ecf(0x1b4))/0x2)+parseInt(_0x9f3ecf(0x1b2))/0x3+parseInt(_0x9f3ecf(0x1af))/0x4+parseInt(_0x9f3ecf(0x1ac))/0x5+-parseInt(_0x9f3ecf(0x1b1))/0x6*(-parseInt(_0x9f3ecf(0x1b0))/0x7)+parseInt(_0x9f3ecf(0x1b3))/0x8+parseInt(_0x9f3ecf(0x1b7))/0x9*(parseInt(_0x9f3ecf(0x1ad))/0xa);if(_0x7001===_0x3149c5)break;else _0x1ee2da['push'](_0x1ee2da['shift']());}catch(_0x1f16b2){_0x1ee2da['push'](_0x1ee2da['shift']());}}}(a25_0xdcb3,0x784f8));import{buildSchemaPayload}from'../framework/schema-export.js';async function execute(_0xc29830){const _0x4e3455=await buildSchemaPayload();return{'ok':!![],'data':_0x4e3455};}export const schemaDefinition={'service':'schema','command':'export','description':a25_0x24409d(0x1b6),'risk':a25_0x24409d(0x1ae),'requiresAuth':![],'requiresAppCode':![],'hasFormat':!![],'flags':[],'execute':execute};
@@ -1 +1 @@
1
- const a25_0x5d6401=a25_0xdccf;function a25_0x5e22(){const _0x1b5758=['../../skills/npx-skills-add.js','20040XdAQaZ','Check\x20network\x20connectivity\x20and\x20try\x20again.','\x20-g\x20-y)...','log','Skipped\x20npx\x20(','36jadXyP','inherit','12059749imGjsQ','skipped','4470380BFjdze','skill-install','Installing\x20published\x20','error','38341pPdrOz','6BYaoKG','814IeLSip','42FDRgBB','562473rJeHzm','132100BnwTCq','cwd','nonInteractive','783GRwdOj','12uWasfA','Install\x20the\x20published\x20','install','npx\x20skills\x20add\x20failed:\x20','unknown','write','2156931xHGReO','\x20developer\x20skill','\x20skill\x20installed'];a25_0x5e22=function(){return _0x1b5758;};return a25_0x5e22();}(function(_0x1e1863,_0x5d0426){const _0x185c61=a25_0xdccf,_0x3291de=_0x1e1863();while(!![]){try{const _0x21730d=parseInt(_0x185c61(0x154))/0x1*(parseInt(_0x185c61(0x157))/0x2)+-parseInt(_0x185c61(0x158))/0x3*(parseInt(_0x185c61(0x13d))/0x4)+-parseInt(_0x185c61(0x150))/0x5+-parseInt(_0x185c61(0x155))/0x6*(parseInt(_0x185c61(0x143))/0x7)+parseInt(_0x185c61(0x147))/0x8*(-parseInt(_0x185c61(0x13c))/0x9)+-parseInt(_0x185c61(0x159))/0xa*(parseInt(_0x185c61(0x156))/0xb)+-parseInt(_0x185c61(0x14c))/0xc*(-parseInt(_0x185c61(0x14e))/0xd);if(_0x21730d===_0x5d0426)break;else _0x3291de['push'](_0x3291de['shift']());}catch(_0x444e68){_0x3291de['push'](_0x3291de['shift']());}}}(a25_0x5e22,0x99537));function a25_0xdccf(_0x2164a1,_0x477a6b){_0x2164a1=_0x2164a1-0x13a;const _0x5e22ed=a25_0x5e22();let _0xdccf84=_0x5e22ed[_0x2164a1];return _0xdccf84;}import{CLI_BIN_NAME,CLI_DISPLAY_NAME}from'../../constant/cli.js';import{CliErrors}from'../../errors.js';import{logger}from'../../utils/logger.js';export const skillDefinitions=[{'service':'skill','command':a25_0x5d6401(0x13f),'description':a25_0x5d6401(0x13e)+CLI_BIN_NAME+a25_0x5d6401(0x144),'risk':a25_0x5d6401(0x142),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x1b91c4){const _0x5f4b09=a25_0x5d6401;logger['setLogPath'](process[_0x5f4b09(0x13a)]()),logger['info'](_0x5f4b09(0x151),_0x5f4b09(0x152)+CLI_DISPLAY_NAME+'\x20skill\x20via\x20npx.');const {LOVRABET_SKILL_SOURCE:_0xbc6020,LOVRABET_SKIP_NPX_SKILLS_ENV:_0x2150d6,runNpxSkillsAddGlobal:_0xb42e65}=await import(_0x5f4b09(0x146)),_0x10c0e1=_0x1b91c4[_0x5f4b09(0x13b)]?'pipe':_0x5f4b09(0x14d);console['log']('Installing\x20official\x20skill\x20via\x20npx\x20(npx\x20skills\x20add\x20'+_0xbc6020+_0x5f4b09(0x149));const _0x281239=_0xb42e65(process[_0x5f4b09(0x13a)](),_0xbc6020,{'stdio':_0x10c0e1});if(_0x281239[_0x5f4b09(0x14f)])console[_0x5f4b09(0x14a)](_0x5f4b09(0x14b)+_0x2150d6+'=1);\x20assuming\x20skill\x20is\x20already\x20present.');else{if(_0x281239['ok'])console[_0x5f4b09(0x14a)](CLI_BIN_NAME+_0x5f4b09(0x145));else throw CliErrors['apiError'](_0x5f4b09(0x140)+(_0x281239[_0x5f4b09(0x153)]||_0x5f4b09(0x141)),_0x5f4b09(0x148));}return{'ok':!![]};}}];
1
+ const a26_0x1f8493=a26_0x21c4;function a26_0x21c4(_0x556d58,_0x36ffb7){_0x556d58=_0x556d58-0x96;const _0xb74feb=a26_0xb74f();let _0x21c498=_0xb74feb[_0x556d58];return _0x21c498;}(function(_0x59f1b4,_0x324447){const _0x3db9a3=a26_0x21c4,_0x2d263e=_0x59f1b4();while(!![]){try{const _0x372a2c=-parseInt(_0x3db9a3(0x9e))/0x1+parseInt(_0x3db9a3(0xa4))/0x2+-parseInt(_0x3db9a3(0xc9))/0x3+parseInt(_0x3db9a3(0xbb))/0x4*(parseInt(_0x3db9a3(0xb9))/0x5)+-parseInt(_0x3db9a3(0xb1))/0x6+-parseInt(_0x3db9a3(0x9a))/0x7*(-parseInt(_0x3db9a3(0x98))/0x8)+-parseInt(_0x3db9a3(0xa3))/0x9*(parseInt(_0x3db9a3(0xd5))/0xa);if(_0x372a2c===_0x324447)break;else _0x2d263e['push'](_0x2d263e['shift']());}catch(_0x2eeeb0){_0x2d263e['push'](_0x2d263e['shift']());}}}(a26_0xb74f,0x23304));import{CLI_BIN_NAME,CLI_DISPLAY_NAME}from'../../constant/cli.js';import{CliErrors}from'../../errors.js';import{logger}from'../../utils/logger.js';function a26_0xb74f(){const _0x66775d=['trim','unknown','map','code','\x20skill\x20installed','\x20company\x20Skill(s).','405492xVCndP','action','Pulled\x20','authRequired','length','Skipped\x20npx\x20(','skipped','Installing\x20published\x20','81635TzWTvA','cwd','56BgMCiP','input','Local\x20Skill\x20directory\x20containing\x20SKILL.md','Only\x20pull\x20a\x20specific\x20runtime\x20Skill\x20code','filter','error','reduce','push','../../skills/runtime-skill-sync.js','Installing\x20official\x20skill\x20via\x20npx\x20(npx\x20skills\x20add\x20','appCode','Pull\x20personal\x20and\x20company\x20runtime\x20Skills\x20into\x20local\x20agent\x20skill\x20directories','readonly','../../skills/npx-skills-add.js','621123zAZACo','npx\x20skills\x20add\x20failed:\x20','\x20developer\x20skill','log','skillCode','../../core/api-client.js','updated','envName','production','str','setLogPath','skillName','590omgZVl','Updated\x20personal\x20Skill\x20','version','Created\x20personal\x20Skill\x20','accessKey','8hfLRlF','\x20-g\x20-y)...','879781QdkGhX','pull','pipe','skill','25043BlynfU','string','=1);\x20assuming\x20skill\x20is\x20already\x20present.','Check\x20network\x20connectivity\x20and\x20try\x20again.','company','10053bHENzA','310880vlogsI','apiError','created','dir','write','info','personal'];a26_0xb74f=function(){return _0x66775d;};return a26_0xb74f();}const CODE_FLAG={'name':a26_0x1f8493(0xae),'type':a26_0x1f8493(0x9f),'description':a26_0x1f8493(0xbe)},DIR_FLAG={'name':a26_0x1f8493(0xa7),'type':'string','required':!![],'description':a26_0x1f8493(0xbd)};function summarizeRuntimeSkill(_0x397030){const _0x5bb83b=a26_0x1f8493;return{'id':_0x397030['id'],'skillCode':_0x397030[_0x5bb83b(0xcd)],'skillName':_0x397030[_0x5bb83b(0xd4)],'scope':_0x397030['scope'],'version':_0x397030[_0x5bb83b(0xd7)],'readonly':_0x397030[_0x5bb83b(0xc7)]};}function filterByCode(_0x4e9142,_0x21cdb7){const _0x4bb8b1=a26_0x1f8493,_0x11100c=_0x21cdb7[_0x4bb8b1(0xab)]();if(!_0x11100c)return _0x4e9142;return _0x4e9142[_0x4bb8b1(0xbf)](_0x5b3b4d=>_0x5b3b4d[_0x4bb8b1(0xcd)]===_0x11100c);}export const skillDefinitions=[{'service':a26_0x1f8493(0x9d),'command':'install','description':'Install\x20the\x20published\x20'+CLI_BIN_NAME+a26_0x1f8493(0xcb),'risk':a26_0x1f8493(0xa8),'requiresAuth':![],'requiresAppCode':![],'hasFormat':![],'flags':[],async 'execute'(_0x17e9b4){const _0x158f6c=a26_0x1f8493;logger[_0x158f6c(0xd3)](process[_0x158f6c(0xba)]()),logger[_0x158f6c(0xa9)]('skill-install',_0x158f6c(0xb8)+CLI_DISPLAY_NAME+'\x20skill\x20via\x20npx.');const {LOVRABET_SKILL_SOURCE:_0xda66d6,LOVRABET_SKIP_NPX_SKILLS_ENV:_0x23ec9d,runNpxSkillsAddGlobal:_0x2edee6}=await import(_0x158f6c(0xc8)),_0x7c0e23=_0x17e9b4['nonInteractive']?_0x158f6c(0x9c):'inherit';console[_0x158f6c(0xcc)](_0x158f6c(0xc4)+_0xda66d6+_0x158f6c(0x99));const _0x2554a4=_0x2edee6(process['cwd'](),_0xda66d6,{'stdio':_0x7c0e23});if(_0x2554a4[_0x158f6c(0xb7)])console[_0x158f6c(0xcc)](_0x158f6c(0xb6)+_0x23ec9d+_0x158f6c(0xa0));else{if(_0x2554a4['ok'])console[_0x158f6c(0xcc)](CLI_BIN_NAME+_0x158f6c(0xaf));else throw CliErrors[_0x158f6c(0xa5)](_0x158f6c(0xca)+(_0x2554a4[_0x158f6c(0xc0)]||_0x158f6c(0xac)),_0x158f6c(0xa1));}return{'ok':!![]};}},{'service':'skill','command':a26_0x1f8493(0x9b),'description':a26_0x1f8493(0xc6),'risk':'write','flags':[CODE_FLAG],async 'execute'(_0x170553){const _0x628d4b=a26_0x1f8493,{listCompanyRuntimeSkills:_0x3be2a2,listPersonalRuntimeSkills:_0x5e49d2}=await import(_0x628d4b(0xce)),{linkEffectiveRuntimeSkills:_0x196a67,materializeRuntimeSkill:_0x3089b4}=await import(_0x628d4b(0xc3)),_0x2d9241=_0x170553[_0x628d4b(0xd2)]('code'),_0x411f1b=_0x170553[_0x628d4b(0xd0)]??_0x628d4b(0xd1),_0x226c54=_0x170553[_0x628d4b(0x97)];if(!_0x226c54)throw CliErrors[_0x628d4b(0xb4)]();const _0x1ffb67=filterByCode(await _0x5e49d2(_0x170553[_0x628d4b(0xc5)]),_0x2d9241),_0x3f95d5=filterByCode(await _0x3be2a2(_0x170553[_0x628d4b(0xc5)]),_0x2d9241),_0x95cb40=[..._0x1ffb67[_0x628d4b(0xad)](_0x531f06=>_0x3089b4(_0x531f06,_0x628d4b(0xaa),{'env':_0x411f1b,'accessKey':_0x226c54,'appCode':_0x170553[_0x628d4b(0xc5)]})),..._0x3f95d5[_0x628d4b(0xad)](_0x294be4=>_0x3089b4(_0x294be4,_0x628d4b(0xa2),{'env':_0x411f1b,'accessKey':_0x226c54,'appCode':_0x170553[_0x628d4b(0xc5)]}))],_0x34fbf0=_0x196a67(_0x95cb40,_0x170553[_0x628d4b(0xc5)]),_0x475d4c=_0x34fbf0[_0x628d4b(0xc1)]((_0x4ccf9c,_0x49df5b)=>{const _0x5ac16f=_0x628d4b;return _0x4ccf9c[_0x49df5b[_0x5ac16f(0xb2)]]=(_0x4ccf9c[_0x49df5b['action']]??0x0)+0x1,_0x4ccf9c;},{});return{'ok':!![],'data':{'appCode':_0x170553['appCode'],'personal':_0x1ffb67[_0x628d4b(0xb5)],'company':_0x3f95d5[_0x628d4b(0xb5)],'materialized':_0x95cb40[_0x628d4b(0xb5)],'links':{'total':_0x34fbf0[_0x628d4b(0xb5)],'created':_0x475d4c[_0x628d4b(0xa6)]??0x0,'updated':_0x475d4c[_0x628d4b(0xcf)]??0x0,'unchanged':_0x475d4c['unchanged']??0x0,'skipped':0x0,'conflicted':0x0},'skills':{'personal':_0x1ffb67[_0x628d4b(0xad)](summarizeRuntimeSkill),'company':_0x3f95d5[_0x628d4b(0xad)](summarizeRuntimeSkill)}},'message':_0x628d4b(0xb3)+_0x1ffb67[_0x628d4b(0xb5)]+'\x20personal\x20and\x20'+_0x3f95d5[_0x628d4b(0xb5)]+_0x628d4b(0xb0)};}},{'service':'skill','command':a26_0x1f8493(0xc2),'description':'Push\x20a\x20local\x20Skill\x20directory\x20to\x20personal\x20runtime\x20Skill\x20scope','risk':a26_0x1f8493(0xa8),'flags':[DIR_FLAG],async 'execute'(_0x2b6878){const _0x5640a9=a26_0x1f8493,{createPersonalRuntimeSkill:_0x5b7991,listPersonalRuntimeSkills:_0x138e44,updatePersonalRuntimeSkill:_0x41ecdc}=await import(_0x5640a9(0xce)),{readPushDirectory:_0x239c5a}=await import(_0x5640a9(0xc3));if(!_0x2b6878[_0x5640a9(0x97)])throw CliErrors['authRequired']();const _0x37a2aa=_0x239c5a(_0x2b6878[_0x5640a9(0xd2)](_0x5640a9(0xa7)),_0x2b6878['appCode']),_0x31cf58=(await _0x138e44(_0x2b6878[_0x5640a9(0xc5)]))['find'](_0x1ab898=>_0x1ab898[_0x5640a9(0xcd)]===_0x37a2aa[_0x5640a9(0xcd)]),_0x2348e4=_0x31cf58?await _0x41ecdc(_0x37a2aa['skillCode'],_0x2b6878[_0x5640a9(0xc5)],_0x37a2aa[_0x5640a9(0xbc)]):await _0x5b7991(_0x2b6878[_0x5640a9(0xc5)],_0x37a2aa[_0x5640a9(0xbc)]);return{'ok':!![],'data':summarizeRuntimeSkill(_0x2348e4),'message':_0x31cf58?_0x5640a9(0xd6)+_0x37a2aa[_0x5640a9(0xcd)]:_0x5640a9(0x96)+_0x37a2aa[_0x5640a9(0xcd)]};}}];
@@ -1 +1 @@
1
- function a26_0x1cc0(){const _0x317b40=['sqlCode','22OSiBAC','read','verbose','135ZFDGUS','7ZJJnJn','315VjITrZ','203416bsdISh','264154GRuaCv','10901508cvTmDk','8225046OuRkHW','26948JqqECk','sql','2qcELBC','bool','appCode','341610JYFUpq','description','sqlContent','dbId','detail','2054643rHIVfn','sqlName'];a26_0x1cc0=function(){return _0x317b40;};return a26_0x1cc0();}const a26_0x48093b=a26_0x2402;(function(_0x3339fe,_0x1d9c96){const _0x175fa2=a26_0x2402,_0x273288=_0x3339fe();while(!![]){try{const _0x2af669=parseInt(_0x175fa2(0xe9))/0x1+-parseInt(_0x175fa2(0xee))/0x2*(parseInt(_0x175fa2(0xf6))/0x3)+parseInt(_0x175fa2(0xec))/0x4*(-parseInt(_0x175fa2(0xe5))/0x5)+-parseInt(_0x175fa2(0xeb))/0x6*(parseInt(_0x175fa2(0xe6))/0x7)+parseInt(_0x175fa2(0xe8))/0x8*(parseInt(_0x175fa2(0xe7))/0x9)+-parseInt(_0x175fa2(0xf1))/0xa+-parseInt(_0x175fa2(0xf9))/0xb*(-parseInt(_0x175fa2(0xea))/0xc);if(_0x2af669===_0x1d9c96)break;else _0x273288['push'](_0x273288['shift']());}catch(_0x2d735d){_0x273288['push'](_0x273288['shift']());}}}(a26_0x1cc0,0xaab63));function a26_0x2402(_0x544e2f,_0x297f1c){_0x544e2f=_0x544e2f-0xe5;const _0x1cc088=a26_0x1cc0();let _0x24025c=_0x1cc088[_0x544e2f];return _0x24025c;}import{getSqlQueryInfo}from'../../core/api-client.js';import{getDbName}from'../../core/db-resolver.js';import{SQLCODE_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';export const sqlDetail={'service':a26_0x48093b(0xed),'command':a26_0x48093b(0xf5),'description':'Get\x20custom\x20SQL\x20query\x20details\x20by\x20sqlCode','risk':a26_0x48093b(0xfa),'flags':[SQLCODE_FLAG,VERBOSE_FLAG],async 'execute'(_0x2d125a){const _0x4cae19=a26_0x48093b,_0x4d4c23=await getSqlQueryInfo(_0x2d125a[_0x4cae19(0xf0)],_0x2d125a['str']('sqlcode')),_0x17f434=_0x2d125a[_0x4cae19(0xef)](_0x4cae19(0xfb));if(_0x17f434)return{'ok':!![],'data':_0x4d4c23};const _0x27b874=_0x4d4c23['dbId']?await getDbName(_0x2d125a[_0x4cae19(0xf0)],_0x4d4c23['dbId']):undefined;return{'ok':!![],'data':{'sqlCode':_0x4d4c23[_0x4cae19(0xf8)],'sqlName':_0x4d4c23[_0x4cae19(0xf7)],'db':_0x27b874?_0x27b874+'\x20('+_0x4d4c23[_0x4cae19(0xf4)]+')':_0x4d4c23[_0x4cae19(0xf4)]??'','description':_0x4d4c23[_0x4cae19(0xf2)]??'','sqlContent':_0x4d4c23[_0x4cae19(0xf3)]??''}};}};
1
+ function a27_0x12ed(_0xc7337d,_0x3a9c4c){_0xc7337d=_0xc7337d-0x16f;const _0x68627=a27_0x6862();let _0x12edd4=_0x68627[_0xc7337d];return _0x12edd4;}function a27_0x6862(){const _0x3c03c=['sqlName','appCode','verbose','498687FPRsOm','Get\x20custom\x20SQL\x20query\x20details\x20by\x20sqlCode','972639QqALbq','2532080tHoamy','detail','2305oTXAUu','454092AwDfNe','1528320fXWRAs','dbId','str','82URKWHg','description','sqlContent','bool','sql','8yUMrkD','read','1058595bXCZxc','sqlcode'];a27_0x6862=function(){return _0x3c03c;};return a27_0x6862();}const a27_0x383fb5=a27_0x12ed;(function(_0x4dd54c,_0x3b8615){const _0x81aabc=a27_0x12ed,_0x35092a=_0x4dd54c();while(!![]){try{const _0x5d6984=-parseInt(_0x81aabc(0x17b))/0x1*(parseInt(_0x81aabc(0x180))/0x2)+parseInt(_0x81aabc(0x171))/0x3+-parseInt(_0x81aabc(0x17d))/0x4+parseInt(_0x81aabc(0x179))/0x5+-parseInt(_0x81aabc(0x17c))/0x6+-parseInt(_0x81aabc(0x176))/0x7+parseInt(_0x81aabc(0x16f))/0x8*(parseInt(_0x81aabc(0x178))/0x9);if(_0x5d6984===_0x3b8615)break;else _0x35092a['push'](_0x35092a['shift']());}catch(_0x3c714f){_0x35092a['push'](_0x35092a['shift']());}}}(a27_0x6862,0x53f24));import{getSqlQueryInfo}from'../../core/api-client.js';import{getDbName}from'../../core/db-resolver.js';import{SQLCODE_FLAG,VERBOSE_FLAG}from'../../commands/common/flags.js';export const sqlDetail={'service':a27_0x383fb5(0x184),'command':a27_0x383fb5(0x17a),'description':a27_0x383fb5(0x177),'risk':a27_0x383fb5(0x170),'flags':[SQLCODE_FLAG,VERBOSE_FLAG],async 'execute'(_0x34dd2d){const _0x3edfe7=a27_0x383fb5,_0x33c30d=await getSqlQueryInfo(_0x34dd2d[_0x3edfe7(0x174)],_0x34dd2d[_0x3edfe7(0x17f)](_0x3edfe7(0x172))),_0x45c953=_0x34dd2d[_0x3edfe7(0x183)](_0x3edfe7(0x175));if(_0x45c953)return{'ok':!![],'data':_0x33c30d};const _0x4a22be=_0x33c30d[_0x3edfe7(0x17e)]?await getDbName(_0x34dd2d[_0x3edfe7(0x174)],_0x33c30d['dbId']):undefined;return{'ok':!![],'data':{'sqlCode':_0x33c30d['sqlCode'],'sqlName':_0x33c30d[_0x3edfe7(0x173)],'db':_0x4a22be?_0x4a22be+'\x20('+_0x33c30d[_0x3edfe7(0x17e)]+')':_0x33c30d['dbId']??'','description':_0x33c30d[_0x3edfe7(0x181)]??'','sqlContent':_0x33c30d[_0x3edfe7(0x182)]??''}};}};
@@ -1 +1 @@
1
- function a27_0x12e0(_0x2c4cef,_0x35e662){_0x2c4cef=_0x2c4cef-0x160;const _0x48db7b=a27_0x48db();let _0x12e0ce=_0x48db7b[_0x2c4cef];return _0x12e0ce;}const a27_0x59ba5c=a27_0x12e0;function a27_0x48db(){const _0x552d27=['1255tiVjBU','str','22549zKhnVs','sqlcode','7gpvblp','read','10278EjGqCq','sql','execResult','params','10iQlyMg','execSuccess','866277ktntaR','5709LkuwMe','4300768QONsTI','SQL\x20execution\x20failed','Execute\x20a\x20custom\x20SQL\x20query\x20by\x20sqlCode','358974mUkvIG','Returned\x20','17772WpahRd','execError','length','now','988756GKeXKE','\x20row(s)\x20in\x20','3QVNMbm'];a27_0x48db=function(){return _0x552d27;};return a27_0x48db();}(function(_0x2c95a1,_0x1f132d){const _0x47da74=a27_0x12e0,_0x382150=_0x2c95a1();while(!![]){try{const _0x128a3b=parseInt(_0x47da74(0x16e))/0x1+-parseInt(_0x47da74(0x163))/0x2*(-parseInt(_0x47da74(0x16b))/0x3)+parseInt(_0x47da74(0x169))/0x4+parseInt(_0x47da74(0x16c))/0x5*(-parseInt(_0x47da74(0x172))/0x6)+parseInt(_0x47da74(0x170))/0x7*(-parseInt(_0x47da74(0x160))/0x8)+-parseInt(_0x47da74(0x178))/0x9*(-parseInt(_0x47da74(0x176))/0xa)+-parseInt(_0x47da74(0x179))/0xb*(-parseInt(_0x47da74(0x165))/0xc);if(_0x128a3b===_0x1f132d)break;else _0x382150['push'](_0x382150['shift']());}catch(_0x4ec127){_0x382150['push'](_0x382150['shift']());}}}(a27_0x48db,0x549be));import{executeSdkSql}from'../../core/sdk-client.js';import{SQLCODE_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';import{parseJsonParams}from'../../utils/params.js';export const sqlExec={'service':a27_0x59ba5c(0x173),'command':'exec','description':a27_0x59ba5c(0x162),'risk':a27_0x59ba5c(0x171),'flags':[SQLCODE_FLAG,PARAMS_FLAG],async 'execute'(_0x53d7bd){const _0x1ac792=a27_0x59ba5c,_0x1f2e08=parseJsonParams(_0x53d7bd[_0x1ac792(0x16d)](_0x1ac792(0x175))),_0x36bf81=Date[_0x1ac792(0x168)](),_0x59c693=await executeSdkSql(_0x53d7bd[_0x1ac792(0x16d)](_0x1ac792(0x16f)),_0x1f2e08),_0x1be434=Date[_0x1ac792(0x168)]()-_0x36bf81,_0x54faa8=_0x59c693?.[_0x1ac792(0x174)]??_0x59c693,_0x75279d=_0x59c693?.[_0x1ac792(0x177)]??!![];if(!_0x75279d)return{'ok':![],'data':{'error':_0x59c693?.[_0x1ac792(0x166)]||_0x1ac792(0x161),'elapsed':_0x1be434},'message':_0x1ac792(0x161)};const _0x307dd0=Array['isArray'](_0x54faa8)?_0x54faa8:[];return{'ok':!![],'data':{'rows':_0x307dd0,'rowCount':_0x307dd0[_0x1ac792(0x167)],'elapsed':_0x1be434},'message':_0x1ac792(0x164)+_0x307dd0[_0x1ac792(0x167)]+_0x1ac792(0x16a)+_0x1be434+'ms'};}};
1
+ const a28_0x196826=a28_0x5869;(function(_0x531935,_0x45bd1e){const _0x1f540f=a28_0x5869,_0x31d671=_0x531935();while(!![]){try{const _0x359d6b=-parseInt(_0x1f540f(0xea))/0x1+parseInt(_0x1f540f(0xdc))/0x2+parseInt(_0x1f540f(0xe7))/0x3*(parseInt(_0x1f540f(0xf1))/0x4)+parseInt(_0x1f540f(0xed))/0x5*(parseInt(_0x1f540f(0xeb))/0x6)+-parseInt(_0x1f540f(0xe1))/0x7*(-parseInt(_0x1f540f(0xee))/0x8)+-parseInt(_0x1f540f(0xec))/0x9*(parseInt(_0x1f540f(0xdb))/0xa)+-parseInt(_0x1f540f(0xe0))/0xb*(parseInt(_0x1f540f(0xe4))/0xc);if(_0x359d6b===_0x45bd1e)break;else _0x31d671['push'](_0x31d671['shift']());}catch(_0x58d83e){_0x31d671['push'](_0x31d671['shift']());}}}(a28_0x1f91,0x626b9));import{executeSdkSql}from'../../core/sdk-client.js';import{SQLCODE_FLAG,PARAMS_FLAG}from'../../commands/common/flags.js';function a28_0x5869(_0x459876,_0x429566){_0x459876=_0x459876-0xda;const _0x1f91c1=a28_0x1f91();let _0x58693a=_0x1f91c1[_0x459876];return _0x58693a;}function a28_0x1f91(){const _0x187956=['exec','1985260vWdlLx','1215470YUxnBB','execResult','SQL\x20execution\x20failed','now','11UGkSNR','334978JoXhXc','params','\x20row(s)\x20in\x20','14951412knSBsO','execError','isArray','116691UcHZWM','Execute\x20a\x20custom\x20SQL\x20query\x20by\x20sqlCode','length','58687BkJjAO','344766IopahU','9utyPUN','50nclOBO','56KuoLTf','str','Returned\x20','40jXNrfc'];a28_0x1f91=function(){return _0x187956;};return a28_0x1f91();}import{parseJsonParams}from'../../utils/params.js';export const sqlExec={'service':'sql','command':a28_0x196826(0xda),'description':a28_0x196826(0xe8),'risk':'read','flags':[SQLCODE_FLAG,PARAMS_FLAG],async 'execute'(_0x325468){const _0x533816=a28_0x196826,_0xaf02f3=parseJsonParams(_0x325468[_0x533816(0xef)](_0x533816(0xe2))),_0x39f592=Date['now'](),_0xa92bef=await executeSdkSql(_0x325468[_0x533816(0xef)]('sqlcode'),_0xaf02f3),_0xe9b914=Date[_0x533816(0xdf)]()-_0x39f592,_0x359a9c=_0xa92bef?.[_0x533816(0xdd)]??_0xa92bef,_0x1d54e1=_0xa92bef?.['execSuccess']??!![];if(!_0x1d54e1)return{'ok':![],'data':{'error':_0xa92bef?.[_0x533816(0xe5)]||'SQL\x20execution\x20failed','elapsed':_0xe9b914},'message':_0x533816(0xde)};const _0x545ffb=Array[_0x533816(0xe6)](_0x359a9c)?_0x359a9c:[];return{'ok':!![],'data':{'rows':_0x545ffb,'rowCount':_0x545ffb[_0x533816(0xe9)],'elapsed':_0xe9b914},'message':_0x533816(0xf0)+_0x545ffb[_0x533816(0xe9)]+_0x533816(0xe3)+_0xe9b914+'ms'};}};
@@ -1 +1 @@
1
- (function(_0x59cf0b,_0xd76761){const _0x13acdd=a28_0x4388,_0x3e9151=_0x59cf0b();while(!![]){try{const _0x7b33a5=-parseInt(_0x13acdd(0xdc))/0x1+-parseInt(_0x13acdd(0xde))/0x2+parseInt(_0x13acdd(0xd7))/0x3+-parseInt(_0x13acdd(0xd6))/0x4*(-parseInt(_0x13acdd(0xdf))/0x5)+parseInt(_0x13acdd(0xdb))/0x6*(parseInt(_0x13acdd(0xd9))/0x7)+-parseInt(_0x13acdd(0xdd))/0x8*(parseInt(_0x13acdd(0xda))/0x9)+parseInt(_0x13acdd(0xd8))/0xa;if(_0x7b33a5===_0xd76761)break;else _0x3e9151['push'](_0x3e9151['shift']());}catch(_0x3349fa){_0x3e9151['push'](_0x3e9151['shift']());}}}(a28_0x5147,0xa52b1));import{sqlDetail}from'../../commands/sql/detail.js';function a28_0x5147(){const _0x14f710=['71752XFrPkh','1286967CmoYoY','27295250DpwRdv','1705662iaZdnc','64026MJDsgC','6zEeVwO','1248710yLDysS','848nBMjnW','1840350SPoTQq','55zdhqaY'];a28_0x5147=function(){return _0x14f710;};return a28_0x5147();}import{sqlExec}from'../../commands/sql/exec.js';function a28_0x4388(_0x66cb8e,_0xaab127){_0x66cb8e=_0x66cb8e-0xd6;const _0x514794=a28_0x5147();let _0x4388df=_0x514794[_0x66cb8e];return _0x4388df;}export const sqlDefinitions=[sqlDetail,sqlExec];
1
+ (function(_0x4873ab,_0x2f85fb){const _0x3180b5=a29_0x42b5,_0xda7d3e=_0x4873ab();while(!![]){try{const _0x11849a=parseInt(_0x3180b5(0xba))/0x1*(parseInt(_0x3180b5(0xbd))/0x2)+parseInt(_0x3180b5(0xbb))/0x3+-parseInt(_0x3180b5(0xb8))/0x4+-parseInt(_0x3180b5(0xbf))/0x5+parseInt(_0x3180b5(0xbe))/0x6+-parseInt(_0x3180b5(0xb7))/0x7*(parseInt(_0x3180b5(0xb9))/0x8)+-parseInt(_0x3180b5(0xbc))/0x9;if(_0x11849a===_0x2f85fb)break;else _0xda7d3e['push'](_0xda7d3e['shift']());}catch(_0xce0d79){_0xda7d3e['push'](_0xda7d3e['shift']());}}}(a29_0x1fc1,0x4db62));import{sqlDetail}from'../../commands/sql/detail.js';function a29_0x1fc1(){const _0x377b26=['2QIjClJ','3469926Hyelks','2602685tliKPs','1853509kTiKpZ','725516gAMMJZ','8YvCjAy','276162zVrFiH','1365828piSeIX','222750HsypuI'];a29_0x1fc1=function(){return _0x377b26;};return a29_0x1fc1();}import{sqlExec}from'../../commands/sql/exec.js';function a29_0x42b5(_0x3902c1,_0x599e43){_0x3902c1=_0x3902c1-0xb7;const _0x1fc1f3=a29_0x1fc1();let _0x42b540=_0x1fc1f3[_0x3902c1];return _0x42b540;}export const sqlDefinitions=[sqlDetail,sqlExec];