@peernova/cuneiform-sf 1.0.2 → 1.0.4-beta.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +81 -30
- package/README.md +59 -95
- package/lib/adapters/connection-facade.d.ts +458 -0
- package/lib/adapters/connection-facade.js +379 -0
- package/lib/adapters/connection-facade.js.map +1 -0
- package/lib/adapters/errors.d.ts +547 -0
- package/lib/adapters/errors.js +937 -0
- package/lib/adapters/errors.js.map +1 -0
- package/lib/adapters/index.d.ts +33 -0
- package/lib/adapters/index.js +50 -0
- package/lib/adapters/index.js.map +1 -0
- package/lib/adapters/lifecycle.d.ts +119 -0
- package/lib/adapters/lifecycle.js +94 -0
- package/lib/adapters/lifecycle.js.map +1 -0
- package/lib/adapters/rest/cache.d.ts +69 -0
- package/lib/adapters/rest/cache.js +133 -0
- package/lib/adapters/rest/cache.js.map +1 -0
- package/lib/adapters/rest/index.d.ts +11 -0
- package/lib/adapters/rest/index.js +18 -0
- package/lib/adapters/rest/index.js.map +1 -0
- package/lib/adapters/rest/profiling-rest-client.d.ts +137 -0
- package/lib/adapters/rest/profiling-rest-client.js +115 -0
- package/lib/adapters/rest/profiling-rest-client.js.map +1 -0
- package/lib/adapters/rest/rest-api-adapter.d.ts +389 -0
- package/lib/adapters/rest/rest-api-adapter.js +747 -0
- package/lib/adapters/rest/rest-api-adapter.js.map +1 -0
- package/lib/adapters/rest/types.d.ts +34 -0
- package/lib/adapters/rest/types.js +9 -0
- package/lib/adapters/rest/types.js.map +1 -0
- package/lib/adapters/retry.d.ts +91 -0
- package/lib/adapters/retry.js +215 -0
- package/lib/adapters/retry.js.map +1 -0
- package/lib/adapters/soql/cuneiform-query-builder.d.ts +391 -0
- package/lib/adapters/soql/cuneiform-query-builder.js +559 -0
- package/lib/adapters/soql/cuneiform-query-builder.js.map +1 -0
- package/lib/adapters/soql/index.d.ts +13 -0
- package/lib/adapters/soql/index.js +21 -0
- package/lib/adapters/soql/index.js.map +1 -0
- package/lib/adapters/soql/soql-query-adapter.d.ts +141 -0
- package/lib/adapters/soql/soql-query-adapter.js +259 -0
- package/lib/adapters/soql/soql-query-adapter.js.map +1 -0
- package/lib/adapters/soql/types.d.ts +37 -0
- package/lib/adapters/soql/types.js +19 -0
- package/lib/adapters/soql/types.js.map +1 -0
- package/lib/adapters/testing/index.d.ts +37 -0
- package/lib/adapters/testing/index.js +20 -0
- package/lib/adapters/testing/index.js.map +1 -0
- package/lib/adapters/testing/mock-connection.d.ts +77 -0
- package/lib/adapters/testing/mock-connection.js +207 -0
- package/lib/adapters/testing/mock-connection.js.map +1 -0
- package/lib/adapters/testing/mock-logger.d.ts +29 -0
- package/lib/adapters/testing/mock-logger.js +57 -0
- package/lib/adapters/testing/mock-logger.js.map +1 -0
- package/lib/adapters/testing/mock-mcp-adapters.d.ts +32 -0
- package/lib/adapters/testing/mock-mcp-adapters.js +52 -0
- package/lib/adapters/testing/mock-mcp-adapters.js.map +1 -0
- package/lib/adapters/testing/mock-oclif-config.d.ts +22 -0
- package/lib/adapters/testing/mock-oclif-config.js +90 -0
- package/lib/adapters/testing/mock-oclif-config.js.map +1 -0
- package/lib/adapters/testing/mock-rest-adapter.d.ts +26 -0
- package/lib/adapters/testing/mock-rest-adapter.js +243 -0
- package/lib/adapters/testing/mock-rest-adapter.js.map +1 -0
- package/lib/adapters/testing/mock-salesforce-connection.d.ts +40 -0
- package/lib/adapters/testing/mock-salesforce-connection.js +61 -0
- package/lib/adapters/testing/mock-salesforce-connection.js.map +1 -0
- package/lib/adapters/testing/mock-soql-adapter.d.ts +30 -0
- package/lib/adapters/testing/mock-soql-adapter.js +120 -0
- package/lib/adapters/testing/mock-soql-adapter.js.map +1 -0
- package/lib/adapters/testing/mock-tooling-adapter.d.ts +24 -0
- package/lib/adapters/testing/mock-tooling-adapter.js +163 -0
- package/lib/adapters/testing/mock-tooling-adapter.js.map +1 -0
- package/lib/adapters/testing/stub-connection.d.ts +93 -0
- package/lib/adapters/testing/stub-connection.js +97 -0
- package/lib/adapters/testing/stub-connection.js.map +1 -0
- package/lib/adapters/testing/stub-rest-adapter.d.ts +52 -0
- package/lib/adapters/testing/stub-rest-adapter.js +58 -0
- package/lib/adapters/testing/stub-rest-adapter.js.map +1 -0
- package/lib/adapters/testing/stub-soql-adapter.d.ts +56 -0
- package/lib/adapters/testing/stub-soql-adapter.js +50 -0
- package/lib/adapters/testing/stub-soql-adapter.js.map +1 -0
- package/lib/adapters/testing/types.d.ts +71 -0
- package/lib/adapters/testing/types.js +9 -0
- package/lib/adapters/testing/types.js.map +1 -0
- package/lib/adapters/tooling/index.d.ts +10 -0
- package/lib/adapters/tooling/index.js +17 -0
- package/lib/adapters/tooling/index.js.map +1 -0
- package/lib/adapters/tooling/tooling-api-adapter.d.ts +157 -0
- package/lib/adapters/tooling/tooling-api-adapter.js +339 -0
- package/lib/adapters/tooling/tooling-api-adapter.js.map +1 -0
- package/lib/adapters/tooling/types.d.ts +81 -0
- package/lib/adapters/tooling/types.js +9 -0
- package/lib/adapters/tooling/types.js.map +1 -0
- package/lib/adapters/types.d.ts +112 -0
- package/lib/adapters/types.js +169 -0
- package/lib/adapters/types.js.map +1 -0
- package/lib/base/cuneiform-command.d.ts +152 -0
- package/lib/base/cuneiform-command.js +243 -0
- package/lib/base/cuneiform-command.js.map +1 -0
- package/lib/commands/cuneiform/compatibility/check.d.ts +43 -0
- package/lib/commands/cuneiform/compatibility/check.js +114 -0
- package/lib/commands/cuneiform/compatibility/check.js.map +1 -0
- package/lib/commands/cuneiform/definition/create.d.ts +119 -0
- package/lib/commands/cuneiform/definition/create.js +693 -0
- package/lib/commands/cuneiform/definition/create.js.map +1 -0
- package/lib/commands/cuneiform/definition/export.d.ts +57 -0
- package/lib/commands/cuneiform/definition/export.js +133 -0
- package/lib/commands/cuneiform/definition/export.js.map +1 -0
- package/lib/commands/cuneiform/definition/get.d.ts +86 -0
- package/lib/commands/cuneiform/definition/get.js +270 -0
- package/lib/commands/cuneiform/definition/get.js.map +1 -0
- package/lib/commands/cuneiform/definition/import.d.ts +54 -0
- package/lib/commands/cuneiform/definition/import.js +118 -0
- package/lib/commands/cuneiform/definition/import.js.map +1 -0
- package/lib/commands/cuneiform/definition/list.d.ts +110 -0
- package/lib/commands/cuneiform/definition/list.js +344 -0
- package/lib/commands/cuneiform/definition/list.js.map +1 -0
- package/lib/commands/cuneiform/definition/purge.d.ts +105 -0
- package/lib/commands/cuneiform/definition/purge.js +533 -0
- package/lib/commands/cuneiform/definition/purge.js.map +1 -0
- package/lib/commands/cuneiform/definition/update.d.ts +58 -0
- package/lib/commands/cuneiform/definition/update.js +206 -0
- package/lib/commands/cuneiform/definition/update.js.map +1 -0
- package/lib/commands/cuneiform/mcp/serve.d.ts +56 -0
- package/lib/commands/cuneiform/mcp/serve.js +109 -0
- package/lib/commands/cuneiform/mcp/serve.js.map +1 -0
- package/lib/commands/cuneiform/object/describe.d.ts +61 -0
- package/lib/commands/cuneiform/object/describe.js +461 -0
- package/lib/commands/cuneiform/object/describe.js.map +1 -0
- package/lib/commands/cuneiform/object/list.d.ts +111 -0
- package/lib/commands/cuneiform/object/list.js +239 -0
- package/lib/commands/cuneiform/object/list.js.map +1 -0
- package/lib/commands/cuneiform/org/details.d.ts +99 -0
- package/lib/commands/cuneiform/org/details.js +521 -0
- package/lib/commands/cuneiform/org/details.js.map +1 -0
- package/lib/commands/cuneiform/org/reset.d.ts +46 -0
- package/lib/commands/cuneiform/org/reset.js +135 -0
- package/lib/commands/cuneiform/org/reset.js.map +1 -0
- package/lib/commands/cuneiform/profile/request/cancel.d.ts +59 -0
- package/lib/commands/cuneiform/profile/request/cancel.js +202 -0
- package/lib/commands/cuneiform/profile/request/cancel.js.map +1 -0
- package/lib/commands/cuneiform/profile/request/delete.d.ts +59 -0
- package/lib/commands/cuneiform/profile/request/delete.js +223 -0
- package/lib/commands/cuneiform/profile/request/delete.js.map +1 -0
- package/lib/commands/cuneiform/profile/request/list.d.ts +35 -0
- package/lib/commands/cuneiform/profile/request/list.js +102 -0
- package/lib/commands/cuneiform/profile/request/list.js.map +1 -0
- package/lib/commands/cuneiform/profile.d.ts +90 -0
- package/lib/commands/cuneiform/profile.js +322 -0
- package/lib/commands/cuneiform/profile.js.map +1 -0
- package/lib/commands/cuneiform/summary/purge.d.ts +77 -0
- package/lib/commands/cuneiform/summary/purge.js +429 -0
- package/lib/commands/cuneiform/summary/purge.js.map +1 -0
- package/lib/commands/cuneiform/summary/reprofile.d.ts +60 -0
- package/lib/commands/cuneiform/summary/reprofile.js +236 -0
- package/lib/commands/cuneiform/summary/reprofile.js.map +1 -0
- package/lib/commands/cuneiform/summary/stop.d.ts +59 -0
- package/lib/commands/cuneiform/summary/stop.js +234 -0
- package/lib/commands/cuneiform/summary/stop.js.map +1 -0
- package/lib/commands/cuneiform/user/details.d.ts +73 -0
- package/lib/commands/cuneiform/user/details.js +391 -0
- package/lib/commands/cuneiform/user/details.js.map +1 -0
- package/lib/constants/index.d.ts +8 -0
- package/lib/constants/index.js +16 -0
- package/lib/constants/index.js.map +1 -0
- package/lib/constants/namespace-constants.d.ts +91 -0
- package/lib/constants/namespace-constants.js +211 -0
- package/lib/constants/namespace-constants.js.map +1 -0
- package/lib/debug/command-debug-proxy.d.ts +101 -0
- package/lib/debug/command-debug-proxy.js +171 -0
- package/lib/debug/command-debug-proxy.js.map +1 -0
- package/lib/debug/debug-logger.d.ts +85 -0
- package/lib/debug/debug-logger.js +133 -0
- package/lib/debug/debug-logger.js.map +1 -0
- package/lib/debug/index.d.ts +12 -0
- package/lib/debug/index.js +20 -0
- package/lib/debug/index.js.map +1 -0
- package/lib/debug/service-debug-proxy.d.ts +30 -0
- package/lib/debug/service-debug-proxy.js +102 -0
- package/lib/debug/service-debug-proxy.js.map +1 -0
- package/lib/hooks/prerun.d.ts +25 -0
- package/lib/hooks/prerun.js +47 -0
- package/lib/hooks/prerun.js.map +1 -0
- package/lib/mcp/config/mcp-config.d.ts +55 -0
- package/lib/mcp/config/mcp-config.js +51 -0
- package/lib/mcp/config/mcp-config.js.map +1 -0
- package/lib/mcp/config/pagination.d.ts +96 -0
- package/lib/mcp/config/pagination.js +108 -0
- package/lib/mcp/config/pagination.js.map +1 -0
- package/lib/mcp/config/system-prompts.d.ts +18 -0
- package/lib/mcp/config/system-prompts.js +92 -0
- package/lib/mcp/config/system-prompts.js.map +1 -0
- package/lib/mcp/errors.d.ts +23 -0
- package/lib/mcp/errors.js +27 -0
- package/lib/mcp/errors.js.map +1 -0
- package/lib/mcp/schemas/input-schemas.d.ts +327 -0
- package/lib/mcp/schemas/input-schemas.js +302 -0
- package/lib/mcp/schemas/input-schemas.js.map +1 -0
- package/lib/mcp/server.d.ts +40 -0
- package/lib/mcp/server.js +316 -0
- package/lib/mcp/server.js.map +1 -0
- package/lib/mcp/tools/contactpoint-tools.d.ts +14 -0
- package/lib/mcp/tools/contactpoint-tools.js +34 -0
- package/lib/mcp/tools/contactpoint-tools.js.map +1 -0
- package/lib/mcp/tools/definition-io-tools.d.ts +19 -0
- package/lib/mcp/tools/definition-io-tools.js +152 -0
- package/lib/mcp/tools/definition-io-tools.js.map +1 -0
- package/lib/mcp/tools/definition-tools.d.ts +51 -0
- package/lib/mcp/tools/definition-tools.js +199 -0
- package/lib/mcp/tools/definition-tools.js.map +1 -0
- package/lib/mcp/tools/index.d.ts +37 -0
- package/lib/mcp/tools/index.js +88 -0
- package/lib/mcp/tools/index.js.map +1 -0
- package/lib/mcp/tools/object-tools.d.ts +22 -0
- package/lib/mcp/tools/object-tools.js +306 -0
- package/lib/mcp/tools/object-tools.js.map +1 -0
- package/lib/mcp/tools/org-tools.d.ts +14 -0
- package/lib/mcp/tools/org-tools.js +177 -0
- package/lib/mcp/tools/org-tools.js.map +1 -0
- package/lib/mcp/tools/profile-tools.d.ts +59 -0
- package/lib/mcp/tools/profile-tools.js +213 -0
- package/lib/mcp/tools/profile-tools.js.map +1 -0
- package/lib/mcp/tools/summary-tools.d.ts +14 -0
- package/lib/mcp/tools/summary-tools.js +38 -0
- package/lib/mcp/tools/summary-tools.js.map +1 -0
- package/lib/mcp/tools/tool-factory.d.ts +63 -0
- package/lib/mcp/tools/tool-factory.js +146 -0
- package/lib/mcp/tools/tool-factory.js.map +1 -0
- package/lib/mcp/tools/user-tools.d.ts +25 -0
- package/lib/mcp/tools/user-tools.js +167 -0
- package/lib/mcp/tools/user-tools.js.map +1 -0
- package/lib/models/date-literal.d.ts +211 -0
- package/lib/models/date-literal.js +615 -0
- package/lib/models/date-literal.js.map +1 -0
- package/lib/models/object-describe-types.d.ts +173 -0
- package/lib/models/object-describe-types.js +9 -0
- package/lib/models/object-describe-types.js.map +1 -0
- package/lib/models/profile-request-types.d.ts +118 -0
- package/lib/models/profile-request-types.js +23 -0
- package/lib/models/profile-request-types.js.map +1 -0
- package/lib/models/profiling-execution-types.d.ts +154 -0
- package/lib/models/profiling-execution-types.js +14 -0
- package/lib/models/profiling-execution-types.js.map +1 -0
- package/lib/models/service-result.d.ts +114 -0
- package/lib/models/service-result.js +81 -0
- package/lib/models/service-result.js.map +1 -0
- package/lib/models/sfdmu-types.d.ts +53 -0
- package/lib/models/sfdmu-types.js +23 -0
- package/lib/models/sfdmu-types.js.map +1 -0
- package/lib/models/status-types.d.ts +38 -0
- package/lib/models/status-types.js +12 -0
- package/lib/models/status-types.js.map +1 -0
- package/lib/models/summary-bulk-types.d.ts +61 -0
- package/lib/models/summary-bulk-types.js +23 -0
- package/lib/models/summary-bulk-types.js.map +1 -0
- package/lib/models/user-details-types.d.ts +163 -0
- package/lib/models/user-details-types.js +9 -0
- package/lib/models/user-details-types.js.map +1 -0
- package/lib/models/year-range.d.ts +78 -0
- package/lib/models/year-range.js +153 -0
- package/lib/models/year-range.js.map +1 -0
- package/lib/operations/CompatibilityCheckOperation.d.ts +62 -0
- package/lib/operations/CompatibilityCheckOperation.js +102 -0
- package/lib/operations/CompatibilityCheckOperation.js.map +1 -0
- package/lib/operations/DefinitionCreateOperation.d.ts +411 -0
- package/lib/operations/DefinitionCreateOperation.js +1121 -0
- package/lib/operations/DefinitionCreateOperation.js.map +1 -0
- package/lib/operations/DefinitionExportOperation.d.ts +155 -0
- package/lib/operations/DefinitionExportOperation.js +281 -0
- package/lib/operations/DefinitionExportOperation.js.map +1 -0
- package/lib/operations/DefinitionImportOperation.d.ts +144 -0
- package/lib/operations/DefinitionImportOperation.js +357 -0
- package/lib/operations/DefinitionImportOperation.js.map +1 -0
- package/lib/operations/DefinitionListOperation.d.ts +66 -0
- package/lib/operations/DefinitionListOperation.js +108 -0
- package/lib/operations/DefinitionListOperation.js.map +1 -0
- package/lib/operations/DefinitionPurgeOperation.d.ts +199 -0
- package/lib/operations/DefinitionPurgeOperation.js +465 -0
- package/lib/operations/DefinitionPurgeOperation.js.map +1 -0
- package/lib/operations/DefinitionUpdateOperation.d.ts +78 -0
- package/lib/operations/DefinitionUpdateOperation.js +142 -0
- package/lib/operations/DefinitionUpdateOperation.js.map +1 -0
- package/lib/operations/OrgDetailsOperation.d.ts +253 -0
- package/lib/operations/OrgDetailsOperation.js +456 -0
- package/lib/operations/OrgDetailsOperation.js.map +1 -0
- package/lib/operations/OrgResetOperation.d.ts +114 -0
- package/lib/operations/OrgResetOperation.js +209 -0
- package/lib/operations/OrgResetOperation.js.map +1 -0
- package/lib/operations/ProfileOperation.d.ts +187 -0
- package/lib/operations/ProfileOperation.js +373 -0
- package/lib/operations/ProfileOperation.js.map +1 -0
- package/lib/operations/ProfileRequestCancelOperation.d.ts +59 -0
- package/lib/operations/ProfileRequestCancelOperation.js +137 -0
- package/lib/operations/ProfileRequestCancelOperation.js.map +1 -0
- package/lib/operations/ProfileRequestDeleteOperation.d.ts +64 -0
- package/lib/operations/ProfileRequestDeleteOperation.js +134 -0
- package/lib/operations/ProfileRequestDeleteOperation.js.map +1 -0
- package/lib/operations/ProfileRequestListOperation.d.ts +39 -0
- package/lib/operations/ProfileRequestListOperation.js +61 -0
- package/lib/operations/ProfileRequestListOperation.js.map +1 -0
- package/lib/operations/SummaryPurgeOperation.d.ts +134 -0
- package/lib/operations/SummaryPurgeOperation.js +257 -0
- package/lib/operations/SummaryPurgeOperation.js.map +1 -0
- package/lib/operations/SummaryReprofileOperation.d.ts +88 -0
- package/lib/operations/SummaryReprofileOperation.js +174 -0
- package/lib/operations/SummaryReprofileOperation.js.map +1 -0
- package/lib/operations/SummaryStopOperation.d.ts +87 -0
- package/lib/operations/SummaryStopOperation.js +175 -0
- package/lib/operations/SummaryStopOperation.js.map +1 -0
- package/lib/services/BulkExecutionService.d.ts +120 -0
- package/lib/services/BulkExecutionService.js +535 -0
- package/lib/services/BulkExecutionService.js.map +1 -0
- package/lib/services/CompatibilityService.d.ts +81 -0
- package/lib/services/CompatibilityService.js +118 -0
- package/lib/services/CompatibilityService.js.map +1 -0
- package/lib/services/ConfigureMode.d.ts +85 -0
- package/lib/services/ConfigureMode.js +390 -0
- package/lib/services/ConfigureMode.js.map +1 -0
- package/lib/services/ContactPointService.d.ts +111 -0
- package/lib/services/ContactPointService.js +286 -0
- package/lib/services/ContactPointService.js.map +1 -0
- package/lib/services/DataAvailabilityService.d.ts +81 -0
- package/lib/services/DataAvailabilityService.js +128 -0
- package/lib/services/DataAvailabilityService.js.map +1 -0
- package/lib/services/DefinitionFieldGenerationService.d.ts +309 -0
- package/lib/services/DefinitionFieldGenerationService.js +795 -0
- package/lib/services/DefinitionFieldGenerationService.js.map +1 -0
- package/lib/services/DefinitionQueryBuilder.d.ts +59 -0
- package/lib/services/DefinitionQueryBuilder.js +234 -0
- package/lib/services/DefinitionQueryBuilder.js.map +1 -0
- package/lib/services/ObjectDescribeService.d.ts +436 -0
- package/lib/services/ObjectDescribeService.js +869 -0
- package/lib/services/ObjectDescribeService.js.map +1 -0
- package/lib/services/ObjectFilteringService.d.ts +400 -0
- package/lib/services/ObjectFilteringService.js +878 -0
- package/lib/services/ObjectFilteringService.js.map +1 -0
- package/lib/services/ObjectListCommandService.d.ts +429 -0
- package/lib/services/ObjectListCommandService.js +873 -0
- package/lib/services/ObjectListCommandService.js.map +1 -0
- package/lib/services/ObjectListService.d.ts +201 -0
- package/lib/services/ObjectListService.js +345 -0
- package/lib/services/ObjectListService.js.map +1 -0
- package/lib/services/OrgInfoService.d.ts +485 -0
- package/lib/services/OrgInfoService.js +1122 -0
- package/lib/services/OrgInfoService.js.map +1 -0
- package/lib/services/PollingService.d.ts +105 -0
- package/lib/services/PollingService.js +117 -0
- package/lib/services/PollingService.js.map +1 -0
- package/lib/services/ProfileRequestService.d.ts +186 -0
- package/lib/services/ProfileRequestService.js +555 -0
- package/lib/services/ProfileRequestService.js.map +1 -0
- package/lib/services/ProfilingDefinitionService.d.ts +535 -0
- package/lib/services/ProfilingDefinitionService.js +981 -0
- package/lib/services/ProfilingDefinitionService.js.map +1 -0
- package/lib/services/ProfilingExecutionService.d.ts +122 -0
- package/lib/services/ProfilingExecutionService.js +320 -0
- package/lib/services/ProfilingExecutionService.js.map +1 -0
- package/lib/services/ProfilingSummaryService.d.ts +292 -0
- package/lib/services/ProfilingSummaryService.js +685 -0
- package/lib/services/ProfilingSummaryService.js.map +1 -0
- package/lib/services/RecordTypeService.d.ts +129 -0
- package/lib/services/RecordTypeService.js +284 -0
- package/lib/services/RecordTypeService.js.map +1 -0
- package/lib/services/SFDMUService.d.ts +133 -0
- package/lib/services/SFDMUService.js +295 -0
- package/lib/services/SFDMUService.js.map +1 -0
- package/lib/services/TabDetectionService.d.ts +105 -0
- package/lib/services/TabDetectionService.js +206 -0
- package/lib/services/TabDetectionService.js.map +1 -0
- package/lib/services/UnconfigureMode.d.ts +74 -0
- package/lib/services/UnconfigureMode.js +378 -0
- package/lib/services/UnconfigureMode.js.map +1 -0
- package/lib/services/UserConfigurationService.d.ts +155 -0
- package/lib/services/UserConfigurationService.js +573 -0
- package/lib/services/UserConfigurationService.js.map +1 -0
- package/lib/services/UserConfigurationTypes.d.ts +181 -0
- package/lib/services/UserConfigurationTypes.js +14 -0
- package/lib/services/UserConfigurationTypes.js.map +1 -0
- package/lib/services/UserReadinessService.d.ts +330 -0
- package/lib/services/UserReadinessService.js +831 -0
- package/lib/services/UserReadinessService.js.map +1 -0
- package/lib/services/constants.d.ts +53 -0
- package/lib/services/constants.js +71 -0
- package/lib/services/constants.js.map +1 -0
- package/lib/services/namespace-constants.d.ts +1 -0
- package/lib/services/namespace-constants.js +11 -0
- package/lib/services/namespace-constants.js.map +1 -0
- package/lib/services/validation.d.ts +47 -0
- package/lib/services/validation.js +119 -0
- package/lib/services/validation.js.map +1 -0
- package/lib/utils/batch-processor.d.ts +13 -0
- package/lib/utils/batch-processor.js +39 -0
- package/lib/utils/batch-processor.js.map +1 -0
- package/lib/utils/formatting/availability-grid.d.ts +81 -0
- package/lib/utils/formatting/availability-grid.js +94 -0
- package/lib/utils/formatting/availability-grid.js.map +1 -0
- package/lib/utils/formatting/business-process-grid.d.ts +51 -0
- package/lib/utils/formatting/business-process-grid.js +58 -0
- package/lib/utils/formatting/business-process-grid.js.map +1 -0
- package/lib/utils/formatting/command-display.d.ts +154 -0
- package/lib/utils/formatting/command-display.js +154 -0
- package/lib/utils/formatting/command-display.js.map +1 -0
- package/lib/utils/formatting/definition-create-display.d.ts +118 -0
- package/lib/utils/formatting/definition-create-display.js +231 -0
- package/lib/utils/formatting/definition-create-display.js.map +1 -0
- package/lib/utils/formatting/empty-states.d.ts +35 -0
- package/lib/utils/formatting/empty-states.js +70 -0
- package/lib/utils/formatting/empty-states.js.map +1 -0
- package/lib/utils/formatting/errors.d.ts +33 -0
- package/lib/utils/formatting/errors.js +72 -0
- package/lib/utils/formatting/errors.js.map +1 -0
- package/lib/utils/formatting/field-types.d.ts +32 -0
- package/lib/utils/formatting/field-types.js +88 -0
- package/lib/utils/formatting/field-types.js.map +1 -0
- package/lib/utils/formatting/index.d.ts +29 -0
- package/lib/utils/formatting/index.js +28 -0
- package/lib/utils/formatting/index.js.map +1 -0
- package/lib/utils/formatting/indicators.d.ts +113 -0
- package/lib/utils/formatting/indicators.js +161 -0
- package/lib/utils/formatting/indicators.js.map +1 -0
- package/lib/utils/formatting/loading-messages.d.ts +37 -0
- package/lib/utils/formatting/loading-messages.js +50 -0
- package/lib/utils/formatting/loading-messages.js.map +1 -0
- package/lib/utils/formatting/namespace-display.d.ts +31 -0
- package/lib/utils/formatting/namespace-display.js +64 -0
- package/lib/utils/formatting/namespace-display.js.map +1 -0
- package/lib/utils/formatting/numbers.d.ts +73 -0
- package/lib/utils/formatting/numbers.js +187 -0
- package/lib/utils/formatting/numbers.js.map +1 -0
- package/lib/utils/formatting/object-describe-display.d.ts +114 -0
- package/lib/utils/formatting/object-describe-display.js +440 -0
- package/lib/utils/formatting/object-describe-display.js.map +1 -0
- package/lib/utils/formatting/object-list-display.d.ts +213 -0
- package/lib/utils/formatting/object-list-display.js +672 -0
- package/lib/utils/formatting/object-list-display.js.map +1 -0
- package/lib/utils/formatting/org-identity.d.ts +15 -0
- package/lib/utils/formatting/org-identity.js +28 -0
- package/lib/utils/formatting/org-identity.js.map +1 -0
- package/lib/utils/formatting/record-age-grid.d.ts +41 -0
- package/lib/utils/formatting/record-age-grid.js +56 -0
- package/lib/utils/formatting/record-age-grid.js.map +1 -0
- package/lib/utils/formatting/sections.d.ts +108 -0
- package/lib/utils/formatting/sections.js +150 -0
- package/lib/utils/formatting/sections.js.map +1 -0
- package/lib/utils/formatting/tables.d.ts +90 -0
- package/lib/utils/formatting/tables.js +113 -0
- package/lib/utils/formatting/tables.js.map +1 -0
- package/lib/utils/formatting/user-details-display.d.ts +101 -0
- package/lib/utils/formatting/user-details-display.js +425 -0
- package/lib/utils/formatting/user-details-display.js.map +1 -0
- package/lib/utils/pagination/index.d.ts +11 -0
- package/lib/utils/pagination/index.js +18 -0
- package/lib/utils/pagination/index.js.map +1 -0
- package/lib/utils/pagination/keypress-reader.d.ts +20 -0
- package/lib/utils/pagination/keypress-reader.js +63 -0
- package/lib/utils/pagination/keypress-reader.js.map +1 -0
- package/lib/utils/pagination/paginate-output.d.ts +48 -0
- package/lib/utils/pagination/paginate-output.js +136 -0
- package/lib/utils/pagination/paginate-output.js.map +1 -0
- package/messages/compatibility.check.md +71 -0
- package/messages/cuneiform.access.md +138 -0
- package/messages/definition.create.md +511 -0
- package/messages/definition.export.md +84 -0
- package/messages/definition.get.md +147 -0
- package/messages/definition.import.md +65 -0
- package/messages/definition.list.md +264 -0
- package/messages/definition.purge.md +318 -0
- package/messages/definition.update.md +118 -0
- package/messages/mcp.serve.md +66 -0
- package/messages/object.describe.md +201 -0
- package/messages/object.list.md +443 -0
- package/messages/org.details.md +386 -0
- package/messages/org.reset.md +71 -0
- package/messages/profile.md +231 -0
- package/messages/profile.request.cancel.md +143 -0
- package/messages/profile.request.delete.md +139 -0
- package/messages/profile.request.list.md +89 -0
- package/messages/summary.purge.md +218 -0
- package/messages/summary.reprofile.md +150 -0
- package/messages/summary.stop.md +157 -0
- package/messages/user.details.md +501 -0
- package/oclif.lock +2887 -2149
- package/oclif.manifest.json +2813 -31
- package/package.json +94 -19
- package/lib/commands/cuneiform/about.d.ts +0 -13
- package/lib/commands/cuneiform/about.js +0 -26
- package/lib/commands/cuneiform/about.js.map +0 -1
- package/lib/commands/hello/world.d.ts +0 -14
- package/lib/commands/hello/world.js +0 -27
- package/lib/commands/hello/world.js.map +0 -1
- package/lib/index.d.ts +0 -2
- package/lib/index.js +0 -2
- package/lib/index.js.map +0 -1
- package/messages/cuneiform.about.md +0 -19
- package/messages/hello.world.md +0 -29
|
@@ -0,0 +1,223 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2026, PeerNova, Inc. All Rights Reserved.
|
|
3
|
+
* PROPRIETARY AND CONFIDENTIAL. Unauthorized copying, modification,
|
|
4
|
+
* or distribution is strictly prohibited. Use is governed by the
|
|
5
|
+
* Master Subscription Agreement (MSA) between PeerNova, Inc. and the
|
|
6
|
+
* licensee. See LICENSE file in the repo root.
|
|
7
|
+
*/
|
|
8
|
+
import { Flags } from '@salesforce/sf-plugins-core';
|
|
9
|
+
import { Messages } from '@salesforce/core';
|
|
10
|
+
import { CuneiformCommand } from '../../../../base/cuneiform-command.js';
|
|
11
|
+
import { ProfileRequestService } from '../../../../services/ProfileRequestService.js';
|
|
12
|
+
import { ProfileRequestDeleteOperation, ProfileRequestDeleteErrorCodes, } from '../../../../operations/ProfileRequestDeleteOperation.js';
|
|
13
|
+
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
14
|
+
const messages = Messages.loadMessages('@peernova/cuneiform-sf', 'profile.request.delete');
|
|
15
|
+
/**
|
|
16
|
+
* Permanently deletes profiling requests from a Salesforce org.
|
|
17
|
+
*
|
|
18
|
+
* Deletes canceled or rejected profiling requests. Queued and completed
|
|
19
|
+
* requests are protected — this is an irreversible operation.
|
|
20
|
+
*/
|
|
21
|
+
// eslint-disable-next-line sf-plugin/only-extend-SfCommand -- CuneiformCommand extends SfCommand with shared access gate logic
|
|
22
|
+
export default class ProfileRequestDelete extends CuneiformCommand {
|
|
23
|
+
static summary = messages.getMessage('summary');
|
|
24
|
+
static description = messages.getMessage('description');
|
|
25
|
+
static examples = messages.getMessages('examples');
|
|
26
|
+
// eslint-disable-next-line sf-plugin/spread-base-flags -- CuneiformCommand has no additional flags to spread
|
|
27
|
+
static flags = {
|
|
28
|
+
'target-org': Flags.requiredOrg({
|
|
29
|
+
summary: messages.getMessage('flags.target-org.summary'),
|
|
30
|
+
char: 'o',
|
|
31
|
+
required: true,
|
|
32
|
+
}),
|
|
33
|
+
'api-version': Flags.orgApiVersion(),
|
|
34
|
+
all: Flags.boolean({
|
|
35
|
+
summary: messages.getMessage('flags.all.summary'),
|
|
36
|
+
char: 'a',
|
|
37
|
+
exclusive: ['request-ids'],
|
|
38
|
+
}),
|
|
39
|
+
'request-ids': Flags.string({
|
|
40
|
+
summary: messages.getMessage('flags.request-ids.summary'),
|
|
41
|
+
char: 'i',
|
|
42
|
+
multiple: true,
|
|
43
|
+
exclusive: ['all'],
|
|
44
|
+
}),
|
|
45
|
+
'dry-run': Flags.boolean({
|
|
46
|
+
summary: messages.getMessage('flags.dry-run.summary'),
|
|
47
|
+
char: 'd',
|
|
48
|
+
default: false,
|
|
49
|
+
}),
|
|
50
|
+
'no-prompt': Flags.boolean({
|
|
51
|
+
summary: messages.getMessage('flags.no-prompt.summary'),
|
|
52
|
+
char: 'y',
|
|
53
|
+
default: false,
|
|
54
|
+
}),
|
|
55
|
+
};
|
|
56
|
+
/**
|
|
57
|
+
* Maps error codes to i18n message keys.
|
|
58
|
+
*/
|
|
59
|
+
static ERROR_CODE_MAP = {
|
|
60
|
+
[ProfileRequestDeleteErrorCodes.INVALID_IDS]: 'errors.invalidIds',
|
|
61
|
+
[ProfileRequestDeleteErrorCodes.NO_DELETABLE]: 'errors.noDeletable',
|
|
62
|
+
[ProfileRequestDeleteErrorCodes.DELETE_FAILED]: 'errors.deleteFailed',
|
|
63
|
+
[ProfileRequestDeleteErrorCodes.PARTIAL_FAILURE]: 'errors.partialFailure',
|
|
64
|
+
};
|
|
65
|
+
/**
|
|
66
|
+
* Executes the profile request delete command.
|
|
67
|
+
*/
|
|
68
|
+
async run() {
|
|
69
|
+
const { flags } = await this.parse(ProfileRequestDelete);
|
|
70
|
+
const targetOrg = flags['target-org'].getUsername();
|
|
71
|
+
if (!targetOrg) {
|
|
72
|
+
this.error(messages.getMessage('errors.noTargetOrg'));
|
|
73
|
+
}
|
|
74
|
+
const dryRun = flags['dry-run'];
|
|
75
|
+
const noPrompt = flags['no-prompt'];
|
|
76
|
+
// Initialize services
|
|
77
|
+
const { soqlAdapter, restAdapter } = await this.initConnection(flags);
|
|
78
|
+
const service = new ProfileRequestService({ soqlAdapter, restAdapter });
|
|
79
|
+
const operation = new ProfileRequestDeleteOperation(service);
|
|
80
|
+
// Parse request IDs
|
|
81
|
+
const requestIds = ProfileRequestDelete.parseMultiValueFlag(flags['request-ids']);
|
|
82
|
+
// Validate mutually exclusive flags
|
|
83
|
+
const hasAll = flags.all === true;
|
|
84
|
+
const hasIds = requestIds !== undefined && requestIds.length > 0;
|
|
85
|
+
if (hasAll && hasIds) {
|
|
86
|
+
this.error(messages.getMessage('errors.mutuallyExclusive'));
|
|
87
|
+
}
|
|
88
|
+
if (!hasAll && !hasIds) {
|
|
89
|
+
this.error(messages.getMessage('errors.noSelection'));
|
|
90
|
+
}
|
|
91
|
+
// Build operation options
|
|
92
|
+
const operationOptions = {
|
|
93
|
+
all: flags.all,
|
|
94
|
+
requestIds,
|
|
95
|
+
dryRun,
|
|
96
|
+
noPrompt,
|
|
97
|
+
onDeletableFound: (count) => {
|
|
98
|
+
this.spinner.stop(`${count} deletable request(s) found`);
|
|
99
|
+
},
|
|
100
|
+
onConfirm: async (count) => {
|
|
101
|
+
// For --json mode, skip interactive prompt
|
|
102
|
+
if (this.jsonEnabled())
|
|
103
|
+
return true;
|
|
104
|
+
return this.confirm({
|
|
105
|
+
message: count === 1
|
|
106
|
+
? messages.getMessage('prompt.confirm.singular')
|
|
107
|
+
: messages.getMessage('prompt.confirm.plural', [String(count)]),
|
|
108
|
+
});
|
|
109
|
+
},
|
|
110
|
+
};
|
|
111
|
+
// Execute
|
|
112
|
+
const modeText = dryRun ? '(dry run) ' : '';
|
|
113
|
+
this.log(`Checking for deletable profiling requests ${modeText}...`);
|
|
114
|
+
this.spinner.start('Retrieving deletable requests');
|
|
115
|
+
const result = await operation.execute(operationOptions);
|
|
116
|
+
this.spinner.stop();
|
|
117
|
+
// Handle no deletable requests
|
|
118
|
+
if (!result.success && result.errorCode === ProfileRequestDeleteErrorCodes.NO_DELETABLE) {
|
|
119
|
+
this.log('');
|
|
120
|
+
this.log(messages.getMessage('output.noDeletable'));
|
|
121
|
+
if (result.data.failed.length > 0) {
|
|
122
|
+
this.log('');
|
|
123
|
+
this.log(messages.getMessage('output.failedHeader'));
|
|
124
|
+
for (const f of result.data.failed) {
|
|
125
|
+
this.log(` ${f.id}: ${f.error}`);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
return {
|
|
129
|
+
success: true,
|
|
130
|
+
deleted: 0,
|
|
131
|
+
failed: result.data.failed.length,
|
|
132
|
+
totalDeletable: 0,
|
|
133
|
+
dryRun,
|
|
134
|
+
failures: result.data.failed.length > 0 ? result.data.failed : undefined,
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
// Handle partial failure (some deleted, some could not be deleted)
|
|
138
|
+
if (!result.success && result.errorCode === ProfileRequestDeleteErrorCodes.PARTIAL_FAILURE) {
|
|
139
|
+
this.displayResults(result.data, dryRun);
|
|
140
|
+
return {
|
|
141
|
+
success: false,
|
|
142
|
+
deleted: result.data.deleted.length,
|
|
143
|
+
failed: result.data.failed.length,
|
|
144
|
+
totalDeletable: result.data.totalDeletable,
|
|
145
|
+
dryRun,
|
|
146
|
+
requests: result.data.deleted,
|
|
147
|
+
failures: result.data.failed,
|
|
148
|
+
};
|
|
149
|
+
}
|
|
150
|
+
// Handle user cancellation
|
|
151
|
+
if (result.success && result.metadata?.userCancelled) {
|
|
152
|
+
this.log('');
|
|
153
|
+
this.log(messages.getMessage('output.userCancelled'));
|
|
154
|
+
return {
|
|
155
|
+
success: true,
|
|
156
|
+
deleted: 0,
|
|
157
|
+
failed: 0,
|
|
158
|
+
totalDeletable: result.data.totalDeletable,
|
|
159
|
+
dryRun,
|
|
160
|
+
userCancelled: true,
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
// Handle other failures
|
|
164
|
+
if (!result.success) {
|
|
165
|
+
const errorMessage = ProfileRequestDelete.resolveErrorMessage(ProfileRequestDelete.ERROR_CODE_MAP, result.errorCode, result.message ?? 'Unknown error', messages);
|
|
166
|
+
this.error(errorMessage, { code: result.errorCode });
|
|
167
|
+
}
|
|
168
|
+
const data = result.data;
|
|
169
|
+
// Display results
|
|
170
|
+
this.displayResults(data, dryRun);
|
|
171
|
+
return {
|
|
172
|
+
success: true,
|
|
173
|
+
deleted: data.deleted.length,
|
|
174
|
+
failed: data.failed.length,
|
|
175
|
+
totalDeletable: data.totalDeletable,
|
|
176
|
+
dryRun,
|
|
177
|
+
requests: data.deleted,
|
|
178
|
+
failures: data.failed,
|
|
179
|
+
};
|
|
180
|
+
}
|
|
181
|
+
/**
|
|
182
|
+
* Displays delete results.
|
|
183
|
+
*/
|
|
184
|
+
displayResults(data, dryRun) {
|
|
185
|
+
this.log('');
|
|
186
|
+
if (dryRun) {
|
|
187
|
+
this.log(messages.getMessage('output.dryRunTitle'));
|
|
188
|
+
this.log('');
|
|
189
|
+
// Show table only for dry-run preview
|
|
190
|
+
if (data.deleted.length > 0) {
|
|
191
|
+
this.table({
|
|
192
|
+
data: data.deleted.map((r) => ({
|
|
193
|
+
name: r.name,
|
|
194
|
+
status: r.status,
|
|
195
|
+
object: r.objectName,
|
|
196
|
+
definition: r.definitionName,
|
|
197
|
+
})),
|
|
198
|
+
columns: [
|
|
199
|
+
{ key: 'name', name: 'NAME' },
|
|
200
|
+
{ key: 'status', name: 'STATUS' },
|
|
201
|
+
{ key: 'object', name: 'OBJECT' },
|
|
202
|
+
{ key: 'definition', name: 'DEFINITION' },
|
|
203
|
+
],
|
|
204
|
+
});
|
|
205
|
+
this.log('');
|
|
206
|
+
}
|
|
207
|
+
this.log(messages.getMessage('output.dryRunSummary', [String(data.deleted.length)]));
|
|
208
|
+
}
|
|
209
|
+
else {
|
|
210
|
+
this.log(messages.getMessage('output.deleted', [String(data.deleted.length)]));
|
|
211
|
+
}
|
|
212
|
+
// Show failed requests
|
|
213
|
+
if (data.failed.length > 0) {
|
|
214
|
+
this.log('');
|
|
215
|
+
this.log(messages.getMessage('output.failedHeader'));
|
|
216
|
+
for (const f of data.failed) {
|
|
217
|
+
this.log(` ${f.id}: ${f.error}`);
|
|
218
|
+
}
|
|
219
|
+
this.warn(messages.getMessage('errors.partialFailure', [String(data.deleted.length), String(data.totalDeletable)]));
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
//# sourceMappingURL=delete.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"delete.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,CAAC;YACD,IAAI,CAAC,IAAI,CACP,QAAQ,CAAC,UAAU,CAAC,uBAAuB,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC,CAAC,CACzG,CAAC;QACJ,CAAC;IACH,CAAC"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { CuneiformCommand } from '../../../../base/cuneiform-command.js';
|
|
2
|
+
import type { IProfileRequest } from '../../../../models/profile-request-types.js';
|
|
3
|
+
/**
|
|
4
|
+
* Command result type for JSON output.
|
|
5
|
+
*/
|
|
6
|
+
export type ProfileRequestListCommandResult = {
|
|
7
|
+
/** Whether the operation was successful */
|
|
8
|
+
success: boolean;
|
|
9
|
+
/** List of profiling requests */
|
|
10
|
+
requests: IProfileRequest[];
|
|
11
|
+
/** Error message if failed */
|
|
12
|
+
error?: string;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Lists profiling requests from a Salesforce org.
|
|
16
|
+
*
|
|
17
|
+
* Retrieves pnova__Profiling_Request__c records with their status,
|
|
18
|
+
* definition, and object information. Supports filtering by status
|
|
19
|
+
* and pagination via --limit.
|
|
20
|
+
*/
|
|
21
|
+
export default class ProfileRequestList extends CuneiformCommand<ProfileRequestListCommandResult> {
|
|
22
|
+
static readonly summary: string;
|
|
23
|
+
static readonly description: string;
|
|
24
|
+
static readonly examples: string[];
|
|
25
|
+
static readonly flags: {
|
|
26
|
+
'target-org': import("@oclif/core/interfaces").OptionFlag<import("@salesforce/core").Org, import("@oclif/core/interfaces").CustomOptions>;
|
|
27
|
+
'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
28
|
+
status: import("@oclif/core/interfaces").OptionFlag<"Queued" | "Canceled" | "Completed" | "Rejected" | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
29
|
+
limit: import("@oclif/core/interfaces").OptionFlag<number, import("@oclif/core/interfaces").CustomOptions>;
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* Executes the profile request list command.
|
|
33
|
+
*/
|
|
34
|
+
run(): Promise<ProfileRequestListCommandResult>;
|
|
35
|
+
}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) 2026, PeerNova, Inc. All Rights Reserved.
|
|
3
|
+
* PROPRIETARY AND CONFIDENTIAL. Unauthorized copying, modification,
|
|
4
|
+
* or distribution is strictly prohibited. Use is governed by the
|
|
5
|
+
* Master Subscription Agreement (MSA) between PeerNova, Inc. and the
|
|
6
|
+
* licensee. See LICENSE file in the repo root.
|
|
7
|
+
*/
|
|
8
|
+
import { Flags } from '@salesforce/sf-plugins-core';
|
|
9
|
+
import { Messages } from '@salesforce/core';
|
|
10
|
+
import { CuneiformCommand } from '../../../../base/cuneiform-command.js';
|
|
11
|
+
import { ProfileRequestService } from '../../../../services/ProfileRequestService.js';
|
|
12
|
+
import { ProfileRequestListOperation } from '../../../../operations/ProfileRequestListOperation.js';
|
|
13
|
+
Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
|
|
14
|
+
const messages = Messages.loadMessages('@peernova/cuneiform-sf', 'profile.request.list');
|
|
15
|
+
/**
|
|
16
|
+
* Lists profiling requests from a Salesforce org.
|
|
17
|
+
*
|
|
18
|
+
* Retrieves pnova__Profiling_Request__c records with their status,
|
|
19
|
+
* definition, and object information. Supports filtering by status
|
|
20
|
+
* and pagination via --limit.
|
|
21
|
+
*/
|
|
22
|
+
// eslint-disable-next-line sf-plugin/only-extend-SfCommand -- CuneiformCommand extends SfCommand with shared access gate logic
|
|
23
|
+
export default class ProfileRequestList extends CuneiformCommand {
|
|
24
|
+
static summary = messages.getMessage('summary');
|
|
25
|
+
static description = messages.getMessage('description');
|
|
26
|
+
static examples = messages.getMessages('examples');
|
|
27
|
+
// eslint-disable-next-line sf-plugin/spread-base-flags -- CuneiformCommand has no additional flags to spread
|
|
28
|
+
static flags = {
|
|
29
|
+
'target-org': Flags.requiredOrg({
|
|
30
|
+
summary: messages.getMessage('flags.target-org.summary'),
|
|
31
|
+
char: 'o',
|
|
32
|
+
required: true,
|
|
33
|
+
}),
|
|
34
|
+
'api-version': Flags.orgApiVersion(),
|
|
35
|
+
status: Flags.option({
|
|
36
|
+
summary: messages.getMessage('flags.status.summary'),
|
|
37
|
+
char: 's',
|
|
38
|
+
options: ['Queued', 'Canceled', 'Completed', 'Rejected'],
|
|
39
|
+
})(),
|
|
40
|
+
limit: Flags.integer({
|
|
41
|
+
summary: messages.getMessage('flags.limit.summary'),
|
|
42
|
+
char: 'l',
|
|
43
|
+
min: 1,
|
|
44
|
+
max: 200,
|
|
45
|
+
default: 25,
|
|
46
|
+
}),
|
|
47
|
+
};
|
|
48
|
+
/**
|
|
49
|
+
* Executes the profile request list command.
|
|
50
|
+
*/
|
|
51
|
+
async run() {
|
|
52
|
+
const { flags } = await this.parse(ProfileRequestList);
|
|
53
|
+
const targetOrg = flags['target-org'].getUsername();
|
|
54
|
+
if (!targetOrg) {
|
|
55
|
+
this.error(messages.getMessage('errors.noTargetOrg'));
|
|
56
|
+
}
|
|
57
|
+
// Initialize services
|
|
58
|
+
const { soqlAdapter, restAdapter } = await this.initConnection(flags);
|
|
59
|
+
const service = new ProfileRequestService({ soqlAdapter, restAdapter });
|
|
60
|
+
const operation = new ProfileRequestListOperation(service);
|
|
61
|
+
// Execute operation
|
|
62
|
+
const result = await operation.execute({
|
|
63
|
+
status: flags.status,
|
|
64
|
+
limit: flags.limit,
|
|
65
|
+
});
|
|
66
|
+
if (!result.success) {
|
|
67
|
+
const errorDetail = result.message ?? 'Unknown error';
|
|
68
|
+
this.error(messages.getMessage('errors.queryFailed', [errorDetail]), { code: result.errorCode });
|
|
69
|
+
}
|
|
70
|
+
const requests = result.data;
|
|
71
|
+
// Render output
|
|
72
|
+
if (requests.length === 0) {
|
|
73
|
+
this.log(messages.getMessage('output.noRequests'));
|
|
74
|
+
}
|
|
75
|
+
else {
|
|
76
|
+
this.log(messages.getMessage('output.title'));
|
|
77
|
+
this.table({
|
|
78
|
+
data: requests.map((r) => ({
|
|
79
|
+
name: r.name,
|
|
80
|
+
status: r.status,
|
|
81
|
+
object: r.objectName,
|
|
82
|
+
definition: r.definitionName,
|
|
83
|
+
submittedBy: r.submittedBy,
|
|
84
|
+
createdDate: r.createdDate,
|
|
85
|
+
})),
|
|
86
|
+
columns: [
|
|
87
|
+
{ key: 'name', name: 'NAME' },
|
|
88
|
+
{ key: 'status', name: 'STATUS' },
|
|
89
|
+
{ key: 'object', name: 'OBJECT' },
|
|
90
|
+
{ key: 'definition', name: 'DEFINITION' },
|
|
91
|
+
{ key: 'submittedBy', name: 'SUBMITTED BY' },
|
|
92
|
+
{ key: 'createdDate', name: 'CREATED DATE' },
|
|
93
|
+
],
|
|
94
|
+
});
|
|
95
|
+
}
|
|
96
|
+
return {
|
|
97
|
+
success: true,
|
|
98
|
+
requests,
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
//# sourceMappingURL=list.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"list.js","sourceRoot":"","sources":["../../../../../src/commands/cuneiform/profile/request/list.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AACpD,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,gBAAgB,EAAE,MAAM,uCAAuC,CAAC;AACzE,OAAO,EAAE,qBAAqB,EAAE,MAAM,+CAA+C,CAAC;AACtF,OAAO,EAAE,2BAA2B,EAAE,MAAM,uDAAuD,CAAC;AAGpG,QAAQ,CAAC,kCAAkC,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC7D,MAAM,QAAQ,GAAG,QAAQ,CAAC,YAAY,CAAC,wBAAwB,EAAE,sBAAsB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AI;oBACZ,MAAM,EAAE,CAAC,CAAC,MAAM;oBAChB,MAAM,EAAE,CAAC,CAAC,UAAU;oBACpB,UAAU,EAAE,CAAC,CAAC,cAAc;oBAC5B,WAAW,EAAE,CAAC,CAAC,WAAW;oBAC1B,WAAW,EAAE,CAAC,CAAC,WAAW;iBAC3B,CAAC,CAAC;gBACH,OAAO,EAAE;oBACP,EAAE,GAAG,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE;oBAC7B,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE;oBACjC,EAAE,GAAG,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE;oBACjC,EAAE,GAAG,EAAE,YAAY,EAAE,IAAI,EAAE,YAAY,EAAE;oBACzC,EAAE,GAAG,EAAE,aAAa,EAAE,IAAI,EAAE,cAAc,EAAE;oBAC5C,EAAE,GAAG,EAAE,aAAa,EAAE,IAAI,EAAE,cAAc,EAAE;iBAC7C;aACF,CAAC,CAAC;QACL,CAAC;QAED,OAAO;YACL,OAAO,EAAE,IAAI;YACb,QAAQ;SACT,CAAC;IACJ,CAAC"}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { type ProfileResult } from '../../operations/ProfileOperation.js';
|
|
2
|
+
import { CuneiformCommand } from '../../base/cuneiform-command.js';
|
|
3
|
+
/**
|
|
4
|
+
* Command result type for JSON output.
|
|
5
|
+
* Composes from ProfileResult to stay in sync with the operation layer.
|
|
6
|
+
*/
|
|
7
|
+
export type ProfileCommandResult = ProfileResult & {
|
|
8
|
+
/** Whether the operation was successful */
|
|
9
|
+
success: boolean;
|
|
10
|
+
/** Error message if operation failed */
|
|
11
|
+
error?: string;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Executes profiling operations on Cuneiform profiling definitions.
|
|
15
|
+
*
|
|
16
|
+
* Use this command to:
|
|
17
|
+
* - Profile a single definition by key or ID
|
|
18
|
+
* - Profile multiple definitions in bulk by method
|
|
19
|
+
* - Apply filters to control which definitions are processed
|
|
20
|
+
* - Monitor progress for bulk operations
|
|
21
|
+
*
|
|
22
|
+
* @example
|
|
23
|
+
* ```bash
|
|
24
|
+
* # Profile a single definition by key
|
|
25
|
+
* sf cuneiform profile --target-org myOrg --keys PD-0001
|
|
26
|
+
*
|
|
27
|
+
* # Profile all metadata definitions
|
|
28
|
+
* sf cuneiform profile --target-org myOrg --method metadata --parallel 10
|
|
29
|
+
*
|
|
30
|
+
* # Profile historical definitions with filters
|
|
31
|
+
* sf cuneiform profile --target-org myOrg --method historical --status "NOT PROFILED" --limit 5
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
34
|
+
export default class Profile extends CuneiformCommand<ProfileCommandResult> {
|
|
35
|
+
static readonly summary: string;
|
|
36
|
+
static readonly description: string;
|
|
37
|
+
static readonly examples: string[];
|
|
38
|
+
static readonly flags: {
|
|
39
|
+
'target-org': import("@oclif/core/interfaces").OptionFlag<import("@salesforce/core").Org, import("@oclif/core/interfaces").CustomOptions>;
|
|
40
|
+
'api-version': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
41
|
+
keys: import("@oclif/core/interfaces").OptionFlag<string[] | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
42
|
+
id: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
43
|
+
method: import("@oclif/core/interfaces").OptionFlag<"metadata" | "historical" | "comparative" | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
44
|
+
status: import("@oclif/core/interfaces").OptionFlag<"ERROR" | "NOT PROFILED" | "IN PROGRESS" | "SUCCESS" | "COMPLETE w/ FAILURES" | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
45
|
+
namespace: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
46
|
+
category: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
47
|
+
'time-category': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
48
|
+
'segment-category': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
49
|
+
limit: import("@oclif/core/interfaces").OptionFlag<number, import("@oclif/core/interfaces").CustomOptions>;
|
|
50
|
+
'skip-empty': import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
51
|
+
parallel: import("@oclif/core/interfaces").OptionFlag<number, import("@oclif/core/interfaces").CustomOptions>;
|
|
52
|
+
format: import("@oclif/core/interfaces").OptionFlag<"table" | "json", import("@oclif/core/interfaces").CustomOptions>;
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* Maps operation error codes to i18n message bundle keys.
|
|
56
|
+
* Used by the inherited `resolveErrorMessage()` for consistent error resolution.
|
|
57
|
+
*/
|
|
58
|
+
private static readonly ERROR_CODE_MAP;
|
|
59
|
+
/**
|
|
60
|
+
* Executes the profile command.
|
|
61
|
+
*
|
|
62
|
+
* @returns ProfileCommandResult with execution statistics
|
|
63
|
+
*/
|
|
64
|
+
run(): Promise<ProfileCommandResult>;
|
|
65
|
+
/**
|
|
66
|
+
* Displays bulk execution configuration.
|
|
67
|
+
*
|
|
68
|
+
* @param flags - Parsed command flags
|
|
69
|
+
*/
|
|
70
|
+
private displayBulkConfiguration;
|
|
71
|
+
/**
|
|
72
|
+
* Displays profiling results.
|
|
73
|
+
*
|
|
74
|
+
* @param data - Profile result data
|
|
75
|
+
* @param targetOrg - Target org username for next-steps guidance
|
|
76
|
+
*/
|
|
77
|
+
private displayResults;
|
|
78
|
+
/**
|
|
79
|
+
* Displays single-mode result.
|
|
80
|
+
*
|
|
81
|
+
* @param data - Profile result data
|
|
82
|
+
*/
|
|
83
|
+
private displaySingleResult;
|
|
84
|
+
/**
|
|
85
|
+
* Displays bulk-mode results.
|
|
86
|
+
*
|
|
87
|
+
* @param data - Profile result data
|
|
88
|
+
*/
|
|
89
|
+
private displayBulkResults;
|
|
90
|
+
}
|