@confect/server 9.0.0-next.9 → 9.0.1

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 (89) hide show
  1. package/CHANGELOG.md +168 -4
  2. package/dist/ActionCtx.d.ts +3 -10
  3. package/dist/ActionCtx.d.ts.map +1 -1
  4. package/dist/ActionRunner.d.ts +7 -14
  5. package/dist/ActionRunner.d.ts.map +1 -1
  6. package/dist/Auth.d.ts +15 -23
  7. package/dist/Auth.d.ts.map +1 -1
  8. package/dist/BlobNotFoundError.d.ts +5 -11
  9. package/dist/BlobNotFoundError.d.ts.map +1 -1
  10. package/dist/ConvexConfigProvider.d.ts +1 -8
  11. package/dist/ConvexConfigProvider.d.ts.map +1 -1
  12. package/dist/CronJob.d.ts +12 -19
  13. package/dist/CronJob.d.ts.map +1 -1
  14. package/dist/CronJobs.d.ts +11 -18
  15. package/dist/CronJobs.d.ts.map +1 -1
  16. package/dist/DataModel.d.ts +24 -29
  17. package/dist/DataModel.d.ts.map +1 -1
  18. package/dist/DatabaseReader.d.ts +4313 -4328
  19. package/dist/DatabaseReader.d.ts.map +1 -1
  20. package/dist/DatabaseSchema.d.ts +19 -24
  21. package/dist/DatabaseSchema.d.ts.map +1 -1
  22. package/dist/DatabaseWriter.d.ts +36 -42
  23. package/dist/DatabaseWriter.d.ts.map +1 -1
  24. package/dist/Document.d.ts +26 -36
  25. package/dist/Document.d.ts.map +1 -1
  26. package/dist/FunctionImpl.d.ts +11 -20
  27. package/dist/FunctionImpl.d.ts.map +1 -1
  28. package/dist/GroupImpl.d.ts +29 -35
  29. package/dist/GroupImpl.d.ts.map +1 -1
  30. package/dist/Handler.d.ts +34 -40
  31. package/dist/Handler.d.ts.map +1 -1
  32. package/dist/HttpApi.d.ts +19 -25
  33. package/dist/HttpApi.d.ts.map +1 -1
  34. package/dist/HttpApi.js +4 -4
  35. package/dist/HttpApi.js.map +1 -1
  36. package/dist/MutationCtx.d.ts +3 -10
  37. package/dist/MutationCtx.d.ts.map +1 -1
  38. package/dist/MutationRunner.d.ts +7 -14
  39. package/dist/MutationRunner.d.ts.map +1 -1
  40. package/dist/OrderedQuery.d.ts +15 -22
  41. package/dist/OrderedQuery.d.ts.map +1 -1
  42. package/dist/QueryCtx.d.ts +3 -10
  43. package/dist/QueryCtx.d.ts.map +1 -1
  44. package/dist/QueryInitializer.d.ts +32 -38
  45. package/dist/QueryInitializer.d.ts.map +1 -1
  46. package/dist/QueryRunner.d.ts +7 -14
  47. package/dist/QueryRunner.d.ts.map +1 -1
  48. package/dist/RegisteredConvexFunction.d.ts +1099 -1121
  49. package/dist/RegisteredConvexFunction.d.ts.map +1 -1
  50. package/dist/RegisteredConvexFunction.js +4 -4
  51. package/dist/RegisteredConvexFunction.js.map +1 -1
  52. package/dist/RegisteredFunction.d.ts +46 -64
  53. package/dist/RegisteredFunction.d.ts.map +1 -1
  54. package/dist/RegisteredFunction.js +4 -4
  55. package/dist/RegisteredFunction.js.map +1 -1
  56. package/dist/RegisteredFunctions.d.ts +20 -22
  57. package/dist/RegisteredFunctions.d.ts.map +1 -1
  58. package/dist/RegisteredNodeFunction.d.ts +4 -14
  59. package/dist/RegisteredNodeFunction.d.ts.map +1 -1
  60. package/dist/RegistryItem.d.ts +17 -27
  61. package/dist/RegistryItem.d.ts.map +1 -1
  62. package/dist/Scheduler.d.ts +14 -22
  63. package/dist/Scheduler.d.ts.map +1 -1
  64. package/dist/SchemaToValidator.d.ts +68 -64
  65. package/dist/SchemaToValidator.d.ts.map +1 -1
  66. package/dist/SchemaToValidator.js +2 -2
  67. package/dist/SchemaToValidator.js.map +1 -1
  68. package/dist/StorageActionWriter.d.ts +20 -28
  69. package/dist/StorageActionWriter.d.ts.map +1 -1
  70. package/dist/StorageReader.d.ts +13 -21
  71. package/dist/StorageReader.d.ts.map +1 -1
  72. package/dist/StorageWriter.d.ts +15 -23
  73. package/dist/StorageWriter.d.ts.map +1 -1
  74. package/dist/Table.d.ts +202 -203
  75. package/dist/Table.d.ts.map +1 -1
  76. package/dist/Table.js +2 -2
  77. package/dist/Table.js.map +1 -1
  78. package/dist/TableInfo.d.ts +35 -41
  79. package/dist/TableInfo.d.ts.map +1 -1
  80. package/dist/VectorSearch.d.ts +28 -35
  81. package/dist/VectorSearch.d.ts.map +1 -1
  82. package/dist/index.d.ts +35 -35
  83. package/dist/index.d.ts.map +1 -0
  84. package/dist/internal/utils.d.ts +10 -13
  85. package/dist/internal/utils.d.ts.map +1 -1
  86. package/dist/node.d.ts +2 -2
  87. package/dist/node.d.ts.map +1 -0
  88. package/dist/tsconfig.src.tsbuildinfo +1 -0
  89. package/package.json +10 -13
@@ -1,1133 +1,1111 @@
1
- import { Auth as Auth$1 } from "./Auth.js";
2
- import { Name, SystemTables, Table, WithName } from "./Table.js";
3
- import { AnyWithProps, Tables } from "./DatabaseSchema.js";
4
- import { DocumentDecodeError, DocumentEncodeError, WithoutSystemFields as WithoutSystemFields$1 } from "./Document.js";
5
- import { TableInfo } from "./TableInfo.js";
6
- import { DataModel, DocumentByName, FromSchema, TableInfoWithName, TableNames, ToConvex } from "./DataModel.js";
7
- import { OrderedQuery as OrderedQuery$1 } from "./OrderedQuery.js";
8
- import { GetByIdFailure, GetByIndexFailure } from "./QueryInitializer.js";
9
- import { DatabaseReader } from "./DatabaseReader.js";
10
- import { DatabaseWriter } from "./DatabaseWriter.js";
11
- import { MutationCtx } from "./MutationCtx.js";
12
- import { MutationRunner } from "./MutationRunner.js";
13
- import { QueryRunner } from "./QueryRunner.js";
14
- import { Scheduler as Scheduler$1 } from "./Scheduler.js";
15
- import { StorageReader as StorageReader$1 } from "./StorageReader.js";
16
- import { StorageWriter as StorageWriter$1 } from "./StorageWriter.js";
17
- import { Any } from "./RegisteredFunction.js";
18
- import { AnyWithProps as AnyWithProps$1 } from "./RegistryItem.js";
19
- import * as _confect_core_Ref0 from "@confect/core/Ref";
20
- import * as convex_server0 from "convex/server";
21
- import { GenericMutationCtx } from "convex/server";
22
- import * as Layer from "effect/Layer";
1
+ import { type GenericMutationCtx } from "convex/server";
23
2
  import * as Effect from "effect/Effect";
24
- import "effect/Schema";
25
- import * as effect_Duration0 from "effect/Duration";
26
- import * as effect_ParseResult0 from "effect/ParseResult";
27
- import * as convex_values0 from "convex/values";
28
- import * as effect_DateTime0 from "effect/DateTime";
29
- import * as _confect_core_Types0 from "@confect/core/Types";
30
-
31
- //#region src/RegisteredConvexFunction.d.ts
32
- declare namespace RegisteredConvexFunction_d_exports {
33
- export { MutationServices, make, mutationLayer };
34
- }
35
- declare const make: (databaseSchema: AnyWithProps, {
36
- functionSpec,
37
- handler
38
- }: AnyWithProps$1) => Any;
39
- declare const mutationLayer: <Schema extends AnyWithProps>(schema: Schema, ctx: GenericMutationCtx<ToConvex<FromSchema<Schema>>>) => Layer.Layer<Auth$1 | (<Query extends _confect_core_Ref0.AnyQuery>(query: Query, ...args: _confect_core_Ref0.OptionalArgs<Query>) => Effect.Effect<_confect_core_Ref0.Returns<Query>, _confect_core_Ref0.Error<Query> | effect_ParseResult0.ParseError>) | GenericMutationCtx<ToConvex<FromSchema<Schema>>> | {
40
- table: <const TableName extends "_scheduled_functions" | "_storage" | Name<Tables<Schema>>>(tableName: TableName) => {
41
- readonly get: {
42
- (id: convex_values0.GenericId<TableName>): Effect.Effect<(TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
43
- name: typeof Schema.String;
44
- args: Schema.Array$<typeof Schema.Any>;
45
- scheduledTime: typeof Schema.Number;
46
- completedTime: Schema.optionalWith<typeof Schema.Number, {
47
- exact: true;
48
- }>;
49
- state: Schema.Union<[Schema.Struct<{
50
- kind: Schema.Literal<["pending"]>;
51
- }>, Schema.Struct<{
52
- kind: Schema.Literal<["inProgress"]>;
53
- }>, Schema.Struct<{
54
- kind: Schema.Literal<["success"]>;
55
- }>, Schema.Struct<{
56
- kind: Schema.Literal<["failed"]>;
57
- error: typeof Schema.String;
58
- }>, Schema.Struct<{
59
- kind: Schema.Literal<["canceled"]>;
60
- }>]>;
61
- }>, convex_values0.VObject<{
62
- name: string;
63
- args: any[];
64
- scheduledTime: number;
65
- state: {
66
- kind: "pending";
67
- } | {
68
- kind: "inProgress";
69
- } | {
70
- kind: "success";
71
- } | {
72
- kind: "failed";
73
- error: string;
74
- } | {
75
- kind: "canceled";
76
- };
77
- completedTime?: number;
78
- }, {
79
- name: convex_values0.VString<string, "required">;
80
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
81
- scheduledTime: convex_values0.VFloat64<number, "required">;
82
- state: convex_values0.VUnion<{
83
- kind: "pending";
84
- } | {
85
- kind: "inProgress";
86
- } | {
87
- kind: "success";
88
- } | {
89
- kind: "failed";
90
- error: string;
91
- } | {
92
- kind: "canceled";
93
- }, [convex_values0.VObject<{
94
- kind: "pending";
95
- }, {
96
- kind: convex_values0.VLiteral<"pending", "required">;
97
- }, "required", "kind">, convex_values0.VObject<{
98
- kind: "inProgress";
99
- }, {
100
- kind: convex_values0.VLiteral<"inProgress", "required">;
101
- }, "required", "kind">, convex_values0.VObject<{
102
- kind: "success";
103
- }, {
104
- kind: convex_values0.VLiteral<"success", "required">;
105
- }, "required", "kind">, convex_values0.VObject<{
106
- kind: "failed";
107
- error: string;
108
- }, {
109
- kind: convex_values0.VLiteral<"failed", "required">;
110
- error: convex_values0.VString<string, "required">;
111
- }, "required", "kind" | "error">, convex_values0.VObject<{
112
- kind: "canceled";
113
- }, {
114
- kind: convex_values0.VLiteral<"canceled", "required">;
115
- }, "required", "kind">], "required", "kind" | "error">;
116
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
117
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
118
- sha256: typeof Schema.String;
119
- size: typeof Schema.Number;
120
- contentType: Schema.optionalWith<typeof Schema.String, {
121
- exact: true;
122
- }>;
123
- }>, convex_values0.VObject<{
124
- sha256: string;
125
- size: number;
126
- contentType?: string;
127
- }, {
128
- sha256: convex_values0.VString<string, "required">;
129
- size: convex_values0.VFloat64<number, "required">;
130
- contentType: convex_values0.VString<string | undefined, "optional">;
131
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["document"], DocumentDecodeError | GetByIdFailure, never>;
132
- <IndexName extends keyof (TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
133
- name: typeof Schema.String;
134
- args: Schema.Array$<typeof Schema.Any>;
135
- scheduledTime: typeof Schema.Number;
136
- completedTime: Schema.optionalWith<typeof Schema.Number, {
137
- exact: true;
138
- }>;
139
- state: Schema.Union<[Schema.Struct<{
140
- kind: Schema.Literal<["pending"]>;
141
- }>, Schema.Struct<{
142
- kind: Schema.Literal<["inProgress"]>;
143
- }>, Schema.Struct<{
144
- kind: Schema.Literal<["success"]>;
145
- }>, Schema.Struct<{
146
- kind: Schema.Literal<["failed"]>;
147
- error: typeof Schema.String;
148
- }>, Schema.Struct<{
149
- kind: Schema.Literal<["canceled"]>;
150
- }>]>;
151
- }>, convex_values0.VObject<{
152
- name: string;
153
- args: any[];
154
- scheduledTime: number;
155
- state: {
156
- kind: "pending";
157
- } | {
158
- kind: "inProgress";
159
- } | {
160
- kind: "success";
161
- } | {
162
- kind: "failed";
163
- error: string;
164
- } | {
165
- kind: "canceled";
166
- };
167
- completedTime?: number;
168
- }, {
169
- name: convex_values0.VString<string, "required">;
170
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
171
- scheduledTime: convex_values0.VFloat64<number, "required">;
172
- state: convex_values0.VUnion<{
173
- kind: "pending";
174
- } | {
175
- kind: "inProgress";
176
- } | {
177
- kind: "success";
178
- } | {
179
- kind: "failed";
180
- error: string;
181
- } | {
182
- kind: "canceled";
183
- }, [convex_values0.VObject<{
184
- kind: "pending";
185
- }, {
186
- kind: convex_values0.VLiteral<"pending", "required">;
187
- }, "required", "kind">, convex_values0.VObject<{
188
- kind: "inProgress";
189
- }, {
190
- kind: convex_values0.VLiteral<"inProgress", "required">;
191
- }, "required", "kind">, convex_values0.VObject<{
192
- kind: "success";
193
- }, {
194
- kind: convex_values0.VLiteral<"success", "required">;
195
- }, "required", "kind">, convex_values0.VObject<{
196
- kind: "failed";
197
- error: string;
198
- }, {
199
- kind: convex_values0.VLiteral<"failed", "required">;
200
- error: convex_values0.VString<string, "required">;
201
- }, "required", "kind" | "error">, convex_values0.VObject<{
202
- kind: "canceled";
203
- }, {
204
- kind: convex_values0.VLiteral<"canceled", "required">;
205
- }, "required", "kind">], "required", "kind" | "error">;
206
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
207
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
208
- sha256: typeof Schema.String;
209
- size: typeof Schema.Number;
210
- contentType: Schema.optionalWith<typeof Schema.String, {
211
- exact: true;
212
- }>;
213
- }>, convex_values0.VObject<{
214
- sha256: string;
215
- size: number;
216
- contentType?: string;
217
- }, {
218
- sha256: convex_values0.VString<string, "required">;
219
- size: convex_values0.VFloat64<number, "required">;
220
- contentType: convex_values0.VString<string | undefined, "optional">;
221
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["indexes"]>(indexName: IndexName, ...indexFieldValues: _confect_core_Types0.IndexFieldTypesForEq<ToConvex<DataModel<SystemTables | Tables<Schema>>>, TableName, (TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
222
- name: typeof Schema.String;
223
- args: Schema.Array$<typeof Schema.Any>;
224
- scheduledTime: typeof Schema.Number;
225
- completedTime: Schema.optionalWith<typeof Schema.Number, {
226
- exact: true;
227
- }>;
228
- state: Schema.Union<[Schema.Struct<{
229
- kind: Schema.Literal<["pending"]>;
230
- }>, Schema.Struct<{
231
- kind: Schema.Literal<["inProgress"]>;
232
- }>, Schema.Struct<{
233
- kind: Schema.Literal<["success"]>;
234
- }>, Schema.Struct<{
235
- kind: Schema.Literal<["failed"]>;
236
- error: typeof Schema.String;
237
- }>, Schema.Struct<{
238
- kind: Schema.Literal<["canceled"]>;
239
- }>]>;
240
- }>, convex_values0.VObject<{
241
- name: string;
242
- args: any[];
243
- scheduledTime: number;
244
- state: {
245
- kind: "pending";
246
- } | {
247
- kind: "inProgress";
248
- } | {
249
- kind: "success";
250
- } | {
251
- kind: "failed";
252
- error: string;
253
- } | {
254
- kind: "canceled";
255
- };
256
- completedTime?: number;
257
- }, {
258
- name: convex_values0.VString<string, "required">;
259
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
260
- scheduledTime: convex_values0.VFloat64<number, "required">;
261
- state: convex_values0.VUnion<{
262
- kind: "pending";
263
- } | {
264
- kind: "inProgress";
265
- } | {
266
- kind: "success";
267
- } | {
268
- kind: "failed";
269
- error: string;
270
- } | {
271
- kind: "canceled";
272
- }, [convex_values0.VObject<{
273
- kind: "pending";
274
- }, {
275
- kind: convex_values0.VLiteral<"pending", "required">;
276
- }, "required", "kind">, convex_values0.VObject<{
277
- kind: "inProgress";
278
- }, {
279
- kind: convex_values0.VLiteral<"inProgress", "required">;
280
- }, "required", "kind">, convex_values0.VObject<{
281
- kind: "success";
282
- }, {
283
- kind: convex_values0.VLiteral<"success", "required">;
284
- }, "required", "kind">, convex_values0.VObject<{
285
- kind: "failed";
286
- error: string;
287
- }, {
288
- kind: convex_values0.VLiteral<"failed", "required">;
289
- error: convex_values0.VString<string, "required">;
290
- }, "required", "kind" | "error">, convex_values0.VObject<{
291
- kind: "canceled";
292
- }, {
293
- kind: convex_values0.VLiteral<"canceled", "required">;
294
- }, "required", "kind">], "required", "kind" | "error">;
295
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
296
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
297
- sha256: typeof Schema.String;
298
- size: typeof Schema.Number;
299
- contentType: Schema.optionalWith<typeof Schema.String, {
300
- exact: true;
301
- }>;
302
- }>, convex_values0.VObject<{
303
- sha256: string;
304
- size: number;
305
- contentType?: string;
306
- }, {
307
- sha256: convex_values0.VString<string, "required">;
308
- size: convex_values0.VFloat64<number, "required">;
309
- contentType: convex_values0.VString<string | undefined, "optional">;
310
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["indexes"][IndexName]>): Effect.Effect<(TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
311
- name: typeof Schema.String;
312
- args: Schema.Array$<typeof Schema.Any>;
313
- scheduledTime: typeof Schema.Number;
314
- completedTime: Schema.optionalWith<typeof Schema.Number, {
315
- exact: true;
316
- }>;
317
- state: Schema.Union<[Schema.Struct<{
318
- kind: Schema.Literal<["pending"]>;
319
- }>, Schema.Struct<{
320
- kind: Schema.Literal<["inProgress"]>;
321
- }>, Schema.Struct<{
322
- kind: Schema.Literal<["success"]>;
323
- }>, Schema.Struct<{
324
- kind: Schema.Literal<["failed"]>;
325
- error: typeof Schema.String;
326
- }>, Schema.Struct<{
327
- kind: Schema.Literal<["canceled"]>;
328
- }>]>;
329
- }>, convex_values0.VObject<{
330
- name: string;
331
- args: any[];
332
- scheduledTime: number;
333
- state: {
334
- kind: "pending";
335
- } | {
336
- kind: "inProgress";
337
- } | {
338
- kind: "success";
339
- } | {
340
- kind: "failed";
341
- error: string;
342
- } | {
343
- kind: "canceled";
344
- };
345
- completedTime?: number;
346
- }, {
347
- name: convex_values0.VString<string, "required">;
348
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
349
- scheduledTime: convex_values0.VFloat64<number, "required">;
350
- state: convex_values0.VUnion<{
351
- kind: "pending";
352
- } | {
353
- kind: "inProgress";
354
- } | {
355
- kind: "success";
356
- } | {
357
- kind: "failed";
358
- error: string;
359
- } | {
360
- kind: "canceled";
361
- }, [convex_values0.VObject<{
362
- kind: "pending";
363
- }, {
364
- kind: convex_values0.VLiteral<"pending", "required">;
365
- }, "required", "kind">, convex_values0.VObject<{
366
- kind: "inProgress";
367
- }, {
368
- kind: convex_values0.VLiteral<"inProgress", "required">;
369
- }, "required", "kind">, convex_values0.VObject<{
370
- kind: "success";
371
- }, {
372
- kind: convex_values0.VLiteral<"success", "required">;
373
- }, "required", "kind">, convex_values0.VObject<{
374
- kind: "failed";
375
- error: string;
376
- }, {
377
- kind: convex_values0.VLiteral<"failed", "required">;
378
- error: convex_values0.VString<string, "required">;
379
- }, "required", "kind" | "error">, convex_values0.VObject<{
380
- kind: "canceled";
381
- }, {
382
- kind: convex_values0.VLiteral<"canceled", "required">;
383
- }, "required", "kind">], "required", "kind" | "error">;
384
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
385
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
386
- sha256: typeof Schema.String;
387
- size: typeof Schema.Number;
388
- contentType: Schema.optionalWith<typeof Schema.String, {
389
- exact: true;
390
- }>;
391
- }>, convex_values0.VObject<{
392
- sha256: string;
393
- size: number;
394
- contentType?: string;
395
- }, {
396
- sha256: convex_values0.VString<string, "required">;
397
- size: convex_values0.VFloat64<number, "required">;
398
- contentType: convex_values0.VString<string | undefined, "optional">;
399
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["document"], DocumentDecodeError | GetByIndexFailure, never>;
400
- };
401
- readonly index: {
402
- <IndexName extends keyof (TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
403
- name: typeof Schema.String;
404
- args: Schema.Array$<typeof Schema.Any>;
405
- scheduledTime: typeof Schema.Number;
406
- completedTime: Schema.optionalWith<typeof Schema.Number, {
407
- exact: true;
408
- }>;
409
- state: Schema.Union<[Schema.Struct<{
410
- kind: Schema.Literal<["pending"]>;
411
- }>, Schema.Struct<{
412
- kind: Schema.Literal<["inProgress"]>;
413
- }>, Schema.Struct<{
414
- kind: Schema.Literal<["success"]>;
415
- }>, Schema.Struct<{
416
- kind: Schema.Literal<["failed"]>;
417
- error: typeof Schema.String;
418
- }>, Schema.Struct<{
419
- kind: Schema.Literal<["canceled"]>;
420
- }>]>;
421
- }>, convex_values0.VObject<{
422
- name: string;
423
- args: any[];
424
- scheduledTime: number;
425
- state: {
426
- kind: "pending";
427
- } | {
428
- kind: "inProgress";
429
- } | {
430
- kind: "success";
431
- } | {
432
- kind: "failed";
433
- error: string;
434
- } | {
435
- kind: "canceled";
3
+ import * as Layer from "effect/Layer";
4
+ import * as Schema from "effect/Schema";
5
+ import * as Auth from "./Auth";
6
+ import * as DatabaseReader from "./DatabaseReader";
7
+ import type * as DatabaseSchema from "./DatabaseSchema";
8
+ import * as DatabaseWriter from "./DatabaseWriter";
9
+ import type * as DataModel from "./DataModel";
10
+ import * as MutationCtx from "./MutationCtx";
11
+ import * as MutationRunner from "./MutationRunner";
12
+ import * as QueryRunner from "./QueryRunner";
13
+ import * as RegisteredFunction from "./RegisteredFunction";
14
+ import type * as RegistryItem from "./RegistryItem";
15
+ import * as Scheduler from "./Scheduler";
16
+ import { StorageReader } from "./StorageReader";
17
+ import { StorageWriter } from "./StorageWriter";
18
+ export declare const make: (databaseSchema: DatabaseSchema.AnyWithProps, { functionSpec, handler }: RegistryItem.AnyWithProps) => RegisteredFunction.Any;
19
+ export declare const mutationLayer: <Schema extends DatabaseSchema.AnyWithProps>(schema: Schema, ctx: GenericMutationCtx<DataModel.ToConvex<DataModel.FromSchema<Schema>>>) => Layer.Layer<Auth.Auth | (<Mutation extends import("@confect/core/Ref").AnyMutation>(mutation: Mutation, ...args: import("@confect/core/Ref").OptionalArgs<Mutation>) => Effect.Effect<import("@confect/core/Ref").Returns<Mutation>, import("@confect/core/Ref").Error<Mutation> | import("effect/ParseResult").ParseError>) | (<Query extends import("@confect/core/Ref").AnyQuery>(query: Query, ...args: import("@confect/core/Ref").OptionalArgs<Query>) => Effect.Effect<import("@confect/core/Ref").Returns<Query>, import("@confect/core/Ref").Error<Query> | import("effect/ParseResult").ParseError>) | {
20
+ runAfter: <Ref_ extends import("@confect/core/Ref").AnyMutation | import("@confect/core/Ref").AnyAction>(delay: import("effect/Duration").Duration, ref: Ref_, ...args: import("@confect/core/Ref").OptionalArgs<Ref_>) => Effect.Effect<import("convex/values").GenericId<"_scheduled_functions">, never, never>;
21
+ runAt: <Ref_ extends import("@confect/core/Ref").AnyMutation | import("@confect/core/Ref").AnyAction>(dateTime: import("effect/DateTime").DateTime, ref: Ref_, ...args: import("@confect/core/Ref").OptionalArgs<Ref_>) => Effect.Effect<import("convex/values").GenericId<"_scheduled_functions">, never, never>;
22
+ } | StorageReader | StorageWriter | GenericMutationCtx<DataModel.ToConvex<DataModel.FromSchema<Schema>>> | {
23
+ table: <const TableName extends "_scheduled_functions" | "_storage" | import("./Table").Name<DatabaseSchema.Tables<Schema>>>(tableName: TableName) => {
24
+ readonly get: {
25
+ (id: import("convex/values").GenericId<TableName>): Effect.Effect<(import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
26
+ name: typeof Schema.String;
27
+ args: Schema.Array$<typeof Schema.Any>;
28
+ scheduledTime: typeof Schema.Number;
29
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
30
+ exact: true;
31
+ }>;
32
+ state: Schema.Union<[Schema.Struct<{
33
+ kind: Schema.Literal<["pending"]>;
34
+ }>, Schema.Struct<{
35
+ kind: Schema.Literal<["inProgress"]>;
36
+ }>, Schema.Struct<{
37
+ kind: Schema.Literal<["success"]>;
38
+ }>, Schema.Struct<{
39
+ kind: Schema.Literal<["failed"]>;
40
+ error: typeof Schema.String;
41
+ }>, Schema.Struct<{
42
+ kind: Schema.Literal<["canceled"]>;
43
+ }>]>;
44
+ }>, import("convex/values").VObject<{
45
+ name: string;
46
+ args: any[];
47
+ scheduledTime: number;
48
+ state: {
49
+ kind: "pending";
50
+ } | {
51
+ kind: "inProgress";
52
+ } | {
53
+ kind: "success";
54
+ } | {
55
+ kind: "failed";
56
+ error: string;
57
+ } | {
58
+ kind: "canceled";
59
+ };
60
+ completedTime?: number;
61
+ }, {
62
+ name: import("convex/values").VString<string, "required">;
63
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
64
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
65
+ state: import("convex/values").VUnion<{
66
+ kind: "pending";
67
+ } | {
68
+ kind: "inProgress";
69
+ } | {
70
+ kind: "success";
71
+ } | {
72
+ kind: "failed";
73
+ error: string;
74
+ } | {
75
+ kind: "canceled";
76
+ }, [import("convex/values").VObject<{
77
+ kind: "pending";
78
+ }, {
79
+ kind: import("convex/values").VLiteral<"pending", "required">;
80
+ }, "required", "kind">, import("convex/values").VObject<{
81
+ kind: "inProgress";
82
+ }, {
83
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
84
+ }, "required", "kind">, import("convex/values").VObject<{
85
+ kind: "success";
86
+ }, {
87
+ kind: import("convex/values").VLiteral<"success", "required">;
88
+ }, "required", "kind">, import("convex/values").VObject<{
89
+ kind: "failed";
90
+ error: string;
91
+ }, {
92
+ kind: import("convex/values").VLiteral<"failed", "required">;
93
+ error: import("convex/values").VString<string, "required">;
94
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
95
+ kind: "canceled";
96
+ }, {
97
+ kind: import("convex/values").VLiteral<"canceled", "required">;
98
+ }, "required", "kind">], "required", "kind" | "error">;
99
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
100
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
101
+ sha256: typeof Schema.String;
102
+ size: typeof Schema.Number;
103
+ contentType: Schema.optionalWith<typeof Schema.String, {
104
+ exact: true;
105
+ }>;
106
+ }>, import("convex/values").VObject<{
107
+ sha256: string;
108
+ size: number;
109
+ contentType?: string;
110
+ }, {
111
+ sha256: import("convex/values").VString<string, "required">;
112
+ size: import("convex/values").VFloat64<number, "required">;
113
+ contentType: import("convex/values").VString<string | undefined, "optional">;
114
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["document"], import("./Document").DocumentDecodeError | import("./QueryInitializer").GetByIdFailure, never>;
115
+ <IndexName extends keyof (import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
116
+ name: typeof Schema.String;
117
+ args: Schema.Array$<typeof Schema.Any>;
118
+ scheduledTime: typeof Schema.Number;
119
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
120
+ exact: true;
121
+ }>;
122
+ state: Schema.Union<[Schema.Struct<{
123
+ kind: Schema.Literal<["pending"]>;
124
+ }>, Schema.Struct<{
125
+ kind: Schema.Literal<["inProgress"]>;
126
+ }>, Schema.Struct<{
127
+ kind: Schema.Literal<["success"]>;
128
+ }>, Schema.Struct<{
129
+ kind: Schema.Literal<["failed"]>;
130
+ error: typeof Schema.String;
131
+ }>, Schema.Struct<{
132
+ kind: Schema.Literal<["canceled"]>;
133
+ }>]>;
134
+ }>, import("convex/values").VObject<{
135
+ name: string;
136
+ args: any[];
137
+ scheduledTime: number;
138
+ state: {
139
+ kind: "pending";
140
+ } | {
141
+ kind: "inProgress";
142
+ } | {
143
+ kind: "success";
144
+ } | {
145
+ kind: "failed";
146
+ error: string;
147
+ } | {
148
+ kind: "canceled";
149
+ };
150
+ completedTime?: number;
151
+ }, {
152
+ name: import("convex/values").VString<string, "required">;
153
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
154
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
155
+ state: import("convex/values").VUnion<{
156
+ kind: "pending";
157
+ } | {
158
+ kind: "inProgress";
159
+ } | {
160
+ kind: "success";
161
+ } | {
162
+ kind: "failed";
163
+ error: string;
164
+ } | {
165
+ kind: "canceled";
166
+ }, [import("convex/values").VObject<{
167
+ kind: "pending";
168
+ }, {
169
+ kind: import("convex/values").VLiteral<"pending", "required">;
170
+ }, "required", "kind">, import("convex/values").VObject<{
171
+ kind: "inProgress";
172
+ }, {
173
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
174
+ }, "required", "kind">, import("convex/values").VObject<{
175
+ kind: "success";
176
+ }, {
177
+ kind: import("convex/values").VLiteral<"success", "required">;
178
+ }, "required", "kind">, import("convex/values").VObject<{
179
+ kind: "failed";
180
+ error: string;
181
+ }, {
182
+ kind: import("convex/values").VLiteral<"failed", "required">;
183
+ error: import("convex/values").VString<string, "required">;
184
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
185
+ kind: "canceled";
186
+ }, {
187
+ kind: import("convex/values").VLiteral<"canceled", "required">;
188
+ }, "required", "kind">], "required", "kind" | "error">;
189
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
190
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
191
+ sha256: typeof Schema.String;
192
+ size: typeof Schema.Number;
193
+ contentType: Schema.optionalWith<typeof Schema.String, {
194
+ exact: true;
195
+ }>;
196
+ }>, import("convex/values").VObject<{
197
+ sha256: string;
198
+ size: number;
199
+ contentType?: string;
200
+ }, {
201
+ sha256: import("convex/values").VString<string, "required">;
202
+ size: import("convex/values").VFloat64<number, "required">;
203
+ contentType: import("convex/values").VString<string | undefined, "optional">;
204
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["indexes"]>(indexName: IndexName, ...indexFieldValues: import("@confect/core/Types").IndexFieldTypesForEq<DataModel.ToConvex<DataModel.DataModel<import("./Table").SystemTables | DatabaseSchema.Tables<Schema>>>, TableName, (import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
205
+ name: typeof Schema.String;
206
+ args: Schema.Array$<typeof Schema.Any>;
207
+ scheduledTime: typeof Schema.Number;
208
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
209
+ exact: true;
210
+ }>;
211
+ state: Schema.Union<[Schema.Struct<{
212
+ kind: Schema.Literal<["pending"]>;
213
+ }>, Schema.Struct<{
214
+ kind: Schema.Literal<["inProgress"]>;
215
+ }>, Schema.Struct<{
216
+ kind: Schema.Literal<["success"]>;
217
+ }>, Schema.Struct<{
218
+ kind: Schema.Literal<["failed"]>;
219
+ error: typeof Schema.String;
220
+ }>, Schema.Struct<{
221
+ kind: Schema.Literal<["canceled"]>;
222
+ }>]>;
223
+ }>, import("convex/values").VObject<{
224
+ name: string;
225
+ args: any[];
226
+ scheduledTime: number;
227
+ state: {
228
+ kind: "pending";
229
+ } | {
230
+ kind: "inProgress";
231
+ } | {
232
+ kind: "success";
233
+ } | {
234
+ kind: "failed";
235
+ error: string;
236
+ } | {
237
+ kind: "canceled";
238
+ };
239
+ completedTime?: number;
240
+ }, {
241
+ name: import("convex/values").VString<string, "required">;
242
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
243
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
244
+ state: import("convex/values").VUnion<{
245
+ kind: "pending";
246
+ } | {
247
+ kind: "inProgress";
248
+ } | {
249
+ kind: "success";
250
+ } | {
251
+ kind: "failed";
252
+ error: string;
253
+ } | {
254
+ kind: "canceled";
255
+ }, [import("convex/values").VObject<{
256
+ kind: "pending";
257
+ }, {
258
+ kind: import("convex/values").VLiteral<"pending", "required">;
259
+ }, "required", "kind">, import("convex/values").VObject<{
260
+ kind: "inProgress";
261
+ }, {
262
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
263
+ }, "required", "kind">, import("convex/values").VObject<{
264
+ kind: "success";
265
+ }, {
266
+ kind: import("convex/values").VLiteral<"success", "required">;
267
+ }, "required", "kind">, import("convex/values").VObject<{
268
+ kind: "failed";
269
+ error: string;
270
+ }, {
271
+ kind: import("convex/values").VLiteral<"failed", "required">;
272
+ error: import("convex/values").VString<string, "required">;
273
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
274
+ kind: "canceled";
275
+ }, {
276
+ kind: import("convex/values").VLiteral<"canceled", "required">;
277
+ }, "required", "kind">], "required", "kind" | "error">;
278
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
279
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
280
+ sha256: typeof Schema.String;
281
+ size: typeof Schema.Number;
282
+ contentType: Schema.optionalWith<typeof Schema.String, {
283
+ exact: true;
284
+ }>;
285
+ }>, import("convex/values").VObject<{
286
+ sha256: string;
287
+ size: number;
288
+ contentType?: string;
289
+ }, {
290
+ sha256: import("convex/values").VString<string, "required">;
291
+ size: import("convex/values").VFloat64<number, "required">;
292
+ contentType: import("convex/values").VString<string | undefined, "optional">;
293
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["indexes"][IndexName]>): Effect.Effect<(import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
294
+ name: typeof Schema.String;
295
+ args: Schema.Array$<typeof Schema.Any>;
296
+ scheduledTime: typeof Schema.Number;
297
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
298
+ exact: true;
299
+ }>;
300
+ state: Schema.Union<[Schema.Struct<{
301
+ kind: Schema.Literal<["pending"]>;
302
+ }>, Schema.Struct<{
303
+ kind: Schema.Literal<["inProgress"]>;
304
+ }>, Schema.Struct<{
305
+ kind: Schema.Literal<["success"]>;
306
+ }>, Schema.Struct<{
307
+ kind: Schema.Literal<["failed"]>;
308
+ error: typeof Schema.String;
309
+ }>, Schema.Struct<{
310
+ kind: Schema.Literal<["canceled"]>;
311
+ }>]>;
312
+ }>, import("convex/values").VObject<{
313
+ name: string;
314
+ args: any[];
315
+ scheduledTime: number;
316
+ state: {
317
+ kind: "pending";
318
+ } | {
319
+ kind: "inProgress";
320
+ } | {
321
+ kind: "success";
322
+ } | {
323
+ kind: "failed";
324
+ error: string;
325
+ } | {
326
+ kind: "canceled";
327
+ };
328
+ completedTime?: number;
329
+ }, {
330
+ name: import("convex/values").VString<string, "required">;
331
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
332
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
333
+ state: import("convex/values").VUnion<{
334
+ kind: "pending";
335
+ } | {
336
+ kind: "inProgress";
337
+ } | {
338
+ kind: "success";
339
+ } | {
340
+ kind: "failed";
341
+ error: string;
342
+ } | {
343
+ kind: "canceled";
344
+ }, [import("convex/values").VObject<{
345
+ kind: "pending";
346
+ }, {
347
+ kind: import("convex/values").VLiteral<"pending", "required">;
348
+ }, "required", "kind">, import("convex/values").VObject<{
349
+ kind: "inProgress";
350
+ }, {
351
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
352
+ }, "required", "kind">, import("convex/values").VObject<{
353
+ kind: "success";
354
+ }, {
355
+ kind: import("convex/values").VLiteral<"success", "required">;
356
+ }, "required", "kind">, import("convex/values").VObject<{
357
+ kind: "failed";
358
+ error: string;
359
+ }, {
360
+ kind: import("convex/values").VLiteral<"failed", "required">;
361
+ error: import("convex/values").VString<string, "required">;
362
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
363
+ kind: "canceled";
364
+ }, {
365
+ kind: import("convex/values").VLiteral<"canceled", "required">;
366
+ }, "required", "kind">], "required", "kind" | "error">;
367
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
368
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
369
+ sha256: typeof Schema.String;
370
+ size: typeof Schema.Number;
371
+ contentType: Schema.optionalWith<typeof Schema.String, {
372
+ exact: true;
373
+ }>;
374
+ }>, import("convex/values").VObject<{
375
+ sha256: string;
376
+ size: number;
377
+ contentType?: string;
378
+ }, {
379
+ sha256: import("convex/values").VString<string, "required">;
380
+ size: import("convex/values").VFloat64<number, "required">;
381
+ contentType: import("convex/values").VString<string | undefined, "optional">;
382
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["document"], import("./Document").DocumentDecodeError | import("./QueryInitializer").GetByIndexFailure, never>;
436
383
  };
437
- completedTime?: number;
438
- }, {
439
- name: convex_values0.VString<string, "required">;
440
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
441
- scheduledTime: convex_values0.VFloat64<number, "required">;
442
- state: convex_values0.VUnion<{
443
- kind: "pending";
444
- } | {
445
- kind: "inProgress";
446
- } | {
447
- kind: "success";
448
- } | {
449
- kind: "failed";
450
- error: string;
451
- } | {
452
- kind: "canceled";
453
- }, [convex_values0.VObject<{
454
- kind: "pending";
455
- }, {
456
- kind: convex_values0.VLiteral<"pending", "required">;
457
- }, "required", "kind">, convex_values0.VObject<{
458
- kind: "inProgress";
459
- }, {
460
- kind: convex_values0.VLiteral<"inProgress", "required">;
461
- }, "required", "kind">, convex_values0.VObject<{
462
- kind: "success";
463
- }, {
464
- kind: convex_values0.VLiteral<"success", "required">;
465
- }, "required", "kind">, convex_values0.VObject<{
466
- kind: "failed";
467
- error: string;
468
- }, {
469
- kind: convex_values0.VLiteral<"failed", "required">;
470
- error: convex_values0.VString<string, "required">;
471
- }, "required", "kind" | "error">, convex_values0.VObject<{
472
- kind: "canceled";
473
- }, {
474
- kind: convex_values0.VLiteral<"canceled", "required">;
475
- }, "required", "kind">], "required", "kind" | "error">;
476
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
477
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
478
- sha256: typeof Schema.String;
479
- size: typeof Schema.Number;
480
- contentType: Schema.optionalWith<typeof Schema.String, {
481
- exact: true;
482
- }>;
483
- }>, convex_values0.VObject<{
484
- sha256: string;
485
- size: number;
486
- contentType?: string;
487
- }, {
488
- sha256: convex_values0.VString<string, "required">;
489
- size: convex_values0.VFloat64<number, "required">;
490
- contentType: convex_values0.VString<string | undefined, "optional">;
491
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["indexes"]>(indexName: IndexName, indexRange?: ((q: convex_server0.IndexRangeBuilder<(TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
492
- name: typeof Schema.String;
493
- args: Schema.Array$<typeof Schema.Any>;
494
- scheduledTime: typeof Schema.Number;
495
- completedTime: Schema.optionalWith<typeof Schema.Number, {
496
- exact: true;
497
- }>;
498
- state: Schema.Union<[Schema.Struct<{
499
- kind: Schema.Literal<["pending"]>;
500
- }>, Schema.Struct<{
501
- kind: Schema.Literal<["inProgress"]>;
502
- }>, Schema.Struct<{
503
- kind: Schema.Literal<["success"]>;
504
- }>, Schema.Struct<{
505
- kind: Schema.Literal<["failed"]>;
506
- error: typeof Schema.String;
507
- }>, Schema.Struct<{
508
- kind: Schema.Literal<["canceled"]>;
509
- }>]>;
510
- }>, convex_values0.VObject<{
511
- name: string;
512
- args: any[];
513
- scheduledTime: number;
514
- state: {
515
- kind: "pending";
516
- } | {
517
- kind: "inProgress";
518
- } | {
519
- kind: "success";
520
- } | {
521
- kind: "failed";
522
- error: string;
523
- } | {
524
- kind: "canceled";
384
+ readonly index: {
385
+ <IndexName extends keyof (import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
386
+ name: typeof Schema.String;
387
+ args: Schema.Array$<typeof Schema.Any>;
388
+ scheduledTime: typeof Schema.Number;
389
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
390
+ exact: true;
391
+ }>;
392
+ state: Schema.Union<[Schema.Struct<{
393
+ kind: Schema.Literal<["pending"]>;
394
+ }>, Schema.Struct<{
395
+ kind: Schema.Literal<["inProgress"]>;
396
+ }>, Schema.Struct<{
397
+ kind: Schema.Literal<["success"]>;
398
+ }>, Schema.Struct<{
399
+ kind: Schema.Literal<["failed"]>;
400
+ error: typeof Schema.String;
401
+ }>, Schema.Struct<{
402
+ kind: Schema.Literal<["canceled"]>;
403
+ }>]>;
404
+ }>, import("convex/values").VObject<{
405
+ name: string;
406
+ args: any[];
407
+ scheduledTime: number;
408
+ state: {
409
+ kind: "pending";
410
+ } | {
411
+ kind: "inProgress";
412
+ } | {
413
+ kind: "success";
414
+ } | {
415
+ kind: "failed";
416
+ error: string;
417
+ } | {
418
+ kind: "canceled";
419
+ };
420
+ completedTime?: number;
421
+ }, {
422
+ name: import("convex/values").VString<string, "required">;
423
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
424
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
425
+ state: import("convex/values").VUnion<{
426
+ kind: "pending";
427
+ } | {
428
+ kind: "inProgress";
429
+ } | {
430
+ kind: "success";
431
+ } | {
432
+ kind: "failed";
433
+ error: string;
434
+ } | {
435
+ kind: "canceled";
436
+ }, [import("convex/values").VObject<{
437
+ kind: "pending";
438
+ }, {
439
+ kind: import("convex/values").VLiteral<"pending", "required">;
440
+ }, "required", "kind">, import("convex/values").VObject<{
441
+ kind: "inProgress";
442
+ }, {
443
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
444
+ }, "required", "kind">, import("convex/values").VObject<{
445
+ kind: "success";
446
+ }, {
447
+ kind: import("convex/values").VLiteral<"success", "required">;
448
+ }, "required", "kind">, import("convex/values").VObject<{
449
+ kind: "failed";
450
+ error: string;
451
+ }, {
452
+ kind: import("convex/values").VLiteral<"failed", "required">;
453
+ error: import("convex/values").VString<string, "required">;
454
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
455
+ kind: "canceled";
456
+ }, {
457
+ kind: import("convex/values").VLiteral<"canceled", "required">;
458
+ }, "required", "kind">], "required", "kind" | "error">;
459
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
460
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
461
+ sha256: typeof Schema.String;
462
+ size: typeof Schema.Number;
463
+ contentType: Schema.optionalWith<typeof Schema.String, {
464
+ exact: true;
465
+ }>;
466
+ }>, import("convex/values").VObject<{
467
+ sha256: string;
468
+ size: number;
469
+ contentType?: string;
470
+ }, {
471
+ sha256: import("convex/values").VString<string, "required">;
472
+ size: import("convex/values").VFloat64<number, "required">;
473
+ contentType: import("convex/values").VString<string | undefined, "optional">;
474
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["indexes"]>(indexName: IndexName, indexRange?: ((q: import("convex/server").IndexRangeBuilder<(import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
475
+ name: typeof Schema.String;
476
+ args: Schema.Array$<typeof Schema.Any>;
477
+ scheduledTime: typeof Schema.Number;
478
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
479
+ exact: true;
480
+ }>;
481
+ state: Schema.Union<[Schema.Struct<{
482
+ kind: Schema.Literal<["pending"]>;
483
+ }>, Schema.Struct<{
484
+ kind: Schema.Literal<["inProgress"]>;
485
+ }>, Schema.Struct<{
486
+ kind: Schema.Literal<["success"]>;
487
+ }>, Schema.Struct<{
488
+ kind: Schema.Literal<["failed"]>;
489
+ error: typeof Schema.String;
490
+ }>, Schema.Struct<{
491
+ kind: Schema.Literal<["canceled"]>;
492
+ }>]>;
493
+ }>, import("convex/values").VObject<{
494
+ name: string;
495
+ args: any[];
496
+ scheduledTime: number;
497
+ state: {
498
+ kind: "pending";
499
+ } | {
500
+ kind: "inProgress";
501
+ } | {
502
+ kind: "success";
503
+ } | {
504
+ kind: "failed";
505
+ error: string;
506
+ } | {
507
+ kind: "canceled";
508
+ };
509
+ completedTime?: number;
510
+ }, {
511
+ name: import("convex/values").VString<string, "required">;
512
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
513
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
514
+ state: import("convex/values").VUnion<{
515
+ kind: "pending";
516
+ } | {
517
+ kind: "inProgress";
518
+ } | {
519
+ kind: "success";
520
+ } | {
521
+ kind: "failed";
522
+ error: string;
523
+ } | {
524
+ kind: "canceled";
525
+ }, [import("convex/values").VObject<{
526
+ kind: "pending";
527
+ }, {
528
+ kind: import("convex/values").VLiteral<"pending", "required">;
529
+ }, "required", "kind">, import("convex/values").VObject<{
530
+ kind: "inProgress";
531
+ }, {
532
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
533
+ }, "required", "kind">, import("convex/values").VObject<{
534
+ kind: "success";
535
+ }, {
536
+ kind: import("convex/values").VLiteral<"success", "required">;
537
+ }, "required", "kind">, import("convex/values").VObject<{
538
+ kind: "failed";
539
+ error: string;
540
+ }, {
541
+ kind: import("convex/values").VLiteral<"failed", "required">;
542
+ error: import("convex/values").VString<string, "required">;
543
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
544
+ kind: "canceled";
545
+ }, {
546
+ kind: import("convex/values").VLiteral<"canceled", "required">;
547
+ }, "required", "kind">], "required", "kind" | "error">;
548
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
549
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
550
+ sha256: typeof Schema.String;
551
+ size: typeof Schema.Number;
552
+ contentType: Schema.optionalWith<typeof Schema.String, {
553
+ exact: true;
554
+ }>;
555
+ }>, import("convex/values").VObject<{
556
+ sha256: string;
557
+ size: number;
558
+ contentType?: string;
559
+ }, {
560
+ sha256: import("convex/values").VString<string, "required">;
561
+ size: import("convex/values").VFloat64<number, "required">;
562
+ contentType: import("convex/values").VString<string | undefined, "optional">;
563
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["convexDocument"], import("convex/server").NamedIndex<DataModel.TableInfoWithName<DataModel.DataModel<import("./Table").SystemTables | DatabaseSchema.Tables<Schema>>, TableName>, IndexName>, 0>) => import("convex/server").IndexRange) | undefined, order?: "asc" | "desc"): import("./OrderedQuery").OrderedQuery<import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
564
+ name: typeof Schema.String;
565
+ args: Schema.Array$<typeof Schema.Any>;
566
+ scheduledTime: typeof Schema.Number;
567
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
568
+ exact: true;
569
+ }>;
570
+ state: Schema.Union<[Schema.Struct<{
571
+ kind: Schema.Literal<["pending"]>;
572
+ }>, Schema.Struct<{
573
+ kind: Schema.Literal<["inProgress"]>;
574
+ }>, Schema.Struct<{
575
+ kind: Schema.Literal<["success"]>;
576
+ }>, Schema.Struct<{
577
+ kind: Schema.Literal<["failed"]>;
578
+ error: typeof Schema.String;
579
+ }>, Schema.Struct<{
580
+ kind: Schema.Literal<["canceled"]>;
581
+ }>]>;
582
+ }>, import("convex/values").VObject<{
583
+ name: string;
584
+ args: any[];
585
+ scheduledTime: number;
586
+ state: {
587
+ kind: "pending";
588
+ } | {
589
+ kind: "inProgress";
590
+ } | {
591
+ kind: "success";
592
+ } | {
593
+ kind: "failed";
594
+ error: string;
595
+ } | {
596
+ kind: "canceled";
597
+ };
598
+ completedTime?: number;
599
+ }, {
600
+ name: import("convex/values").VString<string, "required">;
601
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
602
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
603
+ state: import("convex/values").VUnion<{
604
+ kind: "pending";
605
+ } | {
606
+ kind: "inProgress";
607
+ } | {
608
+ kind: "success";
609
+ } | {
610
+ kind: "failed";
611
+ error: string;
612
+ } | {
613
+ kind: "canceled";
614
+ }, [import("convex/values").VObject<{
615
+ kind: "pending";
616
+ }, {
617
+ kind: import("convex/values").VLiteral<"pending", "required">;
618
+ }, "required", "kind">, import("convex/values").VObject<{
619
+ kind: "inProgress";
620
+ }, {
621
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
622
+ }, "required", "kind">, import("convex/values").VObject<{
623
+ kind: "success";
624
+ }, {
625
+ kind: import("convex/values").VLiteral<"success", "required">;
626
+ }, "required", "kind">, import("convex/values").VObject<{
627
+ kind: "failed";
628
+ error: string;
629
+ }, {
630
+ kind: import("convex/values").VLiteral<"failed", "required">;
631
+ error: import("convex/values").VString<string, "required">;
632
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
633
+ kind: "canceled";
634
+ }, {
635
+ kind: import("convex/values").VLiteral<"canceled", "required">;
636
+ }, "required", "kind">], "required", "kind" | "error">;
637
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
638
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
639
+ sha256: typeof Schema.String;
640
+ size: typeof Schema.Number;
641
+ contentType: Schema.optionalWith<typeof Schema.String, {
642
+ exact: true;
643
+ }>;
644
+ }>, import("convex/values").VObject<{
645
+ sha256: string;
646
+ size: number;
647
+ contentType?: string;
648
+ }, {
649
+ sha256: import("convex/values").VString<string, "required">;
650
+ size: import("convex/values").VFloat64<number, "required">;
651
+ contentType: import("convex/values").VString<string | undefined, "optional">;
652
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>, TableName>;
653
+ <IndexName extends keyof (import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
654
+ name: typeof Schema.String;
655
+ args: Schema.Array$<typeof Schema.Any>;
656
+ scheduledTime: typeof Schema.Number;
657
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
658
+ exact: true;
659
+ }>;
660
+ state: Schema.Union<[Schema.Struct<{
661
+ kind: Schema.Literal<["pending"]>;
662
+ }>, Schema.Struct<{
663
+ kind: Schema.Literal<["inProgress"]>;
664
+ }>, Schema.Struct<{
665
+ kind: Schema.Literal<["success"]>;
666
+ }>, Schema.Struct<{
667
+ kind: Schema.Literal<["failed"]>;
668
+ error: typeof Schema.String;
669
+ }>, Schema.Struct<{
670
+ kind: Schema.Literal<["canceled"]>;
671
+ }>]>;
672
+ }>, import("convex/values").VObject<{
673
+ name: string;
674
+ args: any[];
675
+ scheduledTime: number;
676
+ state: {
677
+ kind: "pending";
678
+ } | {
679
+ kind: "inProgress";
680
+ } | {
681
+ kind: "success";
682
+ } | {
683
+ kind: "failed";
684
+ error: string;
685
+ } | {
686
+ kind: "canceled";
687
+ };
688
+ completedTime?: number;
689
+ }, {
690
+ name: import("convex/values").VString<string, "required">;
691
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
692
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
693
+ state: import("convex/values").VUnion<{
694
+ kind: "pending";
695
+ } | {
696
+ kind: "inProgress";
697
+ } | {
698
+ kind: "success";
699
+ } | {
700
+ kind: "failed";
701
+ error: string;
702
+ } | {
703
+ kind: "canceled";
704
+ }, [import("convex/values").VObject<{
705
+ kind: "pending";
706
+ }, {
707
+ kind: import("convex/values").VLiteral<"pending", "required">;
708
+ }, "required", "kind">, import("convex/values").VObject<{
709
+ kind: "inProgress";
710
+ }, {
711
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
712
+ }, "required", "kind">, import("convex/values").VObject<{
713
+ kind: "success";
714
+ }, {
715
+ kind: import("convex/values").VLiteral<"success", "required">;
716
+ }, "required", "kind">, import("convex/values").VObject<{
717
+ kind: "failed";
718
+ error: string;
719
+ }, {
720
+ kind: import("convex/values").VLiteral<"failed", "required">;
721
+ error: import("convex/values").VString<string, "required">;
722
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
723
+ kind: "canceled";
724
+ }, {
725
+ kind: import("convex/values").VLiteral<"canceled", "required">;
726
+ }, "required", "kind">], "required", "kind" | "error">;
727
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
728
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
729
+ sha256: typeof Schema.String;
730
+ size: typeof Schema.Number;
731
+ contentType: Schema.optionalWith<typeof Schema.String, {
732
+ exact: true;
733
+ }>;
734
+ }>, import("convex/values").VObject<{
735
+ sha256: string;
736
+ size: number;
737
+ contentType?: string;
738
+ }, {
739
+ sha256: import("convex/values").VString<string, "required">;
740
+ size: import("convex/values").VFloat64<number, "required">;
741
+ contentType: import("convex/values").VString<string | undefined, "optional">;
742
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["indexes"]>(indexName: IndexName, order?: "asc" | "desc"): import("./OrderedQuery").OrderedQuery<import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
743
+ name: typeof Schema.String;
744
+ args: Schema.Array$<typeof Schema.Any>;
745
+ scheduledTime: typeof Schema.Number;
746
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
747
+ exact: true;
748
+ }>;
749
+ state: Schema.Union<[Schema.Struct<{
750
+ kind: Schema.Literal<["pending"]>;
751
+ }>, Schema.Struct<{
752
+ kind: Schema.Literal<["inProgress"]>;
753
+ }>, Schema.Struct<{
754
+ kind: Schema.Literal<["success"]>;
755
+ }>, Schema.Struct<{
756
+ kind: Schema.Literal<["failed"]>;
757
+ error: typeof Schema.String;
758
+ }>, Schema.Struct<{
759
+ kind: Schema.Literal<["canceled"]>;
760
+ }>]>;
761
+ }>, import("convex/values").VObject<{
762
+ name: string;
763
+ args: any[];
764
+ scheduledTime: number;
765
+ state: {
766
+ kind: "pending";
767
+ } | {
768
+ kind: "inProgress";
769
+ } | {
770
+ kind: "success";
771
+ } | {
772
+ kind: "failed";
773
+ error: string;
774
+ } | {
775
+ kind: "canceled";
776
+ };
777
+ completedTime?: number;
778
+ }, {
779
+ name: import("convex/values").VString<string, "required">;
780
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
781
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
782
+ state: import("convex/values").VUnion<{
783
+ kind: "pending";
784
+ } | {
785
+ kind: "inProgress";
786
+ } | {
787
+ kind: "success";
788
+ } | {
789
+ kind: "failed";
790
+ error: string;
791
+ } | {
792
+ kind: "canceled";
793
+ }, [import("convex/values").VObject<{
794
+ kind: "pending";
795
+ }, {
796
+ kind: import("convex/values").VLiteral<"pending", "required">;
797
+ }, "required", "kind">, import("convex/values").VObject<{
798
+ kind: "inProgress";
799
+ }, {
800
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
801
+ }, "required", "kind">, import("convex/values").VObject<{
802
+ kind: "success";
803
+ }, {
804
+ kind: import("convex/values").VLiteral<"success", "required">;
805
+ }, "required", "kind">, import("convex/values").VObject<{
806
+ kind: "failed";
807
+ error: string;
808
+ }, {
809
+ kind: import("convex/values").VLiteral<"failed", "required">;
810
+ error: import("convex/values").VString<string, "required">;
811
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
812
+ kind: "canceled";
813
+ }, {
814
+ kind: import("convex/values").VLiteral<"canceled", "required">;
815
+ }, "required", "kind">], "required", "kind" | "error">;
816
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
817
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
818
+ sha256: typeof Schema.String;
819
+ size: typeof Schema.Number;
820
+ contentType: Schema.optionalWith<typeof Schema.String, {
821
+ exact: true;
822
+ }>;
823
+ }>, import("convex/values").VObject<{
824
+ sha256: string;
825
+ size: number;
826
+ contentType?: string;
827
+ }, {
828
+ sha256: import("convex/values").VString<string, "required">;
829
+ size: import("convex/values").VFloat64<number, "required">;
830
+ contentType: import("convex/values").VString<string | undefined, "optional">;
831
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>, TableName>;
525
832
  };
526
- completedTime?: number;
527
- }, {
528
- name: convex_values0.VString<string, "required">;
529
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
530
- scheduledTime: convex_values0.VFloat64<number, "required">;
531
- state: convex_values0.VUnion<{
532
- kind: "pending";
533
- } | {
534
- kind: "inProgress";
535
- } | {
536
- kind: "success";
537
- } | {
538
- kind: "failed";
539
- error: string;
540
- } | {
541
- kind: "canceled";
542
- }, [convex_values0.VObject<{
543
- kind: "pending";
833
+ readonly search: <IndexName extends keyof (import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
834
+ name: typeof Schema.String;
835
+ args: Schema.Array$<typeof Schema.Any>;
836
+ scheduledTime: typeof Schema.Number;
837
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
838
+ exact: true;
839
+ }>;
840
+ state: Schema.Union<[Schema.Struct<{
841
+ kind: Schema.Literal<["pending"]>;
842
+ }>, Schema.Struct<{
843
+ kind: Schema.Literal<["inProgress"]>;
844
+ }>, Schema.Struct<{
845
+ kind: Schema.Literal<["success"]>;
846
+ }>, Schema.Struct<{
847
+ kind: Schema.Literal<["failed"]>;
848
+ error: typeof Schema.String;
849
+ }>, Schema.Struct<{
850
+ kind: Schema.Literal<["canceled"]>;
851
+ }>]>;
852
+ }>, import("convex/values").VObject<{
853
+ name: string;
854
+ args: any[];
855
+ scheduledTime: number;
856
+ state: {
857
+ kind: "pending";
858
+ } | {
859
+ kind: "inProgress";
860
+ } | {
861
+ kind: "success";
862
+ } | {
863
+ kind: "failed";
864
+ error: string;
865
+ } | {
866
+ kind: "canceled";
867
+ };
868
+ completedTime?: number;
544
869
  }, {
545
- kind: convex_values0.VLiteral<"pending", "required">;
546
- }, "required", "kind">, convex_values0.VObject<{
547
- kind: "inProgress";
870
+ name: import("convex/values").VString<string, "required">;
871
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
872
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
873
+ state: import("convex/values").VUnion<{
874
+ kind: "pending";
875
+ } | {
876
+ kind: "inProgress";
877
+ } | {
878
+ kind: "success";
879
+ } | {
880
+ kind: "failed";
881
+ error: string;
882
+ } | {
883
+ kind: "canceled";
884
+ }, [import("convex/values").VObject<{
885
+ kind: "pending";
886
+ }, {
887
+ kind: import("convex/values").VLiteral<"pending", "required">;
888
+ }, "required", "kind">, import("convex/values").VObject<{
889
+ kind: "inProgress";
890
+ }, {
891
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
892
+ }, "required", "kind">, import("convex/values").VObject<{
893
+ kind: "success";
894
+ }, {
895
+ kind: import("convex/values").VLiteral<"success", "required">;
896
+ }, "required", "kind">, import("convex/values").VObject<{
897
+ kind: "failed";
898
+ error: string;
899
+ }, {
900
+ kind: import("convex/values").VLiteral<"failed", "required">;
901
+ error: import("convex/values").VString<string, "required">;
902
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
903
+ kind: "canceled";
904
+ }, {
905
+ kind: import("convex/values").VLiteral<"canceled", "required">;
906
+ }, "required", "kind">], "required", "kind" | "error">;
907
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
908
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
909
+ sha256: typeof Schema.String;
910
+ size: typeof Schema.Number;
911
+ contentType: Schema.optionalWith<typeof Schema.String, {
912
+ exact: true;
913
+ }>;
914
+ }>, import("convex/values").VObject<{
915
+ sha256: string;
916
+ size: number;
917
+ contentType?: string;
548
918
  }, {
549
- kind: convex_values0.VLiteral<"inProgress", "required">;
550
- }, "required", "kind">, convex_values0.VObject<{
551
- kind: "success";
919
+ sha256: import("convex/values").VString<string, "required">;
920
+ size: import("convex/values").VFloat64<number, "required">;
921
+ contentType: import("convex/values").VString<string | undefined, "optional">;
922
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["searchIndexes"]>(indexName: IndexName, searchFilter: (q: import("convex/server").SearchFilterBuilder<(import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
923
+ name: typeof Schema.String;
924
+ args: Schema.Array$<typeof Schema.Any>;
925
+ scheduledTime: typeof Schema.Number;
926
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
927
+ exact: true;
928
+ }>;
929
+ state: Schema.Union<[Schema.Struct<{
930
+ kind: Schema.Literal<["pending"]>;
931
+ }>, Schema.Struct<{
932
+ kind: Schema.Literal<["inProgress"]>;
933
+ }>, Schema.Struct<{
934
+ kind: Schema.Literal<["success"]>;
935
+ }>, Schema.Struct<{
936
+ kind: Schema.Literal<["failed"]>;
937
+ error: typeof Schema.String;
938
+ }>, Schema.Struct<{
939
+ kind: Schema.Literal<["canceled"]>;
940
+ }>]>;
941
+ }>, import("convex/values").VObject<{
942
+ name: string;
943
+ args: any[];
944
+ scheduledTime: number;
945
+ state: {
946
+ kind: "pending";
947
+ } | {
948
+ kind: "inProgress";
949
+ } | {
950
+ kind: "success";
951
+ } | {
952
+ kind: "failed";
953
+ error: string;
954
+ } | {
955
+ kind: "canceled";
956
+ };
957
+ completedTime?: number;
552
958
  }, {
553
- kind: convex_values0.VLiteral<"success", "required">;
554
- }, "required", "kind">, convex_values0.VObject<{
555
- kind: "failed";
556
- error: string;
959
+ name: import("convex/values").VString<string, "required">;
960
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
961
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
962
+ state: import("convex/values").VUnion<{
963
+ kind: "pending";
964
+ } | {
965
+ kind: "inProgress";
966
+ } | {
967
+ kind: "success";
968
+ } | {
969
+ kind: "failed";
970
+ error: string;
971
+ } | {
972
+ kind: "canceled";
973
+ }, [import("convex/values").VObject<{
974
+ kind: "pending";
975
+ }, {
976
+ kind: import("convex/values").VLiteral<"pending", "required">;
977
+ }, "required", "kind">, import("convex/values").VObject<{
978
+ kind: "inProgress";
979
+ }, {
980
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
981
+ }, "required", "kind">, import("convex/values").VObject<{
982
+ kind: "success";
983
+ }, {
984
+ kind: import("convex/values").VLiteral<"success", "required">;
985
+ }, "required", "kind">, import("convex/values").VObject<{
986
+ kind: "failed";
987
+ error: string;
988
+ }, {
989
+ kind: import("convex/values").VLiteral<"failed", "required">;
990
+ error: import("convex/values").VString<string, "required">;
991
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
992
+ kind: "canceled";
993
+ }, {
994
+ kind: import("convex/values").VLiteral<"canceled", "required">;
995
+ }, "required", "kind">], "required", "kind" | "error">;
996
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
997
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
998
+ sha256: typeof Schema.String;
999
+ size: typeof Schema.Number;
1000
+ contentType: Schema.optionalWith<typeof Schema.String, {
1001
+ exact: true;
1002
+ }>;
1003
+ }>, import("convex/values").VObject<{
1004
+ sha256: string;
1005
+ size: number;
1006
+ contentType?: string;
557
1007
  }, {
558
- kind: convex_values0.VLiteral<"failed", "required">;
559
- error: convex_values0.VString<string, "required">;
560
- }, "required", "kind" | "error">, convex_values0.VObject<{
561
- kind: "canceled";
1008
+ sha256: import("convex/values").VString<string, "required">;
1009
+ size: import("convex/values").VFloat64<number, "required">;
1010
+ contentType: import("convex/values").VString<string | undefined, "optional">;
1011
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>)["convexDocument"], import("convex/server").NamedSearchIndex<DataModel.TableInfoWithName<DataModel.DataModel<import("./Table").SystemTables | DatabaseSchema.Tables<Schema>>, TableName>, IndexName>>) => import("convex/server").SearchFilter) => import("./OrderedQuery").OrderedQuery<import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_scheduled_functions", Schema.Struct<{
1012
+ name: typeof Schema.String;
1013
+ args: Schema.Array$<typeof Schema.Any>;
1014
+ scheduledTime: typeof Schema.Number;
1015
+ completedTime: Schema.optionalWith<typeof Schema.Number, {
1016
+ exact: true;
1017
+ }>;
1018
+ state: Schema.Union<[Schema.Struct<{
1019
+ kind: Schema.Literal<["pending"]>;
1020
+ }>, Schema.Struct<{
1021
+ kind: Schema.Literal<["inProgress"]>;
1022
+ }>, Schema.Struct<{
1023
+ kind: Schema.Literal<["success"]>;
1024
+ }>, Schema.Struct<{
1025
+ kind: Schema.Literal<["failed"]>;
1026
+ error: typeof Schema.String;
1027
+ }>, Schema.Struct<{
1028
+ kind: Schema.Literal<["canceled"]>;
1029
+ }>]>;
1030
+ }>, import("convex/values").VObject<{
1031
+ name: string;
1032
+ args: any[];
1033
+ scheduledTime: number;
1034
+ state: {
1035
+ kind: "pending";
1036
+ } | {
1037
+ kind: "inProgress";
1038
+ } | {
1039
+ kind: "success";
1040
+ } | {
1041
+ kind: "failed";
1042
+ error: string;
1043
+ } | {
1044
+ kind: "canceled";
1045
+ };
1046
+ completedTime?: number;
562
1047
  }, {
563
- kind: convex_values0.VLiteral<"canceled", "required">;
564
- }, "required", "kind">], "required", "kind" | "error">;
565
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
566
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
567
- sha256: typeof Schema.String;
568
- size: typeof Schema.Number;
569
- contentType: Schema.optionalWith<typeof Schema.String, {
570
- exact: true;
571
- }>;
572
- }>, convex_values0.VObject<{
573
- sha256: string;
574
- size: number;
575
- contentType?: string;
576
- }, {
577
- sha256: convex_values0.VString<string, "required">;
578
- size: convex_values0.VFloat64<number, "required">;
579
- contentType: convex_values0.VString<string | undefined, "optional">;
580
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["convexDocument"], convex_server0.NamedIndex<TableInfoWithName<DataModel<SystemTables | Tables<Schema>>, TableName>, IndexName>, 0>) => convex_server0.IndexRange) | undefined, order?: "asc" | "desc"): OrderedQuery$1<TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
581
- name: typeof Schema.String;
582
- args: Schema.Array$<typeof Schema.Any>;
583
- scheduledTime: typeof Schema.Number;
584
- completedTime: Schema.optionalWith<typeof Schema.Number, {
585
- exact: true;
586
- }>;
587
- state: Schema.Union<[Schema.Struct<{
588
- kind: Schema.Literal<["pending"]>;
589
- }>, Schema.Struct<{
590
- kind: Schema.Literal<["inProgress"]>;
591
- }>, Schema.Struct<{
592
- kind: Schema.Literal<["success"]>;
593
- }>, Schema.Struct<{
594
- kind: Schema.Literal<["failed"]>;
595
- error: typeof Schema.String;
596
- }>, Schema.Struct<{
597
- kind: Schema.Literal<["canceled"]>;
598
- }>]>;
599
- }>, convex_values0.VObject<{
600
- name: string;
601
- args: any[];
602
- scheduledTime: number;
603
- state: {
604
- kind: "pending";
605
- } | {
606
- kind: "inProgress";
607
- } | {
608
- kind: "success";
609
- } | {
610
- kind: "failed";
611
- error: string;
612
- } | {
613
- kind: "canceled";
614
- };
615
- completedTime?: number;
616
- }, {
617
- name: convex_values0.VString<string, "required">;
618
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
619
- scheduledTime: convex_values0.VFloat64<number, "required">;
620
- state: convex_values0.VUnion<{
621
- kind: "pending";
622
- } | {
623
- kind: "inProgress";
624
- } | {
625
- kind: "success";
626
- } | {
627
- kind: "failed";
628
- error: string;
629
- } | {
630
- kind: "canceled";
631
- }, [convex_values0.VObject<{
632
- kind: "pending";
633
- }, {
634
- kind: convex_values0.VLiteral<"pending", "required">;
635
- }, "required", "kind">, convex_values0.VObject<{
636
- kind: "inProgress";
637
- }, {
638
- kind: convex_values0.VLiteral<"inProgress", "required">;
639
- }, "required", "kind">, convex_values0.VObject<{
640
- kind: "success";
641
- }, {
642
- kind: convex_values0.VLiteral<"success", "required">;
643
- }, "required", "kind">, convex_values0.VObject<{
644
- kind: "failed";
645
- error: string;
646
- }, {
647
- kind: convex_values0.VLiteral<"failed", "required">;
648
- error: convex_values0.VString<string, "required">;
649
- }, "required", "kind" | "error">, convex_values0.VObject<{
650
- kind: "canceled";
651
- }, {
652
- kind: convex_values0.VLiteral<"canceled", "required">;
653
- }, "required", "kind">], "required", "kind" | "error">;
654
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
655
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
656
- sha256: typeof Schema.String;
657
- size: typeof Schema.Number;
658
- contentType: Schema.optionalWith<typeof Schema.String, {
659
- exact: true;
660
- }>;
661
- }>, convex_values0.VObject<{
662
- sha256: string;
663
- size: number;
664
- contentType?: string;
665
- }, {
666
- sha256: convex_values0.VString<string, "required">;
667
- size: convex_values0.VFloat64<number, "required">;
668
- contentType: convex_values0.VString<string | undefined, "optional">;
669
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>, TableName>;
670
- <IndexName extends keyof (TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
671
- name: typeof Schema.String;
672
- args: Schema.Array$<typeof Schema.Any>;
673
- scheduledTime: typeof Schema.Number;
674
- completedTime: Schema.optionalWith<typeof Schema.Number, {
675
- exact: true;
676
- }>;
677
- state: Schema.Union<[Schema.Struct<{
678
- kind: Schema.Literal<["pending"]>;
679
- }>, Schema.Struct<{
680
- kind: Schema.Literal<["inProgress"]>;
681
- }>, Schema.Struct<{
682
- kind: Schema.Literal<["success"]>;
683
- }>, Schema.Struct<{
684
- kind: Schema.Literal<["failed"]>;
685
- error: typeof Schema.String;
686
- }>, Schema.Struct<{
687
- kind: Schema.Literal<["canceled"]>;
688
- }>]>;
689
- }>, convex_values0.VObject<{
690
- name: string;
691
- args: any[];
692
- scheduledTime: number;
693
- state: {
694
- kind: "pending";
695
- } | {
696
- kind: "inProgress";
697
- } | {
698
- kind: "success";
699
- } | {
700
- kind: "failed";
701
- error: string;
702
- } | {
703
- kind: "canceled";
704
- };
705
- completedTime?: number;
706
- }, {
707
- name: convex_values0.VString<string, "required">;
708
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
709
- scheduledTime: convex_values0.VFloat64<number, "required">;
710
- state: convex_values0.VUnion<{
711
- kind: "pending";
712
- } | {
713
- kind: "inProgress";
714
- } | {
715
- kind: "success";
716
- } | {
717
- kind: "failed";
718
- error: string;
719
- } | {
720
- kind: "canceled";
721
- }, [convex_values0.VObject<{
722
- kind: "pending";
1048
+ name: import("convex/values").VString<string, "required">;
1049
+ args: import("convex/values").VArray<any[], import("convex/values").VAny<any, "required", string>, "required">;
1050
+ scheduledTime: import("convex/values").VFloat64<number, "required">;
1051
+ state: import("convex/values").VUnion<{
1052
+ kind: "pending";
1053
+ } | {
1054
+ kind: "inProgress";
1055
+ } | {
1056
+ kind: "success";
1057
+ } | {
1058
+ kind: "failed";
1059
+ error: string;
1060
+ } | {
1061
+ kind: "canceled";
1062
+ }, [import("convex/values").VObject<{
1063
+ kind: "pending";
1064
+ }, {
1065
+ kind: import("convex/values").VLiteral<"pending", "required">;
1066
+ }, "required", "kind">, import("convex/values").VObject<{
1067
+ kind: "inProgress";
1068
+ }, {
1069
+ kind: import("convex/values").VLiteral<"inProgress", "required">;
1070
+ }, "required", "kind">, import("convex/values").VObject<{
1071
+ kind: "success";
1072
+ }, {
1073
+ kind: import("convex/values").VLiteral<"success", "required">;
1074
+ }, "required", "kind">, import("convex/values").VObject<{
1075
+ kind: "failed";
1076
+ error: string;
1077
+ }, {
1078
+ kind: import("convex/values").VLiteral<"failed", "required">;
1079
+ error: import("convex/values").VString<string, "required">;
1080
+ }, "required", "kind" | "error">, import("convex/values").VObject<{
1081
+ kind: "canceled";
1082
+ }, {
1083
+ kind: import("convex/values").VLiteral<"canceled", "required">;
1084
+ }, "required", "kind">], "required", "kind" | "error">;
1085
+ completedTime: import("convex/values").VFloat64<number | undefined, "optional">;
1086
+ }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<import("./Table").Table<"_storage", Schema.Struct<{
1087
+ sha256: typeof Schema.String;
1088
+ size: typeof Schema.Number;
1089
+ contentType: Schema.optionalWith<typeof Schema.String, {
1090
+ exact: true;
1091
+ }>;
1092
+ }>, import("convex/values").VObject<{
1093
+ sha256: string;
1094
+ size: number;
1095
+ contentType?: string;
723
1096
  }, {
724
- kind: convex_values0.VLiteral<"pending", "required">;
725
- }, "required", "kind">, convex_values0.VObject<{
726
- kind: "inProgress";
727
- }, {
728
- kind: convex_values0.VLiteral<"inProgress", "required">;
729
- }, "required", "kind">, convex_values0.VObject<{
730
- kind: "success";
731
- }, {
732
- kind: convex_values0.VLiteral<"success", "required">;
733
- }, "required", "kind">, convex_values0.VObject<{
734
- kind: "failed";
735
- error: string;
736
- }, {
737
- kind: convex_values0.VLiteral<"failed", "required">;
738
- error: convex_values0.VString<string, "required">;
739
- }, "required", "kind" | "error">, convex_values0.VObject<{
740
- kind: "canceled";
741
- }, {
742
- kind: convex_values0.VLiteral<"canceled", "required">;
743
- }, "required", "kind">], "required", "kind" | "error">;
744
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
745
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
746
- sha256: typeof Schema.String;
747
- size: typeof Schema.Number;
748
- contentType: Schema.optionalWith<typeof Schema.String, {
749
- exact: true;
750
- }>;
751
- }>, convex_values0.VObject<{
752
- sha256: string;
753
- size: number;
754
- contentType?: string;
755
- }, {
756
- sha256: convex_values0.VString<string, "required">;
757
- size: convex_values0.VFloat64<number, "required">;
758
- contentType: convex_values0.VString<string | undefined, "optional">;
759
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["indexes"]>(indexName: IndexName, order?: "asc" | "desc"): OrderedQuery$1<TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
760
- name: typeof Schema.String;
761
- args: Schema.Array$<typeof Schema.Any>;
762
- scheduledTime: typeof Schema.Number;
763
- completedTime: Schema.optionalWith<typeof Schema.Number, {
764
- exact: true;
765
- }>;
766
- state: Schema.Union<[Schema.Struct<{
767
- kind: Schema.Literal<["pending"]>;
768
- }>, Schema.Struct<{
769
- kind: Schema.Literal<["inProgress"]>;
770
- }>, Schema.Struct<{
771
- kind: Schema.Literal<["success"]>;
772
- }>, Schema.Struct<{
773
- kind: Schema.Literal<["failed"]>;
774
- error: typeof Schema.String;
775
- }>, Schema.Struct<{
776
- kind: Schema.Literal<["canceled"]>;
777
- }>]>;
778
- }>, convex_values0.VObject<{
779
- name: string;
780
- args: any[];
781
- scheduledTime: number;
782
- state: {
783
- kind: "pending";
784
- } | {
785
- kind: "inProgress";
786
- } | {
787
- kind: "success";
788
- } | {
789
- kind: "failed";
790
- error: string;
791
- } | {
792
- kind: "canceled";
793
- };
794
- completedTime?: number;
795
- }, {
796
- name: convex_values0.VString<string, "required">;
797
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
798
- scheduledTime: convex_values0.VFloat64<number, "required">;
799
- state: convex_values0.VUnion<{
800
- kind: "pending";
801
- } | {
802
- kind: "inProgress";
803
- } | {
804
- kind: "success";
805
- } | {
806
- kind: "failed";
807
- error: string;
808
- } | {
809
- kind: "canceled";
810
- }, [convex_values0.VObject<{
811
- kind: "pending";
812
- }, {
813
- kind: convex_values0.VLiteral<"pending", "required">;
814
- }, "required", "kind">, convex_values0.VObject<{
815
- kind: "inProgress";
816
- }, {
817
- kind: convex_values0.VLiteral<"inProgress", "required">;
818
- }, "required", "kind">, convex_values0.VObject<{
819
- kind: "success";
820
- }, {
821
- kind: convex_values0.VLiteral<"success", "required">;
822
- }, "required", "kind">, convex_values0.VObject<{
823
- kind: "failed";
824
- error: string;
825
- }, {
826
- kind: convex_values0.VLiteral<"failed", "required">;
827
- error: convex_values0.VString<string, "required">;
828
- }, "required", "kind" | "error">, convex_values0.VObject<{
829
- kind: "canceled";
830
- }, {
831
- kind: convex_values0.VLiteral<"canceled", "required">;
832
- }, "required", "kind">], "required", "kind" | "error">;
833
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
834
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
835
- sha256: typeof Schema.String;
836
- size: typeof Schema.Number;
837
- contentType: Schema.optionalWith<typeof Schema.String, {
838
- exact: true;
839
- }>;
840
- }>, convex_values0.VObject<{
841
- sha256: string;
842
- size: number;
843
- contentType?: string;
844
- }, {
845
- sha256: convex_values0.VString<string, "required">;
846
- size: convex_values0.VFloat64<number, "required">;
847
- contentType: convex_values0.VString<string | undefined, "optional">;
848
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>, TableName>;
1097
+ sha256: import("convex/values").VString<string, "required">;
1098
+ size: import("convex/values").VFloat64<number, "required">;
1099
+ contentType: import("convex/values").VString<string | undefined, "optional">;
1100
+ }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>> | import("./TableInfo").TableInfo<import("./Table").WithName<DatabaseSchema.Tables<Schema>, TableName>>, TableName>;
849
1101
  };
850
- readonly search: <IndexName extends keyof (TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
851
- name: typeof Schema.String;
852
- args: Schema.Array$<typeof Schema.Any>;
853
- scheduledTime: typeof Schema.Number;
854
- completedTime: Schema.optionalWith<typeof Schema.Number, {
855
- exact: true;
856
- }>;
857
- state: Schema.Union<[Schema.Struct<{
858
- kind: Schema.Literal<["pending"]>;
859
- }>, Schema.Struct<{
860
- kind: Schema.Literal<["inProgress"]>;
861
- }>, Schema.Struct<{
862
- kind: Schema.Literal<["success"]>;
863
- }>, Schema.Struct<{
864
- kind: Schema.Literal<["failed"]>;
865
- error: typeof Schema.String;
866
- }>, Schema.Struct<{
867
- kind: Schema.Literal<["canceled"]>;
868
- }>]>;
869
- }>, convex_values0.VObject<{
870
- name: string;
871
- args: any[];
872
- scheduledTime: number;
873
- state: {
874
- kind: "pending";
875
- } | {
876
- kind: "inProgress";
877
- } | {
878
- kind: "success";
879
- } | {
880
- kind: "failed";
881
- error: string;
882
- } | {
883
- kind: "canceled";
884
- };
885
- completedTime?: number;
886
- }, {
887
- name: convex_values0.VString<string, "required">;
888
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
889
- scheduledTime: convex_values0.VFloat64<number, "required">;
890
- state: convex_values0.VUnion<{
891
- kind: "pending";
892
- } | {
893
- kind: "inProgress";
894
- } | {
895
- kind: "success";
896
- } | {
897
- kind: "failed";
898
- error: string;
899
- } | {
900
- kind: "canceled";
901
- }, [convex_values0.VObject<{
902
- kind: "pending";
903
- }, {
904
- kind: convex_values0.VLiteral<"pending", "required">;
905
- }, "required", "kind">, convex_values0.VObject<{
906
- kind: "inProgress";
907
- }, {
908
- kind: convex_values0.VLiteral<"inProgress", "required">;
909
- }, "required", "kind">, convex_values0.VObject<{
910
- kind: "success";
911
- }, {
912
- kind: convex_values0.VLiteral<"success", "required">;
913
- }, "required", "kind">, convex_values0.VObject<{
914
- kind: "failed";
915
- error: string;
916
- }, {
917
- kind: convex_values0.VLiteral<"failed", "required">;
918
- error: convex_values0.VString<string, "required">;
919
- }, "required", "kind" | "error">, convex_values0.VObject<{
920
- kind: "canceled";
921
- }, {
922
- kind: convex_values0.VLiteral<"canceled", "required">;
923
- }, "required", "kind">], "required", "kind" | "error">;
924
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
925
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
926
- sha256: typeof Schema.String;
927
- size: typeof Schema.Number;
928
- contentType: Schema.optionalWith<typeof Schema.String, {
929
- exact: true;
930
- }>;
931
- }>, convex_values0.VObject<{
932
- sha256: string;
933
- size: number;
934
- contentType?: string;
935
- }, {
936
- sha256: convex_values0.VString<string, "required">;
937
- size: convex_values0.VFloat64<number, "required">;
938
- contentType: convex_values0.VString<string | undefined, "optional">;
939
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["searchIndexes"]>(indexName: IndexName, searchFilter: (q: convex_server0.SearchFilterBuilder<(TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
940
- name: typeof Schema.String;
941
- args: Schema.Array$<typeof Schema.Any>;
942
- scheduledTime: typeof Schema.Number;
943
- completedTime: Schema.optionalWith<typeof Schema.Number, {
944
- exact: true;
945
- }>;
946
- state: Schema.Union<[Schema.Struct<{
947
- kind: Schema.Literal<["pending"]>;
948
- }>, Schema.Struct<{
949
- kind: Schema.Literal<["inProgress"]>;
950
- }>, Schema.Struct<{
951
- kind: Schema.Literal<["success"]>;
952
- }>, Schema.Struct<{
953
- kind: Schema.Literal<["failed"]>;
954
- error: typeof Schema.String;
955
- }>, Schema.Struct<{
956
- kind: Schema.Literal<["canceled"]>;
957
- }>]>;
958
- }>, convex_values0.VObject<{
959
- name: string;
960
- args: any[];
961
- scheduledTime: number;
962
- state: {
963
- kind: "pending";
964
- } | {
965
- kind: "inProgress";
966
- } | {
967
- kind: "success";
968
- } | {
969
- kind: "failed";
970
- error: string;
971
- } | {
972
- kind: "canceled";
973
- };
974
- completedTime?: number;
975
- }, {
976
- name: convex_values0.VString<string, "required">;
977
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
978
- scheduledTime: convex_values0.VFloat64<number, "required">;
979
- state: convex_values0.VUnion<{
980
- kind: "pending";
981
- } | {
982
- kind: "inProgress";
983
- } | {
984
- kind: "success";
985
- } | {
986
- kind: "failed";
987
- error: string;
988
- } | {
989
- kind: "canceled";
990
- }, [convex_values0.VObject<{
991
- kind: "pending";
992
- }, {
993
- kind: convex_values0.VLiteral<"pending", "required">;
994
- }, "required", "kind">, convex_values0.VObject<{
995
- kind: "inProgress";
996
- }, {
997
- kind: convex_values0.VLiteral<"inProgress", "required">;
998
- }, "required", "kind">, convex_values0.VObject<{
999
- kind: "success";
1000
- }, {
1001
- kind: convex_values0.VLiteral<"success", "required">;
1002
- }, "required", "kind">, convex_values0.VObject<{
1003
- kind: "failed";
1004
- error: string;
1005
- }, {
1006
- kind: convex_values0.VLiteral<"failed", "required">;
1007
- error: convex_values0.VString<string, "required">;
1008
- }, "required", "kind" | "error">, convex_values0.VObject<{
1009
- kind: "canceled";
1010
- }, {
1011
- kind: convex_values0.VLiteral<"canceled", "required">;
1012
- }, "required", "kind">], "required", "kind" | "error">;
1013
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
1014
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
1015
- sha256: typeof Schema.String;
1016
- size: typeof Schema.Number;
1017
- contentType: Schema.optionalWith<typeof Schema.String, {
1018
- exact: true;
1019
- }>;
1020
- }>, convex_values0.VObject<{
1021
- sha256: string;
1022
- size: number;
1023
- contentType?: string;
1024
- }, {
1025
- sha256: convex_values0.VString<string, "required">;
1026
- size: convex_values0.VFloat64<number, "required">;
1027
- contentType: convex_values0.VString<string | undefined, "optional">;
1028
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>)["convexDocument"], convex_server0.NamedSearchIndex<TableInfoWithName<DataModel<SystemTables | Tables<Schema>>, TableName>, IndexName>>) => convex_server0.SearchFilter) => OrderedQuery$1<TableInfo<WithName<Tables<Schema>, TableName>> | TableInfo<WithName<Table<"_scheduled_functions", Schema.Struct<{
1029
- name: typeof Schema.String;
1030
- args: Schema.Array$<typeof Schema.Any>;
1031
- scheduledTime: typeof Schema.Number;
1032
- completedTime: Schema.optionalWith<typeof Schema.Number, {
1033
- exact: true;
1034
- }>;
1035
- state: Schema.Union<[Schema.Struct<{
1036
- kind: Schema.Literal<["pending"]>;
1037
- }>, Schema.Struct<{
1038
- kind: Schema.Literal<["inProgress"]>;
1039
- }>, Schema.Struct<{
1040
- kind: Schema.Literal<["success"]>;
1041
- }>, Schema.Struct<{
1042
- kind: Schema.Literal<["failed"]>;
1043
- error: typeof Schema.String;
1044
- }>, Schema.Struct<{
1045
- kind: Schema.Literal<["canceled"]>;
1046
- }>]>;
1047
- }>, convex_values0.VObject<{
1048
- name: string;
1049
- args: any[];
1050
- scheduledTime: number;
1051
- state: {
1052
- kind: "pending";
1053
- } | {
1054
- kind: "inProgress";
1055
- } | {
1056
- kind: "success";
1057
- } | {
1058
- kind: "failed";
1059
- error: string;
1060
- } | {
1061
- kind: "canceled";
1062
- };
1063
- completedTime?: number;
1064
- }, {
1065
- name: convex_values0.VString<string, "required">;
1066
- args: convex_values0.VArray<any[], convex_values0.VAny<any, "required", string>, "required">;
1067
- scheduledTime: convex_values0.VFloat64<number, "required">;
1068
- state: convex_values0.VUnion<{
1069
- kind: "pending";
1070
- } | {
1071
- kind: "inProgress";
1072
- } | {
1073
- kind: "success";
1074
- } | {
1075
- kind: "failed";
1076
- error: string;
1077
- } | {
1078
- kind: "canceled";
1079
- }, [convex_values0.VObject<{
1080
- kind: "pending";
1081
- }, {
1082
- kind: convex_values0.VLiteral<"pending", "required">;
1083
- }, "required", "kind">, convex_values0.VObject<{
1084
- kind: "inProgress";
1085
- }, {
1086
- kind: convex_values0.VLiteral<"inProgress", "required">;
1087
- }, "required", "kind">, convex_values0.VObject<{
1088
- kind: "success";
1089
- }, {
1090
- kind: convex_values0.VLiteral<"success", "required">;
1091
- }, "required", "kind">, convex_values0.VObject<{
1092
- kind: "failed";
1093
- error: string;
1094
- }, {
1095
- kind: convex_values0.VLiteral<"failed", "required">;
1096
- error: convex_values0.VString<string, "required">;
1097
- }, "required", "kind" | "error">, convex_values0.VObject<{
1098
- kind: "canceled";
1099
- }, {
1100
- kind: convex_values0.VLiteral<"canceled", "required">;
1101
- }, "required", "kind">], "required", "kind" | "error">;
1102
- completedTime: convex_values0.VFloat64<number | undefined, "optional">;
1103
- }, "required", "name" | "args" | "scheduledTime" | "completedTime" | "state" | "state.kind" | "state.error">, {}, {}, {}>, TableName>> | TableInfo<WithName<Table<"_storage", Schema.Struct<{
1104
- sha256: typeof Schema.String;
1105
- size: typeof Schema.Number;
1106
- contentType: Schema.optionalWith<typeof Schema.String, {
1107
- exact: true;
1108
- }>;
1109
- }>, convex_values0.VObject<{
1110
- sha256: string;
1111
- size: number;
1112
- contentType?: string;
1113
- }, {
1114
- sha256: convex_values0.VString<string, "required">;
1115
- size: convex_values0.VFloat64<number, "required">;
1116
- contentType: convex_values0.VString<string | undefined, "optional">;
1117
- }, "required", "sha256" | "size" | "contentType">, {}, {}, {}>, TableName>>, TableName>;
1118
- };
1119
- } | {
1120
- table: <const TableName extends TableNames<FromSchema<Schema>>>(tableName: TableName) => {
1121
- insert: (document: WithoutSystemFields$1<DocumentByName<FromSchema<Schema>, TableName>>) => Effect.Effect<convex_values0.GenericId<TableName>, DocumentEncodeError, never>;
1122
- patch: (id: convex_values0.GenericId<TableName>, patchedValues: Partial<convex_server0.Expand<convex_server0.BetterOmit<DocumentByName<FromSchema<Schema>, TableName>, "_id" | "_creationTime">>>) => Effect.Effect<void, DocumentDecodeError | GetByIdFailure | DocumentEncodeError, never>;
1123
- replace: (id: convex_values0.GenericId<TableName>, value: convex_server0.Expand<convex_server0.BetterOmit<DocumentByName<FromSchema<Schema>, TableName>, "_id" | "_creationTime">>) => Effect.Effect<void, DocumentEncodeError, never>;
1124
- delete: (id: convex_values0.GenericId<TableName>) => Effect.Effect<void, never, never>;
1125
- };
1126
1102
  } | {
1127
- runAfter: <Ref_ extends _confect_core_Ref0.AnyMutation | _confect_core_Ref0.AnyAction>(delay: effect_Duration0.Duration, ref: Ref_, ...args: _confect_core_Ref0.OptionalArgs<Ref_>) => Effect.Effect<convex_values0.GenericId<"_scheduled_functions">, never, never>;
1128
- runAt: <Ref_ extends _confect_core_Ref0.AnyMutation | _confect_core_Ref0.AnyAction>(dateTime: effect_DateTime0.DateTime, ref: Ref_, ...args: _confect_core_Ref0.OptionalArgs<Ref_>) => Effect.Effect<convex_values0.GenericId<"_scheduled_functions">, never, never>;
1129
- } | StorageReader$1 | StorageWriter$1 | (<Mutation extends _confect_core_Ref0.AnyMutation>(mutation: Mutation, ...args: _confect_core_Ref0.OptionalArgs<Mutation>) => Effect.Effect<_confect_core_Ref0.Returns<Mutation>, _confect_core_Ref0.Error<Mutation> | effect_ParseResult0.ParseError>), never, never>;
1130
- type MutationServices<Schema extends AnyWithProps> = DatabaseReader<Schema> | DatabaseWriter<Schema> | Auth$1 | Scheduler$1 | StorageReader$1 | StorageWriter$1 | QueryRunner | MutationRunner | MutationCtx<ToConvex<FromSchema<Schema>>>;
1131
- //#endregion
1132
- export { MutationServices, RegisteredConvexFunction_d_exports, make, mutationLayer };
1103
+ table: <const TableName extends DataModel.TableNames<DataModel.FromSchema<Schema>>>(tableName: TableName) => {
1104
+ insert: (document: import("./Document").WithoutSystemFields<DataModel.DocumentByName<DataModel.FromSchema<Schema>, TableName>>) => Effect.Effect<import("convex/values").GenericId<TableName>, import("./Document").DocumentEncodeError, never>;
1105
+ patch: (id: import("convex/values").GenericId<TableName>, patchedValues: Partial<import("convex/server").Expand<import("convex/server").BetterOmit<DataModel.DocumentByName<DataModel.FromSchema<Schema>, TableName>, "_creationTime" | "_id">>>) => Effect.Effect<void, import("./Document").DocumentDecodeError | import("./Document").DocumentEncodeError | import("./QueryInitializer").GetByIdFailure, never>;
1106
+ replace: (id: import("convex/values").GenericId<TableName>, value: import("convex/server").Expand<import("convex/server").BetterOmit<DataModel.DocumentByName<DataModel.FromSchema<Schema>, TableName>, "_creationTime" | "_id">>) => Effect.Effect<void, import("./Document").DocumentEncodeError, never>;
1107
+ delete: (id: import("convex/values").GenericId<TableName>) => Effect.Effect<void, never, never>;
1108
+ };
1109
+ }, never, never>;
1110
+ export type MutationServices<Schema extends DatabaseSchema.AnyWithProps> = DatabaseReader.DatabaseReader<Schema> | DatabaseWriter.DatabaseWriter<Schema> | Auth.Auth | Scheduler.Scheduler | StorageReader | StorageWriter | QueryRunner.QueryRunner | MutationRunner.MutationRunner | MutationCtx.MutationCtx<DataModel.ToConvex<DataModel.FromSchema<Schema>>>;
1133
1111
  //# sourceMappingURL=RegisteredConvexFunction.d.ts.map