# ORM Client

## Setup ```typescript import { createClient } from './orm'; const db = createClient({ endpoint: 'https://api.example.com/graphql', headers: { Authorization: 'Bearer ' }, }); ``` ## Models | Model | Operations | |-------|------------| | `build` | findMany, findOne, create, update, delete | | `buildStep` | findMany, findOne, create, update, delete | | `contentPreset` | findMany, findOne, create, update, delete | | `databaseFunctionGraph` | findMany, findOne, update, delete | | `databaseFunctionGraphExecutionCancelRequest` | findMany, findOne, create, update, delete | | `databaseFunctionGraphExecution` | findMany, findOne, create, update, delete | | `databaseFunctionGraphExecutionNodeState` | findMany, findOne, create, update, delete | | `databaseFunctionGraphExecutionOutput` | findMany, findOne, create, update, delete | | `databaseGraphCommit` | findMany, findOne, create, update, delete | | `databaseGraphGetAllTreeNodesRecord` | findMany, findOne, update, delete | | `databaseGraphObject` | findMany, findOne, create, update, delete | | `databaseGraphRef` | findMany, findOne, create, update, delete | | `databaseGraphStore` | findMany, findOne, create, update, delete | | `dbPreset` | findMany, findOne, create, update, delete | | `functionApiBinding` | findMany, findOne, create, update, delete | | `functionCapabilityBinding` | findMany, findOne, create, update, delete | | `functionDefinition` | findMany, findOne, create, update, delete | | `functionDeployment` | findMany, findOne, create, update, delete | | `functionDeploymentEvent` | findMany, findOne, create, update, delete | | `functionExecutionLog` | findMany, findOne, create, update, delete | | `functionGraphCommit` | findMany, findOne, create, update, delete | | `functionGraph` | findMany, findOne, update, delete | | `functionGraphExecutionCancelRequest` | findMany, findOne, create, update, delete | | `functionGraphExecution` | findMany, findOne, create, update, delete | | `functionGraphExecutionNodeState` | findMany, findOne, create, update, delete | | `functionGraphExecutionOutput` | findMany, findOne, create, update, delete | | `functionGraphObject` | findMany, findOne, create, update, delete | | `functionGraphRef` | findMany, findOne, create, update, delete | | `functionGraphStore` | findMany, findOne, create, update, delete | | `functionInvocationAttempt` | findMany, findOne, create, update, delete | | `functionInvocation` | findMany, findOne, create, update, delete | | `functionSchedule` | findMany, findOne, create, update, delete | | `getAllTreeNodesRecord` | findMany, findOne, update, delete | | `image` | findMany, findOne, create, update, delete | | `imageGrant` | findMany, findOne, create, update, delete | | `infraCommit` | findMany, findOne, create, update, delete | | `infraGetAllTreeNodesRecord` | findMany, findOne, update, delete | | `infraObject` | findMany, findOne, create, update, delete | | `infraRef` | findMany, findOne, create, update, delete | | `infraStore` | findMany, findOne, create, update, delete | | `integrationProvider` | findMany, findOne, create, update, delete | | `namespace` | findMany, findOne, create, update, delete | | `namespaceEvent` | findMany, findOne, create, update, delete | | `platformBuild` | findMany, findOne, create, update, delete | | `platformBuildStep` | findMany, findOne, create, update, delete | | `platformFunctionApiBinding` | findMany, findOne, create, update, delete | | `platformFunctionCapabilityBinding` | findMany, findOne, create, update, delete | | `platformFunctionDefinition` | findMany, findOne, create, update, delete | | `platformFunctionDeployment` | findMany, findOne, create, update, delete | | `platformFunctionDeploymentEvent` | findMany, findOne, create, update, delete | | `platformFunctionExecutionLog` | findMany, findOne, create, update, delete | | `platformFunctionInvocationAttempt` | findMany, findOne, create, update, delete | | `platformFunctionInvocation` | findMany, findOne, create, update, delete | | `platformFunctionSchedule` | findMany, findOne, create, update, delete | | `platformImage` | findMany, findOne, create, update, delete | | `platformImageGrant` | findMany, findOne, create, update, delete | | `platformInfraCommit` | findMany, findOne, create, update, delete | | `platformInfraGetAllTreeNodesRecord` | findMany, findOne, update, delete | | `platformInfraObject` | findMany, findOne, create, update, delete | | `platformInfraRef` | findMany, findOne, create, update, delete | | `platformInfraStore` | findMany, findOne, create, update, delete | | `platformK8sResourceKind` | findMany, findOne, create, update, delete | | `platformK8sSpecRule` | findMany, findOne, create, update, delete | | `platformNamespace` | findMany, findOne, create, update, delete | | `platformNamespaceEvent` | findMany, findOne, create, update, delete | | `platformProposalComment` | findMany, findOne, create, update, delete | | `platformProposal` | findMany, findOne, create, update, delete | | `platformProposalFileView` | findMany, findOne, create, update, delete | | `platformProposalReaction` | findMany, findOne, create, update, delete | | `platformProposalReview` | findMany, findOne, create, update, delete | | `platformProposalsChunk` | findMany, findOne, create, update, delete | | `platformRegistryBinding` | findMany, findOne, create, update, delete | | `platformRegistry` | findMany, findOne, create, update, delete | | `platformRegistryGrant` | findMany, findOne, create, update, delete | | `platformRepository` | findMany, findOne, create, update, delete | | `platformRepositoryEvent` | findMany, findOne, create, update, delete | | `platformRepositoryRequiredCheck` | findMany, findOne, create, update, delete | | `platformRepositoryWorkflow` | findMany, findOne, create, update, delete | | `platformResource` | findMany, findOne, create, update, delete | | `platformResourceDeclaredCapacity` | findMany, findOne, update, delete | | `platformResourceDefinition` | findMany, findOne, create, update, delete | | `platformResourceEvent` | findMany, findOne, create, update, delete | | `platformResourceInstallation` | findMany, findOne, create, update, delete | | `platformResourceObservedStorage` | findMany, findOne, update, delete | | `platformResourceStatusCheck` | findMany, findOne, create, update, delete | | `platformResourceUsageLog` | findMany, findOne, create, update, delete | | `platformResourceUsageSummary` | findMany, findOne, create, update, delete | | `platformResourceUtilization` | findMany, findOne, update, delete | | `platformResourcesHealth` | findMany, findOne, update, delete | | `platformResourcesRequirementsState` | findMany, findOne, update, delete | | `platformResourcesResolvedRequirement` | findMany, findOne, update, delete | | `platformServiceBinding` | findMany, findOne, create, update, delete | | `platformWebhookEndpoint` | findMany, findOne, create, update, delete | | `platformWebhookEvent` | findMany, findOne, create, update, delete | | `proposalComment` | findMany, findOne, create, update, delete | | `proposal` | findMany, findOne, create, update, delete | | `proposalFileView` | findMany, findOne, create, update, delete | | `proposalReaction` | findMany, findOne, create, update, delete | | `proposalReview` | findMany, findOne, create, update, delete | | `proposalsChunk` | findMany, findOne, create, update, delete | | `registryBinding` | findMany, findOne, create, update, delete | | `registry` | findMany, findOne, create, update, delete | | `registryGrant` | findMany, findOne, create, update, delete | | `repository` | findMany, findOne, create, update, delete | | `repositoryEvent` | findMany, findOne, create, update, delete | | `repositoryRequiredCheck` | findMany, findOne, create, update, delete | | `repositoryWorkflow` | findMany, findOne, create, update, delete | | `resource` | findMany, findOne, create, update, delete | | `resourceDeclaredCapacity` | findMany, findOne, update, delete | | `resourceDefinition` | findMany, findOne, create, update, delete | | `resourceEvent` | findMany, findOne, create, update, delete | | `resourceInstallation` | findMany, findOne, create, update, delete | | `resourceObservedStorage` | findMany, findOne, update, delete | | `resourceStatusCheck` | findMany, findOne, create, update, delete | | `resourceUsageLog` | findMany, findOne, create, update, delete | | `resourceUsageSummary` | findMany, findOne, create, update, delete | | `resourceUtilization` | findMany, findOne, update, delete | | `resourcesHealth` | findMany, findOne, update, delete | | `resourcesRequirementsState` | findMany, findOne, update, delete | | `resourcesResolvedRequirement` | findMany, findOne, update, delete | | `serviceBinding` | findMany, findOne, create, update, delete | | `webhookEndpoint` | findMany, findOne, create, update, delete | | `webhookEvent` | findMany, findOne, create, update, delete | ## Table Operations ### `db.build` CRUD operations for Build records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `attempt` | Int | Yes | | `commitSha` | String | Yes | | `conclusion` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `eventId` | UUID | Yes | | `finishedAt` | Datetime | Yes | | `id` | UUID | No | | `imageRef` | String | Yes | | `jobId` | BigInt | Yes | | `logs` | ConstructiveInternalTypeUpload | Yes | | `logsUrl` | String | No | | `logsVersions` | FileVersion | No | | `matrixKey` | String | Yes | | `metadata` | JSON | Yes | | `proposalId` | UUID | Yes | | `ref` | String | Yes | | `repositoryId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `workflowId` | UUID | Yes | **Operations:** ```typescript // List all build records const items = await db.build.findMany({ select: { actorId: true, attempt: true, commitSha: true, conclusion: true, createdAt: true, createdByPrincipal: true, databaseId: true, eventId: true, finishedAt: true, id: true, imageRef: true, jobId: true, logs: true, matrixKey: true, metadata: true, proposalId: true, ref: true, repositoryId: true, startedAt: true, status: true, updatedAt: true, updatedByPrincipal: true, workflowId: true } }).execute(); // Get one by id const item = await db.build.findOne({ id: '', select: { actorId: true, attempt: true, commitSha: true, conclusion: true, createdAt: true, createdByPrincipal: true, databaseId: true, eventId: true, finishedAt: true, id: true, imageRef: true, jobId: true, logs: true, matrixKey: true, metadata: true, proposalId: true, ref: true, repositoryId: true, startedAt: true, status: true, updatedAt: true, updatedByPrincipal: true, workflowId: true } }).execute(); // Create const created = await db.build.create({ data: { actorId: '', attempt: '', commitSha: '', conclusion: '', createdByPrincipal: '', databaseId: '', eventId: '', finishedAt: '', imageRef: '', jobId: '', logs: '', matrixKey: '', metadata: '', proposalId: '', ref: '', repositoryId: '', startedAt: '', status: '', updatedByPrincipal: '', workflowId: '' }, select: { id: true } }).execute(); // Update const updated = await db.build.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.build.delete({ where: { id: '' } }).execute(); ``` ### `db.buildStep` CRUD operations for BuildStep records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `buildId` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `exitCode` | Int | Yes | | `finishedAt` | Datetime | Yes | | `id` | UUID | No | | `kind` | String | Yes | | `logBytes` | BigInt | Yes | | `logOffset` | BigInt | Yes | | `name` | String | Yes | | `parentSeq` | Int | Yes | | `recordedAt` | Datetime | Yes | | `seq` | Int | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `summary` | JSON | Yes | **Operations:** ```typescript // List all buildStep records const items = await db.buildStep.findMany({ select: { buildId: true, createdByPrincipal: true, databaseId: true, exitCode: true, finishedAt: true, id: true, kind: true, logBytes: true, logOffset: true, name: true, parentSeq: true, recordedAt: true, seq: true, startedAt: true, status: true, summary: true } }).execute(); // Get one by id const item = await db.buildStep.findOne({ id: '', select: { buildId: true, createdByPrincipal: true, databaseId: true, exitCode: true, finishedAt: true, id: true, kind: true, logBytes: true, logOffset: true, name: true, parentSeq: true, recordedAt: true, seq: true, startedAt: true, status: true, summary: true } }).execute(); // Create const created = await db.buildStep.create({ data: { buildId: '', createdByPrincipal: '', databaseId: '', exitCode: '', finishedAt: '', kind: '', logBytes: '', logOffset: '', name: '', parentSeq: '', recordedAt: '', seq: '', startedAt: '', status: '', summary: '' }, select: { id: true } }).execute(); // Update const updated = await db.buildStep.update({ where: { id: '' }, data: { buildId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.buildStep.delete({ where: { id: '' } }).execute(); ``` ### `db.contentPreset` CRUD operations for ContentPreset records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `active` | Boolean | Yes | | `commitId` | UUID | Yes | | `createdAt` | Datetime | No | | `definition` | JSON | Yes | | `description` | String | Yes | | `id` | UUID | No | | `kind` | String | Yes | | `label` | String | Yes | | `slug` | String | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all contentPreset records const items = await db.contentPreset.findMany({ select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, kind: true, label: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Get one by id const item = await db.contentPreset.findOne({ id: '', select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, kind: true, label: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Create const created = await db.contentPreset.create({ data: { active: '', commitId: '', definition: '', description: '', kind: '', label: '', slug: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.contentPreset.update({ where: { id: '' }, data: { active: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.contentPreset.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseFunctionGraph` CRUD operations for DatabaseFunctionGraph records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `context` | String | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `databaseId` | UUID | Yes | | `definitionsCommitId` | UUID | Yes | | `description` | String | Yes | | `id` | UUID | No | | `isValid` | Boolean | Yes | | `name` | String | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | | `validationErrors` | JSON | Yes | **Operations:** ```typescript // List all databaseFunctionGraph records const items = await db.databaseFunctionGraph.findMany({ select: { context: true, createdAt: true, createdBy: true, databaseId: true, definitionsCommitId: true, description: true, id: true, isValid: true, name: true, storeId: true, updatedAt: true, validationErrors: true } }).execute(); // Get one by id const item = await db.databaseFunctionGraph.findOne({ id: '', select: { context: true, createdAt: true, createdBy: true, databaseId: true, definitionsCommitId: true, description: true, id: true, isValid: true, name: true, storeId: true, updatedAt: true, validationErrors: true } }).execute(); // Update const updated = await db.databaseFunctionGraph.update({ where: { id: '' }, data: { context: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseFunctionGraph.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseFunctionGraphExecutionCancelRequest` CRUD operations for DatabaseFunctionGraphExecutionCancelRequest records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `executionId` | UUID | Yes | | `id` | UUID | No | **Operations:** ```typescript // List all databaseFunctionGraphExecutionCancelRequest records const items = await db.databaseFunctionGraphExecutionCancelRequest.findMany({ select: { actorId: true, createdAt: true, executionId: true, id: true } }).execute(); // Get one by id const item = await db.databaseFunctionGraphExecutionCancelRequest.findOne({ id: '', select: { actorId: true, createdAt: true, executionId: true, id: true } }).execute(); // Create const created = await db.databaseFunctionGraphExecutionCancelRequest.create({ data: { actorId: '', executionId: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseFunctionGraphExecutionCancelRequest.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseFunctionGraphExecutionCancelRequest.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseFunctionGraphExecution` CRUD operations for DatabaseFunctionGraphExecution records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `completedAt` | Datetime | Yes | | `currentWave` | Int | Yes | | `databaseId` | UUID | Yes | | `definitionsCommitId` | UUID | Yes | | `entityId` | UUID | Yes | | `entityType` | String | Yes | | `errorCode` | String | Yes | | `errorMessage` | String | Yes | | `executionPlan` | JSON | Yes | | `graphId` | UUID | Yes | | `id` | UUID | No | | `inputPayload` | JSON | Yes | | `invocationCreatedAt` | Datetime | Yes | | `invocationId` | UUID | Yes | | `lastProgressAt` | Datetime | Yes | | `maxPendingJobs` | Int | Yes | | `maxTicks` | Int | Yes | | `nodeOutputs` | JSON | Yes | | `organizationId` | UUID | Yes | | `outputNames` | String | Yes | | `outputNode` | String | Yes | | `outputPayload` | JSON | Yes | | `outputPort` | String | Yes | | `parentExecutionId` | UUID | Yes | | `parentInvocationId` | UUID | Yes | | `parentNodeName` | String | Yes | | `principalId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `tickCount` | Int | Yes | | `timeoutAt` | Datetime | Yes | **Operations:** ```typescript // List all databaseFunctionGraphExecution records const items = await db.databaseFunctionGraphExecution.findMany({ select: { actorId: true, completedAt: true, currentWave: true, databaseId: true, definitionsCommitId: true, entityId: true, entityType: true, errorCode: true, errorMessage: true, executionPlan: true, graphId: true, id: true, inputPayload: true, invocationCreatedAt: true, invocationId: true, lastProgressAt: true, maxPendingJobs: true, maxTicks: true, nodeOutputs: true, organizationId: true, outputNames: true, outputNode: true, outputPayload: true, outputPort: true, parentExecutionId: true, parentInvocationId: true, parentNodeName: true, principalId: true, startedAt: true, status: true, tickCount: true, timeoutAt: true } }).execute(); // Get one by id const item = await db.databaseFunctionGraphExecution.findOne({ id: '', select: { actorId: true, completedAt: true, currentWave: true, databaseId: true, definitionsCommitId: true, entityId: true, entityType: true, errorCode: true, errorMessage: true, executionPlan: true, graphId: true, id: true, inputPayload: true, invocationCreatedAt: true, invocationId: true, lastProgressAt: true, maxPendingJobs: true, maxTicks: true, nodeOutputs: true, organizationId: true, outputNames: true, outputNode: true, outputPayload: true, outputPort: true, parentExecutionId: true, parentInvocationId: true, parentNodeName: true, principalId: true, startedAt: true, status: true, tickCount: true, timeoutAt: true } }).execute(); // Create const created = await db.databaseFunctionGraphExecution.create({ data: { actorId: '', completedAt: '', currentWave: '', databaseId: '', definitionsCommitId: '', entityId: '', entityType: '', errorCode: '', errorMessage: '', executionPlan: '', graphId: '', inputPayload: '', invocationCreatedAt: '', invocationId: '', lastProgressAt: '', maxPendingJobs: '', maxTicks: '', nodeOutputs: '', organizationId: '', outputNames: '', outputNode: '', outputPayload: '', outputPort: '', parentExecutionId: '', parentInvocationId: '', parentNodeName: '', principalId: '', startedAt: '', status: '', tickCount: '', timeoutAt: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseFunctionGraphExecution.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseFunctionGraphExecution.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseFunctionGraphExecutionNodeState` CRUD operations for DatabaseFunctionGraphExecutionNodeState records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `callbackInputs` | JSON | Yes | | `callbackMeta` | JSON | Yes | | `callbackTokenHash` | String | Yes | | `completedAt` | Datetime | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `errorCode` | String | Yes | | `errorMessage` | String | Yes | | `executionId` | UUID | Yes | | `expiryDefaultOutput` | JSON | Yes | | `expiryEscalatedAt` | Datetime | Yes | | `expiryPolicy` | String | Yes | | `id` | UUID | No | | `nodeName` | String | Yes | | `nodePath` | String | Yes | | `outputId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `waitingDeadlineAt` | Datetime | Yes | | `waitingOn` | String | Yes | | `waitingSince` | Datetime | Yes | **Operations:** ```typescript // List all databaseFunctionGraphExecutionNodeState records const items = await db.databaseFunctionGraphExecutionNodeState.findMany({ select: { callbackInputs: true, callbackMeta: true, callbackTokenHash: true, completedAt: true, createdAt: true, databaseId: true, errorCode: true, errorMessage: true, executionId: true, expiryDefaultOutput: true, expiryEscalatedAt: true, expiryPolicy: true, id: true, nodeName: true, nodePath: true, outputId: true, startedAt: true, status: true, waitingDeadlineAt: true, waitingOn: true, waitingSince: true } }).execute(); // Get one by id const item = await db.databaseFunctionGraphExecutionNodeState.findOne({ id: '', select: { callbackInputs: true, callbackMeta: true, callbackTokenHash: true, completedAt: true, createdAt: true, databaseId: true, errorCode: true, errorMessage: true, executionId: true, expiryDefaultOutput: true, expiryEscalatedAt: true, expiryPolicy: true, id: true, nodeName: true, nodePath: true, outputId: true, startedAt: true, status: true, waitingDeadlineAt: true, waitingOn: true, waitingSince: true } }).execute(); // Create const created = await db.databaseFunctionGraphExecutionNodeState.create({ data: { callbackInputs: '', callbackMeta: '', callbackTokenHash: '', completedAt: '', databaseId: '', errorCode: '', errorMessage: '', executionId: '', expiryDefaultOutput: '', expiryEscalatedAt: '', expiryPolicy: '', nodeName: '', nodePath: '', outputId: '', startedAt: '', status: '', waitingDeadlineAt: '', waitingOn: '', waitingSince: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseFunctionGraphExecutionNodeState.update({ where: { id: '' }, data: { callbackInputs: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseFunctionGraphExecutionNodeState.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseFunctionGraphExecutionOutput` CRUD operations for DatabaseFunctionGraphExecutionOutput records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `data` | JSON | Yes | | `databaseId` | UUID | Yes | | `hash` | Base64EncodedBinary | Yes | | `id` | UUID | No | **Operations:** ```typescript // List all databaseFunctionGraphExecutionOutput records const items = await db.databaseFunctionGraphExecutionOutput.findMany({ select: { createdAt: true, data: true, databaseId: true, hash: true, id: true } }).execute(); // Get one by id const item = await db.databaseFunctionGraphExecutionOutput.findOne({ id: '', select: { createdAt: true, data: true, databaseId: true, hash: true, id: true } }).execute(); // Create const created = await db.databaseFunctionGraphExecutionOutput.create({ data: { data: '', databaseId: '', hash: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseFunctionGraphExecutionOutput.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseFunctionGraphExecutionOutput.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseGraphCommit` CRUD operations for DatabaseGraphCommit records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `authorId` | UUID | Yes | | `committerId` | UUID | Yes | | `databaseId` | UUID | Yes | | `date` | Datetime | Yes | | `id` | UUID | No | | `message` | String | Yes | | `parentIds` | UUID | Yes | | `storeId` | UUID | Yes | | `treeId` | UUID | Yes | **Operations:** ```typescript // List all databaseGraphCommit records const items = await db.databaseGraphCommit.findMany({ select: { authorId: true, committerId: true, databaseId: true, date: true, id: true, message: true, parentIds: true, storeId: true, treeId: true } }).execute(); // Get one by id const item = await db.databaseGraphCommit.findOne({ id: '', select: { authorId: true, committerId: true, databaseId: true, date: true, id: true, message: true, parentIds: true, storeId: true, treeId: true } }).execute(); // Create const created = await db.databaseGraphCommit.create({ data: { authorId: '', committerId: '', databaseId: '', date: '', message: '', parentIds: '', storeId: '', treeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseGraphCommit.update({ where: { id: '' }, data: { authorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseGraphCommit.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseGraphGetAllTreeNodesRecord` CRUD operations for DatabaseGraphGetAllTreeNodesRecord records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `data` | JSON | Yes | | `path` | String | Yes | **Operations:** ```typescript // List all databaseGraphGetAllTreeNodesRecord records const items = await db.databaseGraphGetAllTreeNodesRecord.findMany({ select: { data: true, path: true } }).execute(); // Get one by id const item = await db.databaseGraphGetAllTreeNodesRecord.findOne({ id: '', select: { data: true, path: true } }).execute(); // Update const updated = await db.databaseGraphGetAllTreeNodesRecord.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseGraphGetAllTreeNodesRecord.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseGraphObject` CRUD operations for DatabaseGraphObject records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `data` | JSON | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `kids` | UUID | Yes | | `ktree` | String | Yes | **Operations:** ```typescript // List all databaseGraphObject records const items = await db.databaseGraphObject.findMany({ select: { createdAt: true, data: true, databaseId: true, id: true, kids: true, ktree: true } }).execute(); // Get one by id const item = await db.databaseGraphObject.findOne({ id: '', select: { createdAt: true, data: true, databaseId: true, id: true, kids: true, ktree: true } }).execute(); // Create const created = await db.databaseGraphObject.create({ data: { data: '', databaseId: '', kids: '', ktree: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseGraphObject.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseGraphObject.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseGraphRef` CRUD operations for DatabaseGraphRef records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `commitId` | UUID | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `storeId` | UUID | Yes | **Operations:** ```typescript // List all databaseGraphRef records const items = await db.databaseGraphRef.findMany({ select: { commitId: true, databaseId: true, id: true, name: true, storeId: true } }).execute(); // Get one by id const item = await db.databaseGraphRef.findOne({ id: '', select: { commitId: true, databaseId: true, id: true, name: true, storeId: true } }).execute(); // Create const created = await db.databaseGraphRef.create({ data: { commitId: '', databaseId: '', name: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseGraphRef.update({ where: { id: '' }, data: { commitId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseGraphRef.delete({ where: { id: '' } }).execute(); ``` ### `db.databaseGraphStore` CRUD operations for DatabaseGraphStore records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `hash` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | **Operations:** ```typescript // List all databaseGraphStore records const items = await db.databaseGraphStore.findMany({ select: { createdAt: true, databaseId: true, hash: true, id: true, name: true } }).execute(); // Get one by id const item = await db.databaseGraphStore.findOne({ id: '', select: { createdAt: true, databaseId: true, hash: true, id: true, name: true } }).execute(); // Create const created = await db.databaseGraphStore.create({ data: { databaseId: '', hash: '', name: '' }, select: { id: true } }).execute(); // Update const updated = await db.databaseGraphStore.update({ where: { id: '' }, data: { databaseId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseGraphStore.delete({ where: { id: '' } }).execute(); ``` ### `db.dbPreset` CRUD operations for DbPreset records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `active` | Boolean | Yes | | `commitId` | UUID | Yes | | `createdAt` | Datetime | No | | `definition` | JSON | Yes | | `description` | String | Yes | | `id` | UUID | No | | `label` | String | Yes | | `modulesHash` | UUID | Yes | | `slug` | String | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all dbPreset records const items = await db.dbPreset.findMany({ select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, label: true, modulesHash: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Get one by id const item = await db.dbPreset.findOne({ id: '', select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, label: true, modulesHash: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Create const created = await db.dbPreset.create({ data: { active: '', commitId: '', definition: '', description: '', label: '', modulesHash: '', slug: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.dbPreset.update({ where: { id: '' }, data: { active: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.dbPreset.delete({ where: { id: '' } }).execute(); ``` ### `db.functionApiBinding` CRUD operations for FunctionApiBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `alias` | String | Yes | | `apiId` | UUID | Yes | | `config` | JSON | Yes | | `createdAt` | Datetime | No | | `functionDefinitionId` | UUID | Yes | | `id` | UUID | No | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all functionApiBinding records const items = await db.functionApiBinding.findMany({ select: { alias: true, apiId: true, config: true, createdAt: true, functionDefinitionId: true, id: true, updatedAt: true } }).execute(); // Get one by id const item = await db.functionApiBinding.findOne({ id: '', select: { alias: true, apiId: true, config: true, createdAt: true, functionDefinitionId: true, id: true, updatedAt: true } }).execute(); // Create const created = await db.functionApiBinding.create({ data: { alias: '', apiId: '', config: '', functionDefinitionId: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionApiBinding.update({ where: { id: '' }, data: { alias: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionApiBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.functionCapabilityBinding` CRUD operations for FunctionCapabilityBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `bucketId` | UUID | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `functionId` | UUID | Yes | | `graphId` | UUID | Yes | | `id` | UUID | No | | `key` | String | Yes | | `lifecycle` | String | Yes | | `metadata` | JSON | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all functionCapabilityBinding records const items = await db.functionCapabilityBinding.findMany({ select: { bucketId: true, createdAt: true, databaseId: true, functionId: true, graphId: true, id: true, key: true, lifecycle: true, metadata: true, updatedAt: true } }).execute(); // Get one by id const item = await db.functionCapabilityBinding.findOne({ id: '', select: { bucketId: true, createdAt: true, databaseId: true, functionId: true, graphId: true, id: true, key: true, lifecycle: true, metadata: true, updatedAt: true } }).execute(); // Create const created = await db.functionCapabilityBinding.create({ data: { bucketId: '', databaseId: '', functionId: '', graphId: '', key: '', lifecycle: '', metadata: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionCapabilityBinding.update({ where: { id: '' }, data: { bucketId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionCapabilityBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.functionDefinition` CRUD operations for FunctionDefinition records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `accessChannels` | String | Yes | | `anonymousCallable` | Boolean | Yes | | `category` | String | Yes | | `concurrency` | Int | Yes | | `cpuLimitMillicores` | BigInt | No | | `cpuRequestMillicores` | BigInt | No | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `description` | String | Yes | | `fnCategory` | String | Yes | | `functionColumns` | JSON | Yes | | `graphId` | UUID | Yes | | `icon` | String | Yes | | `id` | UUID | No | | `image` | String | Yes | | `inputs` | JSON | Yes | | `integrations` | String | Yes | | `isPublished` | Boolean | Yes | | `maxAttempts` | Int | Yes | | `memoryLimitBytes` | BigInt | No | | `memoryRequestBytes` | BigInt | No | | `moduleTable` | String | Yes | | `name` | String | Yes | | `outputs` | JSON | Yes | | `payloadArgs` | JSON | Yes | | `priority` | Int | Yes | | `props` | JSON | Yes | | `protected` | Boolean | Yes | | `publishedAt` | Datetime | Yes | | `queueName` | String | Yes | | `requiredBuckets` | String | Yes | | `requiredCapabilities` | JSON | Yes | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredModels` | String | Yes | | `requiredModules` | String | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `resources` | JSON | Yes | | `runtime` | String | Yes | | `scaleMax` | Int | Yes | | `scaleMin` | Int | Yes | | `targetFunction` | String | Yes | | `targetSchema` | String | Yes | | `taskIdentifier` | String | No | | `timeoutSeconds` | Int | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `volatile` | Boolean | Yes | **Operations:** ```typescript // List all functionDefinition records const items = await db.functionDefinition.findMany({ select: { accessChannels: true, anonymousCallable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdByPrincipal: true, databaseId: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredCapabilities: true, requiredModels: true, requiredModules: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true, volatile: true } }).execute(); // Get one by id const item = await db.functionDefinition.findOne({ id: '', select: { accessChannels: true, anonymousCallable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdByPrincipal: true, databaseId: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredCapabilities: true, requiredModels: true, requiredModules: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true, volatile: true } }).execute(); // Create const created = await db.functionDefinition.create({ data: { accessChannels: '', anonymousCallable: '', category: '', concurrency: '', createdByPrincipal: '', databaseId: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredCapabilities: '', requiredConfigs: '', requiredModels: '', requiredModules: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', timeoutSeconds: '', updatedByPrincipal: '', volatile: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionDefinition.update({ where: { id: '' }, data: { accessChannels: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionDefinition.delete({ where: { id: '' } }).execute(); ``` ### `db.functionDeployment` CRUD operations for FunctionDeployment records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `concurrency` | Int | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `errorCount` | Int | Yes | | `handlerName` | String | Yes | | `id` | UUID | No | | `image` | String | Yes | | `imageVersion` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `lastErrorAt` | Datetime | Yes | | `namespaceId` | UUID | Yes | | `realm` | String | Yes | | `resources` | JSON | Yes | | `revision` | Int | Yes | | `scaleMax` | Int | Yes | | `scaleMin` | Int | Yes | | `serviceName` | String | Yes | | `serviceUrl` | String | Yes | | `status` | String | Yes | | `timeoutSeconds` | Int | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all functionDeployment records const items = await db.functionDeployment.findMany({ select: { annotations: true, concurrency: true, createdAt: true, createdByPrincipal: true, databaseId: true, errorCount: true, handlerName: true, id: true, image: true, imageVersion: true, labels: true, lastError: true, lastErrorAt: true, namespaceId: true, realm: true, resources: true, revision: true, scaleMax: true, scaleMin: true, serviceName: true, serviceUrl: true, status: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.functionDeployment.findOne({ id: '', select: { annotations: true, concurrency: true, createdAt: true, createdByPrincipal: true, databaseId: true, errorCount: true, handlerName: true, id: true, image: true, imageVersion: true, labels: true, lastError: true, lastErrorAt: true, namespaceId: true, realm: true, resources: true, revision: true, scaleMax: true, scaleMin: true, serviceName: true, serviceUrl: true, status: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.functionDeployment.create({ data: { annotations: '', concurrency: '', createdByPrincipal: '', databaseId: '', errorCount: '', handlerName: '', image: '', imageVersion: '', labels: '', lastError: '', lastErrorAt: '', namespaceId: '', realm: '', resources: '', revision: '', scaleMax: '', scaleMin: '', serviceName: '', serviceUrl: '', status: '', timeoutSeconds: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionDeployment.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionDeployment.delete({ where: { id: '' } }).execute(); ``` ### `db.functionDeploymentEvent` CRUD operations for FunctionDeploymentEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `deploymentId` | UUID | Yes | | `eventType` | String | Yes | | `id` | UUID | No | | `message` | String | Yes | | `metadata` | JSON | Yes | **Operations:** ```typescript // List all functionDeploymentEvent records const items = await db.functionDeploymentEvent.findMany({ select: { actorId: true, createdAt: true, databaseId: true, deploymentId: true, eventType: true, id: true, message: true, metadata: true } }).execute(); // Get one by id const item = await db.functionDeploymentEvent.findOne({ id: '', select: { actorId: true, createdAt: true, databaseId: true, deploymentId: true, eventType: true, id: true, message: true, metadata: true } }).execute(); // Create const created = await db.functionDeploymentEvent.create({ data: { actorId: '', databaseId: '', deploymentId: '', eventType: '', message: '', metadata: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionDeploymentEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionDeploymentEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.functionExecutionLog` CRUD operations for FunctionExecutionLog records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `invocationId` | UUID | Yes | | `logLevel` | String | Yes | | `message` | String | Yes | | `metadata` | JSON | Yes | | `taskIdentifier` | String | Yes | **Operations:** ```typescript // List all functionExecutionLog records const items = await db.functionExecutionLog.findMany({ select: { actorId: true, createdAt: true, databaseId: true, id: true, invocationId: true, logLevel: true, message: true, metadata: true, taskIdentifier: true } }).execute(); // Get one by id const item = await db.functionExecutionLog.findOne({ id: '', select: { actorId: true, createdAt: true, databaseId: true, id: true, invocationId: true, logLevel: true, message: true, metadata: true, taskIdentifier: true } }).execute(); // Create const created = await db.functionExecutionLog.create({ data: { actorId: '', databaseId: '', invocationId: '', logLevel: '', message: '', metadata: '', taskIdentifier: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionExecutionLog.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionExecutionLog.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphCommit` CRUD operations for FunctionGraphCommit records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `authorId` | UUID | Yes | | `committerId` | UUID | Yes | | `date` | Datetime | Yes | | `id` | UUID | No | | `message` | String | Yes | | `parentIds` | UUID | Yes | | `scopeId` | UUID | Yes | | `storeId` | UUID | Yes | | `treeId` | UUID | Yes | **Operations:** ```typescript // List all functionGraphCommit records const items = await db.functionGraphCommit.findMany({ select: { authorId: true, committerId: true, date: true, id: true, message: true, parentIds: true, scopeId: true, storeId: true, treeId: true } }).execute(); // Get one by id const item = await db.functionGraphCommit.findOne({ id: '', select: { authorId: true, committerId: true, date: true, id: true, message: true, parentIds: true, scopeId: true, storeId: true, treeId: true } }).execute(); // Create const created = await db.functionGraphCommit.create({ data: { authorId: '', committerId: '', date: '', message: '', parentIds: '', scopeId: '', storeId: '', treeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphCommit.update({ where: { id: '' }, data: { authorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphCommit.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraph` CRUD operations for FunctionGraph records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `context` | String | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `definitionsCommitId` | UUID | Yes | | `description` | String | Yes | | `id` | UUID | No | | `isValid` | Boolean | Yes | | `name` | String | Yes | | `scopeId` | UUID | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | | `validationErrors` | JSON | Yes | **Operations:** ```typescript // List all functionGraph records const items = await db.functionGraph.findMany({ select: { context: true, createdAt: true, createdBy: true, definitionsCommitId: true, description: true, id: true, isValid: true, name: true, scopeId: true, storeId: true, updatedAt: true, validationErrors: true } }).execute(); // Get one by id const item = await db.functionGraph.findOne({ id: '', select: { context: true, createdAt: true, createdBy: true, definitionsCommitId: true, description: true, id: true, isValid: true, name: true, scopeId: true, storeId: true, updatedAt: true, validationErrors: true } }).execute(); // Update const updated = await db.functionGraph.update({ where: { id: '' }, data: { context: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraph.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphExecutionCancelRequest` CRUD operations for FunctionGraphExecutionCancelRequest records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `executionId` | UUID | Yes | | `id` | UUID | No | **Operations:** ```typescript // List all functionGraphExecutionCancelRequest records const items = await db.functionGraphExecutionCancelRequest.findMany({ select: { actorId: true, createdAt: true, executionId: true, id: true } }).execute(); // Get one by id const item = await db.functionGraphExecutionCancelRequest.findOne({ id: '', select: { actorId: true, createdAt: true, executionId: true, id: true } }).execute(); // Create const created = await db.functionGraphExecutionCancelRequest.create({ data: { actorId: '', executionId: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphExecutionCancelRequest.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphExecutionCancelRequest.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphExecution` CRUD operations for FunctionGraphExecution records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `completedAt` | Datetime | Yes | | `currentWave` | Int | Yes | | `definitionsCommitId` | UUID | Yes | | `entityId` | UUID | Yes | | `entityType` | String | Yes | | `errorCode` | String | Yes | | `errorMessage` | String | Yes | | `executionPlan` | JSON | Yes | | `graphId` | UUID | Yes | | `id` | UUID | No | | `inputPayload` | JSON | Yes | | `invocationCreatedAt` | Datetime | Yes | | `invocationId` | UUID | Yes | | `lastProgressAt` | Datetime | Yes | | `maxPendingJobs` | Int | Yes | | `maxTicks` | Int | Yes | | `nodeOutputs` | JSON | Yes | | `organizationId` | UUID | Yes | | `outputNames` | String | Yes | | `outputNode` | String | Yes | | `outputPayload` | JSON | Yes | | `outputPort` | String | Yes | | `parentExecutionId` | UUID | Yes | | `parentInvocationId` | UUID | Yes | | `parentNodeName` | String | Yes | | `principalId` | UUID | Yes | | `scopeId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `tickCount` | Int | Yes | | `timeoutAt` | Datetime | Yes | **Operations:** ```typescript // List all functionGraphExecution records const items = await db.functionGraphExecution.findMany({ select: { actorId: true, completedAt: true, currentWave: true, definitionsCommitId: true, entityId: true, entityType: true, errorCode: true, errorMessage: true, executionPlan: true, graphId: true, id: true, inputPayload: true, invocationCreatedAt: true, invocationId: true, lastProgressAt: true, maxPendingJobs: true, maxTicks: true, nodeOutputs: true, organizationId: true, outputNames: true, outputNode: true, outputPayload: true, outputPort: true, parentExecutionId: true, parentInvocationId: true, parentNodeName: true, principalId: true, scopeId: true, startedAt: true, status: true, tickCount: true, timeoutAt: true } }).execute(); // Get one by id const item = await db.functionGraphExecution.findOne({ id: '', select: { actorId: true, completedAt: true, currentWave: true, definitionsCommitId: true, entityId: true, entityType: true, errorCode: true, errorMessage: true, executionPlan: true, graphId: true, id: true, inputPayload: true, invocationCreatedAt: true, invocationId: true, lastProgressAt: true, maxPendingJobs: true, maxTicks: true, nodeOutputs: true, organizationId: true, outputNames: true, outputNode: true, outputPayload: true, outputPort: true, parentExecutionId: true, parentInvocationId: true, parentNodeName: true, principalId: true, scopeId: true, startedAt: true, status: true, tickCount: true, timeoutAt: true } }).execute(); // Create const created = await db.functionGraphExecution.create({ data: { actorId: '', completedAt: '', currentWave: '', definitionsCommitId: '', entityId: '', entityType: '', errorCode: '', errorMessage: '', executionPlan: '', graphId: '', inputPayload: '', invocationCreatedAt: '', invocationId: '', lastProgressAt: '', maxPendingJobs: '', maxTicks: '', nodeOutputs: '', organizationId: '', outputNames: '', outputNode: '', outputPayload: '', outputPort: '', parentExecutionId: '', parentInvocationId: '', parentNodeName: '', principalId: '', scopeId: '', startedAt: '', status: '', tickCount: '', timeoutAt: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphExecution.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphExecution.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphExecutionNodeState` CRUD operations for FunctionGraphExecutionNodeState records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `callbackInputs` | JSON | Yes | | `callbackMeta` | JSON | Yes | | `callbackTokenHash` | String | Yes | | `completedAt` | Datetime | Yes | | `createdAt` | Datetime | No | | `errorCode` | String | Yes | | `errorMessage` | String | Yes | | `executionId` | UUID | Yes | | `expiryDefaultOutput` | JSON | Yes | | `expiryEscalatedAt` | Datetime | Yes | | `expiryPolicy` | String | Yes | | `id` | UUID | No | | `nodeName` | String | Yes | | `nodePath` | String | Yes | | `outputId` | UUID | Yes | | `scopeId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `waitingDeadlineAt` | Datetime | Yes | | `waitingOn` | String | Yes | | `waitingSince` | Datetime | Yes | **Operations:** ```typescript // List all functionGraphExecutionNodeState records const items = await db.functionGraphExecutionNodeState.findMany({ select: { callbackInputs: true, callbackMeta: true, callbackTokenHash: true, completedAt: true, createdAt: true, errorCode: true, errorMessage: true, executionId: true, expiryDefaultOutput: true, expiryEscalatedAt: true, expiryPolicy: true, id: true, nodeName: true, nodePath: true, outputId: true, scopeId: true, startedAt: true, status: true, waitingDeadlineAt: true, waitingOn: true, waitingSince: true } }).execute(); // Get one by id const item = await db.functionGraphExecutionNodeState.findOne({ id: '', select: { callbackInputs: true, callbackMeta: true, callbackTokenHash: true, completedAt: true, createdAt: true, errorCode: true, errorMessage: true, executionId: true, expiryDefaultOutput: true, expiryEscalatedAt: true, expiryPolicy: true, id: true, nodeName: true, nodePath: true, outputId: true, scopeId: true, startedAt: true, status: true, waitingDeadlineAt: true, waitingOn: true, waitingSince: true } }).execute(); // Create const created = await db.functionGraphExecutionNodeState.create({ data: { callbackInputs: '', callbackMeta: '', callbackTokenHash: '', completedAt: '', errorCode: '', errorMessage: '', executionId: '', expiryDefaultOutput: '', expiryEscalatedAt: '', expiryPolicy: '', nodeName: '', nodePath: '', outputId: '', scopeId: '', startedAt: '', status: '', waitingDeadlineAt: '', waitingOn: '', waitingSince: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphExecutionNodeState.update({ where: { id: '' }, data: { callbackInputs: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphExecutionNodeState.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphExecutionOutput` CRUD operations for FunctionGraphExecutionOutput records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `data` | JSON | Yes | | `hash` | Base64EncodedBinary | Yes | | `id` | UUID | No | | `scopeId` | UUID | Yes | **Operations:** ```typescript // List all functionGraphExecutionOutput records const items = await db.functionGraphExecutionOutput.findMany({ select: { createdAt: true, data: true, hash: true, id: true, scopeId: true } }).execute(); // Get one by id const item = await db.functionGraphExecutionOutput.findOne({ id: '', select: { createdAt: true, data: true, hash: true, id: true, scopeId: true } }).execute(); // Create const created = await db.functionGraphExecutionOutput.create({ data: { data: '', hash: '', scopeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphExecutionOutput.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphExecutionOutput.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphObject` CRUD operations for FunctionGraphObject records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `data` | JSON | Yes | | `id` | UUID | No | | `kids` | UUID | Yes | | `ktree` | String | Yes | | `scopeId` | UUID | Yes | **Operations:** ```typescript // List all functionGraphObject records const items = await db.functionGraphObject.findMany({ select: { createdAt: true, data: true, id: true, kids: true, ktree: true, scopeId: true } }).execute(); // Get one by id const item = await db.functionGraphObject.findOne({ id: '', select: { createdAt: true, data: true, id: true, kids: true, ktree: true, scopeId: true } }).execute(); // Create const created = await db.functionGraphObject.create({ data: { data: '', kids: '', ktree: '', scopeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphObject.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphObject.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphRef` CRUD operations for FunctionGraphRef records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `commitId` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `scopeId` | UUID | Yes | | `storeId` | UUID | Yes | **Operations:** ```typescript // List all functionGraphRef records const items = await db.functionGraphRef.findMany({ select: { commitId: true, id: true, name: true, scopeId: true, storeId: true } }).execute(); // Get one by id const item = await db.functionGraphRef.findOne({ id: '', select: { commitId: true, id: true, name: true, scopeId: true, storeId: true } }).execute(); // Create const created = await db.functionGraphRef.create({ data: { commitId: '', name: '', scopeId: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphRef.update({ where: { id: '' }, data: { commitId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphRef.delete({ where: { id: '' } }).execute(); ``` ### `db.functionGraphStore` CRUD operations for FunctionGraphStore records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `hash` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `scopeId` | UUID | Yes | **Operations:** ```typescript // List all functionGraphStore records const items = await db.functionGraphStore.findMany({ select: { createdAt: true, hash: true, id: true, name: true, scopeId: true } }).execute(); // Get one by id const item = await db.functionGraphStore.findOne({ id: '', select: { createdAt: true, hash: true, id: true, name: true, scopeId: true } }).execute(); // Create const created = await db.functionGraphStore.create({ data: { hash: '', name: '', scopeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionGraphStore.update({ where: { id: '' }, data: { hash: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionGraphStore.delete({ where: { id: '' } }).execute(); ``` ### `db.functionInvocationAttempt` CRUD operations for FunctionInvocationAttempt records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `attempt` | Int | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `durationMs` | Int | Yes | | `error` | String | Yes | | `errorDetail` | JSON | Yes | | `id` | UUID | No | | `invocationCreatedAt` | Datetime | Yes | | `invocationId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `success` | Boolean | Yes | | `taskIdentifier` | String | Yes | **Operations:** ```typescript // List all functionInvocationAttempt records const items = await db.functionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); // Get one by id const item = await db.functionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); // Create const created = await db.functionInvocationAttempt.create({ data: { actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionInvocationAttempt.delete({ where: { id: '' } }).execute(); ``` ### `db.functionInvocation` CRUD operations for FunctionInvocation records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `apiBindingId` | UUID | Yes | | `channel` | String | Yes | | `completedAt` | Datetime | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `definitionScope` | String | Yes | | `durationMs` | Int | Yes | | `entityId` | UUID | Yes | | `entityType` | String | Yes | | `error` | String | Yes | | `functionDefinitionId` | UUID | Yes | | `graphExecutionId` | UUID | Yes | | `id` | UUID | No | | `jobId` | BigInt | Yes | | `jobKey` | String | Yes | | `organizationId` | UUID | Yes | | `parentInvocationId` | UUID | Yes | | `payload` | JSON | Yes | | `principalId` | UUID | Yes | | `provenance` | JSON | Yes | | `queueName` | String | Yes | | `result` | JSON | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `taskIdentifier` | String | Yes | **Operations:** ```typescript // List all functionInvocation records const items = await db.functionInvocation.findMany({ select: { actorId: true, apiBindingId: true, channel: true, completedAt: true, createdAt: true, createdByPrincipal: true, databaseId: true, definitionScope: true, durationMs: true, entityId: true, entityType: true, error: true, functionDefinitionId: true, graphExecutionId: true, id: true, jobId: true, jobKey: true, organizationId: true, parentInvocationId: true, payload: true, principalId: true, provenance: true, queueName: true, result: true, startedAt: true, status: true, taskIdentifier: true } }).execute(); // Get one by id const item = await db.functionInvocation.findOne({ id: '', select: { actorId: true, apiBindingId: true, channel: true, completedAt: true, createdAt: true, createdByPrincipal: true, databaseId: true, definitionScope: true, durationMs: true, entityId: true, entityType: true, error: true, functionDefinitionId: true, graphExecutionId: true, id: true, jobId: true, jobKey: true, organizationId: true, parentInvocationId: true, payload: true, principalId: true, provenance: true, queueName: true, result: true, startedAt: true, status: true, taskIdentifier: true } }).execute(); // Create const created = await db.functionInvocation.create({ data: { actorId: '', apiBindingId: '', channel: '', completedAt: '', createdByPrincipal: '', databaseId: '', definitionScope: '', durationMs: '', entityId: '', entityType: '', error: '', functionDefinitionId: '', graphExecutionId: '', jobId: '', jobKey: '', organizationId: '', parentInvocationId: '', payload: '', principalId: '', provenance: '', queueName: '', result: '', startedAt: '', status: '', taskIdentifier: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionInvocation.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionInvocation.delete({ where: { id: '' } }).execute(); ``` ### `db.functionSchedule` CRUD operations for FunctionSchedule records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `description` | String | Yes | | `functionDefinitionId` | UUID | Yes | | `id` | UUID | No | | `isActive` | Boolean | Yes | | `name` | String | Yes | | `payload` | JSON | Yes | | `scheduleInfo` | JSON | Yes | | `suspendedAt` | Datetime | Yes | | `suspendedReason` | String | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all functionSchedule records const items = await db.functionSchedule.findMany({ select: { actorId: true, createdAt: true, databaseId: true, description: true, functionDefinitionId: true, id: true, isActive: true, name: true, payload: true, scheduleInfo: true, suspendedAt: true, suspendedReason: true, updatedAt: true } }).execute(); // Get one by id const item = await db.functionSchedule.findOne({ id: '', select: { actorId: true, createdAt: true, databaseId: true, description: true, functionDefinitionId: true, id: true, isActive: true, name: true, payload: true, scheduleInfo: true, suspendedAt: true, suspendedReason: true, updatedAt: true } }).execute(); // Create const created = await db.functionSchedule.create({ data: { actorId: '', databaseId: '', description: '', functionDefinitionId: '', isActive: '', name: '', payload: '', scheduleInfo: '', suspendedAt: '', suspendedReason: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionSchedule.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.functionSchedule.delete({ where: { id: '' } }).execute(); ``` ### `db.getAllTreeNodesRecord` CRUD operations for GetAllTreeNodesRecord records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `data` | JSON | Yes | | `path` | String | Yes | **Operations:** ```typescript // List all getAllTreeNodesRecord records const items = await db.getAllTreeNodesRecord.findMany({ select: { data: true, path: true } }).execute(); // Get one by id const item = await db.getAllTreeNodesRecord.findOne({ id: '', select: { data: true, path: true } }).execute(); // Update const updated = await db.getAllTreeNodesRecord.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.getAllTreeNodesRecord.delete({ where: { id: '' } }).execute(); ``` ### `db.image` CRUD operations for Image records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `description` | String | Yes | | `digest` | String | Yes | | `expiresAt` | Datetime | Yes | | `id` | UUID | No | | `isPublished` | Boolean | Yes | | `labels` | JSON | Yes | | `metadata` | JSON | Yes | | `name` | String | Yes | | `ownerId` | UUID | Yes | | `platformOnly` | Boolean | Yes | | `registryHost` | String | Yes | | `repository` | String | Yes | | `runtime` | String | Yes | | `tag` | String | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all image records const items = await db.image.findMany({ select: { createdAt: true, createdByPrincipal: true, databaseId: true, description: true, digest: true, expiresAt: true, id: true, isPublished: true, labels: true, metadata: true, name: true, ownerId: true, platformOnly: true, registryHost: true, repository: true, runtime: true, tag: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.image.findOne({ id: '', select: { createdAt: true, createdByPrincipal: true, databaseId: true, description: true, digest: true, expiresAt: true, id: true, isPublished: true, labels: true, metadata: true, name: true, ownerId: true, platformOnly: true, registryHost: true, repository: true, runtime: true, tag: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.image.create({ data: { createdByPrincipal: '', databaseId: '', description: '', digest: '', expiresAt: '', isPublished: '', labels: '', metadata: '', name: '', ownerId: '', platformOnly: '', registryHost: '', repository: '', runtime: '', tag: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.image.update({ where: { id: '' }, data: { createdByPrincipal: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.image.delete({ where: { id: '' } }).execute(); ``` ### `db.imageGrant` CRUD operations for ImageGrant records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actions` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `expiresAt` | Datetime | Yes | | `grantedBy` | UUID | Yes | | `granteeKey` | UUID | Yes | | `granteeScope` | String | Yes | | `id` | UUID | No | | `imageId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all imageGrant records const items = await db.imageGrant.findMany({ select: { actions: true, createdAt: true, createdByPrincipal: true, databaseId: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, imageId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.imageGrant.findOne({ id: '', select: { actions: true, createdAt: true, createdByPrincipal: true, databaseId: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, imageId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.imageGrant.create({ data: { actions: '', createdByPrincipal: '', databaseId: '', expiresAt: '', grantedBy: '', granteeKey: '', granteeScope: '', imageId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.imageGrant.update({ where: { id: '' }, data: { actions: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.imageGrant.delete({ where: { id: '' } }).execute(); ``` ### `db.infraCommit` CRUD operations for InfraCommit records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `authorId` | UUID | Yes | | `committerId` | UUID | Yes | | `databaseId` | UUID | Yes | | `date` | Datetime | Yes | | `id` | UUID | No | | `message` | String | Yes | | `parentIds` | UUID | Yes | | `storeId` | UUID | Yes | | `treeId` | UUID | Yes | **Operations:** ```typescript // List all infraCommit records const items = await db.infraCommit.findMany({ select: { authorId: true, committerId: true, databaseId: true, date: true, id: true, message: true, parentIds: true, storeId: true, treeId: true } }).execute(); // Get one by id const item = await db.infraCommit.findOne({ id: '', select: { authorId: true, committerId: true, databaseId: true, date: true, id: true, message: true, parentIds: true, storeId: true, treeId: true } }).execute(); // Create const created = await db.infraCommit.create({ data: { authorId: '', committerId: '', databaseId: '', date: '', message: '', parentIds: '', storeId: '', treeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.infraCommit.update({ where: { id: '' }, data: { authorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.infraCommit.delete({ where: { id: '' } }).execute(); ``` ### `db.infraGetAllTreeNodesRecord` CRUD operations for InfraGetAllTreeNodesRecord records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `data` | JSON | Yes | | `path` | String | Yes | **Operations:** ```typescript // List all infraGetAllTreeNodesRecord records const items = await db.infraGetAllTreeNodesRecord.findMany({ select: { data: true, path: true } }).execute(); // Get one by id const item = await db.infraGetAllTreeNodesRecord.findOne({ id: '', select: { data: true, path: true } }).execute(); // Update const updated = await db.infraGetAllTreeNodesRecord.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.infraGetAllTreeNodesRecord.delete({ where: { id: '' } }).execute(); ``` ### `db.infraObject` CRUD operations for InfraObject records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `data` | JSON | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `kids` | UUID | Yes | | `ktree` | String | Yes | **Operations:** ```typescript // List all infraObject records const items = await db.infraObject.findMany({ select: { createdAt: true, data: true, databaseId: true, id: true, kids: true, ktree: true } }).execute(); // Get one by id const item = await db.infraObject.findOne({ id: '', select: { createdAt: true, data: true, databaseId: true, id: true, kids: true, ktree: true } }).execute(); // Create const created = await db.infraObject.create({ data: { data: '', databaseId: '', kids: '', ktree: '' }, select: { id: true } }).execute(); // Update const updated = await db.infraObject.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.infraObject.delete({ where: { id: '' } }).execute(); ``` ### `db.infraRef` CRUD operations for InfraRef records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `commitId` | UUID | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `storeId` | UUID | Yes | **Operations:** ```typescript // List all infraRef records const items = await db.infraRef.findMany({ select: { commitId: true, databaseId: true, id: true, name: true, storeId: true } }).execute(); // Get one by id const item = await db.infraRef.findOne({ id: '', select: { commitId: true, databaseId: true, id: true, name: true, storeId: true } }).execute(); // Create const created = await db.infraRef.create({ data: { commitId: '', databaseId: '', name: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.infraRef.update({ where: { id: '' }, data: { commitId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.infraRef.delete({ where: { id: '' } }).execute(); ``` ### `db.infraStore` CRUD operations for InfraStore records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `hash` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | **Operations:** ```typescript // List all infraStore records const items = await db.infraStore.findMany({ select: { createdAt: true, databaseId: true, hash: true, id: true, name: true } }).execute(); // Get one by id const item = await db.infraStore.findOne({ id: '', select: { createdAt: true, databaseId: true, hash: true, id: true, name: true } }).execute(); // Create const created = await db.infraStore.create({ data: { databaseId: '', hash: '', name: '' }, select: { id: true } }).execute(); // Update const updated = await db.infraStore.update({ where: { id: '' }, data: { databaseId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.infraStore.delete({ where: { id: '' } }).execute(); ``` ### `db.integrationProvider` CRUD operations for IntegrationProvider records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `brand` | JSON | Yes | | `category` | String | Yes | | `createdAt` | Datetime | No | | `description` | String | Yes | | `icon` | String | Yes | | `id` | UUID | No | | `logo` | ConstructiveInternalTypeImage | Yes | | `logoUrl` | String | No | | `logoVersions` | FileVersion | No | | `name` | String | Yes | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `slug` | String | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all integrationProvider records const items = await db.integrationProvider.findMany({ select: { brand: true, category: true, createdAt: true, description: true, icon: true, id: true, logo: true, name: true, slug: true, updatedAt: true } }).execute(); // Get one by id const item = await db.integrationProvider.findOne({ id: '', select: { brand: true, category: true, createdAt: true, description: true, icon: true, id: true, logo: true, name: true, slug: true, updatedAt: true } }).execute(); // Create const created = await db.integrationProvider.create({ data: { brand: '', category: '', description: '', icon: '', logo: '', name: '', requiredConfigs: '', requiredSecrets: '', slug: '' }, select: { id: true } }).execute(); // Update const updated = await db.integrationProvider.update({ where: { id: '' }, data: { brand: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.integrationProvider.delete({ where: { id: '' } }).execute(); ``` ### `db.namespace` CRUD operations for Namespace records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `clusterId` | UUID | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `description` | String | Yes | | `id` | UUID | No | | `isActive` | Boolean | Yes | | `isManaged` | Boolean | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `name` | String | Yes | | `namespaceName` | String | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all namespace records const items = await db.namespace.findMany({ select: { annotations: true, clusterId: true, createdAt: true, databaseId: true, description: true, id: true, isActive: true, isManaged: true, labels: true, lastError: true, name: true, namespaceName: true, status: true, updatedAt: true } }).execute(); // Get one by id const item = await db.namespace.findOne({ id: '', select: { annotations: true, clusterId: true, createdAt: true, databaseId: true, description: true, id: true, isActive: true, isManaged: true, labels: true, lastError: true, name: true, namespaceName: true, status: true, updatedAt: true } }).execute(); // Create const created = await db.namespace.create({ data: { annotations: '', clusterId: '', databaseId: '', description: '', isActive: '', isManaged: '', labels: '', lastError: '', name: '', namespaceName: '', status: '' }, select: { id: true } }).execute(); // Update const updated = await db.namespace.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.namespace.delete({ where: { id: '' } }).execute(); ``` ### `db.namespaceEvent` CRUD operations for NamespaceEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `eventType` | String | Yes | | `id` | UUID | No | | `message` | String | Yes | | `metadata` | JSON | Yes | | `namespaceId` | UUID | Yes | **Operations:** ```typescript // List all namespaceEvent records const items = await db.namespaceEvent.findMany({ select: { actorId: true, createdAt: true, databaseId: true, eventType: true, id: true, message: true, metadata: true, namespaceId: true } }).execute(); // Get one by id const item = await db.namespaceEvent.findOne({ id: '', select: { actorId: true, createdAt: true, databaseId: true, eventType: true, id: true, message: true, metadata: true, namespaceId: true } }).execute(); // Create const created = await db.namespaceEvent.create({ data: { actorId: '', databaseId: '', eventType: '', message: '', metadata: '', namespaceId: '' }, select: { id: true } }).execute(); // Update const updated = await db.namespaceEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.namespaceEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.platformBuild` CRUD operations for PlatformBuild records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `attempt` | Int | Yes | | `commitSha` | String | Yes | | `conclusion` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `eventId` | UUID | Yes | | `finishedAt` | Datetime | Yes | | `id` | UUID | No | | `imageRef` | String | Yes | | `jobId` | BigInt | Yes | | `logs` | ConstructiveInternalTypeUpload | Yes | | `logsUrl` | String | No | | `logsVersions` | FileVersion | No | | `matrixKey` | String | Yes | | `metadata` | JSON | Yes | | `proposalId` | UUID | Yes | | `ref` | String | Yes | | `repositoryId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `workflowId` | UUID | Yes | **Operations:** ```typescript // List all platformBuild records const items = await db.platformBuild.findMany({ select: { actorId: true, attempt: true, commitSha: true, conclusion: true, createdAt: true, createdByPrincipal: true, eventId: true, finishedAt: true, id: true, imageRef: true, jobId: true, logs: true, matrixKey: true, metadata: true, proposalId: true, ref: true, repositoryId: true, startedAt: true, status: true, updatedAt: true, updatedByPrincipal: true, workflowId: true } }).execute(); // Get one by id const item = await db.platformBuild.findOne({ id: '', select: { actorId: true, attempt: true, commitSha: true, conclusion: true, createdAt: true, createdByPrincipal: true, eventId: true, finishedAt: true, id: true, imageRef: true, jobId: true, logs: true, matrixKey: true, metadata: true, proposalId: true, ref: true, repositoryId: true, startedAt: true, status: true, updatedAt: true, updatedByPrincipal: true, workflowId: true } }).execute(); // Create const created = await db.platformBuild.create({ data: { actorId: '', attempt: '', commitSha: '', conclusion: '', createdByPrincipal: '', eventId: '', finishedAt: '', imageRef: '', jobId: '', logs: '', matrixKey: '', metadata: '', proposalId: '', ref: '', repositoryId: '', startedAt: '', status: '', updatedByPrincipal: '', workflowId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformBuild.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformBuild.delete({ where: { id: '' } }).execute(); ``` ### `db.platformBuildStep` CRUD operations for PlatformBuildStep records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `buildId` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `exitCode` | Int | Yes | | `finishedAt` | Datetime | Yes | | `id` | UUID | No | | `kind` | String | Yes | | `logBytes` | BigInt | Yes | | `logOffset` | BigInt | Yes | | `name` | String | Yes | | `parentSeq` | Int | Yes | | `recordedAt` | Datetime | Yes | | `seq` | Int | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `summary` | JSON | Yes | **Operations:** ```typescript // List all platformBuildStep records const items = await db.platformBuildStep.findMany({ select: { buildId: true, createdByPrincipal: true, exitCode: true, finishedAt: true, id: true, kind: true, logBytes: true, logOffset: true, name: true, parentSeq: true, recordedAt: true, seq: true, startedAt: true, status: true, summary: true } }).execute(); // Get one by id const item = await db.platformBuildStep.findOne({ id: '', select: { buildId: true, createdByPrincipal: true, exitCode: true, finishedAt: true, id: true, kind: true, logBytes: true, logOffset: true, name: true, parentSeq: true, recordedAt: true, seq: true, startedAt: true, status: true, summary: true } }).execute(); // Create const created = await db.platformBuildStep.create({ data: { buildId: '', createdByPrincipal: '', exitCode: '', finishedAt: '', kind: '', logBytes: '', logOffset: '', name: '', parentSeq: '', recordedAt: '', seq: '', startedAt: '', status: '', summary: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformBuildStep.update({ where: { id: '' }, data: { buildId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformBuildStep.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionApiBinding` CRUD operations for PlatformFunctionApiBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `alias` | String | Yes | | `apiId` | UUID | Yes | | `config` | JSON | Yes | | `createdAt` | Datetime | No | | `functionDefinitionId` | UUID | Yes | | `id` | UUID | No | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformFunctionApiBinding records const items = await db.platformFunctionApiBinding.findMany({ select: { alias: true, apiId: true, config: true, createdAt: true, functionDefinitionId: true, id: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformFunctionApiBinding.findOne({ id: '', select: { alias: true, apiId: true, config: true, createdAt: true, functionDefinitionId: true, id: true, updatedAt: true } }).execute(); // Create const created = await db.platformFunctionApiBinding.create({ data: { alias: '', apiId: '', config: '', functionDefinitionId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionApiBinding.update({ where: { id: '' }, data: { alias: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionApiBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionCapabilityBinding` CRUD operations for PlatformFunctionCapabilityBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `bucketId` | UUID | Yes | | `createdAt` | Datetime | No | | `functionId` | UUID | Yes | | `graphId` | UUID | Yes | | `id` | UUID | No | | `key` | String | Yes | | `lifecycle` | String | Yes | | `metadata` | JSON | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformFunctionCapabilityBinding records const items = await db.platformFunctionCapabilityBinding.findMany({ select: { bucketId: true, createdAt: true, functionId: true, graphId: true, id: true, key: true, lifecycle: true, metadata: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformFunctionCapabilityBinding.findOne({ id: '', select: { bucketId: true, createdAt: true, functionId: true, graphId: true, id: true, key: true, lifecycle: true, metadata: true, updatedAt: true } }).execute(); // Create const created = await db.platformFunctionCapabilityBinding.create({ data: { bucketId: '', functionId: '', graphId: '', key: '', lifecycle: '', metadata: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionCapabilityBinding.update({ where: { id: '' }, data: { bucketId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionCapabilityBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionDefinition` CRUD operations for PlatformFunctionDefinition records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `accessChannels` | String | Yes | | `anonymousCallable` | Boolean | Yes | | `billable` | Boolean | Yes | | `category` | String | Yes | | `concurrency` | Int | Yes | | `cpuLimitMillicores` | BigInt | No | | `cpuRequestMillicores` | BigInt | No | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `description` | String | Yes | | `fnCategory` | String | Yes | | `functionColumns` | JSON | Yes | | `graphId` | UUID | Yes | | `icon` | String | Yes | | `id` | UUID | No | | `image` | String | Yes | | `inputs` | JSON | Yes | | `integrations` | String | Yes | | `isPublished` | Boolean | Yes | | `maxAttempts` | Int | Yes | | `memoryLimitBytes` | BigInt | No | | `memoryRequestBytes` | BigInt | No | | `moduleTable` | String | Yes | | `name` | String | Yes | | `outputs` | JSON | Yes | | `payloadArgs` | JSON | Yes | | `priority` | Int | Yes | | `props` | JSON | Yes | | `protected` | Boolean | Yes | | `publishedAt` | Datetime | Yes | | `queueName` | String | Yes | | `requiredBuckets` | String | Yes | | `requiredCapabilities` | JSON | Yes | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredModels` | String | Yes | | `requiredModules` | String | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `resources` | JSON | Yes | | `runtime` | String | Yes | | `scaleMax` | Int | Yes | | `scaleMin` | Int | Yes | | `system` | Boolean | Yes | | `targetFunction` | String | Yes | | `targetSchema` | String | Yes | | `taskIdentifier` | String | No | | `timeoutSeconds` | Int | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `volatile` | Boolean | Yes | **Operations:** ```typescript // List all platformFunctionDefinition records const items = await db.platformFunctionDefinition.findMany({ select: { accessChannels: true, anonymousCallable: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdByPrincipal: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredCapabilities: true, requiredModels: true, requiredModules: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true, volatile: true } }).execute(); // Get one by id const item = await db.platformFunctionDefinition.findOne({ id: '', select: { accessChannels: true, anonymousCallable: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdByPrincipal: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredCapabilities: true, requiredModels: true, requiredModules: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true, volatile: true } }).execute(); // Create const created = await db.platformFunctionDefinition.create({ data: { accessChannels: '', anonymousCallable: '', billable: '', category: '', concurrency: '', createdByPrincipal: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredCapabilities: '', requiredConfigs: '', requiredModels: '', requiredModules: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', timeoutSeconds: '', updatedByPrincipal: '', volatile: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionDefinition.update({ where: { id: '' }, data: { accessChannels: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionDefinition.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionDeployment` CRUD operations for PlatformFunctionDeployment records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `concurrency` | Int | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `errorCount` | Int | Yes | | `handlerName` | String | Yes | | `id` | UUID | No | | `image` | String | Yes | | `imageVersion` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `lastErrorAt` | Datetime | Yes | | `namespaceId` | UUID | Yes | | `realm` | String | Yes | | `resources` | JSON | Yes | | `revision` | Int | Yes | | `scaleMax` | Int | Yes | | `scaleMin` | Int | Yes | | `serviceName` | String | Yes | | `serviceUrl` | String | Yes | | `status` | String | Yes | | `timeoutSeconds` | Int | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformFunctionDeployment records const items = await db.platformFunctionDeployment.findMany({ select: { annotations: true, concurrency: true, createdAt: true, createdByPrincipal: true, errorCount: true, handlerName: true, id: true, image: true, imageVersion: true, labels: true, lastError: true, lastErrorAt: true, namespaceId: true, realm: true, resources: true, revision: true, scaleMax: true, scaleMin: true, serviceName: true, serviceUrl: true, status: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformFunctionDeployment.findOne({ id: '', select: { annotations: true, concurrency: true, createdAt: true, createdByPrincipal: true, errorCount: true, handlerName: true, id: true, image: true, imageVersion: true, labels: true, lastError: true, lastErrorAt: true, namespaceId: true, realm: true, resources: true, revision: true, scaleMax: true, scaleMin: true, serviceName: true, serviceUrl: true, status: true, timeoutSeconds: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformFunctionDeployment.create({ data: { annotations: '', concurrency: '', createdByPrincipal: '', errorCount: '', handlerName: '', image: '', imageVersion: '', labels: '', lastError: '', lastErrorAt: '', namespaceId: '', realm: '', resources: '', revision: '', scaleMax: '', scaleMin: '', serviceName: '', serviceUrl: '', status: '', timeoutSeconds: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionDeployment.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionDeployment.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionDeploymentEvent` CRUD operations for PlatformFunctionDeploymentEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `deploymentId` | UUID | Yes | | `eventType` | String | Yes | | `id` | UUID | No | | `message` | String | Yes | | `metadata` | JSON | Yes | **Operations:** ```typescript // List all platformFunctionDeploymentEvent records const items = await db.platformFunctionDeploymentEvent.findMany({ select: { actorId: true, createdAt: true, deploymentId: true, eventType: true, id: true, message: true, metadata: true } }).execute(); // Get one by id const item = await db.platformFunctionDeploymentEvent.findOne({ id: '', select: { actorId: true, createdAt: true, deploymentId: true, eventType: true, id: true, message: true, metadata: true } }).execute(); // Create const created = await db.platformFunctionDeploymentEvent.create({ data: { actorId: '', deploymentId: '', eventType: '', message: '', metadata: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionDeploymentEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionDeploymentEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionExecutionLog` CRUD operations for PlatformFunctionExecutionLog records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `id` | UUID | No | | `invocationId` | UUID | Yes | | `logLevel` | String | Yes | | `message` | String | Yes | | `metadata` | JSON | Yes | | `taskIdentifier` | String | Yes | **Operations:** ```typescript // List all platformFunctionExecutionLog records const items = await db.platformFunctionExecutionLog.findMany({ select: { actorId: true, createdAt: true, id: true, invocationId: true, logLevel: true, message: true, metadata: true, taskIdentifier: true } }).execute(); // Get one by id const item = await db.platformFunctionExecutionLog.findOne({ id: '', select: { actorId: true, createdAt: true, id: true, invocationId: true, logLevel: true, message: true, metadata: true, taskIdentifier: true } }).execute(); // Create const created = await db.platformFunctionExecutionLog.create({ data: { actorId: '', invocationId: '', logLevel: '', message: '', metadata: '', taskIdentifier: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionExecutionLog.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionExecutionLog.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionInvocationAttempt` CRUD operations for PlatformFunctionInvocationAttempt records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `attempt` | Int | Yes | | `createdAt` | Datetime | No | | `durationMs` | Int | Yes | | `error` | String | Yes | | `errorDetail` | JSON | Yes | | `id` | UUID | No | | `invocationCreatedAt` | Datetime | Yes | | `invocationId` | UUID | Yes | | `startedAt` | Datetime | Yes | | `success` | Boolean | Yes | | `taskIdentifier` | String | Yes | **Operations:** ```typescript // List all platformFunctionInvocationAttempt records const items = await db.platformFunctionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); // Get one by id const item = await db.platformFunctionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); // Create const created = await db.platformFunctionInvocationAttempt.create({ data: { actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionInvocationAttempt.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionInvocation` CRUD operations for PlatformFunctionInvocation records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `apiBindingId` | UUID | Yes | | `channel` | String | Yes | | `completedAt` | Datetime | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `definitionScope` | String | Yes | | `durationMs` | Int | Yes | | `entityId` | UUID | Yes | | `entityType` | String | Yes | | `error` | String | Yes | | `functionDefinitionId` | UUID | Yes | | `graphExecutionId` | UUID | Yes | | `id` | UUID | No | | `jobId` | BigInt | Yes | | `jobKey` | String | Yes | | `organizationId` | UUID | Yes | | `parentInvocationId` | UUID | Yes | | `payload` | JSON | Yes | | `principalId` | UUID | Yes | | `provenance` | JSON | Yes | | `queueName` | String | Yes | | `result` | JSON | Yes | | `startedAt` | Datetime | Yes | | `status` | String | Yes | | `taskIdentifier` | String | Yes | **Operations:** ```typescript // List all platformFunctionInvocation records const items = await db.platformFunctionInvocation.findMany({ select: { actorId: true, apiBindingId: true, channel: true, completedAt: true, createdAt: true, createdByPrincipal: true, databaseId: true, definitionScope: true, durationMs: true, entityId: true, entityType: true, error: true, functionDefinitionId: true, graphExecutionId: true, id: true, jobId: true, jobKey: true, organizationId: true, parentInvocationId: true, payload: true, principalId: true, provenance: true, queueName: true, result: true, startedAt: true, status: true, taskIdentifier: true } }).execute(); // Get one by id const item = await db.platformFunctionInvocation.findOne({ id: '', select: { actorId: true, apiBindingId: true, channel: true, completedAt: true, createdAt: true, createdByPrincipal: true, databaseId: true, definitionScope: true, durationMs: true, entityId: true, entityType: true, error: true, functionDefinitionId: true, graphExecutionId: true, id: true, jobId: true, jobKey: true, organizationId: true, parentInvocationId: true, payload: true, principalId: true, provenance: true, queueName: true, result: true, startedAt: true, status: true, taskIdentifier: true } }).execute(); // Create const created = await db.platformFunctionInvocation.create({ data: { actorId: '', apiBindingId: '', channel: '', completedAt: '', createdByPrincipal: '', databaseId: '', definitionScope: '', durationMs: '', entityId: '', entityType: '', error: '', functionDefinitionId: '', graphExecutionId: '', jobId: '', jobKey: '', organizationId: '', parentInvocationId: '', payload: '', principalId: '', provenance: '', queueName: '', result: '', startedAt: '', status: '', taskIdentifier: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionInvocation.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionInvocation.delete({ where: { id: '' } }).execute(); ``` ### `db.platformFunctionSchedule` CRUD operations for PlatformFunctionSchedule records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `description` | String | Yes | | `functionDefinitionId` | UUID | Yes | | `id` | UUID | No | | `isActive` | Boolean | Yes | | `name` | String | Yes | | `payload` | JSON | Yes | | `scheduleInfo` | JSON | Yes | | `suspendedAt` | Datetime | Yes | | `suspendedReason` | String | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformFunctionSchedule records const items = await db.platformFunctionSchedule.findMany({ select: { actorId: true, createdAt: true, description: true, functionDefinitionId: true, id: true, isActive: true, name: true, payload: true, scheduleInfo: true, suspendedAt: true, suspendedReason: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformFunctionSchedule.findOne({ id: '', select: { actorId: true, createdAt: true, description: true, functionDefinitionId: true, id: true, isActive: true, name: true, payload: true, scheduleInfo: true, suspendedAt: true, suspendedReason: true, updatedAt: true } }).execute(); // Create const created = await db.platformFunctionSchedule.create({ data: { actorId: '', description: '', functionDefinitionId: '', isActive: '', name: '', payload: '', scheduleInfo: '', suspendedAt: '', suspendedReason: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionSchedule.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformFunctionSchedule.delete({ where: { id: '' } }).execute(); ``` ### `db.platformImage` CRUD operations for PlatformImage records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `description` | String | Yes | | `digest` | String | Yes | | `expiresAt` | Datetime | Yes | | `id` | UUID | No | | `isPublished` | Boolean | Yes | | `labels` | JSON | Yes | | `metadata` | JSON | Yes | | `name` | String | Yes | | `ownerId` | UUID | Yes | | `platformOnly` | Boolean | Yes | | `registryHost` | String | Yes | | `repository` | String | Yes | | `runtime` | String | Yes | | `tag` | String | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformImage records const items = await db.platformImage.findMany({ select: { createdAt: true, createdByPrincipal: true, description: true, digest: true, expiresAt: true, id: true, isPublished: true, labels: true, metadata: true, name: true, ownerId: true, platformOnly: true, registryHost: true, repository: true, runtime: true, tag: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformImage.findOne({ id: '', select: { createdAt: true, createdByPrincipal: true, description: true, digest: true, expiresAt: true, id: true, isPublished: true, labels: true, metadata: true, name: true, ownerId: true, platformOnly: true, registryHost: true, repository: true, runtime: true, tag: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformImage.create({ data: { createdByPrincipal: '', description: '', digest: '', expiresAt: '', isPublished: '', labels: '', metadata: '', name: '', ownerId: '', platformOnly: '', registryHost: '', repository: '', runtime: '', tag: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformImage.update({ where: { id: '' }, data: { createdByPrincipal: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformImage.delete({ where: { id: '' } }).execute(); ``` ### `db.platformImageGrant` CRUD operations for PlatformImageGrant records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actions` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `expiresAt` | Datetime | Yes | | `grantedBy` | UUID | Yes | | `granteeKey` | UUID | Yes | | `granteeScope` | String | Yes | | `id` | UUID | No | | `imageId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformImageGrant records const items = await db.platformImageGrant.findMany({ select: { actions: true, createdAt: true, createdByPrincipal: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, imageId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformImageGrant.findOne({ id: '', select: { actions: true, createdAt: true, createdByPrincipal: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, imageId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformImageGrant.create({ data: { actions: '', createdByPrincipal: '', expiresAt: '', grantedBy: '', granteeKey: '', granteeScope: '', imageId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformImageGrant.update({ where: { id: '' }, data: { actions: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformImageGrant.delete({ where: { id: '' } }).execute(); ``` ### `db.platformInfraCommit` CRUD operations for PlatformInfraCommit records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `authorId` | UUID | Yes | | `committerId` | UUID | Yes | | `date` | Datetime | Yes | | `id` | UUID | No | | `message` | String | Yes | | `parentIds` | UUID | Yes | | `scopeId` | UUID | Yes | | `storeId` | UUID | Yes | | `treeId` | UUID | Yes | **Operations:** ```typescript // List all platformInfraCommit records const items = await db.platformInfraCommit.findMany({ select: { authorId: true, committerId: true, date: true, id: true, message: true, parentIds: true, scopeId: true, storeId: true, treeId: true } }).execute(); // Get one by id const item = await db.platformInfraCommit.findOne({ id: '', select: { authorId: true, committerId: true, date: true, id: true, message: true, parentIds: true, scopeId: true, storeId: true, treeId: true } }).execute(); // Create const created = await db.platformInfraCommit.create({ data: { authorId: '', committerId: '', date: '', message: '', parentIds: '', scopeId: '', storeId: '', treeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformInfraCommit.update({ where: { id: '' }, data: { authorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformInfraCommit.delete({ where: { id: '' } }).execute(); ``` ### `db.platformInfraGetAllTreeNodesRecord` CRUD operations for PlatformInfraGetAllTreeNodesRecord records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `data` | JSON | Yes | | `path` | String | Yes | **Operations:** ```typescript // List all platformInfraGetAllTreeNodesRecord records const items = await db.platformInfraGetAllTreeNodesRecord.findMany({ select: { data: true, path: true } }).execute(); // Get one by id const item = await db.platformInfraGetAllTreeNodesRecord.findOne({ id: '', select: { data: true, path: true } }).execute(); // Update const updated = await db.platformInfraGetAllTreeNodesRecord.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformInfraGetAllTreeNodesRecord.delete({ where: { id: '' } }).execute(); ``` ### `db.platformInfraObject` CRUD operations for PlatformInfraObject records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `data` | JSON | Yes | | `id` | UUID | No | | `kids` | UUID | Yes | | `ktree` | String | Yes | | `scopeId` | UUID | Yes | **Operations:** ```typescript // List all platformInfraObject records const items = await db.platformInfraObject.findMany({ select: { createdAt: true, data: true, id: true, kids: true, ktree: true, scopeId: true } }).execute(); // Get one by id const item = await db.platformInfraObject.findOne({ id: '', select: { createdAt: true, data: true, id: true, kids: true, ktree: true, scopeId: true } }).execute(); // Create const created = await db.platformInfraObject.create({ data: { data: '', kids: '', ktree: '', scopeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformInfraObject.update({ where: { id: '' }, data: { data: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformInfraObject.delete({ where: { id: '' } }).execute(); ``` ### `db.platformInfraRef` CRUD operations for PlatformInfraRef records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `commitId` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `scopeId` | UUID | Yes | | `storeId` | UUID | Yes | **Operations:** ```typescript // List all platformInfraRef records const items = await db.platformInfraRef.findMany({ select: { commitId: true, id: true, name: true, scopeId: true, storeId: true } }).execute(); // Get one by id const item = await db.platformInfraRef.findOne({ id: '', select: { commitId: true, id: true, name: true, scopeId: true, storeId: true } }).execute(); // Create const created = await db.platformInfraRef.create({ data: { commitId: '', name: '', scopeId: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformInfraRef.update({ where: { id: '' }, data: { commitId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformInfraRef.delete({ where: { id: '' } }).execute(); ``` ### `db.platformInfraStore` CRUD operations for PlatformInfraStore records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `hash` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `scopeId` | UUID | Yes | **Operations:** ```typescript // List all platformInfraStore records const items = await db.platformInfraStore.findMany({ select: { createdAt: true, hash: true, id: true, name: true, scopeId: true } }).execute(); // Get one by id const item = await db.platformInfraStore.findOne({ id: '', select: { createdAt: true, hash: true, id: true, name: true, scopeId: true } }).execute(); // Create const created = await db.platformInfraStore.create({ data: { hash: '', name: '', scopeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformInfraStore.update({ where: { id: '' }, data: { hash: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformInfraStore.delete({ where: { id: '' } }).execute(); ``` ### `db.platformK8sResourceKind` CRUD operations for PlatformK8sResourceKind records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `active` | Boolean | Yes | | `commitId` | UUID | Yes | | `createdAt` | Datetime | No | | `definition` | JSON | Yes | | `description` | String | Yes | | `id` | UUID | No | | `label` | String | Yes | | `slug` | String | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformK8sResourceKind records const items = await db.platformK8sResourceKind.findMany({ select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, label: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformK8sResourceKind.findOne({ id: '', select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, label: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Create const created = await db.platformK8sResourceKind.create({ data: { active: '', commitId: '', definition: '', description: '', label: '', slug: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformK8sResourceKind.update({ where: { id: '' }, data: { active: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformK8sResourceKind.delete({ where: { id: '' } }).execute(); ``` ### `db.platformK8sSpecRule` CRUD operations for PlatformK8sSpecRule records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `active` | Boolean | Yes | | `commitId` | UUID | Yes | | `createdAt` | Datetime | No | | `definition` | JSON | Yes | | `description` | String | Yes | | `id` | UUID | No | | `label` | String | Yes | | `slug` | String | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformK8sSpecRule records const items = await db.platformK8sSpecRule.findMany({ select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, label: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformK8sSpecRule.findOne({ id: '', select: { active: true, commitId: true, createdAt: true, definition: true, description: true, id: true, label: true, slug: true, storeId: true, updatedAt: true } }).execute(); // Create const created = await db.platformK8sSpecRule.create({ data: { active: '', commitId: '', definition: '', description: '', label: '', slug: '', storeId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformK8sSpecRule.update({ where: { id: '' }, data: { active: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformK8sSpecRule.delete({ where: { id: '' } }).execute(); ``` ### `db.platformNamespace` CRUD operations for PlatformNamespace records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `clusterId` | UUID | Yes | | `createdAt` | Datetime | No | | `description` | String | Yes | | `id` | UUID | No | | `isActive` | Boolean | Yes | | `isManaged` | Boolean | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `name` | String | Yes | | `namespaceName` | String | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformNamespace records const items = await db.platformNamespace.findMany({ select: { annotations: true, clusterId: true, createdAt: true, description: true, id: true, isActive: true, isManaged: true, labels: true, lastError: true, name: true, namespaceName: true, status: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformNamespace.findOne({ id: '', select: { annotations: true, clusterId: true, createdAt: true, description: true, id: true, isActive: true, isManaged: true, labels: true, lastError: true, name: true, namespaceName: true, status: true, updatedAt: true } }).execute(); // Create const created = await db.platformNamespace.create({ data: { annotations: '', clusterId: '', description: '', isActive: '', isManaged: '', labels: '', lastError: '', name: '', namespaceName: '', status: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformNamespace.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformNamespace.delete({ where: { id: '' } }).execute(); ``` ### `db.platformNamespaceEvent` CRUD operations for PlatformNamespaceEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `eventType` | String | Yes | | `id` | UUID | No | | `message` | String | Yes | | `metadata` | JSON | Yes | | `namespaceId` | UUID | Yes | **Operations:** ```typescript // List all platformNamespaceEvent records const items = await db.platformNamespaceEvent.findMany({ select: { actorId: true, createdAt: true, eventType: true, id: true, message: true, metadata: true, namespaceId: true } }).execute(); // Get one by id const item = await db.platformNamespaceEvent.findOne({ id: '', select: { actorId: true, createdAt: true, eventType: true, id: true, message: true, metadata: true, namespaceId: true } }).execute(); // Create const created = await db.platformNamespaceEvent.create({ data: { actorId: '', eventType: '', message: '', metadata: '', namespaceId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformNamespaceEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformNamespaceEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.platformProposalComment` CRUD operations for PlatformProposalComment records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `attachments` | ConstructiveInternalTypeUpload | Yes | | `attachmentsUrl` | String | No | | `attachmentsVersions` | FileVersion | No | | `body` | String | Yes | | `bodyTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `embedding` | Vector | Yes | | `embeddingModel` | String | No | | `embeddingModelTrgmSimilarity` | Float | No | | `embeddingUpdatedAt` | Datetime | No | | `embeddingVectorDistance` | Float | No | | `id` | UUID | No | | `line` | Int | Yes | | `outdatedAt` | Datetime | Yes | | `path` | String | Yes | | `pathTrgmSimilarity` | Float | No | | `proposalId` | UUID | Yes | | `resolvedAt` | Datetime | Yes | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformProposalComment records const items = await db.platformProposalComment.findMany({ select: { actorId: true, attachments: true, body: true, bodyTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, line: true, outdatedAt: true, path: true, pathTrgmSimilarity: true, proposalId: true, resolvedAt: true, search: true, searchScore: true, searchTsvRank: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformProposalComment.findOne({ id: '', select: { actorId: true, attachments: true, body: true, bodyTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, line: true, outdatedAt: true, path: true, pathTrgmSimilarity: true, proposalId: true, resolvedAt: true, search: true, searchScore: true, searchTsvRank: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformProposalComment.create({ data: { actorId: '', attachments: '', body: '', createdBy: '', createdByPrincipal: '', embedding: '', line: '', outdatedAt: '', path: '', proposalId: '', resolvedAt: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformProposalComment.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformProposalComment.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.platformProposal` CRUD operations for PlatformProposal records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `body` | String | Yes | | `bodyTrgmSimilarity` | Float | No | | `closedReason` | String | Yes | | `closedReasonTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `decidedAt` | Datetime | Yes | | `dueAt` | Datetime | Yes | | `embedding` | Vector | Yes | | `embeddingModel` | String | No | | `embeddingModelTrgmSimilarity` | Float | No | | `embeddingUpdatedAt` | Datetime | No | | `embeddingVectorDistance` | Float | No | | `id` | UUID | No | | `kind` | String | Yes | | `kindTrgmSimilarity` | Float | No | | `labels` | String | Yes | | `mergeCommit` | String | Yes | | `mergeCommitTrgmSimilarity` | Float | No | | `mergeMethod` | String | Yes | | `mergeMethodTrgmSimilarity` | Float | No | | `mergeRequestedAt` | Datetime | Yes | | `mergedAt` | Datetime | Yes | | `metadata` | JSON | Yes | | `parentId` | UUID | Yes | | `priority` | BigFloat | Yes | | `repositoryId` | UUID | Yes | | `resolution` | String | Yes | | `resolutionTrgmSimilarity` | Float | No | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `sourceRef` | String | Yes | | `sourceRefTrgmSimilarity` | Float | No | | `status` | String | Yes | | `statusTrgmSimilarity` | Float | No | | `targetRef` | String | Yes | | `targetRefTrgmSimilarity` | Float | No | | `title` | String | Yes | | `titleTrgmSimilarity` | Float | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformProposal records const items = await db.platformProposal.findMany({ select: { actorId: true, body: true, bodyTrgmSimilarity: true, closedReason: true, closedReasonTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, decidedAt: true, dueAt: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, kind: true, kindTrgmSimilarity: true, labels: true, mergeCommit: true, mergeCommitTrgmSimilarity: true, mergeMethod: true, mergeMethodTrgmSimilarity: true, mergeRequestedAt: true, mergedAt: true, metadata: true, parentId: true, priority: true, repositoryId: true, resolution: true, resolutionTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, sourceRef: true, sourceRefTrgmSimilarity: true, status: true, statusTrgmSimilarity: true, targetRef: true, targetRefTrgmSimilarity: true, title: true, titleTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformProposal.findOne({ id: '', select: { actorId: true, body: true, bodyTrgmSimilarity: true, closedReason: true, closedReasonTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, decidedAt: true, dueAt: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, kind: true, kindTrgmSimilarity: true, labels: true, mergeCommit: true, mergeCommitTrgmSimilarity: true, mergeMethod: true, mergeMethodTrgmSimilarity: true, mergeRequestedAt: true, mergedAt: true, metadata: true, parentId: true, priority: true, repositoryId: true, resolution: true, resolutionTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, sourceRef: true, sourceRefTrgmSimilarity: true, status: true, statusTrgmSimilarity: true, targetRef: true, targetRefTrgmSimilarity: true, title: true, titleTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformProposal.create({ data: { actorId: '', body: '', closedReason: '', createdBy: '', createdByPrincipal: '', decidedAt: '', dueAt: '', embedding: '', kind: '', labels: '', mergeCommit: '', mergeMethod: '', mergeRequestedAt: '', mergedAt: '', metadata: '', parentId: '', priority: '', repositoryId: '', resolution: '', sourceRef: '', status: '', targetRef: '', title: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformProposal.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformProposal.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.platformProposalFileView` CRUD operations for PlatformProposalFileView records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `blobSha` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `id` | UUID | No | | `path` | String | Yes | | `proposalId` | UUID | Yes | | `reviewerId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `viewedAt` | Datetime | Yes | **Operations:** ```typescript // List all platformProposalFileView records const items = await db.platformProposalFileView.findMany({ select: { blobSha: true, createdAt: true, createdByPrincipal: true, id: true, path: true, proposalId: true, reviewerId: true, updatedAt: true, updatedByPrincipal: true, viewedAt: true } }).execute(); // Get one by id const item = await db.platformProposalFileView.findOne({ id: '', select: { blobSha: true, createdAt: true, createdByPrincipal: true, id: true, path: true, proposalId: true, reviewerId: true, updatedAt: true, updatedByPrincipal: true, viewedAt: true } }).execute(); // Create const created = await db.platformProposalFileView.create({ data: { blobSha: '', createdByPrincipal: '', path: '', proposalId: '', reviewerId: '', updatedByPrincipal: '', viewedAt: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformProposalFileView.update({ where: { id: '' }, data: { blobSha: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformProposalFileView.delete({ where: { id: '' } }).execute(); ``` ### `db.platformProposalReaction` CRUD operations for PlatformProposalReaction records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `commentId` | UUID | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `emoji` | String | Yes | | `id` | UUID | No | | `proposalId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformProposalReaction records const items = await db.platformProposalReaction.findMany({ select: { actorId: true, commentId: true, createdAt: true, createdByPrincipal: true, emoji: true, id: true, proposalId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformProposalReaction.findOne({ id: '', select: { actorId: true, commentId: true, createdAt: true, createdByPrincipal: true, emoji: true, id: true, proposalId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformProposalReaction.create({ data: { actorId: '', commentId: '', createdByPrincipal: '', emoji: '', proposalId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformProposalReaction.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformProposalReaction.delete({ where: { id: '' } }).execute(); ``` ### `db.platformProposalReview` CRUD operations for PlatformProposalReview records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `body` | String | Yes | | `bodyTrgmSimilarity` | Float | No | | `commitSha` | String | Yes | | `commitShaTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `id` | UUID | No | | `proposalId` | UUID | Yes | | `reviewerId` | UUID | Yes | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `submittedAt` | Datetime | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `verdict` | String | Yes | | `verdictTrgmSimilarity` | Float | No | **Operations:** ```typescript // List all platformProposalReview records const items = await db.platformProposalReview.findMany({ select: { body: true, bodyTrgmSimilarity: true, commitSha: true, commitShaTrgmSimilarity: true, createdAt: true, createdByPrincipal: true, id: true, proposalId: true, reviewerId: true, search: true, searchScore: true, searchTsvRank: true, submittedAt: true, updatedAt: true, updatedByPrincipal: true, verdict: true, verdictTrgmSimilarity: true } }).execute(); // Get one by id const item = await db.platformProposalReview.findOne({ id: '', select: { body: true, bodyTrgmSimilarity: true, commitSha: true, commitShaTrgmSimilarity: true, createdAt: true, createdByPrincipal: true, id: true, proposalId: true, reviewerId: true, search: true, searchScore: true, searchTsvRank: true, submittedAt: true, updatedAt: true, updatedByPrincipal: true, verdict: true, verdictTrgmSimilarity: true } }).execute(); // Create const created = await db.platformProposalReview.create({ data: { body: '', commitSha: '', createdByPrincipal: '', proposalId: '', reviewerId: '', submittedAt: '', updatedByPrincipal: '', verdict: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformProposalReview.update({ where: { id: '' }, data: { body: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformProposalReview.delete({ where: { id: '' } }).execute(); ``` > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.platformProposalsChunk` CRUD operations for PlatformProposalsChunk records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `body` | String | Yes | | `chunkIndex` | Int | Yes | | `createdAt` | Datetime | No | | `embedding` | Vector | Yes | | `embeddingVectorDistance` | Float | No | | `id` | UUID | No | | `metadata` | JSON | Yes | | `platformProposalsId` | UUID | Yes | | `searchScore` | Float | No | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformProposalsChunk records const items = await db.platformProposalsChunk.findMany({ select: { actorId: true, body: true, chunkIndex: true, createdAt: true, embedding: true, embeddingVectorDistance: true, id: true, metadata: true, platformProposalsId: true, searchScore: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformProposalsChunk.findOne({ id: '', select: { actorId: true, body: true, chunkIndex: true, createdAt: true, embedding: true, embeddingVectorDistance: true, id: true, metadata: true, platformProposalsId: true, searchScore: true, updatedAt: true } }).execute(); // Create const created = await db.platformProposalsChunk.create({ data: { actorId: '', body: '', chunkIndex: '', embedding: '', metadata: '', platformProposalsId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformProposalsChunk.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformProposalsChunk.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. ### `db.platformRegistryBinding` CRUD operations for PlatformRegistryBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `id` | UUID | No | | `metadata` | JSON | Yes | | `namespaceId` | UUID | Yes | | `observedCredentialVersion` | String | Yes | | `pullSecretName` | String | Yes | | `realm` | String | Yes | | `registryHost` | String | Yes | | `registryId` | UUID | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformRegistryBinding records const items = await db.platformRegistryBinding.findMany({ select: { createdAt: true, createdBy: true, createdByPrincipal: true, id: true, metadata: true, namespaceId: true, observedCredentialVersion: true, pullSecretName: true, realm: true, registryHost: true, registryId: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformRegistryBinding.findOne({ id: '', select: { createdAt: true, createdBy: true, createdByPrincipal: true, id: true, metadata: true, namespaceId: true, observedCredentialVersion: true, pullSecretName: true, realm: true, registryHost: true, registryId: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformRegistryBinding.create({ data: { createdBy: '', createdByPrincipal: '', metadata: '', namespaceId: '', observedCredentialVersion: '', pullSecretName: '', realm: '', registryHost: '', registryId: '', status: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformRegistryBinding.update({ where: { id: '' }, data: { createdBy: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformRegistryBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.platformRegistry` CRUD operations for PlatformRegistry records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `authMode` | String | Yes | | `basePath` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `credentialSecretName` | String | Yes | | `host` | String | Yes | | `id` | UUID | No | | `installationId` | UUID | Yes | | `isPublished` | Boolean | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `metadata` | JSON | Yes | | `name` | String | Yes | | `platformOnly` | Boolean | Yes | | `role` | String | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformRegistry records const items = await db.platformRegistry.findMany({ select: { authMode: true, basePath: true, createdAt: true, createdByPrincipal: true, credentialSecretName: true, host: true, id: true, installationId: true, isPublished: true, kind: true, labels: true, lastError: true, metadata: true, name: true, platformOnly: true, role: true, status: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformRegistry.findOne({ id: '', select: { authMode: true, basePath: true, createdAt: true, createdByPrincipal: true, credentialSecretName: true, host: true, id: true, installationId: true, isPublished: true, kind: true, labels: true, lastError: true, metadata: true, name: true, platformOnly: true, role: true, status: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformRegistry.create({ data: { authMode: '', basePath: '', createdByPrincipal: '', credentialSecretName: '', host: '', installationId: '', isPublished: '', kind: '', labels: '', lastError: '', metadata: '', name: '', platformOnly: '', role: '', status: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformRegistry.update({ where: { id: '' }, data: { authMode: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformRegistry.delete({ where: { id: '' } }).execute(); ``` ### `db.platformRegistryGrant` CRUD operations for PlatformRegistryGrant records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actions` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `expiresAt` | Datetime | Yes | | `grantedBy` | UUID | Yes | | `granteeKey` | UUID | Yes | | `granteeScope` | String | Yes | | `id` | UUID | No | | `registryId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformRegistryGrant records const items = await db.platformRegistryGrant.findMany({ select: { actions: true, createdAt: true, createdByPrincipal: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, registryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformRegistryGrant.findOne({ id: '', select: { actions: true, createdAt: true, createdByPrincipal: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, registryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformRegistryGrant.create({ data: { actions: '', createdByPrincipal: '', expiresAt: '', grantedBy: '', granteeKey: '', granteeScope: '', registryId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformRegistryGrant.update({ where: { id: '' }, data: { actions: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformRegistryGrant.delete({ where: { id: '' } }).execute(); ``` ### `db.platformRepository` CRUD operations for PlatformRepository records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cloneUrl` | String | Yes | | `cloneUrlTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `defaultBranch` | String | Yes | | `defaultBranchTrgmSimilarity` | Float | No | | `description` | String | Yes | | `descriptionTrgmSimilarity` | Float | No | | `embedding` | Vector | Yes | | `embeddingModel` | String | No | | `embeddingModelTrgmSimilarity` | Float | No | | `embeddingUpdatedAt` | Datetime | No | | `embeddingVectorDistance` | Float | No | | `externalId` | String | Yes | | `externalIdTrgmSimilarity` | Float | No | | `id` | UUID | No | | `isArchived` | Boolean | Yes | | `metadata` | JSON | Yes | | `name` | String | Yes | | `nameTrgmSimilarity` | Float | No | | `ownerId` | UUID | Yes | | `provider` | String | Yes | | `providerTrgmSimilarity` | Float | No | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `slug` | String | Yes | | `slugTrgmSimilarity` | Float | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | | `visibility` | String | Yes | | `visibilityTrgmSimilarity` | Float | No | **Operations:** ```typescript // List all platformRepository records const items = await db.platformRepository.findMany({ select: { cloneUrl: true, cloneUrlTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, defaultBranch: true, defaultBranchTrgmSimilarity: true, description: true, descriptionTrgmSimilarity: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, externalId: true, externalIdTrgmSimilarity: true, id: true, isArchived: true, metadata: true, name: true, nameTrgmSimilarity: true, ownerId: true, provider: true, providerTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, slug: true, slugTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true, visibility: true, visibilityTrgmSimilarity: true } }).execute(); // Get one by id const item = await db.platformRepository.findOne({ id: '', select: { cloneUrl: true, cloneUrlTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, defaultBranch: true, defaultBranchTrgmSimilarity: true, description: true, descriptionTrgmSimilarity: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, externalId: true, externalIdTrgmSimilarity: true, id: true, isArchived: true, metadata: true, name: true, nameTrgmSimilarity: true, ownerId: true, provider: true, providerTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, slug: true, slugTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true, visibility: true, visibilityTrgmSimilarity: true } }).execute(); // Create const created = await db.platformRepository.create({ data: { cloneUrl: '', createdBy: '', createdByPrincipal: '', defaultBranch: '', description: '', embedding: '', externalId: '', isArchived: '', metadata: '', name: '', ownerId: '', provider: '', slug: '', updatedBy: '', updatedByPrincipal: '', visibility: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformRepository.update({ where: { id: '' }, data: { cloneUrl: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformRepository.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.platformRepositoryEvent` CRUD operations for PlatformRepositoryEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `commitSha` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `deliveryId` | String | Yes | | `eventType` | String | Yes | | `id` | UUID | No | | `metadata` | JSON | Yes | | `payload` | JSON | Yes | | `ref` | String | Yes | | `repositoryId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformRepositoryEvent records const items = await db.platformRepositoryEvent.findMany({ select: { actorId: true, commitSha: true, createdAt: true, createdByPrincipal: true, deliveryId: true, eventType: true, id: true, metadata: true, payload: true, ref: true, repositoryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformRepositoryEvent.findOne({ id: '', select: { actorId: true, commitSha: true, createdAt: true, createdByPrincipal: true, deliveryId: true, eventType: true, id: true, metadata: true, payload: true, ref: true, repositoryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformRepositoryEvent.create({ data: { actorId: '', commitSha: '', createdByPrincipal: '', deliveryId: '', eventType: '', metadata: '', payload: '', ref: '', repositoryId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformRepositoryEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformRepositoryEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.platformRepositoryRequiredCheck` CRUD operations for PlatformRepositoryRequiredCheck records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `id` | UUID | No | | `repositoryId` | UUID | Yes | | `updatedAt` | Datetime | No | | `workflowId` | UUID | Yes | **Operations:** ```typescript // List all platformRepositoryRequiredCheck records const items = await db.platformRepositoryRequiredCheck.findMany({ select: { createdAt: true, id: true, repositoryId: true, updatedAt: true, workflowId: true } }).execute(); // Get one by id const item = await db.platformRepositoryRequiredCheck.findOne({ id: '', select: { createdAt: true, id: true, repositoryId: true, updatedAt: true, workflowId: true } }).execute(); // Create const created = await db.platformRepositoryRequiredCheck.create({ data: { repositoryId: '', workflowId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformRepositoryRequiredCheck.update({ where: { id: '' }, data: { repositoryId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformRepositoryRequiredCheck.delete({ where: { id: '' } }).execute(); ``` ### `db.platformRepositoryWorkflow` CRUD operations for PlatformRepositoryWorkflow records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cancelInProgress` | Boolean | Yes | | `concurrencyKey` | String | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `eventType` | String | Yes | | `graphId` | UUID | Yes | | `id` | UUID | No | | `inputs` | JSON | Yes | | `isEnabled` | Boolean | Yes | | `name` | String | Yes | | `refPattern` | String | Yes | | `repositoryId` | UUID | Yes | | `requiredSecrets` | String | Yes | | `slug` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformRepositoryWorkflow records const items = await db.platformRepositoryWorkflow.findMany({ select: { cancelInProgress: true, concurrencyKey: true, createdAt: true, createdBy: true, createdByPrincipal: true, eventType: true, graphId: true, id: true, inputs: true, isEnabled: true, name: true, refPattern: true, repositoryId: true, requiredSecrets: true, slug: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformRepositoryWorkflow.findOne({ id: '', select: { cancelInProgress: true, concurrencyKey: true, createdAt: true, createdBy: true, createdByPrincipal: true, eventType: true, graphId: true, id: true, inputs: true, isEnabled: true, name: true, refPattern: true, repositoryId: true, requiredSecrets: true, slug: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformRepositoryWorkflow.create({ data: { cancelInProgress: '', concurrencyKey: '', createdBy: '', createdByPrincipal: '', eventType: '', graphId: '', inputs: '', isEnabled: '', name: '', refPattern: '', repositoryId: '', requiredSecrets: '', slug: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformRepositoryWorkflow.update({ where: { id: '' }, data: { cancelInProgress: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformRepositoryWorkflow.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResource` CRUD operations for PlatformResource records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `cpuLimitMillicores` | BigInt | No | | `cpuRequestMillicores` | BigInt | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `errorCount` | Int | Yes | | `id` | UUID | No | | `imageRef` | String | Yes | | `installationId` | UUID | Yes | | `integrations` | String | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `lastHeartbeatAt` | Datetime | Yes | | `memoryLimitBytes` | BigInt | No | | `memoryRequestBytes` | BigInt | No | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `realm` | String | Yes | | `replicas` | Int | No | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `resourceDefinitionId` | UUID | Yes | | `slug` | String | Yes | | `spec` | JSON | Yes | | `status` | String | Yes | | `statusObserved` | JSON | Yes | | `storageClass` | String | No | | `storageSizeBytes` | BigInt | No | | `storageTotalBytes` | BigInt | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformResource records const items = await db.platformResource.findMany({ select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformResource.findOne({ id: '', select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformResource.create({ data: { annotations: '', createdBy: '', createdByPrincipal: '', errorCount: '', imageRef: '', installationId: '', integrations: '', kind: '', labels: '', lastError: '', lastHeartbeatAt: '', name: '', namespaceId: '', realm: '', requiredConfigs: '', requiredSecrets: '', resourceDefinitionId: '', slug: '', spec: '', status: '', statusObserved: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformResource.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResource.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceDeclaredCapacity` CRUD operations for PlatformResourceDeclaredCapacity records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cpuLimitMillicores` | BigInt | Yes | | `cpuRequestMillicores` | BigInt | Yes | | `installationId` | UUID | Yes | | `isTransient` | Boolean | Yes | | `kind` | String | Yes | | `memoryLimitBytes` | BigInt | Yes | | `memoryRequestBytes` | BigInt | Yes | | `namespaceId` | UUID | Yes | | `podCountMax` | Int | Yes | | `podCountMin` | Int | Yes | | `source` | String | Yes | | `sourceId` | UUID | Yes | | `storageSizeBytes` | BigInt | Yes | | `storageTotalBytes` | BigInt | Yes | **Operations:** ```typescript // List all platformResourceDeclaredCapacity records const items = await db.platformResourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true, storageTotalBytes: true } }).execute(); // Get one by id const item = await db.platformResourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true, storageTotalBytes: true } }).execute(); // Update const updated = await db.platformResourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceDefinition` CRUD operations for PlatformResourceDefinition records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `defaultSpec` | JSON | Yes | | `description` | String | Yes | | `id` | UUID | No | | `integrations` | String | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `paramsSchema` | JSON | Yes | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `slug` | String | Yes | | `stepUpMinAge` | Interval | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformResourceDefinition records const items = await db.platformResourceDefinition.findMany({ select: { annotations: true, createdAt: true, createdBy: true, createdByPrincipal: true, defaultSpec: true, description: true, id: true, integrations: true, kind: true, labels: true, name: true, namespaceId: true, paramsSchema: true, slug: true, stepUpMinAge: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformResourceDefinition.findOne({ id: '', select: { annotations: true, createdAt: true, createdBy: true, createdByPrincipal: true, defaultSpec: true, description: true, id: true, integrations: true, kind: true, labels: true, name: true, namespaceId: true, paramsSchema: true, slug: true, stepUpMinAge: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformResourceDefinition.create({ data: { annotations: '', createdBy: '', createdByPrincipal: '', defaultSpec: '', description: '', integrations: '', kind: '', labels: '', name: '', namespaceId: '', paramsSchema: '', requiredConfigs: '', requiredSecrets: '', slug: '', stepUpMinAge: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformResourceDefinition.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceDefinition.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceEvent` CRUD operations for PlatformResourceEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `eventType` | String | Yes | | `id` | UUID | No | | `message` | String | Yes | | `metadata` | JSON | Yes | | `resourceId` | UUID | Yes | **Operations:** ```typescript // List all platformResourceEvent records const items = await db.platformResourceEvent.findMany({ select: { actorId: true, createdAt: true, eventType: true, id: true, message: true, metadata: true, resourceId: true } }).execute(); // Get one by id const item = await db.platformResourceEvent.findOne({ id: '', select: { actorId: true, createdAt: true, eventType: true, id: true, message: true, metadata: true, resourceId: true } }).execute(); // Create const created = await db.platformResourceEvent.create({ data: { actorId: '', eventType: '', message: '', metadata: '', resourceId: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformResourceEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceInstallation` CRUD operations for PlatformResourceInstallation records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `commitId` | UUID | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `params` | JSON | Yes | | `revision` | Int | Yes | | `slug` | String | Yes | | `status` | String | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformResourceInstallation records const items = await db.platformResourceInstallation.findMany({ select: { commitId: true, createdAt: true, createdBy: true, createdByPrincipal: true, id: true, name: true, namespaceId: true, params: true, revision: true, slug: true, status: true, storeId: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformResourceInstallation.findOne({ id: '', select: { commitId: true, createdAt: true, createdBy: true, createdByPrincipal: true, id: true, name: true, namespaceId: true, params: true, revision: true, slug: true, status: true, storeId: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformResourceInstallation.create({ data: { commitId: '', createdBy: '', createdByPrincipal: '', name: '', namespaceId: '', params: '', revision: '', slug: '', status: '', storeId: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformResourceInstallation.update({ where: { id: '' }, data: { commitId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceInstallation.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceObservedStorage` CRUD operations for PlatformResourceObservedStorage records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `capacity` | String | Yes | | `capacityBytes` | BigInt | Yes | | `claimName` | String | Yes | | `declaredStorageClass` | String | Yes | | `declaredStorageSizeBytes` | BigInt | Yes | | `declaredStorageTotalBytes` | BigInt | Yes | | `installationId` | UUID | Yes | | `isBound` | Boolean | Yes | | `kind` | String | Yes | | `namespaceId` | UUID | Yes | | `phase` | String | Yes | | `requested` | String | Yes | | `requestedBytes` | BigInt | Yes | | `resourceId` | UUID | Yes | | `resourceStatus` | String | Yes | | `slug` | String | Yes | | `storageClass` | String | Yes | | `storageName` | String | Yes | **Operations:** ```typescript // List all platformResourceObservedStorage records const items = await db.platformResourceObservedStorage.findMany({ select: { capacity: true, capacityBytes: true, claimName: true, declaredStorageClass: true, declaredStorageSizeBytes: true, declaredStorageTotalBytes: true, installationId: true, isBound: true, kind: true, namespaceId: true, phase: true, requested: true, requestedBytes: true, resourceId: true, resourceStatus: true, slug: true, storageClass: true, storageName: true } }).execute(); // Get one by id const item = await db.platformResourceObservedStorage.findOne({ id: '', select: { capacity: true, capacityBytes: true, claimName: true, declaredStorageClass: true, declaredStorageSizeBytes: true, declaredStorageTotalBytes: true, installationId: true, isBound: true, kind: true, namespaceId: true, phase: true, requested: true, requestedBytes: true, resourceId: true, resourceStatus: true, slug: true, storageClass: true, storageName: true } }).execute(); // Update const updated = await db.platformResourceObservedStorage.update({ where: { id: '' }, data: { capacity: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceObservedStorage.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceStatusCheck` CRUD operations for PlatformResourceStatusCheck records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `completedAt` | Datetime | Yes | | `id` | UUID | No | | `requestedAt` | Datetime | Yes | | `requestedBy` | UUID | Yes | | `resourceId` | UUID | Yes | | `result` | JSON | Yes | | `status` | String | Yes | **Operations:** ```typescript // List all platformResourceStatusCheck records const items = await db.platformResourceStatusCheck.findMany({ select: { completedAt: true, id: true, requestedAt: true, requestedBy: true, resourceId: true, result: true, status: true } }).execute(); // Get one by id const item = await db.platformResourceStatusCheck.findOne({ id: '', select: { completedAt: true, id: true, requestedAt: true, requestedBy: true, resourceId: true, result: true, status: true } }).execute(); // Create const created = await db.platformResourceStatusCheck.create({ data: { completedAt: '', requestedAt: '', requestedBy: '', resourceId: '', result: '', status: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformResourceStatusCheck.update({ where: { id: '' }, data: { completedAt: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceStatusCheck.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceUsageLog` CRUD operations for PlatformResourceUsageLog records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cpuMillicores` | BigInt | Yes | | `id` | UUID | No | | `intervalSeconds` | Int | Yes | | `memoryBytes` | BigInt | Yes | | `metrics` | JSON | Yes | | `namespaceId` | UUID | Yes | | `resourceId` | UUID | Yes | | `sampledAt` | Datetime | Yes | | `source` | String | Yes | **Operations:** ```typescript // List all platformResourceUsageLog records const items = await db.platformResourceUsageLog.findMany({ select: { cpuMillicores: true, id: true, intervalSeconds: true, memoryBytes: true, metrics: true, namespaceId: true, resourceId: true, sampledAt: true, source: true } }).execute(); // Get one by id const item = await db.platformResourceUsageLog.findOne({ id: '', select: { cpuMillicores: true, id: true, intervalSeconds: true, memoryBytes: true, metrics: true, namespaceId: true, resourceId: true, sampledAt: true, source: true } }).execute(); // Create const created = await db.platformResourceUsageLog.create({ data: { cpuMillicores: '', intervalSeconds: '', memoryBytes: '', metrics: '', namespaceId: '', resourceId: '', sampledAt: '', source: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformResourceUsageLog.update({ where: { id: '' }, data: { cpuMillicores: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceUsageLog.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceUsageSummary` CRUD operations for PlatformResourceUsageSummary records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `date` | Date | Yes | | `gbSeconds` | BigFloat | Yes | | `id` | UUID | No | | `maxCpuMillicores` | BigInt | Yes | | `maxMemoryBytes` | BigInt | Yes | | `namespaceId` | UUID | Yes | | `resourceId` | UUID | Yes | | `runtimeSeconds` | BigInt | Yes | | `sampleCount` | Int | Yes | **Operations:** ```typescript // List all platformResourceUsageSummary records const items = await db.platformResourceUsageSummary.findMany({ select: { date: true, gbSeconds: true, id: true, maxCpuMillicores: true, maxMemoryBytes: true, namespaceId: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id const item = await db.platformResourceUsageSummary.findOne({ id: '', select: { date: true, gbSeconds: true, id: true, maxCpuMillicores: true, maxMemoryBytes: true, namespaceId: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create const created = await db.platformResourceUsageSummary.create({ data: { date: '', gbSeconds: '', maxCpuMillicores: '', maxMemoryBytes: '', namespaceId: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformResourceUsageSummary.update({ where: { id: '' }, data: { date: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceUsageSummary.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourceUtilization` CRUD operations for PlatformResourceUtilization records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `avgMemoryBytes` | BigInt | Yes | | `cpuLimitMillicores` | BigInt | Yes | | `cpuPeakUtilization` | BigFloat | Yes | | `cpuRequestHeadroomMillicores` | BigInt | Yes | | `cpuRequestMillicores` | BigInt | Yes | | `date` | Date | Yes | | `gbSeconds` | BigFloat | Yes | | `kind` | String | Yes | | `maxCpuMillicores` | BigInt | Yes | | `maxMemoryBytes` | BigInt | Yes | | `memoryLimitBytes` | BigInt | Yes | | `memoryPeakUtilization` | BigFloat | Yes | | `memoryRequestBytes` | BigInt | Yes | | `memoryRequestHeadroomBytes` | BigInt | Yes | | `namespaceId` | UUID | Yes | | `replicas` | Int | Yes | | `resourceId` | UUID | Yes | | `runtimeSeconds` | BigInt | Yes | | `sampleCount` | Int | Yes | **Operations:** ```typescript // List all platformResourceUtilization records const items = await db.platformResourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id const item = await db.platformResourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Update const updated = await db.platformResourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourcesHealth` CRUD operations for PlatformResourcesHealth records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `cpuLimitMillicores` | BigInt | Yes | | `cpuRequestMillicores` | BigInt | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `errorCount` | Int | Yes | | `id` | UUID | No | | `imageRef` | String | Yes | | `installationId` | UUID | Yes | | `integrations` | String | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `lastHeartbeatAt` | Datetime | Yes | | `memoryLimitBytes` | BigInt | Yes | | `memoryRequestBytes` | BigInt | Yes | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `realm` | String | Yes | | `replicas` | Int | Yes | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `resourceDefinitionId` | UUID | Yes | | `slug` | String | Yes | | `spec` | JSON | Yes | | `status` | String | Yes | | `statusDetail` | String | Yes | | `statusObserved` | JSON | Yes | | `storageClass` | String | Yes | | `storageSizeBytes` | BigInt | Yes | | `storageTotalBytes` | BigInt | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformResourcesHealth records const items = await db.platformResourcesHealth.findMany({ select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusDetail: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformResourcesHealth.findOne({ id: '', select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusDetail: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Update const updated = await db.platformResourcesHealth.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourcesHealth.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourcesRequirementsState` CRUD operations for PlatformResourcesRequirementsState records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `configHash` | String | Yes | | `configObjectName` | String | Yes | | `requirementsHash` | String | Yes | | `resourceId` | UUID | Yes | | `secretsHash` | String | Yes | | `secretsObjectName` | String | Yes | | `slug` | String | Yes | **Operations:** ```typescript // List all platformResourcesRequirementsState records const items = await db.platformResourcesRequirementsState.findMany({ select: { configHash: true, configObjectName: true, requirementsHash: true, resourceId: true, secretsHash: true, secretsObjectName: true, slug: true } }).execute(); // Get one by id const item = await db.platformResourcesRequirementsState.findOne({ id: '', select: { configHash: true, configObjectName: true, requirementsHash: true, resourceId: true, secretsHash: true, secretsObjectName: true, slug: true } }).execute(); // Update const updated = await db.platformResourcesRequirementsState.update({ where: { id: '' }, data: { configHash: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourcesRequirementsState.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourcesResolvedRequirement` CRUD operations for PlatformResourcesResolvedRequirement records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `atomId` | UUID | Yes | | `configObjectName` | String | Yes | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `present` | Boolean | Yes | | `realm` | String | Yes | | `required` | Boolean | Yes | | `requirementKind` | String | Yes | | `resourceId` | UUID | Yes | | `secretsObjectName` | String | Yes | | `slug` | String | Yes | **Operations:** ```typescript // List all platformResourcesResolvedRequirement records const items = await db.platformResourcesResolvedRequirement.findMany({ select: { atomId: true, configObjectName: true, name: true, namespaceId: true, present: true, realm: true, required: true, requirementKind: true, resourceId: true, secretsObjectName: true, slug: true } }).execute(); // Get one by id const item = await db.platformResourcesResolvedRequirement.findOne({ id: '', select: { atomId: true, configObjectName: true, name: true, namespaceId: true, present: true, realm: true, required: true, requirementKind: true, resourceId: true, secretsObjectName: true, slug: true } }).execute(); // Update const updated = await db.platformResourcesResolvedRequirement.update({ where: { id: '' }, data: { atomId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformResourcesResolvedRequirement.delete({ where: { id: '' } }).execute(); ``` ### `db.platformServiceBinding` CRUD operations for PlatformServiceBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `id` | UUID | No | | `installationId` | UUID | Yes | | `installationScope` | String | Yes | | `kind` | String | Yes | | `lastError` | String | Yes | | `metadata` | JSON | Yes | | `namespaceId` | UUID | Yes | | `observedHost` | String | Yes | | `realm` | String | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformServiceBinding records const items = await db.platformServiceBinding.findMany({ select: { createdAt: true, createdBy: true, createdByPrincipal: true, id: true, installationId: true, installationScope: true, kind: true, lastError: true, metadata: true, namespaceId: true, observedHost: true, realm: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformServiceBinding.findOne({ id: '', select: { createdAt: true, createdBy: true, createdByPrincipal: true, id: true, installationId: true, installationScope: true, kind: true, lastError: true, metadata: true, namespaceId: true, observedHost: true, realm: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformServiceBinding.create({ data: { createdBy: '', createdByPrincipal: '', installationId: '', installationScope: '', kind: '', lastError: '', metadata: '', namespaceId: '', observedHost: '', realm: '', status: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformServiceBinding.update({ where: { id: '' }, data: { createdBy: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformServiceBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.platformWebhookEndpoint` CRUD operations for PlatformWebhookEndpoint records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `active` | Boolean | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `functionDefinitionId` | UUID | Yes | | `host` | String | Yes | | `id` | UUID | No | | `namespaceId` | UUID | Yes | | `path` | String | Yes | | `provider` | String | Yes | | `replayWindowSeconds` | Int | Yes | | `signingSecretName` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all platformWebhookEndpoint records const items = await db.platformWebhookEndpoint.findMany({ select: { active: true, createdAt: true, createdBy: true, createdByPrincipal: true, functionDefinitionId: true, host: true, id: true, namespaceId: true, path: true, provider: true, replayWindowSeconds: true, signingSecretName: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.platformWebhookEndpoint.findOne({ id: '', select: { active: true, createdAt: true, createdBy: true, createdByPrincipal: true, functionDefinitionId: true, host: true, id: true, namespaceId: true, path: true, provider: true, replayWindowSeconds: true, signingSecretName: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.platformWebhookEndpoint.create({ data: { active: '', createdBy: '', createdByPrincipal: '', functionDefinitionId: '', host: '', namespaceId: '', path: '', provider: '', replayWindowSeconds: '', signingSecretName: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformWebhookEndpoint.update({ where: { id: '' }, data: { active: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformWebhookEndpoint.delete({ where: { id: '' } }).execute(); ``` ### `db.platformWebhookEvent` CRUD operations for PlatformWebhookEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `endpointId` | UUID | Yes | | `error` | String | Yes | | `externalEventId` | String | Yes | | `id` | UUID | No | | `invocationCreatedAt` | Datetime | Yes | | `invocationId` | UUID | Yes | | `payload` | JSON | Yes | | `provider` | String | Yes | | `providerTimestamp` | Datetime | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all platformWebhookEvent records const items = await db.platformWebhookEvent.findMany({ select: { createdAt: true, endpointId: true, error: true, externalEventId: true, id: true, invocationCreatedAt: true, invocationId: true, payload: true, provider: true, providerTimestamp: true, status: true, updatedAt: true } }).execute(); // Get one by id const item = await db.platformWebhookEvent.findOne({ id: '', select: { createdAt: true, endpointId: true, error: true, externalEventId: true, id: true, invocationCreatedAt: true, invocationId: true, payload: true, provider: true, providerTimestamp: true, status: true, updatedAt: true } }).execute(); // Create const created = await db.platformWebhookEvent.create({ data: { endpointId: '', error: '', externalEventId: '', invocationCreatedAt: '', invocationId: '', payload: '', provider: '', providerTimestamp: '', status: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformWebhookEvent.update({ where: { id: '' }, data: { endpointId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.platformWebhookEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.proposalComment` CRUD operations for ProposalComment records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `attachments` | ConstructiveInternalTypeUpload | Yes | | `attachmentsUrl` | String | No | | `attachmentsVersions` | FileVersion | No | | `body` | String | Yes | | `bodyTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `embedding` | Vector | Yes | | `embeddingModel` | String | No | | `embeddingModelTrgmSimilarity` | Float | No | | `embeddingUpdatedAt` | Datetime | No | | `embeddingVectorDistance` | Float | No | | `id` | UUID | No | | `line` | Int | Yes | | `outdatedAt` | Datetime | Yes | | `path` | String | Yes | | `pathTrgmSimilarity` | Float | No | | `proposalId` | UUID | Yes | | `resolvedAt` | Datetime | Yes | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all proposalComment records const items = await db.proposalComment.findMany({ select: { actorId: true, attachments: true, body: true, bodyTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, line: true, outdatedAt: true, path: true, pathTrgmSimilarity: true, proposalId: true, resolvedAt: true, search: true, searchScore: true, searchTsvRank: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.proposalComment.findOne({ id: '', select: { actorId: true, attachments: true, body: true, bodyTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, line: true, outdatedAt: true, path: true, pathTrgmSimilarity: true, proposalId: true, resolvedAt: true, search: true, searchScore: true, searchTsvRank: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.proposalComment.create({ data: { actorId: '', attachments: '', body: '', createdBy: '', createdByPrincipal: '', databaseId: '', embedding: '', line: '', outdatedAt: '', path: '', proposalId: '', resolvedAt: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.proposalComment.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.proposalComment.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.proposal` CRUD operations for Proposal records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `body` | String | Yes | | `bodyTrgmSimilarity` | Float | No | | `closedReason` | String | Yes | | `closedReasonTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `decidedAt` | Datetime | Yes | | `dueAt` | Datetime | Yes | | `embedding` | Vector | Yes | | `embeddingModel` | String | No | | `embeddingModelTrgmSimilarity` | Float | No | | `embeddingUpdatedAt` | Datetime | No | | `embeddingVectorDistance` | Float | No | | `id` | UUID | No | | `kind` | String | Yes | | `kindTrgmSimilarity` | Float | No | | `labels` | String | Yes | | `mergeCommit` | String | Yes | | `mergeCommitTrgmSimilarity` | Float | No | | `mergeMethod` | String | Yes | | `mergeMethodTrgmSimilarity` | Float | No | | `mergeRequestedAt` | Datetime | Yes | | `mergedAt` | Datetime | Yes | | `metadata` | JSON | Yes | | `parentId` | UUID | Yes | | `priority` | BigFloat | Yes | | `repositoryId` | UUID | Yes | | `resolution` | String | Yes | | `resolutionTrgmSimilarity` | Float | No | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `sourceRef` | String | Yes | | `sourceRefTrgmSimilarity` | Float | No | | `status` | String | Yes | | `statusTrgmSimilarity` | Float | No | | `targetRef` | String | Yes | | `targetRefTrgmSimilarity` | Float | No | | `title` | String | Yes | | `titleTrgmSimilarity` | Float | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all proposal records const items = await db.proposal.findMany({ select: { actorId: true, body: true, bodyTrgmSimilarity: true, closedReason: true, closedReasonTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, decidedAt: true, dueAt: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, kind: true, kindTrgmSimilarity: true, labels: true, mergeCommit: true, mergeCommitTrgmSimilarity: true, mergeMethod: true, mergeMethodTrgmSimilarity: true, mergeRequestedAt: true, mergedAt: true, metadata: true, parentId: true, priority: true, repositoryId: true, resolution: true, resolutionTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, sourceRef: true, sourceRefTrgmSimilarity: true, status: true, statusTrgmSimilarity: true, targetRef: true, targetRefTrgmSimilarity: true, title: true, titleTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.proposal.findOne({ id: '', select: { actorId: true, body: true, bodyTrgmSimilarity: true, closedReason: true, closedReasonTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, decidedAt: true, dueAt: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, id: true, kind: true, kindTrgmSimilarity: true, labels: true, mergeCommit: true, mergeCommitTrgmSimilarity: true, mergeMethod: true, mergeMethodTrgmSimilarity: true, mergeRequestedAt: true, mergedAt: true, metadata: true, parentId: true, priority: true, repositoryId: true, resolution: true, resolutionTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, sourceRef: true, sourceRefTrgmSimilarity: true, status: true, statusTrgmSimilarity: true, targetRef: true, targetRefTrgmSimilarity: true, title: true, titleTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.proposal.create({ data: { actorId: '', body: '', closedReason: '', createdBy: '', createdByPrincipal: '', databaseId: '', decidedAt: '', dueAt: '', embedding: '', kind: '', labels: '', mergeCommit: '', mergeMethod: '', mergeRequestedAt: '', mergedAt: '', metadata: '', parentId: '', priority: '', repositoryId: '', resolution: '', sourceRef: '', status: '', targetRef: '', title: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.proposal.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.proposal.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.proposalFileView` CRUD operations for ProposalFileView records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `blobSha` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `path` | String | Yes | | `proposalId` | UUID | Yes | | `reviewerId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `viewedAt` | Datetime | Yes | **Operations:** ```typescript // List all proposalFileView records const items = await db.proposalFileView.findMany({ select: { blobSha: true, createdAt: true, createdByPrincipal: true, databaseId: true, id: true, path: true, proposalId: true, reviewerId: true, updatedAt: true, updatedByPrincipal: true, viewedAt: true } }).execute(); // Get one by id const item = await db.proposalFileView.findOne({ id: '', select: { blobSha: true, createdAt: true, createdByPrincipal: true, databaseId: true, id: true, path: true, proposalId: true, reviewerId: true, updatedAt: true, updatedByPrincipal: true, viewedAt: true } }).execute(); // Create const created = await db.proposalFileView.create({ data: { blobSha: '', createdByPrincipal: '', databaseId: '', path: '', proposalId: '', reviewerId: '', updatedByPrincipal: '', viewedAt: '' }, select: { id: true } }).execute(); // Update const updated = await db.proposalFileView.update({ where: { id: '' }, data: { blobSha: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.proposalFileView.delete({ where: { id: '' } }).execute(); ``` ### `db.proposalReaction` CRUD operations for ProposalReaction records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `commentId` | UUID | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `emoji` | String | Yes | | `id` | UUID | No | | `proposalId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all proposalReaction records const items = await db.proposalReaction.findMany({ select: { actorId: true, commentId: true, createdAt: true, createdByPrincipal: true, databaseId: true, emoji: true, id: true, proposalId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.proposalReaction.findOne({ id: '', select: { actorId: true, commentId: true, createdAt: true, createdByPrincipal: true, databaseId: true, emoji: true, id: true, proposalId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.proposalReaction.create({ data: { actorId: '', commentId: '', createdByPrincipal: '', databaseId: '', emoji: '', proposalId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.proposalReaction.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.proposalReaction.delete({ where: { id: '' } }).execute(); ``` ### `db.proposalReview` CRUD operations for ProposalReview records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `body` | String | Yes | | `bodyTrgmSimilarity` | Float | No | | `commitSha` | String | Yes | | `commitShaTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `proposalId` | UUID | Yes | | `reviewerId` | UUID | Yes | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `submittedAt` | Datetime | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | | `verdict` | String | Yes | | `verdictTrgmSimilarity` | Float | No | **Operations:** ```typescript // List all proposalReview records const items = await db.proposalReview.findMany({ select: { body: true, bodyTrgmSimilarity: true, commitSha: true, commitShaTrgmSimilarity: true, createdAt: true, createdByPrincipal: true, databaseId: true, id: true, proposalId: true, reviewerId: true, search: true, searchScore: true, searchTsvRank: true, submittedAt: true, updatedAt: true, updatedByPrincipal: true, verdict: true, verdictTrgmSimilarity: true } }).execute(); // Get one by id const item = await db.proposalReview.findOne({ id: '', select: { body: true, bodyTrgmSimilarity: true, commitSha: true, commitShaTrgmSimilarity: true, createdAt: true, createdByPrincipal: true, databaseId: true, id: true, proposalId: true, reviewerId: true, search: true, searchScore: true, searchTsvRank: true, submittedAt: true, updatedAt: true, updatedByPrincipal: true, verdict: true, verdictTrgmSimilarity: true } }).execute(); // Create const created = await db.proposalReview.create({ data: { body: '', commitSha: '', createdByPrincipal: '', databaseId: '', proposalId: '', reviewerId: '', submittedAt: '', updatedByPrincipal: '', verdict: '' }, select: { id: true } }).execute(); // Update const updated = await db.proposalReview.update({ where: { id: '' }, data: { body: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.proposalReview.delete({ where: { id: '' } }).execute(); ``` > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.proposalsChunk` CRUD operations for ProposalsChunk records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `body` | String | Yes | | `chunkIndex` | Int | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `embedding` | Vector | Yes | | `embeddingVectorDistance` | Float | No | | `id` | UUID | No | | `metadata` | JSON | Yes | | `proposalsId` | UUID | Yes | | `searchScore` | Float | No | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all proposalsChunk records const items = await db.proposalsChunk.findMany({ select: { actorId: true, body: true, chunkIndex: true, createdAt: true, databaseId: true, embedding: true, embeddingVectorDistance: true, id: true, metadata: true, proposalsId: true, searchScore: true, updatedAt: true } }).execute(); // Get one by id const item = await db.proposalsChunk.findOne({ id: '', select: { actorId: true, body: true, chunkIndex: true, createdAt: true, databaseId: true, embedding: true, embeddingVectorDistance: true, id: true, metadata: true, proposalsId: true, searchScore: true, updatedAt: true } }).execute(); // Create const created = await db.proposalsChunk.create({ data: { actorId: '', body: '', chunkIndex: '', databaseId: '', embedding: '', metadata: '', proposalsId: '' }, select: { id: true } }).execute(); // Update const updated = await db.proposalsChunk.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.proposalsChunk.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. ### `db.registryBinding` CRUD operations for RegistryBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `metadata` | JSON | Yes | | `namespaceId` | UUID | Yes | | `observedCredentialVersion` | String | Yes | | `pullSecretName` | String | Yes | | `realm` | String | Yes | | `registryHost` | String | Yes | | `registryId` | UUID | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all registryBinding records const items = await db.registryBinding.findMany({ select: { createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, id: true, metadata: true, namespaceId: true, observedCredentialVersion: true, pullSecretName: true, realm: true, registryHost: true, registryId: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.registryBinding.findOne({ id: '', select: { createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, id: true, metadata: true, namespaceId: true, observedCredentialVersion: true, pullSecretName: true, realm: true, registryHost: true, registryId: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.registryBinding.create({ data: { createdBy: '', createdByPrincipal: '', databaseId: '', metadata: '', namespaceId: '', observedCredentialVersion: '', pullSecretName: '', realm: '', registryHost: '', registryId: '', status: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.registryBinding.update({ where: { id: '' }, data: { createdBy: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.registryBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.registry` CRUD operations for Registry records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `authMode` | String | Yes | | `basePath` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `credentialSecretName` | String | Yes | | `databaseId` | UUID | Yes | | `host` | String | Yes | | `id` | UUID | No | | `installationId` | UUID | Yes | | `isPublished` | Boolean | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `metadata` | JSON | Yes | | `name` | String | Yes | | `platformOnly` | Boolean | Yes | | `role` | String | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all registry records const items = await db.registry.findMany({ select: { authMode: true, basePath: true, createdAt: true, createdByPrincipal: true, credentialSecretName: true, databaseId: true, host: true, id: true, installationId: true, isPublished: true, kind: true, labels: true, lastError: true, metadata: true, name: true, platformOnly: true, role: true, status: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.registry.findOne({ id: '', select: { authMode: true, basePath: true, createdAt: true, createdByPrincipal: true, credentialSecretName: true, databaseId: true, host: true, id: true, installationId: true, isPublished: true, kind: true, labels: true, lastError: true, metadata: true, name: true, platformOnly: true, role: true, status: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.registry.create({ data: { authMode: '', basePath: '', createdByPrincipal: '', credentialSecretName: '', databaseId: '', host: '', installationId: '', isPublished: '', kind: '', labels: '', lastError: '', metadata: '', name: '', platformOnly: '', role: '', status: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.registry.update({ where: { id: '' }, data: { authMode: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.registry.delete({ where: { id: '' } }).execute(); ``` ### `db.registryGrant` CRUD operations for RegistryGrant records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actions` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `expiresAt` | Datetime | Yes | | `grantedBy` | UUID | Yes | | `granteeKey` | UUID | Yes | | `granteeScope` | String | Yes | | `id` | UUID | No | | `registryId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all registryGrant records const items = await db.registryGrant.findMany({ select: { actions: true, createdAt: true, createdByPrincipal: true, databaseId: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, registryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.registryGrant.findOne({ id: '', select: { actions: true, createdAt: true, createdByPrincipal: true, databaseId: true, expiresAt: true, grantedBy: true, granteeKey: true, granteeScope: true, id: true, registryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.registryGrant.create({ data: { actions: '', createdByPrincipal: '', databaseId: '', expiresAt: '', grantedBy: '', granteeKey: '', granteeScope: '', registryId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.registryGrant.update({ where: { id: '' }, data: { actions: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.registryGrant.delete({ where: { id: '' } }).execute(); ``` ### `db.repository` CRUD operations for Repository records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cloneUrl` | String | Yes | | `cloneUrlTrgmSimilarity` | Float | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `defaultBranch` | String | Yes | | `defaultBranchTrgmSimilarity` | Float | No | | `description` | String | Yes | | `descriptionTrgmSimilarity` | Float | No | | `embedding` | Vector | Yes | | `embeddingModel` | String | No | | `embeddingModelTrgmSimilarity` | Float | No | | `embeddingUpdatedAt` | Datetime | No | | `embeddingVectorDistance` | Float | No | | `externalId` | String | Yes | | `externalIdTrgmSimilarity` | Float | No | | `id` | UUID | No | | `isArchived` | Boolean | Yes | | `metadata` | JSON | Yes | | `name` | String | Yes | | `nameTrgmSimilarity` | Float | No | | `ownerId` | UUID | Yes | | `provider` | String | Yes | | `providerTrgmSimilarity` | Float | No | | `search` | FullText | No | | `searchScore` | Float | No | | `searchTsvRank` | Float | No | | `slug` | String | Yes | | `slugTrgmSimilarity` | Float | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | | `visibility` | String | Yes | | `visibilityTrgmSimilarity` | Float | No | **Operations:** ```typescript // List all repository records const items = await db.repository.findMany({ select: { cloneUrl: true, cloneUrlTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, defaultBranch: true, defaultBranchTrgmSimilarity: true, description: true, descriptionTrgmSimilarity: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, externalId: true, externalIdTrgmSimilarity: true, id: true, isArchived: true, metadata: true, name: true, nameTrgmSimilarity: true, ownerId: true, provider: true, providerTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, slug: true, slugTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true, visibility: true, visibilityTrgmSimilarity: true } }).execute(); // Get one by id const item = await db.repository.findOne({ id: '', select: { cloneUrl: true, cloneUrlTrgmSimilarity: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, defaultBranch: true, defaultBranchTrgmSimilarity: true, description: true, descriptionTrgmSimilarity: true, embedding: true, embeddingModel: true, embeddingModelTrgmSimilarity: true, embeddingUpdatedAt: true, embeddingVectorDistance: true, externalId: true, externalIdTrgmSimilarity: true, id: true, isArchived: true, metadata: true, name: true, nameTrgmSimilarity: true, ownerId: true, provider: true, providerTrgmSimilarity: true, search: true, searchScore: true, searchTsvRank: true, slug: true, slugTrgmSimilarity: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true, visibility: true, visibilityTrgmSimilarity: true } }).execute(); // Create const created = await db.repository.create({ data: { cloneUrl: '', createdBy: '', createdByPrincipal: '', databaseId: '', defaultBranch: '', description: '', embedding: '', externalId: '', isArchived: '', metadata: '', name: '', ownerId: '', provider: '', slug: '', updatedBy: '', updatedByPrincipal: '', visibility: '' }, select: { id: true } }).execute(); // Update const updated = await db.repository.update({ where: { id: '' }, data: { cloneUrl: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.repository.delete({ where: { id: '' } }).execute(); ``` > **pgvector embedding fields:** `embedding` > High-dimensional vector columns for semantic similarity search. Query via the Unified Search API pgvector adapter using cosine, L2, or inner-product distance. > **Unified Search API fields:** `search` > Fields provided by the Unified Search plugin. Includes full-text search (tsvector/BM25), trigram similarity scores, and the combined searchScore. Computed fields are read-only and cannot be set in create/update operations. ### `db.repositoryEvent` CRUD operations for RepositoryEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `commitSha` | String | Yes | | `createdAt` | Datetime | No | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `deliveryId` | String | Yes | | `eventType` | String | Yes | | `id` | UUID | No | | `metadata` | JSON | Yes | | `payload` | JSON | Yes | | `ref` | String | Yes | | `repositoryId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all repositoryEvent records const items = await db.repositoryEvent.findMany({ select: { actorId: true, commitSha: true, createdAt: true, createdByPrincipal: true, databaseId: true, deliveryId: true, eventType: true, id: true, metadata: true, payload: true, ref: true, repositoryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.repositoryEvent.findOne({ id: '', select: { actorId: true, commitSha: true, createdAt: true, createdByPrincipal: true, databaseId: true, deliveryId: true, eventType: true, id: true, metadata: true, payload: true, ref: true, repositoryId: true, updatedAt: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.repositoryEvent.create({ data: { actorId: '', commitSha: '', createdByPrincipal: '', databaseId: '', deliveryId: '', eventType: '', metadata: '', payload: '', ref: '', repositoryId: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.repositoryEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.repositoryEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.repositoryRequiredCheck` CRUD operations for RepositoryRequiredCheck records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `repositoryId` | UUID | Yes | | `updatedAt` | Datetime | No | | `workflowId` | UUID | Yes | **Operations:** ```typescript // List all repositoryRequiredCheck records const items = await db.repositoryRequiredCheck.findMany({ select: { createdAt: true, databaseId: true, id: true, repositoryId: true, updatedAt: true, workflowId: true } }).execute(); // Get one by id const item = await db.repositoryRequiredCheck.findOne({ id: '', select: { createdAt: true, databaseId: true, id: true, repositoryId: true, updatedAt: true, workflowId: true } }).execute(); // Create const created = await db.repositoryRequiredCheck.create({ data: { databaseId: '', repositoryId: '', workflowId: '' }, select: { id: true } }).execute(); // Update const updated = await db.repositoryRequiredCheck.update({ where: { id: '' }, data: { databaseId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.repositoryRequiredCheck.delete({ where: { id: '' } }).execute(); ``` ### `db.repositoryWorkflow` CRUD operations for RepositoryWorkflow records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cancelInProgress` | Boolean | Yes | | `concurrencyKey` | String | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `eventType` | String | Yes | | `graphId` | UUID | Yes | | `id` | UUID | No | | `inputs` | JSON | Yes | | `isEnabled` | Boolean | Yes | | `name` | String | Yes | | `refPattern` | String | Yes | | `repositoryId` | UUID | Yes | | `requiredSecrets` | String | Yes | | `slug` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all repositoryWorkflow records const items = await db.repositoryWorkflow.findMany({ select: { cancelInProgress: true, concurrencyKey: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, eventType: true, graphId: true, id: true, inputs: true, isEnabled: true, name: true, refPattern: true, repositoryId: true, requiredSecrets: true, slug: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.repositoryWorkflow.findOne({ id: '', select: { cancelInProgress: true, concurrencyKey: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, eventType: true, graphId: true, id: true, inputs: true, isEnabled: true, name: true, refPattern: true, repositoryId: true, requiredSecrets: true, slug: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.repositoryWorkflow.create({ data: { cancelInProgress: '', concurrencyKey: '', createdBy: '', createdByPrincipal: '', databaseId: '', eventType: '', graphId: '', inputs: '', isEnabled: '', name: '', refPattern: '', repositoryId: '', requiredSecrets: '', slug: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.repositoryWorkflow.update({ where: { id: '' }, data: { cancelInProgress: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.repositoryWorkflow.delete({ where: { id: '' } }).execute(); ``` ### `db.resource` CRUD operations for Resource records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `cpuLimitMillicores` | BigInt | No | | `cpuRequestMillicores` | BigInt | No | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `errorCount` | Int | Yes | | `id` | UUID | No | | `imageRef` | String | Yes | | `installationId` | UUID | Yes | | `integrations` | String | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `lastHeartbeatAt` | Datetime | Yes | | `memoryLimitBytes` | BigInt | No | | `memoryRequestBytes` | BigInt | No | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `realm` | String | Yes | | `replicas` | Int | No | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `resourceDefinitionId` | UUID | Yes | | `slug` | String | Yes | | `spec` | JSON | Yes | | `status` | String | Yes | | `statusObserved` | JSON | Yes | | `storageClass` | String | No | | `storageSizeBytes` | BigInt | No | | `storageTotalBytes` | BigInt | No | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all resource records const items = await db.resource.findMany({ select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.resource.findOne({ id: '', select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.resource.create({ data: { annotations: '', createdBy: '', createdByPrincipal: '', databaseId: '', errorCount: '', imageRef: '', installationId: '', integrations: '', kind: '', labels: '', lastError: '', lastHeartbeatAt: '', name: '', namespaceId: '', realm: '', requiredConfigs: '', requiredSecrets: '', resourceDefinitionId: '', slug: '', spec: '', status: '', statusObserved: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.resource.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resource.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceDeclaredCapacity` CRUD operations for ResourceDeclaredCapacity records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cpuLimitMillicores` | BigInt | Yes | | `cpuRequestMillicores` | BigInt | Yes | | `installationId` | UUID | Yes | | `isTransient` | Boolean | Yes | | `kind` | String | Yes | | `memoryLimitBytes` | BigInt | Yes | | `memoryRequestBytes` | BigInt | Yes | | `namespaceId` | UUID | Yes | | `podCountMax` | Int | Yes | | `podCountMin` | Int | Yes | | `source` | String | Yes | | `sourceId` | UUID | Yes | | `storageSizeBytes` | BigInt | Yes | | `storageTotalBytes` | BigInt | Yes | **Operations:** ```typescript // List all resourceDeclaredCapacity records const items = await db.resourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true, storageTotalBytes: true } }).execute(); // Get one by id const item = await db.resourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true, storageTotalBytes: true } }).execute(); // Update const updated = await db.resourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceDefinition` CRUD operations for ResourceDefinition records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `defaultSpec` | JSON | Yes | | `description` | String | Yes | | `id` | UUID | No | | `integrations` | String | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `paramsSchema` | JSON | Yes | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `slug` | String | Yes | | `stepUpMinAge` | Interval | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all resourceDefinition records const items = await db.resourceDefinition.findMany({ select: { annotations: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, defaultSpec: true, description: true, id: true, integrations: true, kind: true, labels: true, name: true, namespaceId: true, paramsSchema: true, slug: true, stepUpMinAge: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.resourceDefinition.findOne({ id: '', select: { annotations: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, defaultSpec: true, description: true, id: true, integrations: true, kind: true, labels: true, name: true, namespaceId: true, paramsSchema: true, slug: true, stepUpMinAge: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.resourceDefinition.create({ data: { annotations: '', createdBy: '', createdByPrincipal: '', databaseId: '', defaultSpec: '', description: '', integrations: '', kind: '', labels: '', name: '', namespaceId: '', paramsSchema: '', requiredConfigs: '', requiredSecrets: '', slug: '', stepUpMinAge: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.resourceDefinition.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceDefinition.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceEvent` CRUD operations for ResourceEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `actorId` | UUID | Yes | | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `eventType` | String | Yes | | `id` | UUID | No | | `message` | String | Yes | | `metadata` | JSON | Yes | | `resourceId` | UUID | Yes | **Operations:** ```typescript // List all resourceEvent records const items = await db.resourceEvent.findMany({ select: { actorId: true, createdAt: true, databaseId: true, eventType: true, id: true, message: true, metadata: true, resourceId: true } }).execute(); // Get one by id const item = await db.resourceEvent.findOne({ id: '', select: { actorId: true, createdAt: true, databaseId: true, eventType: true, id: true, message: true, metadata: true, resourceId: true } }).execute(); // Create const created = await db.resourceEvent.create({ data: { actorId: '', databaseId: '', eventType: '', message: '', metadata: '', resourceId: '' }, select: { id: true } }).execute(); // Update const updated = await db.resourceEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceEvent.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceInstallation` CRUD operations for ResourceInstallation records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `commitId` | UUID | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `params` | JSON | Yes | | `revision` | Int | Yes | | `slug` | String | Yes | | `status` | String | Yes | | `storeId` | UUID | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all resourceInstallation records const items = await db.resourceInstallation.findMany({ select: { commitId: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, id: true, name: true, namespaceId: true, params: true, revision: true, slug: true, status: true, storeId: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.resourceInstallation.findOne({ id: '', select: { commitId: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, id: true, name: true, namespaceId: true, params: true, revision: true, slug: true, status: true, storeId: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.resourceInstallation.create({ data: { commitId: '', createdBy: '', createdByPrincipal: '', databaseId: '', name: '', namespaceId: '', params: '', revision: '', slug: '', status: '', storeId: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.resourceInstallation.update({ where: { id: '' }, data: { commitId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceInstallation.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceObservedStorage` CRUD operations for ResourceObservedStorage records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `capacity` | String | Yes | | `capacityBytes` | BigInt | Yes | | `claimName` | String | Yes | | `declaredStorageClass` | String | Yes | | `declaredStorageSizeBytes` | BigInt | Yes | | `declaredStorageTotalBytes` | BigInt | Yes | | `installationId` | UUID | Yes | | `isBound` | Boolean | Yes | | `kind` | String | Yes | | `namespaceId` | UUID | Yes | | `phase` | String | Yes | | `requested` | String | Yes | | `requestedBytes` | BigInt | Yes | | `resourceId` | UUID | Yes | | `resourceStatus` | String | Yes | | `slug` | String | Yes | | `storageClass` | String | Yes | | `storageName` | String | Yes | **Operations:** ```typescript // List all resourceObservedStorage records const items = await db.resourceObservedStorage.findMany({ select: { capacity: true, capacityBytes: true, claimName: true, declaredStorageClass: true, declaredStorageSizeBytes: true, declaredStorageTotalBytes: true, installationId: true, isBound: true, kind: true, namespaceId: true, phase: true, requested: true, requestedBytes: true, resourceId: true, resourceStatus: true, slug: true, storageClass: true, storageName: true } }).execute(); // Get one by id const item = await db.resourceObservedStorage.findOne({ id: '', select: { capacity: true, capacityBytes: true, claimName: true, declaredStorageClass: true, declaredStorageSizeBytes: true, declaredStorageTotalBytes: true, installationId: true, isBound: true, kind: true, namespaceId: true, phase: true, requested: true, requestedBytes: true, resourceId: true, resourceStatus: true, slug: true, storageClass: true, storageName: true } }).execute(); // Update const updated = await db.resourceObservedStorage.update({ where: { id: '' }, data: { capacity: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceObservedStorage.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceStatusCheck` CRUD operations for ResourceStatusCheck records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `completedAt` | Datetime | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `requestedAt` | Datetime | Yes | | `requestedBy` | UUID | Yes | | `resourceId` | UUID | Yes | | `result` | JSON | Yes | | `status` | String | Yes | **Operations:** ```typescript // List all resourceStatusCheck records const items = await db.resourceStatusCheck.findMany({ select: { completedAt: true, databaseId: true, id: true, requestedAt: true, requestedBy: true, resourceId: true, result: true, status: true } }).execute(); // Get one by id const item = await db.resourceStatusCheck.findOne({ id: '', select: { completedAt: true, databaseId: true, id: true, requestedAt: true, requestedBy: true, resourceId: true, result: true, status: true } }).execute(); // Create const created = await db.resourceStatusCheck.create({ data: { completedAt: '', databaseId: '', requestedAt: '', requestedBy: '', resourceId: '', result: '', status: '' }, select: { id: true } }).execute(); // Update const updated = await db.resourceStatusCheck.update({ where: { id: '' }, data: { completedAt: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceStatusCheck.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceUsageLog` CRUD operations for ResourceUsageLog records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `cpuMillicores` | BigInt | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `intervalSeconds` | Int | Yes | | `memoryBytes` | BigInt | Yes | | `metrics` | JSON | Yes | | `namespaceId` | UUID | Yes | | `resourceId` | UUID | Yes | | `sampledAt` | Datetime | Yes | | `source` | String | Yes | **Operations:** ```typescript // List all resourceUsageLog records const items = await db.resourceUsageLog.findMany({ select: { cpuMillicores: true, databaseId: true, id: true, intervalSeconds: true, memoryBytes: true, metrics: true, namespaceId: true, resourceId: true, sampledAt: true, source: true } }).execute(); // Get one by id const item = await db.resourceUsageLog.findOne({ id: '', select: { cpuMillicores: true, databaseId: true, id: true, intervalSeconds: true, memoryBytes: true, metrics: true, namespaceId: true, resourceId: true, sampledAt: true, source: true } }).execute(); // Create const created = await db.resourceUsageLog.create({ data: { cpuMillicores: '', databaseId: '', intervalSeconds: '', memoryBytes: '', metrics: '', namespaceId: '', resourceId: '', sampledAt: '', source: '' }, select: { id: true } }).execute(); // Update const updated = await db.resourceUsageLog.update({ where: { id: '' }, data: { cpuMillicores: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceUsageLog.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceUsageSummary` CRUD operations for ResourceUsageSummary records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `databaseId` | UUID | Yes | | `date` | Date | Yes | | `gbSeconds` | BigFloat | Yes | | `id` | UUID | No | | `maxCpuMillicores` | BigInt | Yes | | `maxMemoryBytes` | BigInt | Yes | | `namespaceId` | UUID | Yes | | `resourceId` | UUID | Yes | | `runtimeSeconds` | BigInt | Yes | | `sampleCount` | Int | Yes | **Operations:** ```typescript // List all resourceUsageSummary records const items = await db.resourceUsageSummary.findMany({ select: { databaseId: true, date: true, gbSeconds: true, id: true, maxCpuMillicores: true, maxMemoryBytes: true, namespaceId: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id const item = await db.resourceUsageSummary.findOne({ id: '', select: { databaseId: true, date: true, gbSeconds: true, id: true, maxCpuMillicores: true, maxMemoryBytes: true, namespaceId: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create const created = await db.resourceUsageSummary.create({ data: { databaseId: '', date: '', gbSeconds: '', maxCpuMillicores: '', maxMemoryBytes: '', namespaceId: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update const updated = await db.resourceUsageSummary.update({ where: { id: '' }, data: { databaseId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceUsageSummary.delete({ where: { id: '' } }).execute(); ``` ### `db.resourceUtilization` CRUD operations for ResourceUtilization records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `avgMemoryBytes` | BigInt | Yes | | `cpuLimitMillicores` | BigInt | Yes | | `cpuPeakUtilization` | BigFloat | Yes | | `cpuRequestHeadroomMillicores` | BigInt | Yes | | `cpuRequestMillicores` | BigInt | Yes | | `date` | Date | Yes | | `gbSeconds` | BigFloat | Yes | | `kind` | String | Yes | | `maxCpuMillicores` | BigInt | Yes | | `maxMemoryBytes` | BigInt | Yes | | `memoryLimitBytes` | BigInt | Yes | | `memoryPeakUtilization` | BigFloat | Yes | | `memoryRequestBytes` | BigInt | Yes | | `memoryRequestHeadroomBytes` | BigInt | Yes | | `namespaceId` | UUID | Yes | | `replicas` | Int | Yes | | `resourceId` | UUID | Yes | | `runtimeSeconds` | BigInt | Yes | | `sampleCount` | Int | Yes | **Operations:** ```typescript // List all resourceUtilization records const items = await db.resourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id const item = await db.resourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Update const updated = await db.resourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.resourcesHealth` CRUD operations for ResourcesHealth records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `annotations` | JSON | Yes | | `cpuLimitMillicores` | BigInt | Yes | | `cpuRequestMillicores` | BigInt | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `errorCount` | Int | Yes | | `id` | UUID | No | | `imageRef` | String | Yes | | `installationId` | UUID | Yes | | `integrations` | String | Yes | | `kind` | String | Yes | | `labels` | JSON | Yes | | `lastError` | String | Yes | | `lastHeartbeatAt` | Datetime | Yes | | `memoryLimitBytes` | BigInt | Yes | | `memoryRequestBytes` | BigInt | Yes | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `realm` | String | Yes | | `replicas` | Int | Yes | | `requiredConfigs` | ResourceRequirement | Yes | | `requiredSecrets` | ResourceRequirement | Yes | | `resourceDefinitionId` | UUID | Yes | | `slug` | String | Yes | | `spec` | JSON | Yes | | `status` | String | Yes | | `statusDetail` | String | Yes | | `statusObserved` | JSON | Yes | | `storageClass` | String | Yes | | `storageSizeBytes` | BigInt | Yes | | `storageTotalBytes` | BigInt | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all resourcesHealth records const items = await db.resourcesHealth.findMany({ select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusDetail: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.resourcesHealth.findOne({ id: '', select: { annotations: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, errorCount: true, id: true, imageRef: true, installationId: true, integrations: true, kind: true, labels: true, lastError: true, lastHeartbeatAt: true, memoryLimitBytes: true, memoryRequestBytes: true, name: true, namespaceId: true, realm: true, replicas: true, resourceDefinitionId: true, slug: true, spec: true, status: true, statusDetail: true, statusObserved: true, storageClass: true, storageSizeBytes: true, storageTotalBytes: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Update const updated = await db.resourcesHealth.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourcesHealth.delete({ where: { id: '' } }).execute(); ``` ### `db.resourcesRequirementsState` CRUD operations for ResourcesRequirementsState records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `configHash` | String | Yes | | `configObjectName` | String | Yes | | `requirementsHash` | String | Yes | | `resourceId` | UUID | Yes | | `secretsHash` | String | Yes | | `secretsObjectName` | String | Yes | | `slug` | String | Yes | **Operations:** ```typescript // List all resourcesRequirementsState records const items = await db.resourcesRequirementsState.findMany({ select: { configHash: true, configObjectName: true, requirementsHash: true, resourceId: true, secretsHash: true, secretsObjectName: true, slug: true } }).execute(); // Get one by id const item = await db.resourcesRequirementsState.findOne({ id: '', select: { configHash: true, configObjectName: true, requirementsHash: true, resourceId: true, secretsHash: true, secretsObjectName: true, slug: true } }).execute(); // Update const updated = await db.resourcesRequirementsState.update({ where: { id: '' }, data: { configHash: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourcesRequirementsState.delete({ where: { id: '' } }).execute(); ``` ### `db.resourcesResolvedRequirement` CRUD operations for ResourcesResolvedRequirement records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `atomId` | UUID | Yes | | `configObjectName` | String | Yes | | `name` | String | Yes | | `namespaceId` | UUID | Yes | | `present` | Boolean | Yes | | `realm` | String | Yes | | `required` | Boolean | Yes | | `requirementKind` | String | Yes | | `resourceId` | UUID | Yes | | `secretsObjectName` | String | Yes | | `slug` | String | Yes | **Operations:** ```typescript // List all resourcesResolvedRequirement records const items = await db.resourcesResolvedRequirement.findMany({ select: { atomId: true, configObjectName: true, name: true, namespaceId: true, present: true, realm: true, required: true, requirementKind: true, resourceId: true, secretsObjectName: true, slug: true } }).execute(); // Get one by id const item = await db.resourcesResolvedRequirement.findOne({ id: '', select: { atomId: true, configObjectName: true, name: true, namespaceId: true, present: true, realm: true, required: true, requirementKind: true, resourceId: true, secretsObjectName: true, slug: true } }).execute(); // Update const updated = await db.resourcesResolvedRequirement.update({ where: { id: '' }, data: { atomId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.resourcesResolvedRequirement.delete({ where: { id: '' } }).execute(); ``` ### `db.serviceBinding` CRUD operations for ServiceBinding records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `id` | UUID | No | | `installationId` | UUID | Yes | | `installationScope` | String | Yes | | `kind` | String | Yes | | `lastError` | String | Yes | | `metadata` | JSON | Yes | | `namespaceId` | UUID | Yes | | `observedHost` | String | Yes | | `realm` | String | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all serviceBinding records const items = await db.serviceBinding.findMany({ select: { createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, id: true, installationId: true, installationScope: true, kind: true, lastError: true, metadata: true, namespaceId: true, observedHost: true, realm: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.serviceBinding.findOne({ id: '', select: { createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, id: true, installationId: true, installationScope: true, kind: true, lastError: true, metadata: true, namespaceId: true, observedHost: true, realm: true, status: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.serviceBinding.create({ data: { createdBy: '', createdByPrincipal: '', databaseId: '', installationId: '', installationScope: '', kind: '', lastError: '', metadata: '', namespaceId: '', observedHost: '', realm: '', status: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.serviceBinding.update({ where: { id: '' }, data: { createdBy: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.serviceBinding.delete({ where: { id: '' } }).execute(); ``` ### `db.webhookEndpoint` CRUD operations for WebhookEndpoint records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `active` | Boolean | Yes | | `createdAt` | Datetime | No | | `createdBy` | UUID | Yes | | `createdByPrincipal` | UUID | Yes | | `databaseId` | UUID | Yes | | `functionDefinitionId` | UUID | Yes | | `host` | String | Yes | | `id` | UUID | No | | `namespaceId` | UUID | Yes | | `path` | String | Yes | | `provider` | String | Yes | | `replayWindowSeconds` | Int | Yes | | `signingSecretName` | String | Yes | | `updatedAt` | Datetime | No | | `updatedBy` | UUID | Yes | | `updatedByPrincipal` | UUID | Yes | **Operations:** ```typescript // List all webhookEndpoint records const items = await db.webhookEndpoint.findMany({ select: { active: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, functionDefinitionId: true, host: true, id: true, namespaceId: true, path: true, provider: true, replayWindowSeconds: true, signingSecretName: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Get one by id const item = await db.webhookEndpoint.findOne({ id: '', select: { active: true, createdAt: true, createdBy: true, createdByPrincipal: true, databaseId: true, functionDefinitionId: true, host: true, id: true, namespaceId: true, path: true, provider: true, replayWindowSeconds: true, signingSecretName: true, updatedAt: true, updatedBy: true, updatedByPrincipal: true } }).execute(); // Create const created = await db.webhookEndpoint.create({ data: { active: '', createdBy: '', createdByPrincipal: '', databaseId: '', functionDefinitionId: '', host: '', namespaceId: '', path: '', provider: '', replayWindowSeconds: '', signingSecretName: '', updatedBy: '', updatedByPrincipal: '' }, select: { id: true } }).execute(); // Update const updated = await db.webhookEndpoint.update({ where: { id: '' }, data: { active: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.webhookEndpoint.delete({ where: { id: '' } }).execute(); ``` ### `db.webhookEvent` CRUD operations for WebhookEvent records. **Fields:** | Field | Type | Editable | |-------|------|----------| | `createdAt` | Datetime | No | | `databaseId` | UUID | Yes | | `endpointId` | UUID | Yes | | `error` | String | Yes | | `externalEventId` | String | Yes | | `id` | UUID | No | | `invocationCreatedAt` | Datetime | Yes | | `invocationId` | UUID | Yes | | `payload` | JSON | Yes | | `provider` | String | Yes | | `providerTimestamp` | Datetime | Yes | | `status` | String | Yes | | `updatedAt` | Datetime | No | **Operations:** ```typescript // List all webhookEvent records const items = await db.webhookEvent.findMany({ select: { createdAt: true, databaseId: true, endpointId: true, error: true, externalEventId: true, id: true, invocationCreatedAt: true, invocationId: true, payload: true, provider: true, providerTimestamp: true, status: true, updatedAt: true } }).execute(); // Get one by id const item = await db.webhookEvent.findOne({ id: '', select: { createdAt: true, databaseId: true, endpointId: true, error: true, externalEventId: true, id: true, invocationCreatedAt: true, invocationId: true, payload: true, provider: true, providerTimestamp: true, status: true, updatedAt: true } }).execute(); // Create const created = await db.webhookEvent.create({ data: { databaseId: '', endpointId: '', error: '', externalEventId: '', invocationCreatedAt: '', invocationId: '', payload: '', provider: '', providerTimestamp: '', status: '' }, select: { id: true } }).execute(); // Update const updated = await db.webhookEvent.update({ where: { id: '' }, data: { databaseId: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.webhookEvent.delete({ where: { id: '' } }).execute(); ``` ## Custom Operations ### `db.query.databaseReadFunctionGraph` databaseReadFunctionGraph - **Type:** query - **Arguments:** | Argument | Type | |----------|------| | `graphId` | UUID | ```typescript const result = await db.query.databaseReadFunctionGraph({ graphId: '' }).execute(); ``` ### `db.query.readFunctionGraph` readFunctionGraph - **Type:** query - **Arguments:** | Argument | Type | |----------|------| | `graphId` | UUID | ```typescript const result = await db.query.readFunctionGraph({ graphId: '' }).execute(); ``` ### `db.mutation.addEdge` addEdge - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | AddEdgeInput (required) | ```typescript const result = await db.mutation.addEdge({ input: '' }).execute(); ``` ### `db.mutation.addEdgeAndSave` addEdgeAndSave - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | AddEdgeAndSaveInput (required) | ```typescript const result = await db.mutation.addEdgeAndSave({ input: '' }).execute(); ``` ### `db.mutation.addNode` addNode - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | AddNodeInput (required) | ```typescript const result = await db.mutation.addNode({ input: '' }).execute(); ``` ### `db.mutation.addNodeAndSave` addNodeAndSave - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | AddNodeAndSaveInput (required) | ```typescript const result = await db.mutation.addNodeAndSave({ input: '' }).execute(); ``` ### `db.mutation.approveNode` approveNode - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ApproveNodeInput (required) | ```typescript const result = await db.mutation.approveNode({ input: { approved: '', executionId: '', feedback: '', nodeName: '' } }).execute(); ``` ### `db.mutation.copyGraph` copyGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | CopyGraphInput (required) | ```typescript const result = await db.mutation.copyGraph({ input: { graphId: '', name: '', scopeId: '' } }).execute(); ``` ### `db.mutation.createFunctionGraph` createFunctionGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | CreateFunctionGraphInput (required) | ```typescript const result = await db.mutation.createFunctionGraph({ input: '' }).execute(); ``` ### `db.mutation.databaseAddEdge` databaseAddEdge - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseAddEdgeInput (required) | ```typescript const result = await db.mutation.databaseAddEdge({ input: '' }).execute(); ``` ### `db.mutation.databaseAddEdgeAndSave` databaseAddEdgeAndSave - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseAddEdgeAndSaveInput (required) | ```typescript const result = await db.mutation.databaseAddEdgeAndSave({ input: '' }).execute(); ``` ### `db.mutation.databaseAddNode` databaseAddNode - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseAddNodeInput (required) | ```typescript const result = await db.mutation.databaseAddNode({ input: '' }).execute(); ``` ### `db.mutation.databaseAddNodeAndSave` databaseAddNodeAndSave - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseAddNodeAndSaveInput (required) | ```typescript const result = await db.mutation.databaseAddNodeAndSave({ input: '' }).execute(); ``` ### `db.mutation.databaseApproveNode` databaseApproveNode - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseApproveNodeInput (required) | ```typescript const result = await db.mutation.databaseApproveNode({ input: { approved: '', executionId: '', feedback: '', nodeName: '' } }).execute(); ``` ### `db.mutation.databaseCopyGraph` databaseCopyGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseCopyGraphInput (required) | ```typescript const result = await db.mutation.databaseCopyGraph({ input: { databaseId: '', graphId: '', name: '' } }).execute(); ``` ### `db.mutation.databaseCreateFunctionGraph` databaseCreateFunctionGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseCreateFunctionGraphInput (required) | ```typescript const result = await db.mutation.databaseCreateFunctionGraph({ input: '' }).execute(); ``` ### `db.mutation.databaseGraphInitEmptyRepo` databaseGraphInitEmptyRepo - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseGraphInitEmptyRepoInput (required) | ```typescript const result = await db.mutation.databaseGraphInitEmptyRepo({ input: { sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.databaseGraphInsertNodeAtPath` databaseGraphInsertNodeAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseGraphInsertNodeAtPathInput (required) | ```typescript const result = await db.mutation.databaseGraphInsertNodeAtPath({ input: '' }).execute(); ``` ### `db.mutation.databaseGraphInsertNodesAtPaths` databaseGraphInsertNodesAtPaths - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseGraphInsertNodesAtPathsInput (required) | ```typescript const result = await db.mutation.databaseGraphInsertNodesAtPaths({ input: '' }).execute(); ``` ### `db.mutation.databaseGraphSetAndCommit` databaseGraphSetAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseGraphSetAndCommitInput (required) | ```typescript const result = await db.mutation.databaseGraphSetAndCommit({ input: '' }).execute(); ``` ### `db.mutation.databaseGraphSetDataAtPath` databaseGraphSetDataAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseGraphSetDataAtPathInput (required) | ```typescript const result = await db.mutation.databaseGraphSetDataAtPath({ input: { data: '', path: '', root: '', sId: '' } }).execute(); ``` ### `db.mutation.databaseGraphSetManyAndCommit` databaseGraphSetManyAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseGraphSetManyAndCommitInput (required) | ```typescript const result = await db.mutation.databaseGraphSetManyAndCommit({ input: { entries: '', message: '', refname: '', sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.databaseImportDefinitions` databaseImportDefinitions - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseImportDefinitionsInput (required) | ```typescript const result = await db.mutation.databaseImportDefinitions({ input: { contexts: '', graphId: '', sourceCommitId: '', sourceScopeId: '' } }).execute(); ``` ### `db.mutation.databaseImportGraphJson` databaseImportGraphJson - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseImportGraphJsonInput (required) | ```typescript const result = await db.mutation.databaseImportGraphJson({ input: '' }).execute(); ``` ### `db.mutation.databaseSaveGraph` databaseSaveGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseSaveGraphInput (required) | ```typescript const result = await db.mutation.databaseSaveGraph({ input: { graphId: '', message: '', rootHash: '' } }).execute(); ``` ### `db.mutation.databaseStartExecution` databaseStartExecution - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseStartExecutionInput (required) | ```typescript const result = await db.mutation.databaseStartExecution({ input: '' }).execute(); ``` ### `db.mutation.databaseValidateFunctionGraph` databaseValidateFunctionGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | DatabaseValidateFunctionGraphInput (required) | ```typescript const result = await db.mutation.databaseValidateFunctionGraph({ input: { graphId: '' } }).execute(); ``` ### `db.mutation.functionExecutionLogsAppend` functionExecutionLogsAppend - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | FunctionExecutionLogsAppendInput (required) | ```typescript const result = await db.mutation.functionExecutionLogsAppend({ input: '' }).execute(); ``` ### `db.mutation.functionInvocationsCreatePage` functionInvocationsCreatePage - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | FunctionInvocationsCreatePageInput (required) | ```typescript const result = await db.mutation.functionInvocationsCreatePage({ input: { entityId: '', payload: '', provenance: '', routeBindingId: '', taskIdentifier: '' } }).execute(); ``` ### `db.mutation.functionInvocationsCreateSync` functionInvocationsCreateSync - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | FunctionInvocationsCreateSyncInput (required) | ```typescript const result = await db.mutation.functionInvocationsCreateSync({ input: { entityId: '', payload: '', provenance: '', routeBindingId: '', taskIdentifier: '' } }).execute(); ``` ### `db.mutation.importDefinitions` importDefinitions - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ImportDefinitionsInput (required) | ```typescript const result = await db.mutation.importDefinitions({ input: { contexts: '', graphId: '', sourceCommitId: '', sourceScopeId: '' } }).execute(); ``` ### `db.mutation.importGraphJson` importGraphJson - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ImportGraphJsonInput (required) | ```typescript const result = await db.mutation.importGraphJson({ input: '' }).execute(); ``` ### `db.mutation.infraInitEmptyRepo` infraInitEmptyRepo - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InfraInitEmptyRepoInput (required) | ```typescript const result = await db.mutation.infraInitEmptyRepo({ input: { sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.infraInsertNodeAtPath` infraInsertNodeAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InfraInsertNodeAtPathInput (required) | ```typescript const result = await db.mutation.infraInsertNodeAtPath({ input: '' }).execute(); ``` ### `db.mutation.infraInsertNodesAtPaths` infraInsertNodesAtPaths - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InfraInsertNodesAtPathsInput (required) | ```typescript const result = await db.mutation.infraInsertNodesAtPaths({ input: '' }).execute(); ``` ### `db.mutation.infraSetAndCommit` infraSetAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InfraSetAndCommitInput (required) | ```typescript const result = await db.mutation.infraSetAndCommit({ input: '' }).execute(); ``` ### `db.mutation.infraSetDataAtPath` infraSetDataAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InfraSetDataAtPathInput (required) | ```typescript const result = await db.mutation.infraSetDataAtPath({ input: { data: '', path: '', root: '', sId: '' } }).execute(); ``` ### `db.mutation.infraSetManyAndCommit` infraSetManyAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InfraSetManyAndCommitInput (required) | ```typescript const result = await db.mutation.infraSetManyAndCommit({ input: { entries: '', message: '', refname: '', sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.initEmptyRepo` initEmptyRepo - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InitEmptyRepoInput (required) | ```typescript const result = await db.mutation.initEmptyRepo({ input: { sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.insertNodeAtPath` insertNodeAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InsertNodeAtPathInput (required) | ```typescript const result = await db.mutation.insertNodeAtPath({ input: '' }).execute(); ``` ### `db.mutation.insertNodesAtPaths` insertNodesAtPaths - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | InsertNodesAtPathsInput (required) | ```typescript const result = await db.mutation.insertNodesAtPaths({ input: '' }).execute(); ``` ### `db.mutation.platformFunctionExecutionLogsAppend` platformFunctionExecutionLogsAppend - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformFunctionExecutionLogsAppendInput (required) | ```typescript const result = await db.mutation.platformFunctionExecutionLogsAppend({ input: '' }).execute(); ``` ### `db.mutation.platformFunctionInvocationsCreatePage` platformFunctionInvocationsCreatePage - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformFunctionInvocationsCreatePageInput (required) | ```typescript const result = await db.mutation.platformFunctionInvocationsCreatePage({ input: { entityId: '', payload: '', provenance: '', routeBindingId: '', taskIdentifier: '' } }).execute(); ``` ### `db.mutation.platformFunctionInvocationsCreateSync` platformFunctionInvocationsCreateSync - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformFunctionInvocationsCreateSyncInput (required) | ```typescript const result = await db.mutation.platformFunctionInvocationsCreateSync({ input: { entityId: '', payload: '', provenance: '', routeBindingId: '', taskIdentifier: '' } }).execute(); ``` ### `db.mutation.platformInfraInitEmptyRepo` platformInfraInitEmptyRepo - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformInfraInitEmptyRepoInput (required) | ```typescript const result = await db.mutation.platformInfraInitEmptyRepo({ input: { sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.platformInfraInsertNodeAtPath` platformInfraInsertNodeAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformInfraInsertNodeAtPathInput (required) | ```typescript const result = await db.mutation.platformInfraInsertNodeAtPath({ input: '' }).execute(); ``` ### `db.mutation.platformInfraInsertNodesAtPaths` platformInfraInsertNodesAtPaths - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformInfraInsertNodesAtPathsInput (required) | ```typescript const result = await db.mutation.platformInfraInsertNodesAtPaths({ input: '' }).execute(); ``` ### `db.mutation.platformInfraSetAndCommit` platformInfraSetAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformInfraSetAndCommitInput (required) | ```typescript const result = await db.mutation.platformInfraSetAndCommit({ input: '' }).execute(); ``` ### `db.mutation.platformInfraSetDataAtPath` platformInfraSetDataAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformInfraSetDataAtPathInput (required) | ```typescript const result = await db.mutation.platformInfraSetDataAtPath({ input: { data: '', path: '', root: '', sId: '' } }).execute(); ``` ### `db.mutation.platformInfraSetManyAndCommit` platformInfraSetManyAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformInfraSetManyAndCommitInput (required) | ```typescript const result = await db.mutation.platformInfraSetManyAndCommit({ input: { entries: '', message: '', refname: '', sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsInstall` platformResourceInstallationsInstall - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformResourceInstallationsInstallInput (required) | ```typescript const result = await db.mutation.platformResourceInstallationsInstall({ input: { definitionIds: '', name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsRollback` platformResourceInstallationsRollback - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformResourceInstallationsRollbackInput (required) | ```typescript const result = await db.mutation.platformResourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUninstall` platformResourceInstallationsUninstall - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformResourceInstallationsUninstallInput (required) | ```typescript const result = await db.mutation.platformResourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUpgrade` platformResourceInstallationsUpgrade - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | PlatformResourceInstallationsUpgradeInput (required) | ```typescript const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.provisionBucket` Reconcile an S3 bucket for a logical bucket in the database. Records the request on the bucket row via RLS; the bucket's job trigger then enqueues the same storage:provision_bucket job used on INSERT, and repeated requests collapse into one pending job. This is idempotent for an already-reconciled bucket; failures become GraphQL errors. - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ProvisionBucketInput (required) | ```typescript const result = await db.mutation.provisionBucket({ input: { bucketKey: '', ownerId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsInstall` resourceInstallationsInstall - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ResourceInstallationsInstallInput (required) | ```typescript const result = await db.mutation.resourceInstallationsInstall({ input: { definitionIds: '', name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsRollback` resourceInstallationsRollback - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ResourceInstallationsRollbackInput (required) | ```typescript const result = await db.mutation.resourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUninstall` resourceInstallationsUninstall - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ResourceInstallationsUninstallInput (required) | ```typescript const result = await db.mutation.resourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUpgrade` resourceInstallationsUpgrade - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ResourceInstallationsUpgradeInput (required) | ```typescript const result = await db.mutation.resourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.saveGraph` saveGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | SaveGraphInput (required) | ```typescript const result = await db.mutation.saveGraph({ input: { graphId: '', message: '', rootHash: '' } }).execute(); ``` ### `db.mutation.setAndCommit` setAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | SetAndCommitInput (required) | ```typescript const result = await db.mutation.setAndCommit({ input: '' }).execute(); ``` ### `db.mutation.setDataAtPath` setDataAtPath - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | SetDataAtPathInput (required) | ```typescript const result = await db.mutation.setDataAtPath({ input: { data: '', path: '', root: '', sId: '' } }).execute(); ``` ### `db.mutation.setManyAndCommit` setManyAndCommit - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | SetManyAndCommitInput (required) | ```typescript const result = await db.mutation.setManyAndCommit({ input: { entries: '', message: '', refname: '', sId: '', storeId: '' } }).execute(); ``` ### `db.mutation.startExecution` startExecution - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | StartExecutionInput (required) | ```typescript const result = await db.mutation.startExecution({ input: '' }).execute(); ``` ### `db.mutation.validateFunctionGraph` validateFunctionGraph - **Type:** mutation - **Arguments:** | Argument | Type | |----------|------| | `input` | ValidateFunctionGraphInput (required) | ```typescript const result = await db.mutation.validateFunctionGraph({ input: { graphId: '' } }).execute(); ```