@columnus/shared 0.1.47

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 (206) hide show
  1. package/LICENSE +21 -0
  2. package/dist/apiProfile.d.ts +1072 -0
  3. package/dist/apiProfile.js +4210 -0
  4. package/dist/apiProfile.js.map +1 -0
  5. package/dist/apiProfileSlug.d.ts +11 -0
  6. package/dist/apiProfileSlug.js +39 -0
  7. package/dist/apiProfileSlug.js.map +1 -0
  8. package/dist/apiToken.d.ts +6 -0
  9. package/dist/apiToken.js +35 -0
  10. package/dist/apiToken.js.map +1 -0
  11. package/dist/betterAuthSession.d.ts +8 -0
  12. package/dist/betterAuthSession.js +57 -0
  13. package/dist/betterAuthSession.js.map +1 -0
  14. package/dist/bffHost.d.ts +36 -0
  15. package/dist/bffHost.js +74 -0
  16. package/dist/bffHost.js.map +1 -0
  17. package/dist/bffProtocol.d.ts +1357 -0
  18. package/dist/bffProtocol.js +4362 -0
  19. package/dist/bffProtocol.js.map +1 -0
  20. package/dist/bffRedact.d.ts +30 -0
  21. package/dist/bffRedact.js +55 -0
  22. package/dist/bffRedact.js.map +1 -0
  23. package/dist/ciPreviewEnv.d.ts +49 -0
  24. package/dist/ciPreviewEnv.js +143 -0
  25. package/dist/ciPreviewEnv.js.map +1 -0
  26. package/dist/clipboardTransfer.d.ts +25 -0
  27. package/dist/clipboardTransfer.js +4862 -0
  28. package/dist/clipboardTransfer.js.map +1 -0
  29. package/dist/convexSiteUrl.d.ts +73 -0
  30. package/dist/convexSiteUrl.js +137 -0
  31. package/dist/convexSiteUrl.js.map +1 -0
  32. package/dist/csv.d.ts +54 -0
  33. package/dist/csv.js +5499 -0
  34. package/dist/csv.js.map +1 -0
  35. package/dist/dataTransfer.d.ts +21 -0
  36. package/dist/dataTransfer.js +74 -0
  37. package/dist/dataTransfer.js.map +1 -0
  38. package/dist/dateValues.d.ts +18 -0
  39. package/dist/dateValues.js +73 -0
  40. package/dist/dateValues.js.map +1 -0
  41. package/dist/deployOutput.d.ts +3 -0
  42. package/dist/deployOutput.js +23 -0
  43. package/dist/deployOutput.js.map +1 -0
  44. package/dist/displayLabel.d.ts +13 -0
  45. package/dist/displayLabel.js +4342 -0
  46. package/dist/displayLabel.js.map +1 -0
  47. package/dist/displayTemplateGenerator.d.ts +11 -0
  48. package/dist/displayTemplateGenerator.js +98 -0
  49. package/dist/displayTemplateGenerator.js.map +1 -0
  50. package/dist/displayTypes.d.ts +10 -0
  51. package/dist/displayTypes.js +3 -0
  52. package/dist/displayTypes.js.map +1 -0
  53. package/dist/dotenv.d.ts +8 -0
  54. package/dist/dotenv.js +61 -0
  55. package/dist/dotenv.js.map +1 -0
  56. package/dist/erdLayout.d.ts +27 -0
  57. package/dist/erdLayout.js +78 -0
  58. package/dist/erdLayout.js.map +1 -0
  59. package/dist/fieldTypeFormat.d.ts +5 -0
  60. package/dist/fieldTypeFormat.js +63 -0
  61. package/dist/fieldTypeFormat.js.map +1 -0
  62. package/dist/fieldTypeMeta.d.ts +50 -0
  63. package/dist/fieldTypeMeta.js +84 -0
  64. package/dist/fieldTypeMeta.js.map +1 -0
  65. package/dist/fieldValueEqual.d.ts +4 -0
  66. package/dist/fieldValueEqual.js +58 -0
  67. package/dist/fieldValueEqual.js.map +1 -0
  68. package/dist/importMatch.d.ts +80 -0
  69. package/dist/importMatch.js +5643 -0
  70. package/dist/importMatch.js.map +1 -0
  71. package/dist/index.d.ts +58 -0
  72. package/dist/index.js +10647 -0
  73. package/dist/index.js.map +1 -0
  74. package/dist/inferIdentifier.d.ts +18 -0
  75. package/dist/inferIdentifier.js +49 -0
  76. package/dist/inferIdentifier.js.map +1 -0
  77. package/dist/keyboard.d.ts +16 -0
  78. package/dist/keyboard.js +71 -0
  79. package/dist/keyboard.js.map +1 -0
  80. package/dist/manifestDeploy.d.ts +27 -0
  81. package/dist/manifestDeploy.js +16 -0
  82. package/dist/manifestDeploy.js.map +1 -0
  83. package/dist/manifestHash.d.ts +11 -0
  84. package/dist/manifestHash.js +35 -0
  85. package/dist/manifestHash.js.map +1 -0
  86. package/dist/previewDeployName.d.ts +26 -0
  87. package/dist/previewDeployName.js +77 -0
  88. package/dist/previewDeployName.js.map +1 -0
  89. package/dist/proposePolicy.d.ts +17 -0
  90. package/dist/proposePolicy.js +33 -0
  91. package/dist/proposePolicy.js.map +1 -0
  92. package/dist/queryBetween.d.ts +20 -0
  93. package/dist/queryBetween.js +28 -0
  94. package/dist/queryBetween.js.map +1 -0
  95. package/dist/queryExecution.d.ts +5 -0
  96. package/dist/queryExecution.js +58 -0
  97. package/dist/queryExecution.js.map +1 -0
  98. package/dist/queryFieldOps.d.ts +66 -0
  99. package/dist/queryFieldOps.js +138 -0
  100. package/dist/queryFieldOps.js.map +1 -0
  101. package/dist/queryMerge.d.ts +29 -0
  102. package/dist/queryMerge.js +4277 -0
  103. package/dist/queryMerge.js.map +1 -0
  104. package/dist/queryPlan.d.ts +97 -0
  105. package/dist/queryPlan.js +4564 -0
  106. package/dist/queryPlan.js.map +1 -0
  107. package/dist/queryStudio.d.ts +25 -0
  108. package/dist/queryStudio.js +4658 -0
  109. package/dist/queryStudio.js.map +1 -0
  110. package/dist/queryTypes.d.ts +402 -0
  111. package/dist/queryTypes.js +4239 -0
  112. package/dist/queryTypes.js.map +1 -0
  113. package/dist/queryValidators.d.ts +99 -0
  114. package/dist/queryValidators.js +76 -0
  115. package/dist/queryValidators.js.map +1 -0
  116. package/dist/readApiQuery.d.ts +10 -0
  117. package/dist/readApiQuery.js +24 -0
  118. package/dist/readApiQuery.js.map +1 -0
  119. package/dist/recordTableColumns.d.ts +21 -0
  120. package/dist/recordTableColumns.js +4469 -0
  121. package/dist/recordTableColumns.js.map +1 -0
  122. package/dist/refDisplayRequests.d.ts +17 -0
  123. package/dist/refDisplayRequests.js +4877 -0
  124. package/dist/refDisplayRequests.js.map +1 -0
  125. package/dist/refGraph.d.ts +23 -0
  126. package/dist/refGraph.js +102 -0
  127. package/dist/refGraph.js.map +1 -0
  128. package/dist/refsRecompute.d.ts +8 -0
  129. package/dist/refsRecompute.js +12 -0
  130. package/dist/refsRecompute.js.map +1 -0
  131. package/dist/richDoc.d.ts +67 -0
  132. package/dist/richDoc.js +4408 -0
  133. package/dist/richDoc.js.map +1 -0
  134. package/dist/schemaGenerator.d.ts +31 -0
  135. package/dist/schemaGenerator.js +198 -0
  136. package/dist/schemaGenerator.js.map +1 -0
  137. package/dist/schemaShrink.d.ts +74 -0
  138. package/dist/schemaShrink.js +132 -0
  139. package/dist/schemaShrink.js.map +1 -0
  140. package/dist/schemaShrinkValidators.d.ts +72 -0
  141. package/dist/schemaShrinkValidators.js +31 -0
  142. package/dist/schemaShrinkValidators.js.map +1 -0
  143. package/dist/schemaTypes.d.ts +454 -0
  144. package/dist/schemaTypes.js +4557 -0
  145. package/dist/schemaTypes.js.map +1 -0
  146. package/dist/share.d.ts +8 -0
  147. package/dist/share.js +4755 -0
  148. package/dist/share.js.map +1 -0
  149. package/dist/shareApiBridge.d.ts +18 -0
  150. package/dist/shareApiBridge.js +4283 -0
  151. package/dist/shareApiBridge.js.map +1 -0
  152. package/dist/shareGuestPolicy.d.ts +14 -0
  153. package/dist/shareGuestPolicy.js +90 -0
  154. package/dist/shareGuestPolicy.js.map +1 -0
  155. package/dist/shareProposal.d.ts +113 -0
  156. package/dist/shareProposal.js +4810 -0
  157. package/dist/shareProposal.js.map +1 -0
  158. package/dist/shareProposalDiff.d.ts +13 -0
  159. package/dist/shareProposalDiff.js +91 -0
  160. package/dist/shareProposalDiff.js.map +1 -0
  161. package/dist/shareScopes.d.ts +14 -0
  162. package/dist/shareScopes.js +223 -0
  163. package/dist/shareScopes.js.map +1 -0
  164. package/dist/shareTokenCrypto.d.ts +9 -0
  165. package/dist/shareTokenCrypto.js +87 -0
  166. package/dist/shareTokenCrypto.js.map +1 -0
  167. package/dist/shareTokens.d.ts +6 -0
  168. package/dist/shareTokens.js +26 -0
  169. package/dist/shareTokens.js.map +1 -0
  170. package/dist/shareTypes.d.ts +107 -0
  171. package/dist/shareTypes.js +3 -0
  172. package/dist/shareTypes.js.map +1 -0
  173. package/dist/shareValidators.d.ts +168 -0
  174. package/dist/shareValidators.js +124 -0
  175. package/dist/shareValidators.js.map +1 -0
  176. package/dist/shareWizard.d.ts +14 -0
  177. package/dist/shareWizard.js +200 -0
  178. package/dist/shareWizard.js.map +1 -0
  179. package/dist/spaceBundle.d.ts +67 -0
  180. package/dist/spaceBundle.js +4664 -0
  181. package/dist/spaceBundle.js.map +1 -0
  182. package/dist/storageFieldValues.d.ts +10 -0
  183. package/dist/storageFieldValues.js +4421 -0
  184. package/dist/storageFieldValues.js.map +1 -0
  185. package/dist/studioBoot.d.ts +49 -0
  186. package/dist/studioBoot.js +167 -0
  187. package/dist/studioBoot.js.map +1 -0
  188. package/dist/syncClampMembership.d.ts +22 -0
  189. package/dist/syncClampMembership.js +74 -0
  190. package/dist/syncClampMembership.js.map +1 -0
  191. package/dist/tenantHosts.d.ts +30 -0
  192. package/dist/tenantHosts.js +60 -0
  193. package/dist/tenantHosts.js.map +1 -0
  194. package/dist/tenantSecretsCrypto.d.ts +31 -0
  195. package/dist/tenantSecretsCrypto.js +145 -0
  196. package/dist/tenantSecretsCrypto.js.map +1 -0
  197. package/dist/useDebouncedCommit.d.ts +11 -0
  198. package/dist/useDebouncedCommit.js +34 -0
  199. package/dist/useDebouncedCommit.js.map +1 -0
  200. package/dist/useDebouncedValue.d.ts +1 -0
  201. package/dist/useDebouncedValue.js +15 -0
  202. package/dist/useDebouncedValue.js.map +1 -0
  203. package/dist/useModifierHeld.d.ts +2 -0
  204. package/dist/useModifierHeld.js +28 -0
  205. package/dist/useModifierHeld.js.map +1 -0
  206. package/package.json +36 -0
@@ -0,0 +1,1357 @@
1
+ import { z } from "zod";
2
+ import { MAX_TRANSFER_BYTES } from "./dataTransfer.ts";
3
+ /** Versioned BFF ↔ Management ↔ deploy-service contract (D32). */
4
+ export declare const COLUMNUS_BFF_PROTOCOL_VERSION: 1;
5
+ export declare const COLUMNUS_BFF_API_PREFIX: "/api/columnus/v1";
6
+ export declare const COLUMNUS_BFF_MANAGEMENT_PREFIX: "/internal/columnus-bff/v1";
7
+ export declare const COLUMNUS_DEPLOY_INTERNAL_PREFIX: "/internal/v1";
8
+ export declare const COLUMNUS_DEPLOY_OPS_PREFIX: "/ops/v1";
9
+ /** Header carrying COLUMNUS_BFF_MANAGEMENT_SECRET (D6). */
10
+ export declare const COLUMNUS_BFF_MANAGEMENT_SECRET_HEADER: "x-columnus-bff-management-secret";
11
+ /** Header carrying COLUMNUS_PREVIEW_REGISTRATION_SECRET (D25). */
12
+ export declare const COLUMNUS_PREVIEW_REGISTRATION_SECRET_HEADER: "x-columnus-preview-registration-secret";
13
+ /** Caller-generated operation / idempotency IDs (not authorization credentials). */
14
+ export declare const OPERATION_ID_RE: RegExp;
15
+ /** Server-issued random transfer IDs (D10) — not signed bearer tokens. */
16
+ export declare const TRANSFER_ID_RE: RegExp;
17
+ export declare const MANIFEST_HASH_RE: RegExp;
18
+ export declare const TABLE_NAME_RE: RegExp;
19
+ export declare const operationIdSchema: z.ZodString;
20
+ export declare const transferIdSchema: z.ZodString;
21
+ export declare const manifestHashSchema: z.ZodString;
22
+ export declare const bffPrepareOperationTypeSchema: z.ZodEnum<["schemaDeploy", "dataExport", "dataImportPrepare", "dataImportCommit"]>;
23
+ export type BffPrepareOperationType = z.infer<typeof bffPrepareOperationTypeSchema>;
24
+ export declare const transferOperationSchema: z.ZodEnum<["export", "import"]>;
25
+ export type TransferOperation = z.infer<typeof transferOperationSchema>;
26
+ export declare const transferSessionStateSchema: z.ZodEnum<["exportReady", "importAwaitingUpload", "importUploaded", "importCommitted", "importFailed", "expired"]>;
27
+ export type TransferSessionState = z.infer<typeof transferSessionStateSchema>;
28
+ export declare const schemaDeployPhaseSchema: z.ZodEnum<["cleaning", "ready", "deploying", "succeeded", "failed"]>;
29
+ export type SchemaDeployPhase = z.infer<typeof schemaDeployPhaseSchema>;
30
+ /** Active schema operations hold this lease before a new operation may supersede them. */
31
+ export declare const SCHEMA_DEPLOY_OPERATION_LEASE_MS: number;
32
+ export declare function isSchemaDeployPhaseActive(phase: string | undefined): boolean;
33
+ export declare function hasSchemaDeployOperationLeaseExpired(startedAt: number | undefined, now: number): boolean;
34
+ /** Cryptographically random ID suitable for operationId / transferId. */
35
+ export declare function createRandomId(byteLength?: number): string;
36
+ export declare function createOperationId(): string;
37
+ export declare function createTransferId(): string;
38
+ export declare function isOperationId(value: string): boolean;
39
+ export declare function isTransferId(value: string): boolean;
40
+ export declare function isManifestHash(value: string): boolean;
41
+ /** True when completion should apply: same operation and matching desired hash. */
42
+ export declare function matchesDeployCompletion(args: {
43
+ activeOperationId: string | undefined;
44
+ activeDesiredHash: string | undefined;
45
+ completionOperationId: string;
46
+ completionManifestHash: string;
47
+ }): boolean;
48
+ export declare const dataTransferManifestSchema: z.ZodEffects<z.ZodObject<{
49
+ version: z.ZodLiteral<1>;
50
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
51
+ schemaHash: z.ZodString;
52
+ includeFileStorage: z.ZodBoolean;
53
+ }, "strip", z.ZodTypeAny, {
54
+ tables: string[];
55
+ version: 1;
56
+ schemaHash: string;
57
+ includeFileStorage: boolean;
58
+ }, {
59
+ tables: string[];
60
+ version: 1;
61
+ schemaHash: string;
62
+ includeFileStorage: boolean;
63
+ }>, {
64
+ tables: string[];
65
+ version: 1;
66
+ schemaHash: string;
67
+ includeFileStorage: boolean;
68
+ }, {
69
+ tables: string[];
70
+ version: 1;
71
+ schemaHash: string;
72
+ includeFileStorage: boolean;
73
+ }>;
74
+ export type DataTransferManifestV1 = z.infer<typeof dataTransferManifestSchema>;
75
+ export declare const bffSchemaDeployRequestSchema: z.ZodObject<{
76
+ operationId: z.ZodString;
77
+ manifestJson: z.ZodString;
78
+ }, "strip", z.ZodTypeAny, {
79
+ operationId: string;
80
+ manifestJson: string;
81
+ }, {
82
+ operationId: string;
83
+ manifestJson: string;
84
+ }>;
85
+ export type BffSchemaDeployRequest = z.infer<typeof bffSchemaDeployRequestSchema>;
86
+ export declare const bffTransferScopeRequestSchema: z.ZodObject<{
87
+ operationId: z.ZodString;
88
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
89
+ schemaHash: z.ZodString;
90
+ includeFileStorage: z.ZodBoolean;
91
+ }, "strip", z.ZodTypeAny, {
92
+ tables: string[];
93
+ schemaHash: string;
94
+ includeFileStorage: boolean;
95
+ operationId: string;
96
+ }, {
97
+ tables: string[];
98
+ schemaHash: string;
99
+ includeFileStorage: boolean;
100
+ operationId: string;
101
+ }>;
102
+ export type BffTransferScopeRequest = z.infer<typeof bffTransferScopeRequestSchema>;
103
+ export declare const bffTransferCommitRequestSchema: z.ZodObject<{
104
+ operationId: z.ZodString;
105
+ /** Client echo; server also rechecks the transfer-bound hash. */
106
+ schemaHash: z.ZodString;
107
+ }, "strip", z.ZodTypeAny, {
108
+ schemaHash: string;
109
+ operationId: string;
110
+ }, {
111
+ schemaHash: string;
112
+ operationId: string;
113
+ }>;
114
+ export type BffTransferCommitRequest = z.infer<typeof bffTransferCommitRequestSchema>;
115
+ export type BffTransferCommitArgs = BffTransferCommitRequest & {
116
+ transferId: z.infer<typeof transferIdSchema>;
117
+ };
118
+ export declare const bffHealthResponseSchema: z.ZodObject<{
119
+ ok: z.ZodBoolean;
120
+ commit: z.ZodString;
121
+ executor: z.ZodObject<{
122
+ ok: z.ZodBoolean;
123
+ commit: z.ZodOptional<z.ZodString>;
124
+ error: z.ZodOptional<z.ZodString>;
125
+ }, "strip", z.ZodTypeAny, {
126
+ ok: boolean;
127
+ error?: string | undefined;
128
+ commit?: string | undefined;
129
+ }, {
130
+ ok: boolean;
131
+ error?: string | undefined;
132
+ commit?: string | undefined;
133
+ }>;
134
+ }, "strip", z.ZodTypeAny, {
135
+ ok: boolean;
136
+ commit: string;
137
+ executor: {
138
+ ok: boolean;
139
+ error?: string | undefined;
140
+ commit?: string | undefined;
141
+ };
142
+ }, {
143
+ ok: boolean;
144
+ commit: string;
145
+ executor: {
146
+ ok: boolean;
147
+ error?: string | undefined;
148
+ commit?: string | undefined;
149
+ };
150
+ }>;
151
+ export type BffHealthResponse = z.infer<typeof bffHealthResponseSchema>;
152
+ export declare const bffActiveOperationMetaSchema: z.ZodObject<{
153
+ operationId: z.ZodString;
154
+ desiredManifestHash: z.ZodOptional<z.ZodString>;
155
+ phase: z.ZodOptional<z.ZodEnum<["cleaning", "ready", "deploying", "succeeded", "failed"]>>;
156
+ startedAt: z.ZodOptional<z.ZodNumber>;
157
+ }, "strip", z.ZodTypeAny, {
158
+ operationId: string;
159
+ desiredManifestHash?: string | undefined;
160
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
161
+ startedAt?: number | undefined;
162
+ }, {
163
+ operationId: string;
164
+ desiredManifestHash?: string | undefined;
165
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
166
+ startedAt?: number | undefined;
167
+ }>;
168
+ export type BffActiveOperationMeta = z.infer<typeof bffActiveOperationMetaSchema>;
169
+ export declare const bffSchemaDeployResponseSchema: z.ZodObject<{
170
+ ok: z.ZodBoolean;
171
+ operationId: z.ZodString;
172
+ phase: z.ZodEnum<["cleaning", "ready", "deploying", "succeeded", "failed"]>;
173
+ desiredManifestHash: z.ZodOptional<z.ZodString>;
174
+ deployedManifestHash: z.ZodOptional<z.ZodString>;
175
+ error: z.ZodOptional<z.ZodString>;
176
+ logTail: z.ZodOptional<z.ZodString>;
177
+ activeOperation: z.ZodOptional<z.ZodObject<{
178
+ operationId: z.ZodString;
179
+ desiredManifestHash: z.ZodOptional<z.ZodString>;
180
+ phase: z.ZodOptional<z.ZodEnum<["cleaning", "ready", "deploying", "succeeded", "failed"]>>;
181
+ startedAt: z.ZodOptional<z.ZodNumber>;
182
+ }, "strip", z.ZodTypeAny, {
183
+ operationId: string;
184
+ desiredManifestHash?: string | undefined;
185
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
186
+ startedAt?: number | undefined;
187
+ }, {
188
+ operationId: string;
189
+ desiredManifestHash?: string | undefined;
190
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
191
+ startedAt?: number | undefined;
192
+ }>>;
193
+ }, "strip", z.ZodTypeAny, {
194
+ ok: boolean;
195
+ operationId: string;
196
+ phase: "cleaning" | "ready" | "deploying" | "succeeded" | "failed";
197
+ error?: string | undefined;
198
+ desiredManifestHash?: string | undefined;
199
+ deployedManifestHash?: string | undefined;
200
+ logTail?: string | undefined;
201
+ activeOperation?: {
202
+ operationId: string;
203
+ desiredManifestHash?: string | undefined;
204
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
205
+ startedAt?: number | undefined;
206
+ } | undefined;
207
+ }, {
208
+ ok: boolean;
209
+ operationId: string;
210
+ phase: "cleaning" | "ready" | "deploying" | "succeeded" | "failed";
211
+ error?: string | undefined;
212
+ desiredManifestHash?: string | undefined;
213
+ deployedManifestHash?: string | undefined;
214
+ logTail?: string | undefined;
215
+ activeOperation?: {
216
+ operationId: string;
217
+ desiredManifestHash?: string | undefined;
218
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
219
+ startedAt?: number | undefined;
220
+ } | undefined;
221
+ }>;
222
+ export type BffSchemaDeployResponse = z.infer<typeof bffSchemaDeployResponseSchema>;
223
+ export declare const bffTransferCreateResponseSchema: z.ZodObject<{
224
+ ok: z.ZodLiteral<true>;
225
+ transferId: z.ZodString;
226
+ expiresAt: z.ZodNumber;
227
+ bytes: z.ZodOptional<z.ZodNumber>;
228
+ }, "strip", z.ZodTypeAny, {
229
+ ok: true;
230
+ transferId: string;
231
+ expiresAt: number;
232
+ bytes?: number | undefined;
233
+ }, {
234
+ ok: true;
235
+ transferId: string;
236
+ expiresAt: number;
237
+ bytes?: number | undefined;
238
+ }>;
239
+ export type BffTransferCreateResponse = z.infer<typeof bffTransferCreateResponseSchema>;
240
+ export declare const bffTransferCommitResponseSchema: z.ZodObject<{
241
+ ok: z.ZodBoolean;
242
+ transferId: z.ZodString;
243
+ error: z.ZodOptional<z.ZodString>;
244
+ logTail: z.ZodOptional<z.ZodString>;
245
+ }, "strip", z.ZodTypeAny, {
246
+ ok: boolean;
247
+ transferId: string;
248
+ error?: string | undefined;
249
+ logTail?: string | undefined;
250
+ }, {
251
+ ok: boolean;
252
+ transferId: string;
253
+ error?: string | undefined;
254
+ logTail?: string | undefined;
255
+ }>;
256
+ export type BffTransferCommitResponse = z.infer<typeof bffTransferCommitResponseSchema>;
257
+ export declare const bffTransferUploadResponseSchema: z.ZodObject<{
258
+ ok: z.ZodLiteral<true>;
259
+ bytes: z.ZodNumber;
260
+ }, "strip", z.ZodTypeAny, {
261
+ bytes: number;
262
+ ok: true;
263
+ }, {
264
+ bytes: number;
265
+ ok: true;
266
+ }>;
267
+ export type BffTransferUploadResponse = z.infer<typeof bffTransferUploadResponseSchema>;
268
+ export declare const bffErrorCodeSchema: z.ZodEnum<["unauthorized", "forbidden", "unknown_host", "disabled_host", "conflict", "executor_mismatch", "executor_unavailable", "validation_error", "not_found", "payload_too_large", "gone", "internal_error"]>;
269
+ export type BffErrorCode = z.infer<typeof bffErrorCodeSchema>;
270
+ export declare const bffErrorResponseSchema: z.ZodObject<{
271
+ ok: z.ZodLiteral<false>;
272
+ error: z.ZodString;
273
+ code: z.ZodOptional<z.ZodEnum<["unauthorized", "forbidden", "unknown_host", "disabled_host", "conflict", "executor_mismatch", "executor_unavailable", "validation_error", "not_found", "payload_too_large", "gone", "internal_error"]>>;
274
+ logTail: z.ZodOptional<z.ZodString>;
275
+ activeOperation: z.ZodOptional<z.ZodObject<{
276
+ operationId: z.ZodString;
277
+ desiredManifestHash: z.ZodOptional<z.ZodString>;
278
+ phase: z.ZodOptional<z.ZodEnum<["cleaning", "ready", "deploying", "succeeded", "failed"]>>;
279
+ startedAt: z.ZodOptional<z.ZodNumber>;
280
+ }, "strip", z.ZodTypeAny, {
281
+ operationId: string;
282
+ desiredManifestHash?: string | undefined;
283
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
284
+ startedAt?: number | undefined;
285
+ }, {
286
+ operationId: string;
287
+ desiredManifestHash?: string | undefined;
288
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
289
+ startedAt?: number | undefined;
290
+ }>>;
291
+ }, "strip", z.ZodTypeAny, {
292
+ error: string;
293
+ ok: false;
294
+ code?: "unauthorized" | "forbidden" | "unknown_host" | "disabled_host" | "conflict" | "executor_mismatch" | "executor_unavailable" | "validation_error" | "not_found" | "payload_too_large" | "gone" | "internal_error" | undefined;
295
+ logTail?: string | undefined;
296
+ activeOperation?: {
297
+ operationId: string;
298
+ desiredManifestHash?: string | undefined;
299
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
300
+ startedAt?: number | undefined;
301
+ } | undefined;
302
+ }, {
303
+ error: string;
304
+ ok: false;
305
+ code?: "unauthorized" | "forbidden" | "unknown_host" | "disabled_host" | "conflict" | "executor_mismatch" | "executor_unavailable" | "validation_error" | "not_found" | "payload_too_large" | "gone" | "internal_error" | undefined;
306
+ logTail?: string | undefined;
307
+ activeOperation?: {
308
+ operationId: string;
309
+ desiredManifestHash?: string | undefined;
310
+ phase?: "cleaning" | "ready" | "deploying" | "succeeded" | "failed" | undefined;
311
+ startedAt?: number | undefined;
312
+ } | undefined;
313
+ }>;
314
+ export type BffErrorResponse = z.infer<typeof bffErrorResponseSchema>;
315
+ export declare const bffPrepareOperationSchema: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
316
+ type: z.ZodLiteral<"schemaDeploy">;
317
+ operationId: z.ZodString;
318
+ manifestJson: z.ZodString;
319
+ }, "strip", z.ZodTypeAny, {
320
+ type: "schemaDeploy";
321
+ operationId: string;
322
+ manifestJson: string;
323
+ }, {
324
+ type: "schemaDeploy";
325
+ operationId: string;
326
+ manifestJson: string;
327
+ }>, z.ZodObject<{
328
+ type: z.ZodLiteral<"dataExport">;
329
+ operationId: z.ZodString;
330
+ transferManifest: z.ZodEffects<z.ZodObject<{
331
+ version: z.ZodLiteral<1>;
332
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
333
+ schemaHash: z.ZodString;
334
+ includeFileStorage: z.ZodBoolean;
335
+ }, "strip", z.ZodTypeAny, {
336
+ tables: string[];
337
+ version: 1;
338
+ schemaHash: string;
339
+ includeFileStorage: boolean;
340
+ }, {
341
+ tables: string[];
342
+ version: 1;
343
+ schemaHash: string;
344
+ includeFileStorage: boolean;
345
+ }>, {
346
+ tables: string[];
347
+ version: 1;
348
+ schemaHash: string;
349
+ includeFileStorage: boolean;
350
+ }, {
351
+ tables: string[];
352
+ version: 1;
353
+ schemaHash: string;
354
+ includeFileStorage: boolean;
355
+ }>;
356
+ }, "strip", z.ZodTypeAny, {
357
+ type: "dataExport";
358
+ operationId: string;
359
+ transferManifest: {
360
+ tables: string[];
361
+ version: 1;
362
+ schemaHash: string;
363
+ includeFileStorage: boolean;
364
+ };
365
+ }, {
366
+ type: "dataExport";
367
+ operationId: string;
368
+ transferManifest: {
369
+ tables: string[];
370
+ version: 1;
371
+ schemaHash: string;
372
+ includeFileStorage: boolean;
373
+ };
374
+ }>, z.ZodObject<{
375
+ type: z.ZodLiteral<"dataImportPrepare">;
376
+ operationId: z.ZodString;
377
+ transferManifest: z.ZodEffects<z.ZodObject<{
378
+ version: z.ZodLiteral<1>;
379
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
380
+ schemaHash: z.ZodString;
381
+ includeFileStorage: z.ZodBoolean;
382
+ }, "strip", z.ZodTypeAny, {
383
+ tables: string[];
384
+ version: 1;
385
+ schemaHash: string;
386
+ includeFileStorage: boolean;
387
+ }, {
388
+ tables: string[];
389
+ version: 1;
390
+ schemaHash: string;
391
+ includeFileStorage: boolean;
392
+ }>, {
393
+ tables: string[];
394
+ version: 1;
395
+ schemaHash: string;
396
+ includeFileStorage: boolean;
397
+ }, {
398
+ tables: string[];
399
+ version: 1;
400
+ schemaHash: string;
401
+ includeFileStorage: boolean;
402
+ }>;
403
+ }, "strip", z.ZodTypeAny, {
404
+ type: "dataImportPrepare";
405
+ operationId: string;
406
+ transferManifest: {
407
+ tables: string[];
408
+ version: 1;
409
+ schemaHash: string;
410
+ includeFileStorage: boolean;
411
+ };
412
+ }, {
413
+ type: "dataImportPrepare";
414
+ operationId: string;
415
+ transferManifest: {
416
+ tables: string[];
417
+ version: 1;
418
+ schemaHash: string;
419
+ includeFileStorage: boolean;
420
+ };
421
+ }>, z.ZodObject<{
422
+ type: z.ZodLiteral<"dataImportCommit">;
423
+ operationId: z.ZodString;
424
+ transferId: z.ZodString;
425
+ schemaHash: z.ZodString;
426
+ }, "strip", z.ZodTypeAny, {
427
+ type: "dataImportCommit";
428
+ schemaHash: string;
429
+ operationId: string;
430
+ transferId: string;
431
+ }, {
432
+ type: "dataImportCommit";
433
+ schemaHash: string;
434
+ operationId: string;
435
+ transferId: string;
436
+ }>]>;
437
+ export type BffPrepareOperation = z.infer<typeof bffPrepareOperationSchema>;
438
+ export declare const bffPrepareRequestSchema: z.ZodObject<{
439
+ protocolVersion: z.ZodLiteral<1>;
440
+ /** Trusted hostname only (already extracted by BFF). */
441
+ host: z.ZodString;
442
+ correlationId: z.ZodOptional<z.ZodString>;
443
+ operation: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
444
+ type: z.ZodLiteral<"schemaDeploy">;
445
+ operationId: z.ZodString;
446
+ manifestJson: z.ZodString;
447
+ }, "strip", z.ZodTypeAny, {
448
+ type: "schemaDeploy";
449
+ operationId: string;
450
+ manifestJson: string;
451
+ }, {
452
+ type: "schemaDeploy";
453
+ operationId: string;
454
+ manifestJson: string;
455
+ }>, z.ZodObject<{
456
+ type: z.ZodLiteral<"dataExport">;
457
+ operationId: z.ZodString;
458
+ transferManifest: z.ZodEffects<z.ZodObject<{
459
+ version: z.ZodLiteral<1>;
460
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
461
+ schemaHash: z.ZodString;
462
+ includeFileStorage: z.ZodBoolean;
463
+ }, "strip", z.ZodTypeAny, {
464
+ tables: string[];
465
+ version: 1;
466
+ schemaHash: string;
467
+ includeFileStorage: boolean;
468
+ }, {
469
+ tables: string[];
470
+ version: 1;
471
+ schemaHash: string;
472
+ includeFileStorage: boolean;
473
+ }>, {
474
+ tables: string[];
475
+ version: 1;
476
+ schemaHash: string;
477
+ includeFileStorage: boolean;
478
+ }, {
479
+ tables: string[];
480
+ version: 1;
481
+ schemaHash: string;
482
+ includeFileStorage: boolean;
483
+ }>;
484
+ }, "strip", z.ZodTypeAny, {
485
+ type: "dataExport";
486
+ operationId: string;
487
+ transferManifest: {
488
+ tables: string[];
489
+ version: 1;
490
+ schemaHash: string;
491
+ includeFileStorage: boolean;
492
+ };
493
+ }, {
494
+ type: "dataExport";
495
+ operationId: string;
496
+ transferManifest: {
497
+ tables: string[];
498
+ version: 1;
499
+ schemaHash: string;
500
+ includeFileStorage: boolean;
501
+ };
502
+ }>, z.ZodObject<{
503
+ type: z.ZodLiteral<"dataImportPrepare">;
504
+ operationId: z.ZodString;
505
+ transferManifest: z.ZodEffects<z.ZodObject<{
506
+ version: z.ZodLiteral<1>;
507
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
508
+ schemaHash: z.ZodString;
509
+ includeFileStorage: z.ZodBoolean;
510
+ }, "strip", z.ZodTypeAny, {
511
+ tables: string[];
512
+ version: 1;
513
+ schemaHash: string;
514
+ includeFileStorage: boolean;
515
+ }, {
516
+ tables: string[];
517
+ version: 1;
518
+ schemaHash: string;
519
+ includeFileStorage: boolean;
520
+ }>, {
521
+ tables: string[];
522
+ version: 1;
523
+ schemaHash: string;
524
+ includeFileStorage: boolean;
525
+ }, {
526
+ tables: string[];
527
+ version: 1;
528
+ schemaHash: string;
529
+ includeFileStorage: boolean;
530
+ }>;
531
+ }, "strip", z.ZodTypeAny, {
532
+ type: "dataImportPrepare";
533
+ operationId: string;
534
+ transferManifest: {
535
+ tables: string[];
536
+ version: 1;
537
+ schemaHash: string;
538
+ includeFileStorage: boolean;
539
+ };
540
+ }, {
541
+ type: "dataImportPrepare";
542
+ operationId: string;
543
+ transferManifest: {
544
+ tables: string[];
545
+ version: 1;
546
+ schemaHash: string;
547
+ includeFileStorage: boolean;
548
+ };
549
+ }>, z.ZodObject<{
550
+ type: z.ZodLiteral<"dataImportCommit">;
551
+ operationId: z.ZodString;
552
+ transferId: z.ZodString;
553
+ schemaHash: z.ZodString;
554
+ }, "strip", z.ZodTypeAny, {
555
+ type: "dataImportCommit";
556
+ schemaHash: string;
557
+ operationId: string;
558
+ transferId: string;
559
+ }, {
560
+ type: "dataImportCommit";
561
+ schemaHash: string;
562
+ operationId: string;
563
+ transferId: string;
564
+ }>]>;
565
+ }, "strip", z.ZodTypeAny, {
566
+ host: string;
567
+ protocolVersion: 1;
568
+ operation: {
569
+ type: "schemaDeploy";
570
+ operationId: string;
571
+ manifestJson: string;
572
+ } | {
573
+ type: "dataExport";
574
+ operationId: string;
575
+ transferManifest: {
576
+ tables: string[];
577
+ version: 1;
578
+ schemaHash: string;
579
+ includeFileStorage: boolean;
580
+ };
581
+ } | {
582
+ type: "dataImportPrepare";
583
+ operationId: string;
584
+ transferManifest: {
585
+ tables: string[];
586
+ version: 1;
587
+ schemaHash: string;
588
+ includeFileStorage: boolean;
589
+ };
590
+ } | {
591
+ type: "dataImportCommit";
592
+ schemaHash: string;
593
+ operationId: string;
594
+ transferId: string;
595
+ };
596
+ correlationId?: string | undefined;
597
+ }, {
598
+ host: string;
599
+ protocolVersion: 1;
600
+ operation: {
601
+ type: "schemaDeploy";
602
+ operationId: string;
603
+ manifestJson: string;
604
+ } | {
605
+ type: "dataExport";
606
+ operationId: string;
607
+ transferManifest: {
608
+ tables: string[];
609
+ version: 1;
610
+ schemaHash: string;
611
+ includeFileStorage: boolean;
612
+ };
613
+ } | {
614
+ type: "dataImportPrepare";
615
+ operationId: string;
616
+ transferManifest: {
617
+ tables: string[];
618
+ version: 1;
619
+ schemaHash: string;
620
+ includeFileStorage: boolean;
621
+ };
622
+ } | {
623
+ type: "dataImportCommit";
624
+ schemaHash: string;
625
+ operationId: string;
626
+ transferId: string;
627
+ };
628
+ correlationId?: string | undefined;
629
+ }>;
630
+ export type BffPrepareRequest = z.infer<typeof bffPrepareRequestSchema>;
631
+ export declare const bffPreparedTenantSchema: z.ZodObject<{
632
+ slug: z.ZodString;
633
+ convexUrl: z.ZodString;
634
+ authIssuer: z.ZodOptional<z.ZodString>;
635
+ deploymentName: z.ZodOptional<z.ZodString>;
636
+ }, "strip", z.ZodTypeAny, {
637
+ slug: string;
638
+ convexUrl: string;
639
+ authIssuer?: string | undefined;
640
+ deploymentName?: string | undefined;
641
+ }, {
642
+ slug: string;
643
+ convexUrl: string;
644
+ authIssuer?: string | undefined;
645
+ deploymentName?: string | undefined;
646
+ }>;
647
+ export type BffPreparedTenant = z.infer<typeof bffPreparedTenantSchema>;
648
+ /** Inner payload shapes for deploy-service `/internal/v1/*` (D39). */
649
+ export declare const deployInternalSchemaDeployPayloadSchema: z.ZodObject<{
650
+ manifestJson: z.ZodString;
651
+ convexDeployKey: z.ZodString;
652
+ convexUrl: z.ZodString;
653
+ authIssuer: z.ZodOptional<z.ZodString>;
654
+ previewName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
655
+ operationId: z.ZodOptional<z.ZodString>;
656
+ }, "strip", z.ZodTypeAny, {
657
+ manifestJson: string;
658
+ convexUrl: string;
659
+ convexDeployKey: string;
660
+ operationId?: string | undefined;
661
+ authIssuer?: string | undefined;
662
+ previewName?: string | null | undefined;
663
+ }, {
664
+ manifestJson: string;
665
+ convexUrl: string;
666
+ convexDeployKey: string;
667
+ operationId?: string | undefined;
668
+ authIssuer?: string | undefined;
669
+ previewName?: string | null | undefined;
670
+ }>;
671
+ export type DeployInternalSchemaDeployPayload = z.infer<typeof deployInternalSchemaDeployPayloadSchema>;
672
+ export declare const deployInternalTransferExportPayloadSchema: z.ZodObject<{
673
+ transferManifest: z.ZodEffects<z.ZodObject<{
674
+ version: z.ZodLiteral<1>;
675
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
676
+ schemaHash: z.ZodString;
677
+ includeFileStorage: z.ZodBoolean;
678
+ }, "strip", z.ZodTypeAny, {
679
+ tables: string[];
680
+ version: 1;
681
+ schemaHash: string;
682
+ includeFileStorage: boolean;
683
+ }, {
684
+ tables: string[];
685
+ version: 1;
686
+ schemaHash: string;
687
+ includeFileStorage: boolean;
688
+ }>, {
689
+ tables: string[];
690
+ version: 1;
691
+ schemaHash: string;
692
+ includeFileStorage: boolean;
693
+ }, {
694
+ tables: string[];
695
+ version: 1;
696
+ schemaHash: string;
697
+ includeFileStorage: boolean;
698
+ }>;
699
+ convexDeployKey: z.ZodString;
700
+ convexUrl: z.ZodString;
701
+ tenantSlug: z.ZodString;
702
+ operationId: z.ZodString;
703
+ }, "strip", z.ZodTypeAny, {
704
+ operationId: string;
705
+ transferManifest: {
706
+ tables: string[];
707
+ version: 1;
708
+ schemaHash: string;
709
+ includeFileStorage: boolean;
710
+ };
711
+ convexUrl: string;
712
+ convexDeployKey: string;
713
+ tenantSlug: string;
714
+ }, {
715
+ operationId: string;
716
+ transferManifest: {
717
+ tables: string[];
718
+ version: 1;
719
+ schemaHash: string;
720
+ includeFileStorage: boolean;
721
+ };
722
+ convexUrl: string;
723
+ convexDeployKey: string;
724
+ tenantSlug: string;
725
+ }>;
726
+ export type DeployInternalTransferExportPayload = z.infer<typeof deployInternalTransferExportPayloadSchema>;
727
+ export declare const deployInternalTransferImportPreparePayloadSchema: z.ZodObject<{
728
+ transferManifest: z.ZodEffects<z.ZodObject<{
729
+ version: z.ZodLiteral<1>;
730
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
731
+ schemaHash: z.ZodString;
732
+ includeFileStorage: z.ZodBoolean;
733
+ }, "strip", z.ZodTypeAny, {
734
+ tables: string[];
735
+ version: 1;
736
+ schemaHash: string;
737
+ includeFileStorage: boolean;
738
+ }, {
739
+ tables: string[];
740
+ version: 1;
741
+ schemaHash: string;
742
+ includeFileStorage: boolean;
743
+ }>, {
744
+ tables: string[];
745
+ version: 1;
746
+ schemaHash: string;
747
+ includeFileStorage: boolean;
748
+ }, {
749
+ tables: string[];
750
+ version: 1;
751
+ schemaHash: string;
752
+ includeFileStorage: boolean;
753
+ }>;
754
+ convexDeployKey: z.ZodString;
755
+ convexUrl: z.ZodString;
756
+ tenantSlug: z.ZodString;
757
+ operationId: z.ZodString;
758
+ }, "strip", z.ZodTypeAny, {
759
+ operationId: string;
760
+ transferManifest: {
761
+ tables: string[];
762
+ version: 1;
763
+ schemaHash: string;
764
+ includeFileStorage: boolean;
765
+ };
766
+ convexUrl: string;
767
+ convexDeployKey: string;
768
+ tenantSlug: string;
769
+ }, {
770
+ operationId: string;
771
+ transferManifest: {
772
+ tables: string[];
773
+ version: 1;
774
+ schemaHash: string;
775
+ includeFileStorage: boolean;
776
+ };
777
+ convexUrl: string;
778
+ convexDeployKey: string;
779
+ tenantSlug: string;
780
+ }>;
781
+ export type DeployInternalTransferImportPreparePayload = z.infer<typeof deployInternalTransferImportPreparePayloadSchema>;
782
+ export declare const deployInternalTransferCommitPayloadSchema: z.ZodObject<{
783
+ transferId: z.ZodString;
784
+ convexDeployKey: z.ZodString;
785
+ convexUrl: z.ZodString;
786
+ tenantSlug: z.ZodString;
787
+ operationId: z.ZodString;
788
+ schemaHash: z.ZodString;
789
+ }, "strip", z.ZodTypeAny, {
790
+ schemaHash: string;
791
+ operationId: string;
792
+ transferId: string;
793
+ convexUrl: string;
794
+ convexDeployKey: string;
795
+ tenantSlug: string;
796
+ }, {
797
+ schemaHash: string;
798
+ operationId: string;
799
+ transferId: string;
800
+ convexUrl: string;
801
+ convexDeployKey: string;
802
+ tenantSlug: string;
803
+ }>;
804
+ export type DeployInternalTransferCommitPayload = z.infer<typeof deployInternalTransferCommitPayloadSchema>;
805
+ /**
806
+ * Management prepare response: a discriminated envelope whose operation owns
807
+ * the exact deploy-service payload shape. BFF forwards `payload` wholesale and
808
+ * must never log it as a unit.
809
+ */
810
+ export declare const bffPreparedBodyEnvelopeSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObject<{
811
+ protocolVersion: z.ZodLiteral<1>;
812
+ tenant: z.ZodObject<{
813
+ slug: z.ZodString;
814
+ convexUrl: z.ZodString;
815
+ authIssuer: z.ZodOptional<z.ZodString>;
816
+ deploymentName: z.ZodOptional<z.ZodString>;
817
+ }, "strip", z.ZodTypeAny, {
818
+ slug: string;
819
+ convexUrl: string;
820
+ authIssuer?: string | undefined;
821
+ deploymentName?: string | undefined;
822
+ }, {
823
+ slug: string;
824
+ convexUrl: string;
825
+ authIssuer?: string | undefined;
826
+ deploymentName?: string | undefined;
827
+ }>;
828
+ correlationId: z.ZodOptional<z.ZodString>;
829
+ } & {
830
+ operation: z.ZodLiteral<"schemaDeploy">;
831
+ payload: z.ZodObject<{
832
+ manifestJson: z.ZodString;
833
+ convexDeployKey: z.ZodString;
834
+ convexUrl: z.ZodString;
835
+ authIssuer: z.ZodOptional<z.ZodString>;
836
+ previewName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
837
+ operationId: z.ZodOptional<z.ZodString>;
838
+ }, "strip", z.ZodTypeAny, {
839
+ manifestJson: string;
840
+ convexUrl: string;
841
+ convexDeployKey: string;
842
+ operationId?: string | undefined;
843
+ authIssuer?: string | undefined;
844
+ previewName?: string | null | undefined;
845
+ }, {
846
+ manifestJson: string;
847
+ convexUrl: string;
848
+ convexDeployKey: string;
849
+ operationId?: string | undefined;
850
+ authIssuer?: string | undefined;
851
+ previewName?: string | null | undefined;
852
+ }>;
853
+ }, "strip", z.ZodTypeAny, {
854
+ protocolVersion: 1;
855
+ operation: "schemaDeploy";
856
+ tenant: {
857
+ slug: string;
858
+ convexUrl: string;
859
+ authIssuer?: string | undefined;
860
+ deploymentName?: string | undefined;
861
+ };
862
+ payload: {
863
+ manifestJson: string;
864
+ convexUrl: string;
865
+ convexDeployKey: string;
866
+ operationId?: string | undefined;
867
+ authIssuer?: string | undefined;
868
+ previewName?: string | null | undefined;
869
+ };
870
+ correlationId?: string | undefined;
871
+ }, {
872
+ protocolVersion: 1;
873
+ operation: "schemaDeploy";
874
+ tenant: {
875
+ slug: string;
876
+ convexUrl: string;
877
+ authIssuer?: string | undefined;
878
+ deploymentName?: string | undefined;
879
+ };
880
+ payload: {
881
+ manifestJson: string;
882
+ convexUrl: string;
883
+ convexDeployKey: string;
884
+ operationId?: string | undefined;
885
+ authIssuer?: string | undefined;
886
+ previewName?: string | null | undefined;
887
+ };
888
+ correlationId?: string | undefined;
889
+ }>, z.ZodObject<{
890
+ protocolVersion: z.ZodLiteral<1>;
891
+ tenant: z.ZodObject<{
892
+ slug: z.ZodString;
893
+ convexUrl: z.ZodString;
894
+ authIssuer: z.ZodOptional<z.ZodString>;
895
+ deploymentName: z.ZodOptional<z.ZodString>;
896
+ }, "strip", z.ZodTypeAny, {
897
+ slug: string;
898
+ convexUrl: string;
899
+ authIssuer?: string | undefined;
900
+ deploymentName?: string | undefined;
901
+ }, {
902
+ slug: string;
903
+ convexUrl: string;
904
+ authIssuer?: string | undefined;
905
+ deploymentName?: string | undefined;
906
+ }>;
907
+ correlationId: z.ZodOptional<z.ZodString>;
908
+ } & {
909
+ operation: z.ZodLiteral<"dataExport">;
910
+ payload: z.ZodObject<{
911
+ transferManifest: z.ZodEffects<z.ZodObject<{
912
+ version: z.ZodLiteral<1>;
913
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
914
+ schemaHash: z.ZodString;
915
+ includeFileStorage: z.ZodBoolean;
916
+ }, "strip", z.ZodTypeAny, {
917
+ tables: string[];
918
+ version: 1;
919
+ schemaHash: string;
920
+ includeFileStorage: boolean;
921
+ }, {
922
+ tables: string[];
923
+ version: 1;
924
+ schemaHash: string;
925
+ includeFileStorage: boolean;
926
+ }>, {
927
+ tables: string[];
928
+ version: 1;
929
+ schemaHash: string;
930
+ includeFileStorage: boolean;
931
+ }, {
932
+ tables: string[];
933
+ version: 1;
934
+ schemaHash: string;
935
+ includeFileStorage: boolean;
936
+ }>;
937
+ convexDeployKey: z.ZodString;
938
+ convexUrl: z.ZodString;
939
+ tenantSlug: z.ZodString;
940
+ operationId: z.ZodString;
941
+ }, "strip", z.ZodTypeAny, {
942
+ operationId: string;
943
+ transferManifest: {
944
+ tables: string[];
945
+ version: 1;
946
+ schemaHash: string;
947
+ includeFileStorage: boolean;
948
+ };
949
+ convexUrl: string;
950
+ convexDeployKey: string;
951
+ tenantSlug: string;
952
+ }, {
953
+ operationId: string;
954
+ transferManifest: {
955
+ tables: string[];
956
+ version: 1;
957
+ schemaHash: string;
958
+ includeFileStorage: boolean;
959
+ };
960
+ convexUrl: string;
961
+ convexDeployKey: string;
962
+ tenantSlug: string;
963
+ }>;
964
+ }, "strip", z.ZodTypeAny, {
965
+ protocolVersion: 1;
966
+ operation: "dataExport";
967
+ tenant: {
968
+ slug: string;
969
+ convexUrl: string;
970
+ authIssuer?: string | undefined;
971
+ deploymentName?: string | undefined;
972
+ };
973
+ payload: {
974
+ operationId: string;
975
+ transferManifest: {
976
+ tables: string[];
977
+ version: 1;
978
+ schemaHash: string;
979
+ includeFileStorage: boolean;
980
+ };
981
+ convexUrl: string;
982
+ convexDeployKey: string;
983
+ tenantSlug: string;
984
+ };
985
+ correlationId?: string | undefined;
986
+ }, {
987
+ protocolVersion: 1;
988
+ operation: "dataExport";
989
+ tenant: {
990
+ slug: string;
991
+ convexUrl: string;
992
+ authIssuer?: string | undefined;
993
+ deploymentName?: string | undefined;
994
+ };
995
+ payload: {
996
+ operationId: string;
997
+ transferManifest: {
998
+ tables: string[];
999
+ version: 1;
1000
+ schemaHash: string;
1001
+ includeFileStorage: boolean;
1002
+ };
1003
+ convexUrl: string;
1004
+ convexDeployKey: string;
1005
+ tenantSlug: string;
1006
+ };
1007
+ correlationId?: string | undefined;
1008
+ }>, z.ZodObject<{
1009
+ protocolVersion: z.ZodLiteral<1>;
1010
+ tenant: z.ZodObject<{
1011
+ slug: z.ZodString;
1012
+ convexUrl: z.ZodString;
1013
+ authIssuer: z.ZodOptional<z.ZodString>;
1014
+ deploymentName: z.ZodOptional<z.ZodString>;
1015
+ }, "strip", z.ZodTypeAny, {
1016
+ slug: string;
1017
+ convexUrl: string;
1018
+ authIssuer?: string | undefined;
1019
+ deploymentName?: string | undefined;
1020
+ }, {
1021
+ slug: string;
1022
+ convexUrl: string;
1023
+ authIssuer?: string | undefined;
1024
+ deploymentName?: string | undefined;
1025
+ }>;
1026
+ correlationId: z.ZodOptional<z.ZodString>;
1027
+ } & {
1028
+ operation: z.ZodLiteral<"dataImportPrepare">;
1029
+ payload: z.ZodObject<{
1030
+ transferManifest: z.ZodEffects<z.ZodObject<{
1031
+ version: z.ZodLiteral<1>;
1032
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
1033
+ schemaHash: z.ZodString;
1034
+ includeFileStorage: z.ZodBoolean;
1035
+ }, "strip", z.ZodTypeAny, {
1036
+ tables: string[];
1037
+ version: 1;
1038
+ schemaHash: string;
1039
+ includeFileStorage: boolean;
1040
+ }, {
1041
+ tables: string[];
1042
+ version: 1;
1043
+ schemaHash: string;
1044
+ includeFileStorage: boolean;
1045
+ }>, {
1046
+ tables: string[];
1047
+ version: 1;
1048
+ schemaHash: string;
1049
+ includeFileStorage: boolean;
1050
+ }, {
1051
+ tables: string[];
1052
+ version: 1;
1053
+ schemaHash: string;
1054
+ includeFileStorage: boolean;
1055
+ }>;
1056
+ convexDeployKey: z.ZodString;
1057
+ convexUrl: z.ZodString;
1058
+ tenantSlug: z.ZodString;
1059
+ operationId: z.ZodString;
1060
+ }, "strip", z.ZodTypeAny, {
1061
+ operationId: string;
1062
+ transferManifest: {
1063
+ tables: string[];
1064
+ version: 1;
1065
+ schemaHash: string;
1066
+ includeFileStorage: boolean;
1067
+ };
1068
+ convexUrl: string;
1069
+ convexDeployKey: string;
1070
+ tenantSlug: string;
1071
+ }, {
1072
+ operationId: string;
1073
+ transferManifest: {
1074
+ tables: string[];
1075
+ version: 1;
1076
+ schemaHash: string;
1077
+ includeFileStorage: boolean;
1078
+ };
1079
+ convexUrl: string;
1080
+ convexDeployKey: string;
1081
+ tenantSlug: string;
1082
+ }>;
1083
+ }, "strip", z.ZodTypeAny, {
1084
+ protocolVersion: 1;
1085
+ operation: "dataImportPrepare";
1086
+ tenant: {
1087
+ slug: string;
1088
+ convexUrl: string;
1089
+ authIssuer?: string | undefined;
1090
+ deploymentName?: string | undefined;
1091
+ };
1092
+ payload: {
1093
+ operationId: string;
1094
+ transferManifest: {
1095
+ tables: string[];
1096
+ version: 1;
1097
+ schemaHash: string;
1098
+ includeFileStorage: boolean;
1099
+ };
1100
+ convexUrl: string;
1101
+ convexDeployKey: string;
1102
+ tenantSlug: string;
1103
+ };
1104
+ correlationId?: string | undefined;
1105
+ }, {
1106
+ protocolVersion: 1;
1107
+ operation: "dataImportPrepare";
1108
+ tenant: {
1109
+ slug: string;
1110
+ convexUrl: string;
1111
+ authIssuer?: string | undefined;
1112
+ deploymentName?: string | undefined;
1113
+ };
1114
+ payload: {
1115
+ operationId: string;
1116
+ transferManifest: {
1117
+ tables: string[];
1118
+ version: 1;
1119
+ schemaHash: string;
1120
+ includeFileStorage: boolean;
1121
+ };
1122
+ convexUrl: string;
1123
+ convexDeployKey: string;
1124
+ tenantSlug: string;
1125
+ };
1126
+ correlationId?: string | undefined;
1127
+ }>, z.ZodObject<{
1128
+ protocolVersion: z.ZodLiteral<1>;
1129
+ tenant: z.ZodObject<{
1130
+ slug: z.ZodString;
1131
+ convexUrl: z.ZodString;
1132
+ authIssuer: z.ZodOptional<z.ZodString>;
1133
+ deploymentName: z.ZodOptional<z.ZodString>;
1134
+ }, "strip", z.ZodTypeAny, {
1135
+ slug: string;
1136
+ convexUrl: string;
1137
+ authIssuer?: string | undefined;
1138
+ deploymentName?: string | undefined;
1139
+ }, {
1140
+ slug: string;
1141
+ convexUrl: string;
1142
+ authIssuer?: string | undefined;
1143
+ deploymentName?: string | undefined;
1144
+ }>;
1145
+ correlationId: z.ZodOptional<z.ZodString>;
1146
+ } & {
1147
+ operation: z.ZodLiteral<"dataImportCommit">;
1148
+ payload: z.ZodObject<{
1149
+ transferId: z.ZodString;
1150
+ convexDeployKey: z.ZodString;
1151
+ convexUrl: z.ZodString;
1152
+ tenantSlug: z.ZodString;
1153
+ operationId: z.ZodString;
1154
+ schemaHash: z.ZodString;
1155
+ }, "strip", z.ZodTypeAny, {
1156
+ schemaHash: string;
1157
+ operationId: string;
1158
+ transferId: string;
1159
+ convexUrl: string;
1160
+ convexDeployKey: string;
1161
+ tenantSlug: string;
1162
+ }, {
1163
+ schemaHash: string;
1164
+ operationId: string;
1165
+ transferId: string;
1166
+ convexUrl: string;
1167
+ convexDeployKey: string;
1168
+ tenantSlug: string;
1169
+ }>;
1170
+ }, "strip", z.ZodTypeAny, {
1171
+ protocolVersion: 1;
1172
+ operation: "dataImportCommit";
1173
+ tenant: {
1174
+ slug: string;
1175
+ convexUrl: string;
1176
+ authIssuer?: string | undefined;
1177
+ deploymentName?: string | undefined;
1178
+ };
1179
+ payload: {
1180
+ schemaHash: string;
1181
+ operationId: string;
1182
+ transferId: string;
1183
+ convexUrl: string;
1184
+ convexDeployKey: string;
1185
+ tenantSlug: string;
1186
+ };
1187
+ correlationId?: string | undefined;
1188
+ }, {
1189
+ protocolVersion: 1;
1190
+ operation: "dataImportCommit";
1191
+ tenant: {
1192
+ slug: string;
1193
+ convexUrl: string;
1194
+ authIssuer?: string | undefined;
1195
+ deploymentName?: string | undefined;
1196
+ };
1197
+ payload: {
1198
+ schemaHash: string;
1199
+ operationId: string;
1200
+ transferId: string;
1201
+ convexUrl: string;
1202
+ convexDeployKey: string;
1203
+ tenantSlug: string;
1204
+ };
1205
+ correlationId?: string | undefined;
1206
+ }>]>;
1207
+ export type BffPreparedBodyEnvelope = z.infer<typeof bffPreparedBodyEnvelopeSchema>;
1208
+ export type BffPreparedBodyEnvelopeFor<T extends BffPrepareOperationType> = Extract<BffPreparedBodyEnvelope, {
1209
+ operation: T;
1210
+ }>;
1211
+ export declare const bffPreviewRegisterRequestSchema: z.ZodObject<{
1212
+ hostname: z.ZodString;
1213
+ convexUrl: z.ZodString;
1214
+ deployKey: z.ZodString;
1215
+ expectedCommit: z.ZodString;
1216
+ expiresAt: z.ZodNumber;
1217
+ }, "strip", z.ZodTypeAny, {
1218
+ hostname: string;
1219
+ expiresAt: number;
1220
+ convexUrl: string;
1221
+ deployKey: string;
1222
+ expectedCommit: string;
1223
+ }, {
1224
+ hostname: string;
1225
+ expiresAt: number;
1226
+ convexUrl: string;
1227
+ deployKey: string;
1228
+ expectedCommit: string;
1229
+ }>;
1230
+ export type BffPreviewRegisterRequest = z.infer<typeof bffPreviewRegisterRequestSchema>;
1231
+ export declare const bffPreviewRemoveRequestSchema: z.ZodObject<{
1232
+ hostname: z.ZodString;
1233
+ }, "strip", z.ZodTypeAny, {
1234
+ hostname: string;
1235
+ }, {
1236
+ hostname: string;
1237
+ }>;
1238
+ export type BffPreviewRemoveRequest = z.infer<typeof bffPreviewRemoveRequestSchema>;
1239
+ export declare const transferSessionRecordSchema: z.ZodObject<{
1240
+ transferId: z.ZodString;
1241
+ tenantSlug: z.ZodString;
1242
+ convexUrl: z.ZodString;
1243
+ operation: z.ZodEnum<["export", "import"]>;
1244
+ tables: z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">;
1245
+ schemaHash: z.ZodString;
1246
+ includeFileStorage: z.ZodBoolean;
1247
+ maxBytes: z.ZodNumber;
1248
+ expiresAt: z.ZodNumber;
1249
+ state: z.ZodEnum<["exportReady", "importAwaitingUpload", "importUploaded", "importCommitted", "importFailed", "expired"]>;
1250
+ operationId: z.ZodOptional<z.ZodString>;
1251
+ bytes: z.ZodOptional<z.ZodNumber>;
1252
+ commitResult: z.ZodOptional<z.ZodObject<{
1253
+ ok: z.ZodBoolean;
1254
+ error: z.ZodOptional<z.ZodString>;
1255
+ logTail: z.ZodOptional<z.ZodString>;
1256
+ }, "strip", z.ZodTypeAny, {
1257
+ ok: boolean;
1258
+ error?: string | undefined;
1259
+ logTail?: string | undefined;
1260
+ }, {
1261
+ ok: boolean;
1262
+ error?: string | undefined;
1263
+ logTail?: string | undefined;
1264
+ }>>;
1265
+ }, "strip", z.ZodTypeAny, {
1266
+ tables: string[];
1267
+ schemaHash: string;
1268
+ includeFileStorage: boolean;
1269
+ transferId: string;
1270
+ expiresAt: number;
1271
+ operation: "export" | "import";
1272
+ convexUrl: string;
1273
+ tenantSlug: string;
1274
+ maxBytes: number;
1275
+ state: "exportReady" | "importAwaitingUpload" | "importUploaded" | "importCommitted" | "importFailed" | "expired";
1276
+ bytes?: number | undefined;
1277
+ operationId?: string | undefined;
1278
+ commitResult?: {
1279
+ ok: boolean;
1280
+ error?: string | undefined;
1281
+ logTail?: string | undefined;
1282
+ } | undefined;
1283
+ }, {
1284
+ tables: string[];
1285
+ schemaHash: string;
1286
+ includeFileStorage: boolean;
1287
+ transferId: string;
1288
+ expiresAt: number;
1289
+ operation: "export" | "import";
1290
+ convexUrl: string;
1291
+ tenantSlug: string;
1292
+ maxBytes: number;
1293
+ state: "exportReady" | "importAwaitingUpload" | "importUploaded" | "importCommitted" | "importFailed" | "expired";
1294
+ bytes?: number | undefined;
1295
+ operationId?: string | undefined;
1296
+ commitResult?: {
1297
+ ok: boolean;
1298
+ error?: string | undefined;
1299
+ logTail?: string | undefined;
1300
+ } | undefined;
1301
+ }>;
1302
+ export type TransferSessionRecord = z.infer<typeof transferSessionRecordSchema>;
1303
+ export declare const deployInternalTransferCreateResponseSchema: z.ZodObject<{
1304
+ ok: z.ZodLiteral<true>;
1305
+ transferId: z.ZodString;
1306
+ expiresAt: z.ZodNumber;
1307
+ bytes: z.ZodOptional<z.ZodNumber>;
1308
+ }, "strip", z.ZodTypeAny, {
1309
+ ok: true;
1310
+ transferId: string;
1311
+ expiresAt: number;
1312
+ bytes?: number | undefined;
1313
+ }, {
1314
+ ok: true;
1315
+ transferId: string;
1316
+ expiresAt: number;
1317
+ bytes?: number | undefined;
1318
+ }>;
1319
+ export declare const deployInternalSchemaDeployResponseSchema: z.ZodObject<{
1320
+ ok: z.ZodBoolean;
1321
+ durationMs: z.ZodNumber;
1322
+ prepareMs: z.ZodOptional<z.ZodNumber>;
1323
+ cliMs: z.ZodOptional<z.ZodNumber>;
1324
+ kernelCommit: z.ZodOptional<z.ZodString>;
1325
+ error: z.ZodOptional<z.ZodString>;
1326
+ logTail: z.ZodOptional<z.ZodString>;
1327
+ }, "strip", z.ZodTypeAny, {
1328
+ ok: boolean;
1329
+ durationMs: number;
1330
+ error?: string | undefined;
1331
+ logTail?: string | undefined;
1332
+ prepareMs?: number | undefined;
1333
+ cliMs?: number | undefined;
1334
+ kernelCommit?: string | undefined;
1335
+ }, {
1336
+ ok: boolean;
1337
+ durationMs: number;
1338
+ error?: string | undefined;
1339
+ logTail?: string | undefined;
1340
+ prepareMs?: number | undefined;
1341
+ cliMs?: number | undefined;
1342
+ kernelCommit?: string | undefined;
1343
+ }>;
1344
+ export declare const deployHealthResponseSchema: z.ZodObject<{
1345
+ ok: z.ZodBoolean;
1346
+ commit: z.ZodOptional<z.ZodString>;
1347
+ }, "strip", z.ZodTypeAny, {
1348
+ ok: boolean;
1349
+ commit?: string | undefined;
1350
+ }, {
1351
+ ok: boolean;
1352
+ commit?: string | undefined;
1353
+ }>;
1354
+ export type DeployHealthResponse = z.infer<typeof deployHealthResponseSchema>;
1355
+ /** Default JSON body size for non-streaming BFF routes (bytes). */
1356
+ export declare const BFF_JSON_BODY_LIMIT_BYTES: number;
1357
+ export { MAX_TRANSFER_BYTES as BFF_TRANSFER_MAX_BYTES };