@constructive-sdk/cli 0.23.2 → 0.24.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.
- package/admin/cli/commands/app-limit-event.js +248 -2
- package/admin/cli/commands/app-limit.js +44 -0
- package/admin/cli/commands/org-limit-aggregate.js +44 -0
- package/admin/cli/commands/org-limit-event.js +248 -2
- package/admin/cli/commands/org-limit.js +44 -0
- package/admin/cli/commands.js +31 -33
- package/admin/cli/executor.d.ts +15 -16
- package/admin/orm/index.d.ts +31 -33
- package/admin/orm/index.js +32 -33
- package/admin/orm/input-types.d.ts +2090 -2039
- package/admin/orm/input-types.js +4 -4
- package/admin/orm/models/appLimitEvent.d.ts +26 -2
- package/admin/orm/models/appLimitEvent.js +45 -0
- package/admin/orm/models/index.d.ts +15 -16
- package/admin/orm/models/index.js +31 -33
- package/admin/orm/models/orgLimitEvent.d.ts +26 -2
- package/admin/orm/models/orgLimitEvent.js +45 -0
- package/{esm/public/cli/commands/agent-message.d.ts → auth/cli/commands/audit-log-auth.d.ts} +1 -1
- package/auth/cli/commands/{audit-log.js → audit-log-auth.js} +14 -14
- package/auth/cli/commands.js +5 -5
- package/auth/cli/executor.d.ts +6 -6
- package/auth/orm/index.d.ts +8 -8
- package/auth/orm/index.js +4 -3
- package/auth/orm/input-types.d.ts +94 -94
- package/auth/orm/input-types.js +1 -1
- package/auth/orm/models/auditLogAuth.d.ts +54 -0
- package/{public/orm/models/agentMessage.js → auth/orm/models/auditLogAuth.js} +27 -27
- package/auth/orm/models/index.d.ts +1 -1
- package/auth/orm/models/index.js +3 -3
- package/auth/orm/mutation/index.d.ts +9 -9
- package/auth/orm/mutation/index.js +12 -12
- package/esm/admin/cli/commands/app-limit-event.js +248 -2
- package/esm/admin/cli/commands/app-limit.js +44 -0
- package/esm/admin/cli/commands/org-limit-aggregate.js +44 -0
- package/esm/admin/cli/commands/org-limit-event.js +248 -2
- package/esm/admin/cli/commands/org-limit.js +44 -0
- package/esm/admin/cli/commands.js +31 -33
- package/esm/admin/cli/executor.d.ts +15 -16
- package/esm/admin/orm/index.d.ts +31 -33
- package/esm/admin/orm/index.js +31 -33
- package/esm/admin/orm/input-types.d.ts +2090 -2039
- package/esm/admin/orm/input-types.js +4 -4
- package/esm/admin/orm/models/appLimitEvent.d.ts +26 -2
- package/esm/admin/orm/models/appLimitEvent.js +46 -1
- package/esm/admin/orm/models/index.d.ts +15 -16
- package/esm/admin/orm/models/index.js +15 -16
- package/esm/admin/orm/models/orgLimitEvent.d.ts +26 -2
- package/esm/admin/orm/models/orgLimitEvent.js +46 -1
- package/esm/auth/cli/commands/audit-log-auth.d.ts +8 -0
- package/esm/{public/cli/commands/audit-log.js → auth/cli/commands/audit-log-auth.js} +14 -14
- package/esm/auth/cli/commands.js +5 -5
- package/esm/auth/cli/executor.d.ts +6 -6
- package/esm/auth/orm/index.d.ts +8 -8
- package/esm/auth/orm/index.js +3 -3
- package/esm/auth/orm/input-types.d.ts +94 -94
- package/esm/auth/orm/input-types.js +1 -1
- package/esm/auth/orm/models/auditLogAuth.d.ts +54 -0
- package/esm/{public/orm/models/auditLog.js → auth/orm/models/auditLogAuth.js} +25 -25
- package/esm/auth/orm/models/index.d.ts +1 -1
- package/esm/auth/orm/models/index.js +1 -1
- package/esm/auth/orm/mutation/index.d.ts +9 -9
- package/esm/auth/orm/mutation/index.js +12 -12
- package/esm/objects/orm/index.d.ts +1 -1
- package/esm/objects/orm/index.js +1 -1
- package/esm/public/cli/commands/{agent-thread.d.ts → agent-module.d.ts} +1 -1
- package/esm/public/cli/commands/agent-module.js +690 -0
- package/esm/public/cli/commands/app-limit-event.js +248 -2
- package/esm/public/cli/commands/app-limit.js +44 -0
- package/esm/public/cli/commands/apply-registry-defaults.d.ts +8 -0
- package/esm/public/cli/commands/{rev-parse.js → apply-registry-defaults.js} +9 -12
- package/esm/public/cli/commands/audit-log-auth.d.ts +8 -0
- package/esm/{auth/cli/commands/audit-log.js → public/cli/commands/audit-log-auth.js} +14 -14
- package/esm/public/cli/commands/billing-module.js +88 -0
- package/esm/public/cli/commands/compute-log-module.d.ts +8 -0
- package/esm/public/cli/commands/compute-log-module.js +514 -0
- package/esm/public/cli/commands/config-secrets-org-module.d.ts +8 -0
- package/esm/public/cli/commands/{encrypted-secrets-module.js → config-secrets-org-module.js} +8 -8
- package/esm/public/cli/commands/config-secrets-user-module.d.ts +8 -0
- package/esm/public/cli/commands/{object.js → config-secrets-user-module.js} +60 -67
- package/esm/public/cli/commands/construct-blueprint.js +1 -1
- package/{admin/cli/commands/usage-snapshot.d.ts → esm/public/cli/commands/db-usage-module.d.ts} +1 -1
- package/esm/public/cli/commands/db-usage-module.js +558 -0
- package/esm/public/cli/commands/entity-type-provision.js +386 -34
- package/esm/public/cli/commands/field.js +4 -26
- package/esm/public/cli/commands/function-module.d.ts +8 -0
- package/esm/public/cli/commands/function-module.js +778 -0
- package/{auth/cli/commands/audit-log.d.ts → esm/public/cli/commands/graph-module.d.ts} +1 -1
- package/esm/public/cli/commands/graph-module.js +584 -0
- package/esm/public/cli/commands/inference-log-module.d.ts +8 -0
- package/esm/public/cli/commands/inference-log-module.js +514 -0
- package/esm/public/cli/commands/memberships-module.js +22 -0
- package/esm/public/cli/commands/merkle-store-module.d.ts +8 -0
- package/esm/public/cli/commands/merkle-store-module.js +498 -0
- package/esm/public/cli/commands/namespace-module.d.ts +8 -0
- package/esm/public/cli/commands/namespace-module.js +558 -0
- package/esm/public/cli/commands/org-limit-aggregate.js +44 -0
- package/esm/public/cli/commands/org-limit-event.js +248 -2
- package/esm/public/cli/commands/org-limit.js +44 -0
- package/esm/public/cli/commands/partition.js +44 -0
- package/esm/public/cli/commands/storage-log-module.d.ts +8 -0
- package/esm/public/cli/commands/storage-log-module.js +514 -0
- package/esm/public/cli/commands/storage-module.js +36 -14
- package/esm/public/cli/commands/transfer-log-module.d.ts +8 -0
- package/esm/public/cli/commands/transfer-log-module.js +514 -0
- package/esm/public/cli/commands.js +83 -101
- package/esm/public/cli/executor.d.ts +72 -125
- package/esm/public/orm/index.d.ts +102 -153
- package/esm/public/orm/index.js +59 -55
- package/esm/public/orm/input-types.d.ts +6255 -3877
- package/esm/public/orm/input-types.js +24 -15
- package/esm/public/orm/models/agentModule.d.ts +54 -0
- package/esm/public/orm/models/{agentThread.js → agentModule.js} +25 -25
- package/esm/public/orm/models/appLimitEvent.d.ts +26 -2
- package/esm/public/orm/models/appLimitEvent.js +46 -1
- package/esm/public/orm/models/auditLogAuth.d.ts +54 -0
- package/esm/{auth/orm/models/auditLog.js → public/orm/models/auditLogAuth.js} +25 -25
- package/esm/public/orm/models/computeLogModule.d.ts +54 -0
- package/esm/public/orm/models/{commit.js → computeLogModule.js} +25 -25
- package/esm/public/orm/models/configSecretsOrgModule.d.ts +54 -0
- package/esm/public/orm/models/{encryptedSecretsModule.js → configSecretsOrgModule.js} +25 -25
- package/esm/public/orm/models/configSecretsUserModule.d.ts +54 -0
- package/esm/public/orm/models/configSecretsUserModule.js +100 -0
- package/esm/public/orm/models/dbUsageModule.d.ts +54 -0
- package/esm/{admin/orm/models/usageSnapshot.js → public/orm/models/dbUsageModule.js} +25 -25
- package/esm/public/orm/models/functionModule.d.ts +54 -0
- package/esm/public/orm/models/{agentMessage.js → functionModule.js} +25 -25
- package/esm/public/orm/models/graphModule.d.ts +54 -0
- package/esm/public/orm/models/{agentTask.js → graphModule.js} +25 -25
- package/esm/public/orm/models/index.d.ts +29 -27
- package/esm/public/orm/models/index.js +29 -27
- package/esm/public/orm/models/inferenceLogModule.d.ts +54 -0
- package/esm/public/orm/models/inferenceLogModule.js +100 -0
- package/esm/public/orm/models/merkleStoreModule.d.ts +54 -0
- package/esm/public/orm/models/merkleStoreModule.js +100 -0
- package/esm/public/orm/models/namespaceModule.d.ts +54 -0
- package/esm/public/orm/models/namespaceModule.js +100 -0
- package/esm/public/orm/models/orgLimitEvent.d.ts +26 -2
- package/esm/public/orm/models/orgLimitEvent.js +46 -1
- package/esm/public/orm/models/storageLogModule.d.ts +54 -0
- package/esm/public/orm/models/{store.js → storageLogModule.js} +25 -25
- package/esm/public/orm/models/transferLogModule.d.ts +54 -0
- package/esm/public/orm/models/transferLogModule.js +100 -0
- package/esm/public/orm/mutation/index.d.ts +69 -133
- package/esm/public/orm/mutation/index.js +78 -174
- package/esm/public/orm/query/index.d.ts +22 -71
- package/esm/public/orm/query/index.js +36 -124
- package/objects/orm/index.d.ts +1 -1
- package/objects/orm/index.js +2 -1
- package/package.json +6 -6
- package/{esm/public/cli/commands/agent-task.d.ts → public/cli/commands/agent-module.d.ts} +1 -1
- package/public/cli/commands/agent-module.js +692 -0
- package/public/cli/commands/app-limit-event.js +248 -2
- package/public/cli/commands/app-limit.js +44 -0
- package/public/cli/commands/apply-registry-defaults.d.ts +8 -0
- package/public/cli/commands/{rev-parse.js → apply-registry-defaults.js} +9 -12
- package/public/cli/commands/audit-log-auth.d.ts +8 -0
- package/public/cli/commands/{audit-log.js → audit-log-auth.js} +14 -14
- package/public/cli/commands/billing-module.js +88 -0
- package/public/cli/commands/compute-log-module.d.ts +8 -0
- package/public/cli/commands/compute-log-module.js +516 -0
- package/public/cli/commands/config-secrets-org-module.d.ts +8 -0
- package/public/cli/commands/{encrypted-secrets-module.js → config-secrets-org-module.js} +8 -8
- package/public/cli/commands/config-secrets-user-module.d.ts +8 -0
- package/public/cli/commands/{object.js → config-secrets-user-module.js} +60 -67
- package/public/cli/commands/construct-blueprint.js +1 -1
- package/{esm/admin/cli/commands/usage-snapshot.d.ts → public/cli/commands/db-usage-module.d.ts} +1 -1
- package/public/cli/commands/db-usage-module.js +560 -0
- package/public/cli/commands/entity-type-provision.js +386 -34
- package/public/cli/commands/field.js +4 -26
- package/public/cli/commands/function-module.d.ts +8 -0
- package/public/cli/commands/function-module.js +780 -0
- package/{esm/auth/cli/commands/audit-log.d.ts → public/cli/commands/graph-module.d.ts} +1 -1
- package/public/cli/commands/graph-module.js +586 -0
- package/public/cli/commands/inference-log-module.d.ts +8 -0
- package/public/cli/commands/inference-log-module.js +516 -0
- package/public/cli/commands/memberships-module.js +22 -0
- package/public/cli/commands/merkle-store-module.d.ts +8 -0
- package/public/cli/commands/merkle-store-module.js +500 -0
- package/public/cli/commands/namespace-module.d.ts +8 -0
- package/public/cli/commands/namespace-module.js +560 -0
- package/public/cli/commands/org-limit-aggregate.js +44 -0
- package/public/cli/commands/org-limit-event.js +248 -2
- package/public/cli/commands/org-limit.js +44 -0
- package/public/cli/commands/partition.js +44 -0
- package/public/cli/commands/storage-log-module.d.ts +8 -0
- package/public/cli/commands/storage-log-module.js +516 -0
- package/public/cli/commands/storage-module.js +36 -14
- package/public/cli/commands/transfer-log-module.d.ts +8 -0
- package/public/cli/commands/transfer-log-module.js +516 -0
- package/public/cli/commands.js +83 -101
- package/public/cli/executor.d.ts +72 -125
- package/public/orm/index.d.ts +102 -153
- package/public/orm/index.js +60 -55
- package/public/orm/input-types.d.ts +6255 -3877
- package/public/orm/input-types.js +24 -15
- package/public/orm/models/agentModule.d.ts +54 -0
- package/public/orm/models/{agentThread.js → agentModule.js} +27 -27
- package/public/orm/models/appLimitEvent.d.ts +26 -2
- package/public/orm/models/appLimitEvent.js +45 -0
- package/public/orm/models/auditLogAuth.d.ts +54 -0
- package/{admin/orm/models/usageSnapshot.js → public/orm/models/auditLogAuth.js} +27 -27
- package/public/orm/models/computeLogModule.d.ts +54 -0
- package/{auth/orm/models/auditLog.js → public/orm/models/computeLogModule.js} +27 -27
- package/public/orm/models/configSecretsOrgModule.d.ts +54 -0
- package/public/orm/models/{encryptedSecretsModule.js → configSecretsOrgModule.js} +27 -27
- package/public/orm/models/configSecretsUserModule.d.ts +54 -0
- package/public/orm/models/{ref.js → configSecretsUserModule.js} +27 -27
- package/public/orm/models/dbUsageModule.d.ts +54 -0
- package/public/orm/models/{usageSnapshot.js → dbUsageModule.js} +27 -27
- package/public/orm/models/functionModule.d.ts +54 -0
- package/public/orm/models/functionModule.js +104 -0
- package/public/orm/models/graphModule.d.ts +54 -0
- package/public/orm/models/{agentTask.js → graphModule.js} +27 -27
- package/public/orm/models/index.d.ts +29 -27
- package/public/orm/models/index.js +61 -57
- package/public/orm/models/inferenceLogModule.d.ts +54 -0
- package/public/orm/models/inferenceLogModule.js +104 -0
- package/public/orm/models/merkleStoreModule.d.ts +54 -0
- package/public/orm/models/merkleStoreModule.js +104 -0
- package/public/orm/models/namespaceModule.d.ts +54 -0
- package/public/orm/models/namespaceModule.js +104 -0
- package/public/orm/models/orgLimitEvent.d.ts +26 -2
- package/public/orm/models/orgLimitEvent.js +45 -0
- package/public/orm/models/storageLogModule.d.ts +54 -0
- package/public/orm/models/storageLogModule.js +104 -0
- package/public/orm/models/transferLogModule.d.ts +54 -0
- package/public/orm/models/transferLogModule.js +104 -0
- package/public/orm/mutation/index.d.ts +69 -133
- package/public/orm/mutation/index.js +78 -174
- package/public/orm/query/index.d.ts +22 -71
- package/public/orm/query/index.js +36 -124
- package/admin/cli/commands/usage-snapshot.js +0 -316
- package/admin/orm/models/usageSnapshot.d.ts +0 -54
- package/auth/orm/models/auditLog.d.ts +0 -54
- package/esm/admin/cli/commands/usage-snapshot.js +0 -314
- package/esm/admin/orm/models/usageSnapshot.d.ts +0 -54
- package/esm/auth/orm/models/auditLog.d.ts +0 -54
- package/esm/public/cli/commands/agent-message.js +0 -324
- package/esm/public/cli/commands/agent-task.js +0 -368
- package/esm/public/cli/commands/agent-thread.js +0 -372
- package/esm/public/cli/commands/audit-log.d.ts +0 -8
- package/esm/public/cli/commands/commit.d.ts +0 -8
- package/esm/public/cli/commands/commit.js +0 -380
- package/esm/public/cli/commands/encrypted-secrets-module.d.ts +0 -8
- package/esm/public/cli/commands/freeze-objects.d.ts +0 -8
- package/esm/public/cli/commands/freeze-objects.js +0 -34
- package/esm/public/cli/commands/get-all-objects-from-root.d.ts +0 -8
- package/esm/public/cli/commands/get-all-objects-from-root.js +0 -52
- package/esm/public/cli/commands/get-all-record.d.ts +0 -8
- package/esm/public/cli/commands/get-all-record.js +0 -124
- package/esm/public/cli/commands/get-object-at-path.d.ts +0 -8
- package/esm/public/cli/commands/get-object-at-path.js +0 -47
- package/esm/public/cli/commands/get-path-objects-from-root.d.ts +0 -8
- package/esm/public/cli/commands/get-path-objects-from-root.js +0 -57
- package/esm/public/cli/commands/init-empty-repo.d.ts +0 -8
- package/esm/public/cli/commands/init-empty-repo.js +0 -34
- package/esm/public/cli/commands/insert-node-at-path.d.ts +0 -8
- package/esm/public/cli/commands/insert-node-at-path.js +0 -34
- package/esm/public/cli/commands/object.d.ts +0 -8
- package/esm/public/cli/commands/ref.d.ts +0 -8
- package/esm/public/cli/commands/ref.js +0 -290
- package/esm/public/cli/commands/remove-node-at-path.d.ts +0 -8
- package/esm/public/cli/commands/remove-node-at-path.js +0 -34
- package/esm/public/cli/commands/rev-parse.d.ts +0 -8
- package/esm/public/cli/commands/set-and-commit.d.ts +0 -8
- package/esm/public/cli/commands/set-and-commit.js +0 -34
- package/esm/public/cli/commands/set-data-at-path.d.ts +0 -8
- package/esm/public/cli/commands/set-data-at-path.js +0 -34
- package/esm/public/cli/commands/set-props-and-commit.d.ts +0 -8
- package/esm/public/cli/commands/set-props-and-commit.js +0 -34
- package/esm/public/cli/commands/store.d.ts +0 -8
- package/esm/public/cli/commands/store.js +0 -276
- package/esm/public/cli/commands/update-node-at-path.d.ts +0 -8
- package/esm/public/cli/commands/update-node-at-path.js +0 -34
- package/esm/public/cli/commands/usage-snapshot.d.ts +0 -8
- package/esm/public/cli/commands/usage-snapshot.js +0 -314
- package/esm/public/orm/models/agentMessage.d.ts +0 -54
- package/esm/public/orm/models/agentTask.d.ts +0 -54
- package/esm/public/orm/models/agentThread.d.ts +0 -54
- package/esm/public/orm/models/auditLog.d.ts +0 -54
- package/esm/public/orm/models/commit.d.ts +0 -54
- package/esm/public/orm/models/encryptedSecretsModule.d.ts +0 -54
- package/esm/public/orm/models/getAllRecord.d.ts +0 -30
- package/esm/public/orm/models/getAllRecord.js +0 -55
- package/esm/public/orm/models/object.d.ts +0 -54
- package/esm/public/orm/models/object.js +0 -90
- package/esm/public/orm/models/ref.d.ts +0 -54
- package/esm/public/orm/models/ref.js +0 -100
- package/esm/public/orm/models/store.d.ts +0 -54
- package/esm/public/orm/models/usageSnapshot.d.ts +0 -54
- package/esm/public/orm/models/usageSnapshot.js +0 -100
- package/public/cli/commands/agent-message.d.ts +0 -8
- package/public/cli/commands/agent-message.js +0 -326
- package/public/cli/commands/agent-task.d.ts +0 -8
- package/public/cli/commands/agent-task.js +0 -370
- package/public/cli/commands/agent-thread.d.ts +0 -8
- package/public/cli/commands/agent-thread.js +0 -374
- package/public/cli/commands/audit-log.d.ts +0 -8
- package/public/cli/commands/commit.d.ts +0 -8
- package/public/cli/commands/commit.js +0 -382
- package/public/cli/commands/encrypted-secrets-module.d.ts +0 -8
- package/public/cli/commands/freeze-objects.d.ts +0 -8
- package/public/cli/commands/freeze-objects.js +0 -36
- package/public/cli/commands/get-all-objects-from-root.d.ts +0 -8
- package/public/cli/commands/get-all-objects-from-root.js +0 -54
- package/public/cli/commands/get-all-record.d.ts +0 -8
- package/public/cli/commands/get-all-record.js +0 -126
- package/public/cli/commands/get-object-at-path.d.ts +0 -8
- package/public/cli/commands/get-object-at-path.js +0 -49
- package/public/cli/commands/get-path-objects-from-root.d.ts +0 -8
- package/public/cli/commands/get-path-objects-from-root.js +0 -59
- package/public/cli/commands/init-empty-repo.d.ts +0 -8
- package/public/cli/commands/init-empty-repo.js +0 -36
- package/public/cli/commands/insert-node-at-path.d.ts +0 -8
- package/public/cli/commands/insert-node-at-path.js +0 -36
- package/public/cli/commands/object.d.ts +0 -8
- package/public/cli/commands/ref.d.ts +0 -8
- package/public/cli/commands/ref.js +0 -292
- package/public/cli/commands/remove-node-at-path.d.ts +0 -8
- package/public/cli/commands/remove-node-at-path.js +0 -36
- package/public/cli/commands/rev-parse.d.ts +0 -8
- package/public/cli/commands/set-and-commit.d.ts +0 -8
- package/public/cli/commands/set-and-commit.js +0 -36
- package/public/cli/commands/set-data-at-path.d.ts +0 -8
- package/public/cli/commands/set-data-at-path.js +0 -36
- package/public/cli/commands/set-props-and-commit.d.ts +0 -8
- package/public/cli/commands/set-props-and-commit.js +0 -36
- package/public/cli/commands/store.d.ts +0 -8
- package/public/cli/commands/store.js +0 -278
- package/public/cli/commands/update-node-at-path.d.ts +0 -8
- package/public/cli/commands/update-node-at-path.js +0 -36
- package/public/cli/commands/usage-snapshot.d.ts +0 -8
- package/public/cli/commands/usage-snapshot.js +0 -316
- package/public/orm/models/agentMessage.d.ts +0 -54
- package/public/orm/models/agentTask.d.ts +0 -54
- package/public/orm/models/agentThread.d.ts +0 -54
- package/public/orm/models/auditLog.d.ts +0 -54
- package/public/orm/models/auditLog.js +0 -104
- package/public/orm/models/commit.d.ts +0 -54
- package/public/orm/models/commit.js +0 -104
- package/public/orm/models/encryptedSecretsModule.d.ts +0 -54
- package/public/orm/models/getAllRecord.d.ts +0 -30
- package/public/orm/models/getAllRecord.js +0 -59
- package/public/orm/models/object.d.ts +0 -54
- package/public/orm/models/object.js +0 -94
- package/public/orm/models/ref.d.ts +0 -54
- package/public/orm/models/store.d.ts +0 -54
- package/public/orm/models/store.js +0 -104
- package/public/orm/models/usageSnapshot.d.ts +0 -54
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const executor_1 = require("../executor");
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
|
-
exports.default = async (argv, prompter, _options) => {
|
|
6
|
-
try {
|
|
7
|
-
if (argv.help || argv.h) {
|
|
8
|
-
console.log('get-object-at-path - getObjectAtPath\n\nUsage: get-object-at-path [OPTIONS]\n');
|
|
9
|
-
process.exit(0);
|
|
10
|
-
}
|
|
11
|
-
const answers = await prompter.prompt(argv, [
|
|
12
|
-
{
|
|
13
|
-
type: 'text',
|
|
14
|
-
name: 'dbId',
|
|
15
|
-
message: 'dbId',
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
type: 'text',
|
|
19
|
-
name: 'storeId',
|
|
20
|
-
message: 'storeId',
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
type: 'text',
|
|
24
|
-
name: 'path',
|
|
25
|
-
message: 'path',
|
|
26
|
-
},
|
|
27
|
-
{
|
|
28
|
-
type: 'text',
|
|
29
|
-
name: 'refname',
|
|
30
|
-
message: 'refname',
|
|
31
|
-
},
|
|
32
|
-
]);
|
|
33
|
-
const client = (0, executor_1.getClient)();
|
|
34
|
-
const selectFields = (0, utils_1.buildSelectFromPaths)(argv.select ?? '');
|
|
35
|
-
const result = await client.query
|
|
36
|
-
.getObjectAtPath(answers, {
|
|
37
|
-
select: selectFields,
|
|
38
|
-
})
|
|
39
|
-
.execute();
|
|
40
|
-
console.log(JSON.stringify(result, null, 2));
|
|
41
|
-
}
|
|
42
|
-
catch (error) {
|
|
43
|
-
console.error('Failed: getObjectAtPath');
|
|
44
|
-
if (error instanceof Error) {
|
|
45
|
-
console.error(error.message);
|
|
46
|
-
}
|
|
47
|
-
process.exit(1);
|
|
48
|
-
}
|
|
49
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI command for query getPathObjectsFromRoot
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const executor_1 = require("../executor");
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
|
-
exports.default = async (argv, prompter, _options) => {
|
|
6
|
-
try {
|
|
7
|
-
if (argv.help || argv.h) {
|
|
8
|
-
console.log('get-path-objects-from-root - Reads and enables pagination through a set of `Object`.\n\nUsage: get-path-objects-from-root [OPTIONS]\n');
|
|
9
|
-
process.exit(0);
|
|
10
|
-
}
|
|
11
|
-
const answers = await prompter.prompt(argv, [
|
|
12
|
-
{
|
|
13
|
-
type: 'text',
|
|
14
|
-
name: 'databaseId',
|
|
15
|
-
message: 'databaseId',
|
|
16
|
-
},
|
|
17
|
-
{
|
|
18
|
-
type: 'text',
|
|
19
|
-
name: 'id',
|
|
20
|
-
message: 'id',
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
type: 'text',
|
|
24
|
-
name: 'path',
|
|
25
|
-
message: 'path',
|
|
26
|
-
},
|
|
27
|
-
{
|
|
28
|
-
type: 'text',
|
|
29
|
-
name: 'first',
|
|
30
|
-
message: 'Only read the first `n` values of the set.',
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
type: 'text',
|
|
34
|
-
name: 'offset',
|
|
35
|
-
message: 'Skip the first `n` values from our `after` cursor, an alternative to cursor\nbased pagination. May not be used with `last`.',
|
|
36
|
-
},
|
|
37
|
-
{
|
|
38
|
-
type: 'text',
|
|
39
|
-
name: 'after',
|
|
40
|
-
message: 'Read all values in the set after (below) this cursor.',
|
|
41
|
-
},
|
|
42
|
-
]);
|
|
43
|
-
const client = (0, executor_1.getClient)();
|
|
44
|
-
const selectFields = (0, utils_1.buildSelectFromPaths)(argv.select ?? '');
|
|
45
|
-
const result = await client.query
|
|
46
|
-
.getPathObjectsFromRoot(answers, {
|
|
47
|
-
select: selectFields,
|
|
48
|
-
})
|
|
49
|
-
.execute();
|
|
50
|
-
console.log(JSON.stringify(result, null, 2));
|
|
51
|
-
}
|
|
52
|
-
catch (error) {
|
|
53
|
-
console.error('Failed: getPathObjectsFromRoot');
|
|
54
|
-
if (error instanceof Error) {
|
|
55
|
-
console.error(error.message);
|
|
56
|
-
}
|
|
57
|
-
process.exit(1);
|
|
58
|
-
}
|
|
59
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI command for mutation initEmptyRepo
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const executor_1 = require("../executor");
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
|
-
exports.default = async (argv, prompter, _options) => {
|
|
6
|
-
try {
|
|
7
|
-
if (argv.help || argv.h) {
|
|
8
|
-
console.log('init-empty-repo - initEmptyRepo\n\nUsage: init-empty-repo [OPTIONS]\n');
|
|
9
|
-
process.exit(0);
|
|
10
|
-
}
|
|
11
|
-
const answers = await prompter.prompt(argv, [
|
|
12
|
-
{
|
|
13
|
-
type: 'text',
|
|
14
|
-
name: 'input',
|
|
15
|
-
message: 'The exclusive input argument for this mutation. An object type, make sure to see documentation for this object\u2019s fields.',
|
|
16
|
-
required: true,
|
|
17
|
-
},
|
|
18
|
-
]);
|
|
19
|
-
const client = (0, executor_1.getClient)();
|
|
20
|
-
const parsedAnswers = (0, utils_1.unflattenDotNotation)(answers);
|
|
21
|
-
const selectFields = (0, utils_1.buildSelectFromPaths)(argv.select ?? 'clientMutationId');
|
|
22
|
-
const result = await client.mutation
|
|
23
|
-
.initEmptyRepo(parsedAnswers, {
|
|
24
|
-
select: selectFields,
|
|
25
|
-
})
|
|
26
|
-
.execute();
|
|
27
|
-
console.log(JSON.stringify(result, null, 2));
|
|
28
|
-
}
|
|
29
|
-
catch (error) {
|
|
30
|
-
console.error('Failed: initEmptyRepo');
|
|
31
|
-
if (error instanceof Error) {
|
|
32
|
-
console.error(error.message);
|
|
33
|
-
}
|
|
34
|
-
process.exit(1);
|
|
35
|
-
}
|
|
36
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI command for mutation insertNodeAtPath
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const executor_1 = require("../executor");
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
|
-
exports.default = async (argv, prompter, _options) => {
|
|
6
|
-
try {
|
|
7
|
-
if (argv.help || argv.h) {
|
|
8
|
-
console.log('insert-node-at-path - insertNodeAtPath\n\nUsage: insert-node-at-path [OPTIONS]\n');
|
|
9
|
-
process.exit(0);
|
|
10
|
-
}
|
|
11
|
-
const answers = await prompter.prompt(argv, [
|
|
12
|
-
{
|
|
13
|
-
type: 'text',
|
|
14
|
-
name: 'input',
|
|
15
|
-
message: 'The exclusive input argument for this mutation. An object type, make sure to see documentation for this object\u2019s fields.',
|
|
16
|
-
required: true,
|
|
17
|
-
},
|
|
18
|
-
]);
|
|
19
|
-
const client = (0, executor_1.getClient)();
|
|
20
|
-
const parsedAnswers = (0, utils_1.unflattenDotNotation)(answers);
|
|
21
|
-
const selectFields = (0, utils_1.buildSelectFromPaths)(argv.select ?? 'clientMutationId');
|
|
22
|
-
const result = await client.mutation
|
|
23
|
-
.insertNodeAtPath(parsedAnswers, {
|
|
24
|
-
select: selectFields,
|
|
25
|
-
})
|
|
26
|
-
.execute();
|
|
27
|
-
console.log(JSON.stringify(result, null, 2));
|
|
28
|
-
}
|
|
29
|
-
catch (error) {
|
|
30
|
-
console.error('Failed: insertNodeAtPath');
|
|
31
|
-
if (error instanceof Error) {
|
|
32
|
-
console.error(error.message);
|
|
33
|
-
}
|
|
34
|
-
process.exit(1);
|
|
35
|
-
}
|
|
36
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI commands for Object
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI commands for Ref
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,292 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
/**
|
|
4
|
-
* CLI commands for Ref
|
|
5
|
-
* @generated by @constructive-io/graphql-codegen
|
|
6
|
-
* DO NOT EDIT - changes will be overwritten
|
|
7
|
-
*/
|
|
8
|
-
const inquirerer_1 = require("inquirerer");
|
|
9
|
-
const executor_1 = require("../executor");
|
|
10
|
-
const utils_1 = require("../utils");
|
|
11
|
-
const fieldSchema = {
|
|
12
|
-
id: 'uuid',
|
|
13
|
-
name: 'string',
|
|
14
|
-
databaseId: 'uuid',
|
|
15
|
-
storeId: 'uuid',
|
|
16
|
-
commitId: 'uuid',
|
|
17
|
-
};
|
|
18
|
-
const usage = '\nref <command>\n\nCommands:\n list List ref records\n find-first Find first matching ref record\n get Get a ref by ID\n create Create a new ref\n update Update an existing ref\n delete Delete a ref\n\nList Options:\n --limit <n> Max number of records to return (forward pagination)\n --last <n> Number of records from the end (backward pagination)\n --after <cursor> Cursor for forward pagination\n --before <cursor> Cursor for backward pagination\n --offset <n> Number of records to skip\n --select <fields> Comma-separated list of fields to return\n --where.<field>.<op> Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.<f>.<op> Condition filter (dot-notation)\n --orderBy <values> Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select <fields> Comma-separated list of fields to return\n --where.<field>.<op> Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.<f>.<op> Condition filter (dot-notation)\n --orderBy <values> Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n';
|
|
19
|
-
exports.default = async (argv, prompter, _options) => {
|
|
20
|
-
if (argv.help || argv.h) {
|
|
21
|
-
console.log(usage);
|
|
22
|
-
process.exit(0);
|
|
23
|
-
}
|
|
24
|
-
const { first: subcommand, newArgv } = (0, inquirerer_1.extractFirst)(argv);
|
|
25
|
-
if (!subcommand) {
|
|
26
|
-
const answer = await prompter.prompt(argv, [
|
|
27
|
-
{
|
|
28
|
-
type: 'autocomplete',
|
|
29
|
-
name: 'subcommand',
|
|
30
|
-
message: 'What do you want to do?',
|
|
31
|
-
options: ['list', 'find-first', 'get', 'create', 'update', 'delete'],
|
|
32
|
-
},
|
|
33
|
-
]);
|
|
34
|
-
return handleTableSubcommand(answer.subcommand, newArgv, prompter);
|
|
35
|
-
}
|
|
36
|
-
return handleTableSubcommand(subcommand, newArgv, prompter);
|
|
37
|
-
};
|
|
38
|
-
async function handleTableSubcommand(subcommand, argv, prompter) {
|
|
39
|
-
switch (subcommand) {
|
|
40
|
-
case 'list':
|
|
41
|
-
return handleList(argv, prompter);
|
|
42
|
-
case 'find-first':
|
|
43
|
-
return handleFindFirst(argv, prompter);
|
|
44
|
-
case 'get':
|
|
45
|
-
return handleGet(argv, prompter);
|
|
46
|
-
case 'create':
|
|
47
|
-
return handleCreate(argv, prompter);
|
|
48
|
-
case 'update':
|
|
49
|
-
return handleUpdate(argv, prompter);
|
|
50
|
-
case 'delete':
|
|
51
|
-
return handleDelete(argv, prompter);
|
|
52
|
-
default:
|
|
53
|
-
console.log(usage);
|
|
54
|
-
process.exit(1);
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
async function handleList(argv, _prompter) {
|
|
58
|
-
try {
|
|
59
|
-
const defaultSelect = {
|
|
60
|
-
id: true,
|
|
61
|
-
name: true,
|
|
62
|
-
databaseId: true,
|
|
63
|
-
storeId: true,
|
|
64
|
-
commitId: true,
|
|
65
|
-
};
|
|
66
|
-
const findManyArgs = (0, utils_1.parseFindManyArgs)(argv, defaultSelect);
|
|
67
|
-
const client = (0, executor_1.getClient)();
|
|
68
|
-
const result = await client.ref.findMany(findManyArgs).execute();
|
|
69
|
-
console.log(JSON.stringify(result, null, 2));
|
|
70
|
-
}
|
|
71
|
-
catch (error) {
|
|
72
|
-
console.error('Failed to list records.');
|
|
73
|
-
if (error instanceof Error) {
|
|
74
|
-
console.error(error.message);
|
|
75
|
-
}
|
|
76
|
-
process.exit(1);
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
async function handleFindFirst(argv, _prompter) {
|
|
80
|
-
try {
|
|
81
|
-
const defaultSelect = {
|
|
82
|
-
id: true,
|
|
83
|
-
name: true,
|
|
84
|
-
databaseId: true,
|
|
85
|
-
storeId: true,
|
|
86
|
-
commitId: true,
|
|
87
|
-
};
|
|
88
|
-
const findFirstArgs = (0, utils_1.parseFindFirstArgs)(argv, defaultSelect);
|
|
89
|
-
const client = (0, executor_1.getClient)();
|
|
90
|
-
const result = await client.ref.findFirst(findFirstArgs).execute();
|
|
91
|
-
console.log(JSON.stringify(result, null, 2));
|
|
92
|
-
}
|
|
93
|
-
catch (error) {
|
|
94
|
-
console.error('Failed to find record.');
|
|
95
|
-
if (error instanceof Error) {
|
|
96
|
-
console.error(error.message);
|
|
97
|
-
}
|
|
98
|
-
process.exit(1);
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
async function handleGet(argv, prompter) {
|
|
102
|
-
try {
|
|
103
|
-
const answers = await prompter.prompt(argv, [
|
|
104
|
-
{
|
|
105
|
-
type: 'text',
|
|
106
|
-
name: 'id',
|
|
107
|
-
message: 'id',
|
|
108
|
-
required: true,
|
|
109
|
-
},
|
|
110
|
-
]);
|
|
111
|
-
const client = (0, executor_1.getClient)();
|
|
112
|
-
const result = await client.ref
|
|
113
|
-
.findOne({
|
|
114
|
-
id: answers.id,
|
|
115
|
-
select: {
|
|
116
|
-
id: true,
|
|
117
|
-
name: true,
|
|
118
|
-
databaseId: true,
|
|
119
|
-
storeId: true,
|
|
120
|
-
commitId: true,
|
|
121
|
-
},
|
|
122
|
-
})
|
|
123
|
-
.execute();
|
|
124
|
-
console.log(JSON.stringify(result, null, 2));
|
|
125
|
-
}
|
|
126
|
-
catch (error) {
|
|
127
|
-
console.error('Record not found.');
|
|
128
|
-
if (error instanceof Error) {
|
|
129
|
-
console.error(error.message);
|
|
130
|
-
}
|
|
131
|
-
process.exit(1);
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
async function handleCreate(argv, prompter) {
|
|
135
|
-
try {
|
|
136
|
-
const rawAnswers = await prompter.prompt(argv, [
|
|
137
|
-
{
|
|
138
|
-
type: 'text',
|
|
139
|
-
name: 'name',
|
|
140
|
-
message: 'name',
|
|
141
|
-
required: true,
|
|
142
|
-
},
|
|
143
|
-
{
|
|
144
|
-
type: 'text',
|
|
145
|
-
name: 'databaseId',
|
|
146
|
-
message: 'databaseId',
|
|
147
|
-
required: true,
|
|
148
|
-
},
|
|
149
|
-
{
|
|
150
|
-
type: 'text',
|
|
151
|
-
name: 'storeId',
|
|
152
|
-
message: 'storeId',
|
|
153
|
-
required: true,
|
|
154
|
-
},
|
|
155
|
-
{
|
|
156
|
-
type: 'text',
|
|
157
|
-
name: 'commitId',
|
|
158
|
-
message: 'commitId',
|
|
159
|
-
required: false,
|
|
160
|
-
skipPrompt: true,
|
|
161
|
-
},
|
|
162
|
-
]);
|
|
163
|
-
const answers = (0, utils_1.coerceAnswers)(rawAnswers, fieldSchema);
|
|
164
|
-
const cleanedData = (0, utils_1.stripUndefined)(answers, fieldSchema);
|
|
165
|
-
const client = (0, executor_1.getClient)();
|
|
166
|
-
const result = await client.ref
|
|
167
|
-
.create({
|
|
168
|
-
data: {
|
|
169
|
-
name: cleanedData.name,
|
|
170
|
-
databaseId: cleanedData.databaseId,
|
|
171
|
-
storeId: cleanedData.storeId,
|
|
172
|
-
commitId: cleanedData.commitId,
|
|
173
|
-
},
|
|
174
|
-
select: {
|
|
175
|
-
id: true,
|
|
176
|
-
name: true,
|
|
177
|
-
databaseId: true,
|
|
178
|
-
storeId: true,
|
|
179
|
-
commitId: true,
|
|
180
|
-
},
|
|
181
|
-
})
|
|
182
|
-
.execute();
|
|
183
|
-
console.log(JSON.stringify(result, null, 2));
|
|
184
|
-
}
|
|
185
|
-
catch (error) {
|
|
186
|
-
console.error('Failed to create record.');
|
|
187
|
-
if (error instanceof Error) {
|
|
188
|
-
console.error(error.message);
|
|
189
|
-
}
|
|
190
|
-
process.exit(1);
|
|
191
|
-
}
|
|
192
|
-
}
|
|
193
|
-
async function handleUpdate(argv, prompter) {
|
|
194
|
-
try {
|
|
195
|
-
const rawAnswers = await prompter.prompt(argv, [
|
|
196
|
-
{
|
|
197
|
-
type: 'text',
|
|
198
|
-
name: 'id',
|
|
199
|
-
message: 'id',
|
|
200
|
-
required: true,
|
|
201
|
-
},
|
|
202
|
-
{
|
|
203
|
-
type: 'text',
|
|
204
|
-
name: 'name',
|
|
205
|
-
message: 'name',
|
|
206
|
-
required: false,
|
|
207
|
-
},
|
|
208
|
-
{
|
|
209
|
-
type: 'text',
|
|
210
|
-
name: 'databaseId',
|
|
211
|
-
message: 'databaseId',
|
|
212
|
-
required: false,
|
|
213
|
-
},
|
|
214
|
-
{
|
|
215
|
-
type: 'text',
|
|
216
|
-
name: 'storeId',
|
|
217
|
-
message: 'storeId',
|
|
218
|
-
required: false,
|
|
219
|
-
},
|
|
220
|
-
{
|
|
221
|
-
type: 'text',
|
|
222
|
-
name: 'commitId',
|
|
223
|
-
message: 'commitId',
|
|
224
|
-
required: false,
|
|
225
|
-
skipPrompt: true,
|
|
226
|
-
},
|
|
227
|
-
]);
|
|
228
|
-
const answers = (0, utils_1.coerceAnswers)(rawAnswers, fieldSchema);
|
|
229
|
-
const cleanedData = (0, utils_1.stripUndefined)(answers, fieldSchema);
|
|
230
|
-
const client = (0, executor_1.getClient)();
|
|
231
|
-
const result = await client.ref
|
|
232
|
-
.update({
|
|
233
|
-
where: {
|
|
234
|
-
id: answers.id,
|
|
235
|
-
},
|
|
236
|
-
data: {
|
|
237
|
-
name: cleanedData.name,
|
|
238
|
-
databaseId: cleanedData.databaseId,
|
|
239
|
-
storeId: cleanedData.storeId,
|
|
240
|
-
commitId: cleanedData.commitId,
|
|
241
|
-
},
|
|
242
|
-
select: {
|
|
243
|
-
id: true,
|
|
244
|
-
name: true,
|
|
245
|
-
databaseId: true,
|
|
246
|
-
storeId: true,
|
|
247
|
-
commitId: true,
|
|
248
|
-
},
|
|
249
|
-
})
|
|
250
|
-
.execute();
|
|
251
|
-
console.log(JSON.stringify(result, null, 2));
|
|
252
|
-
}
|
|
253
|
-
catch (error) {
|
|
254
|
-
console.error('Failed to update record.');
|
|
255
|
-
if (error instanceof Error) {
|
|
256
|
-
console.error(error.message);
|
|
257
|
-
}
|
|
258
|
-
process.exit(1);
|
|
259
|
-
}
|
|
260
|
-
}
|
|
261
|
-
async function handleDelete(argv, prompter) {
|
|
262
|
-
try {
|
|
263
|
-
const rawAnswers = await prompter.prompt(argv, [
|
|
264
|
-
{
|
|
265
|
-
type: 'text',
|
|
266
|
-
name: 'id',
|
|
267
|
-
message: 'id',
|
|
268
|
-
required: true,
|
|
269
|
-
},
|
|
270
|
-
]);
|
|
271
|
-
const answers = (0, utils_1.coerceAnswers)(rawAnswers, fieldSchema);
|
|
272
|
-
const client = (0, executor_1.getClient)();
|
|
273
|
-
const result = await client.ref
|
|
274
|
-
.delete({
|
|
275
|
-
where: {
|
|
276
|
-
id: answers.id,
|
|
277
|
-
},
|
|
278
|
-
select: {
|
|
279
|
-
id: true,
|
|
280
|
-
},
|
|
281
|
-
})
|
|
282
|
-
.execute();
|
|
283
|
-
console.log(JSON.stringify(result, null, 2));
|
|
284
|
-
}
|
|
285
|
-
catch (error) {
|
|
286
|
-
console.error('Failed to delete record.');
|
|
287
|
-
if (error instanceof Error) {
|
|
288
|
-
console.error(error.message);
|
|
289
|
-
}
|
|
290
|
-
process.exit(1);
|
|
291
|
-
}
|
|
292
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI command for mutation removeNodeAtPath
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const executor_1 = require("../executor");
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
|
-
exports.default = async (argv, prompter, _options) => {
|
|
6
|
-
try {
|
|
7
|
-
if (argv.help || argv.h) {
|
|
8
|
-
console.log('remove-node-at-path - removeNodeAtPath\n\nUsage: remove-node-at-path [OPTIONS]\n');
|
|
9
|
-
process.exit(0);
|
|
10
|
-
}
|
|
11
|
-
const answers = await prompter.prompt(argv, [
|
|
12
|
-
{
|
|
13
|
-
type: 'text',
|
|
14
|
-
name: 'input',
|
|
15
|
-
message: 'The exclusive input argument for this mutation. An object type, make sure to see documentation for this object\u2019s fields.',
|
|
16
|
-
required: true,
|
|
17
|
-
},
|
|
18
|
-
]);
|
|
19
|
-
const client = (0, executor_1.getClient)();
|
|
20
|
-
const parsedAnswers = (0, utils_1.unflattenDotNotation)(answers);
|
|
21
|
-
const selectFields = (0, utils_1.buildSelectFromPaths)(argv.select ?? 'clientMutationId');
|
|
22
|
-
const result = await client.mutation
|
|
23
|
-
.removeNodeAtPath(parsedAnswers, {
|
|
24
|
-
select: selectFields,
|
|
25
|
-
})
|
|
26
|
-
.execute();
|
|
27
|
-
console.log(JSON.stringify(result, null, 2));
|
|
28
|
-
}
|
|
29
|
-
catch (error) {
|
|
30
|
-
console.error('Failed: removeNodeAtPath');
|
|
31
|
-
if (error instanceof Error) {
|
|
32
|
-
console.error(error.message);
|
|
33
|
-
}
|
|
34
|
-
process.exit(1);
|
|
35
|
-
}
|
|
36
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI command for query revParse
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI command for mutation setAndCommit
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const executor_1 = require("../executor");
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
|
-
exports.default = async (argv, prompter, _options) => {
|
|
6
|
-
try {
|
|
7
|
-
if (argv.help || argv.h) {
|
|
8
|
-
console.log('set-and-commit - setAndCommit\n\nUsage: set-and-commit [OPTIONS]\n');
|
|
9
|
-
process.exit(0);
|
|
10
|
-
}
|
|
11
|
-
const answers = await prompter.prompt(argv, [
|
|
12
|
-
{
|
|
13
|
-
type: 'text',
|
|
14
|
-
name: 'input',
|
|
15
|
-
message: 'The exclusive input argument for this mutation. An object type, make sure to see documentation for this object\u2019s fields.',
|
|
16
|
-
required: true,
|
|
17
|
-
},
|
|
18
|
-
]);
|
|
19
|
-
const client = (0, executor_1.getClient)();
|
|
20
|
-
const parsedAnswers = (0, utils_1.unflattenDotNotation)(answers);
|
|
21
|
-
const selectFields = (0, utils_1.buildSelectFromPaths)(argv.select ?? 'clientMutationId');
|
|
22
|
-
const result = await client.mutation
|
|
23
|
-
.setAndCommit(parsedAnswers, {
|
|
24
|
-
select: selectFields,
|
|
25
|
-
})
|
|
26
|
-
.execute();
|
|
27
|
-
console.log(JSON.stringify(result, null, 2));
|
|
28
|
-
}
|
|
29
|
-
catch (error) {
|
|
30
|
-
console.error('Failed: setAndCommit');
|
|
31
|
-
if (error instanceof Error) {
|
|
32
|
-
console.error(error.message);
|
|
33
|
-
}
|
|
34
|
-
process.exit(1);
|
|
35
|
-
}
|
|
36
|
-
};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI command for mutation setDataAtPath
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { CLIOptions, Inquirerer } from 'inquirerer';
|
|
7
|
-
declare const _default: (argv: Partial<Record<string, unknown>>, prompter: Inquirerer, _options: CLIOptions) => Promise<void>;
|
|
8
|
-
export default _default;
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const executor_1 = require("../executor");
|
|
4
|
-
const utils_1 = require("../utils");
|
|
5
|
-
exports.default = async (argv, prompter, _options) => {
|
|
6
|
-
try {
|
|
7
|
-
if (argv.help || argv.h) {
|
|
8
|
-
console.log('set-data-at-path - setDataAtPath\n\nUsage: set-data-at-path [OPTIONS]\n');
|
|
9
|
-
process.exit(0);
|
|
10
|
-
}
|
|
11
|
-
const answers = await prompter.prompt(argv, [
|
|
12
|
-
{
|
|
13
|
-
type: 'text',
|
|
14
|
-
name: 'input',
|
|
15
|
-
message: 'The exclusive input argument for this mutation. An object type, make sure to see documentation for this object\u2019s fields.',
|
|
16
|
-
required: true,
|
|
17
|
-
},
|
|
18
|
-
]);
|
|
19
|
-
const client = (0, executor_1.getClient)();
|
|
20
|
-
const parsedAnswers = (0, utils_1.unflattenDotNotation)(answers);
|
|
21
|
-
const selectFields = (0, utils_1.buildSelectFromPaths)(argv.select ?? 'clientMutationId');
|
|
22
|
-
const result = await client.mutation
|
|
23
|
-
.setDataAtPath(parsedAnswers, {
|
|
24
|
-
select: selectFields,
|
|
25
|
-
})
|
|
26
|
-
.execute();
|
|
27
|
-
console.log(JSON.stringify(result, null, 2));
|
|
28
|
-
}
|
|
29
|
-
catch (error) {
|
|
30
|
-
console.error('Failed: setDataAtPath');
|
|
31
|
-
if (error instanceof Error) {
|
|
32
|
-
console.error(error.message);
|
|
33
|
-
}
|
|
34
|
-
process.exit(1);
|
|
35
|
-
}
|
|
36
|
-
};
|