@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,54 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Store model for ORM client
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { OrmClient } from '../client';
|
|
7
|
-
import { QueryBuilder } from '../query-builder';
|
|
8
|
-
import type { ConnectionResult, FindManyArgs, FindFirstArgs, CreateArgs, UpdateArgs, DeleteArgs, InferSelectResult, StrictSelect } from '../select-types';
|
|
9
|
-
import type { StoreWithRelations, StoreSelect, StoreFilter, StoreOrderBy, CreateStoreInput, StorePatch } from '../input-types';
|
|
10
|
-
export declare class StoreModel {
|
|
11
|
-
private client;
|
|
12
|
-
constructor(client: OrmClient);
|
|
13
|
-
findMany<S extends StoreSelect>(args: FindManyArgs<S, StoreFilter, StoreOrderBy> & {
|
|
14
|
-
select: S;
|
|
15
|
-
} & StrictSelect<S, StoreSelect>): QueryBuilder<{
|
|
16
|
-
stores: ConnectionResult<InferSelectResult<StoreWithRelations, S>>;
|
|
17
|
-
}>;
|
|
18
|
-
findFirst<S extends StoreSelect>(args: FindFirstArgs<S, StoreFilter, StoreOrderBy> & {
|
|
19
|
-
select: S;
|
|
20
|
-
} & StrictSelect<S, StoreSelect>): QueryBuilder<{
|
|
21
|
-
store: InferSelectResult<StoreWithRelations, S> | null;
|
|
22
|
-
}>;
|
|
23
|
-
findOne<S extends StoreSelect>(args: {
|
|
24
|
-
id: string;
|
|
25
|
-
select: S;
|
|
26
|
-
} & StrictSelect<S, StoreSelect>): QueryBuilder<{
|
|
27
|
-
store: InferSelectResult<StoreWithRelations, S> | null;
|
|
28
|
-
}>;
|
|
29
|
-
create<S extends StoreSelect>(args: CreateArgs<S, CreateStoreInput['store']> & {
|
|
30
|
-
select: S;
|
|
31
|
-
} & StrictSelect<S, StoreSelect>): QueryBuilder<{
|
|
32
|
-
createStore: {
|
|
33
|
-
store: InferSelectResult<StoreWithRelations, S>;
|
|
34
|
-
};
|
|
35
|
-
}>;
|
|
36
|
-
update<S extends StoreSelect>(args: UpdateArgs<S, {
|
|
37
|
-
id: string;
|
|
38
|
-
}, StorePatch> & {
|
|
39
|
-
select: S;
|
|
40
|
-
} & StrictSelect<S, StoreSelect>): QueryBuilder<{
|
|
41
|
-
updateStore: {
|
|
42
|
-
store: InferSelectResult<StoreWithRelations, S>;
|
|
43
|
-
};
|
|
44
|
-
}>;
|
|
45
|
-
delete<S extends StoreSelect>(args: DeleteArgs<{
|
|
46
|
-
id: string;
|
|
47
|
-
}, S> & {
|
|
48
|
-
select: S;
|
|
49
|
-
} & StrictSelect<S, StoreSelect>): QueryBuilder<{
|
|
50
|
-
deleteStore: {
|
|
51
|
-
store: InferSelectResult<StoreWithRelations, S>;
|
|
52
|
-
};
|
|
53
|
-
}>;
|
|
54
|
-
}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* UsageSnapshot model for ORM client
|
|
3
|
-
* @generated by @constructive-io/graphql-codegen
|
|
4
|
-
* DO NOT EDIT - changes will be overwritten
|
|
5
|
-
*/
|
|
6
|
-
import { OrmClient } from '../client';
|
|
7
|
-
import { QueryBuilder } from '../query-builder';
|
|
8
|
-
import type { ConnectionResult, FindManyArgs, FindFirstArgs, CreateArgs, UpdateArgs, DeleteArgs, InferSelectResult, StrictSelect } from '../select-types';
|
|
9
|
-
import type { UsageSnapshotWithRelations, UsageSnapshotSelect, UsageSnapshotFilter, UsageSnapshotOrderBy, CreateUsageSnapshotInput, UsageSnapshotPatch } from '../input-types';
|
|
10
|
-
export declare class UsageSnapshotModel {
|
|
11
|
-
private client;
|
|
12
|
-
constructor(client: OrmClient);
|
|
13
|
-
findMany<S extends UsageSnapshotSelect>(args: FindManyArgs<S, UsageSnapshotFilter, UsageSnapshotOrderBy> & {
|
|
14
|
-
select: S;
|
|
15
|
-
} & StrictSelect<S, UsageSnapshotSelect>): QueryBuilder<{
|
|
16
|
-
usageSnapshots: ConnectionResult<InferSelectResult<UsageSnapshotWithRelations, S>>;
|
|
17
|
-
}>;
|
|
18
|
-
findFirst<S extends UsageSnapshotSelect>(args: FindFirstArgs<S, UsageSnapshotFilter, UsageSnapshotOrderBy> & {
|
|
19
|
-
select: S;
|
|
20
|
-
} & StrictSelect<S, UsageSnapshotSelect>): QueryBuilder<{
|
|
21
|
-
usageSnapshot: InferSelectResult<UsageSnapshotWithRelations, S> | null;
|
|
22
|
-
}>;
|
|
23
|
-
findOne<S extends UsageSnapshotSelect>(args: {
|
|
24
|
-
id: string;
|
|
25
|
-
select: S;
|
|
26
|
-
} & StrictSelect<S, UsageSnapshotSelect>): QueryBuilder<{
|
|
27
|
-
usageSnapshot: InferSelectResult<UsageSnapshotWithRelations, S> | null;
|
|
28
|
-
}>;
|
|
29
|
-
create<S extends UsageSnapshotSelect>(args: CreateArgs<S, CreateUsageSnapshotInput['usageSnapshot']> & {
|
|
30
|
-
select: S;
|
|
31
|
-
} & StrictSelect<S, UsageSnapshotSelect>): QueryBuilder<{
|
|
32
|
-
createUsageSnapshot: {
|
|
33
|
-
usageSnapshot: InferSelectResult<UsageSnapshotWithRelations, S>;
|
|
34
|
-
};
|
|
35
|
-
}>;
|
|
36
|
-
update<S extends UsageSnapshotSelect>(args: UpdateArgs<S, {
|
|
37
|
-
id: string;
|
|
38
|
-
}, UsageSnapshotPatch> & {
|
|
39
|
-
select: S;
|
|
40
|
-
} & StrictSelect<S, UsageSnapshotSelect>): QueryBuilder<{
|
|
41
|
-
updateUsageSnapshot: {
|
|
42
|
-
usageSnapshot: InferSelectResult<UsageSnapshotWithRelations, S>;
|
|
43
|
-
};
|
|
44
|
-
}>;
|
|
45
|
-
delete<S extends UsageSnapshotSelect>(args: DeleteArgs<{
|
|
46
|
-
id: string;
|
|
47
|
-
}, S> & {
|
|
48
|
-
select: S;
|
|
49
|
-
} & StrictSelect<S, UsageSnapshotSelect>): QueryBuilder<{
|
|
50
|
-
deleteUsageSnapshot: {
|
|
51
|
-
usageSnapshot: InferSelectResult<UsageSnapshotWithRelations, S>;
|
|
52
|
-
};
|
|
53
|
-
}>;
|
|
54
|
-
}
|
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
import { QueryBuilder, buildFindManyDocument, buildFindFirstDocument, buildCreateDocument, buildUpdateByPkDocument, buildDeleteByPkDocument, } from '../query-builder';
|
|
2
|
-
import { connectionFieldsMap } from '../input-types';
|
|
3
|
-
export class UsageSnapshotModel {
|
|
4
|
-
client;
|
|
5
|
-
constructor(client) {
|
|
6
|
-
this.client = client;
|
|
7
|
-
}
|
|
8
|
-
findMany(args) {
|
|
9
|
-
const { document, variables } = buildFindManyDocument('UsageSnapshot', 'usageSnapshots', args.select, {
|
|
10
|
-
where: args?.where,
|
|
11
|
-
orderBy: args?.orderBy,
|
|
12
|
-
first: args?.first,
|
|
13
|
-
last: args?.last,
|
|
14
|
-
after: args?.after,
|
|
15
|
-
before: args?.before,
|
|
16
|
-
offset: args?.offset,
|
|
17
|
-
}, 'UsageSnapshotFilter', 'UsageSnapshotOrderBy', connectionFieldsMap);
|
|
18
|
-
return new QueryBuilder({
|
|
19
|
-
client: this.client,
|
|
20
|
-
operation: 'query',
|
|
21
|
-
operationName: 'UsageSnapshot',
|
|
22
|
-
fieldName: 'usageSnapshots',
|
|
23
|
-
document,
|
|
24
|
-
variables,
|
|
25
|
-
});
|
|
26
|
-
}
|
|
27
|
-
findFirst(args) {
|
|
28
|
-
const { document, variables } = buildFindFirstDocument('UsageSnapshot', 'usageSnapshots', args.select, {
|
|
29
|
-
where: args?.where,
|
|
30
|
-
orderBy: args?.orderBy,
|
|
31
|
-
}, 'UsageSnapshotFilter', 'UsageSnapshotOrderBy', connectionFieldsMap);
|
|
32
|
-
return new QueryBuilder({
|
|
33
|
-
client: this.client,
|
|
34
|
-
operation: 'query',
|
|
35
|
-
operationName: 'UsageSnapshot',
|
|
36
|
-
fieldName: 'usageSnapshot',
|
|
37
|
-
document,
|
|
38
|
-
variables,
|
|
39
|
-
transform: (data) => ({
|
|
40
|
-
usageSnapshot: data.usageSnapshots?.nodes?.[0] ?? null,
|
|
41
|
-
}),
|
|
42
|
-
});
|
|
43
|
-
}
|
|
44
|
-
findOne(args) {
|
|
45
|
-
const { document, variables } = buildFindManyDocument('UsageSnapshot', 'usageSnapshots', args.select, {
|
|
46
|
-
where: {
|
|
47
|
-
id: {
|
|
48
|
-
equalTo: args.id,
|
|
49
|
-
},
|
|
50
|
-
},
|
|
51
|
-
first: 1,
|
|
52
|
-
}, 'UsageSnapshotFilter', 'UsageSnapshotOrderBy', connectionFieldsMap);
|
|
53
|
-
return new QueryBuilder({
|
|
54
|
-
client: this.client,
|
|
55
|
-
operation: 'query',
|
|
56
|
-
operationName: 'UsageSnapshot',
|
|
57
|
-
fieldName: 'usageSnapshot',
|
|
58
|
-
document,
|
|
59
|
-
variables,
|
|
60
|
-
transform: (data) => ({
|
|
61
|
-
usageSnapshot: data.usageSnapshots?.nodes?.[0] ?? null,
|
|
62
|
-
}),
|
|
63
|
-
});
|
|
64
|
-
}
|
|
65
|
-
create(args) {
|
|
66
|
-
const { document, variables } = buildCreateDocument('UsageSnapshot', 'createUsageSnapshot', 'usageSnapshot', args.select, args.data, 'CreateUsageSnapshotInput', connectionFieldsMap);
|
|
67
|
-
return new QueryBuilder({
|
|
68
|
-
client: this.client,
|
|
69
|
-
operation: 'mutation',
|
|
70
|
-
operationName: 'UsageSnapshot',
|
|
71
|
-
fieldName: 'createUsageSnapshot',
|
|
72
|
-
document,
|
|
73
|
-
variables,
|
|
74
|
-
});
|
|
75
|
-
}
|
|
76
|
-
update(args) {
|
|
77
|
-
const { document, variables } = buildUpdateByPkDocument('UsageSnapshot', 'updateUsageSnapshot', 'usageSnapshot', args.select, args.where.id, args.data, 'UpdateUsageSnapshotInput', 'id', 'usageSnapshotPatch', connectionFieldsMap);
|
|
78
|
-
return new QueryBuilder({
|
|
79
|
-
client: this.client,
|
|
80
|
-
operation: 'mutation',
|
|
81
|
-
operationName: 'UsageSnapshot',
|
|
82
|
-
fieldName: 'updateUsageSnapshot',
|
|
83
|
-
document,
|
|
84
|
-
variables,
|
|
85
|
-
});
|
|
86
|
-
}
|
|
87
|
-
delete(args) {
|
|
88
|
-
const { document, variables } = buildDeleteByPkDocument('UsageSnapshot', 'deleteUsageSnapshot', 'usageSnapshot', {
|
|
89
|
-
id: args.where.id,
|
|
90
|
-
}, 'DeleteUsageSnapshotInput', args.select, connectionFieldsMap);
|
|
91
|
-
return new QueryBuilder({
|
|
92
|
-
client: this.client,
|
|
93
|
-
operation: 'mutation',
|
|
94
|
-
operationName: 'UsageSnapshot',
|
|
95
|
-
fieldName: 'deleteUsageSnapshot',
|
|
96
|
-
document,
|
|
97
|
-
variables,
|
|
98
|
-
});
|
|
99
|
-
}
|
|
100
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI commands for AgentMessage
|
|
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,326 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
/**
|
|
4
|
-
* CLI commands for AgentMessage
|
|
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
|
-
threadId: 'uuid',
|
|
13
|
-
entityId: 'uuid',
|
|
14
|
-
authorRole: 'string',
|
|
15
|
-
id: 'uuid',
|
|
16
|
-
createdAt: 'string',
|
|
17
|
-
updatedAt: 'string',
|
|
18
|
-
ownerId: 'uuid',
|
|
19
|
-
parts: 'json',
|
|
20
|
-
};
|
|
21
|
-
const usage = '\nagent-message <command>\n\nCommands:\n list List agentMessage records\n find-first Find first matching agentMessage record\n get Get a agentMessage by ID\n create Create a new agentMessage\n update Update an existing agentMessage\n delete Delete a agentMessage\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';
|
|
22
|
-
exports.default = async (argv, prompter, _options) => {
|
|
23
|
-
if (argv.help || argv.h) {
|
|
24
|
-
console.log(usage);
|
|
25
|
-
process.exit(0);
|
|
26
|
-
}
|
|
27
|
-
const { first: subcommand, newArgv } = (0, inquirerer_1.extractFirst)(argv);
|
|
28
|
-
if (!subcommand) {
|
|
29
|
-
const answer = await prompter.prompt(argv, [
|
|
30
|
-
{
|
|
31
|
-
type: 'autocomplete',
|
|
32
|
-
name: 'subcommand',
|
|
33
|
-
message: 'What do you want to do?',
|
|
34
|
-
options: ['list', 'find-first', 'get', 'create', 'update', 'delete'],
|
|
35
|
-
},
|
|
36
|
-
]);
|
|
37
|
-
return handleTableSubcommand(answer.subcommand, newArgv, prompter);
|
|
38
|
-
}
|
|
39
|
-
return handleTableSubcommand(subcommand, newArgv, prompter);
|
|
40
|
-
};
|
|
41
|
-
async function handleTableSubcommand(subcommand, argv, prompter) {
|
|
42
|
-
switch (subcommand) {
|
|
43
|
-
case 'list':
|
|
44
|
-
return handleList(argv, prompter);
|
|
45
|
-
case 'find-first':
|
|
46
|
-
return handleFindFirst(argv, prompter);
|
|
47
|
-
case 'get':
|
|
48
|
-
return handleGet(argv, prompter);
|
|
49
|
-
case 'create':
|
|
50
|
-
return handleCreate(argv, prompter);
|
|
51
|
-
case 'update':
|
|
52
|
-
return handleUpdate(argv, prompter);
|
|
53
|
-
case 'delete':
|
|
54
|
-
return handleDelete(argv, prompter);
|
|
55
|
-
default:
|
|
56
|
-
console.log(usage);
|
|
57
|
-
process.exit(1);
|
|
58
|
-
}
|
|
59
|
-
}
|
|
60
|
-
async function handleList(argv, _prompter) {
|
|
61
|
-
try {
|
|
62
|
-
const defaultSelect = {
|
|
63
|
-
threadId: true,
|
|
64
|
-
entityId: true,
|
|
65
|
-
authorRole: true,
|
|
66
|
-
id: true,
|
|
67
|
-
createdAt: true,
|
|
68
|
-
updatedAt: true,
|
|
69
|
-
ownerId: true,
|
|
70
|
-
parts: true,
|
|
71
|
-
};
|
|
72
|
-
const findManyArgs = (0, utils_1.parseFindManyArgs)(argv, defaultSelect);
|
|
73
|
-
const client = (0, executor_1.getClient)();
|
|
74
|
-
const result = await client.agentMessage.findMany(findManyArgs).execute();
|
|
75
|
-
console.log(JSON.stringify(result, null, 2));
|
|
76
|
-
}
|
|
77
|
-
catch (error) {
|
|
78
|
-
console.error('Failed to list records.');
|
|
79
|
-
if (error instanceof Error) {
|
|
80
|
-
console.error(error.message);
|
|
81
|
-
}
|
|
82
|
-
process.exit(1);
|
|
83
|
-
}
|
|
84
|
-
}
|
|
85
|
-
async function handleFindFirst(argv, _prompter) {
|
|
86
|
-
try {
|
|
87
|
-
const defaultSelect = {
|
|
88
|
-
threadId: true,
|
|
89
|
-
entityId: true,
|
|
90
|
-
authorRole: true,
|
|
91
|
-
id: true,
|
|
92
|
-
createdAt: true,
|
|
93
|
-
updatedAt: true,
|
|
94
|
-
ownerId: true,
|
|
95
|
-
parts: true,
|
|
96
|
-
};
|
|
97
|
-
const findFirstArgs = (0, utils_1.parseFindFirstArgs)(argv, defaultSelect);
|
|
98
|
-
const client = (0, executor_1.getClient)();
|
|
99
|
-
const result = await client.agentMessage.findFirst(findFirstArgs).execute();
|
|
100
|
-
console.log(JSON.stringify(result, null, 2));
|
|
101
|
-
}
|
|
102
|
-
catch (error) {
|
|
103
|
-
console.error('Failed to find record.');
|
|
104
|
-
if (error instanceof Error) {
|
|
105
|
-
console.error(error.message);
|
|
106
|
-
}
|
|
107
|
-
process.exit(1);
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
async function handleGet(argv, prompter) {
|
|
111
|
-
try {
|
|
112
|
-
const answers = await prompter.prompt(argv, [
|
|
113
|
-
{
|
|
114
|
-
type: 'text',
|
|
115
|
-
name: 'id',
|
|
116
|
-
message: 'id',
|
|
117
|
-
required: true,
|
|
118
|
-
},
|
|
119
|
-
]);
|
|
120
|
-
const client = (0, executor_1.getClient)();
|
|
121
|
-
const result = await client.agentMessage
|
|
122
|
-
.findOne({
|
|
123
|
-
id: answers.id,
|
|
124
|
-
select: {
|
|
125
|
-
threadId: true,
|
|
126
|
-
entityId: true,
|
|
127
|
-
authorRole: true,
|
|
128
|
-
id: true,
|
|
129
|
-
createdAt: true,
|
|
130
|
-
updatedAt: true,
|
|
131
|
-
ownerId: true,
|
|
132
|
-
parts: true,
|
|
133
|
-
},
|
|
134
|
-
})
|
|
135
|
-
.execute();
|
|
136
|
-
console.log(JSON.stringify(result, null, 2));
|
|
137
|
-
}
|
|
138
|
-
catch (error) {
|
|
139
|
-
console.error('Record not found.');
|
|
140
|
-
if (error instanceof Error) {
|
|
141
|
-
console.error(error.message);
|
|
142
|
-
}
|
|
143
|
-
process.exit(1);
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
async function handleCreate(argv, prompter) {
|
|
147
|
-
try {
|
|
148
|
-
const rawAnswers = await prompter.prompt(argv, [
|
|
149
|
-
{
|
|
150
|
-
type: 'text',
|
|
151
|
-
name: 'threadId',
|
|
152
|
-
message: 'threadId',
|
|
153
|
-
required: true,
|
|
154
|
-
},
|
|
155
|
-
{
|
|
156
|
-
type: 'text',
|
|
157
|
-
name: 'entityId',
|
|
158
|
-
message: 'entityId',
|
|
159
|
-
required: true,
|
|
160
|
-
},
|
|
161
|
-
{
|
|
162
|
-
type: 'text',
|
|
163
|
-
name: 'authorRole',
|
|
164
|
-
message: 'authorRole',
|
|
165
|
-
required: true,
|
|
166
|
-
},
|
|
167
|
-
{
|
|
168
|
-
type: 'text',
|
|
169
|
-
name: 'ownerId',
|
|
170
|
-
message: 'ownerId',
|
|
171
|
-
required: false,
|
|
172
|
-
skipPrompt: true,
|
|
173
|
-
},
|
|
174
|
-
{
|
|
175
|
-
type: 'json',
|
|
176
|
-
name: 'parts',
|
|
177
|
-
message: 'parts',
|
|
178
|
-
required: false,
|
|
179
|
-
skipPrompt: true,
|
|
180
|
-
},
|
|
181
|
-
]);
|
|
182
|
-
const answers = (0, utils_1.coerceAnswers)(rawAnswers, fieldSchema);
|
|
183
|
-
const cleanedData = (0, utils_1.stripUndefined)(answers, fieldSchema);
|
|
184
|
-
const client = (0, executor_1.getClient)();
|
|
185
|
-
const result = await client.agentMessage
|
|
186
|
-
.create({
|
|
187
|
-
data: {
|
|
188
|
-
threadId: cleanedData.threadId,
|
|
189
|
-
entityId: cleanedData.entityId,
|
|
190
|
-
authorRole: cleanedData.authorRole,
|
|
191
|
-
ownerId: cleanedData.ownerId,
|
|
192
|
-
parts: cleanedData.parts,
|
|
193
|
-
},
|
|
194
|
-
select: {
|
|
195
|
-
threadId: true,
|
|
196
|
-
entityId: true,
|
|
197
|
-
authorRole: true,
|
|
198
|
-
id: true,
|
|
199
|
-
createdAt: true,
|
|
200
|
-
updatedAt: true,
|
|
201
|
-
ownerId: true,
|
|
202
|
-
parts: true,
|
|
203
|
-
},
|
|
204
|
-
})
|
|
205
|
-
.execute();
|
|
206
|
-
console.log(JSON.stringify(result, null, 2));
|
|
207
|
-
}
|
|
208
|
-
catch (error) {
|
|
209
|
-
console.error('Failed to create record.');
|
|
210
|
-
if (error instanceof Error) {
|
|
211
|
-
console.error(error.message);
|
|
212
|
-
}
|
|
213
|
-
process.exit(1);
|
|
214
|
-
}
|
|
215
|
-
}
|
|
216
|
-
async function handleUpdate(argv, prompter) {
|
|
217
|
-
try {
|
|
218
|
-
const rawAnswers = await prompter.prompt(argv, [
|
|
219
|
-
{
|
|
220
|
-
type: 'text',
|
|
221
|
-
name: 'id',
|
|
222
|
-
message: 'id',
|
|
223
|
-
required: true,
|
|
224
|
-
},
|
|
225
|
-
{
|
|
226
|
-
type: 'text',
|
|
227
|
-
name: 'threadId',
|
|
228
|
-
message: 'threadId',
|
|
229
|
-
required: false,
|
|
230
|
-
},
|
|
231
|
-
{
|
|
232
|
-
type: 'text',
|
|
233
|
-
name: 'entityId',
|
|
234
|
-
message: 'entityId',
|
|
235
|
-
required: false,
|
|
236
|
-
},
|
|
237
|
-
{
|
|
238
|
-
type: 'text',
|
|
239
|
-
name: 'authorRole',
|
|
240
|
-
message: 'authorRole',
|
|
241
|
-
required: false,
|
|
242
|
-
},
|
|
243
|
-
{
|
|
244
|
-
type: 'text',
|
|
245
|
-
name: 'ownerId',
|
|
246
|
-
message: 'ownerId',
|
|
247
|
-
required: false,
|
|
248
|
-
skipPrompt: true,
|
|
249
|
-
},
|
|
250
|
-
{
|
|
251
|
-
type: 'json',
|
|
252
|
-
name: 'parts',
|
|
253
|
-
message: 'parts',
|
|
254
|
-
required: false,
|
|
255
|
-
skipPrompt: true,
|
|
256
|
-
},
|
|
257
|
-
]);
|
|
258
|
-
const answers = (0, utils_1.coerceAnswers)(rawAnswers, fieldSchema);
|
|
259
|
-
const cleanedData = (0, utils_1.stripUndefined)(answers, fieldSchema);
|
|
260
|
-
const client = (0, executor_1.getClient)();
|
|
261
|
-
const result = await client.agentMessage
|
|
262
|
-
.update({
|
|
263
|
-
where: {
|
|
264
|
-
id: answers.id,
|
|
265
|
-
},
|
|
266
|
-
data: {
|
|
267
|
-
threadId: cleanedData.threadId,
|
|
268
|
-
entityId: cleanedData.entityId,
|
|
269
|
-
authorRole: cleanedData.authorRole,
|
|
270
|
-
ownerId: cleanedData.ownerId,
|
|
271
|
-
parts: cleanedData.parts,
|
|
272
|
-
},
|
|
273
|
-
select: {
|
|
274
|
-
threadId: true,
|
|
275
|
-
entityId: true,
|
|
276
|
-
authorRole: true,
|
|
277
|
-
id: true,
|
|
278
|
-
createdAt: true,
|
|
279
|
-
updatedAt: true,
|
|
280
|
-
ownerId: true,
|
|
281
|
-
parts: true,
|
|
282
|
-
},
|
|
283
|
-
})
|
|
284
|
-
.execute();
|
|
285
|
-
console.log(JSON.stringify(result, null, 2));
|
|
286
|
-
}
|
|
287
|
-
catch (error) {
|
|
288
|
-
console.error('Failed to update record.');
|
|
289
|
-
if (error instanceof Error) {
|
|
290
|
-
console.error(error.message);
|
|
291
|
-
}
|
|
292
|
-
process.exit(1);
|
|
293
|
-
}
|
|
294
|
-
}
|
|
295
|
-
async function handleDelete(argv, prompter) {
|
|
296
|
-
try {
|
|
297
|
-
const rawAnswers = await prompter.prompt(argv, [
|
|
298
|
-
{
|
|
299
|
-
type: 'text',
|
|
300
|
-
name: 'id',
|
|
301
|
-
message: 'id',
|
|
302
|
-
required: true,
|
|
303
|
-
},
|
|
304
|
-
]);
|
|
305
|
-
const answers = (0, utils_1.coerceAnswers)(rawAnswers, fieldSchema);
|
|
306
|
-
const client = (0, executor_1.getClient)();
|
|
307
|
-
const result = await client.agentMessage
|
|
308
|
-
.delete({
|
|
309
|
-
where: {
|
|
310
|
-
id: answers.id,
|
|
311
|
-
},
|
|
312
|
-
select: {
|
|
313
|
-
id: true,
|
|
314
|
-
},
|
|
315
|
-
})
|
|
316
|
-
.execute();
|
|
317
|
-
console.log(JSON.stringify(result, null, 2));
|
|
318
|
-
}
|
|
319
|
-
catch (error) {
|
|
320
|
-
console.error('Failed to delete record.');
|
|
321
|
-
if (error instanceof Error) {
|
|
322
|
-
console.error(error.message);
|
|
323
|
-
}
|
|
324
|
-
process.exit(1);
|
|
325
|
-
}
|
|
326
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* CLI commands for AgentTask
|
|
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;
|