mirror of
https://github.com/n8n-io/n8n.git
synced 2026-10-21 20:20:03 +02:00
108 lines
3.9 KiB
Markdown
Generated
108 lines
3.9 KiB
Markdown
Generated
# public.app
|
|
|
|
## Columns
|
|
|
|
| Name | Type | Default | Nullable | Children | Parents | Comment |
|
|
| ---- | ---- | ------- | -------- | -------- | ------- | ------- |
|
|
| activeVersionId | varchar(36) | | true | | [public.app_version](public.app_version.md) | app_version served at /apps/\<namespace\>/; null falls back to pages |
|
|
| bindings | json | '[]'::json | false | | | Resources the served app may call through its runtime API |
|
|
| createdAt | timestamp(3) with time zone | CURRENT_TIMESTAMP(3) | false | | | |
|
|
| id | varchar(36) | | false | [public.app_version](public.app_version.md) [public.instance_ai_threads](public.instance_ai_threads.md) [public.page](public.page.md) | | |
|
|
| name | varchar(128) | | false | | | |
|
|
| namespace | varchar(128) | | false | | | URL path segment under /apps/; unique per project |
|
|
| projectId | varchar(36) | | false | | [public.project](public.project.md) | |
|
|
| theme | json | | true | | | Shared colors/spacing for the App, app-defined shape |
|
|
| updatedAt | timestamp(3) with time zone | CURRENT_TIMESTAMP(3) | false | | | |
|
|
|
|
## Constraints
|
|
|
|
| Name | Type | Definition |
|
|
| ---- | ---- | ---------- |
|
|
| FK_f84dd7eb539e46e0c233fa09b20 | FOREIGN KEY | FOREIGN KEY ("projectId") REFERENCES project(id) ON DELETE CASCADE |
|
|
| PK_9478629fc093d229df09e560aea | PRIMARY KEY | PRIMARY KEY (id) |
|
|
| app_activeVersionId_foreign | FOREIGN KEY | FOREIGN KEY ("activeVersionId") REFERENCES app_version(id) ON DELETE SET NULL |
|
|
| app_bindings_not_null | n | NOT NULL bindings |
|
|
| app_createdAt_not_null | n | NOT NULL "createdAt" |
|
|
| app_id_not_null | n | NOT NULL id |
|
|
| app_name_not_null | n | NOT NULL name |
|
|
| app_namespace_not_null | n | NOT NULL namespace |
|
|
| app_projectId_not_null | n | NOT NULL "projectId" |
|
|
| app_updatedAt_not_null | n | NOT NULL "updatedAt" |
|
|
|
|
## Indexes
|
|
|
|
| Name | Definition |
|
|
| ---- | ---------- |
|
|
| IDX_app_namespace | CREATE UNIQUE INDEX "IDX_app_namespace" ON public.app USING btree (namespace) |
|
|
| PK_9478629fc093d229df09e560aea | CREATE UNIQUE INDEX "PK_9478629fc093d229df09e560aea" ON public.app USING btree (id) |
|
|
|
|
## Relations
|
|
|
|
```mermaid
|
|
erDiagram
|
|
|
|
"public.app" }o--o| "public.app_version" : "FOREIGN KEY (#quot;activeVersionId#quot;) REFERENCES app_version(id) ON DELETE SET NULL"
|
|
"public.app_version" }o--|| "public.app" : "FOREIGN KEY (#quot;appId#quot;) REFERENCES app(id) ON DELETE CASCADE"
|
|
"public.instance_ai_threads" }o--o| "public.app" : "FOREIGN KEY (#quot;appId#quot;) REFERENCES app(id) ON DELETE SET NULL"
|
|
"public.page" }o--|| "public.app" : "FOREIGN KEY (#quot;appId#quot;) REFERENCES app(id) ON DELETE CASCADE"
|
|
"public.app" }o--|| "public.project" : "FOREIGN KEY (#quot;projectId#quot;) REFERENCES project(id) ON DELETE CASCADE"
|
|
|
|
"public.app" {
|
|
varchar_36_ activeVersionId FK
|
|
json bindings
|
|
timestamp_3__with_time_zone createdAt
|
|
varchar_36_ id
|
|
varchar_128_ name
|
|
varchar_128_ namespace
|
|
varchar_36_ projectId FK
|
|
json theme
|
|
timestamp_3__with_time_zone updatedAt
|
|
}
|
|
"public.app_version" {
|
|
varchar_36_ appId FK
|
|
timestamp_3__with_time_zone createdAt
|
|
integer distSizeBytes
|
|
varchar_255_ distStorageKey
|
|
varchar_36_ id
|
|
integer sourceSizeBytes
|
|
varchar_255_ sourceStorageKey
|
|
varchar_8_ storedAt
|
|
timestamp_3__with_time_zone updatedAt
|
|
}
|
|
"public.instance_ai_threads" {
|
|
varchar_36_ appId FK
|
|
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.page" {
|
|
varchar_36_ appId FK
|
|
json content
|
|
timestamp_3__with_time_zone createdAt
|
|
varchar_36_ dataWorkflowId FK
|
|
varchar_36_ id
|
|
varchar_36_ parentPageId FK
|
|
varchar_255_ route
|
|
timestamp_3__with_time_zone updatedAt
|
|
}
|
|
"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
|
|
}
|
|
```
|
|
|
|
---
|
|
|
|
> Generated by [tbls](https://github.com/k1LoW/tbls)
|