@tailor-platform/sdk 1.6.3 → 1.8.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 +30 -0
- package/dist/{application-4cO5Zvfo.mjs → application-HIu5peO4.mjs} +111 -46
- package/dist/application-HIu5peO4.mjs.map +1 -0
- package/dist/application-ViV4dYwI.mjs +4 -0
- package/dist/cli/index.mjs +65 -53
- package/dist/cli/index.mjs.map +1 -1
- package/dist/cli/lib.d.mts +134 -25
- package/dist/cli/lib.mjs +3 -4
- package/dist/cli/lib.mjs.map +1 -1
- package/dist/configure/index.d.mts +3 -3
- package/dist/configure/index.mjs +778 -2
- package/dist/configure/index.mjs.map +1 -1
- package/dist/{index-DRFnAgt_.d.mts → index-BwJ7-efr.d.mts} +74 -30
- package/dist/{index-BqMqXRal.d.mts → index-Dkm2qwmF.d.mts} +153 -191
- package/dist/{jiti-SMSW3TA0.mjs → jiti-ygK9KoRA.mjs} +1 -1
- package/dist/{jiti-SMSW3TA0.mjs.map → jiti-ygK9KoRA.mjs.map} +1 -1
- package/dist/{job-8XfvLyxH.mjs → job-l-pIR9IY.mjs} +1 -1
- package/dist/{job-8XfvLyxH.mjs.map → job-l-pIR9IY.mjs.map} +1 -1
- package/dist/{list-DFvkudMF.mjs → list-D1K7WwpV.mjs} +3084 -2362
- package/dist/list-D1K7WwpV.mjs.map +1 -0
- package/dist/{src-qLXX6nub.mjs → src-CG8kJBI9.mjs} +1 -1
- package/dist/{src-qLXX6nub.mjs.map → src-CG8kJBI9.mjs.map} +1 -1
- package/dist/utils/test/index.d.mts +2 -2
- package/dist/utils/test/index.mjs +1 -1
- package/docs/cli/application.md +114 -35
- package/docs/cli/auth.md +101 -44
- package/docs/cli/executor.md +149 -0
- package/docs/cli/secret.md +133 -51
- package/docs/cli/staticwebsite.md +78 -41
- package/docs/cli/tailordb.md +227 -155
- package/docs/cli/user.md +164 -66
- package/docs/cli/workflow.md +132 -73
- package/docs/cli/workspace.md +126 -45
- package/docs/cli-reference.md +9 -0
- package/docs/generator/custom.md +2 -2
- package/docs/services/auth.md +88 -1
- package/package.json +3 -1
- package/dist/application-3rIUD7cq.mjs +0 -5
- package/dist/application-4cO5Zvfo.mjs.map +0 -1
- package/dist/auth-0Zh4xp4z.mjs +0 -772
- package/dist/auth-0Zh4xp4z.mjs.map +0 -1
- package/dist/list-DFvkudMF.mjs.map +0 -1
package/dist/cli/lib.d.mts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/// <reference path="./../user-defined.d.ts" />
|
|
2
|
-
import {
|
|
2
|
+
import { E as TailorDBType, F as IdProviderConfig, L as OAuth2ClientInput, gt as Resolver, p as Executor, r as AppConfig, t as Generator } from "../index-Dkm2qwmF.mjs";
|
|
3
3
|
import "politty";
|
|
4
4
|
import { z } from "zod";
|
|
5
5
|
import { OAuth2Client } from "@badgateway/oauth2-client";
|
|
6
6
|
import "@bufbuild/protobuf/wkt";
|
|
7
7
|
import "@connectrpc/connect";
|
|
8
8
|
import "@bufbuild/protobuf/codegenv2";
|
|
9
|
-
import "@bufbuild/protobuf";
|
|
9
|
+
import { JsonObject } from "@bufbuild/protobuf";
|
|
10
10
|
import { Jsonifiable } from "type-fest";
|
|
11
11
|
|
|
12
12
|
//#region src/cli/config-loader.d.ts
|
|
@@ -86,7 +86,7 @@ type ArrayIncludes<T extends readonly unknown[], U> = T extends readonly [infer
|
|
|
86
86
|
type HasDependency<Deps extends readonly DependencyKind[], D extends DependencyKind> = ArrayIncludes<Deps, D>;
|
|
87
87
|
interface TailorDBProcessMethods<T, Ts> {
|
|
88
88
|
processType(args: {
|
|
89
|
-
type:
|
|
89
|
+
type: TailorDBType;
|
|
90
90
|
namespace: string;
|
|
91
91
|
source: {
|
|
92
92
|
filePath: string;
|
|
@@ -194,6 +194,11 @@ interface ShowOptions {
|
|
|
194
194
|
profile?: string;
|
|
195
195
|
configPath?: string;
|
|
196
196
|
}
|
|
197
|
+
interface WorkspaceInfo$1 {
|
|
198
|
+
workspaceId: string;
|
|
199
|
+
workspaceName: string;
|
|
200
|
+
workspaceRegion?: string;
|
|
201
|
+
}
|
|
197
202
|
interface ApplicationInfo {
|
|
198
203
|
name: string;
|
|
199
204
|
domain: string;
|
|
@@ -202,15 +207,16 @@ interface ApplicationInfo {
|
|
|
202
207
|
cors: string[];
|
|
203
208
|
allowedIpAddresses: string[];
|
|
204
209
|
disableIntrospection: boolean;
|
|
205
|
-
createdAt:
|
|
206
|
-
updatedAt:
|
|
210
|
+
createdAt: Date | null;
|
|
211
|
+
updatedAt: Date | null;
|
|
207
212
|
}
|
|
213
|
+
interface ShowInfo extends ApplicationInfo, WorkspaceInfo$1 {}
|
|
208
214
|
/**
|
|
209
215
|
* Show applied application information for the current workspace.
|
|
210
216
|
* @param options - Show options
|
|
211
217
|
* @returns Application information
|
|
212
218
|
*/
|
|
213
|
-
declare function show(options?: ShowOptions): Promise<
|
|
219
|
+
declare function show(options?: ShowOptions): Promise<ShowInfo>;
|
|
214
220
|
//#endregion
|
|
215
221
|
//#region src/cli/remove.d.ts
|
|
216
222
|
interface RemoveOptions {
|
|
@@ -230,8 +236,8 @@ interface WorkspaceInfo {
|
|
|
230
236
|
id: string;
|
|
231
237
|
name: string;
|
|
232
238
|
region: string;
|
|
233
|
-
createdAt:
|
|
234
|
-
updatedAt:
|
|
239
|
+
createdAt: Date | null;
|
|
240
|
+
updatedAt: Date | null;
|
|
235
241
|
}
|
|
236
242
|
//#endregion
|
|
237
243
|
//#region src/cli/workspace/create.d.ts
|
|
@@ -288,8 +294,9 @@ interface MachineUserInfo {
|
|
|
288
294
|
name: string;
|
|
289
295
|
clientId: string;
|
|
290
296
|
clientSecret: string;
|
|
291
|
-
createdAt:
|
|
292
|
-
updatedAt:
|
|
297
|
+
createdAt: Date | null;
|
|
298
|
+
updatedAt: Date | null;
|
|
299
|
+
attributes: Record<string, unknown>;
|
|
293
300
|
}
|
|
294
301
|
/**
|
|
295
302
|
* List machine users for the current application.
|
|
@@ -324,7 +331,7 @@ interface OAuth2ClientInfo {
|
|
|
324
331
|
clientId: string;
|
|
325
332
|
grantTypes: string[];
|
|
326
333
|
redirectUris: string[];
|
|
327
|
-
createdAt:
|
|
334
|
+
createdAt: Date | null;
|
|
328
335
|
}
|
|
329
336
|
interface OAuth2ClientCredentials {
|
|
330
337
|
name: string;
|
|
@@ -333,7 +340,7 @@ interface OAuth2ClientCredentials {
|
|
|
333
340
|
clientSecret: string;
|
|
334
341
|
grantTypes: string[];
|
|
335
342
|
redirectUris: string[];
|
|
336
|
-
createdAt:
|
|
343
|
+
createdAt: Date | null;
|
|
337
344
|
}
|
|
338
345
|
//#endregion
|
|
339
346
|
//#region src/cli/oauth2client/get.d.ts
|
|
@@ -368,31 +375,31 @@ interface WorkflowListInfo {
|
|
|
368
375
|
name: string;
|
|
369
376
|
mainJob: string;
|
|
370
377
|
jobFunctions: number;
|
|
371
|
-
updatedAt:
|
|
378
|
+
updatedAt: Date | null;
|
|
372
379
|
}
|
|
373
380
|
interface WorkflowInfo {
|
|
374
381
|
name: string;
|
|
375
382
|
id: string;
|
|
376
383
|
mainJob: string;
|
|
377
|
-
jobFunctions: string
|
|
378
|
-
createdAt:
|
|
379
|
-
updatedAt:
|
|
384
|
+
jobFunctions: Record<string, string>;
|
|
385
|
+
createdAt: Date | null;
|
|
386
|
+
updatedAt: Date | null;
|
|
380
387
|
}
|
|
381
388
|
interface WorkflowJobExecutionInfo {
|
|
382
389
|
id: string;
|
|
383
390
|
stackedJobName: string;
|
|
384
391
|
status: string;
|
|
385
392
|
executionId: string;
|
|
386
|
-
startedAt:
|
|
387
|
-
finishedAt:
|
|
393
|
+
startedAt: Date | null;
|
|
394
|
+
finishedAt: Date | null;
|
|
388
395
|
}
|
|
389
396
|
interface WorkflowExecutionInfo {
|
|
390
397
|
id: string;
|
|
391
398
|
workflowName: string;
|
|
392
399
|
status: string;
|
|
393
400
|
jobExecutions: number;
|
|
394
|
-
startedAt:
|
|
395
|
-
finishedAt:
|
|
401
|
+
startedAt: Date | null;
|
|
402
|
+
finishedAt: Date | null;
|
|
396
403
|
}
|
|
397
404
|
//#endregion
|
|
398
405
|
//#region src/cli/workflow/list.d.ts
|
|
@@ -499,6 +506,108 @@ interface ResumeWorkflowResultWithWait {
|
|
|
499
506
|
*/
|
|
500
507
|
declare function resumeWorkflow(options: ResumeWorkflowOptions): Promise<ResumeWorkflowResultWithWait>;
|
|
501
508
|
//#endregion
|
|
509
|
+
//#region src/cli/executor/trigger.d.ts
|
|
510
|
+
interface TriggerExecutorOptions {
|
|
511
|
+
executorName: string;
|
|
512
|
+
payload?: JsonObject;
|
|
513
|
+
workspaceId?: string;
|
|
514
|
+
profile?: string;
|
|
515
|
+
}
|
|
516
|
+
interface TriggerExecutorResult {
|
|
517
|
+
jobId?: string;
|
|
518
|
+
}
|
|
519
|
+
/**
|
|
520
|
+
* Trigger an executor and return the job ID.
|
|
521
|
+
* @param options - Options for triggering executor
|
|
522
|
+
* @returns Result containing the job ID if available
|
|
523
|
+
*/
|
|
524
|
+
declare function triggerExecutor(options: TriggerExecutorOptions): Promise<TriggerExecutorResult>;
|
|
525
|
+
//#endregion
|
|
526
|
+
//#region src/cli/executor/transform.d.ts
|
|
527
|
+
interface ExecutorJobListInfo {
|
|
528
|
+
id: string;
|
|
529
|
+
executorName: string;
|
|
530
|
+
status: string;
|
|
531
|
+
createdAt: string;
|
|
532
|
+
}
|
|
533
|
+
interface ExecutorJobInfo {
|
|
534
|
+
id: string;
|
|
535
|
+
executorName: string;
|
|
536
|
+
status: string;
|
|
537
|
+
scheduledAt: string;
|
|
538
|
+
createdAt: string;
|
|
539
|
+
updatedAt: string;
|
|
540
|
+
}
|
|
541
|
+
interface ExecutorJobAttemptInfo {
|
|
542
|
+
id: string;
|
|
543
|
+
jobId: string;
|
|
544
|
+
status: string;
|
|
545
|
+
error: string;
|
|
546
|
+
startedAt: string;
|
|
547
|
+
finishedAt: string;
|
|
548
|
+
operationReference: string;
|
|
549
|
+
}
|
|
550
|
+
//#endregion
|
|
551
|
+
//#region src/cli/executor/jobs.d.ts
|
|
552
|
+
interface ListExecutorJobsOptions {
|
|
553
|
+
executorName: string;
|
|
554
|
+
status?: string;
|
|
555
|
+
limit?: number;
|
|
556
|
+
workspaceId?: string;
|
|
557
|
+
profile?: string;
|
|
558
|
+
}
|
|
559
|
+
interface GetExecutorJobOptions {
|
|
560
|
+
executorName: string;
|
|
561
|
+
jobId: string;
|
|
562
|
+
attempts?: boolean;
|
|
563
|
+
workspaceId?: string;
|
|
564
|
+
profile?: string;
|
|
565
|
+
}
|
|
566
|
+
interface WatchExecutorJobOptions {
|
|
567
|
+
executorName: string;
|
|
568
|
+
jobId: string;
|
|
569
|
+
workspaceId?: string;
|
|
570
|
+
profile?: string;
|
|
571
|
+
interval?: number;
|
|
572
|
+
logs?: boolean;
|
|
573
|
+
}
|
|
574
|
+
interface ExecutorJobDetailInfo extends ExecutorJobInfo {
|
|
575
|
+
attempts?: ExecutorJobAttemptInfo[];
|
|
576
|
+
}
|
|
577
|
+
interface WorkflowJobLog {
|
|
578
|
+
jobName: string;
|
|
579
|
+
logs?: string;
|
|
580
|
+
result?: string;
|
|
581
|
+
}
|
|
582
|
+
interface WatchExecutorJobResult {
|
|
583
|
+
job: ExecutorJobDetailInfo;
|
|
584
|
+
targetType: string;
|
|
585
|
+
workflowExecutionId?: string;
|
|
586
|
+
workflowStatus?: string;
|
|
587
|
+
workflowJobLogs?: WorkflowJobLog[];
|
|
588
|
+
functionExecutionId?: string;
|
|
589
|
+
functionStatus?: string;
|
|
590
|
+
functionLogs?: string;
|
|
591
|
+
}
|
|
592
|
+
/**
|
|
593
|
+
* List executor jobs for a given executor.
|
|
594
|
+
* @param options - Options for listing executor jobs
|
|
595
|
+
* @returns List of executor job information
|
|
596
|
+
*/
|
|
597
|
+
declare function listExecutorJobs(options: ListExecutorJobsOptions): Promise<ExecutorJobListInfo[]>;
|
|
598
|
+
/**
|
|
599
|
+
* Get details of a specific executor job.
|
|
600
|
+
* @param options - Options for getting executor job details
|
|
601
|
+
* @returns Executor job detail information
|
|
602
|
+
*/
|
|
603
|
+
declare function getExecutorJob(options: GetExecutorJobOptions): Promise<ExecutorJobDetailInfo>;
|
|
604
|
+
/**
|
|
605
|
+
* Watch an executor job until completion, including downstream executions.
|
|
606
|
+
* @param options - Options for watching executor job
|
|
607
|
+
* @returns Result including job details and downstream execution info
|
|
608
|
+
*/
|
|
609
|
+
declare function watchExecutorJob(options: WatchExecutorJobOptions): Promise<WatchExecutorJobResult>;
|
|
610
|
+
//#endregion
|
|
502
611
|
//#region src/cli/context.d.ts
|
|
503
612
|
type LoadWorkspaceIdOptions = {
|
|
504
613
|
workspaceId?: string;
|
|
@@ -752,11 +861,11 @@ declare function getMigrationDirPath(migrationsDir: string, num: number): string
|
|
|
752
861
|
declare function getMigrationFilePath(migrationsDir: string, num: number, type: MigrationFileType): string;
|
|
753
862
|
/**
|
|
754
863
|
* Create a schema snapshot from local type definitions
|
|
755
|
-
* @param {Record<string,
|
|
864
|
+
* @param {Record<string, TailorDBType>} types - Local type definitions
|
|
756
865
|
* @param {string} namespace - Namespace for the snapshot
|
|
757
866
|
* @returns {SchemaSnapshot} Schema snapshot
|
|
758
867
|
*/
|
|
759
|
-
declare function createSnapshotFromLocalTypes(types: Record<string,
|
|
868
|
+
declare function createSnapshotFromLocalTypes(types: Record<string, TailorDBType>, namespace: string): SchemaSnapshot;
|
|
760
869
|
/**
|
|
761
870
|
* Get all migration directories and their files, sorted by number
|
|
762
871
|
* @param {string} migrationsDir - Migrations directory path
|
|
@@ -799,11 +908,11 @@ declare function compareSnapshots(previous: SchemaSnapshot, current: SchemaSnaps
|
|
|
799
908
|
/**
|
|
800
909
|
* Compare local types with a snapshot and generate a diff
|
|
801
910
|
* @param {SchemaSnapshot} snapshot - Schema snapshot to compare against
|
|
802
|
-
* @param {Record<string,
|
|
911
|
+
* @param {Record<string, TailorDBType>} localTypes - Local type definitions
|
|
803
912
|
* @param {string} namespace - Namespace for comparison
|
|
804
913
|
* @returns {MigrationDiff} Migration diff
|
|
805
914
|
*/
|
|
806
|
-
declare function compareLocalTypesWithSnapshot(snapshot: SchemaSnapshot, localTypes: Record<string,
|
|
915
|
+
declare function compareLocalTypesWithSnapshot(snapshot: SchemaSnapshot, localTypes: Record<string, TailorDBType>, namespace: string): MigrationDiff;
|
|
807
916
|
//#endregion
|
|
808
917
|
//#region src/cli/tailordb/migrate/config.d.ts
|
|
809
918
|
/**
|
|
@@ -821,5 +930,5 @@ interface NamespaceWithMigrations {
|
|
|
821
930
|
*/
|
|
822
931
|
declare function getNamespacesWithMigrations(config: AppConfig, configDir: string): NamespaceWithMigrations[];
|
|
823
932
|
//#endregion
|
|
824
|
-
export { type AggregateArgs, type ApiCallOptions, type ApiCallResult, type ApplicationInfo, type ApplyOptions, type BreakingChangeInfo, type CodeGenerator, type CreateWorkspaceOptions, DB_TYPES_FILE_NAME, DIFF_FILE_NAME, type DeleteWorkspaceOptions, type DependencyKind, type Executor, type ExecutorGenerator, type ExecutorInput, type FullCodeGenerator, type FullInput, type GenerateOptions, type GeneratorResult, type GetMachineUserTokenOptions, type GetOAuth2ClientOptions, type GetWorkflowExecutionOptions, type GetWorkflowExecutionResult, type GetWorkflowOptions, INITIAL_SCHEMA_NUMBER, type ListMachineUsersOptions, type ListOAuth2ClientsOptions, type ListWorkflowExecutionsOptions, type ListWorkflowsOptions, type ListWorkspacesOptions, type LoadedConfig, MIGRATE_FILE_NAME, MIGRATION_LABEL_KEY, type MachineUserInfo, type MachineUserTokenInfo, type GenerateOptions$1 as MigrateGenerateOptions, type MigrationDiff, type MigrationInfo, type NamespaceWithMigrations, type OAuth2ClientCredentials, type OAuth2ClientInfo, type RemoveOptions, type Resolver, type ResolverGenerator, type ResolverInput, type ResumeWorkflowOptions, type ResumeWorkflowResultWithWait, SCHEMA_FILE_NAME, type SchemaSnapshot, type ShowOptions, type SnapshotFieldConfig, type SnapshotType, type StartWorkflowOptions, type StartWorkflowResultWithWait, type TailorDBGenerator, type TailorDBInput, type TailorDBResolverGenerator, type
|
|
933
|
+
export { type AggregateArgs, type ApiCallOptions, type ApiCallResult, type ApplicationInfo, type ApplyOptions, type BreakingChangeInfo, type CodeGenerator, type CreateWorkspaceOptions, DB_TYPES_FILE_NAME, DIFF_FILE_NAME, type DeleteWorkspaceOptions, type DependencyKind, type Executor, type ExecutorGenerator, type ExecutorInput, type ExecutorJobAttemptInfo, type ExecutorJobDetailInfo, type ExecutorJobInfo, type ExecutorJobListInfo, type FullCodeGenerator, type FullInput, type GenerateOptions, type GeneratorResult, type GetExecutorJobOptions, type GetMachineUserTokenOptions, type GetOAuth2ClientOptions, type GetWorkflowExecutionOptions, type GetWorkflowExecutionResult, type GetWorkflowOptions, INITIAL_SCHEMA_NUMBER, type ListExecutorJobsOptions, type ListMachineUsersOptions, type ListOAuth2ClientsOptions, type ListWorkflowExecutionsOptions, type ListWorkflowsOptions, type ListWorkspacesOptions, type LoadedConfig, MIGRATE_FILE_NAME, MIGRATION_LABEL_KEY, type MachineUserInfo, type MachineUserTokenInfo, type GenerateOptions$1 as MigrateGenerateOptions, type MigrationDiff, type MigrationInfo, type NamespaceWithMigrations, type OAuth2ClientCredentials, type OAuth2ClientInfo, type RemoveOptions, type Resolver, type ResolverGenerator, type ResolverInput, type ResumeWorkflowOptions, type ResumeWorkflowResultWithWait, SCHEMA_FILE_NAME, type SchemaSnapshot, type ShowOptions, type SnapshotFieldConfig, type SnapshotType, type StartWorkflowOptions, type StartWorkflowResultWithWait, type TailorDBGenerator, type TailorDBInput, type TailorDBResolverGenerator, type TailorDBType, type TriggerExecutorOptions, type TriggerExecutorResult, type TruncateOptions, type WaitOptions, type WatchExecutorJobOptions, type WatchExecutorJobResult, type WorkflowExecutionInfo, type WorkflowInfo, type WorkflowJobExecutionInfo, type WorkflowListInfo, type WorkspaceInfo, apiCall, apply, compareLocalTypesWithSnapshot, compareSnapshots, createSnapshotFromLocalTypes, createWorkspace, deleteWorkspace, formatDiffSummary, formatMigrationDiff, generate, generateUserTypes, getExecutorJob, getLatestMigrationNumber, getMachineUserToken, getMigrationDirPath, getMigrationFilePath, getMigrationFiles, getNamespacesWithMigrations, getNextMigrationNumber, getOAuth2Client, getWorkflow, getWorkflowExecution, hasChanges, listExecutorJobs, listMachineUsers, listOAuth2Clients, listWorkflowExecutions, listWorkflows, listWorkspaces, loadAccessToken, loadConfig, loadWorkspaceId, generate$1 as migrateGenerate, reconstructSnapshotFromMigrations, remove, resumeWorkflow, show, startWorkflow, triggerExecutor, truncate, watchExecutorJob };
|
|
825
934
|
//# sourceMappingURL=lib.d.mts.map
|
package/dist/cli/lib.mjs
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import "../chunk-CIV_ash9.mjs";
|
|
2
|
-
import "../
|
|
3
|
-
import
|
|
4
|
-
import "../application-4cO5Zvfo.mjs";
|
|
2
|
+
import { $ as compareSnapshots, C as getOAuth2Client, D as listMachineUsers, F as watchExecutorJob, G as MIGRATION_LABEL_KEY, H as listWorkflowExecutions, J as DIFF_FILE_NAME, L as startWorkflow, M as getExecutorJob, O as generate, P as listExecutorJobs, Q as compareLocalTypesWithSnapshot, U as apply, V as getWorkflowExecution, X as MIGRATE_FILE_NAME, Y as INITIAL_SCHEMA_NUMBER, Z as SCHEMA_FILE_NAME, _t as apiCall, at as getMigrationFiles, bt as loadAccessToken, c as resumeWorkflow, d as truncate, dt as formatMigrationDiff, et as createSnapshotFromLocalTypes, ft as hasChanges, g as show, gt as loadConfig, ht as generateUserTypes, i as deleteWorkspace, it as getMigrationFilePath, j as triggerExecutor, lt as reconstructSnapshotFromMigrations, n as listWorkspaces, nt as getLatestMigrationNumber, o as createWorkspace, ot as getNextMigrationNumber, p as generate$1, pt as getNamespacesWithMigrations, q as DB_TYPES_FILE_NAME, rt as getMigrationDirPath, u as listWorkflows, ut as formatDiffSummary, v as remove, w as getMachineUserToken, x as listOAuth2Clients, xt as loadWorkspaceId, z as getWorkflow } from "../list-D1K7WwpV.mjs";
|
|
3
|
+
import "../application-HIu5peO4.mjs";
|
|
5
4
|
import { register } from "node:module";
|
|
6
5
|
|
|
7
6
|
//#region src/cli/lib.ts
|
|
8
7
|
register("tsx", import.meta.url, { data: {} });
|
|
9
8
|
|
|
10
9
|
//#endregion
|
|
11
|
-
export { DB_TYPES_FILE_NAME, DIFF_FILE_NAME, INITIAL_SCHEMA_NUMBER, MIGRATE_FILE_NAME, MIGRATION_LABEL_KEY, SCHEMA_FILE_NAME, apiCall, apply, compareLocalTypesWithSnapshot, compareSnapshots, createSnapshotFromLocalTypes, createWorkspace, deleteWorkspace, formatDiffSummary, formatMigrationDiff, generate, generateUserTypes, getLatestMigrationNumber, getMachineUserToken, getMigrationDirPath, getMigrationFilePath, getMigrationFiles, getNamespacesWithMigrations, getNextMigrationNumber, getOAuth2Client, getWorkflow, getWorkflowExecution, hasChanges, listMachineUsers, listOAuth2Clients, listWorkflowExecutions, listWorkflows, listWorkspaces, loadAccessToken, loadConfig, loadWorkspaceId, generate$1 as migrateGenerate, reconstructSnapshotFromMigrations, remove, resumeWorkflow, show, startWorkflow, truncate };
|
|
10
|
+
export { DB_TYPES_FILE_NAME, DIFF_FILE_NAME, INITIAL_SCHEMA_NUMBER, MIGRATE_FILE_NAME, MIGRATION_LABEL_KEY, SCHEMA_FILE_NAME, apiCall, apply, compareLocalTypesWithSnapshot, compareSnapshots, createSnapshotFromLocalTypes, createWorkspace, deleteWorkspace, formatDiffSummary, formatMigrationDiff, generate, generateUserTypes, getExecutorJob, getLatestMigrationNumber, getMachineUserToken, getMigrationDirPath, getMigrationFilePath, getMigrationFiles, getNamespacesWithMigrations, getNextMigrationNumber, getOAuth2Client, getWorkflow, getWorkflowExecution, hasChanges, listExecutorJobs, listMachineUsers, listOAuth2Clients, listWorkflowExecutions, listWorkflows, listWorkspaces, loadAccessToken, loadConfig, loadWorkspaceId, generate$1 as migrateGenerate, reconstructSnapshotFromMigrations, remove, resumeWorkflow, show, startWorkflow, triggerExecutor, truncate, watchExecutorJob };
|
|
12
11
|
//# sourceMappingURL=lib.mjs.map
|
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 { register } from \"node:module\";\n\n// Register tsx to handle TypeScript files when using CLI API programmatically\nregister(\"tsx\", import.meta.url, { data: {} });\n\nexport { apply } from \"./apply/index\";\nexport type { ApplyOptions } from \"./apply/index\";\nexport { generate } from \"./generator/index\";\nexport type { GenerateOptions } from \"./generator/options\";\nexport { loadConfig, type LoadedConfig } from \"./config-loader\";\nexport { generateUserTypes } from \"./type-generator\";\nexport type {\n CodeGenerator,\n TailorDBGenerator,\n ResolverGenerator,\n ExecutorGenerator,\n TailorDBResolverGenerator,\n FullCodeGenerator,\n TailorDBInput,\n ResolverInput,\n ExecutorInput,\n FullInput,\n AggregateArgs,\n GeneratorResult,\n DependencyKind,\n} from \"./generator/types\";\nexport type {
|
|
1
|
+
{"version":3,"file":"lib.mjs","names":[],"sources":["../../src/cli/lib.ts"],"sourcesContent":["// CLI API exports for programmatic usage\nimport { register } from \"node:module\";\n\n// Register tsx to handle TypeScript files when using CLI API programmatically\nregister(\"tsx\", import.meta.url, { data: {} });\n\nexport { apply } from \"./apply/index\";\nexport type { ApplyOptions } from \"./apply/index\";\nexport { generate } from \"./generator/index\";\nexport type { GenerateOptions } from \"./generator/options\";\nexport { loadConfig, type LoadedConfig } from \"./config-loader\";\nexport { generateUserTypes } from \"./type-generator\";\nexport type {\n CodeGenerator,\n TailorDBGenerator,\n ResolverGenerator,\n ExecutorGenerator,\n TailorDBResolverGenerator,\n FullCodeGenerator,\n TailorDBInput,\n ResolverInput,\n ExecutorInput,\n FullInput,\n AggregateArgs,\n GeneratorResult,\n DependencyKind,\n} from \"./generator/types\";\nexport type { TailorDBType } from \"@/parser/service/tailordb/types\";\nexport type { Resolver } from \"@/parser/service/resolver\";\nexport type { Executor } from \"@/parser/service/executor\";\n\nexport { show, type ShowOptions, type ApplicationInfo } from \"./show\";\nexport { remove, type RemoveOptions } from \"./remove\";\nexport { createWorkspace, type CreateWorkspaceOptions } from \"./workspace/create\";\nexport { listWorkspaces, type ListWorkspacesOptions } from \"./workspace/list\";\nexport { deleteWorkspace, type DeleteWorkspaceOptions } from \"./workspace/delete\";\nexport type { WorkspaceInfo } from \"./workspace/transform\";\nexport {\n listMachineUsers,\n type ListMachineUsersOptions,\n type MachineUserInfo,\n} from \"./machineuser/list\";\nexport {\n getMachineUserToken,\n type GetMachineUserTokenOptions,\n type MachineUserTokenInfo,\n} from \"./machineuser/token\";\nexport { getOAuth2Client, type GetOAuth2ClientOptions } from \"./oauth2client/get\";\nexport { listOAuth2Clients, type ListOAuth2ClientsOptions } from \"./oauth2client/list\";\nexport type { OAuth2ClientInfo, OAuth2ClientCredentials } from \"./oauth2client/transform\";\nexport { listWorkflows, type ListWorkflowsOptions } from \"./workflow/list\";\nexport { getWorkflow, type GetWorkflowOptions } from \"./workflow/get\";\nexport {\n startWorkflow,\n type StartWorkflowOptions,\n type StartWorkflowResultWithWait,\n type WaitOptions,\n} from \"./workflow/start\";\nexport {\n listWorkflowExecutions,\n getWorkflowExecution,\n type ListWorkflowExecutionsOptions,\n type GetWorkflowExecutionOptions,\n type GetWorkflowExecutionResult,\n} from \"./workflow/executions\";\nexport {\n resumeWorkflow,\n type ResumeWorkflowOptions,\n type ResumeWorkflowResultWithWait,\n} from \"./workflow/resume\";\nexport type {\n WorkflowListInfo,\n WorkflowInfo,\n WorkflowExecutionInfo,\n WorkflowJobExecutionInfo,\n} from \"./workflow/transform\";\nexport {\n triggerExecutor,\n type TriggerExecutorOptions,\n type TriggerExecutorResult,\n} from \"./executor/trigger\";\nexport {\n listExecutorJobs,\n getExecutorJob,\n watchExecutorJob,\n type ListExecutorJobsOptions,\n type GetExecutorJobOptions,\n type WatchExecutorJobOptions,\n type ExecutorJobDetailInfo,\n type WatchExecutorJobResult,\n} from \"./executor/jobs\";\nexport type {\n ExecutorJobListInfo,\n ExecutorJobInfo,\n ExecutorJobAttemptInfo,\n} from \"./executor/transform\";\nexport { loadAccessToken, loadWorkspaceId } from \"./context\";\nexport { apiCall, type ApiCallOptions, type ApiCallResult } from \"./api\";\nexport { truncate, type TruncateOptions } from \"./tailordb/truncate\";\n\n// Migration exports\nexport {\n generate as migrateGenerate,\n type GenerateOptions as MigrateGenerateOptions,\n} from \"./tailordb/migrate/generate\";\nexport {\n createSnapshotFromLocalTypes,\n reconstructSnapshotFromMigrations,\n compareSnapshots,\n getNextMigrationNumber,\n getLatestMigrationNumber,\n getMigrationFiles,\n compareLocalTypesWithSnapshot,\n} from \"./tailordb/migrate/snapshot\";\nexport {\n getNamespacesWithMigrations,\n type NamespaceWithMigrations,\n} from \"./tailordb/migrate/config\";\nexport {\n hasChanges,\n formatMigrationDiff,\n formatDiffSummary,\n type MigrationDiff,\n type BreakingChangeInfo,\n} from \"./tailordb/migrate/diff-calculator\";\nexport {\n SCHEMA_FILE_NAME,\n DIFF_FILE_NAME,\n MIGRATE_FILE_NAME,\n DB_TYPES_FILE_NAME,\n INITIAL_SCHEMA_NUMBER,\n getMigrationDirPath,\n getMigrationFilePath,\n type SchemaSnapshot,\n type SnapshotType,\n type SnapshotFieldConfig,\n type MigrationInfo,\n} from \"./tailordb/migrate/snapshot\";\nexport { MIGRATION_LABEL_KEY } from \"./tailordb/migrate/types\";\n"],"mappings":";;;;;;AAIA,SAAS,OAAO,OAAO,KAAK,KAAK,EAAE,MAAM,EAAE,EAAE,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference path="./../user-defined.d.ts" />
|
|
2
|
-
import { $ as
|
|
3
|
-
import { A as
|
|
4
|
-
export { AttributeList, AttributeMap, AuthAccessTokenArgs, AuthAccessTokenTrigger, AuthConfig, AuthExternalConfig, AuthInvoker, AuthOwnConfig, AuthServiceInput, BuiltinIdP, Env, ExecutorServiceConfig, ExecutorServiceInput, FunctionOperation, GqlOperation, IDToken, IdPConfig, IdPExternalConfig, IdProviderConfig, IdpUserArgs, IdpUserTrigger, IncomingWebhookArgs, IncomingWebhookRequest, IncomingWebhookTrigger, OAuth2ClientInput as OAuth2Client, OAuth2ClientGrantType, OIDC, Operation, PermissionCondition, QueryType, RecordCreatedArgs, RecordDeletedArgs, RecordTrigger, RecordUpdatedArgs, Resolver, ResolverExecutedArgs, ResolverExecutedTrigger, ResolverExternalConfig, ResolverServiceConfig, ResolverServiceInput, SAML, SCIMAttribute, SCIMAttributeMapping, SCIMAttributeType, SCIMAuthorization, SCIMConfig, SCIMResource, ScheduleArgs, ScheduleTrigger, StaticWebsiteConfig, TailorDBField, TailorDBInstance, TailorDBType, TailorField, TailorTypeGqlPermission, TailorTypePermission, TailorUser, TenantProviderConfig, Trigger, UserAttributeKey, UserAttributeListKey, UserAttributeMap, UsernameFieldKey, ValueOperand, WORKFLOW_TEST_ENV_KEY, WebhookOperation, Workflow, WorkflowConfig, WorkflowJob, WorkflowJobContext, WorkflowJobInput, WorkflowJobOutput, WorkflowOperation, WorkflowServiceConfig, WorkflowServiceInput, authAccessTokenIssuedTrigger, authAccessTokenRefreshedTrigger, authAccessTokenRevokedTrigger, createExecutor, createResolver, createWorkflow, createWorkflowJob, db, defineAuth, defineConfig, defineGenerators, defineIdp, defineStaticWebSite, idpUserCreatedTrigger, idpUserDeletedTrigger, idpUserUpdatedTrigger, incomingWebhookTrigger, infer, output, recordCreatedTrigger, recordDeletedTrigger, recordUpdatedTrigger, resolverExecutedTrigger, scheduleTrigger, t, unauthenticatedTailorUser, unsafeAllowAllGqlPermission, unsafeAllowAllTypePermission };
|
|
2
|
+
import { $ as TailorDBInstance, A as AuthOwnConfig, At as unauthenticatedTailorUser, B as SCIMAttribute, D as AuthConfig, Dt as AttributeList, F as IdProviderConfig, G as SCIMResource, H as SCIMAttributeType, I as OAuth2ClientGrantType, J as UserAttributeListKey, K as TenantProviderConfig, L as OAuth2ClientInput, M as BuiltinIdP, N as DefinedAuth, O as AuthExternalConfig, Ot as AttributeMap, P as IDToken, Q as TailorDBField, R as OIDC, U as SCIMAuthorization, V as SCIMAttributeMapping, W as SCIMConfig, X as UsernameFieldKey, Y as UserAttributeMap, Z as ValueOperand, _t as ResolverExternalConfig, a as IdPExternalConfig, at as unsafeAllowAllGqlPermission, bt as ResolverServiceInput, c as WorkflowServiceConfig, d as defineStaticWebSite, et as TailorDBType, g as ExecutorServiceInput, gt as Resolver, h as ExecutorServiceConfig, ht as QueryType, i as IdPConfig, it as TailorTypePermission, j as AuthServiceInput, kt as TailorUser, l as WorkflowServiceInput, mt as TailorField, nt as PermissionCondition, ot as unsafeAllowAllTypePermission, q as UserAttributeKey, rt as TailorTypeGqlPermission, tt as db, u as StaticWebsiteConfig, wt as Env, yt as ResolverServiceConfig, z as SAML } from "../index-Dkm2qwmF.mjs";
|
|
3
|
+
import { A as idpUserDeletedTrigger, B as WorkflowOperation, C as RecordUpdatedArgs, D as authAccessTokenRefreshedTrigger, E as authAccessTokenIssuedTrigger, F as resolverExecutedTrigger, G as WorkflowJob, H as WorkflowConfig, I as FunctionOperation, J as WorkflowJobOutput, K as WorkflowJobContext, L as GqlOperation, M as recordCreatedTrigger, N as recordDeletedTrigger, O as authAccessTokenRevokedTrigger, P as recordUpdatedTrigger, Q as defineAuth, R as Operation, S as RecordTrigger, T as ResolverExecutedTrigger, U as createWorkflow, V as Workflow, W as WORKFLOW_TEST_ENV_KEY, X as createResolver, Y as createWorkflowJob, Z as AuthInvoker, _ as AuthAccessTokenTrigger, a as defineGenerators, b as RecordCreatedArgs, c as Trigger, d as IncomingWebhookTrigger, f as incomingWebhookTrigger, g as AuthAccessTokenArgs, h as scheduleTrigger, i as defineConfig, j as idpUserUpdatedTrigger, k as idpUserCreatedTrigger, l as IncomingWebhookArgs, m as ScheduleTrigger, n as output, o as defineIdp, p as ScheduleArgs, q as WorkflowJobInput, r as t, s as createExecutor, t as infer, u as IncomingWebhookRequest, v as IdpUserArgs, w as ResolverExecutedArgs, x as RecordDeletedArgs, y as IdpUserTrigger, z as WebhookOperation } from "../index-BwJ7-efr.mjs";
|
|
4
|
+
export { AttributeList, AttributeMap, AuthAccessTokenArgs, AuthAccessTokenTrigger, AuthConfig, AuthExternalConfig, AuthInvoker, AuthOwnConfig, AuthServiceInput, BuiltinIdP, DefinedAuth, Env, ExecutorServiceConfig, ExecutorServiceInput, FunctionOperation, GqlOperation, IDToken, IdPConfig, IdPExternalConfig, IdProviderConfig, IdpUserArgs, IdpUserTrigger, IncomingWebhookArgs, IncomingWebhookRequest, IncomingWebhookTrigger, OAuth2ClientInput as OAuth2Client, OAuth2ClientGrantType, OIDC, Operation, PermissionCondition, QueryType, RecordCreatedArgs, RecordDeletedArgs, RecordTrigger, RecordUpdatedArgs, Resolver, ResolverExecutedArgs, ResolverExecutedTrigger, ResolverExternalConfig, ResolverServiceConfig, ResolverServiceInput, SAML, SCIMAttribute, SCIMAttributeMapping, SCIMAttributeType, SCIMAuthorization, SCIMConfig, SCIMResource, ScheduleArgs, ScheduleTrigger, StaticWebsiteConfig, TailorDBField, TailorDBInstance, TailorDBType, TailorField, TailorTypeGqlPermission, TailorTypePermission, TailorUser, TenantProviderConfig, Trigger, UserAttributeKey, UserAttributeListKey, UserAttributeMap, UsernameFieldKey, ValueOperand, WORKFLOW_TEST_ENV_KEY, WebhookOperation, Workflow, WorkflowConfig, WorkflowJob, WorkflowJobContext, WorkflowJobInput, WorkflowJobOutput, WorkflowOperation, WorkflowServiceConfig, WorkflowServiceInput, authAccessTokenIssuedTrigger, authAccessTokenRefreshedTrigger, authAccessTokenRevokedTrigger, createExecutor, createResolver, createWorkflow, createWorkflowJob, db, defineAuth, defineConfig, defineGenerators, defineIdp, defineStaticWebSite, idpUserCreatedTrigger, idpUserDeletedTrigger, idpUserUpdatedTrigger, incomingWebhookTrigger, infer, output, recordCreatedTrigger, recordDeletedTrigger, recordUpdatedTrigger, resolverExecutedTrigger, scheduleTrigger, t, unauthenticatedTailorUser, unsafeAllowAllGqlPermission, unsafeAllowAllTypePermission };
|