kitcn 0.12.11 → 0.12.12
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.
- package/dist/aggregate/index.d.ts +1 -1
- package/dist/auth/generated/index.d.ts +1 -1
- package/dist/auth/index.d.ts +5 -5
- package/dist/{backend-core-DUsUG58E.mjs → backend-core-Cf6h5gQc.mjs} +1 -1
- package/dist/cli.mjs +104 -5
- package/dist/{generated-contract-disabled-Cf7sqlVD.d.ts → generated-contract-disabled-9Yg1NHlV.d.ts} +2 -2
- package/dist/orm/index.d.ts +1 -1
- package/dist/watcher.mjs +1 -1
- package/dist/{where-clause-compiler-DJ2S06w0.d.ts → where-clause-compiler-BpfS2FJi.d.ts} +73 -73
- package/package.json +1 -1
- package/skills/convex/references/features/auth.md +2 -0
- package/skills/convex/references/setup/auth.md +7 -1
- package/skills/convex/references/setup/index.md +5 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as ConvexNumberBuilderInitial, E as ConvexIdBuilderInitial, N as ConvexCustomBuilderInitial, dn as ConvexTableWithColumns, tr as ConvexTextBuilderInitial } from "../where-clause-compiler-
|
|
1
|
+
import { C as ConvexNumberBuilderInitial, E as ConvexIdBuilderInitial, N as ConvexCustomBuilderInitial, dn as ConvexTableWithColumns, tr as ConvexTextBuilderInitial } from "../where-clause-compiler-BpfS2FJi.js";
|
|
2
2
|
import * as convex_values0 from "convex/values";
|
|
3
3
|
import { GenericId, Infer, Value } from "convex/values";
|
|
4
4
|
import { DocumentByName, GenericDataModel, GenericDatabaseReader, GenericDatabaseWriter, TableNamesInDataModel } from "convex/server";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { S as defineAuth, _ as GenericAuthBeforeResult, b as GenericAuthTriggerHandlers, g as BetterAuthOptionsWithoutDatabase, i as getGeneratedAuthDisabledReason, n as GeneratedAuthDisabledReasonKind, r as createDisabledAuthRuntime, t as AuthRuntime, v as GenericAuthDefinition, x as GenericAuthTriggers, y as GenericAuthTriggerChange } from "../../generated-contract-disabled-
|
|
1
|
+
import { S as defineAuth, _ as GenericAuthBeforeResult, b as GenericAuthTriggerHandlers, g as BetterAuthOptionsWithoutDatabase, i as getGeneratedAuthDisabledReason, n as GeneratedAuthDisabledReasonKind, r as createDisabledAuthRuntime, t as AuthRuntime, v as GenericAuthDefinition, x as GenericAuthTriggers, y as GenericAuthTriggerChange } from "../../generated-contract-disabled-9Yg1NHlV.js";
|
|
2
2
|
export { type AuthRuntime, BetterAuthOptionsWithoutDatabase, type GeneratedAuthDisabledReasonKind, GenericAuthBeforeResult, GenericAuthDefinition, GenericAuthTriggerChange, GenericAuthTriggerHandlers, GenericAuthTriggers, createDisabledAuthRuntime, defineAuth, getGeneratedAuthDisabledReason };
|
package/dist/auth/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { a as QueryCtxWithPreferredOrmQueryTable, n as LookupByIdResultByCtx, t as DocByCtx } from "../query-context-CFZqIvD7.js";
|
|
2
2
|
import { t as GetAuth } from "../types-BiJE7qxR.js";
|
|
3
3
|
import { t as GenericCtx } from "../context-utils-HPC5nXzx.js";
|
|
4
|
-
import { S as defineAuth, _ as GenericAuthBeforeResult, a as AuthFunctions, b as GenericAuthTriggerHandlers, c as createApi, d as deleteOneHandler, f as findManyHandler, g as BetterAuthOptionsWithoutDatabase, h as updateOneHandler, i as getGeneratedAuthDisabledReason, l as createHandler, m as updateManyHandler, n as GeneratedAuthDisabledReasonKind, o as Triggers, p as findOneHandler, r as createDisabledAuthRuntime, s as createClient, t as AuthRuntime, u as deleteManyHandler, v as GenericAuthDefinition, x as GenericAuthTriggers, y as GenericAuthTriggerChange } from "../generated-contract-disabled-
|
|
4
|
+
import { S as defineAuth, _ as GenericAuthBeforeResult, a as AuthFunctions, b as GenericAuthTriggerHandlers, c as createApi, d as deleteOneHandler, f as findManyHandler, g as BetterAuthOptionsWithoutDatabase, h as updateOneHandler, i as getGeneratedAuthDisabledReason, l as createHandler, m as updateManyHandler, n as GeneratedAuthDisabledReasonKind, o as Triggers, p as findOneHandler, r as createDisabledAuthRuntime, s as createClient, t as AuthRuntime, u as deleteManyHandler, v as GenericAuthDefinition, x as GenericAuthTriggers, y as GenericAuthTriggerChange } from "../generated-contract-disabled-9Yg1NHlV.js";
|
|
5
5
|
import * as convex_values0 from "convex/values";
|
|
6
6
|
import { Infer } from "convex/values";
|
|
7
7
|
import { DocumentByName, GenericDataModel, GenericMutationCtx, GenericQueryCtx, GenericSchema, PaginationOptions, PaginationResult, SchemaDefinition, TableNamesInDataModel } from "convex/server";
|
|
@@ -124,8 +124,8 @@ declare const adapterArgsValidator: convex_values0.VObject<{
|
|
|
124
124
|
select?: string[] | undefined;
|
|
125
125
|
offset?: number | undefined;
|
|
126
126
|
sortBy?: {
|
|
127
|
-
direction: "asc" | "desc";
|
|
128
127
|
field: string;
|
|
128
|
+
direction: "asc" | "desc";
|
|
129
129
|
} | undefined;
|
|
130
130
|
model: string;
|
|
131
131
|
}, {
|
|
@@ -134,12 +134,12 @@ declare const adapterArgsValidator: convex_values0.VObject<{
|
|
|
134
134
|
offset: convex_values0.VFloat64<number | undefined, "optional">;
|
|
135
135
|
select: convex_values0.VArray<string[] | undefined, convex_values0.VString<string, "required">, "optional">;
|
|
136
136
|
sortBy: convex_values0.VObject<{
|
|
137
|
-
direction: "asc" | "desc";
|
|
138
137
|
field: string;
|
|
138
|
+
direction: "asc" | "desc";
|
|
139
139
|
} | undefined, {
|
|
140
140
|
direction: convex_values0.VUnion<"asc" | "desc", [convex_values0.VLiteral<"asc", "required">, convex_values0.VLiteral<"desc", "required">], "required", never>;
|
|
141
141
|
field: convex_values0.VString<string, "required">;
|
|
142
|
-
}, "optional", "
|
|
142
|
+
}, "optional", "field" | "direction">;
|
|
143
143
|
where: convex_values0.VArray<{
|
|
144
144
|
operator?: "eq" | "ne" | "lt" | "lte" | "gt" | "gte" | "in" | "not_in" | "contains" | "starts_with" | "ends_with" | undefined;
|
|
145
145
|
connector?: "AND" | "OR" | undefined;
|
|
@@ -156,7 +156,7 @@ declare const adapterArgsValidator: convex_values0.VObject<{
|
|
|
156
156
|
operator: convex_values0.VUnion<"eq" | "ne" | "lt" | "lte" | "gt" | "gte" | "in" | "not_in" | "contains" | "starts_with" | "ends_with" | undefined, [convex_values0.VLiteral<"lt", "required">, convex_values0.VLiteral<"lte", "required">, convex_values0.VLiteral<"gt", "required">, convex_values0.VLiteral<"gte", "required">, convex_values0.VLiteral<"eq", "required">, convex_values0.VLiteral<"in", "required">, convex_values0.VLiteral<"not_in", "required">, convex_values0.VLiteral<"ne", "required">, convex_values0.VLiteral<"contains", "required">, convex_values0.VLiteral<"starts_with", "required">, convex_values0.VLiteral<"ends_with", "required">], "optional", never>;
|
|
157
157
|
value: convex_values0.VUnion<string | number | boolean | string[] | number[] | null, [convex_values0.VString<string, "required">, convex_values0.VFloat64<number, "required">, convex_values0.VBoolean<boolean, "required">, convex_values0.VArray<string[], convex_values0.VString<string, "required">, "required">, convex_values0.VArray<number[], convex_values0.VFloat64<number, "required">, "required">, convex_values0.VNull<null, "required">], "required", never>;
|
|
158
158
|
}, "required", "value" | "operator" | "field" | "connector">, "optional">;
|
|
159
|
-
}, "required", "limit" | "where" | "model" | "select" | "offset" | "sortBy" | "sortBy.
|
|
159
|
+
}, "required", "limit" | "where" | "model" | "select" | "offset" | "sortBy" | "sortBy.field" | "sortBy.direction">;
|
|
160
160
|
declare const hasUniqueFields: (betterAuthSchema: BetterAuthDBSchema, model: string, input: Record<string, any>) => boolean;
|
|
161
161
|
declare const checkUniqueFields: <Schema extends SchemaDefinition<any, any>>(ctx: GenericQueryCtx<GenericDataModel>, schema: Schema, betterAuthSchema: BetterAuthDBSchema, table: string, input: Record<string, any>, doc?: Record<string, any>) => Promise<void>;
|
|
162
162
|
declare const selectFields: <T extends TableNamesInDataModel<GenericDataModel>, D extends DocumentByName<GenericDataModel, T>>(doc: D | null, select?: string[]) => D | null;
|
|
@@ -14926,4 +14926,4 @@ function isEntryPoint(entry, filename) {
|
|
|
14926
14926
|
}
|
|
14927
14927
|
|
|
14928
14928
|
//#endregion
|
|
14929
|
-
export {
|
|
14929
|
+
export { resolvePluginPreset as $, resolveConfiguredBackend as A, runConvexInitIfNeeded as B, isInitialized as C, getConvexConfig as Ct, readPackageVersions as D, parseInitCommandArgs as E, runAfterScaffoldScript as F, trackProcess as G, runInitCommandFlow as H, runAggregateBackfillFlow as I, collectPluginScaffoldTemplates as J, withWorkingDirectory as K, runAggregatePruneFlow as L, resolveInitProjectDir as M, resolveMigrationConfig as N, resolveBackfillConfig as O, resolveRunDeps as P, resolveAddTemplateDefaults as Q, runBackendFunction as R, isEntryPoint as S, generateMeta as St, parseBackendRunJson as T, highlighter as Tt, runMigrationCreate as U, runDevSchemaBackfillIfNeeded as V, runMigrationFlow as W, promptForPluginSelection as X, filterScaffoldTemplatePathMap as Y, promptForScaffoldTemplateSelection as Z, formatInfoOutput as _, inspectPluginDependencyInstall as _t, cleanup as a, isSupportedPluginKey as at, hasRemoteConvexDeploymentEnv as b, serializeEnvValue as bt, createCommandEnv as c, assertSchemaFileExists as ct, extractBackfillCliOptions as d, getSchemaFilePath as dt, resolvePresetScaffoldTemplates as et, extractConcaveRunTargetArgs as f, readPluginLockfile as ft, formatDocsOutput as g, applyPluginDependencyInstall as gt, extractResetCliOptions as h, applyPlanningDependencyInstall as ht, buildInitializationPlan as i, getSupportedPluginKeys as it, resolveDocTopic as j, resolveCodegenTrimSegments as k, ensureConvexGitignoreEntry as l, collectInstalledPluginKeys as lt, extractMigrationDownOptions as m, applyDependencyHintsInstall as mt, applyPluginInstallPlanFiles as n, resolveTemplatesByIdOrThrow as nt, createBackendAdapter as o, buildPluginInstallPlan as ot, extractMigrationCliOptions as p, resolveSchemaInstalledPlugins as pt, createSpinner as q, assertNoRemovedDevPreRunFlag as r, getPluginCatalogEntry as rt, createBackendCommandEnv as s, resolvePluginScaffoldRoots as st, applyDependencyInstallPlan as t, resolveTemplateSelectionSource as tt, extractBackendRunTargetArgs as u, getPluginLockfilePath as ut, getAggregateBackfillDeploymentKey as v, resolveProjectScaffoldContext as vt, parseArgs as w, logger as wt, isConvexDevPreRunConflictFlag as x, stripConvexCommandNoise as xt, getDevAggregateBackfillStatePath as y, resolveAuthEnvState as yt, runConfiguredCodegen as z };
|
package/dist/cli.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { $ as
|
|
2
|
+
import { $ as resolvePluginPreset, A as resolveConfiguredBackend, B as runConvexInitIfNeeded, C as isInitialized, D as readPackageVersions, E as parseInitCommandArgs, F as runAfterScaffoldScript, G as trackProcess, H as runInitCommandFlow, I as runAggregateBackfillFlow, J as collectPluginScaffoldTemplates, K as withWorkingDirectory, L as runAggregatePruneFlow, M as resolveInitProjectDir, N as resolveMigrationConfig, O as resolveBackfillConfig, P as resolveRunDeps, Q as resolveAddTemplateDefaults, R as runBackendFunction, S as isEntryPoint, T as parseBackendRunJson, Tt as highlighter, U as runMigrationCreate, V as runDevSchemaBackfillIfNeeded, W as runMigrationFlow, X as promptForPluginSelection, Y as filterScaffoldTemplatePathMap, Z as promptForScaffoldTemplateSelection, _ as formatInfoOutput, _t as inspectPluginDependencyInstall, a as cleanup, at as isSupportedPluginKey, b as hasRemoteConvexDeploymentEnv, bt as serializeEnvValue, c as createCommandEnv, ct as assertSchemaFileExists, d as extractBackfillCliOptions, dt as getSchemaFilePath, et as resolvePresetScaffoldTemplates, f as extractConcaveRunTargetArgs, ft as readPluginLockfile, g as formatDocsOutput, gt as applyPluginDependencyInstall, h as extractResetCliOptions, ht as applyPlanningDependencyInstall, i as buildInitializationPlan, it as getSupportedPluginKeys, j as resolveDocTopic, k as resolveCodegenTrimSegments, l as ensureConvexGitignoreEntry, lt as collectInstalledPluginKeys, m as extractMigrationDownOptions, mt as applyDependencyHintsInstall, n as applyPluginInstallPlanFiles, nt as resolveTemplatesByIdOrThrow, o as createBackendAdapter, ot as buildPluginInstallPlan, p as extractMigrationCliOptions, pt as resolveSchemaInstalledPlugins, q as createSpinner, r as assertNoRemovedDevPreRunFlag, rt as getPluginCatalogEntry, s as createBackendCommandEnv, st as resolvePluginScaffoldRoots, t as applyDependencyInstallPlan, tt as resolveTemplateSelectionSource, u as extractBackendRunTargetArgs, ut as getPluginLockfilePath, v as getAggregateBackfillDeploymentKey, vt as resolveProjectScaffoldContext, w as parseArgs, wt as logger, x as isConvexDevPreRunConflictFlag, xt as stripConvexCommandNoise, y as getDevAggregateBackfillStatePath, yt as resolveAuthEnvState, z as runConfiguredCodegen } from "./backend-core-Cf6h5gQc.mjs";
|
|
3
3
|
import fs, { existsSync, readFileSync } from "node:fs";
|
|
4
4
|
import path, { delimiter, dirname, join, relative, resolve } from "node:path";
|
|
5
5
|
import { fileURLToPath } from "node:url";
|
|
@@ -322,7 +322,7 @@ const serializeDryRunPlan = (plan) => {
|
|
|
322
322
|
//#region src/cli/commands/dev.ts
|
|
323
323
|
const __filename$1 = fileURLToPath(import.meta.url);
|
|
324
324
|
const __dirname = dirname(__filename$1);
|
|
325
|
-
const HELP_FLAGS$
|
|
325
|
+
const HELP_FLAGS$11 = new Set(["--help", "-h"]);
|
|
326
326
|
const LOCAL_CONCAVE_HOST = "127.0.0.1";
|
|
327
327
|
const LOCAL_CONCAVE_DEV_PORT = 3210;
|
|
328
328
|
const LOCAL_CONCAVE_SITE_PORT = 3211;
|
|
@@ -851,7 +851,7 @@ Options:
|
|
|
851
851
|
--no-migrations-wait Skip waiting for migration completion`;
|
|
852
852
|
const handleDevCommand = async (argv, deps) => {
|
|
853
853
|
const parsed = parseArgs(argv);
|
|
854
|
-
if (HELP_FLAGS$
|
|
854
|
+
if (HELP_FLAGS$11.has(argv[0] ?? "") || HELP_FLAGS$11.has(parsed.restArgs[0] ?? "")) {
|
|
855
855
|
logger.write(DEV_HELP_TEXT);
|
|
856
856
|
return 0;
|
|
857
857
|
}
|
|
@@ -1169,7 +1169,7 @@ const handleDevCommand = async (argv, deps) => {
|
|
|
1169
1169
|
|
|
1170
1170
|
//#endregion
|
|
1171
1171
|
//#region src/cli/commands/add.ts
|
|
1172
|
-
const HELP_FLAGS$
|
|
1172
|
+
const HELP_FLAGS$10 = new Set(["--help", "-h"]);
|
|
1173
1173
|
const RAW_CONVEX_AUTH_PRESET = "convex";
|
|
1174
1174
|
const AUTH_SCHEMA_ONLY_SCOPE = "schema";
|
|
1175
1175
|
const AUTH_SCHEMA_FLAG = "--schema";
|
|
@@ -1340,7 +1340,7 @@ const assertRawConvexAuthDeploymentReady = () => {
|
|
|
1340
1340
|
};
|
|
1341
1341
|
const handleAddCommand = async (argv, deps = {}) => {
|
|
1342
1342
|
const parsed = parseArgs(argv);
|
|
1343
|
-
if (HELP_FLAGS$
|
|
1343
|
+
if (HELP_FLAGS$10.has(argv[0] ?? "") || HELP_FLAGS$10.has(parsed.restArgs[0] ?? "")) {
|
|
1344
1344
|
logger.write(ADD_HELP_TEXT);
|
|
1345
1345
|
return 0;
|
|
1346
1346
|
}
|
|
@@ -1599,6 +1599,102 @@ const handleAnalyzeCommand = async (argv, deps = {}) => {
|
|
|
1599
1599
|
return runAnalyze(parsed.restArgs);
|
|
1600
1600
|
};
|
|
1601
1601
|
|
|
1602
|
+
//#endregion
|
|
1603
|
+
//#region src/cli/commands/auth.ts
|
|
1604
|
+
const HELP_FLAGS$9 = new Set(["--help", "-h"]);
|
|
1605
|
+
const AUTH_JWKS_FUNCTION = "generated/auth:getLatestJwks";
|
|
1606
|
+
const AUTH_ROTATE_KEYS_FUNCTION = "generated/auth:rotateKeys";
|
|
1607
|
+
const AUTH_HELP_TEXT = `Usage: kitcn auth jwks [options]
|
|
1608
|
+
|
|
1609
|
+
Commands:
|
|
1610
|
+
jwks Print a manual JWKS env payload from the auth runtime
|
|
1611
|
+
|
|
1612
|
+
Options:
|
|
1613
|
+
--rotate Rotate auth keys before fetching JWKS
|
|
1614
|
+
--json Machine-readable output
|
|
1615
|
+
|
|
1616
|
+
Target options:
|
|
1617
|
+
Convex: --prod --deployment-name <name> --preview-name <name> --env-file <path> --component <name>
|
|
1618
|
+
Concave: --url <url> --port <port> --component <name>`;
|
|
1619
|
+
const parseAuthCommandArgs = (args) => {
|
|
1620
|
+
const subcommand = args[0];
|
|
1621
|
+
if (!subcommand) throw new Error("Missing auth command. Usage: `kitcn auth jwks`.");
|
|
1622
|
+
if (subcommand !== "jwks") throw new Error(`Unknown auth command "${subcommand}". Supported commands: jwks.`);
|
|
1623
|
+
let json = false;
|
|
1624
|
+
let rotate = false;
|
|
1625
|
+
const targetRemainder = [];
|
|
1626
|
+
for (const arg of args.slice(1)) {
|
|
1627
|
+
if (arg === "--json") {
|
|
1628
|
+
json = true;
|
|
1629
|
+
continue;
|
|
1630
|
+
}
|
|
1631
|
+
if (arg === "--rotate") {
|
|
1632
|
+
rotate = true;
|
|
1633
|
+
continue;
|
|
1634
|
+
}
|
|
1635
|
+
targetRemainder.push(arg);
|
|
1636
|
+
}
|
|
1637
|
+
return {
|
|
1638
|
+
json,
|
|
1639
|
+
rotate,
|
|
1640
|
+
subcommand,
|
|
1641
|
+
targetRemainder
|
|
1642
|
+
};
|
|
1643
|
+
};
|
|
1644
|
+
const formatRelativePath = (cwd, filePath) => path.relative(cwd, filePath).replaceAll("\\", "/") || ".";
|
|
1645
|
+
const assertAuthRuntimeReady = (sharedDir) => {
|
|
1646
|
+
const cwd = process.cwd();
|
|
1647
|
+
const authState = resolveAuthEnvState({
|
|
1648
|
+
cwd,
|
|
1649
|
+
sharedDir
|
|
1650
|
+
});
|
|
1651
|
+
if (!authState.installed) throw new Error(`Auth JWKS export requires auth scaffold at ${formatRelativePath(cwd, authState.definitionPath)}. Install auth first.`);
|
|
1652
|
+
if (!authState.runtimeReady) throw new Error(`Auth JWKS export requires generated auth runtime at ${formatRelativePath(cwd, authState.generatedPath)}. Run \`kitcn codegen\` or \`kitcn dev --bootstrap\` first.`);
|
|
1653
|
+
};
|
|
1654
|
+
const parseRunValue = (stdout) => {
|
|
1655
|
+
const parsed = parseBackendRunJson(stdout);
|
|
1656
|
+
return typeof parsed === "string" ? parsed : JSON.stringify(parsed);
|
|
1657
|
+
};
|
|
1658
|
+
const handleAuthCommand = async (argv, deps = {}) => {
|
|
1659
|
+
const parsed = parseArgs(argv);
|
|
1660
|
+
if (argv.length === 0 || HELP_FLAGS$9.has(argv[0] ?? "") || parsed.restArgs.length === 0 || parsed.restArgs.some((arg) => HELP_FLAGS$9.has(arg))) {
|
|
1661
|
+
logger.write(AUTH_HELP_TEXT);
|
|
1662
|
+
return 0;
|
|
1663
|
+
}
|
|
1664
|
+
const authArgs = parseAuthCommandArgs(parsed.restArgs);
|
|
1665
|
+
const { execa: execaFn, loadCliConfig: loadCliConfigFn, realConcave: realConcavePath, realConvex: realConvexPath } = resolveRunDeps(deps);
|
|
1666
|
+
const config = loadCliConfigFn(parsed.configPath);
|
|
1667
|
+
const backend = resolveConfiguredBackend({
|
|
1668
|
+
backendArg: parsed.backend,
|
|
1669
|
+
config
|
|
1670
|
+
});
|
|
1671
|
+
const backendAdapter = createBackendAdapter({
|
|
1672
|
+
backend,
|
|
1673
|
+
realConvexPath,
|
|
1674
|
+
realConcavePath
|
|
1675
|
+
});
|
|
1676
|
+
assertAuthRuntimeReady(parsed.sharedDir ?? config.paths.shared);
|
|
1677
|
+
const targetArgs = extractBackendRunTargetArgs(backend, authArgs.targetRemainder);
|
|
1678
|
+
if (authArgs.rotate) {
|
|
1679
|
+
const rotateResult = await runBackendFunction(execaFn, backendAdapter, AUTH_ROTATE_KEYS_FUNCTION, {}, targetArgs, { echoOutput: false });
|
|
1680
|
+
if (rotateResult.exitCode !== 0) return rotateResult.exitCode;
|
|
1681
|
+
}
|
|
1682
|
+
const jwksResult = await runBackendFunction(execaFn, backendAdapter, AUTH_JWKS_FUNCTION, {}, targetArgs, { echoOutput: false });
|
|
1683
|
+
if (jwksResult.exitCode !== 0) return jwksResult.exitCode;
|
|
1684
|
+
const jwks = parseRunValue(jwksResult.stdout);
|
|
1685
|
+
const envLine = `JWKS=${serializeEnvValue(jwks)}`;
|
|
1686
|
+
if (authArgs.json) console.info(JSON.stringify({
|
|
1687
|
+
backend,
|
|
1688
|
+
command: "auth",
|
|
1689
|
+
envLine,
|
|
1690
|
+
jwks,
|
|
1691
|
+
rotated: authArgs.rotate,
|
|
1692
|
+
subcommand: authArgs.subcommand
|
|
1693
|
+
}));
|
|
1694
|
+
else console.info(envLine);
|
|
1695
|
+
return 0;
|
|
1696
|
+
};
|
|
1697
|
+
|
|
1602
1698
|
//#endregion
|
|
1603
1699
|
//#region src/cli/commands/codegen.ts
|
|
1604
1700
|
const HELP_FLAGS$8 = new Set(["--help", "-h"]);
|
|
@@ -2553,6 +2649,7 @@ const COMMAND_HELP = {
|
|
|
2553
2649
|
view: VIEW_HELP_TEXT,
|
|
2554
2650
|
info: INFO_HELP_TEXT,
|
|
2555
2651
|
docs: DOCS_HELP_TEXT,
|
|
2652
|
+
auth: AUTH_HELP_TEXT,
|
|
2556
2653
|
dev: DEV_HELP_TEXT,
|
|
2557
2654
|
verify: VERIFY_HELP_TEXT,
|
|
2558
2655
|
codegen: CODEGEN_HELP_TEXT,
|
|
@@ -2565,6 +2662,7 @@ const COMMAND_HANDLERS = {
|
|
|
2565
2662
|
view: handleViewCommand,
|
|
2566
2663
|
info: handleInfoCommand,
|
|
2567
2664
|
docs: handleDocsCommand,
|
|
2665
|
+
auth: handleAuthCommand,
|
|
2568
2666
|
verify: handleVerifyCommand,
|
|
2569
2667
|
codegen: handleCodegenCommand,
|
|
2570
2668
|
env: handleEnvCommand,
|
|
@@ -2601,6 +2699,7 @@ Commands:
|
|
|
2601
2699
|
view [plugin] Inspect a plugin install plan without writing
|
|
2602
2700
|
info Inspect project + installed plugin state
|
|
2603
2701
|
docs <topic...> Show docs links for CLI and plugins
|
|
2702
|
+
auth Auth runtime helpers
|
|
2604
2703
|
env Manage Convex environment variables
|
|
2605
2704
|
deploy Deploy with migrations/backfill flows
|
|
2606
2705
|
migrate Migration lifecycle commands
|
package/dist/{generated-contract-disabled-Cf7sqlVD.d.ts → generated-contract-disabled-9Yg1NHlV.d.ts}
RENAMED
|
@@ -216,8 +216,8 @@ declare const createApi: <Schema extends SchemaDefinition<any, any>, DataModel e
|
|
|
216
216
|
};
|
|
217
217
|
}, Promise<Record<string, unknown> | undefined>>;
|
|
218
218
|
findMany: convex_server0.RegisteredQuery<"internal", {
|
|
219
|
-
limit?: number | undefined;
|
|
220
219
|
join?: any;
|
|
220
|
+
limit?: number | undefined;
|
|
221
221
|
where?: {
|
|
222
222
|
operator?: "eq" | "ne" | "lt" | "lte" | "gt" | "gte" | "in" | "not_in" | "contains" | "starts_with" | "ends_with" | undefined;
|
|
223
223
|
connector?: "AND" | "OR" | undefined;
|
|
@@ -226,8 +226,8 @@ declare const createApi: <Schema extends SchemaDefinition<any, any>, DataModel e
|
|
|
226
226
|
}[] | undefined;
|
|
227
227
|
offset?: number | undefined;
|
|
228
228
|
sortBy?: {
|
|
229
|
-
direction: "asc" | "desc";
|
|
230
229
|
field: string;
|
|
230
|
+
direction: "asc" | "desc";
|
|
231
231
|
} | undefined;
|
|
232
232
|
paginationOpts: {
|
|
233
233
|
id?: number;
|
package/dist/orm/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as GenericOrmCtx$1, $n as unique, $r as endsWith, $t as ManyConfig, A as ConvexDateMode, An as ConvexRankIndexBuilder, Ar as ReturningResult, At as MigrationManifestEntry, B as ConvexBytesBuilderInitial, Bn as rankIndex, Br as OrmSchemaRelations, Bt as defineMigration, C as ConvexNumberBuilderInitial, Ci as ColumnBuilderWithTableName, Cn as RlsRole, Cr as MutationReturning, Ct as MigrationStatusArgs, D as id, Di as IsPrimaryKey, Dn as ConvexAggregateIndexBuilderOn, Dr as PaginatedResult, Dt as MigrationDoc, E as ConvexIdBuilderInitial, Ei as HasDefault, En as ConvexAggregateIndexBuilder, Er as OrderDirection, Et as MigrationDirection, F as custom, Fn as ConvexVectorIndexBuilder, Fr as unsetToken, Ft as MigrationStateMap, G as ConvexBigIntBuilder, Gn as ConvexCheckConfig, Gr as ExpressionVisitor, Gt as OrmReader$1, H as ConvexBooleanBuilder, Hn as uniqueIndex, Hr as TableName, Ht as detectMigrationDrift, I as json, In as ConvexVectorIndexBuilderOn, Ir as Brand, It as MigrationStep, J as CountBackfillChunkArgs, Jn as ConvexUniqueConstraintBuilder, Jr as LogicalExpression, Jt as RlsMode, K as ConvexBigIntBuilderInitial, Kn as ConvexForeignKeyBuilder, Kr as FieldReference, Kt as OrmWriter$1, L as objectOf, Ln as ConvexVectorIndexConfig, Lr as Columns, Lt as MigrationTableName, M as ConvexCustomBuilder, Mn as ConvexSearchIndexBuilder, Mr as UpdateSet, Mt as MigrationPlan, N as ConvexCustomBuilderInitial, Nn as ConvexSearchIndexBuilderOn, Nr as VectorQueryConfig, Nt as MigrationRunStatus, O as ConvexDateBuilder, Oi as IsUnique, On as ConvexIndexBuilder, Or as PredicateWhereIndexConfig, Ot as MigrationDocContext, P as arrayOf, Pn as ConvexSearchIndexConfig, Pr as VectorSearchProvider, Pt as MigrationSet, Q as GenericOrm$1, Qn as foreignKey, Qr as contains, Qt as ExtractTablesWithRelations, R as unionOf, Rn as aggregateIndex, Rr as OrmSchemaExtensionTables, Rt as MigrationWriteMode, S as ConvexNumberBuilder, Si as ColumnBuilderTypeConfig, Sn as rlsPolicy, Sr as MutationResult, St as MigrationRunChunkArgs, T as ConvexIdBuilder, Ti as DrizzleEntity, Tn as rlsRole, Tr as OrderByClause, Tt as MigrationDefinition, U as ConvexBooleanBuilderInitial, Un as vectorIndex, Ur as SystemFields, Ut as DatabaseWithMutations, V as bytes, Vn as searchIndex, Vr as OrmSchemaTriggers, Vt as defineMigrationSet, W as boolean, Wn as ConvexCheckBuilder, Wr as BinaryExpression, Wt as DatabaseWithQuery, X as CountBackfillStatusArgs, Xn as ConvexUniqueConstraintConfig, Xr as and, Xt as extractRelationsConfig, Y as CountBackfillKickoffArgs, Yn as ConvexUniqueConstraintBuilderOn, Yr as UnaryExpression, Yt as EdgeMetadata, Z as CreateOrmOptions, Zn as check, Zr as between, Zt as ExtractTablesFromSchema, _ as ConvexTimestampMode, _i as startsWith, _n as deletion, _r as MutationExecuteConfig, _t as OrmTriggerContext, a as requireSchemaRelations, ai as inArray, an as TablesRelationalConfig, ar as AggregateResult, at as OrmWriterCtx, b as ConvexTextEnumBuilderInitial, bi as ColumnBuilderBaseConfig, bn as RlsPolicyConfig, br as MutationPaginateConfig, bt as MigrationCancelArgs, c as TableConfigResult, ci as isNull, cn as ConvexDeletionBuilder, cr as CountConfig, ct as ScheduledMutationBatchArgs, d as OrmNotFoundError, di as lte, dn as ConvexTableWithColumns, dr as FilterOperators, dt as scheduledDeleteFactory, ei as eq, en as OneConfig, er as ConvexTextBuilder, et as OrmApiResult, f as ConvexVectorBuilder, fi as ne, fn as DiscriminatorBuilderConfig, fr as GetColumnData, ft as SchemaExtension, g as ConvexTimestampBuilderInitial, gi as or, gn as convexTable, gr as InsertValue, gt as OrmTriggerChange, h as ConvexTimestampBuilder, hi as notInArray, hn as TableConfig, hr as InferSelectModel, ht as OrmTableTriggers, i as getSchemaTriggers, ii as ilike, in as TableRelationalConfig, ir as AggregateFieldValue, it as OrmReaderCtx, j as date, jn as ConvexRankIndexBuilderOn, jr as ReturningSelection, jt as MigrationMigrateOne, k as ConvexDateBuilderInitial, ki as NotNull, kn as ConvexIndexBuilderOn, kr as ReturningAll, kt as MigrationDriftIssue, l as getTableColumns, li as like, ln as ConvexDeletionConfig, lr as CountResult, lt as scheduledMutationBatchFactory, m as vector, mi as notBetween, mn as OrmLifecycleOperation, mr as InferModelFromColumns, mt as OrmBeforeResult, n as defineSchema, ni as gt, nn as RelationsBuilderColumnBase, nr as text, nt as OrmClientWithApi$1, o as asc, oi as isFieldReference, on as defineRelations, or as BuildQueryResult, ot as ResolveOrmSchema, p as ConvexVectorBuilderInitial, pi as not, pn as OrmLifecycleChange, pr as InferInsertModel, pt as defineSchemaExtension, q as bigint, qn as ConvexForeignKeyConfig, qr as FilterExpression, qt as RlsContext, r as getSchemaRelations, ri as gte, rn as RelationsBuilderColumnConfig, rr as AggregateConfig, rt as OrmFunctions, s as desc, si as isNotNull, sn as defineRelationsPart, sr as BuildRelationResult, st as createOrm, t as WhereClauseResult, ti as fieldRef, tn as RelationsBuilder, tr as ConvexTextBuilderInitial, tt as OrmClientBase$1, u as getTableConfig, ui as lt, un as ConvexTable, ur as DBQueryConfig, ut as ScheduledDeleteArgs, v as timestamp, vi as AnyColumn, vn as discriminator, vr as MutationExecuteResult, vt as OrmTriggers, w as integer, wi as ColumnDataType, wn as RlsRoleConfig, wr as MutationRunMode, wt as MigrationAppliedState, x as textEnum, xi as ColumnBuilderRuntimeConfig, xn as RlsPolicyToOption, xr as MutationPaginatedResult, xt as MigrationRunArgs, y as ConvexTextEnumBuilder, yi as ColumnBuilder, yn as RlsPolicy, yr as MutationExecutionMode, yt as defineTriggers, z as ConvexBytesBuilder, zn as index, zr as OrmSchemaExtensions, zt as buildMigrationPlan } from "../where-clause-compiler-
|
|
1
|
+
import { $ as GenericOrmCtx$1, $n as unique, $r as endsWith, $t as ManyConfig, A as ConvexDateMode, An as ConvexRankIndexBuilder, Ar as ReturningResult, At as MigrationManifestEntry, B as ConvexBytesBuilderInitial, Bn as rankIndex, Br as OrmSchemaRelations, Bt as defineMigration, C as ConvexNumberBuilderInitial, Ci as ColumnBuilderWithTableName, Cn as RlsRole, Cr as MutationReturning, Ct as MigrationStatusArgs, D as id, Di as IsPrimaryKey, Dn as ConvexAggregateIndexBuilderOn, Dr as PaginatedResult, Dt as MigrationDoc, E as ConvexIdBuilderInitial, Ei as HasDefault, En as ConvexAggregateIndexBuilder, Er as OrderDirection, Et as MigrationDirection, F as custom, Fn as ConvexVectorIndexBuilder, Fr as unsetToken, Ft as MigrationStateMap, G as ConvexBigIntBuilder, Gn as ConvexCheckConfig, Gr as ExpressionVisitor, Gt as OrmReader$1, H as ConvexBooleanBuilder, Hn as uniqueIndex, Hr as TableName, Ht as detectMigrationDrift, I as json, In as ConvexVectorIndexBuilderOn, Ir as Brand, It as MigrationStep, J as CountBackfillChunkArgs, Jn as ConvexUniqueConstraintBuilder, Jr as LogicalExpression, Jt as RlsMode, K as ConvexBigIntBuilderInitial, Kn as ConvexForeignKeyBuilder, Kr as FieldReference, Kt as OrmWriter$1, L as objectOf, Ln as ConvexVectorIndexConfig, Lr as Columns, Lt as MigrationTableName, M as ConvexCustomBuilder, Mn as ConvexSearchIndexBuilder, Mr as UpdateSet, Mt as MigrationPlan, N as ConvexCustomBuilderInitial, Nn as ConvexSearchIndexBuilderOn, Nr as VectorQueryConfig, Nt as MigrationRunStatus, O as ConvexDateBuilder, Oi as IsUnique, On as ConvexIndexBuilder, Or as PredicateWhereIndexConfig, Ot as MigrationDocContext, P as arrayOf, Pn as ConvexSearchIndexConfig, Pr as VectorSearchProvider, Pt as MigrationSet, Q as GenericOrm$1, Qn as foreignKey, Qr as contains, Qt as ExtractTablesWithRelations, R as unionOf, Rn as aggregateIndex, Rr as OrmSchemaExtensionTables, Rt as MigrationWriteMode, S as ConvexNumberBuilder, Si as ColumnBuilderTypeConfig, Sn as rlsPolicy, Sr as MutationResult, St as MigrationRunChunkArgs, T as ConvexIdBuilder, Ti as DrizzleEntity, Tn as rlsRole, Tr as OrderByClause, Tt as MigrationDefinition, U as ConvexBooleanBuilderInitial, Un as vectorIndex, Ur as SystemFields, Ut as DatabaseWithMutations, V as bytes, Vn as searchIndex, Vr as OrmSchemaTriggers, Vt as defineMigrationSet, W as boolean, Wn as ConvexCheckBuilder, Wr as BinaryExpression, Wt as DatabaseWithQuery, X as CountBackfillStatusArgs, Xn as ConvexUniqueConstraintConfig, Xr as and, Xt as extractRelationsConfig, Y as CountBackfillKickoffArgs, Yn as ConvexUniqueConstraintBuilderOn, Yr as UnaryExpression, Yt as EdgeMetadata, Z as CreateOrmOptions, Zn as check, Zr as between, Zt as ExtractTablesFromSchema, _ as ConvexTimestampMode, _i as startsWith, _n as deletion, _r as MutationExecuteConfig, _t as OrmTriggerContext, a as requireSchemaRelations, ai as inArray, an as TablesRelationalConfig, ar as AggregateResult, at as OrmWriterCtx, b as ConvexTextEnumBuilderInitial, bi as ColumnBuilderBaseConfig, bn as RlsPolicyConfig, br as MutationPaginateConfig, bt as MigrationCancelArgs, c as TableConfigResult, ci as isNull, cn as ConvexDeletionBuilder, cr as CountConfig, ct as ScheduledMutationBatchArgs, d as OrmNotFoundError, di as lte, dn as ConvexTableWithColumns, dr as FilterOperators, dt as scheduledDeleteFactory, ei as eq, en as OneConfig, er as ConvexTextBuilder, et as OrmApiResult, f as ConvexVectorBuilder, fi as ne, fn as DiscriminatorBuilderConfig, fr as GetColumnData, ft as SchemaExtension, g as ConvexTimestampBuilderInitial, gi as or, gn as convexTable, gr as InsertValue, gt as OrmTriggerChange, h as ConvexTimestampBuilder, hi as notInArray, hn as TableConfig, hr as InferSelectModel, ht as OrmTableTriggers, i as getSchemaTriggers, ii as ilike, in as TableRelationalConfig, ir as AggregateFieldValue, it as OrmReaderCtx, j as date, jn as ConvexRankIndexBuilderOn, jr as ReturningSelection, jt as MigrationMigrateOne, k as ConvexDateBuilderInitial, ki as NotNull, kn as ConvexIndexBuilderOn, kr as ReturningAll, kt as MigrationDriftIssue, l as getTableColumns, li as like, ln as ConvexDeletionConfig, lr as CountResult, lt as scheduledMutationBatchFactory, m as vector, mi as notBetween, mn as OrmLifecycleOperation, mr as InferModelFromColumns, mt as OrmBeforeResult, n as defineSchema, ni as gt, nn as RelationsBuilderColumnBase, nr as text, nt as OrmClientWithApi$1, o as asc, oi as isFieldReference, on as defineRelations, or as BuildQueryResult, ot as ResolveOrmSchema, p as ConvexVectorBuilderInitial, pi as not, pn as OrmLifecycleChange, pr as InferInsertModel, pt as defineSchemaExtension, q as bigint, qn as ConvexForeignKeyConfig, qr as FilterExpression, qt as RlsContext, r as getSchemaRelations, ri as gte, rn as RelationsBuilderColumnConfig, rr as AggregateConfig, rt as OrmFunctions, s as desc, si as isNotNull, sn as defineRelationsPart, sr as BuildRelationResult, st as createOrm, t as WhereClauseResult, ti as fieldRef, tn as RelationsBuilder, tr as ConvexTextBuilderInitial, tt as OrmClientBase$1, u as getTableConfig, ui as lt, un as ConvexTable, ur as DBQueryConfig, ut as ScheduledDeleteArgs, v as timestamp, vi as AnyColumn, vn as discriminator, vr as MutationExecuteResult, vt as OrmTriggers, w as integer, wi as ColumnDataType, wn as RlsRoleConfig, wr as MutationRunMode, wt as MigrationAppliedState, x as textEnum, xi as ColumnBuilderRuntimeConfig, xn as RlsPolicyToOption, xr as MutationPaginatedResult, xt as MigrationRunArgs, y as ConvexTextEnumBuilder, yi as ColumnBuilder, yn as RlsPolicy, yr as MutationExecutionMode, yt as defineTriggers, z as ConvexBytesBuilder, zn as index, zr as OrmSchemaExtensions, zt as buildMigrationPlan } from "../where-clause-compiler-BpfS2FJi.js";
|
|
2
2
|
import { i as pretendRequired, n as deprecated, r as pretend } from "../validators-vzRKjBJC.js";
|
|
3
3
|
import { a as QueryCtxWithPreferredOrmQueryTable, i as QueryCtxWithOrmQueryTable, n as LookupByIdResultByCtx, o as getByIdWithOrmQueryFallback, r as QueryCtxWithOptionalOrmQueryTable, t as DocByCtx } from "../query-context-CFZqIvD7.js";
|
|
4
4
|
import { DefineSchemaOptions, GenericDatabaseReader, GenericDatabaseWriter, GenericSchema, SchemaDefinition } from "convex/server";
|
package/dist/watcher.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
2
|
+
import { A as resolveConfiguredBackend, Ct as getConvexConfig, P as resolveRunDeps, St as generateMeta, wt as logger } from "./backend-core-Cf6h5gQc.mjs";
|
|
3
3
|
import path from "node:path";
|
|
4
4
|
import { fileURLToPath } from "node:url";
|
|
5
5
|
|
|
@@ -3717,6 +3717,19 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
3717
3717
|
readonly aggregate_bucket: ConvexTableWithColumns<{
|
|
3718
3718
|
name: "aggregate_bucket";
|
|
3719
3719
|
columns: {
|
|
3720
|
+
count: ConvexNumberBuilderInitial<""> & {
|
|
3721
|
+
_: {
|
|
3722
|
+
notNull: true;
|
|
3723
|
+
};
|
|
3724
|
+
} & {
|
|
3725
|
+
_: {
|
|
3726
|
+
tableName: "aggregate_bucket";
|
|
3727
|
+
};
|
|
3728
|
+
} & {
|
|
3729
|
+
_: {
|
|
3730
|
+
fieldName: "count";
|
|
3731
|
+
};
|
|
3732
|
+
};
|
|
3720
3733
|
tableKey: ConvexTextBuilderInitial<""> & {
|
|
3721
3734
|
_: {
|
|
3722
3735
|
notNull: true;
|
|
@@ -3786,19 +3799,6 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
3786
3799
|
fieldName: "keyParts";
|
|
3787
3800
|
};
|
|
3788
3801
|
};
|
|
3789
|
-
count: ConvexNumberBuilderInitial<""> & {
|
|
3790
|
-
_: {
|
|
3791
|
-
notNull: true;
|
|
3792
|
-
};
|
|
3793
|
-
} & {
|
|
3794
|
-
_: {
|
|
3795
|
-
tableName: "aggregate_bucket";
|
|
3796
|
-
};
|
|
3797
|
-
} & {
|
|
3798
|
-
_: {
|
|
3799
|
-
fieldName: "count";
|
|
3800
|
-
};
|
|
3801
|
-
};
|
|
3802
3802
|
sumValues: (NotNull<$Type<ConvexCustomBuilderInitial<"", convex_values0.VRecord<Record<string, any>, convex_values0.VString<string, "required">, convex_values0.VId<any, any> | convex_values0.VString<any, any> | convex_values0.VFloat64<any, any> | convex_values0.VInt64<any, any> | convex_values0.VBoolean<any, any> | convex_values0.VNull<any, any> | convex_values0.VAny<any, any, string> | convex_values0.VLiteral<any, any> | convex_values0.VBytes<any, any> | convex_values0.VObject<any, Record<string, convex_values0.Validator<any, convex_values0.OptionalProperty, any>>, any, any> | convex_values0.VArray<any, convex_values0.Validator<any, "required", any>, any> | convex_values0.VRecord<any, convex_values0.Validator<string, "required", any>, convex_values0.Validator<any, "required", any>, any, any> | convex_values0.VUnion<any, convex_values0.Validator<any, "required", any>[], any, any>, "required", string>>, Record<string, number>>> | NotNull<$Type<ConvexCustomBuilderInitial<"", convex_values0.VId<any, any> | convex_values0.VString<any, any> | convex_values0.VFloat64<any, any> | convex_values0.VInt64<any, any> | convex_values0.VBoolean<any, any> | convex_values0.VNull<any, any> | convex_values0.VAny<any, any, string> | convex_values0.VLiteral<any, any> | convex_values0.VBytes<any, any> | convex_values0.VObject<any, Record<string, convex_values0.Validator<any, convex_values0.OptionalProperty, any>>, any, any> | convex_values0.VArray<any, convex_values0.Validator<any, "required", any>, any> | convex_values0.VRecord<any, convex_values0.Validator<string, "required", any>, convex_values0.Validator<any, "required", any>, any, any> | convex_values0.VUnion<any, convex_values0.Validator<any, "required", any>[], any, any>>, Record<string, number>>>) & {
|
|
3803
3803
|
_: {
|
|
3804
3804
|
tableName: "aggregate_bucket";
|
|
@@ -3826,7 +3826,7 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
3826
3826
|
readonly aggregate_member: ConvexTableWithColumns<{
|
|
3827
3827
|
name: "aggregate_member";
|
|
3828
3828
|
columns: {
|
|
3829
|
-
|
|
3829
|
+
kind: ConvexTextBuilderInitial<""> & {
|
|
3830
3830
|
_: {
|
|
3831
3831
|
notNull: true;
|
|
3832
3832
|
};
|
|
@@ -3836,10 +3836,10 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
3836
3836
|
};
|
|
3837
3837
|
} & {
|
|
3838
3838
|
_: {
|
|
3839
|
-
fieldName: "
|
|
3839
|
+
fieldName: "kind";
|
|
3840
3840
|
};
|
|
3841
3841
|
};
|
|
3842
|
-
|
|
3842
|
+
tableKey: ConvexTextBuilderInitial<""> & {
|
|
3843
3843
|
_: {
|
|
3844
3844
|
notNull: true;
|
|
3845
3845
|
};
|
|
@@ -3849,7 +3849,7 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
3849
3849
|
};
|
|
3850
3850
|
} & {
|
|
3851
3851
|
_: {
|
|
3852
|
-
fieldName: "
|
|
3852
|
+
fieldName: "tableKey";
|
|
3853
3853
|
};
|
|
3854
3854
|
};
|
|
3855
3855
|
indexName: ConvexTextBuilderInitial<""> & {
|
|
@@ -3992,7 +3992,11 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
3992
3992
|
readonly aggregate_extrema: ConvexTableWithColumns<{
|
|
3993
3993
|
name: "aggregate_extrema";
|
|
3994
3994
|
columns: {
|
|
3995
|
-
|
|
3995
|
+
value: ConvexCustomBuilderInitial<"", convex_values0.VAny<any, "required", string>> & {
|
|
3996
|
+
_: {
|
|
3997
|
+
$type: convex_values0.Value;
|
|
3998
|
+
};
|
|
3999
|
+
} & {
|
|
3996
4000
|
_: {
|
|
3997
4001
|
notNull: true;
|
|
3998
4002
|
};
|
|
@@ -4002,10 +4006,10 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4002
4006
|
};
|
|
4003
4007
|
} & {
|
|
4004
4008
|
_: {
|
|
4005
|
-
fieldName: "
|
|
4009
|
+
fieldName: "value";
|
|
4006
4010
|
};
|
|
4007
4011
|
};
|
|
4008
|
-
|
|
4012
|
+
count: ConvexNumberBuilderInitial<""> & {
|
|
4009
4013
|
_: {
|
|
4010
4014
|
notNull: true;
|
|
4011
4015
|
};
|
|
@@ -4015,10 +4019,10 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4015
4019
|
};
|
|
4016
4020
|
} & {
|
|
4017
4021
|
_: {
|
|
4018
|
-
fieldName: "
|
|
4022
|
+
fieldName: "count";
|
|
4019
4023
|
};
|
|
4020
4024
|
};
|
|
4021
|
-
|
|
4025
|
+
tableKey: ConvexTextBuilderInitial<""> & {
|
|
4022
4026
|
_: {
|
|
4023
4027
|
notNull: true;
|
|
4024
4028
|
};
|
|
@@ -4028,14 +4032,10 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4028
4032
|
};
|
|
4029
4033
|
} & {
|
|
4030
4034
|
_: {
|
|
4031
|
-
fieldName: "
|
|
4035
|
+
fieldName: "tableKey";
|
|
4032
4036
|
};
|
|
4033
4037
|
};
|
|
4034
|
-
|
|
4035
|
-
_: {
|
|
4036
|
-
$type: convex_values0.Value;
|
|
4037
|
-
};
|
|
4038
|
-
} & {
|
|
4038
|
+
indexName: ConvexTextBuilderInitial<""> & {
|
|
4039
4039
|
_: {
|
|
4040
4040
|
notNull: true;
|
|
4041
4041
|
};
|
|
@@ -4045,10 +4045,10 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4045
4045
|
};
|
|
4046
4046
|
} & {
|
|
4047
4047
|
_: {
|
|
4048
|
-
fieldName: "
|
|
4048
|
+
fieldName: "indexName";
|
|
4049
4049
|
};
|
|
4050
4050
|
};
|
|
4051
|
-
|
|
4051
|
+
updatedAt: ConvexNumberBuilderInitial<""> & {
|
|
4052
4052
|
_: {
|
|
4053
4053
|
notNull: true;
|
|
4054
4054
|
};
|
|
@@ -4058,10 +4058,10 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4058
4058
|
};
|
|
4059
4059
|
} & {
|
|
4060
4060
|
_: {
|
|
4061
|
-
fieldName: "
|
|
4061
|
+
fieldName: "updatedAt";
|
|
4062
4062
|
};
|
|
4063
4063
|
};
|
|
4064
|
-
|
|
4064
|
+
keyHash: ConvexTextBuilderInitial<""> & {
|
|
4065
4065
|
_: {
|
|
4066
4066
|
notNull: true;
|
|
4067
4067
|
};
|
|
@@ -4071,7 +4071,7 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4071
4071
|
};
|
|
4072
4072
|
} & {
|
|
4073
4073
|
_: {
|
|
4074
|
-
fieldName: "
|
|
4074
|
+
fieldName: "keyHash";
|
|
4075
4075
|
};
|
|
4076
4076
|
};
|
|
4077
4077
|
fieldName: ConvexTextBuilderInitial<""> & {
|
|
@@ -4244,7 +4244,7 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4244
4244
|
readonly aggregate_state: ConvexTableWithColumns<{
|
|
4245
4245
|
name: "aggregate_state";
|
|
4246
4246
|
columns: {
|
|
4247
|
-
|
|
4247
|
+
kind: ConvexTextBuilderInitial<""> & {
|
|
4248
4248
|
_: {
|
|
4249
4249
|
notNull: true;
|
|
4250
4250
|
};
|
|
@@ -4254,10 +4254,19 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4254
4254
|
};
|
|
4255
4255
|
} & {
|
|
4256
4256
|
_: {
|
|
4257
|
-
fieldName: "
|
|
4257
|
+
fieldName: "kind";
|
|
4258
4258
|
};
|
|
4259
4259
|
};
|
|
4260
|
-
|
|
4260
|
+
cursor: ConvexTextBuilderInitial<""> & {
|
|
4261
|
+
_: {
|
|
4262
|
+
tableName: "aggregate_state";
|
|
4263
|
+
};
|
|
4264
|
+
} & {
|
|
4265
|
+
_: {
|
|
4266
|
+
fieldName: "cursor";
|
|
4267
|
+
};
|
|
4268
|
+
};
|
|
4269
|
+
tableKey: ConvexTextBuilderInitial<""> & {
|
|
4261
4270
|
_: {
|
|
4262
4271
|
notNull: true;
|
|
4263
4272
|
};
|
|
@@ -4267,7 +4276,7 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4267
4276
|
};
|
|
4268
4277
|
} & {
|
|
4269
4278
|
_: {
|
|
4270
|
-
fieldName: "
|
|
4279
|
+
fieldName: "tableKey";
|
|
4271
4280
|
};
|
|
4272
4281
|
};
|
|
4273
4282
|
indexName: ConvexTextBuilderInitial<""> & {
|
|
@@ -4322,15 +4331,6 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4322
4331
|
fieldName: "status";
|
|
4323
4332
|
};
|
|
4324
4333
|
};
|
|
4325
|
-
cursor: ConvexTextBuilderInitial<""> & {
|
|
4326
|
-
_: {
|
|
4327
|
-
tableName: "aggregate_state";
|
|
4328
|
-
};
|
|
4329
|
-
} & {
|
|
4330
|
-
_: {
|
|
4331
|
-
fieldName: "cursor";
|
|
4332
|
-
};
|
|
4333
|
-
};
|
|
4334
4334
|
processed: ConvexNumberBuilderInitial<""> & {
|
|
4335
4335
|
_: {
|
|
4336
4336
|
notNull: true;
|
|
@@ -4398,26 +4398,35 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4398
4398
|
readonly migration_state: ConvexTableWithColumns<{
|
|
4399
4399
|
name: "migration_state";
|
|
4400
4400
|
columns: {
|
|
4401
|
-
|
|
4401
|
+
direction: ConvexTextBuilderInitial<""> & {
|
|
4402
4402
|
_: {
|
|
4403
|
-
|
|
4403
|
+
tableName: "migration_state";
|
|
4404
4404
|
};
|
|
4405
4405
|
} & {
|
|
4406
|
+
_: {
|
|
4407
|
+
fieldName: "direction";
|
|
4408
|
+
};
|
|
4409
|
+
};
|
|
4410
|
+
cursor: ConvexTextBuilderInitial<""> & {
|
|
4406
4411
|
_: {
|
|
4407
4412
|
tableName: "migration_state";
|
|
4408
4413
|
};
|
|
4409
4414
|
} & {
|
|
4410
4415
|
_: {
|
|
4411
|
-
fieldName: "
|
|
4416
|
+
fieldName: "cursor";
|
|
4412
4417
|
};
|
|
4413
4418
|
};
|
|
4414
|
-
|
|
4419
|
+
status: ConvexTextBuilderInitial<""> & {
|
|
4420
|
+
_: {
|
|
4421
|
+
notNull: true;
|
|
4422
|
+
};
|
|
4423
|
+
} & {
|
|
4415
4424
|
_: {
|
|
4416
4425
|
tableName: "migration_state";
|
|
4417
4426
|
};
|
|
4418
4427
|
} & {
|
|
4419
4428
|
_: {
|
|
4420
|
-
fieldName: "
|
|
4429
|
+
fieldName: "status";
|
|
4421
4430
|
};
|
|
4422
4431
|
};
|
|
4423
4432
|
processed: ConvexNumberBuilderInitial<""> & {
|
|
@@ -4512,15 +4521,6 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4512
4521
|
fieldName: "applied";
|
|
4513
4522
|
};
|
|
4514
4523
|
};
|
|
4515
|
-
direction: ConvexTextBuilderInitial<""> & {
|
|
4516
|
-
_: {
|
|
4517
|
-
tableName: "migration_state";
|
|
4518
|
-
};
|
|
4519
|
-
} & {
|
|
4520
|
-
_: {
|
|
4521
|
-
fieldName: "direction";
|
|
4522
|
-
};
|
|
4523
|
-
};
|
|
4524
4524
|
runId: ConvexTextBuilderInitial<""> & {
|
|
4525
4525
|
_: {
|
|
4526
4526
|
tableName: "migration_state";
|
|
@@ -4552,6 +4552,19 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4552
4552
|
readonly migration_run: ConvexTableWithColumns<{
|
|
4553
4553
|
name: "migration_run";
|
|
4554
4554
|
columns: {
|
|
4555
|
+
direction: ConvexTextBuilderInitial<""> & {
|
|
4556
|
+
_: {
|
|
4557
|
+
notNull: true;
|
|
4558
|
+
};
|
|
4559
|
+
} & {
|
|
4560
|
+
_: {
|
|
4561
|
+
tableName: "migration_run";
|
|
4562
|
+
};
|
|
4563
|
+
} & {
|
|
4564
|
+
_: {
|
|
4565
|
+
fieldName: "direction";
|
|
4566
|
+
};
|
|
4567
|
+
};
|
|
4555
4568
|
status: ConvexTextBuilderInitial<""> & {
|
|
4556
4569
|
_: {
|
|
4557
4570
|
notNull: true;
|
|
@@ -4609,19 +4622,6 @@ declare const BUILTIN_SCHEMA_EXTENSIONS: readonly [SchemaExtension<{
|
|
|
4609
4622
|
fieldName: "lastError";
|
|
4610
4623
|
};
|
|
4611
4624
|
};
|
|
4612
|
-
direction: ConvexTextBuilderInitial<""> & {
|
|
4613
|
-
_: {
|
|
4614
|
-
notNull: true;
|
|
4615
|
-
};
|
|
4616
|
-
} & {
|
|
4617
|
-
_: {
|
|
4618
|
-
tableName: "migration_run";
|
|
4619
|
-
};
|
|
4620
|
-
} & {
|
|
4621
|
-
_: {
|
|
4622
|
-
fieldName: "direction";
|
|
4623
|
-
};
|
|
4624
|
-
};
|
|
4625
4625
|
runId: ConvexTextBuilderInitial<""> & {
|
|
4626
4626
|
_: {
|
|
4627
4627
|
notNull: true;
|
package/package.json
CHANGED
|
@@ -206,8 +206,10 @@ Local Convex:
|
|
|
206
206
|
Remote / repair:
|
|
207
207
|
1. Use `npx kitcn env push` when the target deployment is already active.
|
|
208
208
|
2. Use `npx kitcn env push --prod` for production sync.
|
|
209
|
+
3. Use `npx kitcn auth jwks` when you need a manual static `JWKS` payload, including backend `concave`.
|
|
209
210
|
|
|
210
211
|
Key rotation: `npx kitcn env push --rotate` (invalidates all tokens).
|
|
212
|
+
Manual rotation/export: `npx kitcn auth jwks --rotate`.
|
|
211
213
|
|
|
212
214
|
---
|
|
213
215
|
|
|
@@ -277,10 +277,16 @@ Use this to sync static `JWKS` onto the target deployment too.
|
|
|
277
277
|
```bash
|
|
278
278
|
bunx kitcn env push --prod
|
|
279
279
|
bunx kitcn env push --rotate
|
|
280
|
+
|
|
281
|
+
# Manual static JWKS payload, including backend concave
|
|
282
|
+
bunx kitcn auth jwks
|
|
283
|
+
bunx kitcn auth jwks --rotate
|
|
280
284
|
```
|
|
281
285
|
|
|
282
286
|
Use `--prod` for production and `--rotate` when you want fresh keys plus fresh
|
|
283
|
-
`JWKS`.
|
|
287
|
+
`JWKS`. `kitcn auth jwks` prints a manual `JWKS=...` line when you need to set
|
|
288
|
+
the env value yourself instead of using `env push`. See `/docs/cli/backend#env`
|
|
289
|
+
and `/docs/cli/backend#auth` for the full command surface.
|
|
284
290
|
|
|
285
291
|
Rotate later:
|
|
286
292
|
|
|
@@ -612,6 +612,8 @@ bunx kitcn codegen
|
|
|
612
612
|
bunx kitcn env push
|
|
613
613
|
bunx kitcn env push --prod
|
|
614
614
|
bunx kitcn env push --rotate
|
|
615
|
+
bunx kitcn auth jwks
|
|
616
|
+
bunx kitcn auth jwks --rotate
|
|
615
617
|
# deploy with automatic aggregate backfill:
|
|
616
618
|
bunx kitcn deploy --prod
|
|
617
619
|
# aggregate index management:
|
|
@@ -623,7 +625,9 @@ bunx kitcn analyze
|
|
|
623
625
|
|
|
624
626
|
On backend `convex`, `kitcn dev` watches `convex/.env` during a local
|
|
625
627
|
dev session and auto-pushes later edits. Keep `env push` for `--prod`,
|
|
626
|
-
`--rotate`, or explicit repair against an already active deployment.
|
|
628
|
+
`--rotate`, or explicit repair against an already active deployment. Use
|
|
629
|
+
`auth jwks` when you need a manual static `JWKS` payload, especially on backend
|
|
630
|
+
`concave`.
|
|
627
631
|
|
|
628
632
|
### 11.2 Phase A gate: non-auth baseline (required before auth work)
|
|
629
633
|
|