@tailor-platform/sdk 2.0.0-next.8 → 2.0.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 +631 -0
- package/dist/{application-GzW98_Xr.mjs → application-CM6hKnSK.mjs} +489 -118
- package/dist/application-CM6hKnSK.mjs.map +1 -0
- package/dist/application-CXNaUNhv.mjs +3 -0
- package/dist/cli/commands/deploy/aigateway.d.mts +2 -2
- package/dist/cli/commands/deploy/application.d.mts +2 -2
- package/dist/cli/commands/deploy/auth.d.mts +2 -2
- package/dist/cli/commands/deploy/deploy.d.mts +1 -0
- package/dist/cli/commands/deploy/executor.d.mts +2 -2
- package/dist/cli/commands/deploy/function-registry.d.mts +1 -2
- package/dist/cli/commands/deploy/idp.d.mts +2 -2
- package/dist/cli/commands/deploy/label.d.mts +2 -0
- package/dist/cli/commands/deploy/resolver.d.mts +2 -2
- package/dist/cli/commands/deploy/secret-manager.d.mts +1 -1
- package/dist/cli/commands/deploy/staticwebsite.d.mts +2 -2
- package/dist/cli/commands/deploy/tailordb/index.d.mts +4 -2
- package/dist/cli/commands/deploy/types.d.mts +2 -1
- package/dist/cli/commands/deploy/workflow-execution-policy.d.mts +1 -2
- package/dist/cli/commands/deploy/workflow.d.mts +2 -2
- package/dist/cli/commands/executor/get.d.mts +1 -10
- package/dist/cli/commands/executor/jobs.d.mts +1 -38
- package/dist/cli/commands/executor/trigger.d.mts +1 -11
- package/dist/cli/commands/generate/seed/bundler.d.mts +2 -1
- package/dist/cli/commands/tailordb/migrate/bundler.d.mts +3 -2
- package/dist/cli/commands/tailordb/migrate/diff-calculator.d.mts +11 -1
- package/dist/cli/commands/tailordb/migrate/schema-checks.d.mts +5 -0
- package/dist/cli/commands/tailordb/migrate/snapshot.d.mts +1 -1
- package/dist/cli/commands/workflow/executions.d.mts +1 -13
- package/dist/cli/commands/workflow/get.d.mts +1 -10
- package/dist/cli/commands/workflow/start.d.mts +2 -14
- package/dist/cli/index.mjs +12 -6552
- package/dist/cli/lib.d.mts +14 -15
- package/dist/cli/lib.mjs +203 -46
- package/dist/cli/lib.mjs.map +1 -1
- package/dist/cli/{index.d.mts → main.d.mts} +1 -1
- package/dist/cli/main.mjs +6777 -0
- package/dist/cli/main.mjs.map +1 -0
- package/dist/cli/services/http-adapter/bundler.d.mts +1 -0
- package/dist/cli/services/workflow/bundler.d.mts +2 -1
- package/dist/cli/shared/client.d.mts +28 -3
- package/dist/cli/shared/config-loader.d.mts +11 -4
- package/dist/cli/shared/error-json.d.mts +23 -0
- package/dist/cli/shared/script-executor.d.mts +6 -3
- package/dist/cli/shared/seed-chunker.d.mts +2 -7
- package/dist/cli/shared/seed-context.d.mts +49 -0
- package/dist/cli/shared/tailordb-namespaces.d.mts +7 -4
- package/dist/cli/shared/tsconfig-paths-plugin.d.mts +2 -0
- package/dist/cli/shared/type-generator.d.mts +4 -3
- package/dist/completion/zsh-worker.zsh +85 -22
- package/dist/configure/config/types.d.mts +29 -4
- package/dist/configure/index.d.mts +4 -3
- package/dist/configure/index.mjs +183 -6
- package/dist/configure/index.mjs.map +1 -1
- package/dist/configure/services/executor/index.d.mts +2 -2
- package/dist/configure/services/executor/trigger/event.d.mts +245 -2
- package/dist/configure/services/executor/trigger/index.d.mts +3 -3
- package/dist/configure/services/idp/index.d.mts +2 -2
- package/dist/configure/services/idp/permission.d.mts +1 -16
- package/dist/configure/services/idp/types.d.mts +5 -1
- package/dist/configure/services/index.d.mts +4 -3
- package/dist/configure/services/resolver/index.d.mts +2 -1
- package/dist/configure/services/resolver/permission.d.mts +64 -0
- package/dist/configure/services/resolver/resolver.d.mts +14 -2
- package/dist/configure/services/tailordb/index.d.mts +0 -1
- package/dist/configure/services/tailordb/permission.d.mts +1 -16
- package/dist/configure/services/workflow/execution-policy.d.mts +3 -3
- package/dist/configure/services/workflow/execution-policy.types.d.mts +1 -1
- package/dist/configure/services/workflow/job.d.mts +11 -2
- package/dist/configure/services/workflow/workflow.d.mts +10 -0
- package/dist/configure/types/permission-operand.types.d.mts +20 -0
- package/dist/{crashreport-CxHne11E.mjs → crashreport-B5LqCTfF.mjs} +2 -2
- package/dist/{crashreport-CxHne11E.mjs.map → crashreport-B5LqCTfF.mjs.map} +1 -1
- package/dist/{crashreport-0ioNRZ4K.mjs → crashreport-eI7ty7ok.mjs} +1 -1
- package/dist/{errors-DfnF4ibq.mjs → errors-D7583Zz7.mjs} +2 -44
- package/dist/errors-D7583Zz7.mjs.map +1 -0
- package/dist/{globals-CBZ0egXT.mjs → globals-TfAVItuK.mjs} +21 -5
- package/dist/globals-TfAVItuK.mjs.map +1 -0
- package/dist/logger-BtX0suGY.mjs +48 -0
- package/dist/logger-BtX0suGY.mjs.map +1 -0
- package/dist/{logger-BwS4ppwO.mjs → logger-CXQq9YIp.mjs} +110 -13
- package/dist/logger-CXQq9YIp.mjs.map +1 -0
- package/dist/node-builtins-CmaL2Cbq.mjs +36 -0
- package/dist/node-builtins-CmaL2Cbq.mjs.map +1 -0
- package/dist/plugin/builtin/enum-constants/index.mjs +115 -2
- package/dist/plugin/builtin/enum-constants/index.mjs.map +1 -0
- package/dist/plugin/builtin/file-utils/index.mjs +149 -2
- package/dist/plugin/builtin/file-utils/index.mjs.map +1 -0
- package/dist/plugin/builtin/kysely-type/index.mjs +274 -2
- package/dist/plugin/builtin/kysely-type/index.mjs.map +1 -0
- package/dist/plugin/builtin/seed/index.d.mts +3 -2
- package/dist/plugin/builtin/seed/index.mjs +1 -1
- package/dist/plugin/builtin/seed/seed-type-processor.d.mts +21 -0
- package/dist/plugin/builtin/seed/types.d.mts +2 -0
- package/dist/{register-ts-hook-DvEs6YsL.mjs → register-ts-hook-LYV7zH-e.mjs} +2953 -996
- package/dist/register-ts-hook-LYV7zH-e.mjs.map +1 -0
- package/dist/{registry-i7EdJ-D5.mjs → registry-BIGVUrMB.mjs} +3 -3
- package/dist/registry-BIGVUrMB.mjs.map +1 -0
- package/dist/runtime/globals.d.mts +7 -0
- package/dist/runtime/index.d.mts +3 -1
- package/dist/runtime/index.mjs +3 -2
- package/dist/runtime/logger.d.mts +98 -0
- package/dist/runtime/logger.mjs +3 -0
- package/dist/runtime/workflow.d.mts +15 -7
- package/dist/runtime/workflow.mjs +1 -1
- package/dist/seed-B-yckgQY.mjs +483 -0
- package/dist/seed-B-yckgQY.mjs.map +1 -0
- package/dist/{service-DaeJlBoH.mjs → service-B5WynBHQ.mjs} +3 -3
- package/dist/{service-DaeJlBoH.mjs.map → service-B5WynBHQ.mjs.map} +1 -1
- package/dist/service-M7OYziQP.mjs +3 -0
- package/dist/{service-Dmxa2I4i.mjs → service-k1xy_A5G.mjs} +30 -4
- package/dist/service-k1xy_A5G.mjs.map +1 -0
- package/dist/{service_pb-BoLM0X4K.mjs → service_pb-D5--My_M.mjs} +5 -5
- package/dist/service_pb-D5--My_M.mjs.map +1 -0
- package/dist/{service_pb-r1T7kpJc.mjs → service_pb-i8CmnQP4.mjs} +1 -1
- package/dist/tailor-proto/src/tailor/v1/application_pb.d.mts +106 -1
- package/dist/tailor-proto/src/tailor/v1/auth_resource_pb.d.mts +6 -1
- package/dist/tailor-proto/src/tailor/v1/executor_resource_pb.d.mts +24 -1
- package/dist/tailor-proto/src/tailor/v1/function_pb.d.mts +49 -1
- package/dist/tailor-proto/src/tailor/v1/service_pb.d.mts +89 -6
- package/dist/tailor-proto/src/tailor/v1/telemetryrouter_resource_pb.d.mts +26 -1
- package/dist/tailor-proto/src/tailor/v1/workflow_pb.d.mts +101 -1
- package/dist/tailor-proto/src/tailor/v1/workflow_resource_pb.d.mts +22 -1
- package/dist/types/auth.generated.d.mts +14 -2
- package/dist/types/executor.generated.d.mts +45 -3
- package/dist/types/http-adapter.generated.d.mts +5 -0
- package/dist/types/idp.generated.d.mts +31 -1
- package/dist/types/resolver.generated.d.mts +30 -2
- package/dist/types/tailordb.generated.d.mts +15 -3
- package/dist/utils/test/index.d.mts +1 -2
- package/dist/utils/test/index.mjs +1 -169
- package/dist/utils/test/index.mjs.map +1 -1
- package/dist/vitest/environment.mjs +1 -1
- package/dist/vitest/index.d.mts +6 -4
- package/dist/vitest/index.mjs +112 -62
- package/dist/vitest/index.mjs.map +1 -1
- package/dist/vitest/mock.d.mts +2 -1
- package/dist/vitest/mocks/logger.d.mts +45 -0
- package/dist/vitest/mocks/workflow.d.mts +8 -8
- package/dist/vitest/setup.mjs +1 -1
- package/dist/{workflow-CsBvRE3g.mjs → workflow-Bamae_Yc.mjs} +5 -5
- package/dist/workflow-Bamae_Yc.mjs.map +1 -0
- package/dist/{workspace_resource_pb-Db3fv68L.mjs → workspace_resource_pb-DXnO2AT-.mjs} +13 -8
- package/dist/workspace_resource_pb-DXnO2AT-.mjs.map +1 -0
- package/docs/cli/application.md +5 -1
- package/docs/cli/tailordb.md +47 -13
- package/docs/cli-reference.md +38 -30
- package/docs/configuration.md +54 -2
- package/docs/github-actions.md +2 -2
- package/docs/migration/v2.md +408 -5
- package/docs/runtime.md +5 -1
- package/docs/services/executor.md +83 -3
- package/docs/services/idp.md +8 -6
- package/docs/services/resolver.md +60 -4
- package/docs/services/tailordb-migration.md +31 -7
- package/docs/services/tailordb.md +7 -5
- package/docs/services/workflow.md +33 -3
- package/docs/testing.md +34 -7
- package/package.json +31 -24
- package/dist/application-GzW98_Xr.mjs.map +0 -1
- package/dist/application-OM0taSPn.mjs +0 -3
- package/dist/cli/index.mjs.map +0 -1
- package/dist/enum-constants-j9QBF0cB.mjs +0 -116
- package/dist/enum-constants-j9QBF0cB.mjs.map +0 -1
- package/dist/errors-DfnF4ibq.mjs.map +0 -1
- package/dist/file-utils-yEiIS4nJ.mjs +0 -150
- package/dist/file-utils-yEiIS4nJ.mjs.map +0 -1
- package/dist/globals-CBZ0egXT.mjs.map +0 -1
- package/dist/kysely-type-DqIRgDYR.mjs +0 -275
- package/dist/kysely-type-DqIRgDYR.mjs.map +0 -1
- package/dist/logger-BwS4ppwO.mjs.map +0 -1
- package/dist/register-ts-hook-DvEs6YsL.mjs.map +0 -1
- package/dist/registry-i7EdJ-D5.mjs.map +0 -1
- package/dist/seed-CRSQJI_z.mjs +0 -1170
- package/dist/seed-CRSQJI_z.mjs.map +0 -1
- package/dist/service-BJAQ70e5.mjs +0 -3
- package/dist/service-Dmxa2I4i.mjs.map +0 -1
- package/dist/service_pb-BoLM0X4K.mjs.map +0 -1
- package/dist/utils/test/mock.d.mts +0 -86
- package/dist/workflow-CsBvRE3g.mjs.map +0 -1
- package/dist/workspace_resource_pb-Db3fv68L.mjs.map +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { AddOrganizationTeamMemberRequestSchema, AddOrganizationTeamMemberResponseSchema, CreateOrganizationFolderRequestSchema, CreateOrganizationFolderResponseSchema, CreateOrganizationTeamRequestSchema, CreateOrganizationTeamResponseSchema, CreateWorkspaceRequestSchema, CreateWorkspaceResponseSchema, DeleteOrganizationFolderIPRestrictionRequestSchema, DeleteOrganizationFolderIPRestrictionResponseSchema, DeleteOrganizationFolderRequestSchema, DeleteOrganizationFolderResponseSchema, DeleteOrganizationIPRestrictionRequestSchema, DeleteOrganizationIPRestrictionResponseSchema, DeleteOrganizationTeamRequestSchema, DeleteOrganizationTeamResponseSchema, DeleteWorkspaceRequestSchema, DeleteWorkspaceResponseSchema, GetOrganizationAccessRequestSchema, GetOrganizationAccessResponseSchema, GetOrganizationFolderAccessRequestSchema, GetOrganizationFolderAccessResponseSchema, GetOrganizationFolderIPRestrictionRequestSchema, GetOrganizationFolderIPRestrictionResponseSchema, GetOrganizationFolderRequestSchema, GetOrganizationFolderResponseSchema, GetOrganizationIPRestrictionRequestSchema, GetOrganizationIPRestrictionResponseSchema, GetOrganizationRequestSchema, GetOrganizationResponseSchema, GetOrganizationTeamMemberRequestSchema, GetOrganizationTeamMemberResponseSchema, GetOrganizationTeamRequestSchema, GetOrganizationTeamResponseSchema, GetPlatformAccountPlanRequestSchema, GetPlatformAccountPlanResponseSchema, GetWorkspacePlatformUserRequestSchema, GetWorkspacePlatformUserResponseSchema, GetWorkspaceRequestSchema, GetWorkspaceResponseSchema, GetWorkspaceRoleRequestSchema, GetWorkspaceRoleResponseSchema, GrantOrganizationAccessRequestSchema, GrantOrganizationAccessResponseSchema, GrantOrganizationFolderAccessRequestSchema, GrantOrganizationFolderAccessResponseSchema, InviteWorkspacePlatformUserRequestSchema, InviteWorkspacePlatformUserResponseSchema, ListAvailableWorkspacePlatformUserRolesRequestSchema, ListAvailableWorkspacePlatformUserRolesResponseSchema, ListAvailableWorkspaceRegionsRequestSchema, ListAvailableWorkspaceRegionsResponseSchema, ListOrganizationAccessesRequestSchema, ListOrganizationAccessesResponseSchema, ListOrganizationFolderAccessesRequestSchema, ListOrganizationFolderAccessesResponseSchema, ListOrganizationFoldersRequestSchema, ListOrganizationFoldersResponseSchema, ListOrganizationTeamMembersRequestSchema, ListOrganizationTeamMembersResponseSchema, ListOrganizationTeamsRequestSchema, ListOrganizationTeamsResponseSchema, ListOrganizationWorkspacesRequestSchema, ListOrganizationWorkspacesResponseSchema, ListOrganizationsRequestSchema, ListOrganizationsResponseSchema, ListUserOrganizationsRequestSchema, ListUserOrganizationsResponseSchema, ListWorkspacePlatformUsersRequestSchema, ListWorkspacePlatformUsersResponseSchema, ListWorkspacesRequestSchema, ListWorkspacesResponseSchema, RemoveOrganizationTeamMemberRequestSchema, RemoveOrganizationTeamMemberResponseSchema, RemoveWorkspacePlatformUserRequestSchema, RemoveWorkspacePlatformUserResponseSchema, RestoreWorkspaceRequestSchema, RestoreWorkspaceResponseSchema, RevokeOrganizationAccessRequestSchema, RevokeOrganizationAccessResponseSchema, RevokeOrganizationFolderAccessRequestSchema, RevokeOrganizationFolderAccessResponseSchema, UpdateOrganizationAccessRequestSchema, UpdateOrganizationAccessResponseSchema, UpdateOrganizationFolderAccessRequestSchema, UpdateOrganizationFolderAccessResponseSchema, UpdateOrganizationFolderRequestSchema, UpdateOrganizationFolderResponseSchema, UpdateOrganizationRequestSchema, UpdateOrganizationResponseSchema, UpdateOrganizationTeamMemberRequestSchema, UpdateOrganizationTeamMemberResponseSchema, UpdateOrganizationTeamRequestSchema, UpdateOrganizationTeamResponseSchema, UpdateWorkspacePlatformUserRequestSchema, UpdateWorkspacePlatformUserResponseSchema, UpdateWorkspaceRequestSchema, UpdateWorkspaceResponseSchema, UpsertOrganizationFolderIPRestrictionRequestSchema, UpsertOrganizationFolderIPRestrictionResponseSchema, UpsertOrganizationIPRestrictionRequestSchema, UpsertOrganizationIPRestrictionResponseSchema } from "../../tailor-proto/src/tailor/v1/workspace_pb.mjs";
|
|
2
|
-
import { CreateApplicationRequestSchema, CreateApplicationResponseSchema, DeleteApplicationRequestSchema, DeleteApplicationResponseSchema, GetApplicationRequestSchema, GetApplicationResponseSchema, GetApplicationSchemaHealthRequestSchema, GetApplicationSchemaHealthResponseSchema, ListApplicationsRequestSchema, ListApplicationsResponseSchema, UpdateApplicationRequestSchema, UpdateApplicationResponseSchema } from "../../tailor-proto/src/tailor/v1/application_pb.mjs";
|
|
2
|
+
import { CloneApplicationDataRequestSchema, CloneApplicationDataResponseSchema, CreateApplicationRequestSchema, CreateApplicationResponseSchema, DeleteApplicationRequestSchema, DeleteApplicationResponseSchema, GetApplicationRequestSchema, GetApplicationResponseSchema, GetApplicationSchemaHealthRequestSchema, GetApplicationSchemaHealthResponseSchema, GetCloneApplicationDataOperationRequestSchema, GetCloneApplicationDataOperationResponseSchema, ListApplicationsRequestSchema, ListApplicationsResponseSchema, UpdateApplicationRequestSchema, UpdateApplicationResponseSchema } from "../../tailor-proto/src/tailor/v1/application_pb.mjs";
|
|
3
3
|
import { CreateAIGatewayRequestSchema, CreateAIGatewayResponseSchema, DeleteAIGatewayRequestSchema, DeleteAIGatewayResponseSchema, GetAIGatewayRequestSchema, GetAIGatewayResponseSchema, ListAIGatewaysRequestSchema, ListAIGatewaysResponseSchema, UpdateAIGatewayRequestSchema, UpdateAIGatewayResponseSchema } from "../../tailor-proto/src/tailor/v1/aigateway_pb.mjs";
|
|
4
4
|
import { ComposeTailorDBSDLRequestSchema, ComposeTailorDBSDLResponseSchema, CreateTailorDBGQLPermissionRequestSchema, CreateTailorDBGQLPermissionResponseSchema, CreateTailorDBServiceRequestSchema, CreateTailorDBServiceResponseSchema, CreateTailorDBTypeRequestSchema, CreateTailorDBTypeResponseSchema, DeleteTailorDBGQLPermissionRequestSchema, DeleteTailorDBGQLPermissionResponseSchema, DeleteTailorDBServiceRequestSchema, DeleteTailorDBServiceResponseSchema, DeleteTailorDBTypeRequestSchema, DeleteTailorDBTypeResponseSchema, GetTailorDBGQLPermissionRequestSchema, GetTailorDBGQLPermissionResponseSchema, GetTailorDBServiceRequestSchema, GetTailorDBServiceResponseSchema, GetTailorDBTypeRequestSchema, GetTailorDBTypeResponseSchema, ListTailorDBGQLPermissionsRequestSchema, ListTailorDBGQLPermissionsResponseSchema, ListTailorDBServicesRequestSchema, ListTailorDBServicesResponseSchema, ListTailorDBTypesRequestSchema, ListTailorDBTypesResponseSchema, TruncateTailorDBTypeRequestSchema, TruncateTailorDBTypeResponseSchema, TruncateTailorDBTypesRequestSchema, TruncateTailorDBTypesResponseSchema, UpdateTailorDBGQLPermissionRequestSchema, UpdateTailorDBGQLPermissionResponseSchema, UpdateTailorDBServiceRequestSchema, UpdateTailorDBServiceResponseSchema, UpdateTailorDBTypeRequestSchema, UpdateTailorDBTypeResponseSchema } from "../../tailor-proto/src/tailor/v1/tailordb_pb.mjs";
|
|
5
5
|
import { ComposePipelineSDLRequestSchema, ComposePipelineSDLResponseSchema, CreatePipelineResolverRequestSchema, CreatePipelineResolverResponseSchema, CreatePipelineServiceRequestSchema, CreatePipelineServiceResponseSchema, DeletePipelineResolverRequestSchema, DeletePipelineResolverResponseSchema, DeletePipelineServiceRequestSchema, DeletePipelineServiceResponseSchema, GetPipelineResolverExecutionResultRequestSchema, GetPipelineResolverExecutionResultResponseSchema, GetPipelineResolverRequestSchema, GetPipelineResolverResponseSchema, GetPipelineServiceRequestSchema, GetPipelineServiceResponseSchema, ListPipelineResolverExecutionResultsRequestSchema, ListPipelineResolverExecutionResultsResponseSchema, ListPipelineResolversRequestSchema, ListPipelineResolversResponseSchema, ListPipelineServicesRequestSchema, ListPipelineServicesResponseSchema, RestartPipelineResolverRequestSchema, RestartPipelineResolverResponseSchema, UpdatePipelineResolverRequestSchema, UpdatePipelineResolverResponseSchema, UpdatePipelineServiceRequestSchema, UpdatePipelineServiceResponseSchema } from "../../tailor-proto/src/tailor/v1/pipeline_pb.mjs";
|
|
@@ -8,12 +8,12 @@ import { CreateExecutorExecutorRequestSchema, CreateExecutorExecutorResponseSche
|
|
|
8
8
|
import { CreateSecretManagerSecretRequestSchema, CreateSecretManagerSecretResponseSchema, CreateSecretManagerVaultRequestSchema, CreateSecretManagerVaultResponseSchema, DeleteSecretManagerSecretRequestSchema, DeleteSecretManagerSecretResponseSchema, DeleteSecretManagerVaultRequestSchema, DeleteSecretManagerVaultResponseSchema, GetSecretManagerSecretRequestSchema, GetSecretManagerSecretResponseSchema, GetSecretManagerVaultRequestSchema, GetSecretManagerVaultResponseSchema, ListSecretManagerSecretsRequestSchema, ListSecretManagerSecretsResponseSchema, ListSecretManagerVaultsRequestSchema, ListSecretManagerVaultsResponseSchema, UpdateSecretManagerSecretRequestSchema, UpdateSecretManagerSecretResponseSchema } from "../../tailor-proto/src/tailor/v1/secret_manager_pb.mjs";
|
|
9
9
|
import { CreateAuthConnectionRequestSchema, CreateAuthConnectionResponseSchema, CreateAuthHookRequestSchema, CreateAuthHookResponseSchema, CreateAuthIDPConfigRequestSchema, CreateAuthIDPConfigResponseSchema, CreateAuthMachineUserRequestSchema, CreateAuthMachineUserResponseSchema, CreateAuthOAuth2ClientRequestSchema, CreateAuthOAuth2ClientResponseSchema, CreateAuthSCIMConfigRequestSchema, CreateAuthSCIMConfigResponseSchema, CreateAuthSCIMResourceRequestSchema, CreateAuthSCIMResourceResponseSchema, CreateAuthServiceRequestSchema, CreateAuthServiceResponseSchema, CreateControlplaneMachineUserRequestSchema, CreateControlplaneMachineUserResponseSchema, CreatePersonalAccessTokenRequestSchema, CreatePersonalAccessTokenResponseSchema, CreateTenantConfigRequestSchema, CreateTenantConfigResponseSchema, CreateUserProfileConfigRequestSchema, CreateUserProfileConfigResponseSchema, DeleteAuthConnectionRequestSchema, DeleteAuthConnectionResponseSchema, DeleteAuthHookRequestSchema, DeleteAuthHookResponseSchema, DeleteAuthIDPConfigRequestSchema, DeleteAuthIDPConfigResponseSchema, DeleteAuthMachineUserRequestSchema, DeleteAuthMachineUserResponseSchema, DeleteAuthOAuth2ClientRequestSchema, DeleteAuthOAuth2ClientResponseSchema, DeleteAuthSCIMConfigRequestSchema, DeleteAuthSCIMConfigResponseSchema, DeleteAuthSCIMResourceRequestSchema, DeleteAuthSCIMResourceResponseSchema, DeleteAuthServiceRequestSchema, DeleteAuthServiceResponseSchema, DeleteControlplaneMachineUserRequestSchema, DeleteControlplaneMachineUserResponseSchema, DeletePersonalAccessTokenRequestSchema, DeletePersonalAccessTokenResponseSchema, DeleteTenantConfigRequestSchema, DeleteTenantConfigResponseSchema, DeleteUserProfileConfigRequestSchema, DeleteUserProfileConfigResponseSchema, ExchangeAuthConnectionAuthorizationCodeRequestSchema, ExchangeAuthConnectionAuthorizationCodeResponseSchema, GetAuthHookRequestSchema, GetAuthHookResponseSchema, GetAuthIDPConfigRequestSchema, GetAuthIDPConfigResponseSchema, GetAuthMachineUserRequestSchema, GetAuthMachineUserResponseSchema, GetAuthOAuth2ClientRequestSchema, GetAuthOAuth2ClientResponseSchema, GetAuthSCIMConfigRequestSchema, GetAuthSCIMConfigResponseSchema, GetAuthSCIMResourceRequestSchema, GetAuthSCIMResourceResponseSchema, GetAuthSCIMResourcesRequestSchema, GetAuthSCIMResourcesResponseSchema, GetAuthServiceRequestSchema, GetAuthServiceResponseSchema, GetControlplaneMachineUserByNameRequestSchema, GetControlplaneMachineUserByNameResponseSchema, GetControlplaneMachineUserRequestSchema, GetControlplaneMachineUserResponseSchema, GetTenantConfigRequestSchema, GetTenantConfigResponseSchema, GetUserProfileConfigRequestSchema, GetUserProfileConfigResponseSchema, ListAuthConnectionsRequestSchema, ListAuthConnectionsResponseSchema, ListAuthIDPConfigsRequestSchema, ListAuthIDPConfigsResponseSchema, ListAuthMachineUsersRequestSchema, ListAuthMachineUsersResponseSchema, ListAuthOAuth2ClientsRequestSchema, ListAuthOAuth2ClientsResponseSchema, ListAuthServicesRequestSchema, ListAuthServicesResponseSchema, ListControlplaneMachineUsersRequestSchema, ListControlplaneMachineUsersResponseSchema, ListPersonalAccessTokensRequestSchema, ListPersonalAccessTokensResponseSchema, RegisterAuthConnectionSessionRequestSchema, RegisterAuthConnectionSessionResponseSchema, RevokeAuthConnectionRequestSchema, RevokeAuthConnectionResponseSchema, UpdateAuthConnectionRequestSchema, UpdateAuthConnectionResponseSchema, UpdateAuthHookRequestSchema, UpdateAuthHookResponseSchema, UpdateAuthIDPConfigRequestSchema, UpdateAuthIDPConfigResponseSchema, UpdateAuthMachineUserRequestSchema, UpdateAuthMachineUserResponseSchema, UpdateAuthOAuth2ClientRequestSchema, UpdateAuthOAuth2ClientResponseSchema, UpdateAuthSCIMConfigRequestSchema, UpdateAuthSCIMConfigResponseSchema, UpdateAuthSCIMResourceRequestSchema, UpdateAuthSCIMResourceResponseSchema, UpdateAuthServiceRequestSchema, UpdateAuthServiceResponseSchema, UpdateControlplaneMachineUserRequestSchema, UpdateControlplaneMachineUserResponseSchema, UpdateTenantConfigRequestSchema, UpdateTenantConfigResponseSchema, UpdateUserProfileConfigRequestSchema, UpdateUserProfileConfigResponseSchema } from "../../tailor-proto/src/tailor/v1/auth_pb.mjs";
|
|
10
10
|
import { ListControlplaneActivityLogsRequestSchema, ListControlplaneActivityLogsResponseSchema, ListDataplaneEventsRequestSchema, ListDataplaneEventsResponseSchema } from "../../tailor-proto/src/tailor/v1/events_pb.mjs";
|
|
11
|
-
import { GetFunctionExecutionRequestSchema, GetFunctionExecutionResponseSchema, ListFunctionExecutionsRequestSchema, ListFunctionExecutionsResponseSchema, TestExecScriptRequestSchema, TestExecScriptResponseSchema } from "../../tailor-proto/src/tailor/v1/function_pb.mjs";
|
|
11
|
+
import { ExecScriptRequestSchema, ExecScriptResponseSchema, GetFunctionExecutionRequestSchema, GetFunctionExecutionResponseSchema, ListFunctionExecutionsRequestSchema, ListFunctionExecutionsResponseSchema, TestExecScriptRequestSchema, TestExecScriptResponseSchema } from "../../tailor-proto/src/tailor/v1/function_pb.mjs";
|
|
12
12
|
import { CreateFunctionRegistryRequestSchema, CreateFunctionRegistryResponseSchema, DeleteFunctionRegistryRequestSchema, DeleteFunctionRegistryResponseSchema, DownloadFunctionRegistryScriptRequestSchema, DownloadFunctionRegistryScriptResponseSchema, GetFunctionRegistryRequestSchema, GetFunctionRegistryResponseSchema, ListFunctionRegistriesRequestSchema, ListFunctionRegistriesResponseSchema, UpdateFunctionRegistryRequestSchema, UpdateFunctionRegistryResponseSchema } from "../../tailor-proto/src/tailor/v1/function_registry_pb.mjs";
|
|
13
13
|
import { ListMeterAITokenUsagesRequestSchema, ListMeterAITokenUsagesResponseSchema, ListMeterEventCountsRequestSchema, ListMeterEventCountsResponseSchema, ListMeterExecutionCountsRequestSchema, ListMeterExecutionCountsResponseSchema, ListMeterRequestCountsRequestSchema, ListMeterRequestCountsResponseSchema } from "../../tailor-proto/src/tailor/v1/meter_pb.mjs";
|
|
14
14
|
import { CreateIdPClientRequestSchema, CreateIdPClientResponseSchema, CreateIdPServiceRequestSchema, CreateIdPServiceResponseSchema, DeleteIdPClientRequestSchema, DeleteIdPClientResponseSchema, DeleteIdPServiceRequestSchema, DeleteIdPServiceResponseSchema, GetIdPClientRequestSchema, GetIdPClientResponseSchema, GetIdPServiceRequestSchema, GetIdPServiceResponseSchema, ListIdPClientsRequestSchema, ListIdPClientsResponseSchema, ListIdPServicesRequestSchema, ListIdPServicesResponseSchema, UpdateIdPServiceRequestSchema, UpdateIdPServiceResponseSchema } from "../../tailor-proto/src/tailor/v1/idp_pb.mjs";
|
|
15
15
|
import { AddCustomDomainRequestSchema, AddCustomDomainResponseSchema, CreateDeploymentRequestSchema, CreateDeploymentResponseSchema, CreateStaticWebsiteRequestSchema, CreateStaticWebsiteResponseSchema, DeleteStaticWebsiteRequestSchema, DeleteStaticWebsiteResponseSchema, GetCustomDomainRequestSchema, GetCustomDomainResponseSchema, GetStaticWebsiteRequestSchema, GetStaticWebsiteResponseSchema, ListCustomDomainsRequestSchema, ListCustomDomainsResponseSchema, ListStaticWebsitesRequestSchema, ListStaticWebsitesResponseSchema, PublishDeploymentRequestSchema, PublishDeploymentResponseSchema, RemoveCustomDomainRequestSchema, RemoveCustomDomainResponseSchema, UpdateStaticWebsiteRequestSchema, UpdateStaticWebsiteResponseSchema, UploadFileRequestSchema, UploadFileResponseSchema } from "../../tailor-proto/src/tailor/v1/staticwebsite_pb.mjs";
|
|
16
|
-
import { CreateWorkflowJobFunctionExecutionPolicyRequestSchema, CreateWorkflowJobFunctionExecutionPolicyResponseSchema, CreateWorkflowJobFunctionRequestSchema, CreateWorkflowJobFunctionResponseSchema, CreateWorkflowRequestSchema, CreateWorkflowResponseSchema, DeleteWorkflowJobFunctionExecutionPolicyRequestSchema, DeleteWorkflowJobFunctionExecutionPolicyResponseSchema, DeleteWorkflowJobFunctionRequestSchema, DeleteWorkflowJobFunctionResponseSchema, DeleteWorkflowRequestSchema, DeleteWorkflowResponseSchema, GetWorkflowByNameRequestSchema, GetWorkflowByNameResponseSchema, GetWorkflowExecutionRequestSchema, GetWorkflowExecutionResponseSchema, GetWorkflowJobFunctionByNameRequestSchema, GetWorkflowJobFunctionByNameResponseSchema, GetWorkflowJobFunctionExecutionPolicyByKeyRequestSchema, GetWorkflowJobFunctionExecutionPolicyByKeyResponseSchema, GetWorkflowJobFunctionExecutionPolicyRequestSchema, GetWorkflowJobFunctionExecutionPolicyResponseSchema, GetWorkflowJobFunctionRequestSchema, GetWorkflowJobFunctionResponseSchema, GetWorkflowRequestSchema, GetWorkflowResponseSchema, ListWorkflowExecutionsRequestSchema, ListWorkflowExecutionsResponseSchema, ListWorkflowJobFunctionExecutionPoliciesRequestSchema, ListWorkflowJobFunctionExecutionPoliciesResponseSchema, ListWorkflowJobFunctionsRequestSchema, ListWorkflowJobFunctionsResponseSchema, ListWorkflowsRequestSchema, ListWorkflowsResponseSchema, TestResumeWorkflowRequestSchema, TestResumeWorkflowResponseSchema, TestStartWorkflowRequestSchema, TestStartWorkflowResponseSchema, UpdateWorkflowJobFunctionExecutionPolicyRequestSchema, UpdateWorkflowJobFunctionExecutionPolicyResponseSchema, UpdateWorkflowJobFunctionRequestSchema, UpdateWorkflowJobFunctionResponseSchema, UpdateWorkflowRequestSchema, UpdateWorkflowResponseSchema } from "../../tailor-proto/src/tailor/v1/workflow_pb.mjs";
|
|
16
|
+
import { CreateWorkflowJobFunctionExecutionPolicyRequestSchema, CreateWorkflowJobFunctionExecutionPolicyResponseSchema, CreateWorkflowJobFunctionRequestSchema, CreateWorkflowJobFunctionResponseSchema, CreateWorkflowRequestSchema, CreateWorkflowResponseSchema, DeleteWorkflowJobFunctionExecutionPolicyRequestSchema, DeleteWorkflowJobFunctionExecutionPolicyResponseSchema, DeleteWorkflowJobFunctionRequestSchema, DeleteWorkflowJobFunctionResponseSchema, DeleteWorkflowRequestSchema, DeleteWorkflowResponseSchema, GetWorkflowByNameRequestSchema, GetWorkflowByNameResponseSchema, GetWorkflowExecutionRequestSchema, GetWorkflowExecutionResponseSchema, GetWorkflowJobFunctionByNameRequestSchema, GetWorkflowJobFunctionByNameResponseSchema, GetWorkflowJobFunctionExecutionPolicyByKeyRequestSchema, GetWorkflowJobFunctionExecutionPolicyByKeyResponseSchema, GetWorkflowJobFunctionExecutionPolicyRequestSchema, GetWorkflowJobFunctionExecutionPolicyResponseSchema, GetWorkflowJobFunctionRequestSchema, GetWorkflowJobFunctionResponseSchema, GetWorkflowRequestSchema, GetWorkflowResponseSchema, ListWorkflowExecutionsRequestSchema, ListWorkflowExecutionsResponseSchema, ListWorkflowJobFunctionExecutionPoliciesRequestSchema, ListWorkflowJobFunctionExecutionPoliciesResponseSchema, ListWorkflowJobFunctionsRequestSchema, ListWorkflowJobFunctionsResponseSchema, ListWorkflowsRequestSchema, ListWorkflowsResponseSchema, ResumeWorkflowExecutionRequestSchema, ResumeWorkflowExecutionResponseSchema, StartWorkflowRequestSchema, StartWorkflowResponseSchema, TestResumeWorkflowRequestSchema, TestResumeWorkflowResponseSchema, TestStartWorkflowRequestSchema, TestStartWorkflowResponseSchema, UpdateWorkflowJobFunctionExecutionPolicyRequestSchema, UpdateWorkflowJobFunctionExecutionPolicyResponseSchema, UpdateWorkflowJobFunctionRequestSchema, UpdateWorkflowJobFunctionResponseSchema, UpdateWorkflowRequestSchema, UpdateWorkflowResponseSchema } from "../../tailor-proto/src/tailor/v1/workflow_pb.mjs";
|
|
17
17
|
import { GetMetadataRequestSchema, GetMetadataResponseSchema, SetMetadataRequestSchema, SetMetadataResponseSchema } from "../../tailor-proto/src/tailor/v1/metadata_pb.mjs";
|
|
18
18
|
import { CreateOTLPExporterRequestSchema, CreateOTLPExporterResponseSchema, CreateResourceAttributesConfigRequestSchema, CreateResourceAttributesConfigResponseSchema, DeleteOTLPExporterRequestSchema, DeleteOTLPExporterResponseSchema, DeleteResourceAttributesConfigRequestSchema, DeleteResourceAttributesConfigResponseSchema, GetOTLPExporterRequestSchema, GetOTLPExporterResponseSchema, GetResourceAttributesConfigRequestSchema, GetResourceAttributesConfigResponseSchema, ListOTLPExportersRequestSchema, ListOTLPExportersResponseSchema, TestOTLPExporterRequestSchema, TestOTLPExporterResponseSchema, UpdateOTLPExporterRequestSchema, UpdateOTLPExporterResponseSchema, UpdateResourceAttributesConfigRequestSchema, UpdateResourceAttributesConfigResponseSchema } from "../../tailor-proto/src/tailor/v1/telemetryrouter_pb.mjs";
|
|
19
19
|
import { OperatorService, PingRequestSchema, PingResponseSchema } from "../../tailor-proto/src/tailor/v1/service_pb.mjs";
|
|
@@ -323,6 +323,16 @@ declare function initOperatorClient(accessToken: string, config?: PlatformClient
|
|
|
323
323
|
input: typeof GetApplicationSchemaHealthRequestSchema;
|
|
324
324
|
output: typeof GetApplicationSchemaHealthResponseSchema;
|
|
325
325
|
};
|
|
326
|
+
cloneApplicationData: {
|
|
327
|
+
methodKind: "unary";
|
|
328
|
+
input: typeof CloneApplicationDataRequestSchema;
|
|
329
|
+
output: typeof CloneApplicationDataResponseSchema;
|
|
330
|
+
};
|
|
331
|
+
getCloneApplicationDataOperation: {
|
|
332
|
+
methodKind: "unary";
|
|
333
|
+
input: typeof GetCloneApplicationDataOperationRequestSchema;
|
|
334
|
+
output: typeof GetCloneApplicationDataOperationResponseSchema;
|
|
335
|
+
};
|
|
326
336
|
createAIGateway: {
|
|
327
337
|
methodKind: "unary";
|
|
328
338
|
input: typeof CreateAIGatewayRequestSchema;
|
|
@@ -898,6 +908,11 @@ declare function initOperatorClient(accessToken: string, config?: PlatformClient
|
|
|
898
908
|
input: typeof ListControlplaneActivityLogsRequestSchema;
|
|
899
909
|
output: typeof ListControlplaneActivityLogsResponseSchema;
|
|
900
910
|
};
|
|
911
|
+
execScript: {
|
|
912
|
+
methodKind: "unary";
|
|
913
|
+
input: typeof ExecScriptRequestSchema;
|
|
914
|
+
output: typeof ExecScriptResponseSchema;
|
|
915
|
+
};
|
|
901
916
|
testExecScript: {
|
|
902
917
|
methodKind: "unary";
|
|
903
918
|
input: typeof TestExecScriptRequestSchema;
|
|
@@ -1138,6 +1153,16 @@ declare function initOperatorClient(accessToken: string, config?: PlatformClient
|
|
|
1138
1153
|
input: typeof ListWorkflowExecutionsRequestSchema;
|
|
1139
1154
|
output: typeof ListWorkflowExecutionsResponseSchema;
|
|
1140
1155
|
};
|
|
1156
|
+
startWorkflow: {
|
|
1157
|
+
methodKind: "unary";
|
|
1158
|
+
input: typeof StartWorkflowRequestSchema;
|
|
1159
|
+
output: typeof StartWorkflowResponseSchema;
|
|
1160
|
+
};
|
|
1161
|
+
resumeWorkflowExecution: {
|
|
1162
|
+
methodKind: "unary";
|
|
1163
|
+
input: typeof ResumeWorkflowExecutionRequestSchema;
|
|
1164
|
+
output: typeof ResumeWorkflowExecutionResponseSchema;
|
|
1165
|
+
};
|
|
1141
1166
|
testStartWorkflow: {
|
|
1142
1167
|
methodKind: "unary";
|
|
1143
1168
|
input: typeof TestStartWorkflowRequestSchema;
|
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
import { Plugin } from "../../plugin/types.mjs";
|
|
2
|
-
import { AppConfig } from "../../configure/config/types.mjs";
|
|
2
|
+
import { AppConfig, EnvValue } from "../../configure/config/types.mjs";
|
|
3
3
|
//#region src/cli/shared/config-loader.d.ts
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
5
|
+
* App config whose `env` entries have been resolved to the values that get
|
|
6
|
+
* deployed: the `{ value, allowSecretReason }` form accepted in `defineConfig`
|
|
7
|
+
* is unwrapped during loading, so nothing downstream can deploy a wrapper
|
|
8
|
+
* object or the reason string alongside the value.
|
|
6
9
|
*/
|
|
7
|
-
type
|
|
10
|
+
type ResolvedEnvAppConfig = Omit<AppConfig, "env"> & {
|
|
11
|
+
env?: Record<string, EnvValue>;
|
|
12
|
+
};
|
|
13
|
+
/** Loaded configuration with resolved path. */
|
|
14
|
+
type LoadedConfig = ResolvedEnvAppConfig & {
|
|
8
15
|
path: string;
|
|
9
16
|
};
|
|
10
17
|
interface LoadConfigOptions {
|
|
@@ -22,4 +29,4 @@ declare function loadConfig(configPath?: string, options?: LoadConfigOptions): P
|
|
|
22
29
|
plugins: Plugin[];
|
|
23
30
|
}>;
|
|
24
31
|
//#endregion
|
|
25
|
-
export { LoadConfigOptions, LoadedConfig, loadConfig };
|
|
32
|
+
export { LoadConfigOptions, LoadedConfig, ResolvedEnvAppConfig, loadConfig };
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
//#region src/cli/shared/error-json.d.ts
|
|
2
|
+
interface ErrorToJsonOptions {
|
|
3
|
+
/** Include the original stack trace in the error envelope. */
|
|
4
|
+
includeStack?: boolean;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Convert a CLI failure into the stable JSON error envelope.
|
|
8
|
+
* @param error - Failure to serialize
|
|
9
|
+
* @param options - JSON serialization options
|
|
10
|
+
* @returns JSON-compatible error envelope
|
|
11
|
+
*/
|
|
12
|
+
declare function errorToJson(error: unknown, options?: ErrorToJsonOptions): {
|
|
13
|
+
error: Readonly<Record<string, unknown>>;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Serialize a CLI failure into the stable JSON error envelope.
|
|
17
|
+
* @param error - Failure to serialize
|
|
18
|
+
* @param options - JSON serialization options
|
|
19
|
+
* @returns Serialized JSON error envelope
|
|
20
|
+
*/
|
|
21
|
+
declare function serializeError(error: unknown, options?: ErrorToJsonOptions): string;
|
|
22
|
+
//#endregion
|
|
23
|
+
export { ErrorToJsonOptions, errorToJson, serializeError };
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AuthInvokerSchema } from "../../tailor-proto/src/tailor/v1/auth_resource_pb.mjs";
|
|
2
2
|
import { FunctionExecution_Status } from "../../tailor-proto/src/tailor/v1/function_resource_pb.mjs";
|
|
3
3
|
import { OperatorClient } from "./client.mjs";
|
|
4
4
|
import { Jsonifiable } from "type-fest";
|
|
5
|
+
import { MessageInitShape } from "@bufbuild/protobuf";
|
|
5
6
|
//#region src/cli/shared/script-executor.d.ts
|
|
7
|
+
/** Authentication context for script execution, provided as a plain object. */
|
|
8
|
+
type ScriptInvoker = MessageInitShape<typeof AuthInvokerSchema>;
|
|
6
9
|
/**
|
|
7
10
|
* Options for script execution
|
|
8
11
|
*/
|
|
@@ -18,7 +21,7 @@ interface ScriptExecutionOptions<T extends Jsonifiable = Jsonifiable> {
|
|
|
18
21
|
/** Optional JSON-serializable argument to pass to the script */
|
|
19
22
|
arg?: T;
|
|
20
23
|
/** Auth invoker for script execution */
|
|
21
|
-
invoker:
|
|
24
|
+
invoker: ScriptInvoker;
|
|
22
25
|
/** Polling interval in milliseconds (default: 1000ms) */
|
|
23
26
|
pollInterval?: number;
|
|
24
27
|
}
|
|
@@ -71,4 +74,4 @@ declare function waitForExecution(client: OperatorClient, workspaceId: string, e
|
|
|
71
74
|
*/
|
|
72
75
|
declare function executeScript<T extends Jsonifiable = Jsonifiable>(options: ScriptExecutionOptions<T>): Promise<ScriptExecutionResult>;
|
|
73
76
|
//#endregion
|
|
74
|
-
export { ExecutionWaitResult, ScriptExecutionOptions, ScriptExecutionResult, executeScript, waitForExecution };
|
|
77
|
+
export { ExecutionWaitResult, ScriptExecutionOptions, ScriptExecutionResult, ScriptInvoker, executeScript, waitForExecution };
|
|
@@ -1,14 +1,9 @@
|
|
|
1
|
+
import { JsonObject } from "type-fest";
|
|
1
2
|
//#region src/cli/shared/seed-chunker.d.ts
|
|
2
|
-
/**
|
|
3
|
-
* Seed data chunker for splitting large seed data into manageable message sizes.
|
|
4
|
-
*
|
|
5
|
-
* When seed data exceeds the gRPC message size limit, this module splits the data
|
|
6
|
-
* into multiple chunks at type boundaries (or record boundaries for large types).
|
|
7
|
-
*/
|
|
8
3
|
/**
|
|
9
4
|
* Seed data keyed by type name, with an array of records per type.
|
|
10
5
|
*/
|
|
11
|
-
type SeedData = Record<string,
|
|
6
|
+
type SeedData = Record<string, JsonObject[]>;
|
|
12
7
|
/**
|
|
13
8
|
* A single chunk of seed data with metadata for ordered execution.
|
|
14
9
|
*/
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { LoadedConfig } from "./config-loader.mjs";
|
|
2
|
+
import { SeedNamespaceConfig } from "../../plugin/builtin/seed/seed-type-processor.mjs";
|
|
3
|
+
//#region src/cli/shared/seed-context.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* IdP `_User` seeding context, present when the config uses the built-in IdP
|
|
6
|
+
* with a user profile type.
|
|
7
|
+
*/
|
|
8
|
+
interface SeedIdpUserContext {
|
|
9
|
+
/** IdP namespace the `_User` records belong to. */
|
|
10
|
+
idpNamespace: string;
|
|
11
|
+
/** Server-side script that creates `_User` records from seed rows. */
|
|
12
|
+
seedScriptCode: string;
|
|
13
|
+
/** Server-side script that deletes all `_User` records. */
|
|
14
|
+
truncateScriptCode: string;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Everything a seed run needs from the local config: the seed data location,
|
|
18
|
+
* per-namespace seeding order, and IdP user context.
|
|
19
|
+
*/
|
|
20
|
+
interface SeedContext {
|
|
21
|
+
/** The loaded Tailor config. */
|
|
22
|
+
config: LoadedConfig;
|
|
23
|
+
/** Absolute path to the seedPlugin output directory. */
|
|
24
|
+
distPath: string;
|
|
25
|
+
/** Default machine user name from seedPlugin options, if configured. */
|
|
26
|
+
machineUserName?: string | undefined;
|
|
27
|
+
/** Seed ordering information per TailorDB namespace. */
|
|
28
|
+
namespaces: SeedNamespaceConfig[];
|
|
29
|
+
/** IdP `_User` seeding context, or null when not applicable. */
|
|
30
|
+
idpUser: SeedIdpUserContext | null;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Options for {@link loadSeedContext}.
|
|
34
|
+
*/
|
|
35
|
+
interface LoadSeedContextOptions {
|
|
36
|
+
/** Path to tailor.config.ts. Defaults to searching from the current directory. */
|
|
37
|
+
configPath?: string;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Load the seed context from the local config. Requires `seedPlugin` to be
|
|
41
|
+
* configured in the config's plugins. A relative `distPath` in the seedPlugin
|
|
42
|
+
* options is resolved against the current working directory — the same base
|
|
43
|
+
* `tailor generate` writes it to.
|
|
44
|
+
* @param options - Seed context loading options.
|
|
45
|
+
* @returns The seed context computed from the local config.
|
|
46
|
+
*/
|
|
47
|
+
declare function loadSeedContext(options?: LoadSeedContextOptions): Promise<SeedContext>;
|
|
48
|
+
//#endregion
|
|
49
|
+
export { LoadSeedContextOptions, SeedContext, SeedIdpUserContext, type SeedNamespaceConfig, loadSeedContext };
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { TailorDBNamespaceData } from "../../plugin/types.mjs";
|
|
1
|
+
import { Plugin, TailorDBNamespaceData } from "../../plugin/types.mjs";
|
|
2
2
|
import { LoadedConfig } from "./config-loader.mjs";
|
|
3
|
+
import "../services/application.mjs";
|
|
3
4
|
//#region src/cli/shared/tailordb-namespaces.d.ts
|
|
4
5
|
/**
|
|
5
6
|
* Namespace selection for {@link loadTailorDBNamespaces}: explicit namespace
|
|
6
|
-
* names, or a selector deriving them from the loaded config.
|
|
7
|
-
* `undefined` (or omitting the option) loads all owned namespaces.
|
|
7
|
+
* names, or a selector deriving them from the loaded config and its plugins.
|
|
8
|
+
* Returning `undefined` (or omitting the option) loads all owned namespaces.
|
|
8
9
|
*/
|
|
9
|
-
type TailorDBNamespaceSelector = string[] | ((config: LoadedConfig) => string[] | undefined);
|
|
10
|
+
type TailorDBNamespaceSelector = string[] | ((config: LoadedConfig, plugins: Plugin[]) => string[] | undefined);
|
|
10
11
|
/**
|
|
11
12
|
* Options for {@link loadTailorDBNamespaces}.
|
|
12
13
|
*/
|
|
@@ -22,6 +23,8 @@ interface LoadTailorDBNamespacesOptions {
|
|
|
22
23
|
interface LoadedTailorDBNamespaces {
|
|
23
24
|
/** The loaded Tailor config. */
|
|
24
25
|
config: LoadedConfig;
|
|
26
|
+
/** Plugins collected from the config module's plugin-array exports (typically `definePlugins()`). */
|
|
27
|
+
plugins: Plugin[];
|
|
25
28
|
/** Loaded TailorDB namespace data, in config order. */
|
|
26
29
|
namespaces: TailorDBNamespaceData[];
|
|
27
30
|
}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import
|
|
1
|
+
import "../../configure/config/types.mjs";
|
|
2
|
+
import { ResolvedEnvAppConfig } from "./config-loader.mjs";
|
|
2
3
|
//#region src/cli/shared/type-generator.d.ts
|
|
3
4
|
/**
|
|
4
5
|
* Options for generating user type definitions
|
|
5
6
|
*/
|
|
6
7
|
interface GenerateUserTypesOptions {
|
|
7
|
-
/** Application config */
|
|
8
|
-
config:
|
|
8
|
+
/** Application config with resolved `env` values */
|
|
9
|
+
config: ResolvedEnvAppConfig;
|
|
9
10
|
/** Path to Tailor config file */
|
|
10
11
|
configPath: string;
|
|
11
12
|
}
|