@downcity/city 1.1.6 → 1.1.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (153) hide show
  1. package/bin/cli/agent/AgentManager.js +1 -1
  2. package/bin/cli/agent/AgentManager.js.map +1 -1
  3. package/bin/cli/agent/AgentReset.js +1 -1
  4. package/bin/cli/agent/AgentReset.js.map +1 -1
  5. package/bin/cli/agent/Init.d.ts.map +1 -1
  6. package/bin/cli/agent/Init.js +4 -2
  7. package/bin/cli/agent/Init.js.map +1 -1
  8. package/bin/cli/agent/Run.d.ts.map +1 -1
  9. package/bin/cli/agent/Run.js +4 -1
  10. package/bin/cli/agent/Run.js.map +1 -1
  11. package/bin/cli/control-plane/ControlPlaneInit.js +1 -1
  12. package/bin/cli/control-plane/ControlPlaneInit.js.map +1 -1
  13. package/bin/cli/control-plane/ControlPlaneProcess.d.ts.map +1 -1
  14. package/bin/cli/control-plane/ControlPlaneProcess.js +2 -1
  15. package/bin/cli/control-plane/ControlPlaneProcess.js.map +1 -1
  16. package/bin/cli/model/ModelCommandShared.d.ts +1 -1
  17. package/bin/cli/model/ModelCommandShared.d.ts.map +1 -1
  18. package/bin/cli/model/ModelCommandShared.js +1 -1
  19. package/bin/cli/model/ModelCommandShared.js.map +1 -1
  20. package/bin/cli/model/ModelCreateCommand.js +1 -1
  21. package/bin/cli/model/ModelCreateCommand.js.map +1 -1
  22. package/bin/cli/model/ModelManager.js +1 -1
  23. package/bin/cli/model/ModelManager.js.map +1 -1
  24. package/bin/cli/model/ModelReadCommand.js +1 -1
  25. package/bin/cli/model/ModelReadCommand.js.map +1 -1
  26. package/bin/cli/service/ServiceCommandSupport.d.ts.map +1 -1
  27. package/bin/cli/service/ServiceCommandSupport.js +2 -1
  28. package/bin/cli/service/ServiceCommandSupport.js.map +1 -1
  29. package/bin/cli/shared/ChatAuth.d.ts.map +1 -1
  30. package/bin/cli/shared/ChatAuth.js +6 -5
  31. package/bin/cli/shared/ChatAuth.js.map +1 -1
  32. package/bin/cli/shared/ChatManager.d.ts.map +1 -1
  33. package/bin/cli/shared/ChatManager.js +11 -7
  34. package/bin/cli/shared/ChatManager.js.map +1 -1
  35. package/bin/cli/shared/Env.js +1 -1
  36. package/bin/cli/shared/Env.js.map +1 -1
  37. package/bin/cli/shared/Plugins.js +2 -1
  38. package/bin/cli/shared/Plugins.js.map +1 -1
  39. package/bin/cli/shared/PublicHostEnv.js +1 -1
  40. package/bin/cli/shared/PublicHostEnv.js.map +1 -1
  41. package/bin/config/Paths.d.ts +1 -5
  42. package/bin/config/Paths.d.ts.map +1 -1
  43. package/bin/config/Paths.js +2 -8
  44. package/bin/config/Paths.js.map +1 -1
  45. package/bin/control/ChannelAccountApiRoutes.d.ts.map +1 -1
  46. package/bin/control/ChannelAccountApiRoutes.js +2 -1
  47. package/bin/control/ChannelAccountApiRoutes.js.map +1 -1
  48. package/bin/control/EnvApiRoutes.js +1 -1
  49. package/bin/control/EnvApiRoutes.js.map +1 -1
  50. package/bin/control/ModelApiRoutes.js +1 -1
  51. package/bin/control/ModelApiRoutes.js.map +1 -1
  52. package/bin/control/ModelPoolService.js +1 -1
  53. package/bin/control/ModelPoolService.js.map +1 -1
  54. package/bin/control/PluginApiRoutes.d.ts.map +1 -1
  55. package/bin/control/PluginApiRoutes.js +2 -1
  56. package/bin/control/PluginApiRoutes.js.map +1 -1
  57. package/bin/control/gateway/AgentActions.d.ts.map +1 -1
  58. package/bin/control/gateway/AgentActions.js +4 -3
  59. package/bin/control/gateway/AgentActions.js.map +1 -1
  60. package/bin/control/gateway/AgentCatalog.js +4 -4
  61. package/bin/control/gateway/AgentCatalog.js.map +1 -1
  62. package/bin/http/auth/AuthService.d.ts.map +1 -1
  63. package/bin/http/auth/AuthService.js +1 -1
  64. package/bin/http/auth/AuthService.js.map +1 -1
  65. package/bin/http/auth/AuthStore.js +2 -2
  66. package/bin/http/auth/AuthStore.js.map +1 -1
  67. package/bin/platform/PluginLifecycle.d.ts +51 -0
  68. package/bin/platform/PluginLifecycle.d.ts.map +1 -0
  69. package/bin/platform/PluginLifecycle.js +98 -0
  70. package/bin/platform/PluginLifecycle.js.map +1 -0
  71. package/bin/platform/chatAuthorization/Store.d.ts +31 -0
  72. package/bin/platform/chatAuthorization/Store.d.ts.map +1 -0
  73. package/bin/platform/chatAuthorization/Store.js +145 -0
  74. package/bin/platform/chatAuthorization/Store.js.map +1 -0
  75. package/bin/platform/store/StoreChannelAccountRepository.d.ts +34 -0
  76. package/bin/platform/store/StoreChannelAccountRepository.d.ts.map +1 -0
  77. package/bin/platform/store/StoreChannelAccountRepository.js +198 -0
  78. package/bin/platform/store/StoreChannelAccountRepository.js.map +1 -0
  79. package/bin/platform/store/StoreEnvRepository.d.ts +98 -0
  80. package/bin/platform/store/StoreEnvRepository.d.ts.map +1 -0
  81. package/bin/platform/store/StoreEnvRepository.js +334 -0
  82. package/bin/platform/store/StoreEnvRepository.js.map +1 -0
  83. package/bin/platform/store/StoreModelRepository.d.ts +61 -0
  84. package/bin/platform/store/StoreModelRepository.d.ts.map +1 -0
  85. package/bin/platform/store/StoreModelRepository.js +278 -0
  86. package/bin/platform/store/StoreModelRepository.js.map +1 -0
  87. package/bin/platform/store/StoreSchema.d.ts +13 -0
  88. package/bin/platform/store/StoreSchema.d.ts.map +1 -0
  89. package/bin/platform/store/StoreSchema.js +319 -0
  90. package/bin/platform/store/StoreSchema.js.map +1 -0
  91. package/bin/platform/store/StoreSecureSettings.d.ts +33 -0
  92. package/bin/platform/store/StoreSecureSettings.d.ts.map +1 -0
  93. package/bin/platform/store/StoreSecureSettings.js +91 -0
  94. package/bin/platform/store/StoreSecureSettings.js.map +1 -0
  95. package/bin/platform/store/StoreShared.d.ts +44 -0
  96. package/bin/platform/store/StoreShared.d.ts.map +1 -0
  97. package/bin/platform/store/StoreShared.js +40 -0
  98. package/bin/platform/store/StoreShared.js.map +1 -0
  99. package/bin/platform/store/crypto.d.ts +24 -0
  100. package/bin/platform/store/crypto.d.ts.map +1 -0
  101. package/bin/platform/store/crypto.js +101 -0
  102. package/bin/platform/store/crypto.js.map +1 -0
  103. package/bin/platform/store/index.d.ts +230 -0
  104. package/bin/platform/store/index.d.ts.map +1 -0
  105. package/bin/platform/store/index.js +360 -0
  106. package/bin/platform/store/index.js.map +1 -0
  107. package/bin/platform/store/schema.d.ts +690 -0
  108. package/bin/platform/store/schema.d.ts.map +1 -0
  109. package/bin/platform/store/schema.js +81 -0
  110. package/bin/platform/store/schema.js.map +1 -0
  111. package/bin/process/registry/AgentHostRuntime.d.ts +9 -1
  112. package/bin/process/registry/AgentHostRuntime.d.ts.map +1 -1
  113. package/bin/process/registry/AgentHostRuntime.js +77 -3
  114. package/bin/process/registry/AgentHostRuntime.js.map +1 -1
  115. package/package.json +2 -2
  116. package/src/cli/agent/AgentManager.ts +1 -1
  117. package/src/cli/agent/AgentReset.ts +1 -1
  118. package/src/cli/agent/Init.ts +13 -8
  119. package/src/cli/agent/Run.ts +4 -1
  120. package/src/cli/control-plane/ControlPlaneInit.ts +1 -1
  121. package/src/cli/control-plane/ControlPlaneProcess.ts +2 -1
  122. package/src/cli/model/ModelCommandShared.ts +1 -1
  123. package/src/cli/model/ModelCreateCommand.ts +1 -1
  124. package/src/cli/model/ModelManager.ts +1 -1
  125. package/src/cli/model/ModelReadCommand.ts +1 -1
  126. package/src/cli/service/ServiceCommandSupport.ts +2 -1
  127. package/src/cli/shared/ChatAuth.ts +5 -6
  128. package/src/cli/shared/ChatManager.ts +12 -7
  129. package/src/cli/shared/Env.ts +1 -1
  130. package/src/cli/shared/Plugins.ts +1 -1
  131. package/src/cli/shared/PublicHostEnv.ts +1 -1
  132. package/src/config/Paths.ts +2 -9
  133. package/src/control/ChannelAccountApiRoutes.ts +2 -1
  134. package/src/control/EnvApiRoutes.ts +1 -1
  135. package/src/control/ModelApiRoutes.ts +1 -1
  136. package/src/control/ModelPoolService.ts +1 -1
  137. package/src/control/PluginApiRoutes.ts +4 -2
  138. package/src/control/gateway/AgentActions.ts +24 -17
  139. package/src/control/gateway/AgentCatalog.ts +4 -4
  140. package/src/http/auth/AuthService.ts +1 -1
  141. package/src/http/auth/AuthStore.ts +2 -2
  142. package/src/platform/PluginLifecycle.ts +132 -0
  143. package/src/platform/chatAuthorization/Store.ts +181 -0
  144. package/src/platform/store/StoreChannelAccountRepository.ts +269 -0
  145. package/src/platform/store/StoreEnvRepository.ts +452 -0
  146. package/src/platform/store/StoreModelRepository.ts +324 -0
  147. package/src/platform/store/StoreSchema.ts +344 -0
  148. package/src/platform/store/StoreSecureSettings.ts +126 -0
  149. package/src/platform/store/StoreShared.ts +67 -0
  150. package/src/platform/store/crypto.ts +112 -0
  151. package/src/platform/store/index.ts +497 -0
  152. package/src/platform/store/schema.ts +103 -0
  153. package/src/process/registry/AgentHostRuntime.ts +79 -3
@@ -0,0 +1,690 @@
1
+ export declare const modelProvidersTable: import("drizzle-orm/sqlite-core").SQLiteTableWithColumns<{
2
+ name: "model_providers";
3
+ schema: undefined;
4
+ columns: {
5
+ id: import("drizzle-orm/sqlite-core").SQLiteColumn<{
6
+ name: "id";
7
+ tableName: "model_providers";
8
+ dataType: "string";
9
+ columnType: "SQLiteText";
10
+ data: string;
11
+ driverParam: string;
12
+ notNull: true;
13
+ hasDefault: false;
14
+ isPrimaryKey: true;
15
+ isAutoincrement: false;
16
+ hasRuntimeDefault: false;
17
+ enumValues: [string, ...string[]];
18
+ baseColumn: never;
19
+ identity: undefined;
20
+ generated: undefined;
21
+ }, object>;
22
+ type: import("drizzle-orm/sqlite-core").SQLiteColumn<{
23
+ name: "type";
24
+ tableName: "model_providers";
25
+ dataType: "string";
26
+ columnType: "SQLiteText";
27
+ data: string;
28
+ driverParam: string;
29
+ notNull: true;
30
+ hasDefault: false;
31
+ isPrimaryKey: false;
32
+ isAutoincrement: false;
33
+ hasRuntimeDefault: false;
34
+ enumValues: [string, ...string[]];
35
+ baseColumn: never;
36
+ identity: undefined;
37
+ generated: undefined;
38
+ }, object>;
39
+ baseUrl: import("drizzle-orm/sqlite-core").SQLiteColumn<{
40
+ name: "base_url";
41
+ tableName: "model_providers";
42
+ dataType: "string";
43
+ columnType: "SQLiteText";
44
+ data: string;
45
+ driverParam: string;
46
+ notNull: false;
47
+ hasDefault: false;
48
+ isPrimaryKey: false;
49
+ isAutoincrement: false;
50
+ hasRuntimeDefault: false;
51
+ enumValues: [string, ...string[]];
52
+ baseColumn: never;
53
+ identity: undefined;
54
+ generated: undefined;
55
+ }, object>;
56
+ apiKeyEncrypted: import("drizzle-orm/sqlite-core").SQLiteColumn<{
57
+ name: "api_key_encrypted";
58
+ tableName: "model_providers";
59
+ dataType: "string";
60
+ columnType: "SQLiteText";
61
+ data: string;
62
+ driverParam: string;
63
+ notNull: false;
64
+ hasDefault: false;
65
+ isPrimaryKey: false;
66
+ isAutoincrement: false;
67
+ hasRuntimeDefault: false;
68
+ enumValues: [string, ...string[]];
69
+ baseColumn: never;
70
+ identity: undefined;
71
+ generated: undefined;
72
+ }, object>;
73
+ createdAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
74
+ name: "created_at";
75
+ tableName: "model_providers";
76
+ dataType: "string";
77
+ columnType: "SQLiteText";
78
+ data: string;
79
+ driverParam: string;
80
+ notNull: true;
81
+ hasDefault: false;
82
+ isPrimaryKey: false;
83
+ isAutoincrement: false;
84
+ hasRuntimeDefault: false;
85
+ enumValues: [string, ...string[]];
86
+ baseColumn: never;
87
+ identity: undefined;
88
+ generated: undefined;
89
+ }, object>;
90
+ updatedAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
91
+ name: "updated_at";
92
+ tableName: "model_providers";
93
+ dataType: "string";
94
+ columnType: "SQLiteText";
95
+ data: string;
96
+ driverParam: string;
97
+ notNull: true;
98
+ hasDefault: false;
99
+ isPrimaryKey: false;
100
+ isAutoincrement: false;
101
+ hasRuntimeDefault: false;
102
+ enumValues: [string, ...string[]];
103
+ baseColumn: never;
104
+ identity: undefined;
105
+ generated: undefined;
106
+ }, object>;
107
+ };
108
+ dialect: "sqlite";
109
+ }>;
110
+ export declare const modelsTable: import("drizzle-orm/sqlite-core").SQLiteTableWithColumns<{
111
+ name: "models";
112
+ schema: undefined;
113
+ columns: {
114
+ id: import("drizzle-orm/sqlite-core").SQLiteColumn<{
115
+ name: "id";
116
+ tableName: "models";
117
+ dataType: "string";
118
+ columnType: "SQLiteText";
119
+ data: string;
120
+ driverParam: string;
121
+ notNull: true;
122
+ hasDefault: false;
123
+ isPrimaryKey: true;
124
+ isAutoincrement: false;
125
+ hasRuntimeDefault: false;
126
+ enumValues: [string, ...string[]];
127
+ baseColumn: never;
128
+ identity: undefined;
129
+ generated: undefined;
130
+ }, object>;
131
+ providerId: import("drizzle-orm/sqlite-core").SQLiteColumn<{
132
+ name: "provider_id";
133
+ tableName: "models";
134
+ dataType: "string";
135
+ columnType: "SQLiteText";
136
+ data: string;
137
+ driverParam: string;
138
+ notNull: true;
139
+ hasDefault: false;
140
+ isPrimaryKey: false;
141
+ isAutoincrement: false;
142
+ hasRuntimeDefault: false;
143
+ enumValues: [string, ...string[]];
144
+ baseColumn: never;
145
+ identity: undefined;
146
+ generated: undefined;
147
+ }, object>;
148
+ name: import("drizzle-orm/sqlite-core").SQLiteColumn<{
149
+ name: "name";
150
+ tableName: "models";
151
+ dataType: "string";
152
+ columnType: "SQLiteText";
153
+ data: string;
154
+ driverParam: string;
155
+ notNull: true;
156
+ hasDefault: false;
157
+ isPrimaryKey: false;
158
+ isAutoincrement: false;
159
+ hasRuntimeDefault: false;
160
+ enumValues: [string, ...string[]];
161
+ baseColumn: never;
162
+ identity: undefined;
163
+ generated: undefined;
164
+ }, object>;
165
+ temperature: import("drizzle-orm/sqlite-core").SQLiteColumn<{
166
+ name: "temperature";
167
+ tableName: "models";
168
+ dataType: "number";
169
+ columnType: "SQLiteReal";
170
+ data: number;
171
+ driverParam: number;
172
+ notNull: false;
173
+ hasDefault: false;
174
+ isPrimaryKey: false;
175
+ isAutoincrement: false;
176
+ hasRuntimeDefault: false;
177
+ enumValues: undefined;
178
+ baseColumn: never;
179
+ identity: undefined;
180
+ generated: undefined;
181
+ }, object>;
182
+ maxTokens: import("drizzle-orm/sqlite-core").SQLiteColumn<{
183
+ name: "max_tokens";
184
+ tableName: "models";
185
+ dataType: "number";
186
+ columnType: "SQLiteInteger";
187
+ data: number;
188
+ driverParam: number;
189
+ notNull: false;
190
+ hasDefault: false;
191
+ isPrimaryKey: false;
192
+ isAutoincrement: false;
193
+ hasRuntimeDefault: false;
194
+ enumValues: undefined;
195
+ baseColumn: never;
196
+ identity: undefined;
197
+ generated: undefined;
198
+ }, object>;
199
+ topP: import("drizzle-orm/sqlite-core").SQLiteColumn<{
200
+ name: "top_p";
201
+ tableName: "models";
202
+ dataType: "number";
203
+ columnType: "SQLiteReal";
204
+ data: number;
205
+ driverParam: number;
206
+ notNull: false;
207
+ hasDefault: false;
208
+ isPrimaryKey: false;
209
+ isAutoincrement: false;
210
+ hasRuntimeDefault: false;
211
+ enumValues: undefined;
212
+ baseColumn: never;
213
+ identity: undefined;
214
+ generated: undefined;
215
+ }, object>;
216
+ frequencyPenalty: import("drizzle-orm/sqlite-core").SQLiteColumn<{
217
+ name: "frequency_penalty";
218
+ tableName: "models";
219
+ dataType: "number";
220
+ columnType: "SQLiteReal";
221
+ data: number;
222
+ driverParam: number;
223
+ notNull: false;
224
+ hasDefault: false;
225
+ isPrimaryKey: false;
226
+ isAutoincrement: false;
227
+ hasRuntimeDefault: false;
228
+ enumValues: undefined;
229
+ baseColumn: never;
230
+ identity: undefined;
231
+ generated: undefined;
232
+ }, object>;
233
+ presencePenalty: import("drizzle-orm/sqlite-core").SQLiteColumn<{
234
+ name: "presence_penalty";
235
+ tableName: "models";
236
+ dataType: "number";
237
+ columnType: "SQLiteReal";
238
+ data: number;
239
+ driverParam: number;
240
+ notNull: false;
241
+ hasDefault: false;
242
+ isPrimaryKey: false;
243
+ isAutoincrement: false;
244
+ hasRuntimeDefault: false;
245
+ enumValues: undefined;
246
+ baseColumn: never;
247
+ identity: undefined;
248
+ generated: undefined;
249
+ }, object>;
250
+ anthropicVersion: import("drizzle-orm/sqlite-core").SQLiteColumn<{
251
+ name: "anthropic_version";
252
+ tableName: "models";
253
+ dataType: "string";
254
+ columnType: "SQLiteText";
255
+ data: string;
256
+ driverParam: string;
257
+ notNull: false;
258
+ hasDefault: false;
259
+ isPrimaryKey: false;
260
+ isAutoincrement: false;
261
+ hasRuntimeDefault: false;
262
+ enumValues: [string, ...string[]];
263
+ baseColumn: never;
264
+ identity: undefined;
265
+ generated: undefined;
266
+ }, object>;
267
+ isPaused: import("drizzle-orm/sqlite-core").SQLiteColumn<{
268
+ name: "is_paused";
269
+ tableName: "models";
270
+ dataType: "number";
271
+ columnType: "SQLiteInteger";
272
+ data: number;
273
+ driverParam: number;
274
+ notNull: true;
275
+ hasDefault: true;
276
+ isPrimaryKey: false;
277
+ isAutoincrement: false;
278
+ hasRuntimeDefault: false;
279
+ enumValues: undefined;
280
+ baseColumn: never;
281
+ identity: undefined;
282
+ generated: undefined;
283
+ }, object>;
284
+ createdAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
285
+ name: "created_at";
286
+ tableName: "models";
287
+ dataType: "string";
288
+ columnType: "SQLiteText";
289
+ data: string;
290
+ driverParam: string;
291
+ notNull: true;
292
+ hasDefault: false;
293
+ isPrimaryKey: false;
294
+ isAutoincrement: false;
295
+ hasRuntimeDefault: false;
296
+ enumValues: [string, ...string[]];
297
+ baseColumn: never;
298
+ identity: undefined;
299
+ generated: undefined;
300
+ }, object>;
301
+ updatedAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
302
+ name: "updated_at";
303
+ tableName: "models";
304
+ dataType: "string";
305
+ columnType: "SQLiteText";
306
+ data: string;
307
+ driverParam: string;
308
+ notNull: true;
309
+ hasDefault: false;
310
+ isPrimaryKey: false;
311
+ isAutoincrement: false;
312
+ hasRuntimeDefault: false;
313
+ enumValues: [string, ...string[]];
314
+ baseColumn: never;
315
+ identity: undefined;
316
+ generated: undefined;
317
+ }, object>;
318
+ };
319
+ dialect: "sqlite";
320
+ }>;
321
+ /**
322
+ * 平台 Env 统一存储表。
323
+ *
324
+ * 关键点(中文)
325
+ * - 全局 env 与 agent env 共用一张表,通过 `scope` + `agentId` 区分。
326
+ * - `agentId` 在 `scope=global` 时固定为空字符串,避免 SQLite 复合主键中的 NULL 语义问题。
327
+ * - value 采用密文存储,解密仅在运行时内存中进行。
328
+ */
329
+ export declare const envEntriesTable: import("drizzle-orm/sqlite-core").SQLiteTableWithColumns<{
330
+ name: "env_entries";
331
+ schema: undefined;
332
+ columns: {
333
+ scope: import("drizzle-orm/sqlite-core").SQLiteColumn<{
334
+ name: "scope";
335
+ tableName: "env_entries";
336
+ dataType: "string";
337
+ columnType: "SQLiteText";
338
+ data: string;
339
+ driverParam: string;
340
+ notNull: true;
341
+ hasDefault: false;
342
+ isPrimaryKey: false;
343
+ isAutoincrement: false;
344
+ hasRuntimeDefault: false;
345
+ enumValues: [string, ...string[]];
346
+ baseColumn: never;
347
+ identity: undefined;
348
+ generated: undefined;
349
+ }, object>;
350
+ agentId: import("drizzle-orm/sqlite-core").SQLiteColumn<{
351
+ name: "agent_id";
352
+ tableName: "env_entries";
353
+ dataType: "string";
354
+ columnType: "SQLiteText";
355
+ data: string;
356
+ driverParam: string;
357
+ notNull: true;
358
+ hasDefault: true;
359
+ isPrimaryKey: false;
360
+ isAutoincrement: false;
361
+ hasRuntimeDefault: false;
362
+ enumValues: [string, ...string[]];
363
+ baseColumn: never;
364
+ identity: undefined;
365
+ generated: undefined;
366
+ }, object>;
367
+ key: import("drizzle-orm/sqlite-core").SQLiteColumn<{
368
+ name: "key";
369
+ tableName: "env_entries";
370
+ dataType: "string";
371
+ columnType: "SQLiteText";
372
+ data: string;
373
+ driverParam: string;
374
+ notNull: true;
375
+ hasDefault: false;
376
+ isPrimaryKey: false;
377
+ isAutoincrement: false;
378
+ hasRuntimeDefault: false;
379
+ enumValues: [string, ...string[]];
380
+ baseColumn: never;
381
+ identity: undefined;
382
+ generated: undefined;
383
+ }, object>;
384
+ description: import("drizzle-orm/sqlite-core").SQLiteColumn<{
385
+ name: "description";
386
+ tableName: "env_entries";
387
+ dataType: "string";
388
+ columnType: "SQLiteText";
389
+ data: string;
390
+ driverParam: string;
391
+ notNull: false;
392
+ hasDefault: false;
393
+ isPrimaryKey: false;
394
+ isAutoincrement: false;
395
+ hasRuntimeDefault: false;
396
+ enumValues: [string, ...string[]];
397
+ baseColumn: never;
398
+ identity: undefined;
399
+ generated: undefined;
400
+ }, object>;
401
+ valueEncrypted: import("drizzle-orm/sqlite-core").SQLiteColumn<{
402
+ name: "value_encrypted";
403
+ tableName: "env_entries";
404
+ dataType: "string";
405
+ columnType: "SQLiteText";
406
+ data: string;
407
+ driverParam: string;
408
+ notNull: true;
409
+ hasDefault: false;
410
+ isPrimaryKey: false;
411
+ isAutoincrement: false;
412
+ hasRuntimeDefault: false;
413
+ enumValues: [string, ...string[]];
414
+ baseColumn: never;
415
+ identity: undefined;
416
+ generated: undefined;
417
+ }, object>;
418
+ createdAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
419
+ name: "created_at";
420
+ tableName: "env_entries";
421
+ dataType: "string";
422
+ columnType: "SQLiteText";
423
+ data: string;
424
+ driverParam: string;
425
+ notNull: true;
426
+ hasDefault: false;
427
+ isPrimaryKey: false;
428
+ isAutoincrement: false;
429
+ hasRuntimeDefault: false;
430
+ enumValues: [string, ...string[]];
431
+ baseColumn: never;
432
+ identity: undefined;
433
+ generated: undefined;
434
+ }, object>;
435
+ updatedAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
436
+ name: "updated_at";
437
+ tableName: "env_entries";
438
+ dataType: "string";
439
+ columnType: "SQLiteText";
440
+ data: string;
441
+ driverParam: string;
442
+ notNull: true;
443
+ hasDefault: false;
444
+ isPrimaryKey: false;
445
+ isAutoincrement: false;
446
+ hasRuntimeDefault: false;
447
+ enumValues: [string, ...string[]];
448
+ baseColumn: never;
449
+ identity: undefined;
450
+ generated: undefined;
451
+ }, object>;
452
+ };
453
+ dialect: "sqlite";
454
+ }>;
455
+ /**
456
+ * Channel Account 表。
457
+ *
458
+ * 关键点(中文)
459
+ * - 各渠道敏感字段独立密文列存储。
460
+ * - `downcity.json` 仅保存 channelAccountId 绑定,不直接保存密钥。
461
+ */
462
+ export declare const channelAccountsTable: import("drizzle-orm/sqlite-core").SQLiteTableWithColumns<{
463
+ name: "channel_accounts";
464
+ schema: undefined;
465
+ columns: {
466
+ id: import("drizzle-orm/sqlite-core").SQLiteColumn<{
467
+ name: "id";
468
+ tableName: "channel_accounts";
469
+ dataType: "string";
470
+ columnType: "SQLiteText";
471
+ data: string;
472
+ driverParam: string;
473
+ notNull: true;
474
+ hasDefault: false;
475
+ isPrimaryKey: true;
476
+ isAutoincrement: false;
477
+ hasRuntimeDefault: false;
478
+ enumValues: [string, ...string[]];
479
+ baseColumn: never;
480
+ identity: undefined;
481
+ generated: undefined;
482
+ }, object>;
483
+ channel: import("drizzle-orm/sqlite-core").SQLiteColumn<{
484
+ name: "channel";
485
+ tableName: "channel_accounts";
486
+ dataType: "string";
487
+ columnType: "SQLiteText";
488
+ data: string;
489
+ driverParam: string;
490
+ notNull: true;
491
+ hasDefault: false;
492
+ isPrimaryKey: false;
493
+ isAutoincrement: false;
494
+ hasRuntimeDefault: false;
495
+ enumValues: [string, ...string[]];
496
+ baseColumn: never;
497
+ identity: undefined;
498
+ generated: undefined;
499
+ }, object>;
500
+ name: import("drizzle-orm/sqlite-core").SQLiteColumn<{
501
+ name: "name";
502
+ tableName: "channel_accounts";
503
+ dataType: "string";
504
+ columnType: "SQLiteText";
505
+ data: string;
506
+ driverParam: string;
507
+ notNull: true;
508
+ hasDefault: false;
509
+ isPrimaryKey: false;
510
+ isAutoincrement: false;
511
+ hasRuntimeDefault: false;
512
+ enumValues: [string, ...string[]];
513
+ baseColumn: never;
514
+ identity: undefined;
515
+ generated: undefined;
516
+ }, object>;
517
+ identity: import("drizzle-orm/sqlite-core").SQLiteColumn<{
518
+ name: "identity";
519
+ tableName: "channel_accounts";
520
+ dataType: "string";
521
+ columnType: "SQLiteText";
522
+ data: string;
523
+ driverParam: string;
524
+ notNull: false;
525
+ hasDefault: false;
526
+ isPrimaryKey: false;
527
+ isAutoincrement: false;
528
+ hasRuntimeDefault: false;
529
+ enumValues: [string, ...string[]];
530
+ baseColumn: never;
531
+ identity: undefined;
532
+ generated: undefined;
533
+ }, object>;
534
+ owner: import("drizzle-orm/sqlite-core").SQLiteColumn<{
535
+ name: "owner";
536
+ tableName: "channel_accounts";
537
+ dataType: "string";
538
+ columnType: "SQLiteText";
539
+ data: string;
540
+ driverParam: string;
541
+ notNull: false;
542
+ hasDefault: false;
543
+ isPrimaryKey: false;
544
+ isAutoincrement: false;
545
+ hasRuntimeDefault: false;
546
+ enumValues: [string, ...string[]];
547
+ baseColumn: never;
548
+ identity: undefined;
549
+ generated: undefined;
550
+ }, object>;
551
+ creator: import("drizzle-orm/sqlite-core").SQLiteColumn<{
552
+ name: "creator";
553
+ tableName: "channel_accounts";
554
+ dataType: "string";
555
+ columnType: "SQLiteText";
556
+ data: string;
557
+ driverParam: string;
558
+ notNull: false;
559
+ hasDefault: false;
560
+ isPrimaryKey: false;
561
+ isAutoincrement: false;
562
+ hasRuntimeDefault: false;
563
+ enumValues: [string, ...string[]];
564
+ baseColumn: never;
565
+ identity: undefined;
566
+ generated: undefined;
567
+ }, object>;
568
+ botTokenEncrypted: import("drizzle-orm/sqlite-core").SQLiteColumn<{
569
+ name: "bot_token_encrypted";
570
+ tableName: "channel_accounts";
571
+ dataType: "string";
572
+ columnType: "SQLiteText";
573
+ data: string;
574
+ driverParam: string;
575
+ notNull: false;
576
+ hasDefault: false;
577
+ isPrimaryKey: false;
578
+ isAutoincrement: false;
579
+ hasRuntimeDefault: false;
580
+ enumValues: [string, ...string[]];
581
+ baseColumn: never;
582
+ identity: undefined;
583
+ generated: undefined;
584
+ }, object>;
585
+ appIdEncrypted: import("drizzle-orm/sqlite-core").SQLiteColumn<{
586
+ name: "app_id_encrypted";
587
+ tableName: "channel_accounts";
588
+ dataType: "string";
589
+ columnType: "SQLiteText";
590
+ data: string;
591
+ driverParam: string;
592
+ notNull: false;
593
+ hasDefault: false;
594
+ isPrimaryKey: false;
595
+ isAutoincrement: false;
596
+ hasRuntimeDefault: false;
597
+ enumValues: [string, ...string[]];
598
+ baseColumn: never;
599
+ identity: undefined;
600
+ generated: undefined;
601
+ }, object>;
602
+ appSecretEncrypted: import("drizzle-orm/sqlite-core").SQLiteColumn<{
603
+ name: "app_secret_encrypted";
604
+ tableName: "channel_accounts";
605
+ dataType: "string";
606
+ columnType: "SQLiteText";
607
+ data: string;
608
+ driverParam: string;
609
+ notNull: false;
610
+ hasDefault: false;
611
+ isPrimaryKey: false;
612
+ isAutoincrement: false;
613
+ hasRuntimeDefault: false;
614
+ enumValues: [string, ...string[]];
615
+ baseColumn: never;
616
+ identity: undefined;
617
+ generated: undefined;
618
+ }, object>;
619
+ domain: import("drizzle-orm/sqlite-core").SQLiteColumn<{
620
+ name: "domain";
621
+ tableName: "channel_accounts";
622
+ dataType: "string";
623
+ columnType: "SQLiteText";
624
+ data: string;
625
+ driverParam: string;
626
+ notNull: false;
627
+ hasDefault: false;
628
+ isPrimaryKey: false;
629
+ isAutoincrement: false;
630
+ hasRuntimeDefault: false;
631
+ enumValues: [string, ...string[]];
632
+ baseColumn: never;
633
+ identity: undefined;
634
+ generated: undefined;
635
+ }, object>;
636
+ sandbox: import("drizzle-orm/sqlite-core").SQLiteColumn<{
637
+ name: "sandbox";
638
+ tableName: "channel_accounts";
639
+ dataType: "number";
640
+ columnType: "SQLiteInteger";
641
+ data: number;
642
+ driverParam: number;
643
+ notNull: false;
644
+ hasDefault: false;
645
+ isPrimaryKey: false;
646
+ isAutoincrement: false;
647
+ hasRuntimeDefault: false;
648
+ enumValues: undefined;
649
+ baseColumn: never;
650
+ identity: undefined;
651
+ generated: undefined;
652
+ }, object>;
653
+ createdAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
654
+ name: "created_at";
655
+ tableName: "channel_accounts";
656
+ dataType: "string";
657
+ columnType: "SQLiteText";
658
+ data: string;
659
+ driverParam: string;
660
+ notNull: true;
661
+ hasDefault: false;
662
+ isPrimaryKey: false;
663
+ isAutoincrement: false;
664
+ hasRuntimeDefault: false;
665
+ enumValues: [string, ...string[]];
666
+ baseColumn: never;
667
+ identity: undefined;
668
+ generated: undefined;
669
+ }, object>;
670
+ updatedAt: import("drizzle-orm/sqlite-core").SQLiteColumn<{
671
+ name: "updated_at";
672
+ tableName: "channel_accounts";
673
+ dataType: "string";
674
+ columnType: "SQLiteText";
675
+ data: string;
676
+ driverParam: string;
677
+ notNull: true;
678
+ hasDefault: false;
679
+ isPrimaryKey: false;
680
+ isAutoincrement: false;
681
+ hasRuntimeDefault: false;
682
+ enumValues: [string, ...string[]];
683
+ baseColumn: never;
684
+ identity: undefined;
685
+ generated: undefined;
686
+ }, object>;
687
+ };
688
+ dialect: "sqlite";
689
+ }>;
690
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../src/platform/store/schema.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAO9B,CAAC;AAEH,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmBvB,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmB3B,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoBhC,CAAC"}