跳转至

public.project

列

约束

名称 类型 定义
PK_4d68b1358bb5b766d3e78f32f57 PRIMARY KEY PRIMARY KEY (id)
project_createdAt_not_null n NOT NULL "createdAt"
project_customTelemetryTags_not_null n NOT NULL "customTelemetryTags"
project_id_not_null n NOT NULL id
project_name_not_null n NOT NULL name
project_type_not_null n NOT NULL type
project_updatedAt_not_null n NOT NULL "updatedAt"
projects_creatorId_foreign FOREIGN KEY FOREIGN KEY ("creatorId") REFERENCES "user"(id) ON DELETE SET NULL

索引

名称 定义
PK_4d68b1358bb5b766d3e78f32f57 CREATE UNIQUE INDEX "PK_4d68b1358bb5b766d3e78f32f57" ON public.project USING btree (id)

关系

erDiagram

"public.project" }o--o| "public.user" : "FOREIGN KEY (#quot;creatorId#quot;) REFERENCES #quot;user#quot;(id) ON DELETE SET NULL"
"public.activity_event" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.agent_chat_attachments" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.agent_execution_threads" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.agents" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.ai_preference" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.app" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.data_table" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.folder" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.insights_metadata" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE SET NULL"
"public.instance_ai_threads" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.knowledge_collection" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.mcp_server" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.project_execution_limit" |o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.project_pool_settings" |o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.project_relation" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.project_secrets_provider_access" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.project_workflow_review_settings" |o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.promotion_environment_project" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.role_mapping_rule_project" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.self_healing_configuration" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.self_healing_configuration_workflow" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.self_healing_investigation" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.self_healing_result" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.shared_credentials" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.shared_knowledge_collection" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.shared_workflow" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.skill" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.skill_source" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.type_availability_policy_scope" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.variables" }o--o| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.workflow_review_request" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
"public.workflow_suggestion" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"

"public.project" {
  timestamp_3__with_time_zone createdAt
  uuid creatorId FK
  json customTelemetryTags
  varchar_512_ description
  json icon
  varchar_36_ id
  varchar_255_ name
  varchar_36_ type
  timestamp_3__with_time_zone updatedAt
}
"public.user" {
  timestamp_3__with_time_zone createdAt
  boolean disabled
  varchar_255_ email
  varchar_32_ firstName
  uuid id
  varchar_16_ kind
  date lastActiveAt
  varchar_32_ lastName
  boolean mfaEnabled
  text mfaRecoveryCodes
  text mfaSecret
  varchar_255_ password
  json personalizationAnswers
  varchar_128_ roleSlug FK
  json settings
  timestamp_3__with_time_zone updatedAt
}
"public.activity_event" {
  varchar_64_ action
  varchar_32_ category
  timestamp_3__with_time_zone createdAt
  json data
  integer id
  varchar_36_ projectId FK
  varchar_36_ resourceId
  text resourceName
  varchar_32_ resourceType
  integer typeVersion
  uuid userId FK
}
"public.agent_chat_attachments" {
  varchar_36_ agentId FK
  text binaryDataId
  varchar_64_ contentHash
  timestamp_3__with_time_zone createdAt
  varchar_128_ createdByThreadId
  varchar_255_ fileName
  integer fileSizeBytes
  varchar_16_ id
  varchar_255_ mimeType
  varchar_36_ projectId FK
  varchar_255_ resourceId
  varchar_32_ source
  varchar_128_ threadId
  timestamp_3__with_time_zone updatedAt
}
"public.agent_execution_threads" {
  varchar_16_ accessScope
  varchar_36_ agentId FK
  varchar_255_ agentName
  timestamp_3__with_time_zone createdAt
  varchar_8_ emoji
  varchar_128_ id
  boolean isTestChat
  uuid ownerId FK
  varchar_36_ parentAgentId
  varchar_128_ parentThreadId
  varchar_255_ projectId FK
  integer sessionNumber
  varchar_32_ taskId
  json taskStop
  varchar_36_ taskVersionId FK
  varchar_255_ title
  integer totalCompletionTokens
  double_precision totalCost
  integer totalDuration
  integer totalPromptTokens
  timestamp_3__with_time_zone updatedAt
}
"public.agents" {
  varchar_36_ activeVersionId FK
  varchar_36_ approvalWorkflowId FK
  boolean availableInMCP
  timestamp_3__with_time_zone createdAt
  varchar_36_ id
  uuid identityId FK
  json integrations
  boolean isArchived
  varchar_128_ name
  varchar_36_ parentFolderId FK
  varchar_255_ projectId FK
  integer publicationRevision
  integer revision
  json schema
  varchar_16_ scope
  timestamp_3__with_time_zone setupCompletedAt
  json skills
  json tools
  timestamp_3__with_time_zone updatedAt
  varchar_36_ versionId
}
"public.ai_preference" {
  text content
  timestamp_3__with_time_zone createdAt
  uuid createdById FK
  uuid id
  varchar_36_ projectId FK
  varchar_16_ source
  timestamp_3__with_time_zone updatedAt
  uuid userId FK
}
"public.app" {
  timestamp_3__with_time_zone createdAt
  uuid draftVersionId FK
  uuid id
  varchar_128_ name
  varchar_128_ namespace
  varchar_36_ projectId FK
  uuid publishedVersionId FK
  timestamp_3__with_time_zone updatedAt
  varchar_16_ visibility
}
"public.data_table" {
  timestamp_3__with_time_zone createdAt
  varchar_36_ id
  varchar_128_ name
  varchar_36_ projectId FK
  timestamp_3__with_time_zone updatedAt
}
"public.folder" {
  timestamp_3__with_time_zone createdAt
  varchar_36_ id
  varchar_128_ name
  varchar_36_ parentFolderId FK
  varchar_36_ projectId FK
  varchar_16_ resourceType
  timestamp_3__with_time_zone updatedAt
}
"public.insights_metadata" {
  integer metaId
  varchar_36_ projectId FK
  varchar_255_ projectName
  varchar_36_ workflowId FK
  varchar_128_ workflowName
}
"public.instance_ai_threads" {
  timestamp_3__with_time_zone createdAt
  uuid id
  json metadata
  varchar_36_ projectId FK
  varchar_255_ resourceId
  text title
  timestamp_3__with_time_zone updatedAt
}
"public.knowledge_collection" {
  varchar_36_ agentId FK
  timestamp_3__with_time_zone createdAt
  uuid createdById FK
  varchar_512_ description
  varchar_16_ id
  boolean isGlobal
  varchar_16_ kind
  varchar_128_ name
  varchar_36_ projectId FK
  varchar_24_ slug
  timestamp_3__with_time_zone updatedAt
}
"public.mcp_server" {
  timestamp_3__with_time_zone createdAt
  uuid createdById FK
  timestamp_3__with_time_zone deletedAt
  text description
  uuid id
  varchar_128_ name
  varchar_36_ projectId FK
  varchar_128_ slug
  timestamp_3__with_time_zone updatedAt
}
"public.project_execution_limit" {
  timestamp_3__with_time_zone createdAt
  integer maxExecutions
  varchar_36_ projectId FK
  timestamp_3__with_time_zone updatedAt
}
"public.project_pool_settings" {
  timestamp_3__with_time_zone createdAt
  varchar_63_ defaultPool
  varchar_36_ projectId FK
  timestamp_3__with_time_zone updatedAt
}
"public.project_relation" {
  timestamp_3__with_time_zone createdAt
  varchar_36_ projectId FK
  varchar role FK
  timestamp_3__with_time_zone updatedAt
  uuid userId FK
}
"public.project_secrets_provider_access" {
  timestamp_3__with_time_zone createdAt
  varchar_36_ projectId FK
  varchar_128_ role
  integer secretsProviderConnectionId FK
  timestamp_3__with_time_zone updatedAt
}
"public.project_workflow_review_settings" {
  timestamp_3__with_time_zone createdAt
  varchar_36_ projectId FK
  boolean requiredByInstance
  boolean requiredByProject
  timestamp_3__with_time_zone updatedAt
}
"public.promotion_environment_project" {
  timestamp_3__with_time_zone createdAt
  varchar_16_ direction
  uuid environmentId FK
  varchar_36_ projectId FK
  timestamp_3__with_time_zone updatedAt
}
"public.role_mapping_rule_project" {
  varchar_36_ projectId FK
  varchar_16_ roleMappingRuleId FK
}
"public.self_healing_configuration" {
  timestamp_3__with_time_zone createdAt
  boolean enabled
  uuid enabledById FK
  integer id
  boolean includeAllProjectMembers
  boolean includeSubWorkflows
  varchar_36_ projectId FK
  varchar_16_ scope
  timestamp_3__with_time_zone updatedAt
}
"public.self_healing_configuration_workflow" {
  integer configurationId FK
  varchar_36_ projectId FK
  varchar_36_ workflowId FK
}
"public.self_healing_investigation" {
  uuid backgroundUserId FK
  integer configurationId FK
  timestamp_3__with_time_zone createdAt
  varchar_36_ executionId
  timestamp_3__with_time_zone finishedAt
  varchar_36_ id
  varchar_36_ projectId FK
  varchar_36_ publishedVersionId
  varchar_36_ resultId FK
  uuid runId
  uuid threadId
  timestamp_3__with_time_zone updatedAt
  varchar_36_ workflowId FK
}
"public.self_healing_result" {
  uuid backgroundUserId FK
  timestamp_3__with_time_zone completedAt
  integer configurationId FK
  timestamp_3__with_time_zone createdAt
  varchar_36_ executionId
  varchar_36_ id
  varchar_16_ outcome
  varchar_36_ projectId FK
  text report
  varchar_16_ reviewState
  text summary
  timestamp_3__with_time_zone updatedAt
  json usage
  varchar_36_ workflowId FK
}
"public.shared_credentials" {
  timestamp_3__with_time_zone createdAt
  varchar_36_ credentialsId FK
  varchar_36_ projectId FK
  text role
  timestamp_3__with_time_zone updatedAt
}
"public.shared_knowledge_collection" {
  timestamp_3__with_time_zone createdAt
  varchar_16_ knowledgeCollectionId FK
  varchar_36_ projectId FK
  varchar_32_ role
  timestamp_3__with_time_zone updatedAt
}
"public.shared_workflow" {
  timestamp_3__with_time_zone createdAt
  varchar_36_ projectId FK
  text role
  timestamp_3__with_time_zone updatedAt
  varchar_36_ workflowId FK
}
"public.skill" {
  boolean availableToAssistant
  boolean availableToMCP
  timestamp_3__with_time_zone createdAt
  uuid createdById FK
  varchar_36_ id
  varchar_36_ projectId FK
  varchar_16_ source
  timestamp_3__with_time_zone updatedAt
}
"public.skill_source" {
  timestamp_3__with_time_zone createdAt
  uuid createdById FK
  varchar_36_ credentialId FK
  boolean credentialRequired
  uuid id
  varchar_255_ identityKey
  timestamp_3__with_time_zone lastCheckedAt
  varchar_32_ lastErrorReason
  json locator
  text probeCursor
  varchar_36_ projectId FK
  varchar_32_ status
  varchar_16_ type
  json unlinkedSkills
  timestamp_3__with_time_zone updatedAt
}
"public.type_availability_policy_scope" {
  timestamp_3__with_time_zone createdAt
  varchar_16_ defaultAction
  varchar_36_ id
  varchar_64_ kind
  varchar_36_ projectId FK
  timestamp_3__with_time_zone updatedAt
  varchar_36_ updatedBy
  integer version
}
"public.variables" {
  varchar_36_ id
  varchar_50_ key
  varchar_36_ projectId FK
  varchar_50_ type
  text value
}
"public.workflow_review_request" {
  timestamp_3__with_time_zone approvedAt
  uuid closedById FK
  timestamp_3__with_time_zone createdAt
  uuid createdById FK
  varchar_50_ decision
  text description
  varchar_36_ id
  varchar_36_ projectId FK
  varchar_16_ state
  varchar_255_ title
  timestamp_3__with_time_zone updatedAt
  uuid updatedById FK
}
"public.workflow_suggestion" {
  varchar_32_ appliedAction
  uuid appliedActorId
  varchar_64_ appliedChecksum
  varchar_36_ appliedVersionId
  uuid backgroundUserId FK
  timestamp_3__with_time_zone closedAt
  varchar_16_ closedReason
  timestamp_3__with_time_zone createdAt
  json expectedBaseline
  varchar_36_ id
  json payload
  varchar_36_ projectId FK
  varchar_16_ resultKind
  varchar_36_ selfHealingResultId FK
  varchar_16_ state
  timestamp_3__with_time_zone updatedAt
  varchar_36_ workflowId FK
}

由 tbls 生成

本页原文 Markdown:在 AtomGit 查看·内容源自开源项目 n8/n8n