@tailor-platform/sdk 2.2.0 → 2.4.0
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/CHANGELOG.md +183 -0
- package/README.md +1 -1
- package/dist/{application-BpLeawBg.mjs → application-C8a0UJ-z.mjs} +312 -166
- package/dist/application-C8a0UJ-z.mjs.map +1 -0
- package/dist/application-D4zOiLLa.mjs +3 -0
- package/dist/cli/commands/tailordb/migrate/diff-calculator.d.mts +47 -24
- package/dist/cli/commands/tailordb/migrate/generate.d.mts +6 -0
- package/dist/cli/commands/tailordb/migrate/rename-detection.d.mts +22 -0
- package/dist/cli/commands/tailordb/migrate/snapshot-types.d.mts +1 -1
- package/dist/cli/commands/tailordb/migrate/snapshot.d.mts +30 -11
- package/dist/cli/commands/tailordb/truncate.d.mts +2 -2
- package/dist/cli/lib.mjs +2 -2
- package/dist/cli/lib.mjs.map +1 -1
- package/dist/cli/main.mjs +366 -137
- package/dist/cli/main.mjs.map +1 -1
- package/dist/cli/ts-hook.mjs +55 -8
- package/dist/completion/zsh-worker.zsh +38 -10
- package/dist/configure/config/index.d.mts +1 -1
- package/dist/configure/index.d.mts +3 -2
- package/dist/configure/index.mjs +92 -25
- package/dist/configure/index.mjs.map +1 -1
- package/dist/configure/services/aigateway/index.d.mts +5 -4
- package/dist/configure/services/aigateway/types.d.mts +6 -1
- package/dist/configure/services/auth/types.d.mts +2 -2
- package/dist/configure/services/index.d.mts +2 -2
- package/dist/configure/services/tailordb/permission.d.mts +1 -1
- package/dist/configure/services/tailordb/schema.d.mts +1 -1
- package/dist/configure/services/tailordb/types.d.mts +7 -4
- package/dist/configure/services/workflow/index.d.mts +2 -2
- package/dist/configure/services/workflow/wait-point.d.mts +72 -13
- package/dist/configure/types/auth-namespace-name.d.mts +18 -0
- package/dist/{crashreport-CINZ5dVN.mjs → crashreport-Cd4TqfZq.mjs} +1 -1
- package/dist/{crashreport-CIIfLnoO.mjs → crashreport-Q0pDAlrj.mjs} +8 -4
- package/dist/{crashreport-CIIfLnoO.mjs.map → crashreport-Q0pDAlrj.mjs.map} +1 -1
- package/dist/{errors-CWj21238.mjs → errors-Bxut5_Sy.mjs} +17 -3
- package/dist/{errors-CWj21238.mjs.map → errors-Bxut5_Sy.mjs.map} +1 -1
- package/dist/file-BUcmVIH2.mjs.map +1 -1
- package/dist/kysely/index.d.mts +2 -1
- package/dist/kysely/index.mjs +2 -1
- package/dist/kysely/index.mjs.map +1 -1
- package/dist/{logger-DSdExfor.mjs → logger-D0bEznPv.mjs} +9 -5
- package/dist/{logger-DSdExfor.mjs.map → logger-D0bEznPv.mjs.map} +1 -1
- package/dist/package-json-8b0O9TlX.mjs.map +1 -1
- package/dist/plugin/builtin/enum-constants/index.d.mts +1 -1
- package/dist/plugin/builtin/enum-constants/index.mjs +5 -5
- package/dist/plugin/builtin/enum-constants/index.mjs.map +1 -1
- package/dist/plugin/builtin/file-utils/index.d.mts +1 -1
- package/dist/plugin/builtin/file-utils/index.mjs +14 -11
- package/dist/plugin/builtin/file-utils/index.mjs.map +1 -1
- package/dist/plugin/builtin/kysely-type/index.d.mts +1 -1
- package/dist/plugin/builtin/kysely-type/index.mjs +9 -9
- package/dist/plugin/builtin/kysely-type/index.mjs.map +1 -1
- package/dist/plugin/builtin/seed/index.mjs +1 -1
- package/dist/plugin/builtin/seed/seed-type-processor.d.mts +4 -4
- package/dist/plugin/get-generated-type.d.mts +4 -4
- package/dist/plugin/index.mjs +13 -13
- package/dist/plugin/index.mjs.map +1 -1
- package/dist/plugin/types.d.mts +2 -2
- package/dist/plugin/with-context.d.mts +1 -1
- package/dist/{register-ts-hook-CTth1eqj.mjs → register-ts-hook-Vqjza10T.mjs} +2516 -857
- package/dist/register-ts-hook-Vqjza10T.mjs.map +1 -0
- package/dist/{repl-editor-BCozyiNq.mjs → repl-editor-F9LotMNx.mjs} +3 -2
- package/dist/{repl-editor-BCozyiNq.mjs.map → repl-editor-F9LotMNx.mjs.map} +1 -1
- package/dist/runtime/file.d.mts +14 -14
- package/dist/{schema--xYWRGfe.mjs → schema-D4TC4BC3.mjs} +4 -3
- package/dist/schema-D4TC4BC3.mjs.map +1 -0
- package/dist/seed/index.d.mts +4 -4
- package/dist/seed/index.mjs +3 -3
- package/dist/seed/index.mjs.map +1 -1
- package/dist/{seed-xqM9WIHP.mjs → seed-Cibjmtry.mjs} +46 -40
- package/dist/seed-Cibjmtry.mjs.map +1 -0
- package/dist/{service-goqlJJgA.mjs → service-2grcAOCJ.mjs} +61 -27
- package/dist/service-2grcAOCJ.mjs.map +1 -0
- package/dist/service-CaBPNDIZ.mjs +3 -0
- package/dist/{service-CCwl3Avt.mjs → service-LTfp03ZZ.mjs} +7 -5
- package/dist/{service-CCwl3Avt.mjs.map → service-LTfp03ZZ.mjs.map} +1 -1
- package/dist/types/aigateway.generated.d.mts +2 -2
- package/dist/types/auth.generated.d.mts +3 -3
- package/dist/types/executor.generated.d.mts +1 -1
- package/dist/types/tailordb.generated.d.mts +12 -12
- package/dist/utils/test/index.d.mts +4 -4
- package/dist/utils/test/index.mjs +4 -4
- package/dist/utils/test/index.mjs.map +1 -1
- package/dist/vitest/index.mjs +95 -7
- package/dist/vitest/index.mjs.map +1 -1
- package/dist/vitest/mocks/workflow.d.mts +13 -1
- package/dist/wait-point-invoker-__oE88_P.mjs +148 -0
- package/dist/wait-point-invoker-__oE88_P.mjs.map +1 -0
- package/dist/wait-point-registry-TL99zotw.mjs +47 -0
- package/dist/wait-point-registry-TL99zotw.mjs.map +1 -0
- package/docs/cli/application.md +3 -1
- package/docs/cli/function.md +17 -13
- package/docs/cli/setup.md +14 -1
- package/docs/cli/tailordb.md +30 -27
- package/docs/cli/workspace.md +2 -2
- package/docs/cli-reference.md +23 -22
- package/docs/configuration.md +2 -2
- package/docs/github-actions.md +73 -28
- package/docs/migration/v2.md +58 -4
- package/docs/migration/v3.md +41 -0
- package/docs/quickstart.md +1 -1
- package/docs/services/aigateway.md +33 -9
- package/docs/services/executor.md +5 -1
- package/docs/services/tailordb-migration.md +146 -44
- package/docs/services/tailordb.md +7 -7
- package/docs/services/workflow.md +52 -2
- package/docs/testing.md +13 -1
- package/package.json +8 -8
- package/dist/application-BpLeawBg.mjs.map +0 -1
- package/dist/application-BxLLiLsr.mjs +0 -3
- package/dist/register-ts-hook-CTth1eqj.mjs.map +0 -1
- package/dist/schema--xYWRGfe.mjs.map +0 -1
- package/dist/seed-xqM9WIHP.mjs.map +0 -1
- package/dist/service-_XmjSEGr.mjs +0 -3
- package/dist/service-goqlJJgA.mjs.map +0 -1
- package/dist/test-env-key-D7UkZp99.mjs +0 -75
- package/dist/test-env-key-D7UkZp99.mjs.map +0 -1
|
@@ -4,11 +4,11 @@ import { SnapshotFieldConfig, SnapshotGqlPermission, SnapshotIndexConfig, Snapsh
|
|
|
4
4
|
* Properties shared by all diff change variants
|
|
5
5
|
*/
|
|
6
6
|
interface DiffChangeBase {
|
|
7
|
-
|
|
7
|
+
tableName: string;
|
|
8
8
|
reason?: string;
|
|
9
9
|
}
|
|
10
10
|
/**
|
|
11
|
-
*
|
|
11
|
+
* Table-level settings patch carried by legacy `type_modified` changes.
|
|
12
12
|
* Current SDK versions no longer produce this kind, but persisted
|
|
13
13
|
* diff.json files written by older versions may still contain it.
|
|
14
14
|
*/
|
|
@@ -16,7 +16,7 @@ interface TypeSettingsPatch {
|
|
|
16
16
|
indexes?: Record<string, SnapshotIndexConfig>;
|
|
17
17
|
files?: Record<string, string>;
|
|
18
18
|
}
|
|
19
|
-
/**
|
|
19
|
+
/** Table-level settings and metadata state used by current diffs. */
|
|
20
20
|
interface SnapshotTypeSettingsState {
|
|
21
21
|
description?: string;
|
|
22
22
|
pluralForm: string;
|
|
@@ -29,29 +29,40 @@ interface SnapshotPermissionState {
|
|
|
29
29
|
recordPermission?: SnapshotRecordPermission;
|
|
30
30
|
gqlPermission?: SnapshotGqlPermission;
|
|
31
31
|
}
|
|
32
|
-
/** A new
|
|
33
|
-
interface
|
|
34
|
-
kind: "
|
|
32
|
+
/** A new table was added to the schema. */
|
|
33
|
+
interface TableAddedChange extends DiffChangeBase {
|
|
34
|
+
kind: "table_added";
|
|
35
35
|
after: TailorDBSnapshotType;
|
|
36
36
|
}
|
|
37
|
-
/** An existing
|
|
38
|
-
interface
|
|
39
|
-
kind: "
|
|
37
|
+
/** An existing table was removed from the schema. */
|
|
38
|
+
interface TableRemovedChange extends DiffChangeBase {
|
|
39
|
+
kind: "table_removed";
|
|
40
40
|
before: TailorDBSnapshotType;
|
|
41
41
|
}
|
|
42
42
|
/**
|
|
43
|
-
*
|
|
43
|
+
* A table was renamed. Recorded when the user confirms that a removed + added
|
|
44
|
+
* table pair is a rename (interactively or via `--rename`).
|
|
45
|
+
* `tableName` is the new name; `previousTableName` is the old name.
|
|
46
|
+
*/
|
|
47
|
+
interface TableRenamedChange extends DiffChangeBase {
|
|
48
|
+
kind: "table_renamed";
|
|
49
|
+
previousTableName: string;
|
|
50
|
+
before: TailorDBSnapshotType;
|
|
51
|
+
after: TailorDBSnapshotType;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Legacy table-level settings change. Kept for backward compatibility with
|
|
44
55
|
* diff.json files written by older SDK versions; `before`/`after` may be
|
|
45
56
|
* absent in those files, hence optional.
|
|
46
57
|
*/
|
|
47
|
-
interface
|
|
48
|
-
kind: "
|
|
58
|
+
interface TableModifiedChange extends DiffChangeBase {
|
|
59
|
+
kind: "table_modified";
|
|
49
60
|
before?: TypeSettingsPatch;
|
|
50
61
|
after?: TypeSettingsPatch;
|
|
51
62
|
}
|
|
52
|
-
/**
|
|
53
|
-
interface
|
|
54
|
-
kind: "
|
|
63
|
+
/** Table-level settings or metadata changed. */
|
|
64
|
+
interface TableSettingsModifiedChange extends DiffChangeBase {
|
|
65
|
+
kind: "table_settings_modified";
|
|
55
66
|
before: SnapshotTypeSettingsState;
|
|
56
67
|
after: SnapshotTypeSettingsState;
|
|
57
68
|
}
|
|
@@ -74,6 +85,18 @@ interface FieldModifiedChange extends DiffChangeBase {
|
|
|
74
85
|
before: SnapshotFieldConfig;
|
|
75
86
|
after: SnapshotFieldConfig;
|
|
76
87
|
}
|
|
88
|
+
/**
|
|
89
|
+
* A field was renamed within a type. Recorded when the user confirms that a
|
|
90
|
+
* removed + added field pair is a rename (interactively or via `--rename`).
|
|
91
|
+
* `fieldName` is the new name; `previousFieldName` is the old name.
|
|
92
|
+
*/
|
|
93
|
+
interface FieldRenamedChange extends DiffChangeBase {
|
|
94
|
+
kind: "field_renamed";
|
|
95
|
+
fieldName: string;
|
|
96
|
+
previousFieldName: string;
|
|
97
|
+
before: SnapshotFieldConfig;
|
|
98
|
+
after: SnapshotFieldConfig;
|
|
99
|
+
}
|
|
77
100
|
/** A field type changed and must remain on the previous type until Post-phase. */
|
|
78
101
|
interface FieldTypeModifiedChange extends DiffChangeBase {
|
|
79
102
|
kind: "field_type_modified";
|
|
@@ -146,7 +169,7 @@ interface RelationshipModifiedChange extends DiffChangeBase {
|
|
|
146
169
|
after: SnapshotRelationship;
|
|
147
170
|
}
|
|
148
171
|
/**
|
|
149
|
-
*
|
|
172
|
+
* Table-level permissions were modified. `before`/`after` are optional for
|
|
150
173
|
* robustness against hand-edited or legacy diff.json files; consumers guard
|
|
151
174
|
* on their presence.
|
|
152
175
|
*/
|
|
@@ -155,7 +178,7 @@ interface PermissionModifiedChange extends DiffChangeBase {
|
|
|
155
178
|
before?: SnapshotPermissionState;
|
|
156
179
|
after?: SnapshotPermissionState;
|
|
157
180
|
}
|
|
158
|
-
/**
|
|
181
|
+
/** Table-level hook/validate script state for diff tracking. */
|
|
159
182
|
interface TypeScriptsState {
|
|
160
183
|
typeHookExpr?: {
|
|
161
184
|
create?: string;
|
|
@@ -163,9 +186,9 @@ interface TypeScriptsState {
|
|
|
163
186
|
};
|
|
164
187
|
typeValidateExpr?: string;
|
|
165
188
|
}
|
|
166
|
-
/**
|
|
167
|
-
interface
|
|
168
|
-
kind: "
|
|
189
|
+
/** Table-level hook/validate scripts changed. */
|
|
190
|
+
interface TableScriptsModifiedChange extends DiffChangeBase {
|
|
191
|
+
kind: "table_scripts_modified";
|
|
169
192
|
before: TypeScriptsState;
|
|
170
193
|
after: TypeScriptsState;
|
|
171
194
|
}
|
|
@@ -173,7 +196,7 @@ interface TypeScriptsModifiedChange extends DiffChangeBase {
|
|
|
173
196
|
* Single change in migration diff, discriminated by `kind` so that
|
|
174
197
|
* `before`/`after` are typed per change kind.
|
|
175
198
|
*/
|
|
176
|
-
type DiffChange =
|
|
199
|
+
type DiffChange = TableAddedChange | TableRemovedChange | TableRenamedChange | TableModifiedChange | TableSettingsModifiedChange | FieldAddedChange | FieldRemovedChange | FieldModifiedChange | FieldRenamedChange | FieldTypeModifiedChange | IndexAddedChange | IndexRemovedChange | IndexModifiedChange | FileAddedChange | FileRemovedChange | FileModifiedChange | RelationshipAddedChange | RelationshipRemovedChange | RelationshipModifiedChange | PermissionModifiedChange | TableScriptsModifiedChange;
|
|
177
200
|
/**
|
|
178
201
|
* Migration diff - changes between two schema versions
|
|
179
202
|
* Stored as XXXX/diff.json (e.g., 0001/diff.json)
|
|
@@ -210,7 +233,7 @@ interface ScriptSkippedInfo {
|
|
|
210
233
|
* Breaking change information in migration diff
|
|
211
234
|
*/
|
|
212
235
|
interface BreakingChangeInfo {
|
|
213
|
-
|
|
236
|
+
tableName: string;
|
|
214
237
|
fieldName?: string;
|
|
215
238
|
reason: string;
|
|
216
239
|
/** If true, this change is not supported and migration generation will fail */
|
|
@@ -227,7 +250,7 @@ interface BreakingChangeInfo {
|
|
|
227
250
|
* preserve or transform data before the change applies.
|
|
228
251
|
*/
|
|
229
252
|
interface WarningChangeInfo {
|
|
230
|
-
|
|
253
|
+
tableName: string;
|
|
231
254
|
fieldName?: string;
|
|
232
255
|
reason: string;
|
|
233
256
|
}
|
|
@@ -250,4 +273,4 @@ declare function formatMigrationDiff(diff: MigrationDiff): string;
|
|
|
250
273
|
*/
|
|
251
274
|
declare function formatDiffSummary(diff: MigrationDiff): string;
|
|
252
275
|
//#endregion
|
|
253
|
-
export { BreakingChangeInfo, DiffChange, FieldAddedChange, FieldModifiedChange, FieldRemovedChange, FieldTypeModifiedChange, FileAddedChange, FileModifiedChange, FileRemovedChange, IndexAddedChange, IndexModifiedChange, IndexRemovedChange, MigrationDiff, PermissionModifiedChange, RelationshipAddedChange, RelationshipModifiedChange, RelationshipRemovedChange, ScriptSkippedInfo, SnapshotPermissionState, SnapshotTypeSettingsState,
|
|
276
|
+
export { BreakingChangeInfo, DiffChange, FieldAddedChange, FieldModifiedChange, FieldRemovedChange, FieldRenamedChange, FieldTypeModifiedChange, FileAddedChange, FileModifiedChange, FileRemovedChange, IndexAddedChange, IndexModifiedChange, IndexRemovedChange, MigrationDiff, PermissionModifiedChange, RelationshipAddedChange, RelationshipModifiedChange, RelationshipRemovedChange, ScriptSkippedInfo, SnapshotPermissionState, SnapshotTypeSettingsState, TableAddedChange, TableModifiedChange, TableRemovedChange, TableRenamedChange, TableScriptsModifiedChange, TableSettingsModifiedChange, TypeScriptsState, TypeSettingsPatch, WarningChangeInfo, formatDiffSummary, formatMigrationDiff, hasChanges };
|
|
@@ -5,6 +5,12 @@ interface GenerateOptions {
|
|
|
5
5
|
name?: string;
|
|
6
6
|
yes?: boolean;
|
|
7
7
|
init?: boolean;
|
|
8
|
+
/** `--rename Table.oldField:newField` / `--rename OldTable:NewTable` values confirming renames non-interactively. */
|
|
9
|
+
renames?: string[];
|
|
10
|
+
/** `--drop Table.field` / `--drop Table` values confirming removals non-interactively. */
|
|
11
|
+
drops?: string[];
|
|
12
|
+
/** `--expand-contract Table.field` values approving a field type conversion. */
|
|
13
|
+
expandContracts?: string[];
|
|
8
14
|
}
|
|
9
15
|
/**
|
|
10
16
|
* Generate migration files for TailorDB schema changes
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
//#region src/cli/commands/tailordb/migrate/rename-detection.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* A confirmed field rename to record in the migration diff.
|
|
4
|
+
*/
|
|
5
|
+
interface FieldRenameSpec {
|
|
6
|
+
tableName: string;
|
|
7
|
+
/** Field name before the rename. */
|
|
8
|
+
previousFieldName: string;
|
|
9
|
+
/** Field name after the rename. */
|
|
10
|
+
fieldName: string;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* A confirmed type rename to record in the migration diff.
|
|
14
|
+
*/
|
|
15
|
+
interface TypeRenameSpec {
|
|
16
|
+
/** Type name before the rename. */
|
|
17
|
+
previousTableName: string;
|
|
18
|
+
/** Type name after the rename. */
|
|
19
|
+
tableName: string;
|
|
20
|
+
}
|
|
21
|
+
//#endregion
|
|
22
|
+
export { FieldRenameSpec, TypeRenameSpec };
|
|
@@ -198,7 +198,7 @@ interface SchemaSnapshot {
|
|
|
198
198
|
version: number;
|
|
199
199
|
namespace: string;
|
|
200
200
|
createdAt: string;
|
|
201
|
-
|
|
201
|
+
tables: Record<string, TailorDBSnapshotType>;
|
|
202
202
|
rebaseline?: RebaselineMarker;
|
|
203
203
|
}
|
|
204
204
|
declare const normalizedSchemaSnapshotBrand: unique symbol;
|
|
@@ -2,6 +2,7 @@ import { TailorDBType } from "../../../../parser/service/tailordb/types.mjs";
|
|
|
2
2
|
import "../../../../tailor-proto/src/tailor/v1/tailordb_resource_pb.mjs";
|
|
3
3
|
import { NormalizedSchemaSnapshot, RebaselineMarker, SchemaSnapshot, SnapshotActionPermission, SnapshotEnumValue, SnapshotFieldConfig, SnapshotGqlPermission, SnapshotGqlPermissionPolicy, SnapshotIndexConfig, SnapshotPermissionCondition, SnapshotPermissionOperand, SnapshotRecordPermission, SnapshotRelationship, TailorDBSnapshotType } from "./snapshot-types.mjs";
|
|
4
4
|
import { MigrationDiff } from "./diff-calculator.mjs";
|
|
5
|
+
import { FieldRenameSpec, TypeRenameSpec } from "./rename-detection.mjs";
|
|
5
6
|
//#region src/cli/commands/tailordb/migrate/snapshot.d.ts
|
|
6
7
|
/**
|
|
7
8
|
* Initial schema migration number (0000)
|
|
@@ -39,8 +40,8 @@ declare function getMigrationDirPath(migrationsDir: string, num: number): string
|
|
|
39
40
|
*/
|
|
40
41
|
declare function getMigrationFilePath(migrationsDir: string, num: number, type: MigrationFileType): string;
|
|
41
42
|
/**
|
|
42
|
-
* Create a schema snapshot from local
|
|
43
|
-
* @param {Record<string, TailorDBType>} types - Local
|
|
43
|
+
* Create a schema snapshot from local table definitions
|
|
44
|
+
* @param {Record<string, TailorDBType>} types - Local table definitions
|
|
44
45
|
* @param {string} namespace - Namespace for the snapshot
|
|
45
46
|
* @returns {NormalizedSchemaSnapshot} Normalized schema snapshot
|
|
46
47
|
*/
|
|
@@ -78,23 +79,41 @@ declare function reconstructSnapshotFromMigrations(migrationsDir: string, maxVer
|
|
|
78
79
|
*/
|
|
79
80
|
declare function getLatestMigrationNumber(migrationsDir: string): number;
|
|
80
81
|
/**
|
|
81
|
-
*
|
|
82
|
-
|
|
83
|
-
|
|
82
|
+
* Options for {@link compareSnapshots}.
|
|
83
|
+
*/
|
|
84
|
+
interface CompareSnapshotsOptions {
|
|
85
|
+
/**
|
|
86
|
+
* Confirmed field renames. Each spec replaces the corresponding
|
|
87
|
+
* `field_removed` + `field_added` pair with a single breaking
|
|
88
|
+
* `field_renamed` change. Specs are validated against both snapshots.
|
|
89
|
+
*/
|
|
90
|
+
fieldRenames?: readonly FieldRenameSpec[];
|
|
91
|
+
/**
|
|
92
|
+
* Confirmed table renames. Each spec replaces the corresponding
|
|
93
|
+
* `table_removed` + `table_added` pair with a single breaking
|
|
94
|
+
* `table_renamed` change. Specs are validated against both snapshots.
|
|
95
|
+
*/
|
|
96
|
+
typeRenames?: readonly TypeRenameSpec[];
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Compare two normalized snapshots and generate a diff
|
|
100
|
+
* @param {NormalizedSchemaSnapshot} previous - Previous normalized snapshot
|
|
101
|
+
* @param {NormalizedSchemaSnapshot} current - Current normalized snapshot
|
|
102
|
+
* @param {CompareSnapshotsOptions} [options] - Comparison options
|
|
84
103
|
* @returns {MigrationDiff} Migration diff between snapshots
|
|
85
104
|
*/
|
|
86
|
-
declare function compareSnapshots(previous:
|
|
105
|
+
declare function compareSnapshots(previous: NormalizedSchemaSnapshot, current: NormalizedSchemaSnapshot, options?: CompareSnapshotsOptions): MigrationDiff;
|
|
87
106
|
/**
|
|
88
|
-
* Compare a snapshot against canonical TailorDBSnapshotType-shaped local
|
|
107
|
+
* Compare a snapshot against canonical TailorDBSnapshotType-shaped local tables.
|
|
89
108
|
* Callers are expected to pre-convert TailorDBService.types to TailorDBSnapshotType via
|
|
90
|
-
* `createSnapshotType`. As a safety net,
|
|
91
|
-
* normalization
|
|
109
|
+
* `createSnapshotType`. As a safety net, both sides are re-run through idempotent
|
|
110
|
+
* normalization here, so a caller that forgets will still get correct
|
|
92
111
|
* comparisons (no silent false drift).
|
|
93
112
|
* @param {SchemaSnapshot} snapshot - Schema snapshot to compare against
|
|
94
|
-
* @param {Record<string, TailorDBSnapshotType>} localTypes - Local snapshot-shaped
|
|
113
|
+
* @param {Record<string, TailorDBSnapshotType>} localTypes - Local snapshot-shaped tables
|
|
95
114
|
* @param {string} namespace - Namespace for comparison
|
|
96
115
|
* @returns {MigrationDiff} Migration diff
|
|
97
116
|
*/
|
|
98
117
|
declare function compareLocalTypesWithSnapshot(snapshot: SchemaSnapshot, localTypes: Record<string, TailorDBSnapshotType>, namespace: string): MigrationDiff;
|
|
99
118
|
//#endregion
|
|
100
|
-
export { DB_TYPES_FILE_NAME, DIFF_FILE_NAME, INITIAL_SCHEMA_NUMBER, MIGRATE_FILE_NAME, MIGRATE_TEST_FILE_NAME, MigrationFileType, type NormalizedSchemaSnapshot, SCHEMA_FILE_NAME, type SchemaSnapshot, type SnapshotFieldConfig, type TailorDBSnapshotType, compareLocalTypesWithSnapshot, compareSnapshots, createSnapshotFromLocalTypes, getLatestMigrationNumber, getMigrationDirPath, getMigrationFilePath, getMigrationFiles, getNextMigrationNumber, reconstructSnapshotFromMigrations };
|
|
119
|
+
export { CompareSnapshotsOptions, DB_TYPES_FILE_NAME, DIFF_FILE_NAME, INITIAL_SCHEMA_NUMBER, MIGRATE_FILE_NAME, MIGRATE_TEST_FILE_NAME, MigrationFileType, type NormalizedSchemaSnapshot, SCHEMA_FILE_NAME, type SchemaSnapshot, type SnapshotFieldConfig, type TailorDBSnapshotType, compareLocalTypesWithSnapshot, compareSnapshots, createSnapshotFromLocalTypes, getLatestMigrationNumber, getMigrationDirPath, getMigrationFilePath, getMigrationFiles, getNextMigrationNumber, reconstructSnapshotFromMigrations };
|
|
@@ -6,11 +6,11 @@ interface TruncateOptions {
|
|
|
6
6
|
configPath?: string;
|
|
7
7
|
all?: boolean;
|
|
8
8
|
namespace?: string;
|
|
9
|
-
|
|
9
|
+
tables?: string[];
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Truncate TailorDB data based on the given options.
|
|
13
|
-
* @param options - Truncate options (all, namespace, or
|
|
13
|
+
* @param options - Truncate options (all, namespace, or tables)
|
|
14
14
|
* @returns Promise that resolves when truncation completes
|
|
15
15
|
*/
|
|
16
16
|
declare function truncate(options?: TruncateOptions): Promise<void>;
|
package/dist/cli/lib.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { $
|
|
2
|
-
import {
|
|
1
|
+
import { $t as listWorkspaces, A as truncate, At as triggerExecutor, Bn as getLatestMigrationNumber, D as resumeWorkflow, Dn as INITIAL_SCHEMA_NUMBER, Dt as listWebhookExecutors, En as DIFF_FILE_NAME, Et as getFunctionRegistry, F as chunkSeedData, Hn as getMigrationFilePath, I as bundleSeedScript, In as compareLocalTypesWithSnapshot, It as listExecutorJobs, J as remove, Jn as reconstructSnapshotFromMigrations, Jt as deploy, L as generate$1, Ln as compareSnapshots, Lt as watchExecutorJob, M as loadSeedContext, Mn as SCHEMA_FILE_NAME, Mt as listExecutors, Nt as getExecutorJob, On as MIGRATE_FILE_NAME, Or as loadWorkspaceId, P as loadTailorDBNamespaces, Pt as getExecutorWaitFailureMessage, Q as organizationTree, Rn as createSnapshotFromLocalTypes, S as getAppHealth, Sr as loadAccessToken, St as generate, T as waitWorkflowExecution, Tn as DB_TYPES_FILE_NAME, U as deployStaticWebsite, Un as getMigrationFiles, Ut as getWorkflowExecution, Vn as getMigrationDirPath, Vt as getWorkflow, W as show, Wn as getNextMigrationNumber, Wt as listWorkflowExecutions, Xn as MIGRATION_LABEL_KEY, Z as updateOrganization, _ as getWorkspace, _r as loadConfig, _t as getOAuth2Client, at as updateFolder, b as listApps, cn as executeScript, d as listUsers, dn as bundleMigrationScript, dr as generateUserTypes, dt as deleteFolder, er as formatDiffSummary, gr as assertWritable, h as restoreWorkspace, hr as apiCall, ht as listOAuth2Clients, i as query, k as listWorkflows, kn as MIGRATE_TEST_FILE_NAME, l as removeUser, ln as waitForExecution, lt as getFolder, n as errorToJson, nn as createWorkspace, nr as hasChanges, p as inviteUser, pt as createFolder, qt as getExecutor, r as serializeError, rr as getNamespacesWithMigrations, rt as getOrganization, s as updateUser, st as listFolders, t as registerTsHook, tr as formatMigrationDiff, tt as listOrganizations, vt as getMachineUserToken, wt as listFunctionRegistries, xt as listMachineUsers, y as deleteWorkspace, zt as startWorkflow } from "../register-ts-hook-Vqjza10T.mjs";
|
|
2
|
+
import { Y as initOperatorClient } from "../application-C8a0UJ-z.mjs";
|
|
3
3
|
import { t as isPluginGeneratedType } from "../type-source-DH_LH20p.mjs";
|
|
4
4
|
|
|
5
5
|
//#region src/cli/lib.ts
|
package/dist/cli/lib.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lib.mjs","names":[],"sources":["../../src/cli/lib.ts"],"sourcesContent":["// CLI API exports for programmatic usage\nimport { registerTsHook } from \"./shared/register-ts-hook\";\n\nawait registerTsHook(new URL(\"./ts-hook.mjs\", import.meta.url));\n\nexport { deploy, deploy as apply } from \"./commands/deploy/deploy\";\nexport type { DeployOptions, DeployOptions as ApplyOptions } from \"./commands/deploy/deploy\";\nexport type { BundledScripts } from \"./commands/deploy/function-registry\";\nexport { generate } from \"./commands/generate/service\";\nexport type { GenerateOptions } from \"./commands/generate/options\";\nexport { loadConfig, type LoadedConfig } from \"./shared/config-loader\";\nexport { errorToJson, serializeError, type ErrorToJsonOptions } from \"./shared/error-json\";\nexport { generateUserTypes } from \"./shared/type-generator\";\nexport {\n loadTailorDBNamespaces,\n type TailorDBNamespaceSelector,\n type LoadTailorDBNamespacesOptions,\n type LoadedTailorDBNamespaces,\n} from \"./shared/tailordb-namespaces\";\nexport {\n deployStaticWebsite,\n type DeployResult as StaticWebsiteDeployResult,\n} from \"./commands/staticwebsite/deploy\";\nexport { assertWritable } from \"./shared/readonly-guard\";\nexport { isPluginGeneratedType } from \"#/parser/service/tailordb/type-source\";\nexport type {\n GeneratorResult,\n Plugin,\n PluginAttachment,\n TailorDBNamespaceData,\n} from \"#/plugin/types\";\nexport type {\n TailorDBType,\n TypeSourceInfoEntry,\n ParsedField,\n OperatorFieldConfig,\n PluginGeneratedTypeSource,\n} from \"#/parser/service/tailordb/types\";\nexport type { Resolver } from \"#/types/resolver.generated\";\nexport type { Executor } from \"#/types/executor.generated\";\n\nexport {\n show,\n type ShowOptions,\n type ApplicationInfo,\n type ShowInfo,\n type AIGatewayInfo,\n} from \"./commands/show\";\nexport { remove, type RemoveOptions } from \"./commands/remove\";\nexport { createWorkspace, type CreateWorkspaceOptions } from \"./commands/workspace/create\";\nexport { listWorkspaces, type ListWorkspacesOptions } from \"./commands/workspace/list\";\nexport { deleteWorkspace, type DeleteWorkspaceOptions } from \"./commands/workspace/delete\";\nexport { getWorkspace, type GetWorkspaceOptions } from \"./commands/workspace/get\";\nexport { restoreWorkspace, type RestoreWorkspaceOptions } from \"./commands/workspace/restore\";\nexport type { WorkspaceInfo, WorkspaceDetails } from \"./commands/workspace/transform\";\nexport { listUsers, type ListUsersOptions } from \"./commands/workspace/user/list\";\nexport { inviteUser, type InviteUserOptions } from \"./commands/workspace/user/invite\";\nexport { updateUser, type UpdateUserOptions } from \"./commands/workspace/user/update\";\nexport { removeUser, type RemoveUserOptions } from \"./commands/workspace/user/remove\";\nexport type { UserInfo } from \"./commands/workspace/user/transform\";\nexport { listApps, type ListAppsOptions } from \"./commands/workspace/app/list\";\nexport {\n getAppHealth,\n type HealthOptions as GetAppHealthOptions,\n} from \"./commands/workspace/app/health\";\nexport type { AppInfo, AppHealthInfo } from \"./commands/workspace/app/transform\";\nexport { getFunctionRegistry, type GetFunctionRegistryOptions } from \"./commands/function/get\";\nexport {\n listFunctionRegistries,\n type ListFunctionRegistriesOptions,\n} from \"./commands/function/list\";\nexport type { FunctionRegistryInfo } from \"./commands/function/transform\";\nexport {\n listMachineUsers,\n type ListMachineUsersOptions,\n type MachineUserInfo,\n} from \"./commands/machineuser/list\";\nexport {\n getMachineUserToken,\n type GetMachineUserTokenOptions,\n type MachineUserTokenInfo,\n} from \"./commands/machineuser/token\";\nexport { getOAuth2Client, type GetOAuth2ClientOptions } from \"./commands/oauth2client/get\";\nexport { listOAuth2Clients, type ListOAuth2ClientsOptions } from \"./commands/oauth2client/list\";\nexport type { OAuth2ClientInfo, OAuth2ClientCredentials } from \"./commands/oauth2client/transform\";\nexport { listWorkflows, type ListWorkflowsOptions } from \"./commands/workflow/list\";\nexport { getWorkflow, type GetWorkflowTypedOptions } from \"./commands/workflow/get\";\nexport type { MachineUserName } from \"@tailor-platform/sdk\";\nexport {\n startWorkflow,\n type StartWorkflowTypedOptions,\n type StartWorkflowResultWithWait,\n type WaitOptions,\n} from \"./commands/workflow/start\";\nexport {\n listWorkflowExecutions,\n getWorkflowExecution,\n type ListWorkflowExecutionsTypedOptions,\n type GetWorkflowExecutionOptions,\n type GetWorkflowExecutionResult,\n type WorkflowExecutionWaitInfo,\n} from \"./commands/workflow/executions\";\nexport { waitWorkflowExecution, type WorkflowWaitOutput } from \"./commands/workflow/wait\";\nexport type { WaitWorkflowExecutionOptions, WorkflowWaitResult } from \"./commands/workflow/waiter\";\nexport {\n resumeWorkflow,\n type ResumeWorkflowOptions,\n type ResumeWorkflowResultWithWait,\n} from \"./commands/workflow/resume\";\nexport type {\n WorkflowListInfo,\n WorkflowInfo,\n WorkflowExecutionInfo,\n WorkflowJobExecutionInfo,\n} from \"./commands/workflow/transform\";\nexport {\n triggerExecutor,\n type TriggerExecutorTypedOptions,\n type TriggerExecutorResult,\n} from \"./commands/executor/trigger\";\nexport {\n listExecutorJobs,\n getExecutorJob,\n getExecutorWaitFailureMessage,\n watchExecutorJob,\n type ListExecutorJobsTypedOptions,\n type GetExecutorJobTypedOptions,\n type WatchExecutorJobTypedOptions,\n type ExecutorJobDetailInfo,\n type WatchExecutorJobResult,\n} from \"./commands/executor/jobs\";\nexport { listExecutors, type ListExecutorsOptions } from \"./commands/executor/list\";\nexport { getExecutor, type GetExecutorTypedOptions } from \"./commands/executor/get\";\nexport {\n listWebhookExecutors,\n type ListWebhookExecutorsOptions,\n type WebhookExecutorInfo,\n} from \"./commands/executor/webhook\";\nexport type {\n ExecutorJobListInfo,\n ExecutorJobInfo,\n ExecutorJobAttemptInfo,\n ExecutorListInfo,\n ExecutorInfo,\n} from \"./commands/executor/transform\";\nexport { listOrganizations, type ListOrganizationsOptions } from \"./commands/organization/list\";\nexport { getOrganization, type GetOrganizationOptions } from \"./commands/organization/get\";\nexport { updateOrganization, type UpdateOrganizationOptions } from \"./commands/organization/update\";\nexport { organizationTree, type OrganizationTreeOptions } from \"./commands/organization/tree\";\nexport type {\n UserOrganizationInfo,\n OrganizationInfo,\n FolderListInfo,\n FolderInfo,\n} from \"./commands/organization/transform\";\nexport { listFolders, type ListFoldersOptions } from \"./commands/organization/folder/list\";\nexport { getFolder, type GetFolderOptions } from \"./commands/organization/folder/get\";\nexport { createFolder, type CreateFolderOptions } from \"./commands/organization/folder/create\";\nexport { updateFolder, type UpdateFolderOptions } from \"./commands/organization/folder/update\";\nexport { deleteFolder, type DeleteFolderOptions } from \"./commands/organization/folder/delete\";\nexport { loadAccessToken, loadWorkspaceId } from \"./shared/context\";\nexport { apiCall, type ApiCallOptions, type ApiCallResult } from \"./commands/api\";\nexport { query } from \"./query\";\nexport { truncate, type TruncateOptions } from \"./commands/tailordb/truncate\";\n\n// Migration exports\nexport {\n generate as migrateGenerate,\n type GenerateOptions as MigrateGenerateOptions,\n} from \"./commands/tailordb/migrate/generate\";\nexport {\n createSnapshotFromLocalTypes,\n reconstructSnapshotFromMigrations,\n compareSnapshots,\n getNextMigrationNumber,\n getLatestMigrationNumber,\n getMigrationFiles,\n compareLocalTypesWithSnapshot,\n} from \"./commands/tailordb/migrate/snapshot\";\nexport {\n getNamespacesWithMigrations,\n type NamespaceWithMigrations,\n} from \"./commands/tailordb/migrate/config\";\nexport {\n hasChanges,\n formatMigrationDiff,\n formatDiffSummary,\n type MigrationDiff,\n type BreakingChangeInfo,\n} from \"./commands/tailordb/migrate/diff-calculator\";\nexport {\n SCHEMA_FILE_NAME,\n DIFF_FILE_NAME,\n MIGRATE_FILE_NAME,\n MIGRATE_TEST_FILE_NAME,\n DB_TYPES_FILE_NAME,\n INITIAL_SCHEMA_NUMBER,\n getMigrationDirPath,\n getMigrationFilePath,\n type SchemaSnapshot,\n type NormalizedSchemaSnapshot,\n type TailorDBSnapshotType,\n type SnapshotFieldConfig,\n} from \"./commands/tailordb/migrate/snapshot\";\nexport { MIGRATION_LABEL_KEY } from \"./commands/tailordb/migrate/types\";\n\n// Seed exports\nexport {\n loadSeedContext,\n type LoadSeedContextOptions,\n type SeedContext,\n type SeedIdpUserContext,\n type SeedNamespaceConfig,\n} from \"./shared/seed-context\";\nexport {\n chunkSeedData,\n type SeedChunk,\n type ChunkSeedDataOptions,\n type SeedData,\n} from \"./shared/seed-chunker\";\nexport { bundleSeedScript, type SeedBundleResult } from \"./commands/generate/seed/bundler\";\nexport {\n bundleMigrationScript,\n type MigrationBundleResult,\n} from \"./commands/tailordb/migrate/bundler\";\nexport {\n executeScript,\n waitForExecution,\n type ScriptExecutionOptions,\n type ScriptExecutionResult,\n type ScriptInvoker,\n type ExecutionWaitResult,\n} from \"./shared/script-executor\";\nexport { initOperatorClient, type OperatorClient } from \"./shared/client\";\nexport type { AuthInvoker } from \"@tailor-platform/tailor-proto/auth_resource_pb\";\n"],"mappings":";;;;;AAGA,MAAM,eAAe,IAAI,IAAI,iBAAiB,
|
|
1
|
+
{"version":3,"file":"lib.mjs","names":[],"sources":["../../src/cli/lib.ts"],"sourcesContent":["// CLI API exports for programmatic usage\nimport { registerTsHook } from \"./shared/register-ts-hook\";\n\nawait registerTsHook(new URL(\"./ts-hook.mjs\", import.meta.url));\n\nexport { deploy, deploy as apply } from \"./commands/deploy/deploy\";\nexport type { DeployOptions, DeployOptions as ApplyOptions } from \"./commands/deploy/deploy\";\nexport type { BundledScripts } from \"./commands/deploy/function-registry\";\nexport { generate } from \"./commands/generate/service\";\nexport type { GenerateOptions } from \"./commands/generate/options\";\nexport { loadConfig, type LoadedConfig } from \"./shared/config-loader\";\nexport { errorToJson, serializeError, type ErrorToJsonOptions } from \"./shared/error-json\";\nexport { generateUserTypes } from \"./shared/type-generator\";\nexport {\n loadTailorDBNamespaces,\n type TailorDBNamespaceSelector,\n type LoadTailorDBNamespacesOptions,\n type LoadedTailorDBNamespaces,\n} from \"./shared/tailordb-namespaces\";\nexport {\n deployStaticWebsite,\n type DeployResult as StaticWebsiteDeployResult,\n} from \"./commands/staticwebsite/deploy\";\nexport { assertWritable } from \"./shared/readonly-guard\";\nexport { isPluginGeneratedType } from \"#/parser/service/tailordb/type-source\";\nexport type {\n GeneratorResult,\n Plugin,\n PluginAttachment,\n TailorDBNamespaceData,\n} from \"#/plugin/types\";\nexport type {\n TailorDBType,\n TypeSourceInfoEntry,\n ParsedField,\n OperatorFieldConfig,\n PluginGeneratedTypeSource,\n} from \"#/parser/service/tailordb/types\";\nexport type { Resolver } from \"#/types/resolver.generated\";\nexport type { Executor } from \"#/types/executor.generated\";\n\nexport {\n show,\n type ShowOptions,\n type ApplicationInfo,\n type ShowInfo,\n type AIGatewayInfo,\n} from \"./commands/show\";\nexport { remove, type RemoveOptions } from \"./commands/remove\";\nexport { createWorkspace, type CreateWorkspaceOptions } from \"./commands/workspace/create\";\nexport { listWorkspaces, type ListWorkspacesOptions } from \"./commands/workspace/list\";\nexport { deleteWorkspace, type DeleteWorkspaceOptions } from \"./commands/workspace/delete\";\nexport { getWorkspace, type GetWorkspaceOptions } from \"./commands/workspace/get\";\nexport { restoreWorkspace, type RestoreWorkspaceOptions } from \"./commands/workspace/restore\";\nexport type { WorkspaceInfo, WorkspaceDetails } from \"./commands/workspace/transform\";\nexport { listUsers, type ListUsersOptions } from \"./commands/workspace/user/list\";\nexport { inviteUser, type InviteUserOptions } from \"./commands/workspace/user/invite\";\nexport { updateUser, type UpdateUserOptions } from \"./commands/workspace/user/update\";\nexport { removeUser, type RemoveUserOptions } from \"./commands/workspace/user/remove\";\nexport type { UserInfo } from \"./commands/workspace/user/transform\";\nexport { listApps, type ListAppsOptions } from \"./commands/workspace/app/list\";\nexport {\n getAppHealth,\n type HealthOptions as GetAppHealthOptions,\n} from \"./commands/workspace/app/health\";\nexport type { AppInfo, AppHealthInfo } from \"./commands/workspace/app/transform\";\nexport { getFunctionRegistry, type GetFunctionRegistryOptions } from \"./commands/function/get\";\nexport {\n listFunctionRegistries,\n type ListFunctionRegistriesOptions,\n} from \"./commands/function/list\";\nexport type { FunctionRegistryInfo } from \"./commands/function/transform\";\nexport {\n listMachineUsers,\n type ListMachineUsersOptions,\n type MachineUserInfo,\n} from \"./commands/machineuser/list\";\nexport {\n getMachineUserToken,\n type GetMachineUserTokenOptions,\n type MachineUserTokenInfo,\n} from \"./commands/machineuser/token\";\nexport { getOAuth2Client, type GetOAuth2ClientOptions } from \"./commands/oauth2client/get\";\nexport { listOAuth2Clients, type ListOAuth2ClientsOptions } from \"./commands/oauth2client/list\";\nexport type { OAuth2ClientInfo, OAuth2ClientCredentials } from \"./commands/oauth2client/transform\";\nexport { listWorkflows, type ListWorkflowsOptions } from \"./commands/workflow/list\";\nexport { getWorkflow, type GetWorkflowTypedOptions } from \"./commands/workflow/get\";\nexport type { MachineUserName } from \"@tailor-platform/sdk\";\nexport {\n startWorkflow,\n type StartWorkflowTypedOptions,\n type StartWorkflowResultWithWait,\n type WaitOptions,\n} from \"./commands/workflow/start\";\nexport {\n listWorkflowExecutions,\n getWorkflowExecution,\n type ListWorkflowExecutionsTypedOptions,\n type GetWorkflowExecutionOptions,\n type GetWorkflowExecutionResult,\n type WorkflowExecutionWaitInfo,\n} from \"./commands/workflow/executions\";\nexport { waitWorkflowExecution, type WorkflowWaitOutput } from \"./commands/workflow/wait\";\nexport type { WaitWorkflowExecutionOptions, WorkflowWaitResult } from \"./commands/workflow/waiter\";\nexport {\n resumeWorkflow,\n type ResumeWorkflowOptions,\n type ResumeWorkflowResultWithWait,\n} from \"./commands/workflow/resume\";\nexport type {\n WorkflowListInfo,\n WorkflowInfo,\n WorkflowExecutionInfo,\n WorkflowJobExecutionInfo,\n} from \"./commands/workflow/transform\";\nexport {\n triggerExecutor,\n type TriggerExecutorTypedOptions,\n type TriggerExecutorResult,\n} from \"./commands/executor/trigger\";\nexport {\n listExecutorJobs,\n getExecutorJob,\n getExecutorWaitFailureMessage,\n watchExecutorJob,\n type ListExecutorJobsTypedOptions,\n type GetExecutorJobTypedOptions,\n type WatchExecutorJobTypedOptions,\n type ExecutorJobDetailInfo,\n type WatchExecutorJobResult,\n} from \"./commands/executor/jobs\";\nexport { listExecutors, type ListExecutorsOptions } from \"./commands/executor/list\";\nexport { getExecutor, type GetExecutorTypedOptions } from \"./commands/executor/get\";\nexport {\n listWebhookExecutors,\n type ListWebhookExecutorsOptions,\n type WebhookExecutorInfo,\n} from \"./commands/executor/webhook\";\nexport type {\n ExecutorJobListInfo,\n ExecutorJobInfo,\n ExecutorJobAttemptInfo,\n ExecutorListInfo,\n ExecutorInfo,\n} from \"./commands/executor/transform\";\nexport { listOrganizations, type ListOrganizationsOptions } from \"./commands/organization/list\";\nexport { getOrganization, type GetOrganizationOptions } from \"./commands/organization/get\";\nexport { updateOrganization, type UpdateOrganizationOptions } from \"./commands/organization/update\";\nexport { organizationTree, type OrganizationTreeOptions } from \"./commands/organization/tree\";\nexport type {\n UserOrganizationInfo,\n OrganizationInfo,\n FolderListInfo,\n FolderInfo,\n} from \"./commands/organization/transform\";\nexport { listFolders, type ListFoldersOptions } from \"./commands/organization/folder/list\";\nexport { getFolder, type GetFolderOptions } from \"./commands/organization/folder/get\";\nexport { createFolder, type CreateFolderOptions } from \"./commands/organization/folder/create\";\nexport { updateFolder, type UpdateFolderOptions } from \"./commands/organization/folder/update\";\nexport { deleteFolder, type DeleteFolderOptions } from \"./commands/organization/folder/delete\";\nexport { loadAccessToken, loadWorkspaceId } from \"./shared/context\";\nexport { apiCall, type ApiCallOptions, type ApiCallResult } from \"./commands/api\";\nexport { query } from \"./query\";\nexport { truncate, type TruncateOptions } from \"./commands/tailordb/truncate\";\n\n// Migration exports\nexport {\n generate as migrateGenerate,\n type GenerateOptions as MigrateGenerateOptions,\n} from \"./commands/tailordb/migrate/generate\";\nexport {\n createSnapshotFromLocalTypes,\n reconstructSnapshotFromMigrations,\n compareSnapshots,\n getNextMigrationNumber,\n getLatestMigrationNumber,\n getMigrationFiles,\n compareLocalTypesWithSnapshot,\n} from \"./commands/tailordb/migrate/snapshot\";\nexport {\n getNamespacesWithMigrations,\n type NamespaceWithMigrations,\n} from \"./commands/tailordb/migrate/config\";\nexport {\n hasChanges,\n formatMigrationDiff,\n formatDiffSummary,\n type MigrationDiff,\n type BreakingChangeInfo,\n} from \"./commands/tailordb/migrate/diff-calculator\";\nexport {\n SCHEMA_FILE_NAME,\n DIFF_FILE_NAME,\n MIGRATE_FILE_NAME,\n MIGRATE_TEST_FILE_NAME,\n DB_TYPES_FILE_NAME,\n INITIAL_SCHEMA_NUMBER,\n getMigrationDirPath,\n getMigrationFilePath,\n type SchemaSnapshot,\n type NormalizedSchemaSnapshot,\n type TailorDBSnapshotType,\n type SnapshotFieldConfig,\n} from \"./commands/tailordb/migrate/snapshot\";\nexport { MIGRATION_LABEL_KEY } from \"./commands/tailordb/migrate/types\";\n\n// Seed exports\nexport {\n loadSeedContext,\n type LoadSeedContextOptions,\n type SeedContext,\n type SeedIdpUserContext,\n type SeedNamespaceConfig,\n} from \"./shared/seed-context\";\nexport {\n chunkSeedData,\n type SeedChunk,\n type ChunkSeedDataOptions,\n type SeedData,\n} from \"./shared/seed-chunker\";\nexport { bundleSeedScript, type SeedBundleResult } from \"./commands/generate/seed/bundler\";\nexport {\n bundleMigrationScript,\n type MigrationBundleResult,\n} from \"./commands/tailordb/migrate/bundler\";\nexport {\n executeScript,\n waitForExecution,\n type ScriptExecutionOptions,\n type ScriptExecutionResult,\n type ScriptInvoker,\n type ExecutionWaitResult,\n} from \"./shared/script-executor\";\nexport { initOperatorClient, type OperatorClient } from \"./shared/client\";\nexport type { AuthInvoker } from \"@tailor-platform/tailor-proto/auth_resource_pb\";\n"],"mappings":";;;;;AAGA,MAAM,eAAe,IAAI,IAAI,iBAAiB,YAAY,GAAG,CAAC"}
|