public.oauth_refresh_tokens¶
列¶
| 名称 | 类型 | 默认值 | 可空 | 子表 | 父表 | 注释 |
|---|---|---|---|---|---|---|
| clientId | varchar | false | public.oauth_clients | |||
| createdAt | timestamp(3) with time zone | CURRENT_TIMESTAMP(3) | false | |||
| expiresAt | bigint | false | Unix 时间戳(毫秒) | |||
| resource | varchar | false | 授权获批所面向的 RFC 8707 资源指示器(例如 https://n8n.example.com/mcp-server/http);由该刷新令牌签发的每个访问令牌的受众。 | |||
| scope | json | '["tool:listWorkflows","tool:getWorkflowDetails"]'::json | false | 授予此刷新令牌的 OAuth 作用域 | ||
| token | varchar(255) | false | ||||
| updatedAt | timestamp(3) with time zone | CURRENT_TIMESTAMP(3) | false | |||
| userId | uuid | false | public.user |
约束¶
| 名称 | 类型 | 定义 |
|---|---|---|
| FK_a699f3ed9fd0c1b19bc2608ac53 | FOREIGN KEY | FOREIGN KEY ("userId") REFERENCES "user"(id) ON DELETE CASCADE |
| FK_b388696ce4d8be7ffbe8d3e4b69 | FOREIGN KEY | FOREIGN KEY ("clientId") REFERENCES oauth_clients(id) ON DELETE CASCADE |
| PK_74abaed0b30711b6532598b0392 | PRIMARY KEY | PRIMARY KEY (token) |
| oauth_refresh_tokens_clientId_not_null | n | NOT NULL "clientId" |
| oauth_refresh_tokens_createdAt_not_null | n | NOT NULL "createdAt" |
| oauth_refresh_tokens_expiresAt_not_null | n | NOT NULL "expiresAt" |
| oauth_refresh_tokens_resource_not_null | n | NOT NULL resource |
| oauth_refresh_tokens_scope_not_null | n | NOT NULL scope |
| oauth_refresh_tokens_token_not_null | n | NOT NULL token |
| oauth_refresh_tokens_updatedAt_not_null | n | NOT NULL "updatedAt" |
| oauth_refresh_tokens_userId_not_null | n | NOT NULL "userId" |
索引¶
| 名称 | 定义 |
|---|---|
| PK_74abaed0b30711b6532598b0392 | CREATE UNIQUE INDEX "PK_74abaed0b30711b6532598b0392" ON public.oauth_refresh_tokens USING btree (token) |
关系¶
erDiagram
"public.oauth_refresh_tokens" }o--|| "public.oauth_clients" : "FOREIGN KEY (#quot;clientId#quot;) REFERENCES oauth_clients(id) ON DELETE CASCADE"
"public.oauth_refresh_tokens" }o--|| "public.user" : "FOREIGN KEY (#quot;userId#quot;) REFERENCES #quot;user#quot;(id) ON DELETE CASCADE"
"public.oauth_refresh_tokens" {
varchar clientId FK
timestamp_3__with_time_zone createdAt
bigint expiresAt
varchar resource
json scope
varchar_255_ token
timestamp_3__with_time_zone updatedAt
uuid userId FK
}
"public.oauth_clients" {
varchar_255_ clientSecret
bigint clientSecretExpiresAt
timestamp_3__with_time_zone createdAt
json grantTypes
varchar id
boolean isFirstParty
varchar_255_ name
json redirectUris
varchar_255_ tokenEndpointAuthMethod
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
}由 tbls 生成
本页原文 Markdown:在 AtomGit 查看·内容源自开源项目 n8/n8n